Mar 27, 2012 at 2:29 pm UTC | 

Let's face it... GoDaddy is not the best choice as a hosting partner (or any shared hosting plan for that matter).  However, it's inexpensive and well marketed, so there will be clients that choose GoDaddy for their hosting needs.

If you have a web product on GoDaddy, most likely it's in the form of a PHP website.  After you've uploaded the site, you'll probably encounter a few issues with how PHP is configured on GoDaddy Linux 4GH accounts.  Here's a list of questions and their answers:

 

Q:  Why is PHP not running as version 5.3?

A:  The default version as of this writing is 5.2.  To change this you have two options:

1. Go to the 'Programming Languages' section of the GoDaddy Dashboard, select PHP, then select the version of PHP you would like to use.  Then 'Update'.  This will take about 20 minutes to go into effect.

http://support.godaddy.com/help/3937?locale=en

2. Within your .htaccess file add..

 AddHandler x-httpd-php5-3 .php

This will take effect immediately.

 

Q.  How do I configure my PHP settings?

A.  GoDaddy hosts their own php.ini file in their /web/conf/ path.  However you cannot edit this file, so the alternative is to copy the php.ini from this location and place it in your web root path (html directory).  For php5, name it php5.ini.

You might wonder if the configuration settings take effect immediately.  They unfortunately do not.  What you will need to do is go to your hosting panel, find the 'System Processes' panel, then click the 'End Web' button.  This will stop the local configuration of Apache for your hosting and it will restart as soon as you load a new web page.  To confirm, you can create a file with phpinfo() in your web root to test that the configuration file is in use.

 

Q.  Why are PHP errors displayed on the web page?

A.  By default this is enabled but can be turned off.  This is configured within your custom php.ini as created above.  Just make the following change below and restart the web processes.

display_errors = Off

 

Q.  How do I get access to error logs?

A.  There's a few things you'll need to do.  To enable Apache logs, go to your hosting panel, find the 'Error Logs' section, and click 'Update'.  This will enable Apache to log any errors.  The error logs will be found in a directory called 'error_logs' at the root level, but not within your web root.  You can then access them via SSH or File Manager.

http://support.godaddy.com/help/article/1197

The second step is to enable PHP logging.  Edit your php.ini and restart the web processes with the following settings.

log_errors = On
error_log = [path to your log file] 

That should do it!  Hope this has saved you some time and effort.


Comments

  • redlinesolutions

    Test test

  • http://www.mk-dizajn.com/ Kresimir Pendic

    thanx for system processes button,, that helped a lot ::))


Find out more...

We are company that builds custom websites and mobile apps.

Are you interested in our services?
Contact Us.

 

Topics

%{%{gallerybox.dataid}[email protected]@value}
Open in New Window