I've installed XAMPP v3.2.2
with PHP 7.0.21
and composer 1.5.1
and building an application on laravel version 5.4.36
.
While installing spatie/laravel-analytics
package i'm getting error:
Problem 1
- This package requires php >=7.0 but your PHP version (5.6.4) does not satisfy that
requirement.
Problem 2
- Installation request for spatie/laravel-analytics ^3.1.0 -> satisfiable by
spatie/laravel-analytics[3.1.0].
- spatie/laravel-analytics 3.1.0 requires php ^7.0 -> your PHP version (7.0.21) overridden
by "config.platform.php" version (5.6.4) does not satisfy that requirement.
I had a line:
"require": {
"php": ">=5.6.4",
................
}
on my composer.json
file. Reading from a post on laracast I changed "php": ">=5.6.4" to "php": ">=7.0" and ran command composer dump-autoload
and composer update
and getting the error message:
Problem 1
- This package requires php >=7.0 but your PHP version (5.6.4) does not satisfy that
requirement.
I would be very thankful if anyone could point out what is causing this error and its possible solution.