I am trying to resolve this error, and looking for answer everywhere. I checked and they are all enabled in ini file, and it's giving me error.
Loading composer repositories with package information
Installing dependencies from lock file
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for sabre/xml dev-master -> satisfiable by sabre/xml[dev-master].
- sabre/xml dev-master requires ext-dom * -> the requested PHP extension dom is missing from your system.
To enable extensions, verify that they are enabled in those .ini files:
- /etc/php/7.0/cli/php.ini
- /etc/php/7.0/cli/conf.d/10-mysqlnd.ini
- /etc/php/7.0/cli/conf.d/10-opcache.ini
- /etc/php/7.0/cli/conf.d/10-pdo.ini
- /etc/php/7.0/cli/conf.d/20-calendar.ini
- /etc/php/7.0/cli/conf.d/20-ctype.ini
- /etc/php/7.0/cli/conf.d/20-curl.ini
- /etc/php/7.0/cli/conf.d/20-exif.ini
- /etc/php/7.0/cli/conf.d/20-fileinfo.ini
- /etc/php/7.0/cli/conf.d/20-ftp.ini
- /etc/php/7.0/cli/conf.d/20-gd.ini
- /etc/php/7.0/cli/conf.d/20-gettext.ini
- /etc/php/7.0/cli/conf.d/20-iconv.ini
- /etc/php/7.0/cli/conf.d/20-igbinary.ini
- /etc/php/7.0/cli/conf.d/20-imap.ini
- /etc/php/7.0/cli/conf.d/20-json.ini
- /etc/php/7.0/cli/conf.d/20-mbstring.ini
- /etc/php/7.0/cli/conf.d/20-mcrypt.ini
- /etc/php/7.0/cli/conf.d/20-mysqli.ini
- /etc/php/7.0/cli/conf.d/20-pdo_mysql.ini
- /etc/php/7.0/cli/conf.d/20-pdo_pgsql.ini
- /etc/php/7.0/cli/conf.d/20-pdo_sqlite.ini
- /etc/php/7.0/cli/conf.d/20-pgsql.ini
- /etc/php/7.0/cli/conf.d/20-phar.ini
- /etc/php/7.0/cli/conf.d/20-posix.ini
- /etc/php/7.0/cli/conf.d/20-readline.ini
- /etc/php/7.0/cli/conf.d/20-shmop.ini
- /etc/php/7.0/cli/conf.d/20-sockets.ini
- /etc/php/7.0/cli/conf.d/20-sqlite3.ini
- /etc/php/7.0/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.0/cli/conf.d/20-sysvsem.ini
- /etc/php/7.0/cli/conf.d/20-sysvshm.ini
- /etc/php/7.0/cli/conf.d/20-tokenizer.ini
- /etc/php/7.0/cli/conf.d/20-zlib.ini
- /etc/php/7.0/cli/conf.d/25-memcached.ini
You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
I was facing the same issue after upgrading to ubuntu 16.04 which by default comes with php7. I was able to resolve it by running the following commands
Run the update comand:
sudo apt-get update
They mycript is missing and needs to be installed:
sudo apt-get install mcrypt php7.0-mcrypt
Run the upgrade command:
sudo apt-get upgrade
Install the php-mbstring which is also missing:
sudo apt-get install php-mbstring
Install the phpunit which is also missing:
sudo apt-get install phpunit
And it worked.
Related
so I get the following error while installing Pterodactyl panel:
Problem 1
- Installation request for aws/aws-sdk-php ^3.156 -> satisfiable by aws/aws-sdk-php[3.156.0].
- aws/aws-sdk-php 3.156.0 requires ext-simplexml * -> the requested PHP extension simplexml is missing from your system.
To enable extensions, verify that they are enabled in your .ini files:
- /etc/php/7.4/cli/php.ini
- /etc/php/7.4/cli/conf.d/10-mysqlnd.ini
- /etc/php/7.4/cli/conf.d/10-opcache.ini
- /etc/php/7.4/cli/conf.d/10-pdo.ini
- /etc/php/7.4/cli/conf.d/20-bcmath.ini
- /etc/php/7.4/cli/conf.d/20-calendar.ini
- /etc/php/7.4/cli/conf.d/20-ctype.ini
- /etc/php/7.4/cli/conf.d/20-exif.ini
- /etc/php/7.4/cli/conf.d/20-ffi.ini
- /etc/php/7.4/cli/conf.d/20-fileinfo.ini
- /etc/php/7.4/cli/conf.d/20-ftp.ini
- /etc/php/7.4/cli/conf.d/20-gettext.ini
- /etc/php/7.4/cli/conf.d/20-iconv.ini
- /etc/php/7.4/cli/conf.d/20-json.ini
- /etc/php/7.4/cli/conf.d/20-mbstring.ini
- /etc/php/7.4/cli/conf.d/20-mysqli.ini
- /etc/php/7.4/cli/conf.d/20-pdo_mysql.ini
- /etc/php/7.4/cli/conf.d/20-phar.ini
- /etc/php/7.4/cli/conf.d/20-posix.ini
- /etc/php/7.4/cli/conf.d/20-readline.ini
- /etc/php/7.4/cli/conf.d/20-shmop.ini
- /etc/php/7.4/cli/conf.d/20-sockets.ini
- /etc/php/7.4/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.4/cli/conf.d/20-sysvsem.ini
- /etc/php/7.4/cli/conf.d/20-sysvshm.ini
- /etc/php/7.4/cli/conf.d/20-tokenizer.ini
- /etc/php/7.4/cli/conf.d/20-zip.ini
You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
but then when doing sudo apt-get install -y php-simplexml
it gives me this:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package php-simplexml is a virtual package provided by:
php7.4-xml 7.4.10-1+ubuntu20.04.1+deb.sury.org+1
php7.3-xml 7.3.22-1+ubuntu20.04.1+deb.sury.org+1
php7.2-xml 7.2.33-1+ubuntu20.04.1+deb.sury.org+1
php7.1-xml 7.1.33-17+ubuntu20.04.1+deb.sury.org+1
php7.0-xml 7.0.33-30+ubuntu20.04.1+deb.sury.org+1
php5.6-xml 5.6.40-30+ubuntu20.04.1+deb.sury.org+1
You should explicitly select one to install.
E: Package 'php-simplexml' has no installation candidate
what can I do?
I'm new to ubuntu and have no clue of what to do
As error says, You should explicitly select one to install.
Search for php version on your machine by
php --version
then use that version to install the package
sudo apt-get install -y php<version>-xml
# so if you get 7.4 then it would be
sudo apt-get install -y php7.4-xml
Thanks to #bassxzero for noticing php version.
Before someone takes this down for duplication. I've checked the other pages and they weren't helpful.
I'm trying to install a package for Laravel 6 on PHP 7.2. I've also tried PHP 7.4.
Unfortunately, I get the following error:
laravel/framework v6.9.0 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
I've installed mbstring and uncommented it in both the php.ini files for 7.2 and 7.4:
extension=mbstring
The only solution to this I would know is restarting the apache2 server. But I still get the error.
My composer.json is requiring PHP 7.2.
I'm also presented with these errors:
- Installation request for laravel/framework (locked at v6.9.0, required as ^6.2) -> satisfiable by laravel/framework[v6.9.0].
To enable extensions, verify that they are enabled in your .ini files:
- /etc/php/7.4/cli/php.ini
- /etc/php/7.4/cli/conf.d/10-mysqlnd.ini
- /etc/php/7.4/cli/conf.d/10-opcache.ini
- /etc/php/7.4/cli/conf.d/10-pdo.ini
- /etc/php/7.4/cli/conf.d/15-xml.ini
- /etc/php/7.4/cli/conf.d/20-calendar.ini
- /etc/php/7.4/cli/conf.d/20-ctype.ini
- /etc/php/7.4/cli/conf.d/20-dom.ini
- /etc/php/7.4/cli/conf.d/20-exif.ini
- /etc/php/7.4/cli/conf.d/20-ffi.ini
- /etc/php/7.4/cli/conf.d/20-fileinfo.ini
- /etc/php/7.4/cli/conf.d/20-ftp.ini
- /etc/php/7.4/cli/conf.d/20-gd.ini
- /etc/php/7.4/cli/conf.d/20-gettext.ini
- /etc/php/7.4/cli/conf.d/20-iconv.ini
- /etc/php/7.4/cli/conf.d/20-json.ini
- /etc/php/7.4/cli/conf.d/20-mysqli.ini
- /etc/php/7.4/cli/conf.d/20-pdo_mysql.ini
- /etc/php/7.4/cli/conf.d/20-phar.ini
- /etc/php/7.4/cli/conf.d/20-posix.ini
- /etc/php/7.4/cli/conf.d/20-readline.ini
- /etc/php/7.4/cli/conf.d/20-shmop.ini
- /etc/php/7.4/cli/conf.d/20-simplexml.ini
- /etc/php/7.4/cli/conf.d/20-sockets.ini
- /etc/php/7.4/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.4/cli/conf.d/20-sysvsem.ini
- /etc/php/7.4/cli/conf.d/20-sysvshm.ini
- /etc/php/7.4/cli/conf.d/20-tokenizer.ini
- /etc/php/7.4/cli/conf.d/20-xmlreader.ini
- /etc/php/7.4/cli/conf.d/20-xmlwriter.ini
- /etc/php/7.4/cli/conf.d/20-xsl.ini
You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
Please run the below commands on Ubuntu OS.
Sudo apt-get update
sudo apt-get install php-mbstring
Try to install mbstring extension.
sudo apt-get install php7.4-mbstring
OS: Ubuntu 17.10 (Artful Aardvark)
I have installed the LAMP stack and Laravel, and when I tried composer install in my Laravel application, I got the following errors.
- Installation request for phar-io/manifest 1.0.1 -> satisfiable by phar-io/manifest[1.0.1].
- phar-io/manifest 1.0.1 requires ext-dom * -> the requested PHP extension dom is missing from your system.
Problem 2
- Installation request for phpunit/php-code-coverage 5.2.2 -> satisfiable by phpunit/php-code-coverage[5.2.2].
- phpunit/php-code-coverage 5.2.2 requires ext-dom * -> the requested PHP extension dom is missing from your system.
Problem 3
- Installation request for phpunit/phpunit 6.4.3 -> satisfiable by phpunit/phpunit[6.4.3].
- phpunit/phpunit 6.4.3 requires ext-dom * -> the requested PHP extension dom is missing from your system.
Problem 4
- Installation request for theseer/tokenizer 1.1.0 -> satisfiable by theseer/tokenizer[1.1.0].
- theseer/tokenizer 1.1.0 requires ext-dom * -> the requested PHP extension dom is missing from your system.
To enable extensions, verify that they are enabled in your .ini files:
- /etc/php/7.1/cli/php.ini
- /etc/php/7.1/cli/conf.d/10-opcache.ini
- /etc/php/7.1/cli/conf.d/10-pdo.ini
- /etc/php/7.1/cli/conf.d/20-calendar.ini
- /etc/php/7.1/cli/conf.d/20-ctype.ini
- /etc/php/7.1/cli/conf.d/20-exif.ini
- /etc/php/7.1/cli/conf.d/20-fileinfo.ini
- /etc/php/7.1/cli/conf.d/20-ftp.ini
- /etc/php/7.1/cli/conf.d/20-gettext.ini
- /etc/php/7.1/cli/conf.d/20-iconv.ini
- /etc/php/7.1/cli/conf.d/20-json.ini
- /etc/php/7.1/cli/conf.d/20-mbstring.ini
- /etc/php/7.1/cli/conf.d/20-pdo.ini
- /etc/php/7.1/cli/conf.d/20-phar.ini
- /etc/php/7.1/cli/conf.d/20-posix.ini
- /etc/php/7.1/cli/conf.d/20-readline.ini
- /etc/php/7.1/cli/conf.d/20-shmop.ini
- /etc/php/7.1/cli/conf.d/20-sockets.ini
- /etc/php/7.1/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.1/cli/conf.d/20-sysvsem.ini
- /etc/php/7.1/cli/conf.d/20-sysvshm.ini
- /etc/php/7.1/cli/conf.d/20-tokenizer.ini
You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
I have rechecked the files, all extensions are enabled and they are located in the
/usr/lib/php/20160303 folder.
Sometimes the problem is the php-xml extension.
Try:
sudo apt-get install php-xml
If still facing the issue then try
sudo apt-get install -y php7.1 php7.1-xml php7.1-mysql php7.1-curl php7.1-mbstring
Try following command:
sudo apt-get install php-mbstring
sudo apt-get install php-xml
As the log speaks we need to install the extension "dom". This is how we do it:
sudo apt install php7.1-dom
If the log shows only one extension missing, then the above command works. If there are other extensions missing, you can add those extensions in the same line like shown below:
sudo apt install php7.1-dom php7.1-ext-mbstring
That’s it. Now you won’t have any issues in installing PHP Composer. Enter composer install.
I'm trying to install cakephp using composer with this tutorial but after I run the command:
sudo composer create-project --prefer-dist cakephp/app my_app_name
I get the error:
Problem 1
- cakephp/cakephp-codesniffer 3.0.0 requires squizlabs/php_codesniffer ^3.0.0 -> satisfiable by squizlabs/php_codesniffer[3.0.0, 3.0.1, 3.0.2, 3.1.0, 3.1.1].
- cakephp/cakephp-codesniffer 3.0.1 requires squizlabs/php_codesniffer ^3.0.0 -> satisfiable by squizlabs/php_codesniffer[3.0.0, 3.0.1, 3.0.2, 3.1.0, 3.1.1].
- squizlabs/php_codesniffer 3.1.1 requires ext-simplexml * -> the requested PHP extension simplexml is missing from your system.
- squizlabs/php_codesniffer 3.1.0 requires ext-simplexml * -> the requested PHP extension simplexml is missing from your system.
- squizlabs/php_codesniffer 3.0.2 requires ext-simplexml * -> the requested PHP extension simplexml is missing from your system.
- squizlabs/php_codesniffer 3.0.1 requires ext-simplexml * -> the requested PHP extension simplexml is missing from your system.
- squizlabs/php_codesniffer 3.0.0 requires ext-simplexml * -> the requested PHP extension simplexml is missing from your system.
- Installation request for cakephp/cakephp-codesniffer ^3.0 -> satisfiable by cakephp/cakephp-codesniffer[3.0.0, 3.0.1].
To enable extensions, verify that they are enabled in your .ini
files:
- /etc/php/7.0/cli/php.ini
- /etc/php/7.0/cli/conf.d/10-opcache.ini
- /etc/php/7.0/cli/conf.d/10-pdo.ini
- /etc/php/7.0/cli/conf.d/20-calendar.ini
- /etc/php/7.0/cli/conf.d/20-ctype.ini
- /etc/php/7.0/cli/conf.d/20-curl.ini
- /etc/php/7.0/cli/conf.d/20-exif.ini
- /etc/php/7.0/cli/conf.d/20-fileinfo.ini
- /etc/php/7.0/cli/conf.d/20-ftp.ini
- /etc/php/7.0/cli/conf.d/20-gettext.ini
- /etc/php/7.0/cli/conf.d/20-iconv.ini
- /etc/php/7.0/cli/conf.d/20-intl.ini
- /etc/php/7.0/cli/conf.d/20-json.ini
- /etc/php/7.0/cli/conf.d/20-mbstring.ini
- /etc/php/7.0/cli/conf.d/20-phar.ini
- /etc/php/7.0/cli/conf.d/20-posix.ini
- /etc/php/7.0/cli/conf.d/20-readline.ini
- /etc/php/7.0/cli/conf.d/20-shmop.ini
- /etc/php/7.0/cli/conf.d/20-sockets.ini
- /etc/php/7.0/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.0/cli/conf.d/20-sysvsem.ini
- /etc/php/7.0/cli/conf.d/20-sysvshm.ini
- /etc/php/7.0/cli/conf.d/20-tokenizer.ini You can also run php --ini inside terminal to see which files are used by PHP in CLI mode.
I installed codeSniffer using both curl and composer. still I can't get rid of the error. any ideas what I am doing wrong?
I had a similar error at one point. It was fixed by installing php-xml. Make sure you install what waris said also.
sudo apt-get install php-xml
You need to install some extension i-e:
sudo pear install PHP_CodeSniffer
And also enable the php extensions for composer i-e curl,intl
sudo apt-get update
sudo apt-get install curl php-cli php-mbstring git unzip
extra options:
to install composer globally :
sudo php composer-setup.php --install-dir=/usr/local/bin --filename=composer
I had a similar error at one point. It was fixed by installing php-xml. Make sure you install what waris said also.
first php version
php -v
and
sudo apt-get install <your php version>-xml
It looks like codeSniffer requires squizlabs ^3.0.0.
And it also looks like you need to enable extensions in your .ini files.
I am having trouble while installation error in laravel.
First install xampp in ubuntu 16.04.
After that
cd /opt/lampp/htdocs/
composer create-project --prefer-dist laravel/laravel blog
installation laravel with composer some error occurs
E: Package 'php5-mcrypt' has no installation candidate
shwekayin#shwekayin-VirtualBox:/opt/lampp/htdocs$ composer create-project --prefer-dist laravel/laravel blog1
Installing laravel/laravel (v5.3.0)
- Installing laravel/laravel (v5.3.0)
Loading from cache
Created project in blog1
> php -r "file_exists('.env') || copy('.env.example', '.env');"
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- laravel/framework v5.3.4 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
- laravel/framework v5.3.3 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
- laravel/framework v5.3.2 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
- laravel/framework v5.3.1 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
- laravel/framework v5.3.0 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
- Installation request for laravel/framework 5.3.* -> satisfiable by laravel/framework[v5.3.0, v5.3.1, v5.3.2, v5.3.3, v5.3.4].
To enable extensions, verify that they are enabled in those .ini files:
- /etc/php/7.0/cli/php.ini
- /etc/php/7.0/cli/conf.d/10-opcache.ini
- /etc/php/7.0/cli/conf.d/10-pdo.ini
- /etc/php/7.0/cli/conf.d/20-calendar.ini
- /etc/php/7.0/cli/conf.d/20-ctype.ini
- /etc/php/7.0/cli/conf.d/20-exif.ini
- /etc/php/7.0/cli/conf.d/20-fileinfo.ini
- /etc/php/7.0/cli/conf.d/20-ftp.ini
- /etc/php/7.0/cli/conf.d/20-gettext.ini
- /etc/php/7.0/cli/conf.d/20-iconv.ini
- /etc/php/7.0/cli/conf.d/20-json.ini
- /etc/php/7.0/cli/conf.d/20-phar.ini
- /etc/php/7.0/cli/conf.d/20-posix.ini
- /etc/php/7.0/cli/conf.d/20-readline.ini
- /etc/php/7.0/cli/conf.d/20-shmop.ini
- /etc/php/7.0/cli/conf.d/20-sockets.ini
- /etc/php/7.0/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.0/cli/conf.d/20-sysvsem.ini
- /etc/php/7.0/cli/conf.d/20-sysvshm.ini
- /etc/php/7.0/cli/conf.d/20-tokenizer.ini
You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
How can I fix this error. My xampp php version is 7.0.10
The error message details what is wrong:
laravel/framework v5.3.4 requires ext-mbstring * -> the requested PHP extension mbstring is missing from your system.
Run sudo apt install php-mbstring to install it.
Run this
sudo apt-get install php libapache2-mod-php php-mcrypt php-mysql
if you no need to update php 7 again, Just run this
sudo apt-get install php-mcrypt
Install optional components these as well
libnet-libidn-perl - Perl bindings for GNU Libidn
php-all-dev - package depending on all supported PHP development packages
php-cgi - server-side, HTML-embedded scripting language (CGI binary) (default)
php-cli - command-line interpreter for the PHP scripting language (default)
php-common - Common files for PHP packages
php-curl - CURL module for PHP [default]
php-dev - Files for PHP module development (default)
php-gd - GD module for PHP [default]
php-gmp - GMP module for PHP [default]
sudo apt-get install package_name
Best ever tutorial How To Install Linux, Apache, MySQL, PHP (LAMP) stack on Ubuntu 16.04 -used and works for me
By default Ubuntu 16.04 has php7.0 installed. You need to install first php5 (in your case here). And then switch to php5 before reinstalling laravel.
https://askubuntu.com/questions/756879/cant-install-php5-on-ubuntu-16-04