In my javascript I have some ajax requests $.getJSON({...})
for various actions. I have a php app that handles these ajax requests. Before processing the actual request, my app first checks the session and in the case the user hasn't logged in yet, it sends a refresh signal back. Something like:
if (not logged in) {
header('Refresh: 0;');
}
else {
//process request
}
But the client doesn't actually refresh. Is there something I'm missing when it comes to AJAX requests and the http refresh header?