Well, you can use the whole XSLT feature set to do that. To avoid the
problem described in your previous post, it's a good idea to create a
second stylesheet for educational purposes (and for fun) that converts
your XML to a different language (ex. HTML or SVG). You will then see
that you have to resort to XSLT features exclusively. This helped me a
lot when I started with XSLT.

Consider factoring out xsl:templates from your stylesheet and use
xsl:param/xsl:with-param combinations to pass parameters into the the
templates. Alternatively, access parent nodes (via XPath) to determine
the color for a border. After all, you have access to the whole input
XML document during XSLT.

Try to find a good XSLT book, look at FOP's pointers to XSLT resources 
(http://xml.apache.org/fop/resources.html). Finally, for XSLT questions
you'll likely get more qualified answers on an XSLT-dedicated list.

Good luck.

On 25.07.2003 01:17:22 Ian Rowlands wrote:
> In reference to my previous post (sorry for the HTML, hopefully fixed
> this time!), I understand why I can't do it this way now. But is there
> any way to dynamically change the colours like this in a similar way
> (the colour will depend on the content)?



Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to