[jQuery] Re: Toggling a checkbox

2007-09-27 Thread voltron
YOU DA MAN Glen! :-) On Sep 27, 10:42 pm, "Glen Lipka" <[EMAIL PROTECTED]> wrote: > I whipped up a demo. > Is this what you meant? > > http://www.commadot.com/jquery/checkboxToggle.php > > Glen > > On 9/27/07, voltron <[EMAIL PROTECTED]> wrote: > > > > > Hmm, Thanks guys, but maybe I did dot ma

[jQuery] Re: Toggling a checkbox

2007-09-27 Thread Glen Lipka
I whipped up a demo. Is this what you meant? http://www.commadot.com/jquery/checkboxToggle.php Glen On 9/27/07, voltron <[EMAIL PROTECTED]> wrote: > > > Hmm, Thanks guys, but maybe I did dot make myself to clear. I am able > to check the boxes, but I´m not able to toggle between both states. >

[jQuery] Re: Toggling a checkbox

2007-09-27 Thread voltron
Hmm, Thanks guys, but maybe I did dot make myself to clear. I am able to check the boxes, but I´m not able to toggle between both states. When the user checks the box, an input field is to be disabled, and when he unchecks it, the input box should be enabled, thats fwhat the toggle function is fo

[jQuery] Re: Toggling a checkbox

2007-09-27 Thread Glen Lipka
$(":checkbox").attr("checked","anyThingWillCheckIt") $(":checkbox").removeAttr("checked") Glen On 9/27/07, Erik Beeson <[EMAIL PROTECTED]> wrote: > > To check or uncheck a checkbox, assign true or false to its 'checked' > property (untested): $('#myCheckbox')[0].checked = true; or > $('#myCheckb

[jQuery] Re: Toggling a checkbox

2007-09-27 Thread Erik Beeson
To check or uncheck a checkbox, assign true or false to its 'checked' property (untested): $('#myCheckbox')[0].checked = true; or $('#myCheckbox').attr('checked', true); But it looks like you're trying to enable/disable them, in which case you probably want $(...).attr('disabled', 'disabled'); and