Path:
Home
/
Home Page
/
Beispiele
/ Java-Script
Blinkende Links:
Beispiel für blinkende
Links
!!!
Quelltext
<script language="JavaScript"> if(navigator.userAgent.indexOf("Mac")>-1) MAC=true; else MAC=false; document.onmouseover = light document.onmouseout = dark pulseInterval = null pulseElement = null pulsePosition = 0 pulseColorText = new Array( "#6699cc", "#72a1d0", "#7ea9d4", "#8ab1d8", "#96b9dc", "#a2c1e0", "#aec9e4", "#bad1e8", "#c6d9ec", "#d2e1f0", "#dee9f4", "#d2e1f0", "#c6d9ec", "#bad1e8", "#aec9e4", "#a2c1e0", "#96b9dc", "#8ab1d8", "#7ea9d4", "#72a1d0" ) function light(e) { if(event.srcElement.tagName=="A") { pulseElement = event.srcElement pulseElement.style.color = "#ff0000" pulseInterval = setInterval("pulse()",50) } } function dark(e) { if(event.srcElement.tagName=="A") { clearInterval(pulseInterval) if(MAC==true) { pulseElement.style.backgroundColor = "#000033" } else { pulseElement.style.removeAttribute("backgroundColor") } pulseElement.style.color = "#6699cc" pulsePosition = 0 } } function pulse() { //* pulseElement.style.backgroundColor = pulseColor[pulsePosition] *// pulseElement.style.color = pulseColorText[pulsePosition] pulsePosition++ if(pulsePosition==pulseColorText.length) pulsePosition = 0 } </script>
Webmaster >>
bis0uhr@gmx.at