Skip to content

Instantly share code, notes, and snippets.

@zthomae
Created May 30, 2012 00:33
Show Gist options
  • Select an option

  • Save zthomae/2831694 to your computer and use it in GitHub Desktop.

Select an option

Save zthomae/2831694 to your computer and use it in GitHub Desktop.
My bookmarklets
<html>
<head>
</head>
<body>
<a href="javascript:(function(e,a,g,h,f,c,b,d)%7Bif(!(f=e.jQuery)%7C%7Cg%3Ef.fn.jquery%7C%7Ch(f))%7Bc=a.createElement(%22script%22);c.type=%22text/javascript%22;c.src=%22http://ajax.googleapis.com/ajax/libs/jquery/%22+g+%22/jquery.min.js%22;c.onload=c.onreadystatechange=function()%7Bif(!b&&(!(d=this.readyState)%7C%7Cd==%22loaded%22%7C%7Cd==%22complete%22))%7Bh((f=e.jQuery).noConflict(1),b=1);f(c).remove()%7D%7D;a.documentElement.childNodes%5B0%5D.appendChild(c)%7D%7D)(window,document,%221.7.2%22,function($,L)%7Bdiv=document.getElementById(%22overlay%22).parentNode;div.removeChild(overlay);div.removeChild(gatewayCreative);document.getElementsByTagName(%22html%22)%5B0%5D.style.overflow=%22scroll%22;%7D);">Kill NYTimes Paywall</a>
<a href="javascript:(function(e,a,g,h,f,c,b,d)%7Bif(!(f=e.jQuery)%7C%7Cg%3Ef.fn.jquery%7C%7Ch(f))%7Bc=a.createElement(%22script%22);c.type=%22text/javascript%22;c.src=%22http://ajax.googleapis.com/ajax/libs/jquery/%22+g+%22/jquery.min.js%22;c.onload=c.onreadystatechange=function()%7Bif(!b&&(!(d=this.readyState)%7C%7Cd==%22loaded%22%7C%7Cd==%22complete%22))%7Bh((f=e.jQuery).noConflict(1),b=1);f(c).remove()%7D%7D;a.documentElement.childNodes%5B0%5D.appendChild(c)%7D%7D)(window,document,%221.3.2%22,function($,L)%7Bvar%20xhr=new%20XMLHttpRequest;xhr.open(%22GET%22,%22https://api-ssl.bitly.com/v3/shorten?longUrl=%22+encodeURIComponent(top.document.URL)+%22&login=LOGIN_KEY&apiKey=API_KEY%22);xhr.onreadystatechange=function()%7Bif(xhr.readyState==4)if(xhr.status==200)%7Bjson=JSON.parse(xhr.responseText);window.prompt(%22Your%20new%20link%22,json.data.url)%7Delse%20console.log(%22Oops%22,xhr)%7D;xhr.send();%7D);">bitly EDITME</a>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment