What to do if PHP prompts that pdo_mysql is not installed_PHP Tutorial

WBOY
Release: 2016-07-13 10:57:50
Original
1158 people have browsed it

Today when I was using phpwind9.0, I found that I actually needed to install the pdo_mysql component when installing it. I personally think this is a stupid approach. How many webmasters have the space to modify the php.ini configuration? Why? The phpwind team feels helpless to do this

Let me introduce some methods below. Friends who have server operation permissions can refer to the following methods.

Common mistakes:
1.pdo_mysql is not installed

Solution:

Modify the local php.ini configuration, taking php under Win as an example,

Found

The code is as follows
 代码如下 复制代码

;extension=php_pdo_mysql.dll
;extension=php_pdo.dll

修改成

;extension=php_pdo_mysql.dll
;extension=php_pdo.dll

Copy code

;extension=php_pdo_mysql.dll ;extension=php_pdo.dll

was changed to

;extension=php_pdo_mysql.dll
 代码如下 复制代码

extension_dir = /www/wdlinux/apache_php-5.2.17/lib/php/extensions/no-debug-non-zts-20060613/
extension=pdo.so
extension=pdo_mysql.so

;extension=php_pdo.dll

Remove the preceding semicolon ";". Just restart the apache service.

Linux server handling methods



lanmp can try changing php.ini

The code is as follows
Copy code


extension_dir = /www/wdlinux/apache_php-5.2.17/lib/php/extensions/no-debug-non-zts-20060613/
extension=pdo.so
extension=pdo_mysql.so
After testing, it was found to be invalid!

Start the re-installation of pdo_mysql. You need to use software such as Xshell to log in to the server to set up Steps: 1. cd lanmp //Move to the installation package directory 2. tar zxvf PDO_MYSQL-1.0.2.tgz //Decompress the installation package 3. cd PDO_MYSQL-1.0.2 //Enter the decompressed installation directory 4. /www/wdlinux/php/bin/phpize //Query environment version 5. ./configure –with-php-config=/www/wdlinux/php/bin/php-config –with-pdo-mysql=/www/wdlinux/mysql //Test configuration before compilation 6. make //Compile the installation package 7. make install //Install
Restart after installation: service httpd restart and service nginxd restart Then install phpwind9.0 again to solve the problem! This method can solve: wdcp environment VPS, the problem that pdo_mysql is not installed and the database connection fails in the configuration of Alibaba Cloud server could not find driver!
http://www.bkjia.com/PHPjc/632078.htmlwww.bkjia.comtruehttp: //www.bkjia.com/PHPjc/632078.htmlTechArticleToday when using phpwind9.0, I found that when installing it, I actually need to install the pdo_mysql component. I personally think this is a What a stupid idea. How many webmasters have space permissions now?
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template