'composer' is not recognized as an internal or external command in windows server
I am using windows server 2008 os. i download composer setup.exe and install to my PC . when I try install composer
. I getting an error:
'composer' is not recognized as an internal or external command,
eg:-
c:xampphtdocsshop>composer install
'composer' is not recognized as an internal or external command,
operable program or batch file.
My environment variable PATH is shown below:
C:xamppphp;C:UsersAdministratorAppDataRoamingComposervendorbin
php windows composer-php environment-variables
add a comment |
I am using windows server 2008 os. i download composer setup.exe and install to my PC . when I try install composer
. I getting an error:
'composer' is not recognized as an internal or external command,
eg:-
c:xampphtdocsshop>composer install
'composer' is not recognized as an internal or external command,
operable program or batch file.
My environment variable PATH is shown below:
C:xamppphp;C:UsersAdministratorAppDataRoamingComposervendorbin
php windows composer-php environment-variables
add a comment |
I am using windows server 2008 os. i download composer setup.exe and install to my PC . when I try install composer
. I getting an error:
'composer' is not recognized as an internal or external command,
eg:-
c:xampphtdocsshop>composer install
'composer' is not recognized as an internal or external command,
operable program or batch file.
My environment variable PATH is shown below:
C:xamppphp;C:UsersAdministratorAppDataRoamingComposervendorbin
php windows composer-php environment-variables
I am using windows server 2008 os. i download composer setup.exe and install to my PC . when I try install composer
. I getting an error:
'composer' is not recognized as an internal or external command,
eg:-
c:xampphtdocsshop>composer install
'composer' is not recognized as an internal or external command,
operable program or batch file.
My environment variable PATH is shown below:
C:xamppphp;C:UsersAdministratorAppDataRoamingComposervendorbin
php windows composer-php environment-variables
php windows composer-php environment-variables
edited Sep 27 '16 at 12:53
danish dani
asked Sep 27 '16 at 12:23
danish danidanish dani
831212
831212
add a comment |
add a comment |
5 Answers
5
active
oldest
votes
For anyone coming here from Google who are facing the same issue. I just managed to solve this issue after all the other "solutions" other people suggested didn't work.
I installed Composer properly and the Environment variable was set but it just wouldn't work.
In my case composer is installed in C:ProgramDataComposerSetupbin
and this is exactly what is in my PATH
Environment variable. After messing around a bit trying to fix it I saw that under System variables
under PATH
there is something called PATHEXT
I opened that and added ;.PHAR
to the end of it. So it ended up like this:
And this is what my PATH
is now:
I closed all file explorer windows and command prompts and started a new CMD and ran composer --version
and it worked!
I hope this helps someone facing the same issue as me.
this worked! Just curious, why do we need to add;.PHAR
to thePATHTEXT
?
– indago
Aug 13 '18 at 19:06
@indago I can't be certain since I got this fixed by just randomly messing around but the reason I thought about adding .PHAR is that there is a Composer.phar inside the composer directory that I believe is what runs when you use composer commands , so when I saw that it's not there I added it and it immediately fixed the issue. Glad you got it sorted as well!
– Mahan_F
Aug 13 '18 at 19:33
for me just restarting cmd (as admin) was enough
– Tadas V.
Oct 31 '18 at 22:23
add a comment |
I had the same problem, I kept repeating the composer installation until it was resolved this way:
1) Download the composer installer (.exe) and put it on C:/XAMPP.
2) Run the installer by just clicking next till the end.
3) Open command-line (cmd) and cd to your project directory (C:/XAMPP/htdocs/myproject) and type composer and see if you have it installed.
4) It should work now, let's say you want to install a PHP framework from your project directory: cmd=>composer require slim/slim "^3.0"
.
add a comment |
https://getcomposer.org/doc/00-intro.md#installation-windows
Close your current terminal and open a new one.
You do not need to restart your computed, simply close your current terminal and open a new one.
– user320487
Jan 18 '18 at 23:20
add a comment |
the solution is . user complete composer path instead of composer install
eg:- C:ProgramDataComposerSetupbincomposer install" instead of "composer install
add a comment |
If u can't find composer file than follow only 2 steps
1- Download composer file from [https://getcomposer.org/download/]<click on Composer-Setup.exe>
2- Install above file at your project root dir. and give second path is your php.exe file and finally solve this issue.
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f39724594%2fcomposer-is-not-recognized-as-an-internal-or-external-command-in-windows-serve%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
5 Answers
5
active
oldest
votes
5 Answers
5
active
oldest
votes
active
oldest
votes
active
oldest
votes
For anyone coming here from Google who are facing the same issue. I just managed to solve this issue after all the other "solutions" other people suggested didn't work.
I installed Composer properly and the Environment variable was set but it just wouldn't work.
In my case composer is installed in C:ProgramDataComposerSetupbin
and this is exactly what is in my PATH
Environment variable. After messing around a bit trying to fix it I saw that under System variables
under PATH
there is something called PATHEXT
I opened that and added ;.PHAR
to the end of it. So it ended up like this:
And this is what my PATH
is now:
I closed all file explorer windows and command prompts and started a new CMD and ran composer --version
and it worked!
I hope this helps someone facing the same issue as me.
this worked! Just curious, why do we need to add;.PHAR
to thePATHTEXT
?
– indago
Aug 13 '18 at 19:06
@indago I can't be certain since I got this fixed by just randomly messing around but the reason I thought about adding .PHAR is that there is a Composer.phar inside the composer directory that I believe is what runs when you use composer commands , so when I saw that it's not there I added it and it immediately fixed the issue. Glad you got it sorted as well!
– Mahan_F
Aug 13 '18 at 19:33
for me just restarting cmd (as admin) was enough
– Tadas V.
Oct 31 '18 at 22:23
add a comment |
For anyone coming here from Google who are facing the same issue. I just managed to solve this issue after all the other "solutions" other people suggested didn't work.
I installed Composer properly and the Environment variable was set but it just wouldn't work.
In my case composer is installed in C:ProgramDataComposerSetupbin
and this is exactly what is in my PATH
Environment variable. After messing around a bit trying to fix it I saw that under System variables
under PATH
there is something called PATHEXT
I opened that and added ;.PHAR
to the end of it. So it ended up like this:
And this is what my PATH
is now:
I closed all file explorer windows and command prompts and started a new CMD and ran composer --version
and it worked!
I hope this helps someone facing the same issue as me.
this worked! Just curious, why do we need to add;.PHAR
to thePATHTEXT
?
– indago
Aug 13 '18 at 19:06
@indago I can't be certain since I got this fixed by just randomly messing around but the reason I thought about adding .PHAR is that there is a Composer.phar inside the composer directory that I believe is what runs when you use composer commands , so when I saw that it's not there I added it and it immediately fixed the issue. Glad you got it sorted as well!
– Mahan_F
Aug 13 '18 at 19:33
for me just restarting cmd (as admin) was enough
– Tadas V.
Oct 31 '18 at 22:23
add a comment |
For anyone coming here from Google who are facing the same issue. I just managed to solve this issue after all the other "solutions" other people suggested didn't work.
I installed Composer properly and the Environment variable was set but it just wouldn't work.
In my case composer is installed in C:ProgramDataComposerSetupbin
and this is exactly what is in my PATH
Environment variable. After messing around a bit trying to fix it I saw that under System variables
under PATH
there is something called PATHEXT
I opened that and added ;.PHAR
to the end of it. So it ended up like this:
And this is what my PATH
is now:
I closed all file explorer windows and command prompts and started a new CMD and ran composer --version
and it worked!
I hope this helps someone facing the same issue as me.
For anyone coming here from Google who are facing the same issue. I just managed to solve this issue after all the other "solutions" other people suggested didn't work.
I installed Composer properly and the Environment variable was set but it just wouldn't work.
In my case composer is installed in C:ProgramDataComposerSetupbin
and this is exactly what is in my PATH
Environment variable. After messing around a bit trying to fix it I saw that under System variables
under PATH
there is something called PATHEXT
I opened that and added ;.PHAR
to the end of it. So it ended up like this:
And this is what my PATH
is now:
I closed all file explorer windows and command prompts and started a new CMD and ran composer --version
and it worked!
I hope this helps someone facing the same issue as me.
answered Aug 12 '18 at 18:32
Mahan_FMahan_F
516511
516511
this worked! Just curious, why do we need to add;.PHAR
to thePATHTEXT
?
– indago
Aug 13 '18 at 19:06
@indago I can't be certain since I got this fixed by just randomly messing around but the reason I thought about adding .PHAR is that there is a Composer.phar inside the composer directory that I believe is what runs when you use composer commands , so when I saw that it's not there I added it and it immediately fixed the issue. Glad you got it sorted as well!
– Mahan_F
Aug 13 '18 at 19:33
for me just restarting cmd (as admin) was enough
– Tadas V.
Oct 31 '18 at 22:23
add a comment |
this worked! Just curious, why do we need to add;.PHAR
to thePATHTEXT
?
– indago
Aug 13 '18 at 19:06
@indago I can't be certain since I got this fixed by just randomly messing around but the reason I thought about adding .PHAR is that there is a Composer.phar inside the composer directory that I believe is what runs when you use composer commands , so when I saw that it's not there I added it and it immediately fixed the issue. Glad you got it sorted as well!
– Mahan_F
Aug 13 '18 at 19:33
for me just restarting cmd (as admin) was enough
– Tadas V.
Oct 31 '18 at 22:23
this worked! Just curious, why do we need to add
;.PHAR
to the PATHTEXT
?– indago
Aug 13 '18 at 19:06
this worked! Just curious, why do we need to add
;.PHAR
to the PATHTEXT
?– indago
Aug 13 '18 at 19:06
@indago I can't be certain since I got this fixed by just randomly messing around but the reason I thought about adding .PHAR is that there is a Composer.phar inside the composer directory that I believe is what runs when you use composer commands , so when I saw that it's not there I added it and it immediately fixed the issue. Glad you got it sorted as well!
– Mahan_F
Aug 13 '18 at 19:33
@indago I can't be certain since I got this fixed by just randomly messing around but the reason I thought about adding .PHAR is that there is a Composer.phar inside the composer directory that I believe is what runs when you use composer commands , so when I saw that it's not there I added it and it immediately fixed the issue. Glad you got it sorted as well!
– Mahan_F
Aug 13 '18 at 19:33
for me just restarting cmd (as admin) was enough
– Tadas V.
Oct 31 '18 at 22:23
for me just restarting cmd (as admin) was enough
– Tadas V.
Oct 31 '18 at 22:23
add a comment |
I had the same problem, I kept repeating the composer installation until it was resolved this way:
1) Download the composer installer (.exe) and put it on C:/XAMPP.
2) Run the installer by just clicking next till the end.
3) Open command-line (cmd) and cd to your project directory (C:/XAMPP/htdocs/myproject) and type composer and see if you have it installed.
4) It should work now, let's say you want to install a PHP framework from your project directory: cmd=>composer require slim/slim "^3.0"
.
add a comment |
I had the same problem, I kept repeating the composer installation until it was resolved this way:
1) Download the composer installer (.exe) and put it on C:/XAMPP.
2) Run the installer by just clicking next till the end.
3) Open command-line (cmd) and cd to your project directory (C:/XAMPP/htdocs/myproject) and type composer and see if you have it installed.
4) It should work now, let's say you want to install a PHP framework from your project directory: cmd=>composer require slim/slim "^3.0"
.
add a comment |
I had the same problem, I kept repeating the composer installation until it was resolved this way:
1) Download the composer installer (.exe) and put it on C:/XAMPP.
2) Run the installer by just clicking next till the end.
3) Open command-line (cmd) and cd to your project directory (C:/XAMPP/htdocs/myproject) and type composer and see if you have it installed.
4) It should work now, let's say you want to install a PHP framework from your project directory: cmd=>composer require slim/slim "^3.0"
.
I had the same problem, I kept repeating the composer installation until it was resolved this way:
1) Download the composer installer (.exe) and put it on C:/XAMPP.
2) Run the installer by just clicking next till the end.
3) Open command-line (cmd) and cd to your project directory (C:/XAMPP/htdocs/myproject) and type composer and see if you have it installed.
4) It should work now, let's say you want to install a PHP framework from your project directory: cmd=>composer require slim/slim "^3.0"
.
edited May 24 '17 at 14:33
Satan Pandeya
2,43231633
2,43231633
answered May 24 '17 at 10:49
aminamin
313
313
add a comment |
add a comment |
https://getcomposer.org/doc/00-intro.md#installation-windows
Close your current terminal and open a new one.
You do not need to restart your computed, simply close your current terminal and open a new one.
– user320487
Jan 18 '18 at 23:20
add a comment |
https://getcomposer.org/doc/00-intro.md#installation-windows
Close your current terminal and open a new one.
You do not need to restart your computed, simply close your current terminal and open a new one.
– user320487
Jan 18 '18 at 23:20
add a comment |
https://getcomposer.org/doc/00-intro.md#installation-windows
Close your current terminal and open a new one.
https://getcomposer.org/doc/00-intro.md#installation-windows
Close your current terminal and open a new one.
edited May 30 '18 at 7:18
answered Jan 18 '18 at 18:46
FurquanFurquan
114
114
You do not need to restart your computed, simply close your current terminal and open a new one.
– user320487
Jan 18 '18 at 23:20
add a comment |
You do not need to restart your computed, simply close your current terminal and open a new one.
– user320487
Jan 18 '18 at 23:20
You do not need to restart your computed, simply close your current terminal and open a new one.
– user320487
Jan 18 '18 at 23:20
You do not need to restart your computed, simply close your current terminal and open a new one.
– user320487
Jan 18 '18 at 23:20
add a comment |
the solution is . user complete composer path instead of composer install
eg:- C:ProgramDataComposerSetupbincomposer install" instead of "composer install
add a comment |
the solution is . user complete composer path instead of composer install
eg:- C:ProgramDataComposerSetupbincomposer install" instead of "composer install
add a comment |
the solution is . user complete composer path instead of composer install
eg:- C:ProgramDataComposerSetupbincomposer install" instead of "composer install
the solution is . user complete composer path instead of composer install
eg:- C:ProgramDataComposerSetupbincomposer install" instead of "composer install
answered Nov 10 '16 at 7:41
danish danidanish dani
831212
831212
add a comment |
add a comment |
If u can't find composer file than follow only 2 steps
1- Download composer file from [https://getcomposer.org/download/]<click on Composer-Setup.exe>
2- Install above file at your project root dir. and give second path is your php.exe file and finally solve this issue.
add a comment |
If u can't find composer file than follow only 2 steps
1- Download composer file from [https://getcomposer.org/download/]<click on Composer-Setup.exe>
2- Install above file at your project root dir. and give second path is your php.exe file and finally solve this issue.
add a comment |
If u can't find composer file than follow only 2 steps
1- Download composer file from [https://getcomposer.org/download/]<click on Composer-Setup.exe>
2- Install above file at your project root dir. and give second path is your php.exe file and finally solve this issue.
If u can't find composer file than follow only 2 steps
1- Download composer file from [https://getcomposer.org/download/]<click on Composer-Setup.exe>
2- Install above file at your project root dir. and give second path is your php.exe file and finally solve this issue.
answered Nov 11 '17 at 11:35
Yagnesh bhalalaYagnesh bhalala
400412
400412
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f39724594%2fcomposer-is-not-recognized-as-an-internal-or-external-command-in-windows-serve%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown