PrepAway - Latest Free Exam Questions & Answers

Which of the following functions will you use instead of * if you want to print the root element of the XML fi

You run the following PHP script:
<?php
include(“xml.inc”);
if (!$dom = domxml_open_mem($xmlstr)) {
echo “Error while parsing the XML document\n”;
exit;
}
$a = **********
print_r($a);
?>
Which of the following functions will you use instead of * if you want to print the root element of the
XML file?

PrepAway - Latest Free Exam Questions & Answers

A.
$node->parent_node();

B.
$dom->document_element();

C.
$dom->root_node();

D.
$dom->root_element();

Explanation:

One Comment on “Which of the following functions will you use instead of * if you want to print the root element of the XML fi


Leave a Reply

Your email address will not be published. Required fields are marked *