在apache服务器中实现MVC时发生500错误

在apache服务器中实现MVC时发生500错误,apache,model-view-controller,zend-framework,.htaccess,controller,Apache,Model View Controller,Zend Framework,.htaccess,Controller,我是php的BigEnginer,我试图用php实现模型视图控制器我更新了allow override to all并创建了一个.htacess文件并在其中写了以下引号 RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-l RewriteRule ^(.*)$ index.php?url=$1 {QSA

我是php的BigEnginer,我试图用php实现模型视图控制器我更新了allow override to all并创建了一个.htacess文件并在其中写了以下引号

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule ^(.*)$ index.php?url=$1 {QSA,L}
但我给了我500个错误,我直接转到apache错误日志,得到了以下错误:

[Mon Apr 09 01:18:36 2012] [alert] [client ::1] C:/wamp/www/.htaccess: Invalid command 'RewriteEngine', perhaps 

misspelled or defined by a module not included in the server configuration
我搜索了又搜索,但找不到它,我只想把所有的请求传递到index.php文件我在youtube上看了一段视频,他的电脑工作正常,但我的电脑没有,他告诉我应该修改php.ini中的某些内容,但我不知道那是什么,如果我在.htacess中编写以下内容:

ErrorDocument 404 /404.php
ErrorDocument 500 /500.php
转到不存在的url,然后由404.php控制,但我试图编写第一个脚本,然后每次都给我500个错误。。。以前我也尝试过安装zend framework,但仍然有相同的错误。。。。 我为我的语言道歉,,,
提前谢谢你。。。请帮助…

您需要启用mod_rewrite。通过“a2enmod rewrite”或手动添加到httpd.conf中,您的apache重写模块是否已启用?您可以在安装目录的httpd.conf文件中启用它。如果您使用的是windows,只需取消对重写模块行的注释,然后重新启动apache


你可以在谷歌上搜索“enable apache rewrite”以获取更多信息。

我还试图修改.htacess的路径,比如
RewriteRule^(.*)$/mvc/index.php?url=$1[QSA,L]
但是如果我给出两条语句,比如:
仍然没有发生任何事情,你能告诉我更多吗?