I've got a problem with configuring apache to run only files with .php extension through FastCGI.
Sample VirtualHost configuration :
<VirtualHost 192.168.0.185:80>
ServerName host1.example.com
DocumentRoot /home/www/host1.example.com/WWW/
SuexecUserGroup host1 www
<Directory "/home/www/host1.example.com/WWW/">
AllowOverride All
Options +ExecCGI
AddHandler fcgid-script .php
FcgidWrapper /home/www/host1.example.com/fcgi/php5.fcgi
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
The problem is, that it also runs files like whats.new.in.php.6.html (basically every file containing .php followed by the dot) as fastcgi instead serving it as static content. I've tried changing AddHandler to
AddHandler fcgid-script .php$
With no luck - php files were not interpreted and served as plain text.
Is there a way to prevent this?