Re: Can I call .html file as a form action instead of .php?

From: Date: Tue, 11 Oct 2005 03:13:28 +0000
Subject: Re: Can I call .html file as a form action instead of .php?
References: 1 2 3 4 5  Groups: php.general 
Request: Send a blank email to php-general+get-223877@lists.php.net to get a copy of this message
Michael Crute wrote:
On 10/10/05, *Richard Lynch* <ceo@l-i-e.com <mailto:ceo@l-i-e.com>> wrote:
    In addition to the Good column, let me add this:
    Once I made all my .html files go through PHP, I found myself adding a
    lot of cool little snippets to my files that I wouldn't have bothered
    with if I had to re-name the file, fix all the links, worry about
    search engines "losing" my page, etc.
    I would encourage anybody but the most hard-core million-hits-per-day
    super-stressed folks to just go ahead and use PHP on .htm and .html
Except its terrible form and not at all portable.
I don't do this myself (I leave extensions off PHP files instead, but that's another story...), but it is reasonably portable -- every web host I've ever dealt with supports .htaccess files; just put the following line in an .htaccess file in the root of your application. AddType application/x-httpd-php .html -- Jasper Bryant-Greene Freelance web developer http://jasper.bryant-greene.name/

« previous php.general (#223877) next »