I've never seen this but I guess they are warnings from a validating XML
parser. Maybe you have a Schema declaration in your stylesheet or
something like that. Maybe you should rewrite the servlet to use a more
JAXP-like approach as described here:

http://cvs.apache.org/viewcvs.cgi/xml-fop/examples/embedding/java/embedding/ExampleXML2PDF.java?hideattic=1&rev=1.1.2.2&only_with_tag=fop-0_20_2-maintain&view=markup

I don't know if this will help but you will have greater control over
how the XSLT process is done.

Good luck.

On 16.02.2005 10:02:25 Manisha Sathe wrote:
> Till now i was trying fop through command line. I was passing xml and xsl 
> file and getting pdf file. So far so good. Now i changed it to servlet. Using 
> example servlet provided but i am getting huge number of errors. (although i 
> am getting the o/p) 
>  
> -------------
> ....
>             TraxInputHandler input =
>                   new TraxInputHandler(new File(xmlParam),
>                                      new File(xslParam));
>             ByteArrayOutputStream out = new ByteArrayOutputStream();
>             Driver driver = new Driver();
>             driver.setLogger(log);
>             driver.setRenderer(Driver.RENDER_PDF);
>             driver.setOutputStream(out);
>             input.run(driver);
> ,.....
>  
> later i write it to pdf file. 
>  
> But i get Errors like
>  
> [Error] advertformat.xsl:7:37 Element type "xsl:stylesheet" must be declared
> [Error] advertformat.xsl:8:37 Element type "xsl:template" must be declared
> [Error] advertformat.xsl:10:37 Element type "fo:table" must be declared
> [Error] advertformat.xsl:17:37 Element type "fo:table-row" must be declared
> [Error] advertformat.xsl:17:37 Element type "fo:table-cell" must be declared
> 
> .....
> ....
> ......
> 
> 
> Like this for all tags it is giving me error. I am getting my pdf file 
> properly but i am not understanding why this is happenning then ?



Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to