Can someone please tell me how to do this?
I tried using the following code but I don’t see what I’m doing wrong?
<IfModule mod_rewrite.c>
RewriteEngine On
</IfModule>
<IfModule mod_rewrite.c>
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(*)$ $1.html
</IfModule>
You’re missing a
.in your regular expression:This:
needs to be:
You could also add this condition:
to prevent 500 errors when someone requests a page that doesn’t exist and properly return a 404.