我有一个由 yii 框架提供支持的网站。
Yii 版本:1.1.14
php版本:5.4以上
我尝试从以下位置安装论坛模块
http://www.yiiframework.com/extension/bbii
我在自述文件中指定的 main.php 中添加了模块。但是 /forum 不起作用,我尝试了其他一些模块,但它们都没有在我的安装上工作。我现在被困住了,我尝试了谷歌,但这就像一个独特的错误,我不知道如何调试它。请帮忙。谢谢
return array(
'basePath'=>dirname(__FILE__).DIRECTORY_SEPARATOR.'..',
'name'=>'testapp',
'preload'=>array('log','bootstrap'),
'import'=>array(
'application.models.*',
'application.components.*',
'application.vendor.*',
'application.controllers.NavSort*',
),
'modules'=>array(
'gii'=>array(
'class'=>'system.gii.GiiModule',
'password'=>'123',
// If removed, Gii defaults to localhost only. Edit carefully to taste.
'ipFilters'=>array('127.0.0.1','::1'),
'generatorPaths' => array(
'bootstrap.gii'
),
),
'forum'=>array(
'class'=>'application.modules.bbii.BbiiModule',
'adminId'=>1,
'userClass'=>'User',
'userIdColumn'=>'id',
'userNameColumn'=>'username',
),
),
'homeUrl'=>array('site/login'),
// application components
'components'=>array(
'bootstrap' => array(
'class' => 'ext.yiibooster.components.Bootstrap',
),
'user'=>array(
// enable cookie-based authentication
'allowAutoLogin'=>true,
),
'session'=>array(
'autoStart'=>true,
'sessionName'=>'session',
'cookieMode' => 'only',
'timeout'=>86400,
),
'urlManager'=>array(
'urlFormat'=>'path',
'showScriptName'=>false,
//'urlSuffix'=>'.html',
'urlSuffix'=>'',
'class' => 'UrlManager',
'rules'=>array(
'<controller:\w+>/<id:\d+>'=>'<controller>/view',
'<controller:\w+>/<action:\w+>/<id:\d+>'=>'<controller>/<action>',
'<controller:\w+>/<action:\w+>'=>'<controller>/<action>',
'<controller:[\w\-]+>/<action:[\w\-]+>' => '<controller>/<action>',
// defaults to a site page if not above
'<view:[a-zA-Z0-9-]+>/'=>'site/login',
),
),
'db'=>array(
'connectionString' => 'pgsql:host=localhost;port=5432;dbname=testdb',
'emulatePrepare' => false,
'username' => 'postgres',
'password' => 'root',
//'tablePrefix'=>'',
'charset' => 'utf8',
),
'errorHandler'=>array(
'errorAction'=>'site/error',
),
'log'=>array(
'class'=>'CLogRouter',
'routes'=>array(
array(
'class'=>'CFileLogRoute',
'levels'=>'error, warning',
),
),
),
),
'params'=>array(
// this is used in contact page
'adminEmail'=>'info@site.com',
),
);