3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $xml = "<?xml version='1.0' encoding='utf-8'?><merchant><merchantID>33abc947-f7d5-45f7-9b99-6825b72b74db</merchantID></merchant> <transaction><merchantTransactionID>123456</merchantTransactionID><method>boleto</method><customerName>João Silva</customerName><CPF>36874950860</CPF><currency>BRL</currency><value>10000</value></transaction>"; $ler = simplexml_load_string($xml); echo 'teste<br>'; echo $ler->merchantID; ?>
Output for 5.1.0 - 5.6.28, 7.0.0 - 7.1.0
Warning: simplexml_load_string(): Entity: line 2: parser error : Extra content at the end of the document in /in/2LQD4 on line 6 Warning: simplexml_load_string(): <transaction><merchantTransactionID>123456</merchantTransactionID><method>boleto in /in/2LQD4 on line 6 Warning: simplexml_load_string(): ^ in /in/2LQD4 on line 6 teste<br> Notice: Trying to get property of non-object in /in/2LQD4 on line 10
Output for hhvm-3.12.0
teste<br> Notice: Cannot access property on non-object in /in/2LQD4 on line 10 Entity: line 2: parser error : Extra content at the end of the document <transaction><merchantTransactionID>123456</merchantTransactionID><method>boleto ^
Output for hhvm-3.10.0

Process exited with code 153.
Output for 5.0.0 - 5.0.5
Warning: Entity: line 2: parser error : Extra content at the end of the document in /in/2LQD4 on line 6 Warning: <transaction><merchantTransactionID>123456</merchantTransactionID><method>boleto in /in/2LQD4 on line 6 Warning: ^ in /in/2LQD4 on line 6 teste<br> Notice: Trying to get property of non-object in /in/2LQD4 on line 10
Output for 4.4.5 - 4.4.9
Fatal error: Call to undefined function: simplexml_load_string() in /in/2LQD4 on line 6
Process exited with code 255.
Output for 4.3.2 - 4.4.4
Fatal error: Call to undefined function: simplexml_load_string() in /in/2LQD4 on line 6
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Call to undefined function: simplexml_load_string() in /in/2LQD4 on line 6