Thursday, July 3, 2014

check if checkbox checked or not in javascript

if (document.getElementById("male").checked) {
        gender = 'male';
    } else {
        gender = 'female';
    }

No comments:

Post a Comment