I get an "Internal Server Error" on my PHP script!

Our servers use the suPHP method of executing PHP scripts. For security reasons, suPHP requires that scripts are not world-writable. If you get an internal server error, first check in the Error Log section of cPanel to see if there is an error message. It is likely that the problem is related to permissions. Using an FTP client or the cPanel File Manager, change the permission on your PHP files to 755. Files that are set to 777 will not be executed, and will give an internal server error.

Another potential reason for such errors may be due to you using a php_value or php_flag option in a .htaccess file. Any .htaccess statements of this sort must be removed, and placed in a new file called php.ini in the same directory. For instance, "php_flag register_globals On" should become "register_globals = On" in a php.ini file.

If you have any trouble with internal server errors and are unable to diagnose them yourself, please submit a support ticket and we can investigate.

  • 604 Users Found This Useful
Was this answer helpful?

Related Articles

What version of PHP and MySQL do you run?

We currently have several versions of PHP available, using the cPanel "MultiPHP" functionality,...

I'm getting memory limit errors in my PHP script

If you are receiving errors of the form "Fatal error: Allowed memory size exhausted" or similar...

I get a warning about "strtotime" in my PHP script

Some users have been receiving warnings similar to this recently: Warning: strtotime()...