You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to this pull request, something's changed in PHP 5.5's XML handling. Come up with a unified/single-code-path approach for finding the the module version in both PHP 5.4 and PH 5.5.
The text was updated successfully, but these errors were encountered:
I've created a small test-script that shows you (well at least me) what's wrong:
<?php
$xmlString = <<<EOF
<config>
<modules>
<Mage_Test>
<version>test</version>
</Mage_Test>
</modules>
</config>
EOF;
$xml = simplexml_load_string($xmlString);
$test = (array)$xml->xpath('//modules');
print_r($test); // Should print array with version "test" present
$test = $xml->xpath('//Mage_Test');
print_r($test); // Should print array with version "test" present
$test = $xml->xpath('//version');
print_r($test); // Preduces empty array in my case
Fetching //version gives wrong output. If I add in another level, the //version works again (but ofcourse this is pointless in Magento):
<version><span>test</span></version>
So it looks to me like it has nothing to do with the number of levels, but simply with the fact that if the element you're trying to match (version) is the last node without children, it is not found.
According to this pull request, something's changed in PHP 5.5's XML handling. Come up with a unified/single-code-path approach for finding the the module version in both PHP 5.4 and PH 5.5.
The text was updated successfully, but these errors were encountered: