Jim Lucas dedi ki:
> Abdullah Ramazanoglu wrote:

  --8<--

>> Is it possible at all to use environment variables in php.ini, or is
>> there any other solution to the problem above?
>> 
>> Thank you.
> 
> Read this:
> 
> http://us3.php.net/manual/en/configuration.php#configuration.file
> 
> You can put a file in any other these locations that will be read by the
> cgi when it is started.
> 
> my suggestion would be to use a single php.ini file in a global location.
>  Then symlink a php.ini to there home directory or web root.
> 
> Then set perms on the single global file such that only you can write to
> it, but everybody can read
> it.  This should work for you.

That was also my first inclination but I had to abandon it, because then I
couldn't give different parameters for different virtual hosts.

For instance currently I (have to) centrally use "error_log=php_error.log"
and this causes a "php_error.log" been created everywhere (as I can't give
absolute address, each php script creates a log in the directory it
resides in.) If only I would have been able to give something to the
effect of "php_error=$HOME/php_error.log" then every user would've had
only one log file.

Another drawback with central read-only php.ini is that users won't be able
to tweak php.ini to certain extent (but not much - just like php_flag and
php_value). With cgi-php, users are either too restricted (r/o php.ini) or
too free (r/w php.ini).

Thanks and regards
-- 
Abdullah Ramazanoglu
aramazan ÄT myrealbox D0T cöm

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to