Forum Moderators: coopster

Message Too Old, No Replies

Getting headers sent by the user's browser in php?

I want the type of information you get from the ieHTTPheaders extension...

         

rollinj

7:29 am on Dec 20, 2009 (gmt 0)

10+ Year Member



If you'll search the following string on Google or your favorite search engine (with quotes!), you'll find an example of what I'm looking for.

"HTTP headers supplied by your browser"

The above search query returns a page that lists all of the headers sent by your browser (whatever it may be) to the page...

I can find plenty of php variables detailing server side headers, but how do I access the client's headers..? They're sending them to me, so I don't see it being that difficult!

ALKateb

1:26 pm on Dec 20, 2009 (gmt 0)

10+ Year Member



is this what you meant?

echo "<pre>";
print_r( apache_request_headers() );
echo "</pre>";

rollinj

12:49 am on Dec 22, 2009 (gmt 0)

10+ Year Member



That's it! Thank you!

Feeling pretty dumb now... as I'm sure I had crossed that function before, but was confused as there was no mention of "browser" at all in the function name, rather the server...! Thanks :)