mtech-hosting

Well-Known Member
Apr 30, 2006
62
0
156
Just as the title states, we moved php5 to fcgi-suexe and now we need to parse some php thats in html fils. How should we go about this?

Also, where are all the settings for fcgi? Shouldnt there be something like this someone for the settings?
Code:
<IfModule mod_fastcgi.c>
FastCgiIpcDir /usr/local/www/fcgi_ipc/tmp
AddHandler fastcgi-script .fcgi
FastCgiSuexec /usr/local/sbin/suexec
FastCgiConfig -singleThreshold 100 -killInterval 300 -autoUpdate -idle-timeout 240 -pass-header HTTP_AUTHORIZATION
</IfModule>
<Location /php-fastcgi/>
Options ExecCGI        
SetHandler fastcgi-script
</Location>
Thanks
 
Last edited:

rustelekom

Well-Known Member
PartnerNOC
Nov 13, 2003
290
0
166
moscow
If you use Apache 2.xxx and php 5.xxx try set in user .htaccess fille RemoveType directive. Like this one:

RemoveType .php .php3 .php4 .phtml .asp .htm .html
AddType x-httpd-php5 .php .php3 .php4 .phtml .asp .htm .html
AddHandler x-httpd-php5 .php .php3 .php4 .phtml .asp .htm .html

It should be help with interpreting .html extension as php
 

mtech-hosting

Well-Known Member
Apr 30, 2006
62
0
156
Thank you for the info but i dont think that would would help since the php is using a wrapper. I managed to solve the issue by using
Code:
# Fastcgi configuration for PHP5
LoadModule fcgid_module modules/mod_fcgid.so
MaxRequestsPerProcess 500
AddHandler fcgid-script .php5 .php .php3 .php2 .phtml .html 
FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .php5
FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .php
FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .php3
FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .php2
FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .phtml
FCGIWrapper /usr/local/cpanel/cgi-sys/php5 .html
I just added another wrapper for .html to the AddHandler and a FCGIWrapper for html. I dont know if this will enable it html parsing for the entire server, but its working now though it may not be the correct way to do it.