#43643 [Opn]: XMLReader::isValid returns false always

From: Date: Thu, 20 Dec 2007 16:04:39 +0000
Subject: #43643 [Opn]: XMLReader::isValid returns false always
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-120779@lists.php.net to get a copy of this message
ID: 43643 Updated by: felipe@php.net Reported By: arkadiusz dot tulodziecki at firma dot o2 dot pl Status: Open Bug Type: XML Reader Operating System: Linux PHP Version: 5.2.5 New Comment: Use: $reader->setParserProperty(XMLReader::VALIDATE, true); Previous Comments: ------------------------------------------------------------------------ [2007-12-20 15:34:47] arkadiusz dot tulodziecki at firma dot o2 dot pl Description: ------------ XMLReader::isValid gives false for all valid XML I had. All files parses correctly but sometimes XMLReader::read generates PHP Worning. Reproduce code: --------------- <?php $reader = new XMLReader(); $reader->open('test.xml'); var_dump($reader->isValid()); ?> <?xml version="1.0" encoding="utf-8" ?> <ads version="1.0.6" xmlns="http://www.example.com/xmlns/1.0/"> <ad offer_date="2007-08-21 21:21:00" offer_code="0" offer_type="0"> AAA </ad> </ads> Expected result: ---------------- bool(true) Actual result: -------------- bool(false) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=43643&edit=1

« previous php.bugs (#120779) next »