Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@wijhuang
Last active April 10, 2018 07:43
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 wijhuang/11309f9a63f01ea64b5369b790356e7a to your computer and use it in GitHub Desktop.
Save wijhuang/11309f9a63f01ea64b5369b790356e7a to your computer and use it in GitHub Desktop.
Inject jQuery to any webpage
if (typeof(jQuery)=="function") console.log("Success")
javascript:(function() {
function l(u, i) {
var d = document;
if (!d.getElementById(i)) {
var s = d.createElement('script');
s.src = u;
s.id = i;
d.body.appendChild(s);
}
}
l('//code.jquery.com/jquery-3.2.1.min.js', 'jquery')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment