| JQuery AJAX only loading once in IE
|
tsisson

msg:4377148 | 4:23 pm on Oct 20, 2011 (gmt 0) | I am having an issue with the following code only loading once in IE, it loads fine repeatedly in Chrome, FF, and safari. If anyone has any suggestions I would greatly appreciate it: <script type="text/javascript"> var c=0; setInterval(function() { $.ajax({ type: "GET", url: 'randomize.php', success: function(data) { $('#dispeople').html(data); } }); },2000); </script>
|
Fotiman

msg:4377162 | 4:55 pm on Oct 20, 2011 (gmt 0) | You're probably getting a cached version in IE. Add some dynamic value to the URL to prevent it from caching. url: 'randomize.php?ck=' + (new Date()).getTime(),
|
tsisson

msg:4377247 | 6:38 pm on Oct 20, 2011 (gmt 0) | Thanks for the suggestion, i tried that along with adding this above the JQuery: $.ajaxSetup ({ // Disable caching of AJAX responses cache: false }); and am still experiencing the same issue, any other thoughts?
|
tsisson

msg:4377249 | 6:38 pm on Oct 20, 2011 (gmt 0) | So now i have this for the entire code block: <script type="text/javascript"> var c=0; $.ajaxSetup ({ // Disable caching of AJAX responses cache: false }); setInterval(function() { $.ajax({ type: "GET", url: 'randomize.php?ck=' + (new Date()).getTime(), success: function(data) { // data is ur summary $('#dispeople').html(data); } }); },2000); </script>
|
|
|