1--TEST--
2DOMDocument::saveHTML() should dump the internal document into a string using HTML formatting
3--CREDITS--
4Knut Urdalen <knut@php.net>
5#PHPTestFest2009 Norway 2009-06-09 \o/
6--SKIPIF--
7<?php
8require_once dirname(__FILE__) .'/skipif.inc';
9?>
10--FILE--
11<?php
12$doc = new DOMDocument('1.0');
13$root = $doc->createElement('html');
14$root = $doc->appendChild($root);
15$head = $doc->createElement('head');
16$head = $root->appendChild($head);
17$title = $doc->createElement('title');
18$title = $head->appendChild($title);
19$text = $doc->createTextNode('This is the title');
20$text = $title->appendChild($text);
21echo $doc->saveHTML();
22?>
23--EXPECTF--
24<html><head><title>This is the title</title></head></html>
25