I am trying to add another RewriteRule in my .htaccess file in addition to one I have in there. Currently I have:
RewriteEngine On
RewriteCond %{HTTP_HOST} websitename\.com [NC]
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://websitename.com/$1 [R,L]
and I would like to add this rule in there:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.html -f
RewriteRule ^(.*)$ $1.html [NC, L]
I left out the additional 'RewriteEngine On' and pasted the other 3 lines underneath, but it is not working. The code I have initially is to direct my website to https:// so the security shows up no matter how you type in the address. But I also ran into the issue of my pages having .html after them in the index bar. Upon looking up how to remove that I read that one way is to remove the .html in all my href's in my code, and then to add this mod rewrite to my .htaccess, but so far with no success.