Just a quick update, I rebuilt my ACO table and aco_aro table seeing
if I might have fouled something up when tinkering around, but it
still has the same results.
Auth seems to work just fine, users are required to login on pages
where they should have to, and I can get things like user group and
user id from $this->Auth->user
I don't understand what could have gone wrong with acl though.
-Rob
On Sep 1, 12:10 pm, Anthony <anthony.c.fra...@gmail.com> wrote:
> If you followed the Auth and ACL examples from the handbook hes
> referring to the build_acl action.
>
> http://book.cakephp.org/view/1549/An-Automated-tool-for-creating-ACOs
>
> On Sep 1, 10:54 am, Rob <bizarro...@gmail.com> wrote:
>
> > Hey,
> > This is my AppController
>
> > class AppController extends Controller{
> > var $components = array('Acl', 'Auth', 'Session');
> > function beforeFilter(){
> > $this->Auth->Authorize = 'actions';
> > $this->Auth->loginAction = array('controller' => 'users', 'action'
> > => 'login');
> > $this->Auth->logoutRedirect = array('controller' => 'users',
> > 'action' => 'login');
> > $this->Auth->loginRedirect = array('controller' => 'cps', 'action'
> > => 'panel');
> > $this->Auth->actionPath = 'controllers/';
> > $this->Auth->allowedActions = array('display');
> > }
>
> > }
>
> > and I don't have an initACL function, it wasn't mentioned at all in
> > the tutorial I followed...I have initDB where I set allow and deny, is
> > that similar?
>
> > function initDB(){
> > $group =& $this->User->Group;
>
> > $group->id = 2;
> > $this->Acl->deny($group, 'controllers');
>
> > $group->id = 3;
> > $this->Acl->deny($group, 'controllers');
> > $this->Acl->allow($group, 'controllers/Campaigns/add');
> > $this->Acl->allow($group, 'controllers/Campaigns/index');
> > $this->Acl->allow($group, 'controllers/Ads/view');
> > $this->Acl->allow($group, 'controllers/Users/view');
> > $this->Acl->allow($group, 'controllers/Cps/panel');
> > $this->Acl->allow($group, 'controllers/Pages');
>
> > echo "done";
> > exit;
>
> > }
>
> > On Sep 1, 2:39 am, "gome$" <gmo...@gmail.com> wrote:
>
> > > hi,
> > > It won't affect auth permanently.
> > > Show me your AppControler source code and initACL function.
Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
No comments:
Post a Comment