[jQuery] Re: [validate] Attaching events to dynamically added fields

2009-01-09 Thread Rob
Thanks! On Jan 9, 2:18 am, "Jörn Zaefferer" wrote: > The new element has the same name as the existing one, while the validation > plugin requires unique names. You'd have to add an index to each name to get > this to work, eg. item_title[0], item_title[1] etc. > > For another example on generat

[jQuery] Re: [validate] Attaching events to dynamically added fields

2009-01-09 Thread Jörn Zaefferer
The new element has the same name as the existing one, while the validation plugin requires unique names. You'd have to add an index to each name to get this to work, eg. item_title[0], item_title[1] etc. For another example on generating those: http://jquery.bassistance.de/validate/demo/dynamic-t

[jQuery] Re: [validate] Attaching events to dynamically added fields

2009-01-08 Thread Rob
Hi Jörn, I have been plugging away at this for a while now, with no luck. I set up a test page, and stripped it down to be as basic as possible (it's much more basic than even the demos). It is located here: http://cymantix.net/validation When you add new items, they don't appear to be validat

[jQuery] Re: [validate] Attaching events to dynamically added fields

2009-01-06 Thread Rob
Ok, the rules are inline, thank you very much for the response, I will take a second look at it to see if I can figure out what's going on. On Jan 6, 2:34 am, "Jörn Zaefferer" wrote: > The validation plugin binds various events to the form, handling everything > that bubbles up from its form ele

[jQuery] Re: [validate] Attaching events to dynamically added fields

2009-01-06 Thread Jörn Zaefferer
The validation plugin binds various events to the form, handling everything that bubbles up from its form elements. So you don't have to add any event binding after adding new elements, just make sure the validation rules are present. If it isn't working, its probably a different issue. Jörn On M

[jQuery] Re: [validate] Attaching events to dynamically added fields

2009-01-05 Thread Rob
Thanks Brian, At the moment I'm using basically the simplest implementation of the plugin. I'm using inline rules, so I don't have to worry about the brackets yet. I do understand the event delegation, I had thought that calling $("#form").validate() again after inserting the elements would do

[jQuery] Re: [validate] Attaching events to dynamically added fields

2009-01-05 Thread brian
On Mon, Jan 5, 2009 at 2:40 PM, Rob wrote: > > Hi Jörn or anyone else familiar with this plugin, > > First off, thanks for the great validation plugin. I hope I do not > impose too much with this question. > > I have a dynamic form with fields named using brackets ([]). See this note: http://doc