[thelist] JavaScript rollover problem in IE4,5
aardvark
roselli at earthlink.net
Wed, 11 Aug 1999 16:25:26 -0400
http://roselli.org/adrian/temp/rollover.asp
since my gallery is getting so big, and since i want to keep image
load down, i'm trying to break out my arrows into one re-usable
rollover, and over and over...
works fine in NN3,4...
in IE4,5:
'document[...]' is not an object
offending code (watch for wrap):
<SCRIPT LANGUAGE = "JavaScript">
<!--
if (document.images) {
on = new Image();
on.src = "b_arrow_on.gif";
off = new Image();
off.src = "b_arrow_off.gif";
}
function rotate(state,imageName) {
if (document.images) {
document[imageName].src = eval(state + ".src");
}
}
// -->
</SCRIPT>