This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: <xsl:choose> <xsl:when> and graphics salad!
- To: xsl-list at mulberrytech dot com
- Subject: Re: <xsl:choose> <xsl:when> and graphics salad!
- From: David Carlisle <davidc at nag dot co dot uk>
- Date: Wed, 5 Apr 2000 16:19:46 +0100 (BST)
- References: <BB3B8E2BD7EED211935500A0C9C74B7B86EDEA@exch-grimm.btg.com>
- Reply-To: xsl-list at mulberrytech dot com
> It looks like:
haha at last some information:-)
> <document>
so your root element is called document.
so the xpath expression /text/@text.role will always return an empty
node set, which counts as false to xsl:if.
> Should I just do <xsl:template match="packet">
> <xsl:value-of select="text"/>
well that is always empty, judging by your example, packet
only has para and illust children, no text children.
Of course I don't have any idea what the desired output should be but
I'd guess you want to have
<xsl:template match=packet">
....
and then have queries like select="para" select="illust/image" etc.
you need to use relative queries from the current node, not absolute
paths starting with / if yoxrmu intend to get different values for
different instances of the template. The current node will be whichever
node you specify in the match attribute to xsl:template.
David
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list