Home » XML » XML_Beautifier » Bug #1233
Empty tags replaced by single tag
Details
| Submitted | 2004-04-17 18:48 UTC |
|---|---|
| From | guillaume dot lecanu at online dot fr |
| Assigned | schst |
| Status | Wont fix |
| Package | XML_Beautifier |
| PHP Version | 4.3.4 |
| OS | Debian Sid |
| Roadmaps | (Not assigned) |
Comments
[2004-04-17 18:48 UTC] guillaume dot lecanu at online dot fr
Description:
------------
The empty tags are replaced by single tag :
<span></span>
to
<span />
Reproduce code:
---------------
<?php
include_once 'XML/Beautifier.php';
$xml = '<?xml version="1.0" encoding="UTF-8" standalone="no"?>'
.'<example></example>';
$fmt = new XML_Beautifier();
$out =& $fmt->formatString($xml);
print "<br />Original XML : <br />".htmlSpecialChars($xml);
print "<br />Formatted XML : <br />".htmlSpecialChars($out);
?>
Expected result:
----------------
Original XML :
<?xml version="1.0" encoding="UTF-8" standalone="no"?><example></example>
Formatted XML :
<?xml version="1.0" encoding="UTF-8" standalone="no"?><example></example>
Actual result:
--------------
Original XML :
<?xml version="1.0" encoding="UTF-8" standalone="no"?><example></example>
Formatted XML :
<?xml version="1.0" encoding="UTF-8" standalone="yes"?><example />
[2004-04-30 07:15 UTC] unknown_delivery at yahoo dot com
You need to replace output as html.