3v4l.org

run code in 300+ PHP versions simultaneously
<?php $xml = new SimpleXMLElement('<xml/>'); for ($i = 1; $i <= 8; ++$i) { $track = $xml->addChild('track'); $track->addChild('path', "song$i.mp3"); $track->addChild('title', "Track $i - Track Title"); } Header('Content-type: text/xml'); print($xml->asXML());

preferences:
32.3 ms | 402 KiB | 5 Q