ID: 46978 Updated by: fel...@php.net Reported By: remy dot damour at laposte dot net -Status: Open +Status: Assigned Bug Type: XML Reader Operating System: ubuntu intrepid PHP Version: 5.2.8 -Assigned To: +Assigned To: rrichards
Previous Comments: ------------------------------------------------------------------------ [2008-12-30 21:04:30] remy dot damour at laposte dot net Description: ------------ Each time I call XMLReader::setRelaxNGSchema() or XMLReader::setRelaxNGSchemaSource() it ends up with an error message. My relax-ng content looks valid, it's succefully loaded and used for parsing xml with both xmllint (from package libxml2-utils) and sun-microsystem "msv" (https://msv.dev.java.net/) validator. Reproduce code: --------------- <?php $rng_schema = <<<RNG <?xml version="1.0"?> <grammar xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"> <start> <element name="node1"><text/></element> </start> </grammar> RNG; $xml_reader = new XMLReader(); $xml_reader->setRelaxNGSchemaSource($rng_schema); Expected result: ---------------- no error message Actual result: -------------- Warning: XMLReader::setRelaxNGSchemaSource() [xmlreader.setrelaxngschemasource]: Unable to set schema. This must be set prior to reading or schema contains errors. in /var/www/test.php on line 12 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=46978&edit=1