Created
January 29, 2013 16:35
-
-
Save mendelgusmao/4665606 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name MediaboomShittyProtection | |
// @namespace @MendelGusmao | |
// @include *mediaboom.org/* | |
// @version 1 | |
// @require http://code.jquery.com/jquery-1.9.0.min.js | |
// @require https://raw.github.com/carlo/jquery-base64/master/jquery.base64.min.js | |
// ==/UserScript== | |
var matcher = /url=([^=]+)/; | |
$("a[href*=go]").each(function(i, link) { | |
var encoded = decodeURIComponent($(link).attr("href").match(matcher)[1]); | |
if (encoded !== undefined && encoded.indexOf("aHR0cDov") > -1) | |
$(link).attr("href", $.base64.decode(encoded)); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment