Skip to content

Instantly share code, notes, and snippets.

@danielricecodes
Created January 2, 2012 17:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danielricecodes/1551525 to your computer and use it in GitHub Desktop.
Save danielricecodes/1551525 to your computer and use it in GitHub Desktop.
manually executing jquery ajax call instead of using remote => true in the link_to tag
li.links
= link_to ccn.name, '#', :class => 'symptom_link grey', :id => "symptom-#{ccn.id}"
javascript:
jQuery(function() {
jQuery(".symptom_link").click(function() {
jQuery.ajax("/symptom/update_possible_causes/#{ccn.name.gsub(/\s/, '-').downcase}");
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment