Skip to content

Instantly share code, notes, and snippets.

@henrysher
Created November 10, 2012 09:51
Show Gist options
  • Select an option

  • Save henrysher/4050585 to your computer and use it in GitHub Desktop.

Select an option

Save henrysher/4050585 to your computer and use it in GitHub Desktop.
Make the pocket able to save HTTPS URL
javascript: (function () {
var d = document,
l = d.location;
m = l.protocol + '//getpocket.com/save?url=' + encodeURIComponent(l.href);
with(window.open(m)) {
}
})();
javascript: (function () {
var d = document,
l = d.location;
m = l.protocol + '//getpocket.com/save?url=' + encodeURIComponent(l.href);
with(window.open(m)) {
}
})();
javascript: (function () {
var d = document,
l = d.location;
m = l.protocol + '//getpocket.com/save?url=' + encodeURIComponent(l.href);
with(window.open(m)) {
}
})();
javascript: (function () {
var d = document,
l = d.location;
m = l.protocol + '//getpocket.com/save?url=' + encodeURIComponent(l.href);
with(window.open(m)) {
}
})();
javascript: (function () {
var d = document,
l = d.location,
fname = l.pathname.split("/"),
fname = fname[fname.length - 1];
if (d.title) {
var m = l.protocol + '//getpocket.com/save?url=' + l.href + '&title=' + d.title;
} else {
var m = l.protocol + '//getpocket.com/save?url=' + l.href + '&title=' + fname;
}
window.open(m);
})();
// [blocked] The page at https://httpkit.com/resources/HTTP-from-the-Command-Line/ ran insecure content from http://getpocket.com/b/r.js.
javascript: (function () {
var d = document,
l = d.location,
fname = l.pathname.split("/"),
fname = fname[fname.length - 1];
if (d.title) {
var m = l.protocol + '//getpocket.com/save?url=' + l.href + '&title=' + d.title;
} else {
var m = l.protocol + '//getpocket.com/save?url=' + l.href + '&title=' + fname;
}
window.open(m);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment