PHP Compiled as? (Problems with files) Print

  • 41

In answer to the many many questions we get about how PHP has been compiled, let us try to explain why and how and what to do for everything to function.

PHP5 Servers:
************
ALL of our PHP5 servers have PHP compiled as CGI with phpSuExec running. This will allow you the proper use of php uploads and prevents the user "nobody" taking ownership of your files. [SINCE V5.1.2+ YOU CAN NO LONGER OVER-RIDE THE SERVERS MAIN PHP.INI FILE]

Points to be aware of when running PHP compiled as CGI:
************************************************
#1 php scripts will now run using the userid of the account holder instead of user "nobody"

#2 World writable folders (chmod 777) will not be required for file uploads through php

#3 The php files will also have ownership of your userid

#4 php files (scripts) do not need 755 permissions. 644 is fine. In fact 400 or 600 is ok too (especially good for sensitive information)

#5 php_flag or php_value can NOT be used in .htaccess files (It will result in Internal Server Error)


Was this answer helpful?

« Back