Others

4 Evil Javascript Pranks for your Friends!

This time we’ll do something fun! We’ll be doing some pranks with javascript. Here are 4 pranks that I picked for you (some of them is pure evil) Be-warned, this could piss someone!

Bieber-nizer



Sneakup to your friend and add these 2 javascript lines to any script tag. It will turn all images on that page into Bieber’s.

Array.prototype.slice.call(document.querySelectorAll('img')).map(function(el){
  el.src = 'http://data.whicdn.com/images/208691316/large.jpg';
});

Greek Question mark

;

Replace one of your victim semi-colon with a Greek Questions Mark. It’s entirely different character but looks exactly the same as semi-colon. This will blew up the syntax and your friend will surely be frustrated to find out where

Image Freak

Copy and paste below to your friend’s dev console and watch all the images go wild!!

javascript:R=0; x1=.1; y1=.05; x2=.25; y2=.24; x3=1.6; y3=.24; x4=300; y4=200; x5=300; y5=200; DI=document.getElementsByTagName("img"); DIL=DI.length; function A(){for(i=0; i-DIL; i++){DIS=DI[ i ].style; DIS.position='absolute'; DIS.left=(Math.sin(R*x1+i*x2+x3)*x4+x5)+"px"; DIS.top=(Math.cos(R*y1+i*y2+y3)*y4+y5)+"px"}R++}setInterval('A()',5); void(0);

Fake Aw Snap! 

I personally love this one – Place below code into any script tag. Once your friend refresh the page, it will clear all html code and replace it with Chrome Aw Snap! page. Your friend will have no idea why his code crashed the Chrome.

setTimeout(function(){$('body').removeAttr('style').html('<img src="https://image.ibb.co/byWcEv/rtaImage.jpg">').css('text-align','center').css('margin','125px');},2500);

See all them live in action in our Youtube video. Or check out other interesting videos at our channel

Red Stapler Channel: https://www.youtube.com/c/RedStapler_channel

One comment

Leave a Reply

Your email address will not be published. Required fields are marked *

error: