IE9 and jQuery AJAX problem .... "The first time it works well if I click the button, but the second time it does not ... I assume the cache" I have jquery https://ajax.googleapis.com/ ajax / libs / jquery / 1.4.4 / jquery.min.js And a simple ajax call:
$('#isvalidcompany').click(function(event) { var image = $('#isvalidcompany_img'); var old_state = image.attr('src'); image.attr('src', '/images/loading.gif'); $.getJSON('/ajax/change', function(data) { if (data['error'] != '') { image.attr('src', old_state); $('#isvalidcompany_error').html(data['error']); } else { if (data['isvalidcompany'] == 1) { image.attr('src', '/icons/tick_16.png'); } else { image.attr('src', '/icons/delete_16.png'); } } }); return false; });
And it works well on all browsers except ie9 and ie8 and ie7 Therefore, if anyone has experience, please share :)
source share