New Improved Right Click Shake
+2
zarapotpoto3
lovebang01
6 posters
Page 1 of 1
New Improved Right Click Shake
change A to img if u only want the image to move
- makes ur primary pic .. photo gallery... comment pic and friendlist shake
other version using math
Credits on Unskilled.forumotion.com
- makes ur primary pic .. photo gallery... comment pic and friendlist shake
- Code:
/**********************************/
/* Submitted: by: Admer */
/**********************************/
function shake(){br=document.getElementsByTagName("A");
for(bage=0;bage<br.length;bage++){br[bage].style.position="relative";
br[bage].onmouseover=function(){shakeit(this);qkie();}
br[bage].onmouseout=function(){newPosition(this);top.focus();}}}
attachOnLoadHandler(shake);sa=0;pimp=1;
function shakeit(go){sa=0;my=go;
my.style.left=0;my.style.top=0;}function qkie(){if(sa==1){return;}
if(pimp==1){my.style.top=parseInt(my.style.top)+3;pimp++;}
else if(pimp==2){my.style.left=parseInt(my.style.left)+3;pimp++;}
else if(pimp==3){my.style.top=parseInt(my.style.top)-3;pimp++;}
else{my.style.left=parseInt(my.style.left)-3;pimp=1;}
setTimeout(qkie,50)}function newPosition(go){
sa=1;go.style.left=0;go.style.top=0;}
other version using math
- Code:
/**************************************************/
/* Image shake - Friendster Tweaks */
/* by: Archer - www.unskkilled.forumotion.com */
/* adjust the value of speed and radius */
/**************************************************/
pics = document.getElementsByTagName('img')
FF = "Netscape"
IE = "Microsoft Interner Explorer"
radius=8
speed=5
a = 0
function tagAllPics(){
for(x=0; x<pics.length;x++){
if(navigator.appName==FF){
pics[x].setAttribute("onmouseover","tagX("+x+")")
pics[x].setAttribute("onmouseout","tagY("+x+")")
}
else{
psrc = pics[x].getAttribute("src")
pid = pics[x].getAttribute("id")
pcls = pics[x].getAttribute("class")
pics[x].outerHTML=
"<img id="+pid+" class="+pcls+" src="+psrc+
" onmouseover=tagX("+x+") onmouseout=tagY("+x+")>"}
}
}
function tagX(x){
pics[x].style.position="relative"
moveIt = setInterval("orbit("+x+")",5)
}
function tagY(x){
pics[x].style.top = "0"
pics[x].style.left= "0"
window.clearInterval(moveIt)
}
function orbit(x){
pics[x].style.top= radius*Math.cos(a/speed)
pics[x].style.left=radius*Math.sin(a/speed)
a++;}
setTimeout("tagAllPics()", 1000)
Credits on Unskilled.forumotion.com
Re: New Improved Right Click Shake
any preview?
anyway tnx for sharing.
anyway tnx for sharing.
XED- Global Moderator
-
Posts : 6137
Age : 114
Joined date : 2009-10-22
Location : sa bag mo :]]
Cash : 32112
Re: New Improved Right Click Shake
This is NOT right click code tricks.....
this is onmouseover image shake tricks....
@ topic starter kindly modify your topic..
this is onmouseover image shake tricks....
@ topic starter kindly modify your topic..
Marz- DPC Whiz
-
Posts : 2030
Joined date : 2009-10-17
Location : .
Cash : 242451441
Re: New Improved Right Click Shake
i've been browsing this forum and I noticed that most of the codes posted by the thread starter belonged to someone I know and I was just wondering how come the author was another person?
the code mentioned submitted by Admer was an original code of dynamic drive modified by Angell de Ville to target any object in the page...
the code mentioned submitted by Admer was an original code of dynamic drive modified by Angell de Ville to target any object in the page...
Энджелл Виллем де- Guest
-
Posts : 5
Age : 113
Joined date : 2009-11-14
Location :
Cash : 27440
Re: New Improved Right Click Shake
hmmmm . dynamic drive . maybe you're right . idk .
@TS , thanks for this.
@TS , thanks for this.
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum