site1.com没有启用https,并且未安装SSL证书。 site2.com确实启用了https。 站点访问者请求https://site1.com时,会收到SSL证书不匹配错误,并且如果单击“仍然继续”,则会将他们发送到https://site2.com
由于site1.com没有SSL证书,我该怎么做才能在将https重定向的同时将流量重定向回site1.com?
我在site2.com的.htaccess文件中尝试过
RewriteEngine on
#if the request is actually for site1 forward them to site1
RewriteRule "^site1.com" "http://site1.com" [R]
#if the request is actually for site1 (with www prefix) forward them to site 1
RewriteRule "^www.site1.com" "http://site1.com" [R]