I am trying to run the following code:
is_dir('~/tmp');
On a shared LAMP stack. It works fine, and returns TRUE. (That directory exists.) When I run the same code on my local box (Mac OSX 10.5, running Zend Server Community Ed) I get FALSE which is wrong because ~/tmp exists and has permissions set to 777.
I am missing a server directive somewhere, I think.
I have checked with phpInfo and I have (on both local and production):
safe_mode Off Off
safe_mode_exec_dir no value no value
safe_mode_gid Off Off
safe_mode_include_dir no value no value
open_basedir no value no value
So I think that I am missing something, but what?
[edit...] Some more information...
running the following on my local
get_current_user()
gives me 'username', which is the correct user whose ~/tmp directory I want to verify, BUT
shell_exec('whoami')
gives me 'daemon'. So I think I know where my problem is coming from. Now I just need to figure out if/how I can change the user that is running the web server on my local.