PrepAway - Latest Free Exam Questions & Answers

What will be the output of the following PHP script?

What will be the output of the following PHP script?

<code>
<?php include(“xml.inc”);
if (!$dom = domxml_open_mem($xmlstr)) {
echo “Error while parsing the XML document \n”;
exit;
}
$a = $dom->document_element();
print_r($a);
?>
</code>

PrepAway - Latest Free Exam Questions & Answers

A.
It will display the root element of the XML file.

B.
It will display the XML code of the XML file.

C.
It will throw an error.

D.
It will display the contents of the XML file.


Leave a Reply

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