Hey, that's probably what I've been looking for!
As for the mime type, I just read that there is a variable in recent
versions of PHP, $userfile_type, that may get sent up by the uploading
browser. I'll store that if availabe to give the user's browser the same
hint.
Thanks
--Louis <louis@bertrandtech.on.ca>
Louis Bertrand http://www.bertrandtech.on.ca/
Bertrand Technical Services, Bowmanville, ON, Canada
Tel: +1.905.623.1500 Fax: +1.905.623.3852
OpenBSD: Secure by default. http://www.openbsd.org/
On Sun, 7 Jan 2001, Stephen van Egmond wrote:
> Louis Bertrand (louis@bertrandtech.on.ca) wrote:
> > What headers can I send to fill in that file name?
>
> Look at content-disposition in the HTTP RFC.
>
> I do this in a similar application:
> header("Content-Disposition: attachment; filename=\"$original_name\"");
>
> it helps on the end-user side if you also report the correct
> MIME type for the document (i.e. application/msword).
>
> header("Content-type: $mime");
>
>