Jump to content
xisto Community
Sign in to follow this  
wannabeeaweak

Javascript To Shake Your Screen Like Earthquake

Recommended Posts

here is ascript that will allow your visitors when they click there screen shakes like an earth quake. input this some where inside of <body> </body>

<script language=JavaScript1.2><!-- /*Get the best java scripts at[url=http://sites.move.to]http://sites.move.to[/url]*/function shakem(n) {   if (self.moveBy) {	for (i = 15; i > 0; i--) {    for (j = n; j > 0; j--) {  self.moveBy(0,i);  self.moveBy(i,0);  self.moveBy(0,-i);  self.moveBy(-i,0);           }       }   }}// End --></SCRIPT><script language=JavaScript1.2><!-- function shakef(n) {   if (self.moveBy) {	for (i = 30; i > 0; i--) {    for (j = n; j > 0; j--) {  self.moveBy(0,i);  self.moveBy(i,0);  self.moveBy(0,-i);  self.moveBy(-i,0);           }       }   }}// End --></SCRIPT><center><form><input onclick=shakem(3) type=button value="Start Earthquake"> </form></center>

Edited by microscopic^earthling (see edit history)

Share this post


Link to post
Share on other sites

That's cool and all that JavaScript is able to make the screen shake, but if it happened over and over again it would become very annoying and may make people not want to visit your site as frequently. It would become a hassle to watch the screen shake each time it was triggered.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.