3v4l.org

run code in 300+ PHP versions simultaneously
<?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 = new DOMDocument(); $ler->load($xml); $merchant = $ler.getElementsByTagName('merchant'); $merchantID = $merchant->getElementsByTagName('merchantID')->item(0)->nodeValue; echo 'teste<br>'; echo $merchantID; ?>
Output for git.master, git.master_jit, rfc.property-hooks
Warning: DOMDocument::load(): I/O warning : failed to load external entity "/<?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>" in /in/JpDGB on line 6 Fatal error: Uncaught Error: Call to undefined function getElementsByTagName() in /in/JpDGB:8 Stack trace: #0 {main} thrown in /in/JpDGB on line 8
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
40.11 ms | 402 KiB | 8 Q