Hi,

I have succeeded downloading a file using the POST method using the help of
this list, but unfortunately I am not able to get the file name every time.

I have seen that if the web server sets the Content-Disposition header and
specifies the file name, I am able to use it, but sometimes this header is
not given.
In that situation, only the Content-type: application/zip is used, but I
don't know how to get the file name.
If I try to download that file using Internet Explorer I can see that the
file name is given, and it is the .zip file and not the name of the PHP
script file.

I have tried to print:

$response->as_string

...in order to see all the headers, but I cannot see any header that
contains the name of the file, however Internet Explorer knows the name of
that file.
I have seen that the zip file contains a .doc file and the name of the given
file by the browser is the name of the .doc file... something like:

file_name.doc.zip

I thought IE is able to look inside the .zip file and get the file name it
contains, but I have tried to create my own example, but I see that this is
not true, so it remains a mistery about how IE can get the file name.

Do you have any idea?

Thank you.

Teddy,
teddy.fcc.ro     [EMAIL PROTECTED]

Reply via email to