<? Php // Master configuration file $ Config = array ( 'Modules' => array ( 'Giii '=> array ( 'Class' => 'system. gii. GiiModule ', 'Password' => 'admin ', ), ), 'Basepath' => dirname (_ FILE _). DIRECTORY_SEPARATOR .'..', 'Name' => 'yii learn', // project name 'Preload' => array ('log '), 'Import' => array (// automatically loaded class 'Application. models .*', 'Application. components .*', ), 'Defaultcontroller' => 'index', // Default controller 'Layout '=> 'layout', // layout file 'Components' => array ( 'DB' => array (// database configuration 'Connectionstring' => 'MySQL: host = localhost; dbname = h. Me ', 'Username' => 'root ', 'Password' => '', 'Charset' => 'utf8 ', 'Tableprefix' => 'TP _', 'Enablesparamlogging' => true, // displays SQL statements with parameters ), 'Urlmanager' => array ( 'Urlformat' => 'path', // pathinfo mode 'Showscriptname' => false, // set false to hide index. php. // 'Urlsuffix '=> '.html', // The url suffix is equivalent to pseudo static ), 'Errorhandler' => array ( 'Erroraction' => 'index/error', // method for redirecting from error 404 ), 'Log' => array (// log 'Class' => 'clogrouter ', 'Routes '=> array ( Array ( 'Class' => 'cweblogroute ', 'Levels' => 'Trace, error, waring ', // Application Log display level 'Category' => 'system. * ', // record category ), ), ), ), 'Params' => require (dirname (_ FILE _). '/params. Php '), ); Return $ config; ?> |