Here’s what I have:
<%= link_to "Reload Div", {:controller => "my_controller", :action => "my_action"}, remote => true %>
I want to be able to click the link and have a div reload with different content generated by Ruby on Rails. How can I do this?
For simplicity… I simply want to be able to click the link and reload the div with a number one higher than the previous.
If you’re using jQuery, this might be easier with UJS than by hacking something together yourself. Maybe something that does this: