Check Box validation problem

Results 1 to 2 of 2

Thread: Check Box validation problem

  1. #1
    Faizi Guest

    Default Check Box validation problem

    I am using blank check box validation in java script. There are more than one checkbox with the same name<BR>. Problem is that the following code is not working when name of the checkboxes are same, but working properly with different name of checkboxes.<BR>Can Any one solve this problem. My requirement is that the name of checkboxes should be same.<BR> Code is as follows<BR><BR> .......<BR>if (form.certify.checked == 0)<BR>{<BR>alert("Please fill in the First Check Box field.");<BR>form.certify.focus();<BR>return (false);<BR>}<BR><BR>&#060;input TYPE="checkbox" NAME="certify" VALUE="1"&#062;<BR>&#060;input TYPE="checkbox" NAME="certify" VALUE="2"&#062;<BR>........<BR><BR>Thanks

  2. #2
    Join Date
    Dec 1969

    Default RE: Check Box validation problem

    if (form.certify(0).checked) <BR>{ <BR>alert("Please fill in the First Check Box field."); <BR>form.certify.focus(); <BR>return (false); <BR>} <BR><BR>you have to check each checkbox like this<BR><BR>samir

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts