Re: "/home/{user}/directory"

From: Date: Wed, 18 Mar 2009 09:16:25 +0000
Subject: Re: "/home/{user}/directory"
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-290213@lists.php.net to get a copy of this message
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 <george.g.larson@gmail.com>wrote: > Thanks! > > On Tue, Mar 17, 2009 at 9:46 AM, Stuart <stuttle@gmail.com> wrote: > > > 2009/3/17 George Larson <george.g.larson@gmail.com> > > > > 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, > >> for > >> another user, it would be "/home/their-username/foo"? > > > > > > $dir = realpath('~/foo'); > > > > -Stuart > > > > -- > > http://stut.net/ > > >

« previous php.general (#290213) next »