Composer can't find ext-mbstring even though it is installed Composer can't find ext-mbstring even though it is installed windows windows

Composer can't find ext-mbstring even though it is installed


Pay attention that, both in Windows and Linux, PHP can run with multiples php.ini configuration files.

In general, when you find this kind of issue, you have to double check that the configuration file loaded is the same that you are editing or you need to find the right path and add the extension also to the right php.ini configuration file.

While running a script through a web server, you can find the configuration file using the function

phpinfo();

and checking the line "Loaded Configuration File" (or just look for php.ini)PHP Info Screenshot

For what concern the CLI you can run in CMD

php --ini

and check the first lines in order to find the Loaded Configuration File value.