download a file in C3 throught php rederection

  • Thread starter Thread starter Octavio Filipe
  • Start date Start date
O

Octavio Filipe

Hi there,

I'm trying to download a file, but i don't have the real link, i only
have a php page that redirects me to the real link...

I'm using
webClient.DownloadFile(DOWNLOAD_URL,"c:\\temp\\");
and I'm copying headers (just in case the server verifies then).

But still it doesn't work!

By the way DOWNLOAD_URL have the complete php link:
https://server.com/folder/certificates.php

Thanks in advance.
Octavio Filipe
 
Hi Octavio,

I think you may need to use HttpWebRequest/Response. HttpWebRequest has an AllowRedirect property that might be of use. You can check the HttpWebRequest.Address property to determine the redirected address.
 
Back
Top