windows开启Apache的mod_rewrite模块

windows下安装apache默认是没有开启mod_rewrite模块的,启用也很简单,修改apache配置文件httpd.conf,查找rewrite_module,

找到这行:#LoadModule rewrite_module modules/mod_rewrite.so这一行前面的#号去掉,改为LoadModule rewrite_module modules/mod_rewrite.so

备注:liunx 开启:sudo a2enmod rewrite   其实修改的文件是:/etc/apache2/mods-available

windows下配置虚拟目录:

windows下安装apache默认是没有开启mod_rewrite模块的,启用也很简单,修改apache配置文件httpd.conf,查找rewrite_module,

找到这行:#LoadModule rewrite_module modules/mod_rewrite.so这一行前面的#号去掉,改为LoadModule rewrite_module modules/mod_rewrite.so

httpd.conf在添加

--------------------------

NameVirtualHost *:80

<VirtualHost *:80>
DocumentRoot "E:\wamp\www\sub7"
ServerName www.erptest.com
setenv APPLICATION_ENV dev
</VirtualHost>

--------------------------------------------------这里面的内容

<Directory />
Options FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
</Directory>

在本件修改 php.ini

display_errors = On

上一篇:分享基于EF+MVC+Bootstrap的通用后台管理系统及架构


下一篇:用cxf开发restful风格的WebService