Thursday, August 14, 2008

Gotcha Of The Day - GoDaddy and php.ini

While installing a 3rd party application on one my client's sites today, I needed to change the PHP config settings.

No problem, I'll just upload a .htaccess file, right? Wrong, when I did that, I ended up with a 500 Error - the reason why is described here.

I noticed there was a ini.php in the top level directory of the user account. However, when I made changes to it, nothing happened.

Turns out - php.ini is for configuring PHP 4. To configure PHP 5, you need to upload php5.ini. This is described here.

D'oh - I was so close, yet so far away.


  1. Anonymous5:18 PM

    Thank you for posting this. I've been fighting with them for about 8 hours over 2 weeks. "php.ini is for adjusting your settings. If it's not working, it's something in your .ini and we can't see that."

    "By default, only php.ini is automatically created during new account setup." But php5.ini is required on php 5 servers!

  2. Lance -

    I'm so glad you found this advice helpful. Why godaddy doesn't make their servers run php5 by default boggles my mind.


  3. Anonymous11:34 AM

    Thank You! I was struggling with ini.php setting.

    This information have been of great help.

  4. Anonymous12:25 PM

    This saved me so much time. I was trying to figure out why my changes to the php.ini file did nothing.

    The most simple problems cause the biggest headaches!!

  5. Glad this was such a big help!


  6. Anonymous6:24 AM

    Thanku Very really very much helpfull for me...

  7. Anonymous2:00 PM

    Thank for sharing this with us!

  8. tamilarasan.munusamy@gmail.com12:36 PM


    How can i change the php.ini file contents in godaddy? and where is the php.ini file?

  9. Anonymous6:00 PM

    I have been trying and trying to add php.ini or php5.ini to GoDaddy and just cannot get it to work. I have a file that consists entirely of the following lines:


    upload_max_filesize = 64M

    And that's it. I've named it both php.ini and php5.ini and uploaded it both ways and nothing happens. I still can't upload anything bigger than 8megs with Wordpress. Anyone have any idea what to do? Godaddy has been absolutely USELESS in helping. They just email me the same blah blah that's on their website.

  10. Have you tried uploading a page with phpinfo() on it? That might show you that upload_max_filesize is being set, and perhaps you're running into another limit (there's also a max post size, I think too).

    Also, you may be able to see which .ini file is in use.

    You could also try setting php variables in the .htaccess file.

  11. This post just saved me hours of headaches.

  12. ahh - thank you for the post! GoDaddy really should consider actually 'training' their support staff before putting them in the call center.