I followed this railscast to add “complex” functionality to a form. I
added the ability to click a link to add an element to an object form
and a link to remove it.
However I am getting this error when I click “add element”
I recently overhauled pages for speed improvements including creating
cached pages for my styles and javascript files and ended up with the
same error. I performed diffs on my /public directories and found
that my true.js file had concatenated file that was contained in
another cached file. In other words, I had the same .js file being
called twice. When I removed the duplicate, my error disappeared and
my form worked properly.
I bumped into another problem made apparent using the horrible IE 7
browser. A javascript error showing there (but not in Firefox) led me
to a code error in an outside vendor widget. Removing the code also
stopped a seemingly unrelated error.
You might consider removing all your .js files except the one that
seems to throw the error. Adding your .js files one at a time might
lead you to the problem file.
I followed this railscast to add “complex” functionality to a form. I
added the ability to click a link to add an element to an object form
and a link to remove it.
Me also got the same error. I include the <%= javascript_include_tag
:defaults %> in required file (exactly in view->layout->tasks.html.erb)
That solved this error
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.