Re: [PHP] "/home/{user}/directory"

2009-03-18 Thread Steve Holmes
On Tue, Mar 17, 2009 at 9:51 AM, Thiago H. Pojda wrote: > On Tue, Mar 17, 2009 at 10:42 AM, George Larson > wrote: > > > In my scripts, I usually define a boolean constant DEBUG. True looks for > > local copies of includes and echoes queries as they're used. > > > > My question is: > > > > Is the

Re: [PHP] "/home/{user}/directory"

2009-03-18 Thread George Larson
My question was, as usual, inadequately formed. Realpath() was interesting but I was creating directories to store archived data. In my limited testing, it seemed that realpath returns a relative path. Other words, if you're already in home and you try (realpath("~")."\archive\") then you get on

Re: [PHP] "/home/{user}/directory"

2009-03-18 Thread Waynn Lue
bash also has $HOME, which maps to /home/USERNAME, just in case you wanted another way. :) On Tue, Mar 17, 2009 at 6:47 AM, George Larson wrote: > Thanks! > > On Tue, Mar 17, 2009 at 9:46 AM, Stuart wrote: > > > 2009/3/17 George Larson > > > > In my scripts, I usually define a boolean constant

Re: [PHP] "/home/{user}/directory"

2009-03-17 Thread Stuart
2009/3/17 George Larson > In my scripts, I usually define a boolean constant DEBUG. True looks for > local copies of includes and echoes queries as they're used. > > My question is: > > Is there any way for me to reflect the actual home folder of the person > running the script? So it will be "

Re: [PHP] "/home/{user}/directory"

2009-03-17 Thread George Larson
That is correct. PHP on CLI. Thanks! On Tue, Mar 17, 2009 at 9:51 AM, Thiago H. Pojda wrote: > On Tue, Mar 17, 2009 at 10:42 AM, George Larson > wrote: > >> In my scripts, I usually define a boolean constant DEBUG. True looks for >> local copies of includes and echoes queries as they're used.

Re: [PHP] "/home/{user}/directory"

2009-03-17 Thread George Larson
Thanks! On Tue, Mar 17, 2009 at 9:46 AM, Stuart wrote: > 2009/3/17 George Larson > > In my scripts, I usually define a boolean constant DEBUG. True looks for >> local copies of includes and echoes queries as they're used. >> >> My question is: >> >> Is there any way for me to reflect the actua

Re: [PHP] "/home/{user}/directory"

2009-03-17 Thread Thiago H. Pojda
On Tue, Mar 17, 2009 at 10:42 AM, George Larson wrote: > In my scripts, I usually define a boolean constant DEBUG. True looks for > local copies of includes and echoes queries as they're used. > > My question is: > > Is there any way for me to reflect the actual home folder of the person > runnin

[PHP] "/home/{user}/directory"

2009-03-17 Thread George Larson
In my scripts, I usually define a boolean constant DEBUG. True looks for local copies of includes and echoes queries as they're used. My question is: Is there any way for me to reflect the actual home folder of the person running the script? So it will be "/home/george/foo" when I run it but, f