RE: [PHP-DEV] Problem with XSLT Sablotron -> Bug ?

From: Date: Mon, 14 Oct 2002 21:12:25 +0000
Subject: RE: [PHP-DEV] Problem with XSLT Sablotron -> Bug ?
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-89457@lists.php.net to get a copy of this message
does this work from the sablotron command line? you should be able to run sabcmd test.xslt test.xml and see the correct output. If this fails, then the problem has nothing to do with PHP. If this succeeds, then the error lies with the php extension. I'm cc-ing sab-php list which has assumed ownership of PHP's xslt extension. We should remove php-dev from this list for the time being. dave -----Original Message----- From: Dirk Schwier [mailto:caseopeia195@compuserve.de] Sent: Monday, October 14, 2002 1:24 PM To: php-dev@lists.php.net Subject: [PHP-DEV] Problem with XSLT Sablotron -> Bug ? Hy NG, I get under some circumstances an Sablotron Error: "XML parser error 3: no element found" - this Error occurs only, when I put a lot of Text into an CDATA-Section. I Put a sample script beyond, maybe somone can tell me, if there is a wokaround or if it is a bug (this is, what I guess). I tried different php versions (4.2.3, 4.3.0dev, 4.3.0.-pre1, etc.) at the moment I use Sablotron 0.96.1. These are the sample scripts: An XML-Datei (test.xml) <?xml version="1.0" encoding="iso-8859-1"?> <!DOCTYPE navigation [ <!ENTITY module1 SYSTEM "test2.xml"> ]> <navigation> &module1; </navigation> and test2.xml. the entity: <?xml version="1.0" encoding="iso-8859-1"?> <test> <![CDATA[ sdfgsdfgjsödfkjgsödlkfjgsödkfjgsödfkgjsödkfgjsödkfgjsödkfgjsödlkfjgsödfgsdfg gggggggggggggslkdjfgsödlkfjgöslkdjgösldkgjsödlkfgjsödklfgjsödlkfgjsödkfgjsöd flkgjsödkfgjsödklfgjsödlkfgjsödlkfgjsödlkfgjsödlkfgjsödlkfgjsödklfgjösdklfgj södklfgjsödklfgjsödkfgjösdkfgjsödfkgjsödfkgjsödfkgjsödfgsdfgsjdöfgksjödfkgjs ödlfkgjsödlkfjgsödlkfgjsödkfjgösdklfgjösdkfjgösdkfgjösdlkfgjsödlkfgjsödlkfjg öskldfgjöslkjgölkwejrtkwejrtwejrtkjweörkltjweörkltjwöekrtjwöerlktjwöerkltjwö ekrltjwöelkrtjwöeklrjtwöelkrtjweölrktjwöelrktjwöelkrjtwöekrtjwöekrjtöwerktjw öerkjtöweklrtjwkerjtöwkerjtöwlkerjtöwklerjtöwlkerjtöweklrjtöwklerjtöwekrtjöw elkrtjöwkelrjtöwkerjtöwlkerjtöweklrtjöweklrjtöwekrjtöwerktjwöekrtjwöekrjtöwe lkrjtwöekrtjöwekrtjöwelkrjtwökelrtöwekrtjöwkelrjtölwkerjtwlökerjtwölekrjtwöl ekrjtlwöekrjtlwöekrjlketjlkjklrjlkjkjrkjlkröjlkrjklrejlkrejlkrtjlktrjlktrkjl trjlktrkljkltrjlktrjkltrkjlötrewrjlkewjlkrewjklrejlktrwkjlrkjlörwejklörewjkl trjöewrjlökerkwrelökwrjkleöw [... snipp ca. 240 columns with same content ...] ]]> </test> (for the test you have to the 240 cols into the script ...) and test.xslt: [... snipp ...] <xsl:template match="navigation"> <xsl:value-of select="."/> </xsl:template> [... snipp ...] this is the parsing script (test.php): if( !$result = @xslt_process( $parser, // resource xh "test.xml", // string xml "test.xslt", // string xslt $html, // string result array(), // array arguments array() // array parameters ) ) { printf( "Sablotron Error (%s): <br /><strong>%s</strong>", xslt_errno($parser), xslt_error($parser) ); } xslt_free($parser); echo $result; echo $html; after that I get the error. If I delete some content in the test2.xml I get no error. So I hope, that someone can help me. :) Dirk Schwier. -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, visit: http://www.php.net/unsub.php

« previous php.dev (#89457) next »