Mam skrypt:
<?php
$url = "http://www.tibia.com";
$page = file_get_contents($url);
echo $page;
?>
Po czym przy otwieraniu stronki wyświetlany zostaje błąd.
Warning: file_get_contents() [function.file-get-contents]: php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution in /home/a3639014/public_html/index.php on line 3
Nawet dwa:
Warning: file_get_contents([url]http://www.tibia.com[/url]) [function.file-get-contents]: failed to open stream: php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution in /home/a3639014/public_html/index.php on line 3
Gdy postawie to na webservie to wszystko jest OK. Jednak jeżeli na darmowym hostingu wywala mi te błędy.
Server hostujący ma php w wersji 5.2.6 oraz "allow_url_fopen" ustawione na ON. Dlatego nie mam pojęcia dlaczego ta funkcja nie działa.
Nie wiecie może dlaczego?