Created
March 17, 2013 13:16
-
-
Save kedarmhaswade/5181460 to your computer and use it in GitHub Desktop.
Making data-remote=true link behave as such, but only once!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var j = jQuery.noConflict(); | |
j("body").append("<%= escape_javascript(render :partial => 'problems/problem_gallery_carousel')%>"); | |
j("#show-problem-gallery-link").unbind(); | |
j("#show-problem-gallery-link").attr("data-remote", "false"); //no Ajax anymore | |
j("#show-problem-gallery-link").click(function() { //attach a JS-only event handler | |
j("#problem-gallery-carousel").carousel({interval: false}); | |
j("#problem-gallery-modal").modal('show'); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment