I have the simple view page:
<div id="test1"></div>
<%= link_to_remote "Turn on Alert", :url => {:controller => "alerts",
:action => "new"} :update => "test1" %>
Then in my controller I simply do
if request.xhr?
render :text => "AJAX Called"
else
redirect_to :back
end
It's hitting the request.xhr? block as I had a logger.info statement
there. However the "test1" div is not saying "AJAX Called". Nothing
appears.
Help?
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---