title: session_destroy() Not working at all
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/13849215/login-system-on-wamp">Login System on WAMP</a>  </p>
  </blockquote>
  
  
  
  <p>I recently switched my website files from a different server to my localhost on WAMP server. Everything worked fine on the other server, but on thise server, all the login php session code is messed up.]</p>
  
  <p>For Example:</p>
  
  <pre><code>&lt;?php 
  session_start();
  session_destroy();
  header('Location:login.php');
  ?&gt;
  </code></pre>
  
  <p>That is the logout code, and it used to work fine on the other server, but now, it doesnt even Destroy the session variable. I know because, once i clicked logout it is supposed ot bring me back to the login page, but it just stays at the same page, because this is at the top of the login page...</p>
  
  <pre><code>if(!session_start('mypassword')){
      /*If No session registered go here*/
  } else {
      header("location:login_success.php");
  }
  </code></pre>
  
  <p>And it still says the session is registered, even after i logged out.
  Please help, im new at this, and help would be greatly appreciated, thanks.</p>