xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chen, Ben" <bc...@biosignia.com>
Subject FOP and HTML tags
Date Wed, 06 Apr 2005 17:23:38 GMT
Hi all,

I'm currently having a problem converting HTML to PDF using FOP
(v.0.20.5).  The problem is that although I've defined tags in the
XSL-FO file (ex.

            <xsl:template match="li">




test="string-length(../@style) = 0">

<fo:inline font-family="sans-serif">&#x2022;</fo:inline>






<xsl:value-of select="."/>






the result of the PDF document includes the tags as part of displayed
text rather than parsing them as tags.  For example, in the PDF document
I see "<ul><li>test</li></ul>" rather than just *test.  My Java program
does two conversion (we support both an HTML report and a PDF report and
would like to keep both conversions for consistency):  first from XML to
HTML through a XSLT stylesheet and then from that HTML to PDF through a
XSL-FO stylesheet.  Something to note is that if HTML tags are added as
a result from the XML to HTML conversion, then the PDF displays
correctly as a *test.  However, if the tag was present prior to the XML
to HTML conversion (ex. the string text was obtained with tags from the
messagesbundle:  TEST=<ul><li>test</li></ul>) then
"<ul><li>test</li></ul>" appears in the PDF.  Can anyone explain why
these HTML tags are not parsed using the 2nd method and also tell me how
I would get them to be parsed?  I've examined the HMTL content with both
methods (both through the messagesbundle and through adding tags in the
XSLT) before the HTML to PDF conversion and they are identical.  Thanks
for your help in advance :).


View raw message