This question already has an answer here:
This link to an rss feed doesn't load with simplexml_load_file
.
The link is a valid RSS feed and no it isn't a permission problem everything else loads.
This question already has an answer here:
This link to an rss feed doesn't load with simplexml_load_file
.
The link is a valid RSS feed and no it isn't a permission problem everything else loads.
The rss feed is gziped. This should do the trick:
See PHP: Call to undefined function gzdecode() for further details regarding the gzinflate.
First of all you need to enable error logging and/or reporting to find out more. Also you can check some parameters from the return value and the remote request:
This will tell you that loading failed, the error messages tell you why it failed:
And the
$http_response_header
also show you the picture what has been returned from that host:According to the HTTP specs that you make use of by using a HTTP uri, the content encoding is:
This is not supported by PHP out of the box with it's HTTP Wrapper so you need to work around that your own
For example by using the zlib Stream Wrapper::
Or with the help of the
gzdecode
function:Full example code with all the variants:
Related Questions:
And the following PHP Bugreports are related (just picked some, this is likely not complete):