PDA

View Full Version : Form Validation Help needed!


achilles.m91382174
06-14-2009, 04:34 PM
Hello guys. I have created a form in dreamweaver and im now using Webassist's form validation toolkit to validate my form.
But the problem i am facing is that i am not able to validate all the fields.

When i select validation > client side validation:
Then i get a box in which we have to choose entries that have to be validated and how they have to be validated but all the entries in the form are not there in the list from where i can choose the form elements to validate.

For example i can choose all the radio buttons to validate and all the select also but many of the textfieds are not in that list.

Please help!

AlaskaTom
06-15-2009, 01:03 AM
Can you paste the html content of your form.
Everything between and including the <form> </form>

Thanks.
Tom

achilles.m91382174
06-15-2009, 02:07 AM
Thanks for the hint :)

Problem solved. Actually i was working on some existing form so the textfields that were present in the form were not originally created by me and this was the problem :

<input name="firstname" class="input_bgr" id="firstname" style="text-transform:uppercase" onblur="isUpper(this)" size="12" maxlength="20" />


I changed it to

<input name="firstname" type="text" id="firstname" style="text-transform:uppercase" onblur="isUpper(this)" size="12" maxlength="20" />


And now its available in the list.

Thanks

AlaskaTom
06-15-2009, 02:22 AM
Yep, It was probably the missing type="text".
As I have worked with, and cleaned up other developers code, I have found a number of reasons that validation toolkit will not recognize form elements. Sometimes if they are in a table, or have invalid attributes, or missing quotes around values etc.

Glad you got it figgured out!

Tom