错误:在centos7上的codeigniter中找不到404页面

时间:2017-02-05 14:40:08

标签: codeigniter centos7

我的codeigniter项目在Windows上成功运行,但在centos7

中显示错误
    ERROR : 404 Page not found
The page your are requested was not found

这是我的.htaccess文件

Options +FollowSymLinks
Options -Indexes
DirectoryIndex index.php
RewriteEngine on
RewriteCond $1 !^(index\.php|img|css|js|robots\.txt|favicon\.ico)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L,QSA] 

无法弄清楚....请帮助.....

1 个答案:

答案 0 :(得分:0)

将此代码段用于htaccess

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?$1 [L]