zen of coding

User Auth with CakePHP 2.1 – part 3

As promised in the previous part we’ll take a look at the admin section. If you remember, we’ve setup our users so that when they create an account, they are inactive by default and cannot login into the app. app/Controller/AppController.php [cc lang=”php”] $this->Auth->authenticate = array( ‘all’ => array ( ‘scope’[…]

Read More »

User Auth with CakePHP 2.1 – part 2

CakePHP 2.1 Now that we’ve completed our basic setup for Auth, let’s take a look at the User.php model… [cc lang=”php”] class User extends AppModel { public $validate = array( ‘username’ => array( array( ‘rule’ => ‘notEmpty’, ‘message’ => ‘Username cannot be empty’ ), array( ‘rule’ => ‘isUnique’, ‘message’ =>[…]

Read More »

User Auth with CakePHP 2.1 – part 1

CakePHP 2.1 The example application in the CakePHP book does a very good job of covering setup and implementation of a basic Auth system. Let’s continue building on that and cover a few other things, by adding a couple of more features and looking at some of the other things[…]

Read More »
%d bloggers like this: