Recently,So I wrote an article:WordPress Open full stop HTTPS ,This side describes in detail how I turned the whole grid down to the station https of,Now I need to open an experimental subdomain,The result was writing htaccess ,To redirect to443Port the code causes the entire domain name is redirected to the primary domain,It makes very egg pain,Or sub-domain must also have a certificate,Or can only turn off the primary domain redirect。
Eventually,I found the wording for a domain name,Allow access rules to identify the domain,If no redirection is not the primary domain。
Code is as follows:
1 2 3 4 5 |
RewriteCond %{SERVER_PORT} !^443$ RewriteCond %{HTTP_HOST} www.logcg.com RewriteRule ^.*$ https://www.logcg.com%{REQUEST_URI} [L,R=301] |
After this modify the code,Access subdomain will not affect longer,Can be used normally http The 80-port!
Original article written by LogStudio:R0uter's Blog » htaccess redirect to https redirection also cause subdomain solutions
Reproduced Please keep the source and description link:https://www.logcg.com/archives/1033.html
Will the next template open yet
Open source。