ID: 42141
Updated by: [EMAIL PROTECTED]
Reported By: linus dot martensson at elplan-gm dot se
-Status: Open
+Status: Wont fix
Bug Type: Feature/Change Request
PHP Version: 5.2.3
New Comment:
XML is case-sensitive... you'll just have to deal with this in your
scripts.
Previous Comments:
------------------------------------------------------------------------
[2007-07-29 16:08:51] linus dot martensson at elplan-gm dot se
Description:
------------
DOMNamedNodeMap->getNamedItem() is case-sensitive, the ability to
change this would be useful in templating systems. Add a second
parameter for case-sensitive?
Reproduce code:
---------------
$xml = new DOMDocument();
$xml->loadXML('<html><head><!--yadayada--></head><body><div
Id="testid"></div></body></html>');
$element = $xml->getElementById('testid');
echo $element->attributes->getNamedItem('id');
Expected result:
----------------
should echo "testid", the name of the element retrieved.
Actual result:
--------------
Echoes nothing, as the 'Id' in the xml is spelt with a capital I.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=42141&edit=1