-1

This code return an error500 and have no clue why

<?php

$url = "https://www.idownloadblog.com/tag/iphone/feed"; // url to parse
$rss = simplexml_load_file($url); // XML parser

// RSS items loop
echo $rss;

?>
Domien
  • 11
  • 5

1 Answers1

0

Becuase simplexml_load_file is to load a file not an URL

http://php.net/manual/en/function.simplexml-load-file.php

Vidal
  • 2,605
  • 2
  • 16
  • 32
  • No, that is actually not true. Most file loading functions in PHP can very well also load a document from an URL. And actually, that is clearly mentioned in the documentation you yourself linked... – arkascha Feb 23 '19 at 16:10