% cat 2nnReadHtmlConv.user.js // ==UserScript== // @name URL convert for 2nn // @namespace http://www.2nn.jp/ // @description Covert to read.cgi from read.html included in an URL // @include http://www.2nn.jp/* // ==/UserScript==
window.addEventListener("load", function(e){ var aTags = document.getElementsByTagName("a"); for (var i=0; i<aTags.length; i++) { var href = aTags[i].href; aTags[i].href = href.replace(/(read\.html)/, "read.cgi"); } }, false);