How to install MySQLi

2019-01-02 21:25发布

I cannot find instructions about installing MySQLi on a Mac. Just to be clear, MySQL is up to date and I am running PHP 5. How do I install it? Where do I even get it from? Thanks for your help. I'll be giving an up vote and a check mark to whoever answers this!

11条回答
步步皆殇っ
2楼-- · 2019-01-02 21:51

Here is the link for installation details: http://php.net/manual/en/mysqli.installation.php

If you are using Windows or Linux:
- The MySQLi extension is automatically installed in most cases, when PHP & MySQL package is installed.

查看更多
笑指拈花
3楼-- · 2019-01-02 21:56

Use php-mysqlnd instead of php-mysql

apt-get install php-mysqlnd
查看更多
墨雨无痕
4楼-- · 2019-01-02 22:03

This article is clearly explained, how to install MySqli with EachApache. This works for me too.

To install mysqli using EachApache:

  1. Login to WHM as 'root' user.

  2. Either search for "EasyApache" or go to Software > EasyApache

  3. Scroll down and select a build option (Previously Saved Config)

  4. Click Start "Start customizing based on profile"

  5. Select the version of Apache and click "Next Step".

  6. Select the version of PHP and click "Next Step".

  7. Chose additional options within the "Short Options List"

  8. Select "Exhaustive Options List" and look for "MySQL Improved extension"

  9. Click "Save and Build"

查看更多
一个人的天荒地老
5楼-- · 2019-01-02 22:04
sudo apt-get -y -f install php7.0-mysql
查看更多
还给你的自由
6楼-- · 2019-01-02 22:04

if you use ubuntu 16.04 (maybe and above) just do this

 sudo phpenmod mysqli
 sudo service php7.0-fpm restart
查看更多
登录 后发表回答