Return to Snippet

Revision: 26900
at May 15, 2010 02:02 by sevennbsp


Initial Code
<?php
class AppController extends Controller {
    var $components = array('Auth');

    function beforeFilter() {
		$this->Auth->loginAction = array('controller' => 'users', 'action' => 'login');
        $this->Auth->logoutRedirect = array('controller' => 'users', 'action' => 'login');
        $this->Auth->loginRedirect = array('controller' => 'users', 'action' => 'index');
		$this->Auth->allow('*');
		$this->Auth->deny('delete','view','index');
    }
}
?>

Initial URL
http://www.jbcrawford.net/archives/45

Initial Description
this is the entire app_controller code with auth setup and use in it.

Initial Title
app_controller auth setup

Initial Tags
cakephp

Initial Language
PHP