Don't rely on print_r
or var_dump
when it comes to SimpleXml
, rather do:
foreach ($ln as $l)
echo htmlentities($l->asXML());
With this method, the result with 5.3.10 vs. 5.4.9 is the same:
<title>Lectio 1, Prologus</title>
PHP 5.3.10: see http://codepad.viper-7.com/RL8L0i
PHP 5.4.9: see http://codepad.viper-7.com/0JgAmQ