SHARE
TWEET

Checkbox form validation in Firefox

a guest Feb 27th, 2012 30 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var isChecked = document.forms['myform'].elements['mycheckbox'].checked;
  2. if (!isChecked) {
  3.   alert('You must agree');
  4. }
RAW Paste Data
Top