Manipulate Request Headers after Redirect
| From: | Louis Huppenbauer | Date: | Fri, 24 Jun 2011 07:04:58 +0000 |
| Subject: | Manipulate Request Headers after Redirect | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-313690@lists.php.net to get a copy of this message | ||
Hi there!
I just have a small question concerning the http-protocol and php (and
in specific the header-function, i think).
Is it possible to manipulate the headers for the request which is sent
after a 302-header?
eg:
Response:
header('Referer: example.com');
header('Location: example.net');
Request (for the 302):
header('Referer: example.net');
header('Cache: max-age=0);
I think I need that for a login to a tomcat app from an external
php-form. As of now the Login works fine, I just have to reload the
page to actually be logged in (and that is quite a bother).
Sincerely yours
Louis