[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: Dropdown
> From: Juan Carlos Gonzalez [mailto:jcgonz@xxxxxxxxx] > Sent: Tuesday, October 22, 2002 11:37 AM > Subject: Dropdown > > > Hi: > > I'm trying to create a drop down list box dynamically, > but I'm getting an error message cause the "select" > tag is not being closed within the "if" tag. I have > tried replacing the < and > sign with the < and > > but it's still not working. Any ideas? > > <xsl:if test="some condition"> > <select name="cat"> > </xsl:if> > > ...the folowing template will create the options tag > amoung other things ... > > <xsl:apply-templates select="cat"/> > > <xsl:if test="some condition"> > </select> > </xsl:if> That isn't valid XSLT. The select element must be closed within the scope of the first xsl:if element. Assuming that you have a template or templates to create the options for the drop-down, your XSLT should probably look like: <xsl:if test="some condition"> <select name="cat"> <xsl:apply-templates select="cat"/> </select> </xsl:if> cheers, b. | brian martinez brian.martinez@xxxxxxxx | | senior gui programmer 303.708.7248 | | trip network, inc. fax 303.790.9350 | | 6436 s. racine cir. englewood, co 80111 | | http://www.cheaptickets.com/ http://www.trip.com/ | 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
|