file_get_contents(); from external URL not working

file_get_contents(); from external URL not working

Posted by: zylox
Posted on: 2007-02-27 05:33:00

Hi!

I've recently installed a script on my account which fetches the contents of an xml file from an external url (yahoo weather), but the script only creates empty files.
Is the functions somehow disabled on DH? Or at least the ability to connect to outside urls?
The script works on my VPS and on my business hosting account which I've got with another host.

I'm using PHP 5.1.2 for my Domain here at DH.


Any help would be appreciated. Thanks!

Re: file_get_contents(); from external URL not wor

Posted by: weslei
Posted on: 2007-02-27 05:43:00

Take a look in the 'how to remedy it' here:

http://forum.dreamhosters.com/programming/27459-PHP5-and-file_get_contentsurl.htm

Good luck.

Re: file_get_contents(); from external URL not wor

Posted by: zylox
Posted on: 2007-02-27 05:50:00

Thanks for the pointer! I'll look into curl!


Tags: external urldhxml filescript worksphp 5vpsurlsappreciated