Support » How-To and Troubleshooting » HTTPS Redirect changing subdomain URL

HTTPS Redirect changing subdomain URL

  • I have an SSL set up on my domain ( http://www.domain.com ). My WP is installed in it’s own directory but running from my root directory.

    I found reference to making my WP auto-load with HTTPS on the forms and added the following to my .htaccess (in my root directory) for WP right under RewriteEngine On :

    RewriteCond %{SERVER_PORT} 80
    RewriteRule ^(.*)$ https://www.domain.com/$1 [R,L]

    I have a few non-wp subdomains, however now when I start using them, they are not pointing at subdomain.domain.com but instead https://domain.com/subdomain/

    Can anyone advise on a way to correct this that filters my subdomains out of the HTTPS structure?


Viewing 1 replies (of 1 total)
  • I resolved this by adding the following in my .htaccess under my RewriteEngine On:

    RewriteCond %{SERVER_PORT} 80
    RewriteCond %{HTTP_HOST} !^(demo|demo2)\.creativecollab\.com$ [NC]
    RewriteRule ^(.*)$ https://www.demo.com/$1 [R,L]

    That successfully excluded my subdomains from loading the https url.

Viewing 1 replies (of 1 total)
  • The topic ‘HTTPS Redirect changing subdomain URL’ is closed to new replies.
Skip to toolbar