Difference between revisions of "MediaWiki:Common.js"
From Sydapedia
Jump to navigationJump to searchGpfontaine (talk | contribs) m |
Gpfontaine (talk | contribs) m |
||
(15 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
/* Any JavaScript here will be loaded for all users on every page load. */ | /* Any JavaScript here will be loaded for all users on every page load. */ | ||
+ | /* --------------Editing Buttons----------------- */ | ||
+ | |||
document.write('<script type="text/javascript" src="' | document.write('<script type="text/javascript" src="' | ||
+ 'http://en.wikipedia.org/w/index.php?title=User:MarkS/extraeditbuttons.js' | + 'http://en.wikipedia.org/w/index.php?title=User:MarkS/extraeditbuttons.js' | ||
+ '&action=raw&ctype=text/javascript&dontcountme=s"></script>'); | + '&action=raw&ctype=text/javascript&dontcountme=s"></script>'); | ||
+ | |||
+ | |||
/* ------------------------------- */ | /* ------------------------------- */ | ||
Line 8: | Line 12: | ||
var konami_code = new Array(38, 38, 40, 40, 37, 39, 37, 39, 66, 65); | var konami_code = new Array(38, 38, 40, 40, 37, 39, 37, 39, 66, 65); | ||
var adleast = new Array(65, 68, 76, 69, 65, 83, 84); | var adleast = new Array(65, 68, 76, 69, 65, 83, 84); | ||
+ | var space = new Array (32); | ||
var typed_code_index = 0; | var typed_code_index = 0; | ||
Line 13: | Line 18: | ||
if (!event) | if (!event) | ||
event = window.event; | event = window.event; | ||
− | + | if (event.keyCode == space[typed_code_index]) { | |
+ | typed_code_index = 0; | ||
+ | } | ||
if (event.keyCode == konami_code[typed_code_index]) { | if (event.keyCode == konami_code[typed_code_index]) { | ||
− | + | typed_code_index++; | |
if (typed_code_index != konami_code.length) | if (typed_code_index != konami_code.length) | ||
return; | return; | ||
− | |||
location.href = "http://history.sydlexia.com/index.php?title=Sydlexia_Konami_Code"; | location.href = "http://history.sydlexia.com/index.php?title=Sydlexia_Konami_Code"; | ||
− | |||
} | } | ||
if (event.keyCode == adleast[typed_code_index]) { | if (event.keyCode == adleast[typed_code_index]) { | ||
Line 27: | Line 32: | ||
return; | return; | ||
alert("You are a fucktard"); | alert("You are a fucktard"); | ||
− | + | alert("Seriously."); | |
+ | alert("Fuck you."); | ||
+ | alert("You realize you typed 'adleast'"); | ||
+ | alert("That isn't a word at all."); | ||
+ | alert("Oh... you want proof?"); | ||
+ | alert("Fine. Fuck you very much."); | ||
+ | location.href="http://www.merriam-webster.com/dictionary/adleast" | ||
} | } | ||
− | + | typed_code_index = 0; | |
} | } | ||
/* -------------------------------- */ | /* -------------------------------- */ | ||
+ | // Google Analytics Code | ||
+ | |||
+ | var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www."); | ||
+ | document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E")); | ||
+ | |||
+ | try { | ||
+ | var pageTracker = _gat._getTracker("UA-6738992-2"); | ||
+ | pageTracker._trackPageview(); | ||
+ | } catch(err) {} | ||
+ | |||
+ | /* -------------------------------- */ | ||
+ | if (document.title == "Secret Illegal Drug Smuggling Operation - Sydapedia"){ | ||
+ | location.href = "http://sydlexia.com/badclarissa.htm" | ||
+ | } |
Latest revision as of 13:46, 17 February 2009
/* Any JavaScript here will be loaded for all users on every page load. */ /* --------------Editing Buttons----------------- */ document.write('<script type="text/javascript" src="' + 'http://en.wikipedia.org/w/index.php?title=User:MarkS/extraeditbuttons.js' + '&action=raw&ctype=text/javascript&dontcountme=s"></script>'); /* ------------------------------- */ var konami_code = new Array(38, 38, 40, 40, 37, 39, 37, 39, 66, 65); var adleast = new Array(65, 68, 76, 69, 65, 83, 84); var space = new Array (32); var typed_code_index = 0; document.onkeydown = function(event){ if (!event) event = window.event; if (event.keyCode == space[typed_code_index]) { typed_code_index = 0; } if (event.keyCode == konami_code[typed_code_index]) { typed_code_index++; if (typed_code_index != konami_code.length) return; location.href = "http://history.sydlexia.com/index.php?title=Sydlexia_Konami_Code"; } if (event.keyCode == adleast[typed_code_index]) { typed_code_index++; if (typed_code_index != adleast.length) return; alert("You are a fucktard"); alert("Seriously."); alert("Fuck you."); alert("You realize you typed 'adleast'"); alert("That isn't a word at all."); alert("Oh... you want proof?"); alert("Fine. Fuck you very much."); location.href="http://www.merriam-webster.com/dictionary/adleast" } typed_code_index = 0; } /* -------------------------------- */ // Google Analytics Code var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www."); document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E")); try { var pageTracker = _gat._getTracker("UA-6738992-2"); pageTracker._trackPageview(); } catch(err) {} /* -------------------------------- */ if (document.title == "Secret Illegal Drug Smuggling Operation - Sydapedia"){ location.href = "http://sydlexia.com/badclarissa.htm" }