You are using an outdated browser. For a faster, safer browsing experience, upgrade for free today.

Redirect www a https

Za řádek RewriteBase / pridat:

# --------------------- www and https ----------------#
    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.
    # [NC] is a case-insensitive match
    RewriteCond %{HTTP_HOST} !^www. [NC]
    RewriteRule .* https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
# ------------------ www and https konec -----------#

Jinak to ma Exohosting

# --------------------- www and https ----------------#
RewriteCond %{HTTP_HOST} !^www.
RewriteRule ^(.*)$ https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
RewriteCond %{HTTP:X-Forwarded-Proto} !https
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
# ------------------ www and https konec -----------#