How to Secure PHP?

To secure PHP log into shell and type the following: # php -i |grep php.ini than, --Turn on safe_mode --Replace “disable_functions = “ by “disable_functions = dl,system,exec,passthru,shell_exec” --Replace “register_globals = On” with “register_globals = Off” --Run PHP through PHPsuexec to recompile PHP with suexec. on cPanel /scripts/easyapache.