Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- CDbException
- Table "user" does not have a column named "name".
- /var/www/html/protected/yii/db/schema/CDbCommandBuilder.php(697)
- 685 }
- 686 else
- 687 {
- 688 $conditions[]=$prefix.$column->rawName.'='.self::PARAM_PREFIX.$i;
- 689 $values[self::PARAM_PREFIX.$i]=$value;
- 690 $i++;
- 691 }
- 692 }
- 693 else
- 694 $conditions[]=$prefix.$column->rawName.' IS NULL';
- 695 }
- 696 else
- 697 throw new CDbException(Yii::t('yii','Table "{table}" does not have a column named "{column}".',
- 698 array('{table}'=>$table->name,'{column}'=>$name)));
- 699 }
- 700 $criteria->params=array_merge($values,$criteria->params);
- 701 if(isset($conditions[0]))
- 702 {
- 703 if($criteria->condition!='')
- 704 $criteria->condition=implode(' AND ',$conditions).' AND ('.$criteria->condition.')';
- 705 else
- 706 $criteria->condition=implode(' AND ',$conditions);
- 707 }
- 708 return $criteria;
- 709 }
- Stack Trace
- #0
- + /var/www/html/protected/yii/db/ar/CActiveRecord.php(1523): CDbCommandBuilder->createColumnCriteria(CMysqlTableSchema, array("name" => "admin"), "", array(), ...)
- #1
- – /var/www/html/protected/components/UserIdentity.php(16): CActiveRecord->findByAttributes(array("name" => "admin"))
- 11 {
- 12 public $_id;
- 13
- 14 public function authenticate($ignoreIp = false)
- 15 {
- 16 $model = User::model()->findByAttributes(array('name'=>$this->name));
- 17 if ($model)
- 18 $this->password = crypt($this->password, $model->password);
- 19 if(!$model)
- 20 $this->errorCode = self::ERROR_USERNAME_INVALID;
- 21 else if($model->password !== $this->password)
- #2
- – /var/www/html/protected/models/LoginForm.php(50): UserIdentity->authenticate("1")
- 45 public function authenticate($attribute,$params)
- 46 {
- 47 if(!$this->hasErrors())
- 48 {
- 49 $this->_identity=new UserIdentity($this->name, $this->password);
- 50 if(!$this->_identity->authenticate($this->ignoreIp))
- 51 $this->addError('password',Yii::t('mc', 'Incorrect username or password.'));
- 52 }
- 53 }
- 54
- 55 public function login()
- #3
- – /var/www/html/protected/yii/validators/CInlineValidator.php(42): LoginForm->authenticate("password", array())
- 37 * @param string $attribute the attribute being validated
- 38 */
- 39 protected function validateAttribute($object,$attribute)
- 40 {
- 41 $method=$this->method;
- 42 $object->$method($attribute,$this->params);
- 43 }
- 44
- 45 /**
- 46 * Returns the JavaScript code needed to perform client-side validation by calling the {@link clientValidate} method.
- 47 * In the client validation code, these variables are predefined:
- #4
- – /var/www/html/protected/yii/validators/CValidator.php(201): CInlineValidator->validateAttribute(LoginForm, "password")
- 196 else
- 197 $attributes=$this->attributes;
- 198 foreach($attributes as $attribute)
- 199 {
- 200 if(!$this->skipOnError || !$object->hasErrors($attribute))
- 201 $this->validateAttribute($object,$attribute);
- 202 }
- 203 }
- 204
- 205 /**
- 206 * Returns the JavaScript needed for performing client-side validation.
- #5
- – /var/www/html/protected/yii/base/CModel.php(159): CValidator->validate(LoginForm, null)
- 154 if($clearErrors)
- 155 $this->clearErrors();
- 156 if($this->beforeValidate())
- 157 {
- 158 foreach($this->getValidators() as $validator)
- 159 $validator->validate($this,$attributes);
- 160 $this->afterValidate();
- 161 return !$this->hasErrors();
- 162 }
- 163 else
- 164 return false;
- #6
- – /var/www/html/protected/controllers/SiteController.php(102): CModel->validate()
- 097 $session['login_time'] = $now;
- 098 }
- 099 if (@$session['login_tries'] >= $logTries)
- 100 $model->addError('name', Yii::t('mc', 'Login temporarily blocked.'));
- 101 }
- 102 if(!$model->hasErrors() && $model->validate() && $model->login())
- 103 {
- 104 if ($logTries)
- 105 {
- 106 $session = Yii::app()->session;
- 107 $session['login_tries'] = 0;
- #7
- unknown(0): SiteController->actionLogin("", "")
- #8
- – /var/www/html/protected/yii/web/actions/CAction.php(109): ReflectionMethod->invokeArgs(SiteController, array("", ""))
- 104 elseif($param->isDefaultValueAvailable())
- 105 $ps[]=$param->getDefaultValue();
- 106 else
- 107 return false;
- 108 }
- 109 $method->invokeArgs($object,$ps);
- 110 return true;
- 111 }
- 112 }
- #9
- – /var/www/html/protected/yii/web/actions/CInlineAction.php(47): CAction->runWithParamsInternal(SiteController, ReflectionMethod, array("r" => "site/login"))
- 42 {
- 43 $methodName='action'.$this->getId();
- 44 $controller=$this->getController();
- 45 $method=new ReflectionMethod($controller, $methodName);
- 46 if($method->getNumberOfParameters()>0)
- 47 return $this->runWithParamsInternal($controller, $method, $params);
- 48
- 49 $controller->$methodName();
- 50 return true;
- 51 }
- 52 }
- #10
- – /var/www/html/protected/yii/web/CController.php(308): CInlineAction->runWithParams(array("r" => "site/login"))
- 303 {
- 304 $priorAction=$this->_action;
- 305 $this->_action=$action;
- 306 if($this->beforeAction($action))
- 307 {
- 308 if($action->runWithParams($this->getActionParams())===false)
- 309 $this->invalidActionParams($action);
- 310 else
- 311 $this->afterAction($action);
- 312 }
- 313 $this->_action=$priorAction;
- #11
- – /var/www/html/protected/yii/web/CController.php(286): CController->runAction(CInlineAction)
- 281 * @see runAction
- 282 */
- 283 public function runActionWithFilters($action,$filters)
- 284 {
- 285 if(empty($filters))
- 286 $this->runAction($action);
- 287 else
- 288 {
- 289 $priorAction=$this->_action;
- 290 $this->_action=$action;
- 291 CFilterChain::create($this,$action,$filters)->run();
- #12
- – /var/www/html/protected/yii/web/CController.php(265): CController->runActionWithFilters(CInlineAction, array())
- 260 {
- 261 if(($parent=$this->getModule())===null)
- 262 $parent=Yii::app();
- 263 if($parent->beforeControllerAction($this,$action))
- 264 {
- 265 $this->runActionWithFilters($action,$this->filters());
- 266 $parent->afterControllerAction($this,$action);
- 267 }
- 268 }
- 269 else
- 270 $this->missingAction($actionID);
- #13
- – /var/www/html/protected/yii/web/CWebApplication.php(282): CController->run("login")
- 277 {
- 278 list($controller,$actionID)=$ca;
- 279 $oldController=$this->_controller;
- 280 $this->_controller=$controller;
- 281 $controller->init();
- 282 $controller->run($actionID);
- 283 $this->_controller=$oldController;
- 284 }
- 285 else
- 286 throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".',
- 287 array('{route}'=>$this->defaultController)));
- #14
- – /var/www/html/protected/yii/web/CWebApplication.php(141): CWebApplication->runController("site/login")
- 136 foreach(array_splice($this->catchAllRequest,1) as $name=>$value)
- 137 $_GET[$name]=$value;
- 138 }
- 139 else
- 140 $route=$this->getUrlManager()->parseUrl($this->getRequest());
- 141 $this->runController($route);
- 142 }
- 143
- 144 /**
- 145 * Registers the core application components.
- 146 * This method overrides the parent implementation by registering additional core components.
- #15
- – /var/www/html/protected/yii/base/CApplication.php(185): CWebApplication->processRequest()
- 180 public function run()
- 181 {
- 182 if($this->hasEventHandler('onBeginRequest'))
- 183 $this->onBeginRequest(new CEvent($this));
- 184 register_shutdown_function(array($this,'end'),0,false);
- 185 $this->processRequest();
- 186 if($this->hasEventHandler('onEndRequest'))
- 187 $this->onEndRequest(new CEvent($this));
- 188 }
- 189
- 190 /**
- #16
- – /var/www/html/install.php(21): CApplication->run()
- 16
- 17 require_once($yii);
- 18 $app = Yii::createWebApplication($config);
- 19 $app->params['installer'] = 'show';
- 20 if (preg_match('/^(site\/log(in|out)|install\/|daemon\/ajaxGetDaemonStatus)/', @$_GET['r']))
- 21 $app->run();
- 22 else
- 23 $app->runController('/install');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement