I need some .htaccess code that will treat extensionless files as PHP files.
Suppose the visitors visits www.mywebsite.com/dir1/dir2/file.name
, it will
Ok, the answer was a combination of answers. I needed to add Options +MultiViews
in my Apache configuration. Then I extend Andrews
answer to the following:
RewriteEngine On
RewriteCond %{REQUEST_URI} !^/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ $1.php [L]
Regards and many thanks! Kevin