[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] XSL newbie question formatting
I have the following xsl code. This one works but the when I try to break it into a new template it does not work. Ideas? The broken code is at the bottom <xsl:template match="/"> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master master-name="mailer" page-height="29.7cm" page-width="21cm" margin-top="1cm" margin-bottom="2cm" margin-left="2.5cm" margin-right="2.5cm"> <fo:region-body margin-top="3cm"/> <fo:region-before extent="3cm"/> <fo:region-after extent="1.5cm"/> </fo:simple-page-master> </fo:layout-master-set> <fo:page-sequence master-reference="mailer"> <fo:flow flow-name="xsl-region-body"> <fo:block font-size="10pt" font-family="sans-serif" line-height="15pt" space-after.optimum="3pt" text-align="justify"> <fo:block> <xsl:value-of select="/header/contact"/> </fo:block> <fo:block> <xsl:value-of select="/header/addr1"/> </fo:block> <fo:block> <xsl:value-of select="/header/addr2"/> </fo:block> <fo:block> <xsl:value-of select="/header/addr3"/> </fo:block> <fo:block> <xsl:value-of select="/header/city"/> <xsl:value-of select="/header/state"/> <xsl:value-of select="/header/zip_code"/> </fo:block> </fo:block> </fo:flow> </fo:page-sequence> </fo:root> </xsl:template> THIS DOES NOT WORK WHY? All I did was make a template out of it. Or did I do more? <xsl:template match="/"> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master master-name="mailer" page-height="29.7cm" page-width="21cm" margin-top="1cm" margin-bottom="2cm" margin-left="2.5cm" margin-right="2.5cm"> <fo:region-body margin-top="3cm"/> <fo:region-before extent="3cm"/> <fo:region-after extent="1.5cm"/> </fo:simple-page-master> </fo:layout-master-set> <fo:page-sequence master-reference="mailer"> <fo:flow flow-name="xsl-region-body"> <fo:block> <xsl:apply-templates select="mailingAddr"/> </fo:block> </fo:flow> </fo:page-sequence> </fo:root> </xsl:template> <!-- DATA FIELD TEMPLATES --> <xsl:template name="mailingAddr"> <fo:block font-size="10pt" font-family="sans-serif" line-height="15pt" space-after.optimum="3pt" text-align="justify"> <fo:block> <xsl:value-of select="/header/contact"/> </fo:block> <fo:block> <xsl:value-of select="/header/addr1"/> </fo:block> <fo:block> <xsl:value-of select="/header/addr2"/> </fo:block> <fo:block> <xsl:value-of select="/header/addr3"/> </fo:block> <fo:block> <xsl:value-of select="/header/city"/> <xsl:value-of select="/header/state"/> <xsl:value-of select="/header/zip_code"/> </fo:block> </fo:block> </xsl:template> __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|