Skip to content

Instantly share code, notes, and snippets.

@c2k
Created November 16, 2013 00:23
Show Gist options
  • Save c2k/7494119 to your computer and use it in GitHub Desktop.
Save c2k/7494119 to your computer and use it in GitHub Desktop.
Inject jQuery into Google's search result page
// Run on Google search result page
(function() {
var jq = document.createElement('script'); jq.type = 'text/javascript'; jq.async = true;
jq.src = ('https:' == document.location.protocol ? 'https://' : 'http://') + 'code.jquery.com/jquery-latest.min.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(jq, s);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment