AppointmentsList contains the elements I am loading. It is pretty simple.
After one day of refreshing the broswer IE8 (but I've tried with other browsers and the problem is still there) loads more than 800Mb of memory.
It seems that the empty() function "
$("#AppointmentsList").empty();
" cannot release the DOM elements.
Is there anyone else faced the same problems?
Regards
Alberto
$(document).ready(function() {
$('#loading').html("<img src='Images/bigloader.gif' />").hide();
ScheduledAction(LoadAppointments, -1, 1000);
});
function ScheduledAction(func, times, interval) {
var ID = window.setInterval(function() {
if (times > -1) {
if (--times <= 0)
window.clearInterval(ID);
}
func();
}, interval);
}
function LoadAppointments() {
$("#AppointmentsList").empty();
$('#loading').show();
$.get(UrlAction,
function(data) {
if (data != '') {
$('#AppointmentsList').append(data);
$('#loading').hide();
}
else {
$('#loading').fadeOut(3000);
}
});
}