This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Use of Parameters ...Help! :)


I'm still very new to this so excuse my ignorance.  I got some excellent
help in my last question on passing cookies into the stylesheet.  Using an
example I was directed to from Michael Kay in an article he wrote at MSDN, I
can now get my cookie passed but into the PARAM but my stylesheet breaks
when I try to use the pram in various places within the stylesheet.  I
figure it must be syntax on how I'm using it, or you cannot use it where I
want to.  I need to use it in the SORT statement, template match and
apply-templates (see below).  My cookie is outputting correctly, I can call
<xsl:value-of "$myCookie"/> and I get my cookie I set.

Again, all help is greatly appreciated!   Thanks, Bill

<?xml version="1.0"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:param name="myParm" select="'myCookie'"/>

	<xsl:template match="/">
	
		<xsl:for-each select="//agency//">
		<xsl:sort order="ascending" select="$myParm"/>

			<xsl:apply-templates select="$myParm"/>

		</xsl:for-each>

	</xsl:template>

		<xsl:template match="$myParm">
		<b> <xsl:value-of select="."/> </b>	<br/>
		</xsl:template>

	</xsl:stylesheet>


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]