Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

the requested PHP extension mbstring is missing from your system

my error message that I am getting from the composer is: Your requirements could not be resolved to an installable set of packages.

 Problem 1
    - Installation request for laravel/framework v5.4.28 -> satisfiable by laravel/framework[v5.4.28].
    - laravel/framework v5.4.28 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
  Problem 2
    - Installation request for phpunit/phpunit 5.7.21 -> satisfiable by phpunit/phpunit[5.7.21].
    - phpunit/phpunit 5.7.21 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
  Problem 3
    - laravel/framework v5.4.28 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
    - laravel/tinker v1.0.1 requires illuminate/console ~5.1 -> satisfiable by laravel/framework[v5.4.28].
    - Installation request for laravel/tinker v1.0.1 -> satisfiable by laravel/tinker[v1.0.1].

I have tried uncommenting the extension=php_mbstring.dll but it still raises the error. I have tried to change the extension_dir in the "php.ini" and it gives an error. Help is appreciated.

like image 611
Martin Savov Avatar asked Jul 03 '17 17:07

Martin Savov


2 Answers

-- EDIT BASED ON NEW INFORMATION --

Since this is Windows, re-installing PHP, enabling the extension in the PHP.INI file, and restarting the Webserver, should work.

-- PREVIOUS SOLUTION FOR LINUX --

You need to install mbstring for php.

Use:

 sudo apt-get install phpX.X-mbstring

Where X.X is your version number of PHP.

like image 79
TBowman Avatar answered Nov 19 '22 04:11

TBowman


Its worked for me:

sudo apt-get install php7.2-mbstring
like image 5
Diego Santa Cruz Mendezú Avatar answered Nov 19 '22 02:11

Diego Santa Cruz Mendezú