Monday, 27 April 2015

Ajax data not getting updated in IE

Again an issue with Ajax and JSON in IE. I was working on an application that needs the updated data to be rendered once every minute. Everything works good in Firefox and Chrome. But again IE, only the first result set was getting rendered and the subsequent ajax calls data wasn't fetching the updated one. When explored on this issue, we found it was a caching problem. I did try adding a timer to the ajax call URL so that every call is unique but that did not work either. Then tried the attribute - {cache: "false"}and it started working :) There are scenarios where changing the url by just appending some additional unique parameter to the url everytime worked in IE but there could be an issue with cache and setting the cache attribute to false helps!! :)

No comments:

Post a Comment