You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Jose Hernandez <jh...@algorithmics.com> on 2002/08/26 22:37:16 UTC

RE: Unknown Formatting Object - root element must be root, not 'n one' - again

That means ...
 
In your XSLT you have ...
<xsl:template match="CCDS"> <!-- also fails with "/" --> 
        <fo:CCDS xmlns:fo=" http://www.w3.org/1999/XSL/Format
<http://www.w3.org/1999/XSL/Format> "> <!-- also fails with fo:root --> 


And must be ...

<xsl:template match="CCDS"> <!-- also fails with "/" --> 
        <fo:root xmlns:fo="  <http://www.w3.org/1999/XSL/Format>
http://www.w3.org/1999/XSL/Format"> <!-- also fails with fo:root --> 


-----Original Message-----
From: Chalasani, Kumar [mailto:kumar.chalasani@documentum.com]
Sent: Monday, August 26, 2002 03:33 p.m.
To: 'fop-user@xml.apache.org'
Subject: Unknown Formatting Object - root element must be root, not 'none'
<element name> - again



Hi, 

I have tried everything, and read the archives here - i still get this
error: 
Root Element must be root, not (none) :CCDS 

I am trying to run fop - emebedded, with XML and XSL as input, and hoping
for PDF output. 

CCDS is the root element in my XML instances.... as in: 

<?xml version="1.0"?> 
<!DOCTYPE CCDS SYSTEM "./ccds.dtd"> 
<CCDS> 


CCDS is what I am template-matching on for my root-element rule in my XSL. 
i have also tried template-matching on "/", root, and got the same error
message. 


My FO namespace is correct from what i've read on this list: here's the top
of the XSL: 

<?xml version="1.0" encoding="UTF-8" ?> 
<xsl:stylesheet 
        xmlns:xsl=" http://www.w3.org/1999/XSL/Transform
<http://www.w3.org/1999/XSL/Transform> " 
        xmlns:fo=" http://www.w3.org/1999/XSL/Format
<http://www.w3.org/1999/XSL/Format> " 
        version="1.0"> 
<xsl:strip-space elements="*"/> 

<xsl:template match="CCDS"> <!-- also fails with "/" --> 
        <fo:CCDS xmlns:fo=" http://www.w3.org/1999/XSL/Format
<http://www.w3.org/1999/XSL/Format> "> <!-- also fails with fo:root --> 



I have a feeling something or the other is not in synch regarding what is
root, etc..but can't figure out exactly what. 
Is there maybe a compatibility issue with versions or something?  I am
running 0.20.4 fop.jar with xalan 2.3.1 and xerces-1.2.3.jar in the
classpath.

There MUST be something wrong with what I am doing, or conflicts in
classpaths, etc.  Fop from command line direct works fine on these same two
inputs/.

THANKS in advance for any help. 


And here's the Error: 

[INFO] building formatting object tree 
[ERROR] Unknown formatting object ^CCDS 
org.apache.fop.apps.FOPException: Root element must be root, not (none):CCDS

        at org.apache.fop.fo.FOTreeBuilder.startElement(Unknown Source) 
        at
org.apache.xerces.parsers.SAXParser.startElement(SAXParser.java:1371) 

        at
org.apache.xerces.validators.common.XMLValidator.callStartElement(XML 
Validator.java:828) 
        at
org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.disp 
atch(XMLDocumentScanner.java:989) 
        at
org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentS 
canner.java:380) 
        at org.apache.xerces.framework.XMLParser.parse(XMLParser.java:908) 
        at org.apache.fop.apps.Driver.render(Unknown Source) 
        at org.apache.fop.apps.Driver.run(Unknown Source) 
        at runTransformation.doFOTransformation(runTransformation.java:537) 
        at runTransformation.doTransformation(runTransformation.java:318) 
        at runTransformation.main(runTransformation.java:132)