I have an app that logs in via .htaccess. When the person wants to logout, I use:
function logout2() { try{
var agt=navigator.userAgent.toLowerCase(); if (agt.indexOf("msie") != -1) { // IE clear HTTP Authentication document.execCommand("ClearAuthenticationCache"); } else { var xmlhttp = createXMLObject(); xmlhttp.open("GET",".force_logout_offer_login_mozilla",true,"logout",""); xmlhttp.send(""); xmlhttp.abort(); } } catch(e) { alert("there was an error"); } function createXMLObject() { try { if (window.XMLHttpRequest) { xmlhttp =
new XMLHttpRequest(); } // code for IE else if (window.ActiveXObject) {
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
} } catch (e) { xmlhttp=false } return xmlhttp; }
The problem is that this is not working for Safari, the person is always logged in using the initial credentials, even closing and reopening the browser. Does anybody know how to handle this?