title: CakePHP auth component redirects to login after logOUT
body: <p>I'm getting started with CakePHP and I'm having a problem setting up the Auth component. <strong>Every time a user logs out, cake is redirecting them back to login.</strong>
  You will see that I'm trying to delete/unset some cookies during logout(). This is because I'm setting up a single sign on with a Wordpress site, so I want the user to be logged out of both sites.</p>
  
  <p>My AppController:</p>
  
  <pre><code>class AppController extends Controller {    
  
  public $components = array(
      'Session',
      'Cookie',
      'Auth'      =&gt; array(
          'loginRedirect'     =&gt; array('controller' =&gt; 'questions', 'action' =&gt; 'index'), 
          'logoutRedirect'    =&gt; array('controller' =&gt; 'pages', 'action' =&gt; 'display', 'home')            
      )
  );
  public function beforeFilter() {
      $this-&gt;Auth-&gt;allow('index', 'view', 'login', 'logout', 'display');
  }
  }
  </code></pre>
  
  <p>UsersController:</p>
  
  <pre><code>class UsersController extends AppController {
  
  public function beforeFilter() {
      parent::beforeFilter();
      $this-&gt;Auth-&gt;allow('add', 'logout', 'login');
  }
  </code></pre>
  
  <p>...</p>
  
  <pre><code>public function login() {
  //who cares
  }
  
  public function logout() {
  
      $wp_cookie = grab_wp_cookie(); //this grabs a specific cookie
      $cookie_name = (isset($wp_cookie['name'])) ? $wp_cookie['name'] : NULL;
        //NONE OF THESE WORK...
      $this-&gt;Cookie-&gt;write($cookie_name, '', false, time()-3600);
      $this-&gt;Cookie-&gt;delete($cookie_name);
      $this-&gt;Cookie-&gt;destroy();
  
      $this-&gt;redirect($this-&gt;Auth-&gt;logout());
  }
  </code></pre>