使用WAMP服务器的内部服务器错误

KuM*_*MaR 5 php .htaccess wamp

我已经创建了一个MVC应用程序php,但是当我尝试访问它时,它给了我"服务器遇到内部错误"

当我检查日志时,它给了我:

内部服务器错误

服务器遇到内部错误或配置错误,无法完成您的请求.
请通过admin@example.com与服务器管理员联系,告知他们此错误发生的时间以及您在此错误发生之前执行的操作.
服务器错误日志中可能提供了有关此错误的更多信息.

我的.htaccess文件代码:

Options-MultiViews
RewriteEngine On

RewriteBase/MVC/public

RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f


RewriteRule ^(.+)$ index.php?url=$1 [QSA,L]
Run Code Online (Sandbox Code Playgroud)

ami*_*mit 2

要启用 mod_rewrite,请执行以下步骤:

\n\n
1. Find and open the file .http.conf. This will be located in your Apache install folder.\n2. Make a backup of http.conf which you can restore from, if anything were to go wrong\n3. Find the line #LoadModule rewrite_module modules/mod_rewrite.so and remove the hash \xe2\x80\x98#\xe2\x80\x99\n4. Locate the block within the directory tags as indicated below and change to:\n<directory />\nOptions All\nAllowOverride All\n</directory>\n5. Find any additional occurrences of the line \xe2\x80\x9cAllowOverride None\xe2\x80\x9d and change it to \xe2\x80\x9cAllowOverride All\xe2\x80\x9d.\n6.Finally, restart apache server and your browser. The .htaccess rewriting should now be working for any local website.\n
Run Code Online (Sandbox Code Playgroud)\n