Skip to content

Instantly share code, notes, and snippets.

@dwiyatci
Last active April 22, 2016 15:12
Show Gist options
  • Save dwiyatci/01eafdfab60b5f45c396af6ffef2dc03 to your computer and use it in GitHub Desktop.
Save dwiyatci/01eafdfab60b5f45c396af6ffef2dc03 to your computer and use it in GitHub Desktop.
javascript:void function()%7B(function()%7Bfunction e()%7Bvar e%3Ddocument.createElement("link")%3Be.setAttribute("type","text/css"),e.setAttribute("rel","stylesheet"),e.setAttribute("href",T),e.setAttribute("class",A),document.body.appendChild(e)%7Dfunction t()%7Bfor(var e%3Ddocument.getElementsByClassName(A),t%3D0%3Bt<e.length%3Bt%2B%2B)document.body.removeChild(e%5Bt%5D)%7Dfunction n()%7Bvar e%3Ddocument.createElement("div")%3Be.setAttribute("class",C),document.body.appendChild(e),setTimeout(function()%7Bdocument.body.removeChild(e)%7D,100)%7Dfunction o(e)%7Breturn%7Bheight:e.offsetHeight,width:e.offsetWidth%7D%7Dfunction a(e)%7Bvar t%3Do(e)%3Breturn t.height>p%26%26t.height<b%26%26t.width>w%26%26t.width<v%7Dfunction r(e)%7Bfor(var t%3De,n%3D0%3Bt%3B)n%2B%3Dt.offsetTop,t%3Dt.offsetParent%3Breturn n%7Dfunction i()%7Bvar e%3Ddocument.documentElement%3Breturn window.innerWidth%3Fwindow.innerHeight:e%26%26!isNaN(e.clientHeight)%3Fe.clientHeight:0%7Dfunction s()%7Breturn window.pageYOffset%3Fwindow.pageYOffset:Math.max(document.documentElement.scrollTop,document.body.scrollTop)%7Dfunction m(e)%7Bvar t%3Dr(e)%3Breturn t>%3DB%26%26H%2BB>%3Dt%7Dfunction d()%7Bvar e%3Ddocument.createElement("audio")%3Be.setAttribute("class",A),e.src%3Dy,e.loop%3D!1%3Bvar o%3D!1,a%3D!1,r%3D!1%3Be.addEventListener("timeupdate",function()%7Bvar t,i%3De.currentTime,s%3DL,m%3Ds.length%3Bif(i>%3D.5%26%26!o%26%26(o%3D!0,u(z)),i>%3D15.5%26%26!a)for(a%3D!0,f(),n(),t%3D0%3Bm>t%3Bt%2B%2B)c(s%5Bt%5D)%3Be.currentTime>%3D28.4%26%26!r%26%26(r%3D!0,l())%7D,!0),e.addEventListener("ended",function()%7Bf(),t()%7D,!0),e.innerHTML%3D"<p>If you are reading this, it is because your browser does not support the audio element. We recommend that you get a new browser.</p>",document.body.appendChild(e),e.play()%7Dfunction u(e)%7Be.className%2B%3D" "%2BE%2B" "%2B_%7Dfunction c(e)%7Be.className%2B%3D" "%2BE%2B" "%2Bk%5BMath.floor(Math.random()*k.length)%5D%7Dfunction l()%7Bfor(var e%3Ddocument.getElementsByClassName(E),t%3D0%3Bt<e.length%3B)e%5Bt%5D.className%3De%5Bt%5D.className.replace(E,N)%3BE%3DN%7Dfunction f()%7Bfor(var e%3Ddocument.getElementsByClassName(E),t%3Dnew RegExp("%5C%5Cb"%2BE%2B"%5C%5Cb"),n%3D0%3Bn<e.length%3B)e%5Bn%5D.className%3De%5Bn%5D.className.replace(t,"")%7Dvar h,g,p%3D30,w%3D30,b%3D350,v%3D350,y%3D"//s3.amazonaws.com/moovweb-marketing/playground/harlem-shake.ogg",E%3D"mw-harlem_shake_me",N%3D"mw-harlem_shake_slow",_%3D"im_first",k%3D%5B"im_drunk","im_baked","im_trippin","im_blown"%5D,C%3D"mw-strobe_light",T%3D"//s3.amazonaws.com/moovweb-marketing/playground/harlem-shake-style.css",A%3D"mw_added_css",H%3Di(),B%3Ds(),M%3Ddocument.getElementsByTagName("*"),x%3DM.length,z%3Dnull%3Bfor(h%3D0%3Bx>h%3Bh%2B%2B)if(g%3DM%5Bh%5D,a(g)%26%26m(g))%7Bz%3Dg%3Bbreak%7Dif(null%3D%3D%3Dg)return void console.warn("Could not find a node of the right size. Please try a different page.")%3Be(),d()%3Bvar L%3D%5B%5D%3Bfor(h%3D0%3Bx>h%3Bh%2B%2B)g%3DM%5Bh%5D,a(g)%26%26L.push(g)%7D)()%7D()%3B
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment