Subject: Is it possible to dynamically select portions of an XML page?
From: Ben Robb <Ben@xxxxxxxxxx>
Date: Fri, 14 May 1999 11:47:54 +0100
|
Hi,
I have a large XML page, and I want to show only a small part of it via my
XSL sheet.
I put in something like:
<xsl:for-each select="BOOKSTORE/BOOK">
<xsl:if test=".TITLE='book1'">
<!-- show the book details-->
</xsl:if>
<!-- else don;t -->
</xsl:for-each>
and it works fine. Now for the slightly tricky bit. I want the "if"
statement to be dynamic. I can pass the ASP page I am displaying the XML in
a querystring. So is there a nice way to pass the querystring to the
stylesheet and have it act on it?
something like (but not, since you can;t use % symbols)
<xsl:if test=".TITLE='<%=Request.QueryString("title")%>'">
Or is there another workaround?
Hope this is clear.
Rgs,
Ben Robb
cScape Strategic Internet Solutions
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|