php with cgi
1)yum install perl* (/usr/bin/perl)
2)configuration file:
cd /usr/local/apache/htdocs/
mkdir domain123
vim index.php
phpinfo();
?>
# ServerAdmin webmaster@diummy-host.example.com
AddHandler php5-script php
AddType application/x-httpd-php-source phps
LoadModule php5_module modules/libphp5.so
DocumentRoot /usr/local/apache/htdocs/domain123
DirectoryIndex index.php
ServerName domain123.com
php_value memory_limit 128M
php_admin_flag safe_mode On
cd /usr/local/apache/htdocs/
vim index.cgi ( download it from net and http://personal.cityu.edu.hk/CGIWrap/cgi_sam.htm)
edit perl location in the first line
AddHandler php5-script .php
AddHandler cgi-script .cgi
ScriptAlias /cgi-bin /usr/bin/
#AddType application/x-httpd-php-source phps
Action php5-script cgi-bin/perl
Options +ExecCGI
DocumentRoot /usr/local/apache/htdocs
DirectoryIndex index.cgi
ServerName sub.domain123.com