/home/cmcar/domains/cmusedcar.com/public_html/framework/db/CDbCommand.php(543)
531 { 532 if($this->_connection->enableProfiling) 533 Yii::endProfile('system.db.CDbCommand.query('.$this->getText().$par.')','system.db.CDbCommand.query'); 534 535 $errorInfo=$e instanceof PDOException ? $e->errorInfo : null; 536 $message=$e->getMessage(); 537 Yii::log(Yii::t('yii','CDbCommand::{method}() failed: {error}. The SQL statement executed was: {sql}.', 538 array('{method}'=>$method, '{error}'=>$message, '{sql}'=>$this->getText().$par)),CLogger::LEVEL_ERROR,'system.db.CDbCommand'); 539 540 if(YII_DEBUG) 541 $message.='. The SQL statement executed was: '.$this->getText().$par; 542 543 throw new CDbException(Yii::t('yii','CDbCommand failed to execute the SQL statement: {error}', 544 array('{error}'=>$message)),(int)$e->getCode(),$errorInfo); 545 } 546 } 547 548 /** 549 * Builds a SQL SELECT statement from the given query specification. 550 * @param array $query the query specification in name-value pairs. The following 551 * query options are supported: {@link select}, {@link distinct}, {@link from}, 552 * {@link where}, {@link join}, {@link group}, {@link having}, {@link order}, 553 * {@link limit}, {@link offset} and {@link union}. 554 * @throws CDbException if "from" key is not present in given query parameter 555 * @return string the SQL statement
#0 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/framework/db/CDbCommand.php(396): CDbCommand->queryInternal("fetchAll", array(2), array()) 391 * An empty array is returned if the query results in nothing. 392 * @throws CException execution failed 393 */ 394 public function queryAll($fetchAssociative=true,$params=array()) 395 { 396 return $this->queryInternal('fetchAll',$fetchAssociative ? $this->_fetchMode : PDO::FETCH_NUM, $params); 397 } 398 399 /** 400 * Executes the SQL statement and returns the first row of the result. 401 * This is a convenient method of {@link query} when only the first row of data is needed. |
#1 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/framework/db/ar/CActiveRecord.php(1356): CDbCommand->queryAll() 1351 if(empty($criteria->with)) 1352 { 1353 if(!$all) 1354 $criteria->limit=1; 1355 $command=$this->getCommandBuilder()->createFindCommand($this->getTableSchema(),$criteria); 1356 return $all ? $this->populateRecords($command->queryAll(), true, $criteria->index) : $this->populateRecord($command->queryRow()); 1357 } 1358 else 1359 { 1360 $finder=$this->getActiveFinder($criteria->with); 1361 return $finder->query($criteria,$all); |
#2 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/framework/db/ar/CActiveRecord.php(1475): CActiveRecord->query(CDbCriteria, true) 1470 */ 1471 public function findAll($condition='',$params=array()) 1472 { 1473 Yii::trace(get_class($this).'.findAll()','system.db.ar.CActiveRecord'); 1474 $criteria=$this->getCommandBuilder()->createCriteria($condition,$params); 1475 return $this->query($criteria,true); 1476 } 1477 1478 /** 1479 * Finds a single active record with the specified primary key. 1480 * See {@link find()} for detailed explanation about $condition and $params. |
#3 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/protected/components/ShopVip.php(90): CActiveRecord->findAll(CDbCriteria) 85 $criteria->condition = 'tent_id ='.$this->shop->id; 86 $criteria->group = 'brand_id'; 87 $criteria->having = 'enable = "1"'; 88 $criteria->order = '_tent_member DESC'; 89 $criteria->limit = 10; 90 $this->band_featured = Carlist::model()->findAll($criteria); 91 } 92 93 protected function setTemplate(){ 94 $theme = Template::model()->findByAttributes(array('path'=>$this->template)); 95 if(!empty($theme)){ |
#4 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/protected/components/ShopVip.php(40): ShopVip->get_band_featured() 35 $this->tentId = $_SERVER['SERVER_NAME']; 36 $this->tentId = str_replace('www.', '', $this->tentId); 37 $this->tentId = str_replace('.cmusedcar.com', '', $this->tentId); 38 } 39 $this->getData(); 40 $this->get_band_featured(); 41 $this->template = $this->shop->template_path; 42 //Yii::app()->theme = 'default'; 43 Yii::app()->name = $this->shop->tent_name; 44 $this->setTemplate(); 45 $this->setDefault(); |
#5 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/protected/controllers/ShopsController.php(24): ShopVip->init() 19 '2'=>array('post_date'=>CSort::SORT_DESC), 20 '3'=>array('price'=>CSort::SORT_DESC), 21 '4'=>array('price'=>CSort::SORT_ASC) 22 ); 23 public function init() { 24 parent::init(); 25 $this->shopURL = (!$this->shop->domain)? 'http://'.$this->shop->username.'.cmusedcar.com' : 'http://www.'.$this->shop->domain; 26 } 27 28 public function actions(){ 29 return array( |
#6 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/framework/web/CWebApplication.php(281): ShopsController->init() 276 if(($ca=$this->createController($route))!==null) 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}".', |
#7 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/framework/web/CWebApplication.php(141): CWebApplication->runController("shops/contact") 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. |
#8 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/framework/base/CApplication.php(184): CWebApplication->processRequest() 179 public function run() 180 { 181 if($this->hasEventHandler('onBeginRequest')) 182 $this->onBeginRequest(new CEvent($this)); 183 register_shutdown_function(array($this,'end'),0,false); 184 $this->processRequest(); 185 if($this->hasEventHandler('onEndRequest')) 186 $this->onEndRequest(new CEvent($this)); 187 } 188 189 /** |
#9 |
+
–
/home/cmcar/domains/cmusedcar.com/public_html/index.php(67): CApplication->run() 62 // Render Html 63 $html_template = str_replace("{{!PATH_FILE}}","/templates/".$_SESSION['SHOP']['template_path'],$html_template); 64 echo $html_template; 65 } 66 */ 67 Yii::createWebApplication($config)->run(); |