Skip to content

Instantly share code, notes, and snippets.

@lamchau
Last active October 25, 2015 22:24
Show Gist options
  • Save lamchau/cbb59ac45f7ebe8db148 to your computer and use it in GitHub Desktop.
Save lamchau/cbb59ac45f7ebe8db148 to your computer and use it in GitHub Desktop.
bookmarklet to bypass instagram's click shield
if (window.location.host === "instagram.com" && window.location.pathname.startsWith("/p/")) {
var images = document.querySelectorAll(".-cx-PRIVATE-Photo__image");
var length = images.length;
if (length) {
var element = images[length - 1];
if (element.src) {
window.location.href = element.src;
}
}
}
javascript:(function(){if("instagram.com"===window.location.host&&window.location.pathname.startsWith("/p/")){var a=document.querySelectorAll(".-cx-PRIVATE-Photo__image"),b=a.length;if(b){var c=a[b-1];c.src&&(window.location.href=c.src)}}})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment