cvs: php-src /ext/simplexml/tests 023.phpt

From: Date: Sun, 23 Oct 2005 23:25:49 +0000
Subject: cvs: php-src /ext/simplexml/tests 023.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-34745@lists.php.net to get a copy of this message
helly Sun Oct 23 19:25:49 2005 EDT Added files: /php-src/ext/simplexml/tests 023.phpt Log: - Add new test http://cvs.php.net/co.php/php-src/ext/simplexml/tests/023.phpt?r=1.1&p=1 Index: php-src/ext/simplexml/tests/023.phpt +++ php-src/ext/simplexml/tests/023.phpt --TEST-- SimpleXML: Attributes with entities --SKIPIF-- <?php if (!extension_loaded("simplexml")) print "skip"; ?> --FILE-- <?php $xml =<<<EOF <?xml version='1.0'?> <!DOCTYPE talks SYSTEM "nbsp.dtd" [ <!ELEMENT root EMPTY> <!ATTLIST root attr1 CDATA #IMPLIED> <!ENTITY nbsp "&#38;#x00A0;"> ]> <root attr='foo&nbsp;bar&nbsp;baz'></root> EOF; $sxe = simplexml_load_string($xml); var_dump($sxe); var_dump($sxe['attr']); ?> ===DONE=== --EXPECTF-- object(SimpleXMLElement)#1 (1) { ["attr"]=> string(%d) "foo%sbar%sbaz" } object(SimpleXMLElement)#2 (1) { [0]=> string(%d) "foo%sbar%sbaz" } ===DONE===

« previous php.cvs (#34745) next »