note 66479 added to function.xml-parse-into-struct

From: Date: Tue, 23 May 2006 22:26:05 +0000
Subject: note 66479 added to function.xml-parse-into-struct
Groups: php.notes 
Request: Send a blank email to php-notes+get-111905@lists.php.net to get a copy of this message
This is a great little function for a lot of XML work, but note that this function does not handle XML entities properly. The basic XML entities < > & " are fine, just anything else will not work: If the entity is defined in the XML header, the parser will drop it completely from the struct it creates. If the entity is not defined in the XML then the parser will crash out with an undefined entity error. You should be able to work around this limitation by using a preg_replace on your XML string before passing it to the parser. (Further details in Bug #35271; this is just a warning to those thinking of using this function for parsing real XML documents not just trivial XML examples) ---- Server IP: 84.18.202.180 Probable Submitter: 86.53.48.59 ---- X-Spam-Status: No, hits=3.1 required=5.0 tests=DATE_MISSING,FROM_NO_LOWER autolearn=no version=2.64 ---- Manual Page -- http://www.php.net/manual/en/function.xml-parse-into-struct.php Edit -- http://master.php.net/note/edit/66479 Del: integrated -- http://master.php.net/note/delete/66479/integrated Del: useless -- http://master.php.net/note/delete/66479/useless Del: bad code -- http://master.php.net/note/delete/66479/bad+code Del: spam -- http://master.php.net/note/delete/66479/spam Del: non-english -- http://master.php.net/note/delete/66479/non-english Del: in docs -- http://master.php.net/note/delete/66479/in+docs Del: other reasons-- http://master.php.net/note/delete/66479 Reject -- http://master.php.net/note/reject/66479 Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#111905) next »