Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to enable mysqli on XAMPP?

Tags:

php

xampp

mysqli

By seeing suggestions throughout the Internet I tried to convert all my queries to mysqli.

But mysqli is not working in my XAMPP. I checked my PHP folder and there is a php_mysqli.dll file... still it doesn't work

like image 863
funtime Avatar asked Aug 29 '12 03:08

funtime


People also ask

Does xampp support MySQLi?

Because these xampp versions also support Mysqli by default.

How configure MySQLi in PHP?

Open your php. ini file ( php configuration file ) inside your PHP directory ( or windows directory ) . Search for mysqli and enable the dll by removing ; before it. You may have to re-boot your system.

How can I enable the MySQLi extension in PHP 8?

ini file to php. ini and enable the extension by removing semicolon in the php. ini file. Don't forget to restart the server (Apache or Ngnix) after updating php.


2 Answers

Have you declare it to php.ini to load it? If no, try find this in php.ini and add php_mysqli.dll

;;;;;;;;;;;;;;;;;;;;;;
; Dynamic Extensions ;
;;;;;;;;;;;;;;;;;;;;;;

; If you wish to have an extension loaded automatically, use the following
; syntax:
;
;   extension=modulename.extension
;
; For example, on Windows:
;
;   extension=msql.dll
;
; ... or under UNIX:
;
;   extension=msql.so
;
; ... or with a path:
;
;   extension=/path/to/extension/msql.so
;
; If you only provide the name of the extension, PHP will look for it in its
; default extension directory.
;
; Windows Extensions
; Note that ODBC support is built in, so no dll is needed for it.
; Note that many DLL files are located in the extensions/ (PHP 4) ext/ (PHP 5)
; extension folders as well as the separate PECL DLL download (PHP 5).
; Be sure to appropriately set the extension_dir directive.

extension= php_mysqli.dll
like image 50
Furry Avatar answered Oct 08 '22 01:10

Furry


Goto the directory phpMyAdmin, find there is a file with name config.inc.php, open the file and find a line there as:
$cfg['Servers'][$i]['extension'] = 'mysql';
just change mysql to mysqli.

like image 40
Bibhu S. Avatar answered Oct 08 '22 00:10

Bibhu S.