Koozali.org: home of the SME Server
Legacy Forums => Experienced User Forum => Topic started by: brad wright on July 05, 2001, 08:01:46 PM
-
Hi all,
how do I get e-smith to parse all files with a .xxx suffix through PHP?
at present, if i ask for a file abc.php in my web browser, it parses the contents of the file thru PHP before dilivering it (via appache), how do I get PHP to parse a file eg. abc.xxx as a PHP file??
I hope I make sense here.
Thanks for the help,
Brad
-
Why on earth would you want to? In any case, you'd do this by editing /etc/e-smith/templates/etc/httpd/conf/httpd.conf/S95AddType00PHP2ibays, and adding the .xxx extension on line 23.
Probably better if you copied that file to an appropriate directory in /etc/e-smith/templates-custom before editing it, though.
-
Dan,
i simply want to enable the use of the file suffix '.inc' so I can use .inc files as include files. Just makes it easier to fiollow tutes/how-to's relating to PHP as they seem to use the .inc suffix by convention for included files.
Do you think this is a misguided view? I'm interested in hearing another view.
Cheers,
Brad
-
.inc suffix for php includes is considered bad practice.
Search the bugtraq archives for "A study in scarlet".
-
Irrespective of whether it's a bad practice or not, if they're included from a .php file, PHP will parse .inc (or .txt, or any other extension) files.
-
Fillipo,
I tried to find that reference, however bugtraq archives didn't have anything when searched, do you have a URL or copy of the article?? I'm very interested to read it.
Thanks,
Brad
-
http://www.securereality.com.au/studyinscarlet.txt