3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $res = ' <rsp stat="fail" version="1.0"> <err code="1" msg="Invalid API key or user key"/> </rsp> '; $ret = simplexml_load_string($res); print_r($ret->err[0]->@attributes);
Output for 5.4.0 - 5.4.20
Parse error: syntax error, unexpected '@', expecting identifier (T_STRING) or variable (T_VARIABLE) or '{' or '$' in /in/IjO7c on line 9
Process exited with code 255.
Output for 5.3.0 - 5.3.27
Parse error: syntax error, unexpected '@', expecting T_STRING or T_VARIABLE or '{' or '$' in /in/IjO7c on line 9
Process exited with code 255.