Web
simple html dom with proxy - example
06/03/2012
An example to use the 'simple html dom' class passing through a Proxy Server.
//CODE START
include('./parsehtml/simple_html_dom.php');
$myurl = 'http://www. your url to grab .com';
$aContext = array(
'http' => array(
'proxy' => 'tcp://proxy.yournet.it:3128',
'request_fulluri' => true,
),
);
$cxContext = stream_context_create($aContext);
$html = file_get_html($myurl,'',$cxContext);
//END CODE