User:AzaToth/twinklebatchdelete.js: Difference between revisions

Content deleted Content added
Amalthea (talk | contribs)
Attempt to make it work with Special:PrefixIndex/Foo
Amalthea (talk | contribs)
fix
Line 99:
var pathSplit = ___location.pathname.split('/');
if (pathSplit.length<3 || pathSplit[2]!="Special:PrefixIndex") return;
var gapnamespacetitleSplit = Namespace[pathSplit[3].split(':')[0].toUpperCase()];
var gapnamespace = Namespace[titleSplit[0].toUpperCase()];
var gapprefix = pathSplit.splice(3).join('/');
if ( typeof(gapnamespace)=='undefined' )
{
var gapnamespace = Namespace.MAIN;
var gapprefix = pathSplit.splice(3).join('/');
}
else
{
pathSplit = pathSplit.splice(4);
pathSplit.splice(0,0,titleSplit.splice(1).join(':'));
var gapprefix = pathSplit.join('/');
}
}