URL伪静态设置 (apache2.4)


`

`

1.修改apche主配置文件 主要是

#LoadModule rewrite_module modules/mod_rewrite.so
改为
LoadModule rewrite_module modules/mod_rewrite.so
 
DocumentRoot "E:\WWW"
<Directory "E:\WWW">
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>

`

2.在web根目录中添加.htaccess文件,内容如下:

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php/$ [QSA,PT,L]
RewriteRule ^/(.*)$ /index.php?s=$

下面是最简版本

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php/$ [QSA,PT,L]

`

上一篇:[转]svn diff 替代工具


下一篇:unity3d大型手游 可以打包obb文件