Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

The requested PHP extension ext-mysql * is missing from your system. in php 7.1.7

I am trying to deploy php app on heroku. I have added tables to clearDB but stuck on this part: after adding

"ext-mysql":"*" 

this line in composer. json it thows me error saying ERROR: Your 'composer.json' lists dependencies inside 'require', but no 'composer.lock' was found. Please run 'composer update' to re-generate 'composer.lock' if necessary, and commit it into your repository.

and after running

php composer.phar update

I get this error

The requested PHP extension ext-mysql * is missing from your system. Install or enable PHP's mysql extension.
like image 973
Thesoham24 Avatar asked Oct 22 '25 11:10

Thesoham24


2 Answers

You can add --ignore-platform-reqs

Full code:

php composer.phar update --ignore-platform-reqs
like image 123
Ssimo Benlahcene Avatar answered Oct 24 '25 01:10

Ssimo Benlahcene


I hope this will help

http://php.net/manual/en/mysql.php

PHP 5 users can choose between the deprecated mysql extension, mysqli, or PDO_MySQL. PHP 7 removes the mysql extension, leaving only the latter two options.

like image 38
NewBee Avatar answered Oct 24 '25 02:10

NewBee



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!