Forums

This topic is locked

HTML Form validation

Posted 05 Apr 2008 00:14:24
1
has voted
05 Apr 2008 00:14:24 Ande Anderson posted:
I'm looking for a validation code for an HTML Form. I need to have a checkbox or radio button, or something that is required before the form can be processed.

For example:
<p><input type="checkbox" name="agree" value="agree">  We agree to follow the listed Rules of Conduct.<br />

How do I make this a required field for the form submission. I was trying to use Forms To Go to convert my HTML Form to PHP and keep getting the error that this is considered to be a Multivalue field for PHP.

Thanks

Replies

Replied 05 Apr 2008 14:50:20
05 Apr 2008 14:50:20 Alan C replied:
Hi Ande

www.plus2net.com/javascript_tutorial/valid-checkbox.php

mediazeal.com/checkbox-validator.htm

either of these look like they will do the job, I like javascript for this sort of thing because it doesn't let the form come to the server until the user has clicked the box, I would still confirm that the box was checked anyway before using the information

Reply to this topic