一、安装mysql扩展
Java代码
cd php-5.6.14 cd ext/ cd mysql/ /usr/local/php/bin/phpize ./configure --with-php-config=/usr/local/php/bin/php-config --with-mysql=mysqlnd --with-zlib-dir=/usr/local/zlib make make install
提示如下:
Java代码
Installing shared extensions: /usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/
二、安装mysqli扩展
立即学习“PHP免费学习笔记(深入)”;
Java代码
cd php-5.6.14 cd ext/ cd mysqli/ /usr/local/php/bin/phpize ./configure --with-php-config=/usr/local/php/bin/php-config --with-mysql=mysqlnd make make install
提示如下:
Java代码 Installing shared extensions: /usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/ Installing header files: /usr/local/php/include/php/
三、安装pdo扩展
Java代码
cd php-5.6.14 cd ext/ cd pdo/ /usr/local/php/bin/phpize ./configure --with-php-config=/usr/local/php/bin/php-config --with-pdo-mysql=mysqlnd make make install
提示如下:
Java代码
Installing shared extensions: /usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/ Installing header files: /usr/local/php/include/php/ Installing PDO headers: /usr/local/php/include/php/ext/pdo/
最后配置php.ini即可
PHP怎么学习?PHP怎么入门?PHP在哪学?PHP怎么学才快?不用担心,这里为大家提供了PHP速学教程(入门到精通),有需要的小伙伴保存下载就能学习啦!
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号