User:Arthena/detalkify.js

function catSwapButton { if(document.title.indexOf('Category:' == 0)) { mw.util.addPortletLink('p-cactions','javascript:catSwap;','De-Talkify','ca-catswap','change category links from talk pages to article pages'); } } addOnloadHook(catSwapButton);

function catSwap { var cat = document.getElementById('mw-pages'); cat.innerHTML = cat.innerHTML.replace(/Talk\:/g,'').replace(/[_\s]talk\:/g,':'); }