All Blogs | Help
25th January 2010 @ 23:06
If you are like me, you dislike the .php extension for web pages that display content, eg /contactus.php . To me this is a web page that is displaying HTML, so lets give it an .html suffix. but the easist way to implements templates is to use html.

To achieve this easily just create a .htaccess file to redirect .html's to .php.
.htaccess code:
 
RewriteEngine On
RewriteRule (.*).html $1.php [QSA]
 
(The QSA just forwards all variables to the .php script)
Requirements: are apache and mod_rewrite
More Info: http://www.kuro5hin.org/story/2003/7/31/2335/08552