User:50000cal/wikia.js

// IC's vestige if ( wgNamespaceNumber === 1200 ) { $('', {       id: 'ImageWarn',        style: 'cursor:pointer;',    }).html('Image Warning') .prependTo('.toolbar .tools') .click(function {       files = prompt('File names (separate with ", " (space comma space))');        if (!files) return;        files = files.split(' , ');        title = prompt('title', 'Uncategorized Images');        if (!title) return;        blockDuration = prompt('block duration (leave blank if just warning)');        blockReason = prompt('Block reason', 'failing to comply with image policy.');        if ( blockDuration !==  && blockDuration !== null && blockReason !==  && blockReason !== null) {            var usrToBlock = wgPageName.split('Message_Wall:')[1],            token = mw.user.tokens.get("editToken"),            Api = new mw.Api;            Api.post({ action: 'block', user: usrToBlock, expiry: blockDuration, nocreate: 0, autoblock: 0, reason: blockReason, bot: true, token: token })           .done(function(d) { if (!d.error) { console.log(usrToBlock + ' has been blocked successfully! Length: ' + blockDuration); } else { alert('Failed to block ' + usrToBlock + ': ' + d.error.code); }           });        }        console.log('almost there');        $('#wall-new-message #WallMessageTitle').val(title);        var strb = (blockDuration) ? '|b=' + blockDuration + '}}' : '}}';        $('#wall-new-message #WallMessageBody').val('{{UC|' + files.join('|') + strb);        $('#WallMessageSubmit').click    }); }