Hi, I am running into an issue of caching.
I have a jsp which generates the tree view from an XML file. This XML file are loaded when the jsp is loaded. So whenever I add new child to the tree view the xml file is updated by action class and the request reloads the jsp page which in turns reload that updated XML file. The issue is everytime it reloads the XML file, it gets from the temporary internet file which is not getting updated until I kill the browser and reload it. For example. For the first time, I have the xml file with content .Parent 1 ...Child 1 ...Child 12 ...Child 13 .Parent 2 ...Child 2 ...Child 21 When I call the action,to show tree then it calls the jsp file which loads the XML file and shows the jsp tree which works perfectly. Shows complete tree view based on XML file. Then I will add new child "Child 22" into ".Parent 2" then the action will be called and that action will update the XML file which is located into "../WEBINF/pages" and returns to the same jsp and reloads jsp which also needs to reloads the updated XML file. Now issue is , its not reloading that updated XML file and still showing the tree without newly added child. When I checked internet temporary files, it was still old XML file but at "../WEBINF/pages" location, the XML has been updated. So I figured out that it is an issue of caching. I tried to remove caching with http headers setting <% response.setHeader("Cache-Control","no-cache"); //HTTP 1.1 response.setHeader("Pragma","no-cache"); //HTTP 1.0 response.setDateHeader ("Expires", 0); //prevents caching at the proxy server %> Also tried with adding extra parameters to change the URL request. But still doen't work. Anyone has any suggestions, what to do next. Thanks for your help. Sorry.., If any typos or explained in too much detail. -- View this message in context: http://old.nabble.com/XML-file-reloading-in-JSP-%28Caching-issue%29-tp28657737p28657737.html Sent from the Struts - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org