summaryrefslogtreecommitdiff
path: root/tests/testdom
diff options
context:
space:
mode:
authorUwe Steinmann <steinm@php.net>2000-03-02 16:39:50 +0000
committerUwe Steinmann <steinm@php.net>2000-03-02 16:39:50 +0000
commitad311c35c75f1f99ab6b505e01fc1305dae05ae3 (patch)
treeaff886fbd41c755551ad9966bf091dc21286bcea /tests/testdom
parent74fba75ca0dd75fc8103299729cef35dcc66dbf3 (diff)
downloadphp-git-ad311c35c75f1f99ab6b505e01fc1305dae05ae3.tar.gz
- The root node of a xml doc is now an array since it is possible
to have a comment or pi and an element on root level.
Diffstat (limited to 'tests/testdom')
-rw-r--r--tests/testdom5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/testdom b/tests/testdom
index 53aa75c657..2c64f3de6c 100644
--- a/tests/testdom
+++ b/tests/testdom
@@ -74,12 +74,13 @@ if(!$dom = xmldoc($xmlstr)) {
echo "XML Version: ".$dom->version."\n";
$dtd = $dom->dtd();
$rootnode = $dom->root();
-output_node($rootnode);
+foreach($rootnode as $root)
+ output_node($root);
/* This one creates a dom tree made of php objects */
echo "Test 2: creating a tree with php objects\n";
$dom = xmltree($xmlstr);
-$dom->root->name = "section";
+//$dom->root->name = "section";
var_dump($dom);
echo $dom->root->name;
echo "\n";