php - file_get_contents() error -
i using file_get_contents on php , throws errors:
my code
#try fetch remote $this->remotepath = "http://some-hostname.com/blah/blah.xml $filein = @file_get_contents($this->remotepath);
the errors:
warning: file_get_contents() [function.file-get-contents]: url file-access disabled in server configuration in /virtual/path/to/file/outputfile.php on line 127 warning: file_get_contents(https://some-host-name/data/inputfile.xml) [function.file-get-contents]: failed open stream: no suitable wrapper found in /virtual/path/to/file/outputfile.php on line 127
any idea? worked fine in computer stopped working when ported web server.
your server must have allow_url_fopen
property set true. being on free webhost explains it, it's disabled prevent abuse. if paid hosting, in contact host can enable you.
if changing setting not option, have @ curl library.
Comments
Post a Comment