1 2 3 4 5 6 7 8 9 10 11 12 13 14
| $ua = 'Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.8.0.4) Gecko/20060508 Firefox/1.5.0.4';
$header = array('Accept-Language: fr,fr-fr;q=0.8,en-us;q=0.5,en;q=0.3');
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, 'http://spaces.msn.com/morespaces.aspx');
curl_setopt($ch, CURLOPT_HEADER, 1);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_USERAGENT, $ua);
curl_setopt($ch, CURLOPT_HTTPHEADER, $header);
$reponse = curl_exec($ch);
curl_close($ch);
echo $reponse; |