cancel
Showing results for 
Search instead for 
Did you mean: 

File Extensions

BorderTerroir
Member

I would like visitors to our website to be able to ditch file extensions.

 

i.e. Type www.castlefordheritagetrust.org.uk/Volunteering not www.castlefordheritagetrust.org.uk/Volunteering.php

 

To do this I created a .htaccess file which contained the following script;
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^(.*)$ $1.php

 

I placed it in the public directory and was rewarded with a 500 server error.

 

What am I doing wrong?

0 REPLIES 0