Hi friends i create a webpage in that i use session variables , when i click logout i clear the session variables using ajax , it working fine in IE , But when i use firefox sometimes the session is not destroyed , the code i used to clear session is [when i click logout button]
function floadhomepage(){
ajaxFunction();
//alert('Logout clicked');
window.location.replace("index.php");
}
function ajaxFunction()
var xmlhttp;
if (window.XMLHttpRequest){
// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}
else if (window.ActiveXObject){
// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
else {
alert("Your browser does not support XMLHTTP!");
}
xmlhttp.onreadystatechange=function(){
}
xmlhttp.open("GET","logout.php",true);
xmlhttp.send(null);
}
in logout.php file contain the folowing code
<?php
session_start();
session_destroy();
unset($_Session['session variable name']);
?>
Please guide me to find the solution Thanks in advance..