I have installed PHP as module with apache. I want to know how I can run php script as a different user other the apache user ( which is www in my case ).
thanks
probably not, because the php module is executed by apache itself.
In safe mode, PHP is mostly assuming the privileges of the script's owner, but in some cases it runs as the normal www-user ("nobody" or such). Check out the documents in http://www.php.net, especially http://www.php.net/manual/phpfi2.html#safemode.
-jani