[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

[xsl fo] xsl to a minimum / statements 'on the fly'

Subject: [xsl fo] xsl to a minimum / statements 'on the fly'
From: "ongeaddresseerd ongeaddresseerd" <ongeadresseerd@xxxxxxxxxxx>
Date: Fri, 14 May 2004 12:47:48 +0000
xsl minimum
(expecting my first mail didn't reach the list, apologizing if this is the second mail with the same question)

Hi all,

I'm rendering pdf's with fop and I would like to keep all my lines/files of
xsl to a minimum.

This means I put a lot of formatting information in my xml file, something like this:

<reportXML page-layout="portrait">
	<title> Hello world </title>
	<table table-layout="fixed">
		<tr background-color="#CCCCCC">
			<td width="10cm"
			   <block align="left">hello again</block>
			</td>
		</tr>
                 ...

Trying to keep xsl to a minimum also means it won't include hard-coded lines like:

<fo:page-sequence master-reference="portrait">

My fo-statements (try to) use elements from the input xml, something like this:

<fo:page-sequence master-reference="<xsl:value-of select="$page_layout"/>">

As expectd, his statement won't work.

How to accomplisch this?

ps what (technically) works, is:

	<xsl:if test="@page-layout='portrait'">
		<fo:page-sequence master-reference="portrait">
			<xsl:call-template name="continue"></xsl:call-template>
		</fo:page-sequence>
	</xsl:if>

	<xsl:if test="@page-layout='landscape'">
		<fo:page-sequence master-reference="landscape">
			<xsl:call-template name="continue"></xsl:call-template>
		</fo:page-sequence>
	</xsl:if>

But this will overload my xsl file with if-statements (difficult to maintain)
because I have to use this mechanism a lot.


Thanks in advance,

mathieu van echtelt

_________________________________________________________________
Hotmail en Messenger on the move http://www.msn.nl/communicatie/smsdiensten/hotmailsmsv2/


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.