View Full Version : viewing header information
Jacobb123
12-13-2007, 11:51 PM
How can view the header information sent by a web page. is it possible? I want to see what header information is sent not by my website but one that I visit.
with php?
You'd need some kind of HTTP client, the Zend Framework one is as good as any:
reqire 'Zend/Http/Client.php';
$client = new Zend_Http_Client('http://google.com');
$response = $client->request();
foreach($response->getHeaders() as $key => $val) {
echo $key.':'.$val."\n";
}
http://framework.zend.com/manual/en/zend.http.html
If you just want to see them, then a firefox plugin like Firebug or Tamperdata will show you them.
aWishResigned
12-14-2007, 02:28 PM
If you have FireFox, download Firebug (https://addons.mozilla.org/en-US/firefox/addon/1843). It will display all header information for a page along with javascript errors and so on.
If you don't have FireFox, I strongly suggest you try it out.
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.