Re: .inc or .anything - better or worse ?

From: Date: Wed, 06 Dec 2000 09:32:51 +0000
Subject: Re: .inc or .anything - better or worse ?
References: 1 2 3 4 5 6 7  Groups: php.general 
Request: Send a blank email to php-general+get-28863@lists.php.net to get a copy of this message
Mark Rogers wrote: > > Chris wrote: > > Is there any specific why it an unwritten law that included files are .inc > ? > > On a related note, is there any specific reason not to use .html for PHP > code (ie by reconfiguring Apache to treat html as PHP code)? > > Typical example; take a site which is already pretty much complete, but with > no server side code. Create some standard functions for use when opening a > page to check user credentials and cookies, etc. Put > <?php include("standard.inc"); PageEntry(); ?> > at the top of each html file. > > On the face of it, it would be pointless renaming all the files (and > changing all the links, and breaking any incoming links from other sites, > etc), and I can't see a reason on a heavily PHP based site not to just set > html as PHP code. The only problem is the extra processing time taken on each .html file. Personally my home machine, which is under basically no load to begin with, will process .html, .htm, .php, .php3 and .phtml files. On a busy commercial server, you may need to check and see if the extra load in processing every file is worth it.

« previous php.general (#28863) next »