Skip to content

Instantly share code, notes, and snippets.

@javascripter
Created August 2, 2008 14:39
Show Gist options
  • Save javascripter/3737 to your computer and use it in GitHub Desktop.
Save javascripter/3737 to your computer and use it in GitHub Desktop.
// ==UserScript==
// @name MDCJa2En
// @namespace http://d.hatena.ne.jp/javascripter/
// @include http://developer.mozilla.org/ja/*
// ==/UserScript==
function ja2en(doc) {
Array.forEach(doc.getElementsByClassName('new'),
function(a) {
a.href = a.href.replace("ja","en");
});
}
ja2en(document.body);
if ("AutoPagerize" in window)
window.AutoPagerize.addFilter(function(docs) {
docs.forEach(ja2en)
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment