------------------------報(bào)錯(cuò)------------------------
長垣網(wǎng)站制作公司哪家好,找創(chuàng)新互聯(lián)!從網(wǎng)頁設(shè)計(jì)、網(wǎng)站建設(shè)、微信開發(fā)、APP開發(fā)、響應(yīng)式網(wǎng)站等網(wǎng)站項(xiàng)目制作,到程序開發(fā),運(yùn)營維護(hù)。創(chuàng)新互聯(lián)從2013年開始到現(xiàn)在10年的時(shí)間,我們擁有了豐富的建站經(jīng)驗(yàn)和運(yùn)維經(jīng)驗(yàn),來保證我們的工作的順利進(jìn)行。專注于網(wǎng)站建設(shè)就選創(chuàng)新互聯(lián)。
Fatal error: Class 'PDO' not found in /usr/share/nginx/html/Core/Library/Think/Db.class.php on line 39
:(
Class 'PDO' not found
錯(cuò)誤位置
FILE: /usr/share/nginx/html/Core/Library/Think/Db.class.php LINE: 39
-----------------------------------------------------
1、進(jìn)行源碼包ext/pdo目錄
# cd php-5.6.14/ext/pdo
2、執(zhí)行/usr/local/php/bin/phpize
3、配置、編譯、安裝擴(kuò)展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、啟動(dòng)php-fpm服務(wù)
# /usr/local/php/sbin/php-fpm