Revision as of 15:54, 10 September 2006 view sourceBetacommand (talk | contribs)86,927 editsNo edit summary← Previous edit |
Revision as of 16:02, 10 September 2006 view source Betacommand (talk | contribs)86,927 edits .+?)?\]Next edit → |
Line 1: |
Line 1: |
|
/Written by ], thanks to ] and ] for help with this! |
|
//Written by ], thanks to ] and ] for help with this! |
|
// BEGIN STUBREMOVE CODE |
|
// BEGIN STUBREMOVE CODE |
|
//check if we are editing and we want to stubfix |
|
//check if we are editing and we want to stubfix |
Line 6: |
Line 6: |
|
document.getElementById('wpSummary').value = "Removing stub"; |
|
document.getElementById('wpSummary').value = "Removing stub"; |
|
var contents = document.getElementById('wpTextbox1').value; |
|
var contents = document.getElementById('wpTextbox1').value; |
|
var newcontents = contents.replace(".+?)?\]", ""); |
|
var newcontents = contents.replace(/\{\{.*?stubs?(\|?.*)\}\}/g, ""); |
|
document.getElementById('wpTextbox1').value = newcontents; |
|
document.getElementById('wpTextbox1').value = newcontents; |
|
document.getElementById('wpDiff').click(); |
|
document.getElementById('wpDiff').click(); |
Line 14: |
Line 14: |
|
} |
|
} |
|
//Check if it's article to add the tab |
|
//Check if it's article to add the tab |
|
|
if(wgCanonicalNamespace == "") { |
|
if(document.title.indexOf("") != 0 && document.URL.search(/\?/) == -1) { |
|
|
addOnloadHook(function(){ |
|
addOnloadHook(function(){ |
|
var taburl = "http://en.wikipedia.org/search/?title="+wgPageName+"&action=edit&stubfix=1"; |
|
var taburl = "http://en.wikipedia.org/search/?title="+wgPageName+"&action=edit&stubfix=1"; |