Hi, everyone,
I'm trying to update the content of a div using link_to_remote and RJS template. Everything works fine if I use the default Prototype/Scriptaculous libraries, but I want to use jRails 'coz other parts of my application use a lot of jQuery. Here are the steps I done:
1. inside StatesController.rb I defined the following action: def update_view # do nothing just render the default template, in my case a RJS template end
2. here's the whole update_view.rjs file: page.insert_html :bottom, 'result_view', "Hello, World!<br/>"
3. inside show.html.haml (I really don't like erb): = link_to_remote 'update view', :url => { :action => :update_view } #result_view
4. here is what I get in log/development.log when using Prototype/ Scriptaculous: Parameters: {"authenticity_token"=>"60e55877a4b807f568824ed36c5849e95dc07607", "action"=>"update_view", "controller"=>"states"}
5. here is what I get in log/development.log when using jRails Parameters: {"authenticity_token"=>"60e55877a4b807f568824ed36c5849e95dc07607", "action"=>"show", "id"=>"update_view", "controller"=>"states", "_"=>"1216305965026"}
The action called is "show" (the current one) instead "update_view".
I know it must be a jRails issue, and should post in jRails list, but I believe someone here could help me faster.
Thanks