Skip to content
Grav 2.0 is officially stable. Read the announcement →

Community guidelines

Please keep discussions civil and on-topic. Repeated violations may lead to a temporary ban.

General

Htaccess and https redirect — can someone confirm

Started by Cath 7 years ago · 2 replies · 473 views
7 years ago

I have the certificate installed and if a user types in the full https:// it is working but I want direct all pages to https.

I'm thinking in the htaccess—right below the

RewriteEngine On

all I need to do is add

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

Yes? No? Maybe? (the htacess file make me nervous)

last edited 02/28/19 by Cath
7 years ago

Turns out it was that easy. For me anyway.

7 years ago

Well done 💪
Htaccess stress me a bit too.

Suggested topics

Topic Participants Replies Views Activity
General · by Jerry Hunt, 4 days ago
2 85 13 hours ago
General · by pamtbaau, 18 hours ago
1 60 17 hours ago
General · by Andy Miller, 1 day ago
0 47 1 day ago
General · by Marcel, 12 months ago
6 350 5 days ago
General · by Duc , 6 days ago
3 44 5 days ago