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]

Pass variables from template to another template


Dear all,

	I am wondering how to pass one variable from one template to
another template. I have the following XML codes:

	<STUFF>
		<TYPE>milk</TYPE>
		<CONDITION>still can drink</CONDITION>
		<FEATURES>
			<EXPIREDATE>5 May 2000</EXPIREDATE>
			<BRAND>ASDA</BRAND>
		</FEATURES>	
	</STUFF>

	Now I have an XSL codes to pass in the expire date (<xsl:param
name="expire" />) and read the values at the tag <EXPIREDATE>... Now I am
not sure how to compare two variables, and change the <CONDITION> value?

	For example I pass in the "10 May 2000" and then compare it with
the "5 May 2000", and change the <CONDITION> to "expired". I am not sure
how to pass the two variables into the <CONDITION> template in XSL.

	Please give me some hints for doing this. Thousand thanks.

	

Best regards,
Cheun Ngen CHONG



 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]