Home > Database > Mysql Tutorial > How Do I Enable the MySQLi Extension in PHP 7 on Ubuntu 14.04?

How Do I Enable the MySQLi Extension in PHP 7 on Ubuntu 14.04?

Patricia Arquette
Release: 2024-12-03 22:51:12
Original
660 people have browsed it

How Do I Enable the MySQLi Extension in PHP 7 on Ubuntu 14.04?

Enable MySQLi Extension in PHP 7

Issue:

Upon installing PHP 7 and MySQL 5.5.47 on Ubuntu 14.04, you may encounter a missing MySQLi extension, hindering the use of phpMyAdmin.

Solution:

The php5-mysql package is no longer supported in PHP 7. To enable MySQLi, install the following package:

sudo apt-get install php-mysql
Copy after login

This package includes both MySQL and MySQLi drivers, and will automatically update Apache and PHP 7.

Verification:

To confirm that MySQLi is enabled, you can use phpinfo():

<?php
phpinfo();
?>
Copy after login

Look for the "mysqli" section in the output to verify that the extension is loaded.

The above is the detailed content of How Do I Enable the MySQLi Extension in PHP 7 on Ubuntu 14.04?. For more information, please follow other related articles on the PHP Chinese website!

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
Latest Articles by Author
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template