Fedora 15 安装 Nginx (PHP(2)

4、安装PHP:
yum install php-fpm php-cli php-mysql php-gd php-imap php-ldap php-odbc php-pear php-xml php-xmlrpc php-eaccelerator php-magickwand php-magpierss php-mbstring php-mcrypt php-mssql php-shout php-snmp php-soap php-tidy
然后配置PHP:
vi /etc/php.ini
参照如下配置:

; cgi.fix_pathinfo provides *real* PATH_INFO/PATH_TRANSLATED support for CGI. PHP's ; previous behaviour was to set PATH_TRANSLATED to SCRIPT_FILENAME, and to not grok ; what PATH_INFO is. For more information on PATH_INFO, see the cgi specs. Setting ; this to 1 will cause PHP CGI to fix its paths to conform to the spec. A setting ; of zero causes PHP to behave as before. Default is 1. You should fix your scripts ; to use SCRIPT_FILENAME rather than PATH_TRANSLATED. ; #ini.cgi.fix-pathinfo cgi.fix_pathinfo=0

你也可以参照Nginx官方wiki配置说明:
下一步创建PHP-FPM系统启动链接并启动它:
chkconfig --levels 235 php-fpm on
/etc/init.d/php-fpm start

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:http://www.heiqu.com/wyyyfy.html