Created
November 27, 2009 21:10
-
-
Save ftnk/244240 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 Query Cutter | |
// @namespace http://www.ftnk.jp/userscripts | |
// @description Cut '?ref=rss', and so on | |
// @include http://* | |
// ==/UserScript== | |
(function (){ | |
var newUrl = location.href; | |
// delete rss for Cnet Japan, barks, etc | |
// delete utm* added by feedburner | |
// delete feature for YouTube | |
// for japan.linux.com | |
newUrl = newUrl.replace(/(\?|\&)((ref=|from=)?rss$|utm.+|feature=player_embedded|topic=[0-9]*)/ig, ''); | |
if ( newUrl != location.href ) location.href = newUrl; | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment