In Haml, I've been trying to get the following link_to_remote call to work. It's called from the /questions/new
view.
#{link_to_remote image_tag('x.png'), :url => {:controller => 'questions', :action => 'remove_tag_from_cart'}}
I've tried the following variations.
#{link_to_remote image_tag('x.png'), :url => {:controller => :questions, :action => :remove_tag_from_cart}}
#{link_to_remote image_tag('x.png'), :controller => 'questions', :action => 'remove_tag_from_cart'}
#{link_to_remote image_tag('x.png'), :controller => :questions, :action => :remove_tag_from_cart}
In every case, I get the following link: /questions/new#
. I'm not sure why!
I also have the following in routes.rb, thinking that was the problem...
map.connect ':controller/remove_tag_from_cart', :action => 'remove_tag_from_cart'