Thanks for the reply. Maybe I am doing something wrong, but I think what I setup was a "Custom Authorize Object"? http://book.cakephp.org/2.0/en/core-libraries/components/authentication.html So, maybe I did not ask the question right.... If I create a Authorized Object Class called OrgAuthorize.php in app/Controller/Components/Auth/ Is there a way to call other methods of this class in a Controller? Thanks, Bill On 5/16/2012 8:22 PM, lowpass [via CakePHP] wrote: You're loading Cake's Auth in the $components array. If you're extending that component you need to load 'OrgAuthorize'. On Sun, May 13, 2012 at 5:51 PM, bs28723 < [hidden email] > wrote: > I wrote an Auth Component. It gets a bunch of permission information about > the current user. > How can I pass this information back to the controller? > > In AppContoller.php > public $components = array( > 'Auth' => array( > 'loginRedirect' => array('controller' => 'users', 'action' => > 'index'), > 'logoutRedirect' => array('controller' => 'users', 'action' => > 'index'), > 'authError' => "You can't access that page", > 'authorize' => array('Org','Controller') > ), > 'Session' > ); > > Everything is working, but I can't call any functions in my > Controller/Component/Auth/OrgAuthorize.php > > like... > > $this->Auth->Org->check(); > > I get > Fatal error: Call to a member function getPerms() on a non-object > > How can I get this to work? I don't want to replace the current Auth > Component with myAuth. > > Thanks, > bill > > > ________________________________ > View this message in context: Can't call Auth component from controller > Sent from the CakePHP mailing list archive at Nabble.com. > > -- > Our newest site for the community: CakePHP Video Tutorials > http://tv.cakephp.org > Check out the new CakePHP Questions site http://ask.cakephp.org and help > others with their CakePHP related questions. > > > To unsubscribe from this group, send email to > [hidden email] For more options, visit this group at > http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to [hidden email] For more options, visit this group at http://groups.google.com/group/cake-php If you reply to this email, your message will be added to the discussion below: http://cakephp.1045679.n5.nabble.com/Can-t-call-Auth-component-from-controller-tp5707908p5708020.html To start a new topic under CakePHP, email ml-node+s1045679n125572...@n5.nabble.com To unsubscribe from CakePHP, click here . NAML
-- View this message in context: http://cakephp.1045679.n5.nabble.com/Can-t-call-Auth-component-from-controller-tp5707908p5708026.html Sent from the CakePHP mailing list archive at Nabble.com. -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php