User:Bubba hotep/vector.js

//

// User:Lupin/popups.js

importScript('User:Lupin/popups.js'); popusStructure = 'fancy2'; popupDelay = 2; popupFixDabs = true; popupAdminLinks = true; popupOnEditSelection = false;

//Interiot's javascript edit counter if (document.title.indexOf('User:Interiot/Tool2/code.js') != -1) { importScript('User:Interiot/Tool2/code.js'); }

// Helper tools importScript('User:Voice_of_All/Addtabs/monobook.js');

// Admin tools // importScript('User:Voice_of_All/admin/monobook.js');

$(function { //moves Mvaluejs_class = 'yes'; //edits Rvaluejs_class = 'yes'; //uploads Uvaluejs_class = 'yes'; });

importScript('User:AzaToth/morebits.js'); importScript('Wikipedia:WikiProject User scripts/Scripts/Add LI menu'); importStylesheet('Wikipedia:WikiProject User scripts/Scripts/Add LI menu/css');

if (document.title.indexOf('Editing User talk:') != -1) { importScript('User:AzaToth/twinklewarn.js'); } else { importScript('User:AzaToth/twinklespeedy.js'); importScript('User:AzaToth/twinkleprotect.js'); }

TwinkleConfig = { revertMaxRevisions             :       50, userTalkPageMode               :       'tab', showSharedIPNotice             :       true, openTalkPage                   :       [ 'agf', 'norm', 'vand' ], openTalkPageOnAutoRevert       :       false, openAOLAnonTalkPage            :       false, summaryAd                      :       "", deletionSummaryAd              :       "", protectionSummaryAd            :       "", watchSpeedyPages               :       [  ], openUserTalkPageOnSpeedyDelete :       [  ], watchRevertedPages             :       [  ], markRevertedPagesAsMinor       :       [ 'agf', 'norm', 'vand', 'torev' ], deleteTalkPageOnDelete         :       false, markWarningsAsMinor            :       true, markAIVReportAsMinor           :       true, markSpeedyPagesAsMinor         :       true, confirmUsernameToAIV           :       true, orphanBacklinksOnSpeedyDelete  :       true };

importStylesheet('Wikipedia:Template standardisation/CSS');

importScript('User:Ais523/votesymbols.js');

////////OTHER STUFF

function addlilinkwithedit(tabs, page, name){ page = page.replace(/ /,'_'); logLI = document.createElement('li'); logLI.appendChild(make_link('http://en.wikipedia.org/wiki/'+page,name)); logLI.appendChild(document.createTextNode(' ('));  logLI.appendChild(make_link('http://en.wikipedia.org/w/index.php?action=edit&title='+page,'edit'));   logLI.appendChild(document.createTextNode(')')); tabs.appendChild(logLI); }

function make_link(url,text) { newA = document.createElement('a'); newA.href = url; newA.appendChild(document.createTextNode(text)); return newA; }

//////////GOOGLE AND YAHOO SEARCHES $(function { var title;  if (!(title = document.getElementById('t-whatlinkshere') )) return;  if (!(title = title.getElementsByTagName('a')[0] )) return;  if (!(title = title.href )) return;  if (!(title = title.replace(/^.*Special:Whatlinkshere\//, ) )) return;  if (!(title = title.replace(/^(Talk|User|Wikipedia|Image|MediaWiki|Template|Help|Category|Portal)(_talk)?:/, ) )) return;  if (!(title = title.replace(/("|%22)/g, '') )) return;  if (!(title = title.replace(/_/g, '%20') )) return;

addLink('p-tb', 'http://www.google.com/search?q=%22'+title+'%22%20-Wikipedia&ie=utf-8&oe=utf-8',   'Google search', 't-googlesearch', 'Search Google for "'+decodeURIComponent(title)+'"', 'G', null); addLink('p-tb', 'http://search.yahoo.com/search?p=%22'+title+'%22%20-Wikipedia&ei=UTF-8',   'Yahoo! search', 't-yahoosearch', 'Search Yahoo! for "'+decodeURIComponent(title)+'"', 'Y', null); });

//////////TOOLBOX LINKS $(function{ // get page title var pagetitleRe=/[^:]*:\/\/en\.wikipedia\.org\/(wiki\/|w\/index\.php(?:\?.*&|\?)title=)([^&?#]*)/; ptitle = pagetitleRe.exec(decodeURI(location.href))[2].split('_').join(' '); user_logs_url1 = ""; misza_counter = "";

tabs = document.getElementById('p-tb').getElementsByTagName('ul')[0];

addlilink(tabs, '/wiki/Special:Log', 'All logs', 'pt-alllogs'); addlilink(tabs, '/wiki/Special:Ipblocklist', 'Block list', 'pt-ipblocklist');

// if this is a user, show the logs for the user rather than the page if( (window.location.href.indexOf("User:") != -1) || (window.location.href.indexOf("User_talk:") != -1) ) { regDropSubpages = /[User|User_talk][:|%3A]([^&?\/]*)[\/]?.*/; user = regDropSubpages.exec(ptitle)[1]; user_logs_url1 = "http://en.wikipedia.org/w/index.php?title=Special%3ALog&user=" + user; user_logs_url2 = "http://en.wikipedia.org/w/index.php?title=Special%3ALog&page=User:" + user; misza_counter = ("http://tools.wikimedia.de/~misza13/cgi-bin/count.py?user="+user+"&project=enwiki_p").replace(" ","_"); } if (misza_counter != "") { addlilink(tabs, misza_counter, "Misza counter", "pt-misza-counter"); }

