0
votes

Hello after I installed Laravel, I try to update the version 5.5 to 5.6 and unable to throws me an error: - laravel/framework v5.6.9 requires php ^7.1.3 -> your PHP version (7.0.10) does not satisfy that requirement.

I use XAMPP with PHP 7.2.10. I installed Composer with php 7 And does not help. Thanks

3
on your cmd you can run php -v to see the actual version. Due to mutiple php installation, sometimes it happens.Tuhin
If I check in CMD registered PHP 7.0.10 . But in path C:\xampp\php I get PHP 7.2.10 . How to coordinate their sons? Project Save On XAMPP folder. Thanks for the quick reply.YairBaruch

3 Answers

0
votes

Have a look at your composer.json. It is possible that there is a configuration parameter config.platform.php which contains the value 7.0.10. This feature allows to simulate a specific PHP version to composer. If you don't need it, you can remove it or force composer to install anyway by using the --ignore-platform-reqs parameter when updating the packages.

0
votes

If you are on Linux Debian, you can easily install the latest version of php with sudo apt-get install php x.x. On windows, this link might help. Then, try installing or upgrading Laravel from cmd and it should work sweet! Re-installing the latest verion of XAMPP may also do the work for you.

0
votes

You have to update your system's PATH environment variable so that it finds the newer version of php from your command line. You might have more than one installed right now, so it uses the first one it finds when it looks through the directories defined in your PATH. After updating the path variable, you might have to log out for it to apply.

You can check the version used by your command line with php --version. To see which version Apache is configured with, use phpinfo().