Is there anyway to make a javascript/dhtml ticker (like a stock price ticker) jump to a specific position with Javascript based on an argument. I'm using the following code for my ticker.
/*************************
**********
**********
**
* Cross browser Marquee II- © Dynamic Drive (
www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit
http://www.dynamicdrive.com/ for this script and 100s more.
**************************
**********
**********
*/
var delayb4scroll=2000 //Specify initial delay before marquee starts to scroll on page (2000=2 seconds)
var marqueespeed=2.5 //Specify marquee scroll speed (larger is faster 1-10)
var pauseit=1 //Pause marquee onMousever (0=no. 1=yes)?
////NO NEED TO EDIT BELOW THIS LINE////////////
var copyspeed=marqueespeed
var pausespeed=(pauseit==0)? copyspeed: 0
var actualwidth=''
function scrollmarquee() {
if (parseInt(cross_marquee.st
yle.left)>
(actualwid
th*(-1)+8)
)
cross_marquee.style.left=p
arseInt(cr
oss_marque
e.style.le
ft)-copysp
eed+"px"
else
cross_marquee.style.left=p
arseInt(ma
rqueewidth
)+8+"px"
}
function initializemarquee(){
cross_marquee=document.get
ElementByI
d("vmarque
e")
cross_marquee.style.left=0
marqueewidth=document.getE
lementById
("marqueec
ontainer")
.offsetWid
th
actualwidth=cross_marquee.
offsetWidt
h
if (window.opera || navigator.userAgent.indexO
f("Netscap
e/7")!=-1)
{ //if Opera or Netscape 7x, add scrollbars to scroll and exit
cross_marquee.style.width=
marqueewid
th+"px"
cross_marquee.style.overfl
ow="scroll
"
return
}
setTimeout('lefttime=setIn
terval("sc
rollmarque
e()",30)',
delayb4scroll)
}
if (window.addEventListener)
window.addEventListener("l
oad", initializemarquee, false)
else if (window.attachEvent)
window.attachEvent("onload
", initializemarquee)
else if (document.getElementById)
window.onload=initializema
rquee