Home  >  Article  >  Backend Development  >  去掉斜杠的301跳转如何写

去掉斜杠的301跳转如何写

WBOY
WBOYOriginal
2016-06-13 12:58:14981browse

去掉斜杠的301跳转怎么写?
我用的是PHP虚拟主机,怎么把xxxx.com/abc/ 做301跳转到xxxx.com/abc (其实就是去掉那个斜杠)

现在httpd.ini文件如下:

[ISAPI_Rewrite]
# 3600 = 1 hour
CacheClockRate 3600
RepeatLimit 32

RewriteCond Host: ^www\.xxxx\.com$
RewriteRule (.*) http\://xxxx\.com$1 [I,RP]
------解决方案--------------------
RewriteRule (.*)/ http\://xxxx\.com$1 [I,RP]
RewriteRule (.*) http\://xxxx\.com$1 [I,RP]

Statement:
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