Revision as of 23:15, 13 September 2006 view sourceBetacommand (talk | contribs)86,927 editsNo edit summary← Previous edit |
Revision as of 23:24, 13 September 2006 view source Betacommand (talk | contribs)86,927 editsm Revert to revision 75056998 by Betacommand.Next edit → |
Line 1: |
Line 1: |
|
//Written by ], thanks to ] and ] for help with this! |
|
//Written by ], thanks to ] and ] for help with this! |
|
//Modified by ] |
|
//Modified by ] |
|
// BEGIN Test remove LINK REMOVAL CODE |
|
// BEGIN MYSPACE LINK REMOVAL CODE |
|
//check if we are editing and we want to Test remove |
|
//check if we are editing and we want to myspace |
|
if (window.location.href.indexOf('action=edit') != -1 && window.location.href.indexOf('Test remove=1') != -1) { |
|
if (window.location.href.indexOf('action=edit') != -1 && window.location.href.indexOf('myspace=1') != -1) { |
|
function Test remove() { |
|
function myspace() { |
|
document.getElementById('wpSummary').value = "Removing Test remove link as unverifiable and against policy ]"; |
|
document.getElementById('wpSummary').value = "Removing Myspace link as unverifiable and against policy ]"; |
|
var contents = document.getElementById('wpTextbox1').value; |
|
var contents = document.getElementById('wpTextbox1').value; |
|
var newcontents = contents.replace( /\*?\s*\?\s*\r?/g, ""); |
|
var newcontents = contents.replace(/(\*\s*?)?\/g, ""); |
|
document.getElementById('wpTextbox1').value = newcontents; |
|
document.getElementById('wpTextbox1').value = newcontents; |
|
document.getElementById('wpDiff').click(); |
|
document.getElementById('wpDiff').click(); |
|
document.getElementById('wpWatchthis').checked = ""; |
|
document.getElementById('wpWatchthis').checked = ""; |
|
} |
|
} |
|
addOnloadHook(function(){ Test remove(); }); |
|
addOnloadHook(function(){ myspace(); }); |
|
} |
|
} |
|
//Check if it's article to add the tab |
|
//Check if it's article to add the tab |
|
if(wgCanonicalNamespace == "") { |
|
if(wgCanonicalNamespace == "") { |
|
addOnloadHook(function(){ |
|
addOnloadHook(function(){ |
|
var taburl = "http://en.wikipedia.org/search/?title="+wgPageName+"&action=edit&Test remove=1"; |
|
var taburl = "http://en.wikipedia.org/search/?title="+wgPageName+"&action=edit&myspace=1"; |
|
addTab(taburl, "Remove Test remove!", "ca-Test remove", "This is to kill Test remove Links"); |
|
addTab(taburl, "Remove Myspace!", "ca-myspace", "This is to kill Myspace Links"); |
|
}); |
|
}); |
|
} |
|
} |
|
//END Test remove LINK REMOVAL CODE |
|
//END MYSPACE LINK REMOVAL CODE |