installation php:
Yum-y Install PHP
Restart the httpd service to activate PHP:
/ETC/INIT.D/HTTPD restart
Test whether PHP is installed and finished
vim/var/www/html/info.php
<?php
Phpinfo ();
?>
installation PHP Components of:
Search for PHP Components:
Yum Search PHP
To install common components:
Yum-y Install php-mysql php-gd php-imap php-ldap php-odbc php-pear php-xmlphp-xmlrpc php-bcmath php-mbstring
Remember to restart the HTTPD Service Activation component after installation:
/ETC/INIT.D/HTTPD restart
PHP configuration file:
Vi/etc/php.ini
memory_limit=128m
Post_max_size=8m
Upload_max_filesize=2m
one command to install :
Yum-y Install gcc gcc-c++ gcc-g77 Flex Bison autoconf automake bzip2-develzlib-devel ncurses-devel libjpeg-devel libpng-de Vel libtiff-develfreetype-devel pam-devel openssl-devel libxml2-devel gettext-devel pcre-devel mysql-devel Net-snmp-develcurl-devel perl-dbi mysql mysql-server httpdphp php-mysql php-gd php-imap php-ldap php-odbc php-pear PHP-XM L PHP-XMLRPC Php-bcmath php-mbstring
Install PHP under Centos6.5