Hi Chris,
On Feb 6, 12:33 pm, Christoffer Niska
<
christoffer.ni...@nordsoftware.com> wrote:
> Your auth manager is missing the class property, try this:
>
> return array(
> 'modules' => array(
> 'auth',
> ),
> 'components' => array(
> 'authManager' => array(
> 'class' => 'CachedDbAuthManager',
> 'behaviors' => array(
> 'auth' => array(
> 'class' => 'auth.components.AuthBehavior',
> 'admins'=>array('admin', 'foo', 'bar'), // users with full access
> ),
> ),
> ),
> 'user' => array(
> 'class' => 'auth.components.AuthWebUser',
> ),
> ),
> );
>
Here is my current config file
'authManager' => array(
'class'=>'CDbAuthManager',
'connectionID'=>'db',
'behaviors' => array(
'auth.components.AuthBehavior',
'admins'=>array('admin', ), // users with full access
*/
),
),
and here is full stack of error
CException
Object configuration must be an array containing a "class" element. (/
home/stefano/Documents/developer/www/yii/YiiBase.php:193)
#0 /home/stefano/Documents/developer/www/yii/base/CComponent.php(326):
YiiBase::createComponent(Array)
#1 /home/stefano/Documents/developer/www/yii/base/CComponent.php(297):
CComponent->attachBehavior('admins', Array)
#2 /home/stefano/Documents/developer/www/yii/base/
CApplicationComponent.php(45): CComponent->attachBehaviors(Array)
#3 /home/stefano/Documents/developer/www/yii/web/auth/
CDbAuthManager.php(58): CApplicationComponent->init()
#4 /home/stefano/Documents/developer/www/yii/base/CModule.php(387):
CDbAuthManager->init()
#5 /home/stefano/Documents/developer/www/yii/base/CModule.php(103):
CModule->getComponent('authManager')
#6 /home/stefano/Documents/developer/www/Projects/pecl/protected/
modules/auth/components/AuthWebUser.php(23): CModule-
>__get('authManager')
#7 /home/stefano/Documents/developer/www/yii/base/CModule.php(387):
AuthWebUser->init()
#8 /home/stefano/Documents/developer/www/yii/base/CModule.php(103):
CModule->getComponent('user')
#9 /home/stefano/Documents/developer/www/Projects/pecl/protected/views/
layouts/main.php(57): CModule->__get('user')
#10 /home/stefano/Documents/developer/www/yii/web/
CBaseController.php(126): require('/home/stefano/D...')
#11 /home/stefano/Documents/developer/www/yii/web/
CBaseController.php(95): CBaseController->renderInternal('/home/
stefano/D...', Array, true)
#12 /home/stefano/Documents/developer/www/yii/web/widgets/
CContentDecorator.php(76): CBaseController->renderFile('/home/stefano/
D...', Array, true)
#13 /home/stefano/Documents/developer/www/yii/web/widgets/
CContentDecorator.php(54): CContentDecorator->decorate('
run() #16 /home/stefano/Documents/developer/www/yii/web/
CBaseController.php(300): CBaseController-
>endWidget('CContentDecorat...') #17 /home/stefano/Documents/developer/
www/Projects/pecl/protected/views/layouts/column2.php(37):
CBaseController->endContent() #18 /home/stefano/Documents/developer/
www/yii/web/CBaseController.php(126): require('/home/stefano/D...')
#19 /home/stefano/Documents/developer/www/yii/web/
CBaseController.php(95): CBaseController->renderInternal('/home/
stefano/D...', Array, true) #20 /home/stefano/Documents/developer/www/
yii/web/CController.php(784): CBaseController->renderFile('/home/
stefano/D...', Array, true) #21 /home/stefano/Documents/developer/www/
Projects/pecl/protected/controllers/SiteController.php(72):
CController->render('error', Array) #22 /home/stefano/Documents/
developer/www/yii/web/actions/CInlineAction.php(49): SiteController-
>actionError() #23 /home/stefano/Documents/developer/www/yii/web/
CController.php(308): CInlineAction->runWithParams(Array) #24 /home/
stefano/Documents/developer/www/yii/web/CController.php(286):
CController->runAction(Object(CInlineAction)) #25 /home/stefano/
Documents/developer/www/yii/web/CController.php(265): CController-
>runActionWithFilters(Object(CInlineAction), Array) #26 /home/stefano/
Documents/developer/www/yii/web/CWebApplication.php(282): CController-
>run('error') #27 /home/stefano/Documents/developer/www/yii/base/
CErrorHandler.php(331): CWebApplication->runController('site/error')
#28 /home/stefano/Documents/developer/www/yii/base/
CErrorHandler.php(204): CErrorHandler->render('error', Array) #29 /
home/stefano/Documents/developer/www/yii/base/CErrorHandler.php(129):
CErrorHandler->handleException(Object(CHttpException)) #30 /home/
stefano/Documents/developer/www/yii/base/CApplication.php(720):
CErrorHandler->handle(Object(CExceptionEvent)) #31 [internal
function]: CApplication->handleException(Object(CHttpException)) #32
{main}
> --
> Christoffer Niska
> CTO
> Nord Software
> +358 500 980 565
>
christoffer.ni...@nordsoftware.com
> Runeberginkatu 43 B 12
> 00100 Helsinki,
Finlandwww.nordsoftware.com
> -----------------------------------------------------------------------
> The information contained in this message, its responses or attachments
> are confidential. The message is intended solely for the adressee(s).
> If you are not the intended recipient, you are hereby notified that any
> use, dissemination, or reproduction is strictly prohibited. If you are
> not the intended recipient, please contact the sender by return e-mail
> and destroy all copies of the original message. Unlawful use of this
> email may be prosecuted.
> -----------------------------------------------------------------------
>