39210


こんにちは、閲覧ありがとうございます.  
初歩的な質問かもしれませんが、どうぞよろしくお願い致します.

現在`Laravel`と`PHP`について学習しております.  
諸事情により`PHP5.6`をつかって`Laravel`のプロジェクトを作成したいのですが、コマンドプロンプトから`Laravel new
プロジェクト名`とコマンドを打ちLaravelのプロジェクトを作成しようとすると以下のようなエラーが出ます.

> Crafting application... Loading composer repositories with package  
>  information Installing dependencies (including require-dev) from lock  
>  file Your requirements could not be resolved to an installable set of  
>  packages.
>
> Problem 1  
>  \- This package requires php >=7.0.0 but your PHP version (5.6.32) does not
> satisfy that requirement. Problem 2  
>  \- Installation request for doctrine/inflector v1.2.0 -> satisfiable by
> doctrine/inflector[v1.2.0].  
>  \- doctrine/inflector v1.2.0 requires php ^7.0 -> your PHP version (5.6.32)
> does not satisfy that requirement. Problem 3  
>  \- Installation request for laravel/framework v5.5.19 -> satisfiable by
> laravel/framework[v5.5.19].  
>  \- laravel/framework v5.5.19 requires php >=7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 4  
>  \- Installation request for swiftmailer/swiftmailer v6.0.2 -> satisfiable
> by swiftmailer/swiftmailer[v6.0.2].  
>  \- swiftmailer/swiftmailer v6.0.2 requires php >=7.0.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 5  
>  \- Installation request for phpdocumentor/reflection-docblock 4.1.1 ->
> satisfiable by phpdocumentor/reflection-docblock[4.1.1].  
>  \- phpdocumentor/reflection-docblock 4.1.1 requires php ^7.0 -> your PHP
> version (5.6.32) does not satisfy that requirement. Problem  
>  6  
>  \- 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 php ^7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 7  
>  \- Installation request for phpunit/php-token-stream 2.0.1 -> satisfiable
> by phpunit/php-token-stream[2.0.1].  
>  \- phpunit/php-token-stream 2.0.1 requires php ^7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 8  
>  \- Installation request for phpunit/phpunit 6.4.3 -> satisfiable by
> phpunit/phpunit[6.4.3].  
>  \- phpunit/phpunit 6.4.3 requires php ^7.0 -> your PHP version (5.6.32)
> does not satisfy that requirement. Problem 9  
>  \- Installation request for phpunit/phpunit-mock-objects 4.0.4 ->
> satisfiable by phpunit/phpunit-mock-objects[4.0.4].  
>  \- phpunit/phpunit-mock-objects 4.0.4 requires php ^7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 10  
>  \- Installation request for sebastian/comparator 2.0.2 -> satisfiable by
> sebastian/comparator[2.0.2].  
>  \- sebastian/comparator 2.0.2 requires php ^7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 11  
>  \- Installation request for sebastian/diff 2.0.1 -> satisfiable by
> sebastian/diff[2.0.1].  
>  \- sebastian/diff 2.0.1 requires php ^7.0 -> your PHP version (5.6.32) does
> not satisfy that requirement. Problem 12  
>  \- Installation request for sebastian/environment 3.1.0 -> satisfiable by
> sebastian/environment[3.1.0].  
>  \- sebastian/environment 3.1.0 requires php ^7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 13  
>  \- Installation request for sebastian/exporter 3.1.0 -> satisfiable by
> sebastian/exporter[3.1.0].  
>  \- sebastian/exporter 3.1.0 requires php ^7.0 -> your PHP version (5.6.32)
> does not satisfy that requirement. Problem 14  
>  \- Installation request for sebastian/global-state 2.0.0 -> satisfiable by
> sebastian/global-state[2.0.0].  
>  \- sebastian/global-state 2.0.0 requires php ^7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 15  
>  \- Installation request for sebastian/object-enumerator 3.0.3 ->
> satisfiable by sebastian/object-enumerator[3.0.3].  
>  \- sebastian/object-enumerator 3.0.3 requires php ^7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 16  
>  \- Installation request for sebastian/object-reflector 1.1.1 -> satisfiable
> by sebastian/object-reflector[1.1.1].  
>  \- sebastian/object-reflector 1.1.1 requires php ^7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 17  
>  \- Installation request for sebastian/recursion-context 3.0.0 ->
> satisfiable by sebastian/recursion-context[3.0.0].  
>  \- sebastian/recursion-context 3.0.0 requires php ^7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement. Problem 18  
>  \- Installation request for theseer/tokenizer 1.1.0 -> satisfiable by
> theseer/tokenizer[1.1.0].  
>  \- theseer/tokenizer 1.1.0 requires php ^7.0 -> your PHP version (5.6.32)
> does not satisfy that requirement. Problem 19  
>  \- laravel/framework v5.5.19 requires php >=7.0 -> your PHP version
> (5.6.32) does not satisfy that requirement.  
>  \- laravel/tinker v1.0.2 requires illuminate/console ~5.1 -> satisfiable by
> laravel/framework[v5.5.19].  
>  \- Installation request for laravel/tinker v1.0.2 -> satisfiable by
> laravel/tinker[v1.0.2].
>
> Application ready! Build something amazing.

Composerの方で指定した使用PHPのバージョンは`5.6`です.  
以前`PHP7.0`を使用していたときにはこのようなエラーは出ませんでした.  
調べてみたのですが解決できず、どうかお力添えください.  
足りない箇所はお教えいただけると幸いです.

【keyword】  
\- Windows10  
\- PHP 5.6.32 (cli) (built: Oct 25 2017 16:00:49)  
\- Laravel Installer 1.4.1  
\- Composer version 1.5.2 2017-09-11 16:59:25

【追記】  
Laravelのバージョンは`4.2.11`を使用したいと考えております.  
Laravelはコマンドプロンプトから`Composer global require
"laravel/installer=~1.1"`と入力してインストールしています.


CC BY-SA 3.0
2017-11-01T06:01:31.340
39201
2017-11-01T09:06:42.287
2017-11-01T07:42:12.320
question
php laravel composer
LaravelとPHPのバージョンについて


ログを見る限りlaravel5.5がインストールされているように見えます。  
php5.6を使用したいのならばlaravel5.4以前のものを入れないとだめそうですね。

composer create-project laravel/laravel --prefer-dist PROJECT_NAME 4.2.11

こんな感じのコマンドでインストールできないですかね。


CC BY-SA 3.0
2017-11-01T09:06:42.287
39210
2017-11-01T09:06:42.287
26006
39201
answer