Using two function, we can perform the operation.
// Check #x
$(“#checkboxid”).attr(“checked”, “checked”);
// Uncheck #x
$(“#checkboxid”).removeAttr(“checked”);
Example
Using two function, we can perform the operation.
// Check #x
$(“#checkboxid”).attr(“checked”, “checked”);
// Uncheck #x
$(“#checkboxid”).removeAttr(“checked”);
Example
© PHPInterviewQuestion.com 2009 - 2012

Comments