shagey36 Posted April 30, 2010 Share Posted April 30, 2010 I want to grab the html from a wiki article so I was planning on using file_get_contents to do that but whenever I do it I get some really weird stuff returned to me. Here is the code: <?php $output = file_get_contents('http://en.wikipedia.org/wiki/List_of_PlayStation_3_games'); echo $output; ?> anybody have any ideas? Quote Link to comment https://forums.phpfreaks.com/topic/200301-wiki-and-file_get_contents-help/ Share on other sites More sharing options...
Ken2k7 Posted April 30, 2010 Share Posted April 30, 2010 What really weird stuff? Quote Link to comment https://forums.phpfreaks.com/topic/200301-wiki-and-file_get_contents-help/#findComment-1051185 Share on other sites More sharing options...
947740 Posted April 30, 2010 Share Posted April 30, 2010 I just ran the code on my web-server...and I got absolutely nothing...until I enabled errors! Warning: file_get_contents(http://en.wikipedia.org/wiki/List_of_PlayStation_3_games): failed to open stream: HTTP request failed! HTTP/1.0 403 Forbidden in E:\FM\temp.php on line 7 Is that what you got, shagey36? Quote Link to comment https://forums.phpfreaks.com/topic/200301-wiki-and-file_get_contents-help/#findComment-1051193 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.