This seems like a small problem that I have read from 
  I have the code snippet here as follows:

$xml = XMLReader::open('hello.xml');

// You must to use it
$xml->setParserProperty(XMLReader::VALIDATE, true);

if ($xml->isValid()) echo "true";
else echo "NOT";


Here is the contents of hello.xml:


Obviously, this is not a well formed XML file. 

However, whenever I run the PHP code, it returns true, how do I get it to 
validate it the way it is supposed to be? 

Thanks for your help. 


Search from any Web page with powerful protection. Get the FREE Windows Live 
Toolbar Today!

Reply via email to