PDA

View Full Version : Caching Issue



dsmes
May 24th, 2006, 11:26 PM
The following code works once in a G4 event script... but never again:

local url = "http://www.ssec.wisc.edu/localweather/ww.gif"
NetRemote.SetImageURL ("Warnings", url)Marcel was kind enough to explain that Girder loads a cached copy from the local explorer cache on subsequent calls to the script, which is why the image will never update. Is there a way to force G4 to ignore the cache and actually go to the url and update the image? Alternatively, can someone suggest a work-around?

danward79
May 25th, 2006, 01:14 AM
The following code works once in a G4 event script... but never again:

local url = "http://www.ssec.wisc.edu/localweather/ww.gif"
NetRemote.SetImageURL ("Warnings", url)Marcel was kind enough to explain that Girder loads a cached copy from the local explorer cache on subsequent calls to the script, which is why the image will never update. Is there a way to force G4 to ignore the cache and actually go to the url and update the image? Alternatively, can someone suggest a work-around?

try


NetRemote.SendImageFromURL("Warnings", url)

mhwlng
May 25th, 2006, 02:17 AM
try :

local url ="http://www.ssec.wisc.edu/localweather/ww.gif?yyy="..os.time().."&xxx=.gif";
NetRemote.SetImageURL ("Warnings",url);


Marcel

dsmes
May 25th, 2006, 07:25 AM
Thanks Marcel. I didn't know you could universally apply your os.time() trick to any url. Now I do, and it works great!