日期:2014-05-17  浏览次数:20531 次

zend framework url路由无效
大虾们,帮帮忙,是什么原因呀?
zend framework 路由无效
localhost/test/test/test 访问报404错误。
localhost/index.php/test/test/test 可以正常显示。

LoadModule rewrite_module modules/mod_rewrite.so 这个也设置
index.php 也设置默认页面了。

------解决方案--------------------
如果

localhost/index.php/test/test/test 可以正常显示。

但是
localhost/test/test/test 访问报404错误。


是不是.htaccess放的位置不对呢?
和index.php是在一个地方的?
内容是
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ index.php [NC,L]


如果都正常。就不知道是什么原因了、
不是配置的问题。只能说明代码有问题了