Forum Moderators: open

Message Too Old, No Replies

scrolling text

scrolling text

         

krikri

1:38 am on Jan 31, 2004 (gmt 0)




I have a scrolling text below. Please where should I change the width of the display window. Currently, not all the text can be seen because the width of the window is too small. Your help is appreciated.

<html>
<head>
<style>
span
{
font:12px arial;
background:#CCCCCC;
position:absolute;
width:1200;
height:10;
top:100;
clip:rect(0 100 300 0);
}
</style>
<script type="text/javascript">
var interval
startPosition=0
topPosition=100
endPosition=100
speed=50

function scrollit()
{
if (startPosition!=200)
{
startPosition=startPosition+1
topPosition=topPosition-1
document.getElementById('display').style.clip="rect(" + (startPosition + 1) + " 100 " + (startPosition + endPosition) + " 0)"
document.getElementById('display').style.top=topPosition
interval=setTimeout("scrollit()",speed)
}
else
{
startPosition=0
topPosition=100
endPosition=100
interval=setTimeout("scrollit()",speed)
}
}

function stopinterval()
{
clearTimeout(interval)
}
</script>
</head>

<body onload="scrollit()" onunload="stopinterval()">
<span id="display"><br /><br /><br /><br /><br /><br /><br />
Thank you for choosing us.We hop to make great strides in the quest for better agricultural practices.
</span>
</body>
</html>

ORBiTrus

3:42 am on Jan 31, 2004 (gmt 0)

10+ Year Member



Well, I hop (sic) to help.

I think you need to change the 100.

It's all in that clip: rect (0 100 300 0) code... it's form is (top right bottom left)