From: info at gmwconsult dot nl
Operating system: windows
PHP version: 5.4Git-2014-06-19 (snap)
Package: DOM XML related
Bug Type: Bug
Bug description:empty node is filled with sibling
Description:
------------
if I load a snippet of html with loadXML() and subsequently echo the
contents, the first empty node is filled with the next node. This does
not happen if the first node contains   or another empty node.
So the result will be:
<div>
<nav id="filter" >
<section id="portfolio_container">
<ul id="stage">
</ul>
</section>
</nav>
</div>
php 5.4.19 that comes with xampp running on windows
Test script:
---------------
$html = '<div>
<nav id="filter" />
<section id="portfolio_container">
<ul id="stage">
</ul>
</section>
</div>';
$doc = new DOMDocument('1.0','utf8');
$doc->loadXML($html);
echo"<pre>";
print_r($doc->saveXML());
echo"</pre>";
die();
--
Edit bug report at https://bugs.php.net/bug.php?id=67476&edit=1
--