|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2011-06-01 22:09 UTC] dtajchreber@php.net
-Status: Open
+Status: Bogus
[2011-06-01 22:09 UTC] dtajchreber@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 04 19:00:02 2025 UTC |
Description: ------------ hi, $doc = new \DOMDocument("1.0","UTF-8"); $doc->formatOutput = true; $doc->appendChild($root = $doc->createElement("root")); $root->appendChild($doc->createElement("sub")); $root->appendChild($doc->createElement("sub")); $root->appendChild($doc->createElement("sub")); // uncomment one or both following line(s): //$root->appendChild($doc->createTextNode("text")); //$root->appendChild($doc->createCDATASection("text")); $root->appendChild($doc->createElement("sub")); $root->appendChild($doc->createElement("sub")); echo "<xmp>"; echo $doc->saveXML(); echo "</xmp>";