Hi Jörn,

Brilliant plug-in, it may be that I can do what I need to but i can't
seem to make it work.   I'm building a form with lots of fields, after
the DOM is ready I then bind the validation rules for the known
fields.  I then have functionality which allows the user to add new
fields, table rows with multiple fields, etc.  What I would like to be
able to do is to bind the validation rules for these newly added DOM
elements.  I've looked at your dynamic demo and this is all achieved
by the class attribute (which I don't particularly want to do).   I'm
building up a rule object and binding it to the fields using $
("#form").validate(ruleObj).  This works brilliantly for the known DOM
fields after the initial load.  I would then like to call the $
("#form").validate(ruleObj) with the ruleObj and appended field
validation rules or (ideally) with just the new field validation rules
after a new field (or row of fields) has been added to the DOM.  I've
tried both of these after adding a new field and none of the rules are
bound.  To highlight another jQuery plug-in which has similar
functionality but for a different application (table data sorting)
look at tablesorter where it provides a trigger function to tell the
plug-in that the DOM has changed [$("table").trigger("update");].
Ideally some sort of append rules functionality would be great.

Again fantastic work on a great tool,

Best Regards

Michael

Reply via email to