• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Dynamic Form Validation

 
Jeetendra S Ahuja
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my jsp web page,an table is created dynamically,with columns:
MergeStop Sequence
Now MergeStop is readonly field which cannot be edited and sequence is text field which is to be filled by user,i want to do form validation of this dynamically created web page.
I know static validation i.e., by document.getElemnetById("").value.length>0/////but how to use same concept for varying id's created dynamically..
thank you
do help








 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65216
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Once an element has been created there's no difference between "dynamic" and "static". If you are creating the elements, then you should know what the id values are.
 
Jeetendra S Ahuja
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually,,,,web page content changes dynamically......
so how it is possible to do form validation on varying text fields id's
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65216
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How is it "changing dynamically"? If it's your code changing it, then you should know what id values are being generated. As I said, once the element is created, it doesn't matter how it was created, it can be treated the same as every other element.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic