Topic: gallery.xml not refreshing

hi, I installed autoviewer pro and I'm generating my gallery.xml files in different subdirectories thanks to some php methods, retrieving stuff from databases, etc etc... the thing here is that my customer wants to constantly add and remove pictures from the different works he's exposing on the site ( not a problem at the time of generating the gallery.xml file or anything.

the issue comes at the time of loading it. autoviewer.swf will invoke gallery.xml regularly, but the thing is that this is an old, cached version... so whenever a user is coming back to the site, they'll probably see an "X" where an image has been deleted from the site, and the new pictures will not be showing up since his/her browser will still read the cached gallery.xml file.

is there any way to guarantee that, for every time the swf file calls the xml, it checks that it's actually the most recent version instead of a cached copy?

you can check the source of an example work right here:



Re: gallery.xml not refreshing

The only guaranteed way that I can think of is asking your users to clear their browser's cache. You could try the following <META HTTP-EQUIV="Pragma" CONTENT="no-cache">, but I don't know how well it will be respected by the browsers. You could also try something like "gallery.xml" + "?nocache=" + new Date().getTime().

Mike Richards
SimpleViewer Support Team.

Re: gallery.xml not refreshing

thanks a lot for the quick reply. will give it a try.