[xsl] How to integrate XSLT tags with FO tags

Subject: [xsl] How to integrate XSLT tags with FO tags
From: LiuKui <mobydick1983@xxxxxxxxxxx>
Date: Sun, 12 Apr 2009 16:09:36 +0000
Dear members, 
 
Sorry, there is a problem in the former email, this is the final version.  
 
I began to study XSL 2 weeks ago, now I don't understand how to integrate XSLT tags with FO tags in a single .xsl file. For example: 
 
<?xml version="1.0" encoding="UTF-8"?>
<?xsl:stylesheet type="text/xsl" href="person.xsl"?>
<person first-name="Kui" last-name="Liu"/> 
 
In order to format the .xml file above, I want to use the following .xsl file:
 
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3c.org/1999/XSL/Transform"; xmlns:fo="http://www.w3c.org/1999/XSL/Format";>
<xsl:template match="person">
<fo:block border="thick silver ridge">
<xsl:value-of select="@last-name"/>
<xsl:text> </xsl:text>
<xsl:value-of select="@first-name"/>
</fo:block>
</xsl:template>
</xsl:stylesheet> 
 
But it seems that the FOP can not generate valid .pdf file from these two files above, and <fo:foot> tag doesn't coexist with <xsl:stylesheet> tag. 
 
What's more, I find that Windows IE fails to recognise .fo file, which makes me a little confused. 
 
Could anyone be so kind as to explain these problems to me?
 

Liu Kui
Institute of Chinese Information Processing
Beijing Normal University
_________________________________________________________________
IOWindows Live VP9zJWR3#,OBTXWnPB0fMessenger#!
http://im.live.cn/

Current Thread