Skip to content

Instantly share code, notes, and snippets.

@seivan
Created March 9, 2009 21:23
Show Gist options
  • Save seivan/76489 to your computer and use it in GitHub Desktop.
Save seivan/76489 to your computer and use it in GitHub Desktop.
$(function() {
$("a.rjs").click( function() {
$.ajax({
url: this.href,
dataType: "script",
beforeSend: function(xhr) {xhr.setRequestHeader("Accept", "text/javascript");}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment