|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: xsl:param -- passing multiple values
Actually I solved my own problem by using the id() function. I setup my
xml file with a DTD up to for the product model number as the id:
<!DOCTYPE category [
<!ELEMENT product (category)>
<!ATTLIST product
id ID #REQUIRED>
]>
Then I pass the id values from the form onto the xsl processor with the
xml and xsl file the id values get put into a xsl:parm and then I put
that parameter into a for-each statement, so the part that outputs the
data looks like this.
<xsl:for-each select="id($myparam)/property[position() = $row-no]">
<td class="r{position() mod 2}">
<xsl:apply-templates/>
</td>
</xsl:for-each>
...so only the data for the model numbers passed to the xsl will be
displayed. I am amazed that it actually works myself, I was pretty much
trying everything including some voodoo chants and tried this out just
for kicks and what do you know. The xsl is probably a bit sloppy and
probably goes against the purpose of xsl, but since I can't seem to find
a better solution using XSLT 1.0 this should do for now.
-----Original Message-----
From: Michael Kay [mailto:mhk@xxxxxxxxx]
Sent: Thursday, June 17, 2004 4:18 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: RE: xsl:param -- passing multiple values
> Unfortunatly the processor I am using (or I should say my
> company uses) is Oracle which it looks like only supports
> XSLT 1.0. If this is possible with XSLT 1.0 can someone point
> me towards some samples if there are any...I am pretty new to
> XSLT, I love it so far, but the learning curve is pretty
> tough. If I can get this [expletive deleted] to work, I think I can get my
> work to let me use it on more projects.
>
Such things are possible but painful with XSLT 1.0. I know that many
people
still have to work with XSLT 1.0 (I have to myself on consultancy
assignments) but I no longer do it for pleasure!
Michael Kay
--+------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe@xxxxxxxxxxxxxxxxxxxxxx>
--+--
|
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
|

Cart








