php伪静态.htaccess设置

发布时间:2010年09月06日      浏览次数:705 次
RewriteEngine on
########404页面########
ErrorDocument 404 /404.php
ErrorDocument 403 /404.php
########默认缺省页########
DirectoryIndex index.html index.shtml index.php bbs.php
########绑定图片目录########
RewriteCond %{HTTP_HOST} ^upload.78.com$
RewriteCond %{REQUEST_URI} !^/upload/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /upload/$1
RewriteCond %{HTTP_HOST} ^upload.78.com$
RewriteRule ^(/)?$ upload/ [L]
#######flv
# disables compression on gifs,jpegs,pngs,mp3s and flvs
# for the mod_deflate compression
<IfModule mod_deflate.c>
SetEnvIfNoCase Request_URI \
\.(?:gif|jpe?g|png|flv|mp3)$ no-gzip dont-vary
</IfModule>
RewriteRule ^/?$ /%{HTTP_HOST}
RewriteRule ^/([a-z0-9\-]+)\.78\.com/?$ index.php?act=special&special=$1 [L]
RewriteRule ^(.*).html$ index.php?act=info&id=$1
#RewriteRule ^/?$ %{HTTP_HOST}/$1
#RewriteCond /%{HTTP_HOST} ^([a-z0-9\-]+)\.78\.com$
#RewriteRule ^(.*).html$ /%{HTTP_HOST}/$1
#RewriteRule ^/([a-z0-9\-]+)\.78\.com/(.*)?$ index.php?act=special&special=$1&item_id=$2 [L,R]
#RewriteRule ^/([a-z0-9\-]+)\.78\.com/?$ index.php?act=special&special=$1 [L]
#RewriteRule ^(.*).htm$ index.php?act=info&id=$1
<IfModule mod_gzip.c>
mod_gzip_item_exclude file \.gif $
mod_gzip_item_exclude file \.jpeg$
mod_gzip_item_exclude file \.jpg$
mod_gzip_item_exclude file \.png$
mod_gzip_item_exclude file \.flv$
mod_gzip_item_exclude file \.mp3$
</IfModule>
Options +Includes
AddType text/html .shtml
AddOutputFilter includes .shtml
bbbbbb's blog
免责声明:本站相关技术文章信息部分来自网络,目的主要是传播更多信息,如果您认为本站的某些信息侵犯了您的版权,请与我们联系,我们会即时妥善的处理,谢谢合作!