[提问]
如何通过HTACCESS让gd非win虚拟主机不区分大小写呀!
|
|
老鸟们,麻烦你们了
如何通过HTACCESS让gd非win虚拟主机不区分大小写呀!
万分感谢了! |
|
|
|
|
|
|
|
|
|
|
goldstein
发表于 2010-11-25 21:40:27
|
显示全部楼层
Check it out:- Example:
- Request for /FOO/BAR.htm should return file contents of /foo/bar.htm, but gets stuck in a loop and time's out instead.
- The commands I'm using in my .htaccess
- # If the uri does not contain any uppercase letters, skip the next 29 rules.
- RewriteRule ![A-Z] - [S=29]
- # Skip rewriting for certain files, skip the next 28 rules
- RewriteRule .*(cgi-bin|images|\.gif|\.css|\.jpg|\.png|\.js) - [NC,S=28]
- # Else convert the first instance found of "A" to "a", "B" to "b", etc.
- RewriteRule ([^A]*)A(.*) $1a$2
- RewriteRule ([^B]*)B(.*) $1b$2
- ...repeated for C-X
- RewriteRule ([^Y]*)Y(.*) $1y$2
- RewriteRule ([^Z]*)Z(.*) $1z$2
- # If any more uppercase characters remain, restart mod_rewrite from the top
- RewriteRule [A-Z] - [N]
- # Otherwise rewrite file
- RewriteRule ^/(.*)$ /$1 [L,NS]
复制代码 |
|
|
|
|
|
|
|
|
|
|
7kbb
发表于 2010-11-26 00:19:51
|
显示全部楼层
回复 2# 的帖子
If the uri does not contain any uppercase letters, skip the next 29 rules
URL里面不含有任何大写字母就跳过下面第29条规则。这里是不是指的是用IP访问的网站地址呀 |
|
|
|
|
|
|
|
|