if (user_logs_url1 != "") { logLI = document.createElement('li'); logLI.id = 'pt-logs'; logLI.appendChild(make_link('http://en.wikipedia.org/wiki/User:'+user,'User')); logLI.appendChild(document.createTextNode(' ('));  logLI.appendChild(make_link(user_logs_url1,'logs'));   logLI.appendChild(document.createTextNode(' • '));   logLI.appendChild(make_link(user_logs_url2,'logs'));   logLI.appendChild(document.createTextNode(')')); tabs.appendChild(logLI); } addlilink(tabs, '/w/index.php?title=Special:Log&page=' + ptitle, 'Page logs', 'pt-pagelogs'); });

////////////MASTER ROLL BACK (VoA)

document.write(' ');

$(Dfn_js_con) function Dfn_js_con { Mvaluejs_class = 'spork'; Rvaluejs_class = 'spork'; Uvaluejs_class = 'spork'; }

////////////WIKIBREAK ENFORCER /*addOnloadHook(function{   var currentdate = new Date;                                   // YYYY, MM, DD, HH, MM, SS    var enforced_break_end = new Date(2006, 03, 15, 9, 00, 00);                     // *** IMPORTANT: Subtract 1 from month, i.e. january = 0 ***

if (currentdate > enforced_break_end) { // alert ("Welcome back from your enforced wikibreak!"); } else { alert ("Enforced wikibreak until " + enforced_break_end.toLocaleString + " (currently " + currentdate.toLocaleString + "). Bye!"); window.location = "http://en.wikipedia.org/w/index.php?title=Special:Userlogout&returnto=Main_page"; } });*/

// ======== QuickBlocks ======= function QuickBlock (expiry,reason,ao,ab,autob) { blockForm = document.getElementById('blockip'); inputs = blockForm.getElementsByTagName('input'); for (i=0; i<inputs.length; i++) { if (inputs[i].name == 'wpBlockOther') { inputs[i].value = expiry; continue; }   if (inputs[i].name == 'wpBlockReason') { inputs[i].value = reason; continue; }   if (inputs[i].name == 'wpAnonOnly') { if (ao==1) { inputs[i].checked = 'checked'; }     continue; }   if (inputs[i].name == 'wpEnableAutoblock') { if (autob==0) { inputs[i].checked=false; }     continue; }   if (inputs[i].name == 'wpCreateAccount') { if (ab==0) { inputs[i].checked=false; }     continue; } }  blockForm.submit; }

$(function{ if (document.title.indexOf("Block user") == -1) return;  user = document.getElementById('mw-bi-target').value;  var tabs = document.getElementById('p-cactions').getElementsByTagName('ul')[0];  var isAOL = AOLNetworks.some( function( net ) { return isInNetwork( user, net ) } );  mw.util.addPortletLink('p-cactions','javascript:('+QuickBlock+')("indefinite","",0,0,0)','user...','p-block-user')  mw.util.addPortletLink('p-cactions','javascript:('+QuickBlock+')("indefinite","",1,1,1)','(AB) user...','p-block-b-user')  mw.util.addPortletLink('p-cactions','javascript:('+QuickBlock+')("indefinite","Vandalism account",0,0,1)','vandalism','p-block-vandalism')  addlimenu(tabs, 'indef', 'p-m-indefs');  mw.util.addPortletLink('p-m-indefs','javascript:('+QuickBlock+')("indefinite","Please see WP:USERNAME - no accounts promoting companies/websites.",0,0,0)','promo','p-block-promo')  mw.util.addPortletLink('p-m-indefs','javascript:('+QuickBlock+')("indefinite","Oompapa sock",1,1,1)','oompapa','p-block-oompapa') mw.util.addPortletLink('p-m-indefs','javascript:('+QuickBlock+')("indefinite","",0,0,0)','open proxy','p-block-proxy') if (isAOL) { mw.util.addPortletLink('p-cactions','javascript:('+QuickBlock+')("1 hour","",1,0,0)','AOL (1h)','p-block-AOL-1h') } else { mw.util.addPortletLink('p-cactions','javascript:('+QuickBlock+')("31 hours","",1,0,1)','vandalism (31h)','p-block-31h') addlimenu(tabs, 'anon', 'p-m-anonblocks'); mw.util.addPortletLink('p-m-anonblocks','javascript:('+QuickBlock+')("3 hours","",1,1,0)','school (3h)','p-block-school') mw.util.addPortletLink('p-m-anonblocks','javascript:('+QuickBlock+')("3 hours","",1,0,1)','vandalism (3h)','p-block-3h') mw.util.addPortletLink('p-m-anonblocks','javascript:('+QuickBlock+')("1 week","Repeated vandalism",1,0,1)','One week','p-block-week'); mw.util.addPortletLink('p-m-anonblocks','javascript:('+QuickBlock+')("1 month","Chronic vandalism",1,0,1)','One month','p-block-month'); } });

//////// BIG BLOCK BUTTON $(function {  pagetitleH1 = document.getElementById('content').getElementsByTagName('h1')[0]  pagetitle = pagetitleH1.firstChild.data;  blockip = document.getElementById('t-blockip');  if (blockip) {    blockButton = document.createElement('a');    blockButton.href = blockip.firstChild.href;    blockButton.style.color = "red";    blockButton.appendChild(document.createTextNode('BLOCK'));    pagetitleH1.appendChild(document.createTextNode(' (')); pagetitleH1.appendChild(blockButton); pagetitleH1.appendChild(document.createTextNode(')')); } });

//