graeme_p - 6:05 am on Oct 25, 2013 (gmt 0)
Yes, it is usual for PHP (or Apache if you are using mod_php) to run as "nobody" to limit its access to the file system to reduce the damage that can be done if the server is hacked.
You can configure PHP/Apache to run as a different user, but if you run it as a user that has write access to your .php files or anything important, you are giving up a layer of security. If you run PHP as fastcgi rather than mod_php, it can be a different user from Apache.
I do not think chown() is going to work because it requires PHP to be running as root, which is a really bad idea.
The right solution is probably to configure things so that it is OK for files written by PHP to belong to "nobody".