You are here: irt.org | FAQ | JavaScript | Image | Q1357 [ previous next ]
Do not specify the image dimensions. Change:
<script language="JavaScript"><!-- if (document.images) { name1on = new Image(100,100); name1on.src = 'name1on.gif'; name1off = new Image(100,100); name1off.src = 'name1off.gif'; } //--></script>
with:
<script language="JavaScript"><!-- if (document.images) { name1on = new Image(); name1on.src = 'name1on.gif'; name1off = new Image(); name1off.src = 'name1off.gif'; } //--></script>