<?
/*
Author : Martin Fasani [ www.movil.be ]
lastMod: 20050701 [YYYYMMDD]
EXAMPLE of reading headers.
*/
require("classhttpreq.php");
$req3 = new httpreq('req3');
$req3->getheader='ALL'; //ALL or name e.g. "Last-Modified"
$req3->httpdorequest('HEAD','http://microsoft.com');
$req3->httpfireonload();
$req3->httpcreate();
$req4 = new httpreq('req4');
$req4->getheader='ALL'; //ALL or name e.g. "Last-Modified"
$req4->httpdorequest('HEAD','proxyhead.php?url=http://microsoft.com');
$req4->httpcreate();
?>
<div id='req3' style='overflow: auto; width:100%; height: 180px;border:1px solid'></div>
<a href=javascript:httpdoreq3() >httpdoreq3() Note this is without using proxy, will give a JS alert (because you are requesting other domain)</a>
<div id='req4' style='overflow: auto; width:100%; height: 180px;border:1px solid'></div>
<a href=javascript:httpdoreq4() >httpdoreq4()</a>
|