Asked
Updated
Viewed
10.5k times

I want to know how to get the mbstring PHP extension and where can I put the file to make PHPMyAdmin not to show this error:

The mbstring PHP extension was not found and you seem to be using multibyte charset. Without mbstring extension phpMyAdmin is unable to split strings correctly and it may result in unexpected results.
add a comment
1

2 Answers

  • Votes
  • Oldest
  • Latest
Answered

By default the mbstring extension is not enabled in PHP, but the extension is included and available for use. This extension allows you to work with and/or manipulate strings with multibyte encoding (think of special characters like that used with other languages or emojis). Depending on the operating system you are installing the extension, things may change slightly, but the PHP documentation around installing/enabling this is a good place to start.

As I mentioned, typically this extension is included in the download of PHP, however, it is likely not enabled via the php.ini file. Here is a screenshot of where it is located in my extensions directory for PHP 8.1.1 on Windows:

Screenshot of PHP extensions directory with mbstring

If for some reason you do not have the extension, then attempt to re-download the entire PHP package that matches the version you are using to find that extension. Copy and paste the extension into your ext directory.

Once you have ensured it is there, then you will need to open up your php.ini file and make sure that the extension=mbstring is uncommented like this where you remove the initial semicolon:

Uncomment extension for mbstring in php.ini

Semicolons comment lines out in the php.ini file. Finally, make sure you save this file with your changes, I don't know how many times I have helped developers figure out why it's not working when it ends up usually being because they forgot to save their php.ini file.

Finally, restart your Apache server (if PHP is loaded via that), or restart PHP if it's loading as a separate service. Or just restart everything to be sure you are reloading the PHP configuration file.

add a comment
0
Answered
Updated

You have to download the full library from PHP and unzip it to C:\php (not just the windows install file) it will be an extensions directory. Then in PHP.ini make sure you've uncommented the library and make sure the path to the extensions folder is correct. These instructions can be found in the documentation. If you are doing a Windows install read my tutorial on installing PHP with IIS as it explains there how to do this.

add a comment
0