- var_dump: documentation ( source)
- simplexml_load_string: documentation ( source)
<?php
$xml = "<root>
<PowerOn Description='Engine ON' DateTime='20150318_150553' />
<Ticket Amount='0' Payment='Cash' Description='PRINT REQUEST: OK!!!' DateTime='20150318_150555' />
<Return Amount='700' Payment='Cash' Description='REST PROVIDED' DateTime='20150318_150601' />
<Program id='19' Amount='1000' Payment='Cash' Description='Comfort XL 6pz' DateTime='20150318_203139' />
<Program id='20' Amount='600' Payment='Cash' Description='TOUCH & FEEL CONTROL X6' DateTime='20150318_225334' />
<Ticket Amount='0' Payment='Cash' Description='PRINT REQUEST: OK!!!' DateTime='20150318_225405' />
<Return Amount='1400' Payment='Cash' Description='REST PROVIDED' DateTime='20150318_225417' />
</root>";
$xml = simplexml_load_string( $xml);
var_dump($xml->children());
//foreach( $xml->xpath( './/child') as $child) {
// echo $child->attributes()['name'] . "\n";
//}