PHP Developers Network

A community of PHP developers offering assistance, advice, discussion, and friendship.
 
Loading
It is currently Tue Sep 22, 2020 9:37 am

All times are UTC - 5 hours




Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: Path issue
PostPosted: Sun Jul 03, 2016 4:27 am 
Offline
Forum Newbie

Joined: Sun Jul 03, 2016 3:34 am
Posts: 3
Hello everyone,
I ran into an issue and dont have an explanation for it.
Trying to get global command prompt access for composer using the terminal.
First I set the path in the environment and rebooted, (windows) and checked it ok.
Next I made a little hiworld.php file and for the test put it file in the same dir as php.exe.

Thinking I had global capabilities I entered php hiworld.php from C:\ and get Could not open input file.
changed into the same dir as the hiworld.php and php.exe and it worked.
went back to the C:\ typed 'd' ^z and it echoed back: 'd'
Then typed php C:\dir0\dir1\dir2\hiworld.php it worked
Then typed php C:\dir0\dir1\dir2 hiworld.php it did not work Could not open input file

Whats perplexing is that a dos batch file and php 'd' both echo back from C:\
but it wont execute the .php file from C:\ unless I include the whole path? I assume that is the problem I am running into with composer as well?

I thought all I'd have to do is type php hiworld.php from anywhere and it would have worked like a dos batch file? An explanation escapes me.


Top
 Profile  
 
 Post subject: Re: Path issue
PostPosted: Sun Jul 03, 2016 7:48 am 
Offline
Spammer :|
User avatar

Joined: Wed Oct 15, 2008 2:35 am
Posts: 6617
Location: WA, USA


Top
 Profile  
 
 Post subject: Re: Path issue
PostPosted: Sun Jul 03, 2016 12:16 pm 
Offline
Forum Newbie

Joined: Sun Jul 03, 2016 3:34 am
Posts: 3


Top
 Profile  
 
 Post subject: Re: Path issue
PostPosted: Sun Jul 03, 2016 11:05 pm 
Offline
Spammer :|
User avatar

Joined: Wed Oct 15, 2008 2:35 am
Posts: 6617
Location: WA, USA


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group