我从 github 下载了最新版本的 Yii 用户模块,并在下面解压
protected/modules/
目录,因此我在此目录下的目录结构包括 zip 中包含的用户和其他模块。我对文档中提到的主文件进行了更改,所以我的 main.php 现在看起来像这样
'import'=>array(
'application.modules.user.models.*',
'application.models.*',
'application.components.*',
),
'modules'=>array(
// uncomment the following to enable the Gii tool
'gii'=>array(
'class'=>'system.gii.GiiModule',
'password'=>'sheikh24',
// If removed, Gii defaults to localhost only. Edit carefully to taste.
'ipFilters'=>array('127.0.0.1','::1'),
),
'user' => array(
'debug' => true,
)
),
'components'=>array(
'user'=>array(
'class' => 'application.modules.user.components.YumWebUser',
'allowAutoLogin'=>true,
'loginUrl' => array('//user/user/login'),
),
// uncomment the following to use a MySQL database
'db'=>array(
'connectionString' => 'mysql:host=localhost;dbname=ewindow',
'emulatePrepare' => true,
'username' => 'root',
'password' => '',
'charset' => 'utf8',
'tablePrefix' => '',
),
'errorHandler'=>array(
// use 'site/error' action to display errors
'errorAction'=>'index/error',
),
'log'=>array(
'class'=>'CLogRouter',
'routes'=>array(
array(
'class'=>'CFileLogRoute',
'levels'=>'error, warning',
),
// uncomment the following to show log messages on web pages
/*
array(
'class'=>'CWebLogRoute',
),
*/
),
),
)
如您所见,我已经设置了所有代码,但是当我点击网址时
http://localhost/ewindow/index.php?r=user/install
我收到以下错误
include(UserModule.php) [<a href='function.include'>function.include</a>]: failed to open stream: No such file or directory
或者我尝试在我的应用程序中点击其他页面我收到错误
include(YumWebUser.php) [<a href='function.include'>function.include</a>]: failed to open stream: No such file or directory
谁能告诉我我在这里做错了什么?请帮我 。
编辑 :