Answers for "jquery input checkbox"

63

jquery checkbox checked

//using plane javascript 
if(document.getElementById('on_or_off_checkbox').checked) {
    //I am checked
} 

//using jQuery
if($('#on_or_off_checkbox').is(':checked')){
    //I am checked
}
Posted by: Guest on July-19-2019
6

jQuery check a radio button

// jQuery version 1.6 or above use:  
$("#myRadioID").prop("checked", true);
 
//jQuery versions below 1.6 use:
$("#myRadioID").attr('checked', 'checked');
Posted by: Guest on July-25-2019
13

jquery checkbox checked value

if ($('#check_id').is(":checked"))
{
  // it is checked
}
Posted by: Guest on March-09-2020
11

jquery checkbox checked

$("checkbox").is(":checked")
Posted by: Guest on April-10-2020
9

check a checkbox jquery

$('#grepperRocks').prop('checked', true);
Posted by: Guest on March-17-2020
0

check checkbox by jquery

$('.myCheckbox')[0].checked = true;
$('.myCheckbox')[0].checked = false;
Posted by: Guest on September-04-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language