如何将一个域中的一个子文件夹重定向到另一个保留路径的域中的另一个子文件夹

时间:2017-08-15 17:41:44

标签: regex apache .htaccess redirect

继续这种情况 我有域名1

http://domain-1.com/somefolder-1

有时域1在子文件夹之后有一些信息

http://domain-1.com/somefolder-1/PRESERVE-THIS-PATH

我需要的是发送domain-1 / somefolder-1

到另一个域

http://domain-2.com/anotherfolder-1/PRESERVE-THIS-PATH

保留路径(如果存在)

1 个答案:

答案 0 :(得分:2)

您可以在@Html.Raw(string.Format("<{0}>{1}</{0}>", subArticleLevel, subarticle.SubTitle)) 的网站根目录.htaccess中使用此规则:

domain-1
相关问题