3v4l.org

run code in 300+ PHP versions simultaneously
<?php $xml = '<?xml version="1.0" encoding="UTF-8"?> <translations> <translation id="title"> <english name="name1" ad="ad1">Hello there, how are you?</english> <italian name="name2" ad="ad2">Ciao, come stai?</italian> </translation> <translation id="text2"> <english name="name3" ad="ad4">222Hello there, how are you?</english> <italian name="name3" ad="ad4">222Ciao, come stai?</italian> </translation> <translation id="text3"> <english name="name5" ad="ad5">333Hello there, how are you?</english> <italian name="name6" ad="ad6">333Ciao, come stai?</italian> </translation> </translations>'; $xml = new SimpleXMLElement($xml); echo $xml->translations->translation[0]->english['ad']; echo $xml->translations->translation[0]->italian['name'];
Output for git.master, git.master_jit
Warning: Trying to access array offset on value of type null in /in/YLhlD on line 21 Warning: Attempt to read property "english" on null in /in/YLhlD on line 21 Warning: Trying to access array offset on value of type null in /in/YLhlD on line 21 Warning: Trying to access array offset on value of type null in /in/YLhlD on line 22 Warning: Attempt to read property "italian" on null in /in/YLhlD on line 22 Warning: Trying to access array offset on value of type null in /in/YLhlD on line 22
Output for rfc.property-hooks
Warning: Trying to access array offset on null in /in/YLhlD on line 21 Warning: Attempt to read property "english" on null in /in/YLhlD on line 21 Warning: Trying to access array offset on null in /in/YLhlD on line 21 Warning: Trying to access array offset on null in /in/YLhlD on line 22 Warning: Attempt to read property "italian" on null in /in/YLhlD on line 22 Warning: Trying to access array offset on null in /in/YLhlD on line 22

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:
42.58 ms | 402 KiB | 8 Q