]> git.sesse.net Git - xml-template/blobdiff - php5/xml-template.php
Improve the HTML-entity-magic a bit for PHP5.
[xml-template] / php5 / xml-template.php
index 46047ff8ff27730c09bdc5c91a4d91a6695b93e2..b28db156ebf2cf6e6ffe1f637a3b579a299e7df8 100644 (file)
@@ -209,7 +209,7 @@ function own_clone_element($node, $doc)
                        }
 
                        # You've got to be kidding me...
-                       $attr2->value = htmlentities($attr->value);
+                       $attr2->value = preg_replace("/&/", "&", $attr->value);
                        $newnode->appendChild($attr2);
                }
        }