From:             bugz at nagash dot org
Operating system: windows
PHP version:      5.0.0
PHP Bug Type:     DOM XML related
Bug description:  unexpected result - $dom->saveXML()

Description:
------------
result is unexpected

Reproduce code:
---------------
$doc = new DOMDocument("1.0");
$root = $doc->createElement("HTML");
$root = $doc->appendChild($root);
$head = $doc->createElement("HEAD");
$head = $root->appendChild($head);
$title = $doc->createElement("TITLE");
$title = $head->appendChild($title);
$text = $doc->createTextNode("This is the title");
$text = $title->appendChild($text);
echo $doc->saveXML();

Expected result:
----------------
<?xml version="1.0"?>
<HTML>
  <HEAD>
    <TITLE>
      This is the title
    </TITLE>
  </HEAD>
</HTML>


Actual result:
--------------
<?xml version="1.0"?>
<HTML />

-- 
Edit bug report at http://bugs.php.net/?id=29386&edit=1
-- 
Try a CVS snapshot (php4):  http://bugs.php.net/fix.php?id=29386&r=trysnapshot4
Try a CVS snapshot (php5):  http://bugs.php.net/fix.php?id=29386&r=trysnapshot5
Fixed in CVS:               http://bugs.php.net/fix.php?id=29386&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=29386&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=29386&r=needtrace
Need Reproduce Script:      http://bugs.php.net/fix.php?id=29386&r=needscript
Try newer version:          http://bugs.php.net/fix.php?id=29386&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=29386&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=29386&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=29386&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=29386&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=29386&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=29386&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=29386&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=29386&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=29386&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=29386&r=float

Reply via email to