note 39570 added to function.header
| From: | php at n0spm dot bradquinn dot com | Date: | Mon, 02 Feb 2004 22:07:42 +0000 |
| Subject: | note 39570 added to function.header | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-64566@lists.php.net to get a copy of this message | ||
Another solution for getting the browser to use the right filename for saving is to use mod_rewrite
to hide the fact that you are using a script at all.
Either in the httpd.conf or a .htaccess file, include something like the following:
RewriteEngine On
RewriteRule ^/downloads/(.*) /getFile.php?filename=$1 [NE]
mod_rewrite will translate the url, and the browser (and the user) won't know the difference.
----
Manual Page -- http://www.php.net/manual/en/function.header.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+39570
Delete -- http://master.php.net/manage/user-notes.php?action=delete+39570&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+39570&report=yes
Search -- http://master.php.net/manage/user-notes.php