0
Q:

how to check input is selected or not

//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
}
21
$('#' + id).is(":checked")
4
var $boxes = $('input[name=thename]:checked');
0

New to Communities?

Join the community