WordPress – Error when install WordPress with mariadb “Your PHP installation appears to be missing the MySQL extension which is required by WordPress.”

centos5mariadbphp5Wordpress

rpm -e --nodeps mysql-libs 
yum install MariaDB-server

The above command helped me to install mariadb, also installed WordPress. This was a great help. My problem now is when I reboot the server or restart apache here is the error:

"Your PHP installation appears to be missing the MySQL extension which is required by WordPress."

How can I solve this problem?

Best Answer

You need to install php-mysql so that PHP could connect to a MySQL/MariaDB instance. Do this by

yum install php-mysql