$(document).ready(function(){
$("input#list-one-subscribe").click(function() {
if ($(this).is(":checked")){
$("div.blurb").show();
$("label#add-a").show();
}
else {
else {
$("div.blurb").hide();
$("label#add-a").hide();
}
return false;
}).click();return false;
});
This:
This:
- Adds a click event handler
- The handler looks to see if the input is checked
- If it is, the other stuff is displayed
- If it isn't the other stuff is hidden
- Then fires the click event, to run the check
On 11/2/06,
twothirty <[EMAIL PROTECTED]> wrote:
i'm having a problem with checkbox values (i've read through the discussion
list and it's helped but not enough to get this working).
http://bdm.twothirty.com/
what i want to do is this:
IF checkbox is checked, it shows div.blurb for the blurb underneath the
checkbox, as well as it shows some additional fields. right now it sort of
works if you check a box, and hit refresh, but it does not work without a
page reload.
ideas? suggestions?
--
View this message in context: http://www.nabble.com/when-checkbox-is-checked-tf2556804.html#a7125215
Sent from the JQuery mailing list archive at Nabble.com.
_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/
_______________________________________________ jQuery mailing list [email protected] http://jquery.com/discuss/
