Rails 3 remote resubmit form with dynamic fields
Posted
by
montrealmike
on Stack Overflow
See other posts from Stack Overflow
or by montrealmike
Published on 2012-09-12T13:33:39Z
Indexed on
2012/09/12
15:38 UTC
Read the original article
Hit count: 208
ruby-on-rails-3
|ruby-on-rails-3.2
I have a form which has remote => true
. When i submit it the first time everything works well.
If there are any errors i want to add new fields to this form. I did this with update.js.erb
.
The problem is that when i resubmit this form, the result js file is rendered as html (ie i see the js file text on the screen). This is the same update.js.erb
file that was rendered as js the first time...
Any idea what i'm missing?
© Stack Overflow or respective owner