cosmic foo wrote:
I have noticed that when you set the src attribute of an img via script,
(instead of hard-coding in the img tag), although it caches the images,
if you leave the site and return, the browser has to re-cache the images.
no, I don't think it does re and re and re-cache same image ou same src
onload it always verify if image (even an image.src) is in its cache
just by scripting you realy ensure it does it and get a local source
then you can re-use src instead of url
-> shorter code and image from cache without mistake
(no need to call server (send requests existing img? date? and so one) )
--
Stephane Moriaux et son [moins] vieux Mac