当尝试安装带有composer的laravel时,php版本错误



所以,现在已经两天了,我一直在努力在我的旧mac 10.6上安装laravel我的电脑运行PHP 5.5.27

但是由于某些原因,当我在终端中使用这段代码时:

composer create-project laravel/laravel project-name ~4.2.0 --prefer-dist

我得到这个:

- laravel/framework v4.2.9 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.8 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.7 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.6 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.5 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.4 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.3 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.2 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.17 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.16 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.15 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.14 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.13 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.12 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.11 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.10 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.1 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - laravel/framework v4.2.0 requires php >=5.4.0 -> your PHP version (5.3.26) or "config.platform.php" value does not satisfy that requirement. - Installation request for laravel/framework 4.2.* -> satisfiable by laravel/framework[v4.2.0, v4.2.1, v4.2.10, v4.2.11, v4.2.12, v4.2.13, v4.2.14, v4.2.15, v4.2.16, v4.2.17, v4.2.2, v4.2.3, v4.2.4, v4.2.5, v4.2.6, v4.2.7, v4.2.8, v4.2.9].

Your requirements could not be resolved to an installable set of packages.

有人知道为什么laravel不识别我的php版本吗?

显然,您的机器上安装了几个PHP。使用下面的shell命令检查PATH环境中的第一个php。

php

相关内容

  • 没有找到相关文章

最新更新