首页 > Web开发 > 详细

How to enable mod_rewrite on Apache?

时间:2016-04-19 14:00:21      阅读:155      评论:0      收藏:0      [点我收藏+]

参考:http://www.ewhathow.com/2013/09/how-to-enable-mod_rewrite-on-apache/

Lets check if mod_rewrite exists as a module:
ls /etc/httpd/modules | grep mod_rewrite

Use the following command to check if mod_rewrite is loaded or enabled:
grep -i LoadModule /etc/httpd/conf/httpd.conf | grep rewrite

If you don’t see any of these, add the following line to your httpd.conf:
LoadModule rewrite_module modules/mod_rewrite.so

Type in the following command:
grep -i AllowOverride /etc/httpd/conf/httpd.conf
You need to replace None with All if it is not already All.
在/var/www/html目录下的 AllowOverride 改成 All 就ok了

How to enable mod_rewrite on Apache?

原文:http://www.cnblogs.com/qike/p/5407717.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!