G’day,
Setup: Windoze 7 Pro x64 SP1; Apache 2.4.23 (Win64); MySQL 5.7.15; PHP 7.0.11; CakePHP 2.9.1;
Which of the following compact versions below (2.a, 2.b, 2.c) are the correct way to define the fully specified version 1 in my UsersController.php?
Thanx, McS
public function initDB() { /* partial function listing */
/* allow moderators full access to all clients methods */
/* 1. fully specified version */
$group->id = 2; // moderators group
$this->Acl->deny($group, 'controllers');
$this->Acl->allow($group, 'controllers/Clients/index');
$this->Acl->allow($group, 'controllers/Clients/view');
$this->Acl->allow($group, 'controllers/Clients/add');
$this->Acl->allow($group, 'controllers/Clients/edit');
$this->Acl->allow($group, 'controllers/Clients/delete');
$this->Acl->allow($group, 'controllers/Clients/search');\
/* ALSO allow moderators full access to all clients methods */
/* 2.a compact version */
$group->id = 2; // moderators group
$this->Acl->deny($group, 'controllers');
$this->Acl->allow($group, 'controllers/Clients');
/* OR should it be like this? */
/* 2.b compact version */
$group->id = 2; // moderators group
$this->Acl->deny($group, 'controllers');
$this->Acl->allow($group, 'controllers/Clients/*');
/* OR should it be like this? */
/* 2.c compact version */
$group->id = 2; // moderators group
$this->Acl->deny($group, 'controllers');
$this->Acl->allow($group, 'controllers/Clients/"*"');
}