Hi, I have a script that looks like this :
<script type='text/javascript'>
$(document).ready(function(){
setInterval(function() {
$.ajax({
url: "../Ps/th.php",
ifModified:true,
success: function(data, textStatus){
if(textStatus!="notmodified") {
$("#display").append(data);
alert(textStatus);
}
}});
},1000);
});
</script>
and corresponding php is just this :
<?php
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT, true, 304");
echo "shrinath<br>";
?>
the ifModified header seems to be not working as documented (known bug/whatever).
How do i make sure that the ajax doesn't append the data if it is not changed ?