工作正常:
转到/index.php
网站主页加载
转到/sdagkljahsdf/sdfsafdsaf/
网站(框架)404时
通过index.php
工作不正确:
/index
apache错误消息附带Not
Found
:The requested URL /index was not found on this server.
因此,使用apache 404
不通过框架index.php
我希望它通过index.php
这是我的.htaccess
:
SetEnv APPLICATION_ENV []
php_flag display_errors off
php_flag html_errors off
php_flag log_errors off
#hide index.php
<ifModule mod_rewrite.c>
#Turn on the engine
RewriteEngine on
#Don't Perform for files and directories
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
#Exerything else redirect to index.php
RewriteRule ^(.*)$ index.php/$1
</ifModule>
Redirect 301 /donate /funding
Redirect 301 /site/donate /funding
这是我的vhost
:
<Directory {{ www_path }}>
Options Indexes MultiViews FollowSymLinks
AllowOverride All
</Directory>