/home/wwwroot/www.sh17.com/protected/framework/db/CDbConnection.php(422)
410 * @return PDO the pdo instance 411 */ 412 protected function createPdoInstance() 413 { 414 $pdoClass=$this->pdoClass; 415 if(($pos=strpos($this->connectionString,':'))!==false) 416 { 417 $driver=strtolower(substr($this->connectionString,0,$pos)); 418 if($driver==='mssql' || $driver==='dblib' || $driver==='sqlsrv') 419 $pdoClass='CMssqlPdoAdapter'; 420 } 421 return new $pdoClass($this->connectionString,$this->username, 422 $this->password,$this->_attributes); 423 } 424 425 /** 426 * Initializes the open db connection. 427 * This method is invoked right after the db connection is established. 428 * The default implementation is to set the charset for MySQL and PostgreSQL database connections. 429 * @param PDO $pdo the PDO instance 430 */ 431 protected function initConnection($pdo) 432 { 433 $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); 434 if($this->emulatePrepare!==null && constant('PDO::ATTR_EMULATE_PREPARES'))
#0 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/db/CDbConnection.php(422): PDO->__construct("mysql:host=localhost;dbname=ibuy17", "ibuy17", "Wangyi1986", array()) 417 $driver=strtolower(substr($this->connectionString,0,$pos)); 418 if($driver==='mssql' || $driver==='dblib' || $driver==='sqlsrv') 419 $pdoClass='CMssqlPdoAdapter'; 420 } 421 return new $pdoClass($this->connectionString,$this->username, 422 $this->password,$this->_attributes); 423 } 424 425 /** 426 * Initializes the open db connection. 427 * This method is invoked right after the db connection is established. |
#1 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/db/CDbConnection.php(374): CDbConnection->createPdoInstance() 369 if(empty($this->connectionString)) 370 throw new CDbException('CDbConnection.connectionString cannot be empty.'); 371 try 372 { 373 Yii::trace('Opening DB connection','system.db.CDbConnection'); 374 $this->_pdo=$this->createPdoInstance(); 375 $this->initConnection($this->_pdo); 376 $this->_active=true; 377 } 378 catch(PDOException $e) 379 { |
#2 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/db/CDbConnection.php(331): CDbConnection->open() 326 public function setActive($value) 327 { 328 if($value!=$this->_active) 329 { 330 if($value) 331 $this->open(); 332 else 333 $this->close(); 334 } 335 } 336 |
#3 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/db/CDbConnection.php(309): CDbConnection->setActive(true) 304 */ 305 public function init() 306 { 307 parent::init(); 308 if($this->autoConnect) 309 $this->setActive(true); 310 } 311 312 /** 313 * Returns whether the DB connection is established. 314 * @return boolean whether the DB connection is established |
#4 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/base/CModule.php(388): CDbConnection->init() 383 if(!isset($config['enabled']) || $config['enabled']) 384 { 385 Yii::trace("Loading \"$id\" application component",'system.CModule'); 386 unset($config['enabled']); 387 $component=Yii::createComponent($config); 388 $component->init(); 389 return $this->_components[$id]=$component; 390 } 391 } 392 } 393 |
#5 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/base/CApplication.php(431): CModule->getComponent("db") 426 * Returns the database connection component. 427 * @return CDbConnection the database connection 428 */ 429 public function getDb() 430 { 431 return $this->getComponent('db'); 432 } 433 434 /** 435 * Returns the error handler component. 436 * @return CErrorHandler the error handler application component. |
#6 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/db/ar/CActiveRecord.php(624): CApplication->getDb() 619 { 620 if(self::$db!==null) 621 return self::$db; 622 else 623 { 624 self::$db=Yii::app()->getDb(); 625 if(self::$db instanceof CDbConnection) 626 return self::$db; 627 else 628 throw new CDbException(Yii::t('yii','Active Record requires a "db" CDbConnection application component.')); 629 } |
#7 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/db/ar/CActiveRecord.php(2311): CActiveRecord->getDbConnection() 2306 public function __construct($model) 2307 { 2308 $this->_model=$model; 2309 2310 $tableName=$model->tableName(); 2311 if(($table=$model->getDbConnection()->getSchema()->getTable($tableName))===null) 2312 throw new CDbException(Yii::t('yii','The table "{table}" for active record class "{class}" cannot be found in the database.', 2313 array('{class}'=>get_class($model),'{table}'=>$tableName))); 2314 if($table->primaryKey===null) 2315 { 2316 $table->primaryKey=$model->primaryKey(); |
#8 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/db/ar/CActiveRecord.php(388): CActiveRecordMetaData->__construct(Node) 383 if(isset(self::$_models[$className])) 384 return self::$_models[$className]; 385 else 386 { 387 $model=self::$_models[$className]=new $className(null); 388 $model->_md=new CActiveRecordMetaData($model); 389 $model->attachBehaviors($model->behaviors()); 390 return $model; 391 } 392 } 393 |
#9 |
+
–
/home/wwwroot/www.sh17.com/protected/modules/wfbase/components/WfThemeAction.php(108): CActiveRecord::model("Node") 103 if($this->layout!==null) 104 $controller->layout=$layout; 105 } 106 protected function createQuery($modelClass) 107 { 108 $query=is_object($modelClass)?$modelClass:CActiveRecord::model($modelClass); 109 if (isset($this->filter)) 110 $query->getDbCriteria()->mergeWith($this->filter); 111 if(isset($this->scopes)) 112 WfHelper::applyScopes($query,$this->scopes); 113 return $query; |
#10 |
+
–
/home/wwwroot/www.sh17.com/protected/modules/wfbase/node/WfBaseNodeViewAction.php(7): WfThemeAction->createQuery("Node") 2 class WfBaseNodeViewAction extends WfThemeAction{ 3 public $nodeClass; 4 public function getQuery() 5 { 6 $nodeClass=Yii::import(isset($this->nodeClass)?$this->nodeClass:$this->getController()->getNodeHelper()->nodeClass); 7 return $this->createQuery($nodeClass); 8 } 9 } |
#11 |
+
–
/home/wwwroot/www.sh17.com/protected/modules/wfbase/components/WfNodeAction.php(17): WfBaseNodeViewAction->getQuery() 12 public function runAction() 13 { 14 $id=$this->getIdValue(); 15 WfHelper::notFoundIf(!isset($id)); 16 WfHelper::notFoundIf(isset($this->idList) and !in_array($id,$this->idList)); 17 $query=$this->getQuery()->byid($id,$this->paramType); 18 if (isset($this->type)){$query=$query->byType($this->type);} 19 if (isset($this->catalog)){$query=$query->byCatalog($this->catalog);} 20 $model=$query->find(); 21 WfHelper::notFoundIf(!isset($model)); 22 $this->getPagePreparer()->prepareNode($model); |
#12 |
+
–
/home/wwwroot/www.sh17.com/protected/modules/wfbase/components/WfThemeAction.php(47): WfNodeAction->runAction() 42 } 43 } 44 public function run() 45 { 46 $this->validateForms(); 47 $this->runAction(); 48 $this->render($this->viewData); 49 } 50 public function set() 51 { 52 $controller=Yii::app()->getController(); |
#13 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/web/actions/CAction.php(75): WfThemeAction->run() 70 { 71 $method=new ReflectionMethod($this, 'run'); 72 if($method->getNumberOfParameters()>0) 73 return $this->runWithParamsInternal($this, $method, $params); 74 else 75 return $this->run(); 76 } 77 78 /** 79 * Executes a method of an object with the supplied named parameters. 80 * This method is internally used. |
#14 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/web/CController.php(309): CAction->runWithParams(array("id" => "11322")) 304 { 305 $priorAction=$this->_action; 306 $this->_action=$action; 307 if($this->beforeAction($action)) 308 { 309 if($action->runWithParams($this->getActionParams())===false) 310 $this->invalidActionParams($action); 311 else 312 $this->afterAction($action); 313 } 314 $this->_action=$priorAction; |
#15 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/web/filters/CFilterChain.php(134): CController->runAction(WfNodeAction) 129 $filter=$this->itemAt($this->filterIndex++); 130 Yii::trace('Running filter '.($filter instanceof CInlineFilter ? get_class($this->controller).'.filter'.$filter->name.'()':get_class($filter).'.filter()'),'system.web.filters.CFilterChain'); 131 $filter->filter($this); 132 } 133 else 134 $this->controller->runAction($this->action); 135 } 136 } |
#16 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/web/widgets/COutputCache.php(152): CFilterChain->run() 147 * @return boolean whether the filtering process should stop after this filter. Defaults to false. 148 */ 149 public function filter($filterChain) 150 { 151 if(!$this->getIsContentCached()) 152 $filterChain->run(); 153 $this->run(); 154 } 155 156 /** 157 * Marks the start of content to be cached. |
#17 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/web/filters/CFilterChain.php(131): COutputCache->filter(CFilterChain) 126 { 127 if($this->offsetExists($this->filterIndex)) 128 { 129 $filter=$this->itemAt($this->filterIndex++); 130 Yii::trace('Running filter '.($filter instanceof CInlineFilter ? get_class($this->controller).'.filter'.$filter->name.'()':get_class($filter).'.filter()'),'system.web.filters.CFilterChain'); 131 $filter->filter($this); 132 } 133 else 134 $this->controller->runAction($this->action); 135 } 136 } |
#18 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/web/CController.php(292): CFilterChain->run() 287 $this->runAction($action); 288 else 289 { 290 $priorAction=$this->_action; 291 $this->_action=$action; 292 CFilterChain::create($this,$action,$filters)->run(); 293 $this->_action=$priorAction; 294 } 295 } 296 297 /** |
#19 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/web/CController.php(266): CController->runActionWithFilters(WfNodeAction, array(array("WFThemeCache +index,error,chanpin"), array(0 => "WFThemeCache +pinpaifenlei", "varyByParam" => array("pinpai", "type", "Node_page")), array(0 => "WFThemeCache +pinpaixiangxi", "varyByParam" => array("id")), array(0 => "WFThemeCache +search", "varyByParam" => array("keyword", "Node_page")))) 261 { 262 if(($parent=$this->getModule())===null) 263 $parent=Yii::app(); 264 if($parent->beforeControllerAction($this,$action)) 265 { 266 $this->runActionWithFilters($action,$this->filters()); 267 $parent->afterControllerAction($this,$action); 268 } 269 } 270 else 271 $this->missingAction($actionID); |
#20 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/web/CWebApplication.php(283): CController->run("pinpaixiangxi") 278 { 279 list($controller,$actionID)=$ca; 280 $oldController=$this->_controller; 281 $this->_controller=$controller; 282 $controller->init(); 283 $controller->run($actionID); 284 $this->_controller=$oldController; 285 } 286 else 287 throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".', 288 array('{route}'=>$route===''?$this->defaultController:$route))); |
#21 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/web/CWebApplication.php(142): CWebApplication->runController("site/pinpaixiangxi") 137 foreach(array_splice($this->catchAllRequest,1) as $name=>$value) 138 $_GET[$name]=$value; 139 } 140 else 141 $route=$this->getUrlManager()->parseUrl($this->getRequest()); 142 $this->runController($route); 143 } 144 145 /** 146 * Registers the core application components. 147 * This method overrides the parent implementation by registering additional core components. |
#22 |
+
–
/home/wwwroot/www.sh17.com/protected/framework/base/CApplication.php(162): CWebApplication->processRequest() 157 */ 158 public function run() 159 { 160 if($this->hasEventHandler('onBeginRequest')) 161 $this->onBeginRequest(new CEvent($this)); 162 $this->processRequest(); 163 if($this->hasEventHandler('onEndRequest')) 164 $this->onEndRequest(new CEvent($this)); 165 } 166 167 /** |
#23 |
+
–
/home/wwwroot/www.sh17.com/index.php(13): CApplication->run() 08 defined('YII_DEBUG') or define('YII_DEBUG',true); 09 // specify how many levels of call stack should be shown in each log message 10 defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3); 11 12 require_once($yii); 13 Yii::createWebApplication($config)->run(); |