Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

PHP How to Build a WordPress Theme Launching a WordPress Site How to Migrate a Local WordPress Site to Live Server

Tyrel Hiebert
Tyrel Hiebert
14,739 Points

500 Internal Server Error

While migrating this project from MAMP to my live server I end up with just a 500 error when trying to visit the site.

  1. I backed up my local wordpress files and database using the BackUpWordPress plugin,
  2. created a new database using the wizard in cPanel with a new user,
  3. updated the 'DB_NAME' 'DB_USER' and 'DB_PASSWORD' in the wp-config.php file to reflect this database,
  4. imported the backed up .sql file to the new database in phpMyAdmin,
  5. defined a subdirectory in my wp-config.php file for 'WP_HOME' and 'WP_SITEURL',
  6. uploaded the files to the subdirectory.

I have triple checked the database information and the url structure to the subdirectory.

The site should be here: www.tyrelhiebert.com/projects/wp1/

Also of note, if I use the 1-click install for wordpress in cPanel (which I did for a previous exercise) the blog works perfectly, which I did here

I dont know if this is an error on my part or something to do with my server/hosting configuration maybe. I'm using Namecheap for hosting, is this maybe something I should contact them about?

Thanks for any help!! If you need some more info please ask!

3 Answers

Tyrel Hiebert
Tyrel Hiebert
14,739 Points

Thanks for that link! Helped alot!

500 error is internal server erorr issue , you can check your htaccess file, in my case i rollback my htaccess file into WP standart setting and it running properly after that.

Craig Bauer
Craig Bauer
3,376 Points

If your able to get into the dashboard try going to Settings > Permalinks and clicking save. Every time you move an install you need to do this.