note 32692 added to function.shell-exec

From: Date: Wed, 04 Jun 2003 15:01:51 +0000
Subject: note 32692 added to function.shell-exec
Groups: php.notes 
Request: Send a blank email to php-notes+get-49725@lists.php.net to get a copy of this message
When running subprocesses via shell_exec (and maybe others) from Apache/mod_php4, Apache's environment variables don't seem to be passed on to the subprocess environment unless you specifically force them by using putenv something like this: $remaddr = getenv("REMOTE_ADDR"); putenv("REMOTE_ADDR=$remaddr"); shell_exec("/path/to/subprocess"); ---- Manual Page -- http://www.php.net/manual/en/function.shell-exec.php Edit Note -- http://master.php.net/manage/user-notes.php?action=edit+32692 Delete Note -- http://master.php.net/manage/user-notes.php?action=delete+32692&report=yes Reject Note -- http://master.php.net/manage/user-notes.php?action=reject+32692&report=yes

« previous php.notes (#49725) next »