[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] 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
|
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
|