On 4 January 2012 16:47, Angelo Cordova <acordinz@gmail.com> wrote:
> Hi people.
>
> I'm developing a rails 3.0.9 app, I'm using "accept nested attributes
> for" to add dynamically new "child" items to its parent. the thing is
> every child has the same id, and I need every child with its own id,
> because I need to make some jquery functions to work with them.
I presume you are talking about the id in the html rather than the id
of the record in the database. When you generate the html for the
child, just allocate a new id for each. Since you have not shown us
how you generate the html it is difficult to comment.
Colin
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
No comments:
Post a Comment