// preload images for navigation//function loadImages() {    // ignore browsers without image array    if (document.images) {         // create on and off state objects in theImages for each member of theButtons        for(i = 0; i < theButtons.length; i++) {            theImages[theButtons[i]+"_on"] = new Image();            theImages[theButtons[i]+"_on"].src = theImagesPath + theButtons[i] + "_btn_on.gif";            theImages[theButtons[i]+"_off"] = new Image();            theImages[theButtons[i]+"_off"].src = theImagesPath + theButtons[i] + "_btn_off.gif";        }    }}function changeImage(imgName, state) {            // ignore browsers without image array            if (document.images && theImages[imgName +"_" + state]) {                document.images[imgName].src = theImages[imgName +"_" + state].src;}    }
