title: Login via ajax request only works on second try, fails on first
body: <p>I am sending an ajax request to a php login backend that varyfies the user and password, starts a session and sends a positive or negative response.</p>
  
  <p>The response is then translated to a user message by jquery and if the credentioals were correct, the user is redirected to the closed part of the site via </p>
  
  <p><code>window.location.href('mySecretSite.php')</code></p>
  
  <p>The problem is, that I am allways thrown back to the login site on first try of the browser session, because the next php script has no session and assumes the user is not logged in.</p>