Home > Development Tools > composer > What should I do if there is no response after entering the composer installation command?

What should I do if there is no response after entering the composer installation command?

藏色散人
Release: 2019-09-02 14:09:26
Original
4219 people have browsed it

What should I do if there is no response after entering the composer installation command?

What should I do if there is no response after entering the composer installation command?

Problem description 1: After the installation through the Composer-Setup.exe installation program is completed, the command is invalid, as shown below:

What should I do if there is no response after entering the composer installation command?

Solution:

Check whether the system environment is automatically configured. If not, please add the Path variable: C:\ProgramData\ComposerSetup\bin

Open cmd and enter composer - v. If the following is displayed, the installation is successful and can be accessed globally.

What should I do if there is no response after entering the composer installation command?

Switch to any directory and test composer -v again. The installation is successful as shown below.

What should I do if there is no response after entering the composer installation command?

Problem Description 2: Manual installation through the installation command failed, as shown below:

What should I do if there is no response after entering the composer installation command?

##Solution:

The error prompts that there is no Composer that supports PHP5.5.12. Update PHP version 5.6 and above.

Reinstall through the command. Before installation, please cd to the directory you want to install. Directory (can be created and specified by yourself), for example:

C:\Users\username>cd D: Switch to D drive

C:\Users\username>cd D:\Composer Switch to Composer folder (the installation directory you created)

D:\Composer>php -r "readfile('https://getcomposer.org/installer');" | php execute the installation command from this step The beginning and subsequent steps are the same as the tutorials in the official documentation, please refer to them by yourself to complete the subsequent operations.

The file path after the installation is completed. At this time, the composer -v command can only be executed in this directory, that is, it can only be accessed locally.

What should I do if there is no response after entering the composer installation command?

If you want global access, you need to configure the system environment variables yourself and add the Path variable: D:\Composer (please modify it according to your own installation directory)

For more composer usage technical articles, please visit the

composer usage tutorial column!

The above is the detailed content of What should I do if there is no response after entering the composer installation command?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template