[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: FW: Toggling radio buttons

Subject: Re: FW: Toggling radio buttons
From: Jeni Tennison <mail@xxxxxxxxxxxxxxxx>
Date: Fri, 24 Aug 2001 17:40:33 +0100
xslt radio button checked
[Sorry - my finger slipped!]

Hi Elisabeth,

> I got that code form www.w3schools.com , in the XSL tutorial.

It looks as though they are teaching the Microsoft-specific dialect
called XSL, rather than XSLT? This list covers XSLT, but there are
Microsoft newsgroups for XSL help, if you want to use that (though I'd
recommend that you don't). Have a look at:

  http://www.netcrucible.com/xslt/msxml-faq.htm

to learn about the difference.

> I will try <xsl:if test>. How do I check for a value not equal to
> something?

Either x != y or not(x = y). The latter is more probably what you want
if you are testing node sets.

I think that you want:

  <input type="radio" name="rdoGIQ6" value="Y"
         onClick="disableGroup(this.form, 'txtGIQ6T', false)">
    <xsl:if test="hlfr9_questions/giq6 = 'Y'">
      <xsl:attribute name="checked">checked</xsl:attribute>
    </xsl:if>
  </input>

  <input type="radio" name="rdoGIQ6" value="N"
         onClick="disableGroup(this.form, 'txtGIQ6T', true)">
    <xsl:if test="hlfr9_questions/giq6 = 'N'">
      <xsl:attribute name="checked">checked</xsl:attribute>
    </xsl:if>
  </input>

(Note: boolean attributes in HTML (e.g. <input checked>) are set by
having the attribute of that name set to the name of the attribute.)

I hope that helps,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/


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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.