I have a few functions on my site that update my database using $.post. These all work fine in firefox but not at all in internet explorer and i cant seem to work out why i have put the functions below:
Function 1:
function removeAd(ad_id) {
$.post('remove.php', {
id: ad_id
}, function() {
$('.workarea').load('display.php');
});
};
Function 2:
$(document).ready(function() {
$('a#addBanner').click(function() {
$.post('add.php', {
task: 'banner'
}, function() {
$('.workarea').load('display.php');
});
});
});
Function 3:
$(document).ready(function() {
$(function() {
$("#categoryorder").sortable({
opacity: 0.6,
cursor: 'move',
update: function() {
var order = $(this).sortable("serialize") + '&action=updateRecordsListings';
$.post("update.php", order)
}
});
});
});
Does anyone know why these would work in Firefox but not in IE. I quite new to this and debugging isn’t something I’m great at yet so any help would be much appreciated
IE has caching issues with ajax requests. Try using
Or adding a parameter so IE will think it’s a new page and not get it from cache