# CHANGED: Don't do this.
# if request.xhr?
# render :action => "add_with_ajax"
# else
# redirect_to :controller => "catalog"
# end
respond_to do |format|
format.html {redirect_to :controller => "catalog"}
format.js {render :action => "add_with_ajax"}
end
Respond to Ajax
Leave a Reply
You must be logged in to post a comment.