#17540 [Opn->Fbk]: CDATA incorrect for non block elements
| From: | iliaa@php.net | Date: | Mon, 25 Nov 2002 05:30:40 +0000 |
| Subject: | #17540 [Opn->Fbk]: CDATA incorrect for non block elements | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-25759@lists.php.net to get a copy of this message | ||
ID: 17540
Updated by: iliaa@php.net
Reported By: tim@zero-interactive.com
-Status: Open
+Status: Feedback
Bug Type: XML related
Operating System: Win 2K Pro
PHP Version: 4.2.1
New Comment:
Please try using this CVS snapshot:
http://snaps.php.net/php4-latest.tar.gz
For Windows:
http://snaps.php.net/win32/php4-win32-latest.zip
Previous Comments:
------------------------------------------------------------------------
[2002-05-31 02:08:23] tim@zero-interactive.com
Running PHP 4.2.1 with Apache 2.0.36 on Windows 2000 Profrofessional.
PHP is running as an Apache module.
XML extension enabled
XSLT extension enabled
For some reason when parsing documents that like:
<doc>
<para>Some text <test /> rest of para text</para>
</doc>
The CDATA that is returned through the xml_set_character_data_handler
seems to return the rest of the para CDATA instead of nothing.
After the data handler has been called, then it calls the element
handler to close the <test/> tag.
An easy way to test is to keep track of the current tag that the parser
is on (by setting it in the open element handler) and then running
strlen over the CDATA has it hits the test tag.
Logically it should close the tag, then process the CDATA or at least
return blank CDATA for the test tag.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=17540&edit=1