Sign in through GitHub

RailsCasts Pro episodes are now free!

Learn more or hide this

jakthom's Profile

GitHub User: jakthom

Comments by

Avatar

Richard,
I was having a similar issue. See Mizpah's solution above.

"We also need change how the line is written to include the nodes to stay bound to:

$(document).on("click","#game_classes th a, #game_classes .pagination a", function() {* would replace the line used in the original:
I also believe we now need the lines in application.js that load other documents (// = require somthing).

Thus my complete application.js looks like this:

ruby...
//= require jquery
//= require jquery_ujs
//= require_tree .
$(function() {
$(document).on("click","#game_classes th a, #game_classes .pagination a", function() {
$.getScript(this.href);
return false;
});
$("#game_classes_search input").keyup(function() {
$.get($("#game_classes_search").attr("action"), $("#game_classes_search").serialize(), null, "script");
return false;
});
});

"