您好,登录后才能下订单哦!
------------------------报错------------------------
Fatal error: Class 'PDO' not found in /usr/share/nginx/html/Core/Library/Think/Db.class.php on line 39
:(
Class 'PDO' not found
错误位置
FILE: /usr/share/nginx/html/Core/Library/Think/Db.class.php LINE: 39
-----------------------------------------------------
1、进行源码包ext/pdo目录
# cd php-5.6.14/ext/pdo
2、执行/usr/local/php/bin/phpize
3、配置、编译、安装扩展PDO
# ./configure --with-php-config=/usr/local/php/bin/php-config --enable-pdo=shared && make && make install
……………
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/
4、配置、编译、安装pdo_mysql
# cd ../pdo_mysql/
# /usr/local/php/bin/phpize
# ./configure --with-php-config=/usr/local/php/bin/php-config --with-pdo-mysql=/usr/local/mysql2
……………
Build complete.
Don't forget to run 'make test'.
Installing shared extensions: /usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/
5、在php配置文件中加入
vi /usr/local/php/lib/php.ini
…………
extension=/usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/pdo_mysql.so
extension=/usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/pdo.so
6、启动php-fpm服务
# /usr/local/php/sbin/php-fpm
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。