From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
Behalf Of Calamity
Subject: [jQuery] Toggling div based on radio buttons

Basically I have a form with several fieldsets (I can wrap them in divs
if
absolutely necessary) that need to be displayed/hidden based on radio
button
selection. For example:

There are 4 radio buttons: Software, Hardware, Telecom and Field Device

If a user clicks Software, it should display the fieldset that contains
pertinent information for software. If a user misclicked, or has an
additional request for say, hardware, I would like any section that is
shown
to be hidden prior to showing the hardware section.

-----

That should be simple enough... Here is some code to get your started:

http://pastie.caboo.se/27620 - HTML

http://pastie.caboo.se/27621 - JavaScript

I tried to keep it pretty basic so it should work with whatever you're
HTML set up is.  Make the fieldset and the radio have the same className
and you should be kosher.

-ALEX

_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to