Hi Webmasters, Please I need a mouseover effect on my website all pages like this website: http://www.cindyscakes.com/index.html I know it can be done in CSS file but I don't have much clues. Please help me. Thanks, ML.
You can try something like this... <!--**THIS CODE IS IN 3 SECTIONS!! SCROLL DOWN TO THE BOTTOM TO FIND INSTRUCTIONS.**--> <!--**DELETE THESE AND THE OTHER INSTRUCTION COMMENTS BEFORE PASTING**--> <!--**1 - PASTE THE FOLLOWING PIECE OF CODE INTO THE HEAD SECTION OF YOUR WEBPAGE**--> <style type="text/css"> <!-- .mouse { position:absolute; visibility:visible; top:-50px; font-size:8px; font-family:arial; color:black; } body { width:100%; overflow-x:hidden; overflow-y:scroll; } --> </style> <script> var x,y var step=20 var doit=0 var text="this is a test " text=text.split("") var xpos=new Array() for (i=0;i<=text.length-1;i++) { xpos[i]=-50 } var ypos=new Array() for (i=0;i<=text.length-1;i++) { ypos[i]=-50 } function anddo(e){ x = (document.layers) ? e.pageX : document.body.scrollLeft+event.clientX y = (document.layers) ? e.pageY : document.body.scrollTop+event.clientY doit=1 } function trail() { if (doit==1 && document.all) { for (i=text.length-1; i>=1; i--) { xpos[i]=xpos[i-1]+step ypos[i]=ypos[i-1] } xpos[0]=x+step ypos[0]=y for (i=0; i<text.length-1; i++) { var place = eval("span"+(i)+".style") place.posLeft=xpos[i] place.posTop=ypos[i] } } else if (doit==1 && document.layers) { for (i=text.length-1; i>=1; i--) { xpos[i]=xpos[i-1]+step ypos[i]=ypos[i-1] } xpos[0]=x+step ypos[0]=y for (i=0; i<text.length-1; i++) { var place = eval("document.span"+i) place.left=xpos[i] place.top=ypos[i] } } var timer=setTimeout("trail()",30) } </script> <!--**2 - PASTE THE FOLLOWING PIECE OF CODE INTO THE BODY SECTION OF YOUR WEBPAGE**--> <script> <!-- Beginning of JavaScript - for (i=0;i<=text.length-1;i++) { document.write("<span id='span"+i+"' class='mouse'>") document.write(text[i]) document.write("</span>") } if (document.layers){ document.captureEvents(Event.MOUSEMOVE); } document.onmousemove = anddo; // - End of JavaScript - --> </script> <!--**3 - USE THE FOLLOWING PIECE OF CODE AS THE BODY TAG OF YOUR WEBPAGE**--> <body onLoad="trail()"> Code (markup):
Hi webmaster,,, pls help me... I have some problem between Firefox and IE (internet browser) This css tag can view all in firefox browser li { font-family: Tahoma, "Times New Roman"; font-size: 14px; color: #732b91; list-style-image: url(img/bul.jpg); text-decoration: none; list-style-type: square; border-bottom-width: 0.5px; border-bottom-style: dashed; border-bottom-color: #707070; line-height: 22px; } li a { font-family: Tahoma, "Times New Roman"; font-size: 14px; color: #732b91; list-style-image: url(img/bul.jpg); text-decoration: none; } li a:hover { font-family: Tahoma, "Times New Roman"; font-size: 14px; color: #FFFFFF; list-style-image: url(img/bul.jpg); text-decoration: none; } But In IE browser This css tag cann't view in IE browser. So..i need ur help.if u have some free time, would you slove? i will wait ur helping.. thz so much
I copied everything in my websites hearder.php file but nothing worked. I am using wordpress in my website. Please have a look on the following code:
You might need to move that nasty nest of Javajunk to the bottom of your web page... possibly nothing is happening because the script tries to run before the element has been rendered. The reason why you often see javajunks near the bottom of the page. so <script javascript crap> </script> </body> </html> to show where is should sit. I dunno that that's the reason, but it's a good first guess, because it's a common javascript problem.
still not working friend. I was thinking that it doesn't matter where to put the code, after the body starts or before the body ends. Hope to get some more help here. thx for your efforts.
For Javascript it matters if the element it's supposed to be dicking with comes after the script reference. Generally, browsers load stuff from top of the HTML document to the bottom, so if it gets to script first, the script "loads" and tries to do its thing as fast as possible. Meanwhile the element the script is supposed to interact with hasn't been rendered by the browser yet. But I don't have more than a toe in JS now so I can't go any further with this.