3v4l.org

run code in 300+ PHP versions simultaneously
<?php $xml = <<<XML <?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE foo [ <!ELEMENT foo ANY > <!ENTITY xxe SYSTEM "http://ss23.geek.nz/viper-test.txt" > ]> <foo>&xxe;</foo> XML; $x = new DOMDocument(); $x->loadXML($xml); foreach ($x->getElementsByTagName('foo') as $u) { var_dump($u->nodeValue); }

preferences:
41.16 ms | 402 KiB | 5 Q