Home > Backend Development > PHP Tutorial > 请教htaccess的规则如何转成httpd.ini的规则

请教htaccess的规则如何转成httpd.ini的规则

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-13 10:23:22
Original
913 people have browsed it

请问htaccess的规则怎么转成httpd.ini的规则
我用的是opencart的程序,现在要做伪静态,我的服务器是windows服务器,用的是ISAPI_Rewrite进行执行伪静态的,不过我把下面的规则复制到http.ini里后,网站链接都不对,打不开。请问有人知道怎么转成 httpd.ini的规则么?谢谢!

RewriteBase / 
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)\?*$ index.php?_route_=$1 [L,QSA]

------解决方案--------------------
http://www.zzxj.net/blog/fxs_2008/archive/2009/01/20/11.html

http://www.zzxj.net/blog/fxs_2008/archive/2009/01/18/1.html

参考下
------解决方案--------------------
apache里的特殊字符可以不转义,但ISAPI_Rewrite里的特殊字符就必须转义。
如(仅仅是字符,而不是正则的表达才转义):
apache:
RewriteRule ^(.*)-tmp-(.*)$ $1.php?$2
ISAPI_Rewrite:
RewriteRule ^(.*)-tmp-(.*)$ $1\.php\?$2

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
url-rewrite - nginx rewrite problem
From 1970-01-01 08:00:00
0
0
0
php - apache rewrite unstable
From 1970-01-01 08:00:00
0
0
0
Ask a question about apache rewrite
From 1970-01-01 08:00:00
0
0
0
rewrite - How can nginx rewrite certain routes?
From 1970-01-01 08:00:00
0
0
0
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template