Jeremy Shovan wrote:
[color=blue]
> Michael Austin wrote:
>[color=green]
>> Jeremy Shovan wrote:
>>[color=darkred]
>>> What do I need to change to use the opendir() function when safe mode
>>> is in affect??
>>> I have root access to the server and can make any changes neccessary
>>> except turn safe mode off
>>>
>>> Thanks in advance,
>>> Jeremy[/color]
>>
>>
>>
>> who is the owner of the web server process? I could be wrong, but make
>> sure the process owner has access to the directory you are trying to
>> open. (ie in the same group, etc...)
>>
>> (but I am not wrong: see:
>>
>> go to the PHP site and search for "safe mode opendir" in the "online
>> docs"
>>
>> and you will find:
>>
>>
http://www.php.net/rmdir
>> ....
>> "Note: When safe mode is enabled, PHP checks whether the directory in
>> which you are about to operate has the same UID (owner) as the script
>> that is being executed."
>>
>> Michael Austin.[/color]
>
>
> Thanks for the reply. I understand that much but my problem is that I
> need scripts with different uid's to access the directory that I am
> opening. The code is used with several sites on the server. I read the
> documentation already but I dont quite understand what to do. I set the
> safe_mode_include_dir and safe_mode_exec_dir in the php.ini file but
> that didn't work.
>
> Jeremy[/color]
try putting the UID's and directories in the same group (btw, I am
"assuming" that this is Unix/Linux) chgrp dir <group of UID> and setting
the protections to 664 or 764 or 774... using chmod.
||+--> World Privilege
|+---> Group Privilege
+----> Owner Privilege
7 = rwx
6 = rw-
5 = r-x
4 = r--
3 = -wx
2 = -w-
1 = --x
0 = ---
Michael Austin.