I’m trying to make my links a little easier to write, without the .php.
My rewrite rule is:
RewriteEngine on
RewriteRule ([a-z]+)$ $1.php
This is the first .htaccess I wrote myself, but it doesn’t seem to work.
I’m good with RegExp. And I don’t see the issue here.
Thanks for the help.
Make sure mod_rewrite is enabled in apache config as well as AllowOverride All
To get it workign in wamp
Click on wamp icon in systray
Go to apache
then click on httpd.conf
Search the file for mod_rewrite.so. If that line is commented (#) uncomment it.
It should look like
Then look for something like
You should find a
AllowOverride noneChange it toAllowOverride allRestart your wamp server
Then set your .htaccess to nickb suggestion
If it still doesn’t work just do a search in the httpd.conf for
AllowOverride noneand change them all toAllowOverride all, as there may be a couple