Apache Magento multi-site.htaccess将1个站点的http重定向到https

Apache Magento multi-site.htaccess将1个站点的http重定向到https,apache,.htaccess,magento,redirect,https,Apache,.htaccess,Magento,Redirect,Https,拥有magento多站点设置,3个域 要为3个域中仅1个域上的所有请求安排http到https的htaccess 301重定向 中的代码工作并保留URL的其余部分(即指向),但它对多站点设置中的每个域都这样做 如何修改Michael的代码,以便指定domain1.com重定向,但domain2.com和domain3.com不重定向 迈克尔斯密码在这里 RewriteCond %{HTTPS} off # First rewrite to HTTPS: # Don't put www. here

拥有magento多站点设置,3个域

要为3个域中仅1个域上的所有请求安排http到https的htaccess 301重定向

中的代码工作并保留URL的其余部分(即指向),但它对多站点设置中的每个域都这样做

如何修改Michael的代码,以便指定domain1.com重定向,但domain2.com和domain3.com不重定向

迈克尔斯密码在这里

RewriteCond %{HTTPS} off
# First rewrite to HTTPS:
# Don't put www. here. If it is already there it will be included, if not
# the subsequent rule will catch it.
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
# Now, rewrite any request to the wrong domain to use www.
RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

在Magento配置中为特定的存储范围更改不安全的基本URL对您来说是一个相当大的选择吗?仅在您希望成为https for all app(Magento)请求的域范围内