[thelist] XML files being cached

VOLKAN ÖZÇELİK volkan.ozcelik at gmail.com
Mon Feb 6 01:27:48 CST 2006


Internet Explorer (actually other browsers as well) has a nasty habit
of caching xml data.

The quick and dirty way to avoid it (assuming you are using some
javascript to get the xml)
could be assigning a unique (or random) querystring to your request:

...
myLovelyAjaxObject.get("http://path.to.my.xml.file.xml?r="+Math.rand());
...

If you want to ensure that the querysting is unique you may generate
and ID for it server-side.

HTH,
--
Volkan Ozcelik
+>Yep! I'm blogging! : http://www.volkanozcelik.com/volkanozcelik/blog/
+> My projects/studies/trials/errors : http://www.sarmal.com/



More information about the thelist mailing list