note 4020 deleted from function.header by jimw
| From: | jimw@php.net | Date: | Wed, 31 Oct 2001 21:13:40 +0000 |
| Subject: | note 4020 deleted from function.header by jimw | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-19727@lists.php.net to get a copy of this message | ||
When a visitor chooses a new page on your site by clicking on a link you have set up, the link will
include all the arguments required to identify what page to (create and) send. If the visitor uses
a form to choose a page, the form variables are passed via the post method and don't appear in
the "Location" header sent to the browser with the
requested page, so if the visitor bookmarks that page, the bookmark will lead back to your php3 file
with no arguments given.
Here's how to use the "Location:" header to send all the information that is needed
to enable the user to bookmark a particular page.
header ("Request-URI:
http://www.publicinfo.net/pic.php3?allvars=$allvars");
header ("Content-Location:
http://www.publicinfo.net/pic.php3?allvars=$allvars");
header ("Location:
http://www.publicinfo.net/pic.php3?allvars=$allvars");
If you send these headers in this order, it works! If you just send the "Location" header
or send it first, the browser gets a 301 Found!, which is worse than useless.