Skip to content

Instantly share code, notes, and snippets.

@alex-laties
Created December 26, 2013 03:53
Show Gist options
  • Save alex-laties/8129596 to your computer and use it in GitHub Desktop.
Save alex-laties/8129596 to your computer and use it in GitHub Desktop.
javascript:(function()%7Bfunction%20c()%7Bvar%20e%3Ddocument.createElement(%22link%22)%3Be.setAttribute(%22type%22,%22text/css%22)%3Be.setAttribute(%22rel%22,%22stylesheet%22)%3Be.setAttribute(%22href%22,f)%3Be.setAttribute(%22class%22,l)%3Bdocument.body.appendChild(e)%7Dfunction%20h()%7Bvar%20e%3Ddocument.getElementsByClassName(l)%3Bfor(var%20t%3D0%3Bt%3Ce.length%3Bt%2B%2B)%7Bdocument.body.removeChild(e%5Bt%5D)%7D%7Dfunction%20p()%7Bvar%20e%3Ddocument.createElement(%22div%22)%3Be.setAttribute(%22class%22,a)%3Bdocument.body.appendChild(e)%3BsetTimeout(function()%7Bdocument.body.removeChild(e)%7D,100)%7Dfunction%20d(e)%7Breturn%7Bheight:e.offsetHeight,width:e.offsetWidth%7D%7Dfunction%20v(i)%7Bvar%20s%3Dd(i)%3Breturn%20s.height%3Ee%26%26s.height%3Cn%26%26s.width%3Et%26%26s.width%3Cr%7Dfunction%20m(e)%7Bvar%20t%3De%3Bvar%20n%3D0%3Bwhile(!!t)%7Bn%2B%3Dt.offsetTop%3Bt%3Dt.offsetParent%7Dreturn%20n%7Dfunction%20g()%7Bvar%20e%3Ddocument.documentElement%3Bif(!!window.innerWidth)%7Breturn%20window.innerHeight%7Delse%20if(e%26%26!isNaN(e.clientHeight))%7Breturn%20e.clientHeight%7Dreturn%200%7Dfunction%20y()%7Bif(window.pageYOffset)%7Breturn%20window.pageYOffset%7Dreturn%20Math.max(document.documentElement.scrollTop,document.body.scrollTop)%7Dfunction%20E(e)%7Bvar%20t%3Dm(e)%3Breturn%20t%3E%3Dw%26%26t%3C%3Db%2Bw%7Dfunction%20S()%7Bvar%20e%3Ddocument.createElement(%22audio%22)%3Be.setAttribute(%22class%22,l)%3Be.src%3Di%3Be.loop%3Dfalse%3Be.addEventListener(%22canplay%22,function()%7BsetTimeout(function()%7Bx(k)%7D,500)%3BsetTimeout(function()%7BN()%3Bp()%3Bfor(var%20e%3D0%3Be%3CO.length%3Be%2B%2B)%7BT(O%5Be%5D)%7D%7D,15500)%7D,true)%3Be.addEventListener(%22ended%22,function()%7BN()%3Bh()%7D,true)%3Be.innerHTML%3D%22%20%3Cp%3EIf%20you%20are%20reading%20this,%20it%20is%20because%20your%20browser%20does%20not%20support%20the%20audio%20element.%20We%20recommend%20that%20you%20get%20a%20new%20browser.%3C/p%3E%20%3Cp%3E%22%3Bdocument.body.appendChild(e)%3Be.play()%7Dfunction%20x(e)%7Be.className%2B%3D%22%20%22%2Bs%2B%22%20%22%2Bo%7Dfunction%20T(e)%7Be.className%2B%3D%22%20%22%2Bs%2B%22%20%22%2Bu%5BMath.floor(Math.random()*u.length)%5D%7Dfunction%20N()%7Bvar%20e%3Ddocument.getElementsByClassName(s)%3Bvar%20t%3Dnew%20RegExp(%22%5C%5Cb%22%2Bs%2B%22%5C%5Cb%22)%3Bfor(var%20n%3D0%3Bn%3Ce.length%3B)%7Be%5Bn%5D.className%3De%5Bn%5D.className.replace(t,%22%22)%7D%7Dvar%20e%3D30%3Bvar%20t%3D30%3Bvar%20n%3D350%3Bvar%20r%3D350%3Bvar%20i%3D%22//s3.amazonaws.com/moovweb-marketing/playground/harlem-shake.mp3%22%3Bvar%20s%3D%22mw-harlem_shake_me%22%3Bvar%20o%3D%22im_first%22%3Bvar%20u%3D%5B%22im_drunk%22,%22im_baked%22,%22im_trippin%22,%22im_blown%22%5D%3Bvar%20a%3D%22mw-strobe_light%22%3Bvar%20f%3D%22//s3.amazonaws.com/moovweb-marketing/playground/harlem-shake-style.css%22%3Bvar%20l%3D%22mw_added_css%22%3Bvar%20b%3Dg()%3Bvar%20w%3Dy()%3Bvar%20C%3Ddocument.getElementsByTagName(%22*%22)%3Bvar%20k%3Dnull%3Bfor(var%20L%3D0%3BL%3CC.length%3BL%2B%2B)%7Bvar%20A%3DC%5BL%5D%3Bif(v(A))%7Bif(E(A))%7Bk%3DA%3Bbreak%7D%7D%7Dif(A%3D%3D%3Dnull)%7Bconsole.warn(%22Could%20not%20find%20a%20node%20of%20the%20right%20size.%20Please%20try%20a%20different%20page.%22)%3Breturn%7Dc()%3BS()%3Bvar%20O%3D%5B%5D%3Bfor(var%20L%3D0%3BL%3CC.length%3BL%2B%2B)%7Bvar%20A%3DC%5BL%5D%3Bif(v(A))%7BO.push(A)%7D%7D%7D)()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment