httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Montague <>
Subject Re: [users@httpd] directoryindexing or what?
Date Tue, 18 Oct 2011 18:51:08 GMT
On October 18, 2011 14:35 , Frank Gingras <> 
> You should not use AddType for this. Instead, use:
> <FilesMatch \.php$>
> SetHandler application/x-httpd-php
> </FilesMatch>
> See and

Can you elaborate on that?  I use AddType because avoiding the regular 
expression match done by FilesMatch is presumably more efficient.  But 
is there a problem with this?  If so, what is it?

I checked both of the web pages you link to above (including all of the 
comments on the second one), but while the AddType method is not talked 
about on either of them, it's not warned about, either.  The PHPDownload 
page says "check the value of the Content-Type: http header.  If it's 
application/x-httpd-php, you'll need to remove all erroneous references 
to that value as a mime type in your config."  When I use AddType in my 
configuration, the Content-Type header for a PHP page has the value 
"text/html; charset=utf-8"; hence I am assuming that my use of AddType 
is not an erroneous use.

Any insights you can provide would be appreciated.

   Mark Montague

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message