Answers for "change checkbox jq"

1

how to change checkbox state in jquery

$('[name="SelectedGroup"]').prop('checked', true);
Posted by: Guest on December-17-2020
0

change checkbox jquery alert

$(document).ready(function() {
    //set initial state.
    $('#textbox1').val(this.checked);

    $('#checkbox1').change(function() {
        if(this.checked) {
            var returnVal = confirm("Are you sure?");
            $(this).prop("checked", returnVal);
        }
        $('#textbox1').val(this.checked);        
    });
});
Posted by: Guest on September-23-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language