htaccess 文件遇到错误
当我在项目中包含 htaccess 文件时,出现错误。
我正在使用 php 和 mysql。
## Can be commented out if causes errors, see notes above.
Options +FollowSymLinks
#
# mod_rewrite in use
RewriteEngine On
Rewritebase /xyz/
# For UI Start
### For Index page
RewriteRule ^index$ index.php [NC,L]
RewriteRule ^index/$ index.php [NC,L]
这是我的 htaccess 文件代码。
我正在与 WAMP 合作。
它给出了错误内部服务器错误。
谢谢
when i am includeing htaccess file in my project, it gives an error.
i am using php and mysql.
## Can be commented out if causes errors, see notes above.
Options +FollowSymLinks
#
# mod_rewrite in use
RewriteEngine On
Rewritebase /xyz/
# For UI Start
### For Index page
RewriteRule ^index$ index.php [NC,L]
RewriteRule ^index/$ index.php [NC,L]
This is my htaccess file code.
i am working with WAMP.
it gives an error Internal Server Error.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
最好的办法是查看错误日志文件,但我假设您无权访问该文件。
首先,确保服务器上安装了
mod_rewrite
。尝试仅放入
htaccess 文件中。如果失败并返回 500,则
mod_rewrite
将关闭,您需要与您的提供商联系。The best thing to do would be to look into the error log file, but I assume you have no access to that.
First of all then, make sure
mod_rewrite
is installed on the server.Try putting only
into the htaccess file. If that fails with a 500,
mod_rewrite
is turned off and you need to talk to your provider.您不需要包含 htaccess 文件。只需将其放在适当的位置即可。我确信这是你第一次。
You need not include htaccess files. just put it in proper place. I am sure this is your first time.