将Yii项目文件夹移动到cPanel文件管理器中的public_html时遇到了一些问题。在本地主机http://localhost:8888/eKehadiran/index.php
它工作正常,但是当我将项目移动到public_html并运行ekehadiran.com/index.php
时,出现错误。将Yii项目移动到cPanel时出现500内部服务器错误
这是对的public_html一些相关的文件:
的.htaccess
AddHandler application/x-httpd-php54 .php .php5 .php4 .php3
的index.php
<?php
// change the following paths if necessary
$yii=dirname(__FILE__).'/framework/yii.php';
$config=dirname(__FILE__).'/protected/config/main.php';
// remove the following lines when in production mode
defined('YII_DEBUG') or define('YII_DEBUG',true);
// specify how many levels of call stack should be shown in each log message
defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);
require_once($yii);
Yii::createWebApplication($config)->run();
这是下面的路径还挺从日志文件中的错误: Application.cpp中的SoftException:603:目录“/ home/mrdidie/public_html”可由组写入# – mrdidie
yeayyy!感谢您提供查看error_logs文件的建议。现在是工作。我更改了错误中给出的所有权限error_logs – mrdidie
是的,如果您在服务器上使用suphp,则需要分别为文件夹和文件分配权限755和644 – 24x7servermanagement