Reputation: 855
I want to create a javascript code for validating dynamic controls i have created from a database using php and html. in the database i have a table with questions and answers, the questions and the options (answers) are created dynamically. But i want to validate these controls with javascript, let's say i have 100 questions, i don't want to create 100 different validations for each questions, even worse if more questions are added to the database they will be added to the page, but i wont't have a way to validate the new answers. How could i create the javascript dinamically as well as the questions and answers? I hope all that makes a little sense.
Upvotes: 0
Views: 310
Reputation: 363
Try implementing following steps.
Upvotes: 1