Issues

Issue #29 resolved

Propiedad "CWebUser"."ui" no se encuentra definida.

Juan_Mares
created an issue
Propiedad "CWebUser"."ui" no se encuentra definida.

G:\UwAmp2.1\yii\framework\web\auth\CWebUser.php(141)

129 
130     /**
131      * PHP magic method.
132      * This method is overriden so that persistent states can be accessed like properties.
133      * @param string $name property name
134      * @return mixed property value
135      */
136     public function __get($name)
137     {
138         if($this->hasState($name))
139             return $this->getState($name);
140         else
141             return parent::__get($name);
142     }
143 
144     /**
145      * PHP magic method.
146      * This method is overriden so that persistent states can be set like properties.
147      * @param string $name property name
148      * @param mixed $value property value
149      */
150     public function __set($name,$value)
151     {
152         if($this->hasState($name))
153             $this->setState($name,$value);
Stack Trace
#0  
+  G:\UwAmp2.1\yii\framework\web\auth\CWebUser.php(141): CComponent->__get("ui")
#1  
–  G:\UwAmp2.1\www\yiibase\protected\views\layouts\main.php(36): CWebUser->__get("ui")
31             'items'=>array(
32                 array('label'=>'Home', 'url'=>array('/site/index')),
33                 array('label'=>'About', 'url'=>array('/site/page', 'view'=>'about')),
34                 array('label'=>'Contact', 'url'=>array('/site/contact')),
35                                 array('label'=>'Administrar Usuarios'
36                     , 'url'=>Yii::app()->user->ui->userManagementAdminUrl
37                     , 'visible'=>!Yii::app()->user->isGuest),
38                 array('label'=>'Login'
39                     , 'url'=>Yii::app()->user->ui->loginUrl
40                     , 'visible'=>Yii::app()->user->isGuest),
41                 array('label'=>'Logout ('.Yii::app()->user->name.')'
#2  
+  G:\UwAmp2.1\yii\framework\web\CBaseController.php(127): require("G:\UwAmp2.1\www\yiibase\protected\views\layouts\main.php")
#3  
+  G:\UwAmp2.1\yii\framework\web\CBaseController.php(96): CBaseController->renderInternal("G:\UwAmp2.1\www\yiibase\protected\views//layouts/main.php", array("content" => "<div id="content"> <h1>Bienvenido a <i>YII TUTORIAL</i></h1> ..."), true)
#4  
+  G:\UwAmp2.1\yii\framework\web\widgets\CContentDecorator.php(77): CBaseController->renderFile("G:\UwAmp2.1\www\yiibase\protected\views//layouts/main.php", array("content" => "<div id="content"> <h1>Bienvenido a <i>YII TUTORIAL</i></h1> ..."), true)
#5  
+  G:\UwAmp2.1\yii\framework\web\widgets\CContentDecorator.php(55): CContentDecorator->decorate("<div id="content"> <h1>Bienvenido a <i>YII TUTORIAL</i></h1> ...")
#6  
+  G:\UwAmp2.1\yii\framework\web\widgets\COutputProcessor.php(45): CContentDecorator->processOutput("<div id="content"> <h1>Bienvenido a <i>YII TUTORIAL</i></h1> ...")
#7  
+  G:\UwAmp2.1\yii\framework\web\CBaseController.php(207): COutputProcessor->run()
#8  
+  G:\UwAmp2.1\yii\framework\web\CBaseController.php(301): CBaseController->endWidget("CContentDecorator")
#9  
–  G:\UwAmp2.1\www\yiibase\protected\views\layouts\column1.php(6): CBaseController->endContent()
1 <?php /* @var $this Controller */ ?>
2 <?php $this->beginContent('//layouts/main'); ?>
3 <div id="content">
4     <?php echo $content; ?>
5 </div><!-- content -->
6 <?php $this->endContent(); ?>
#10 
+  G:\UwAmp2.1\yii\framework\web\CBaseController.php(127): require("G:\UwAmp2.1\www\yiibase\protected\views\layouts\column1.php")
#11 
+  G:\UwAmp2.1\yii\framework\web\CBaseController.php(96): CBaseController->renderInternal("G:\UwAmp2.1\www\yiibase\protected\views//layouts/column1.php", array("content" => " <h1>Bienvenido a <i>YII TUTORIAL</i></h1> <p>Esta es la vista ..."), true)
#12 
+  G:\UwAmp2.1\yii\framework\web\CController.php(785): CBaseController->renderFile("G:\UwAmp2.1\www\yiibase\protected\views//layouts/column1.php", array("content" => " <h1>Bienvenido a <i>YII TUTORIAL</i></h1> <p>Esta es la vista ..."), true)
#13 
–  G:\UwAmp2.1\www\yiibase\protected\controllers\SiteController.php(32): CController->render("index")
27      */
28     public function actionIndex()
29     {
30         // renders the view file 'protected/views/site/index.php'
31         // using the default layout 'protected/views/layouts/main.php'
32         $this->render('index');
33     }
34 
35     /**
36      * This is the action to handle external exceptions.
37      */
#14 
+  G:\UwAmp2.1\yii\framework\web\actions\CInlineAction.php(50): SiteController->actionIndex()
#15 
+  G:\UwAmp2.1\yii\framework\web\CController.php(309): CInlineAction->runWithParams(array())
#16 
+  G:\UwAmp2.1\yii\framework\web\CController.php(287): CController->runAction(CInlineAction)
#17 
+  G:\UwAmp2.1\yii\framework\web\CController.php(266): CController->runActionWithFilters(CInlineAction, array())
#18 
+  G:\UwAmp2.1\yii\framework\web\CWebApplication.php(283): CController->run("")
#19 
+  G:\UwAmp2.1\yii\framework\web\CWebApplication.php(142): CWebApplication->runController("")
#20 
+  G:\UwAmp2.1\yii\framework\base\CApplication.php(162): CWebApplication->processRequest()
#21 
+  G:\UwAmp2.1\www\yiibase\index.php(13): CApplication->run()
2012-11-10 20:17:28 Apache/2.2.17 (Win32) PHP/5.3.5 Yii Framework/1.1.12

Comments (3)

  1. Juan_Mares reporter

    Gracias Carlos por contestar, efectivamente me faltaba parte de la configuracion en el main. Ya que estaba con otro proyecto abierto y me equivoque de archivo :(

  2. Log in to comment