Thanks for your response, but I don't think that will do. First - SERVER_PORT is the port the apache/iis/whatever server is working with (usually 80 or 443) Second - That would still be manipulating the headers for the response (As php mostly just generates the response, and not the request). I'm thinking more and more that this is not really a php-question (as it is server-side), but more of a js-question (client-side). thanks anyway! louis 2011/6/24 <admin@xxxxxxxxxxxxxxxxxxx>: > Try > > > If($_SERVER['SERVER_PORT'] == "302") > { > header('Referer: example.net'); > } > > > Richard L. Buskirk > > -----Original Message----- > From: Louis Huppenbauer [mailto:louis.huppenbauer@xxxxxxxxx] > Sent: Friday, June 24, 2011 3:05 AM > To: php-general@xxxxxxxxxxxxx > Subject: Manipulate Request Headers after Redirect > > 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 > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php