Trying to use javascript on our email preference center so when someone checks the "unsubscribe" box, it will automatically uncheck any other boxes on the preference center. However, the script I found on another Community page isn't working. Anybody have any ideas as to why? The script we're using is below:
<script type="text/javascript">
$jQ("#Unsubscribed").click(function() {
if ($jQ('#Unsubscribed:checked').val() != null) {
$jQ("input[name=Newsletter],input[name=Webinars],input[name=Events],input[name=Partner],input[name=Catalyst],input[name=Resources]").attr("checked", false);
}
});
$jQ("#Newsletter, #Webinars, #Events, #Partner, #Catalyst, #Resources").click(function() {
if ($jQ('#Unsubscribed:checked').val() != null) {
$jQ("input[name=Unsubscribed]").attr("checked", false);
}
});
</script>