PDA

View Full Version : Javascript that swirls the images around on a webpage



Clay_Banger
June 8th, 2007, 01:46 AM
i have seen it around, its a bunch of JavaScript code that when added on the the end of the url, plays around with all of the images on the webpage. Ive had a google for it, but i cant seem to find it.
anyone know what im talking about and where i could find it?

FuturePilot
June 8th, 2007, 01:50 AM
I know exactly what you're talking about. I'll be right back:p

FuturePilot
June 8th, 2007, 01:58 AM
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()',50); void(0);
There you go. Go back to the Cafe and try it. It's kind of funny. All the envelopes go flying around:D

Clay_Banger
June 8th, 2007, 01:59 AM
I know exactly what you're talking about. I'll be right back:p
Swweeeeeeet!:D

Clay_Banger
June 8th, 2007, 02:00 AM
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()',50); void(0);
There you go. Go back to the Cafe and try it. It's kind of funny. All the envelopes go flying around:D

Thats just what i wanted!! thanks!

FuturePilot
June 8th, 2007, 02:01 AM
Watch out for the flying thumb tacks :lolflag:

Clay_Banger
June 8th, 2007, 02:02 AM
nah, i think that paper cuts maybe more of a problem.. :smile:

knopper67
June 8th, 2007, 02:11 AM
This Sounds Interesting, How do I Make the Images fly around?

Clay_Banger
June 8th, 2007, 05:41 AM
This Sounds Interesting, How do I Make the Images fly around?
you visit a webpage, preferably one with lots of pictures on it, then in the url bar you remove what is in there and paste the javascript code above into it, and what the images swirl..

FuturePilot
June 8th, 2007, 05:53 AM
Make sure you hit Enter. Clicking the go button doesn't work. Took me forever to figure that out:p

RAV TUX
June 8th, 2007, 05:54 AM
Thanks this is really fun, know of any other java scripts?

screenshot:

RAV TUX
June 8th, 2007, 05:56 AM
Thanks this is really fun, know of any other java scripts?

screenshot:another screenshot

FuturePilot
June 8th, 2007, 05:59 AM
ROFL. Try this one. It makes your browser window go crazy:D My avatar has gone flying around:lolflag:

javascript:function Shw(n) {if (self.moveBy) {for (i = 35; i > 0; i--) {for (j = n; j > 0; j--) {self.moveBy(1,i) ;self.moveBy(i,0);self.moveBy(0,-i);self.moveBy(-i,0); } } }} Shw(6)

RAV TUX
June 8th, 2007, 06:01 AM
ROFL. Try this one. It makes your browser window go crazy:D My avatar has gone flying around:lolflag:

javascript:function Shw(n) {if (self.moveBy) {for (i = 35; i > 0; i--) {for (j = n; j > 0; j--) {self.moveBy(1,i) ;self.moveBy(i,0);self.moveBy(0,-i);self.moveBy(-i,0); } } }} Shw(6)

funny thanks I need one of those every once in a while. ;)

Clay_Banger
June 8th, 2007, 06:01 AM
ROFL. Try this one. It makes your browser window go crazy:D My avatar has gone flying around:lolflag:

javascript:function Shw(n) {if (self.moveBy) {for (i = 35; i > 0; i--) {for (j = n; j > 0; j--) {self.moveBy(1,i) ;self.moveBy(i,0);self.moveBy(0,-i);self.moveBy(-i,0); } } }} Shw(6)
just moves the window to the right a small bit... is it supposed to do something else?

RAV TUX
June 8th, 2007, 06:02 AM
just moves the window to the right a small bit... is it supposed to do something else?

should shake it up also

FuturePilot
June 8th, 2007, 06:03 AM
It should also make it vibrate like crazy.

Clay_Banger
June 8th, 2007, 06:04 AM
turned off beryl, it works now. :lolflag:

Dragonbite
June 8th, 2007, 02:33 PM
Oh, these are funny! Gotta see about fitting them into some of the websites I'm working one (for unsuspecting browsers ... ;) )