#30275 [Opn->Bgs]: Erroneous 'Undeclared entity' error
| From: | rrichards@php.net | Date: | Fri, 12 Nov 2004 11:42:31 +0000 |
| Subject: | #30275 [Opn->Bgs]: Erroneous 'Undeclared entity' error | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-68982@lists.php.net to get a copy of this message | ||
ID: 30275
Updated by: rrichards@php.net
Reported By: michiel at trendserver dot nl
-Status: Open
+Status: Bogus
Bug Type: XML related
Operating System: Debian
PHP Version: 5.0.2
New Comment:
Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same.
Thank you for your interest in PHP.
See Bug #30219
Previous Comments:
------------------------------------------------------------------------
[2004-11-05 14:42:46] joern_h at gmx dot net
I modified the example to call the xml handlers, PHP 5.0.2 on Windows
2000 calls the external_entity_ref_handler for the declaration of the
entity, this does not happen with 4.3.8
------------------------------------------------------------------------
[2004-10-12 20:09:51] apocalypsys dot NOSP at M dot ukr dot net
1)
OS: Windows XP SP1
PHP: 4.3.7, 4.3.2
Error: External entity reference works perfect, but internal reference
- don't. I simply get a space instead of text of my entity.
2)
OS: Windows XP SP1
PHP: 5.0.2
Error: "Undeclared entity error".
------------------------------------------------------------------------
[2004-09-29 14:54:42] michiel at trendserver dot nl
Also occurs using
http://snaps.php.net/win32/php5-win32-200409291030.zip
------------------------------------------------------------------------
[2004-09-29 14:41:17] michiel at trendserver dot nl
Description:
------------
The XML extension in PHP5(.02) seems to fail on the use entities that
are declared in the same XML file.
Reproduce code:
---------------
<?
$xml = <<<HERE
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE test [
<!ENTITY uuml "ü">
]>
<test>ü</test>
HERE;
$parser = xml_parser_create();
if (!xml_parse($parser, $xml))
{
echo xml_error_string(xml_get_error_code($parser)) . "\n";
}
xml_parser_free($parser);
?>
Expected result:
----------------
No errors.
Actual result:
--------------
Undeclared entity error.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=30275&edit=1