.htaccess - Rewrite unsecured subdomain to secured -


i know has been answered, in post htaccess redirect https secure.domain.com, non https www.domain.com

but can't work. have 2 ip addresses. 1 points @ main domain, domain.com not secured. second points @ subdomain.domain.com secured. need subdomain.domain.com rewritten https://subdomain.domain.com. if has more information thankful. .htaccess code using no success-

#non-secure requests subdomain.domain.com should redirect https://secure.domain.com rewritecond %{https} off rewritecond %{http_host} ^subdomain\.domain\.com$ [nc] rewriterule .* https://%{http_host}%{request_uri} [l,r=301]  

did turn on rewriteengine?

options +followsymlinks rewriteengine on 

make sure these 2 lines above line in post.


Comments

Popular posts from this blog

Ansible - ERROR! the field 'hosts' is required but was not set -

customize file_field button ruby on rails -

SoapUI on windows 10 - high DPI/4K scaling issue -