views:

641

answers:

1

I need to retrieve an XML file from another domain I own from PHP.

I'm using simple_XML to do it but, apparently, cross-domain is disabled:

Warning: simplexml_load_file() [function.simplexml-load-file]: URL file-access is disabled in the server configuration

I have no access to server's config (shared hosting).

Any clue on how to perform this?

+3  A: 

Your host disabled it by setting allow_url_fopen in php.ini to off.

You may need to talk to them about having this enabled.

You can try using cURL to download the remote file then loading the string into SimpleXML instead of a remote file path.

Matt