dynamic listview
dynamic listview
The following code works with FF, IE8 and even Safari running on my mac
function getMineList() {
$('#mineGameList').html(""); // init the list of my games
userName = localStorage.getItem('userName');
$('#mineFormSignonID').val(userName);
$('#mineFormRequestType').val("myGames");
var data = $("#mineForm :input").serializeArray();
$.post($("#mineForm").attr('action'), data, function(json){
if(json != null) {
if (json.length > 0) {
var listData = '';
$.each(json,function() {
listData = '<li id="' + this.game_number + '"><a href="">' + this.game_start_time + ' ' + this.locationName + '</a></li>';
$('#mineGameList').append(listData);
});
$('#mineGameList').listview('refresh');
$("#mineStatusMsg").html("finishing getMineList " + new Date());
}
}
else {
$("#mineStatusMsg").html("get games attempt failed");
}
}, "json");
}
However on my iPad, the list never updates. In other words, at 8:00 am there may be three games available. Two hours later there might be five, but the listview still shows the original three games. If I go into Settings and clear "cookies and data" and the dynamic list will be current. Two hours later, same old data. Again, I only see this on my iPad and iPhone. I can see the display message after the ('refresh') so I know the code is being run.
Thanks in advance.
Rob