]> git.sesse.net Git - xml-template/commitdiff
Add our own clone stuff when removing dummy elements, to avoid having PHP5
authorsgunderson@bigfoot.com <>
Sat, 26 Apr 2008 17:35:10 +0000 (19:35 +0200)
committersgunderson@bigfoot.com <>
Sat, 26 Apr 2008 17:35:10 +0000 (19:35 +0200)
add tons of spurious extra namespace declarations on us.

php5/xml-template.php

index 8e53452675bae110183ccc9c53ab09befc2d9a5d..46047ff8ff27730c09bdc5c91a4d91a6695b93e2 100644 (file)
@@ -139,7 +139,7 @@ function XML_Template_clean($node)
                while ($node->childNodes->length > 0) {
                        $child = $node->childNodes->item(0);
                        $node->removeChild($child);
-                       $parent->insertBefore($child, $node);
+                       $parent->insertBefore(own_clone_node($child, $doc), $node);
                }
                $parent->removeChild($node);
        }