mercredi 29 avril 2015

Enforce trailing slash policy htaccess with HTTPS

I was wondering if someone could lend a hand with a small .htaccess issue.

Inside the .htaccess file is this for example:

Options -Indexes 
RewriteEngine On 
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} 

# Normal
RewriteRule ^about$ ./about.html [L,NC]
RewriteRule ^news$ ./news.html [L,NC]
RewriteRule ^other$ ./other.html [L,NC]

This works great if you want to enforce HTTPS and NOT have a forward slash after domain.com/about

My question is:

How do I enforce HTTPS and add the forward slash at the end like so;

http://ift.tt/1oKZBtX

Thanks!

Aucun commentaire:

Enregistrer un commentaire