First let me say, if I am posting this in the wrong location, please disregard.
I am trying to change a javascript on my web page, but i have to admit i have never done anything with java before. I had a guy publish this site [url]www.gototodd.com
Anyway, if anyone can help me with something that seems simple enough, but i can’t seem to figure out.
The scroll box on the left side scrolls up and i would like to change it to scroll down.
Any help would be greatly appreciated.
Here is the script:
<!– Begin
var contentobj = null;
var contentheight = null;
var iens6=document.all||document.getElementById
var ns4=document.layers
var scrollspeed = 30
function GetObj(name) {
if (document.getElementById) return document.getElementById(name);
else if (document.all) return document.all[name];
else if (document.layers) return document.layers[name];
return null;
}
function scrollup() {
if (contentobj == null) getcontent_height();
if(window.scrolltimerdown) clearTimeout(scrolltimerdown);
if(iens6) {
if (parseInt(contentobj.style.top)>=(contentheight*(-1)+100)) {
contentobj.style.top=parseInt(contentobj.style.top)-step
}
else {
shifttotop()
}
}
else {
if(ns4) {
if (contentobj.top>=(contentheight*(-1)+100)) {
contentobj.top-=step
}
else {
shifttotop()
}
}
}
scrolltimerdown = setTimeout(“scrollup()”,scrollspeed)
}
<!– function to stop all scroll timers –>
function stopall() {
if(window.scrolltimerup) clearTimeout(scrolltimerup);
if(window.scrolltimerdown) clearTimeout(scrolltimerdown);
}
<!– function that shifts the object to top –>
function shifttotop(){
stopall();
if (iens6) contentobj.style.top = 0;
else contentobj.top=0;
}
function getcontent_height(){
if (iens6) {
contentobj = GetObj(“content”);
contentheight = contentobj.offsetHeight
}
}
window.onload=scrollup
// End –>