Re: cannot get php through apache to write to my home dir on shared server

From: Date: Thu, 26 Jun 2003 12:17:21 +0000
Subject: Re: cannot get php through apache to write to my home dir on shared server
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-152968@lists.php.net to get a copy of this message
From: "frank reeves" <frankreeves@yahoo.com> > I have an account on shared server and am trying to > write a logfile (a dump of an email which i use mail() > to send) to a logfile in my home dir. This logfile > will grow with all emails send by my app and will thus > give me an archive of sorts. > > However, because php is executed through apache as > user nobody it does not have permission to write to my > linux home dir (fopen("log.file","a")) fails with > permission denied). I dont want to open my home dir to > the world to allow this operation but I also dont want > to write my log to /var/tmp as user nobody. > > Does anyone know how I can get php to write as me to > my home dir ? You can only get this with PHP as a CGI. > I suppose i could write a shell script and have my app > call this but that seems a bit convoluted. Other option is to read/write the file over FTP, since you'll be able to log in as you. ---John Holmes...

« previous php.general (#152968) next »