"Sketcher" <sk******@eircom.net> wrote in message
news:pH******************@news.indigo.ie...
Hi all,
I am looking to add the following scrolling marquee to my website (see
code below)
However instead of using the marquee methods [start | Stop] I want to use
[Up | Down]
and as a person rests their mouse on either word [up | down] the list will
scroll accordingly. I do not want the text to scroll continously - it
should only operate when the Up | Down feature is used.
Any ideas,
thanks.
Sketch.
<marquee id="scroller" direction=up width=100 height=100
style="background-color:#cccccc;border:0px">
Message 1<br>
Message 2<br>
Message 3<br>
Message 4<br>
Message 5<br>
Message 6<br>
Message 7<br>
</marquee><br>
<a href="javascript:scroller.start()">Start</a> | <a
href="javascript:scroller.stop()">Stop</a>
<script>
if (document.all)
scroller.stop()
</script>
"<MARQUEE ...> creates a scrolling display.
<MARQUEE ...> is an MSIE extension, but is now supported by NS 7."
http://www.htmlcodetutorial.com/_MARQUEE.html
The following works under IE5.5; watch for word-wrap:
<html>
<head>
<title>marquees.htm</title>
</head>
<body>
<marquee id="scroller" direction="up"
width="100" height="50"
style="background-color:#CCCCCC; border:1px solid">
<br> Message 1
<br> Message 2
<br> Message 3
<br> Message 4
<br> Message 5
<br> Message 6
<br> Message 7
</marquee>
<br>
<button onmouseover="scroll(0)"
onmouseout="scroller.stop()"
style="width:50">Up</button>
<button onmouseover="scroll(1)"
onmouseout="scroller.stop()"
style="width:50">Down</button>
<script type="text/javascript">
function scroll(what) {
var dirs = new Array("up", "down");
document.getElementById("scroller").direction = dirs[what];
scroller.start();
}
if (document.all) scroller.stop();
</script>
</body>
</html>