transmat
09-09-2003, 01:53 PM
Please take a look at this example: http://www.mojamatize.com/swap/index_safari.html
After clicking the link, the text box will scroll into position and then the preload() function on line 27 is called. A new image is created (red.gif). Then the current image (blue.gif) is supposed to be replaced by that new image using the changeImage() function (on lines 18-24).
This works fine on (Mac) IE5 and on NS7 upon first activation and still works if you refresh the page..
On Safari however, the process only works upon opening a new window, not after repeated refreshes.
I've even checked the source of the image with javascript:alert(document['sp1'].src) in the address box and it tells me that the image is red.gif but blue.gif is still showing. No visible change.
Obviously it doesn't like the code or it's just a lazy browser. Any suggestions for helping it actually change to the red.gif?
thanks,
Brad
After clicking the link, the text box will scroll into position and then the preload() function on line 27 is called. A new image is created (red.gif). Then the current image (blue.gif) is supposed to be replaced by that new image using the changeImage() function (on lines 18-24).
This works fine on (Mac) IE5 and on NS7 upon first activation and still works if you refresh the page..
On Safari however, the process only works upon opening a new window, not after repeated refreshes.
I've even checked the source of the image with javascript:alert(document['sp1'].src) in the address box and it tells me that the image is red.gif but blue.gif is still showing. No visible change.
Obviously it doesn't like the code or it's just a lazy browser. Any suggestions for helping it actually change to the red.gif?
thanks,
Brad