Mateobus Posted September 11, 2006 Share Posted September 11, 2006 Is there a way to save an outside web page with PHP. For example, http://www.randomsite.com/randomfile.html. And then parse through that file Link to comment https://forums.phpfreaks.com/topic/20431-save-a-web-page/ Share on other sites More sharing options...
HuggieBear Posted September 11, 2006 Share Posted September 11, 2006 Yes, it's possible and not too difficult, I use it to read share prices from Reuters.Look at the fopen() function in the PHP manual.RegardsRich Link to comment https://forums.phpfreaks.com/topic/20431-save-a-web-page/#findComment-90104 Share on other sites More sharing options...
Mateobus Posted September 12, 2006 Author Share Posted September 12, 2006 I can't use the fopen, because i don't have permission because the file isn't on my server. I get this error:Permission denied Link to comment https://forums.phpfreaks.com/topic/20431-save-a-web-page/#findComment-90126 Share on other sites More sharing options...
gijew Posted September 12, 2006 Share Posted September 12, 2006 Try file_get_contents()[url=http://us2.php.net/manual/en/function.file-get-contents.php]http://us2.php.net/manual/en/function.file-get-contents.php[/url]I should note you still need to use fopen to access it. It's in the manual there but I just thought to add that bit of info. Link to comment https://forums.phpfreaks.com/topic/20431-save-a-web-page/#findComment-90127 Share on other sites More sharing options...
Mateobus Posted September 12, 2006 Author Share Posted September 12, 2006 same permission error Link to comment https://forums.phpfreaks.com/topic/20431-save-a-web-page/#findComment-90142 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.