User:IceKarma/xbs.js
Appearance
Code that you insert on this page could contain malicious content capable of compromising your account. If you import a script from another page with "importScript", "mw.loader.load", "iusc", or "lusc", take note that this causes you to dynamically load a remote script, which could be changed by others. Editors are responsible for all edits and actions they perform, including by scripts. User scripts are not centrally supported and may malfunction or become inoperable due to software changes. A guide to help you find broken scripts is available. If you are unsure whether code you are adding to this page is safe, you can ask at the appropriate village pump. This code will be executed when previewing this page. |
![]() | Documentation for this user script can be added at User:IceKarma/xbs. |
//
// extended delete box
//
var reasons;
var wpReason;
if ( wgAction == 'delete' ) {
reasons = {
'G1': '[[WP:CSD#G1|CSD G1]]: [[Wikipedia:Patent nonsense|Patent nonsense]]',
'G2': '[[WP:CSD#G2|CSD G2]]: Test page',
'G3': '[[WP:CSD#G3|CSD G3]]: Pure [[Wikipedia:Vandalism|Vandalism]]',
'G4': '[[WP:CSD#G4|CSD G4]]: Recreation of deleted material',
'G5': '[[WP:CSD#G5|CSD G5]]: Banned user',
'G6': '[[WP:CSD#G6|CSD G6]]: Housekeeping',
'G7': '[[WP:CSD#G7|CSD G7]]: Author requests deletion',
'G8': '[[WP:CSD#G8|CSD G8]]: [[Wikipedia:Talk page|Talk page]]s with no article',
'G9': '[[WP:CSD#G9|CSD G9]]: [[Wikipedia:Office Actions|Office actions]]',
'G10': '[[WP:CSD#G10|CSD G10]]: [[Wikipedia:Attack page|Attack page]]',
'G11': '[[WP:CSD#G11|CSD G11]]: Blatant [[Wikipedia:Spam|advertising]]',
'G12': '[[WP:CSD#G12|CSD G12]]: Blatant copyright infringement',
'A1': '[[WP:CSD#A1|CSD A1]]: No context',
'A2': '[[WP:CSD#A2|CSD A2]]: Foreign language article from other Wikimedia project',
'A3': '[[WP:CSD#A3|CSD A3]]: No content',
'A5': '[[WP:CSD#A5|CSD A5]]: [[meta:Help:Transwiki|Transwikied]]',
'A7': '[[WP:CSD#A7|CSD A7]]: No indication of importance/significance.',
'R1': '[[WP:CSD#R1|CSD R1]]: Redirect to deleted/nonexistent page',
'R2': '[[WP:CSD#R2|CSD R2]]: Redirect to Talk:, User:, or User talk:',
'R3': '[[WP:CSD#R3|CSD R3]]: Implausible typo or misnomer',
'I1': '[[WP:CSD#I1|CSD I1]]: Redundant',
'I2': '[[WP:CSD#I2|CSD I2]]: Corrupt or empty image',
'I3': '[[WP:CSD#I3|CSD I3]]: Improper license',
'I4': '[[WP:CSD#I4|CSD I4]]: No license',
'I5': '[[WP:CSD#I5|CSD I5]]: Unused unfree image',
'I6': '[[WP:CSD#I6|CSD I6]]: Missing non-free use rationale',
'I7': '[[WP:CSD#I7|CSD I7]]: Invalid fair-use claim',
'I8': '[[WP:CSD#I8|CSD I8]]: Now on [[Commons:Main Page|Commons]]',
'I9': '[[WP:CSD#I9|CSD I9]]: Blatant copyright infringement',
'C1': '[[WP:CSD#C1|CSD C1]]: Empty category',
'C2': '[[WP:CSD#C2|CSD C2]]: Speedy rename',
'C3': '[[WP:CSD#C3|CSD C3]]: Template category',
'U1': '[[WP:CSD#U1|CSD U1]]: User request',
'U2': '[[WP:CSD#U2|CSD U2]]: Nonexistent user',
'U3': '[[WP:CSD#U3|CSD U3]]: Non-free gallery',
'T1': '[[WP:CSD#T1|CSD T1]]: Template is divisive and inflammatory',
'T2': '[[WP:CSD#T2|CSD T2]]: Template blatantly misrepresents established policy',
'P1': '[[WP:CSD#P1|CSD P1]]: Speedyable portal page',
'P2': '[[WP:CSD#P2|CSD P2]]: Underpopulated portal',
};
function fill( reason ) {
wpReason.value = reasons[reason];
wpReason.focus( );
}
function ExtendDelete( ) {
wpReason = document.getElementById( 'wpReason' );
wpReason.focus( );
var btn = document.getElementById( 'wpConfirmB' );
if ( ! btn )
btn = document.getElementById( 'mw-filedelete-submit' );
btn.parentNode.innerHTML +=
'<br/>' +
'<table>' +
'<tr>' +
'<th align="right">General:</th>' +
'<td>' +
'<a href="#" onclick="return fill(\'G1\');">1</a> ' +
'<a href="#" onclick="return fill(\'G2\');">2</a> ' +
'<a href="#" onclick="return fill(\'G3\');">3</a> ' +
'<a href="#" onclick="return fill(\'G4\');">4</a> ' +
'<a href="#" onclick="return fill(\'G5\');">5</a> ' +
'<a href="#" onclick="return fill(\'G6\');">6</a> ' +
'<a href="#" onclick="return fill(\'G7\');">7</a> ' +
'<a href="#" onclick="return fill(\'G8\');">8</a> ' +
'<a href="#" onclick="return fill(\'G9\');">9</a> ' +
'<a href="#" onclick="return fill(\'G10\');">10</a> ' +
'<a href="#" onclick="return fill(\'G11\');">11</a> ' +
'<a href="#" onclick="return fill(\'G12\');">12</a> ' +
'</td>' +
'</tr>' +
'<tr>' +
'<th align="right">Articles:</th>' +
'<td>' +
'<a href="#" onclick="return fill(\'A1\');">1</a> ' +
'<a href="#" onclick="return fill(\'A2\');">2</a> ' +
'<a href="#" onclick="return fill(\'A3\');">3</a> ' +
'<span style="color: #aaa;">4</span> ' +
'<a href="#" onclick="return fill(\'A5\');">5</a> ' +
'<span style="color: #aaa;">6</span> ' +
'<a href="#" onclick="return fill(\'A7\');">7</a> ' +
'</td>' +
'</tr>' +
'<tr>' +
'<th align="right">Images:</th>' +
'<td>' +
'<a href="#" onclick="return fill(\'I1\');">1</a> ' +
'<a href="#" onclick="return fill(\'I2\');">2</a> ' +
'<a href="#" onclick="return fill(\'I3\');">3</a> ' +
'<a href="#" onclick="return fill(\'I4\');">4</a> ' +
'<a href="#" onclick="return fill(\'I5\');">5</a> ' +
'<a href="#" onclick="return fill(\'I6\');">6</a> ' +
'<a href="#" onclick="return fill(\'I7\');">7</a> ' +
'<a href="#" onclick="return fill(\'I8\');">8</a> ' +
'<a href="#" onclick="return fill(\'I9\');">9</a> ' +
'</td>' +
'</tr>' +
'<tr>' +
'<th align="right">Cats:</th>' +
'<td>' +
'<a href="#" onclick="return fill(\'C1\');">1</a> ' +
'<a href="#" onclick="return fill(\'C2\');">2</a> ' +
'<a href="#" onclick="return fill(\'C3\');">3</a> ' +
'</td>' +
'</tr>' +
'<tr>' +
'<th align="right">User:</th>' +
'<td>' +
'<a href="#" onclick="return fill(\'U1\');">1</a> ' +
'<a href="#" onclick="return fill(\'U2\');">2</a> ' +
'<a href="#" onclick="return fill(\'U3\');">3</a> ' +
'</td>' +
'</tr>' +
'<tr>' +
'<th align="right">Redirs:</th>' +
'<td>' +
'<a href="#" onclick="return fill(\'R1\');">1</a> ' +
'<a href="#" onclick="return fill(\'R2\');">2</a> ' +
'<a href="#" onclick="return fill(\'R3\');">3</a> ' +
'</td>' +
'</tr>' +
'<tr>' +
'<th align="right">Templates:</th>' +
'<td>' +
'<a href="#" onclick="return fill(\'T1\');">1</a> ' +
'<a href="#" onclick="return fill(\'T2\');">2</a> ' +
'</td>' +
'</tr>' +
'<tr>' +
'<th align="right">Portals:</th>' +
'<td>' +
'<a href="#" onclick="return fill(\'P1\');">1</a> ' +
'<a href="#" onclick="return fill(\'P2\');">2</a> ' +
'</td>' +
'</tr>' +
'</table>'
;
}
if ( window.addEventListener ) window.addEventListener( "load", ExtendDelete, false );
else if ( window.attachEvent ) window.attachEvent( "onload", ExtendDelete );
}