Is there a way for two or more ID's be required to be checked before doing something.
For instance:
If BOTH Checkbox 1 and Checkbox 2 are checked then the event happens.
But if only 1 or the other are checked by themselves, something else happens.
I thought this would work but nope.
function toggleStatus() {
if ($('#checkbox1 #checkbox2').is(':checked')) {
$('.option1 :input').attr('checked', true);
} else {
$('.option1 :input').attr('checked', false);
}
function toggleStatus() {
if ($('#checkbox1').is(':checked')) {
$('.option2 :input').attr('checked', true);
} else {
$('.option2 :input').attr('checked', false);
}
function toggleStatus() {
if ($('#checkbox2').is(':checked')) {
$('.option3 :input').attr('checked', true);
} else {
$('.option3 :input').attr('checked', false);
}
Hopefully I am explaining this correctly. I have looked for three days and I am stuck. Thanks for any help!