Bonjour,

Voila j'ai le code suivant :

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
 
<?php 
ini_set('user_agent','Mozilla: (compatible; Windows XP)');
 
$url = "http://myplanetside.station.sony.com/index.jsp";
$fd = fopen ($url, "rb"); 
 
while (!feof ($fd)) {   
 $data = fgets($fd, 4096);    
 echo $data;  
} 
 
fclose ($fd);
?>

et voila mon erreur :

#
Warning: file_get_contents() [function.file-get-contents]: php_network_getaddresses: getaddrinfo failed: Hôte inconnu. in C:\wamp\www\Tests2\filecontent.php on line 3

Warning: file_get_contents(http://www.guerrilladns.com/) [function.file-get-contents]: failed to open stream: php_network_getaddresses: getaddrinfo failed: Hôte inconnu. in C:\wamp\www\Tests2\filecontent.php on line 3

Notice: Undefined offset: 0 in C:\wamp\www\Tests2\filecontent.php on line 5


Je ne comprend pas d'ou cela peut venir :S si vous pouviez m'éclairer cela serait super ! :p

pourtan j'ai bien le allow_url_fopen = On dans mon php.ini

Merci beaucoup d'avance !