Marquee HTML Code Example to Pause onmouseover in Middle

Marquee HTML Code Example to Pause onmouseover

Today i have been trying hard to create a marquee which can be paused when we take the cursor over it. However it took me an hour to do so but in the end the answer was very simple. I am sharing it with you now.
Code:
<marquee behavior="scroll" direction="left" onmouseover="this.stop();" onmouseout="this.start();">It will pause onMouseOver</marquee>
Result:
It will pause onMouseOver
When you will take your mouse over the scrolling text, it will pause there and when you take it out, it will resume. This functionality is provided by two events : onmouseover and onmouseout.
This code looks very simple but you can use it in very interesting style. Inspite of writing the text inside marquee, you can put some images or some links to give a good look to your website. I will show you one such example below.
---------------------------------
These two images also have two hyperlinks on them. Thus marquee can be used in a much interesting ways. Play with it and you will find much interesting things in it.
Share this Article :
Email

No comments:

Post a Comment