大家好,又见面了,我是你们的朋友全栈君。
## Rules for TR and ES country sites
RewriteCond %{REQUEST_URI} ^/(tr|es)$ [NC]
RewriteRule ^(.*) https://xx.com [L,R=301]
##
## Rules for the old alias /sam/*
RewriteRule ^pp/(.*) /xx-p/$1 [L,R=301]
=== RewriteRule ^pp/(.*) xx-p/$1 [L,R=301]{可行}
——-
可以看到的是,%{REQUEST_URI}是一个变量,且包含了前导/
RewriteRule恰好忽略前导/
—
还好有个工具
转载于:https://www.cnblogs.com/qinqiu/p/8919184.html
发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/140540.html原文链接:https://javaforall.net