note 18827 rejected from function.domxml-new-child by didou
| From: | didou@php.net | Date: | Sun, 05 Oct 2003 18:48:55 +0000 |
| Subject: | note 18827 rejected from function.domxml-new-child by didou | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-57854@lists.php.net to get a copy of this message | ||
Note Submitter: ken@positive-edge.com
----
There is a *large* bug in the the new_child() method!
for instance, if i try to add a new node with content containing an entity like this, it will
convert the entity to the original character.
$bugItemNode->new_child( 'title', 'HtmlTagContainer's add() method does
not accept strings as an argument.' );
But when you use $doc->dumpmem(), the output will be the following:
...<title>HtmlTagContainer's add() method does not accept strings as an
argument.</title>
Notice that it contains an apostrophe and it is NOT '. This is a huge bug since it does
not output wellformed XML files.
Obviously, if you simply write the apostrophe character, it will do nothing to convert it to
' as well. This is serious and will hindle MANY applications. Developers, please fix
this.