Search code examples
phpyiiyiic

how to fix CConsoleApplication.user undefined in a command class in yii framework?


I am having that error , whenever I ran my simple cron script in shell , any idea how to fix that thing ?, from the error itself, it says the .user is undefiend, when I placed the

'user' => array(
    // enable cookie-based authentication
     'allowAutoLogin' => true,
 'loginUrl' => array('myaccount/blah/login'),

in the console config, it is looking for a "Class" ,, what class am i supposed to include in that array? , this user login url is using an LDAP stuff in loggin in and authentication, what should I do ?


Solution

  • solved my problem by using update, instead of save in the script...no need to use user array and CWebUser class