【问题标题】:Http redirect for all except one page除一页外的所有页面的 Http 重定向
【发布时间】:2014-07-04 19:15:13
【问题描述】:

任何人都可以建议如何将除 https://{url}/content 之外的所有内容从 https://{url}/$1 重定向到 {url2}/$1

感谢您的帮助。

【问题讨论】:

    标签: .htaccess http redirect


    【解决方案1】:

    可能是这样的:

    RewriteEngine On
    RewriteCond %{HTTPS} on
    RewriteCond %{HTTP_HOST} yourfirstdomain.com
    RewriteRule ^(?!content)(.*) https://yourseconddomain.com/$1 [NE,L,R]
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2016-11-30
      • 1970-01-01
      • 1970-01-01
      • 2020-03-11
      • 2014-07-22
      • 2014-09-11
      • 2015-08-01
      • 2011-09-13
      相关资源
      最近更新 更多