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

WordPress

Uploading Local Wordpress to Live Wordpress site if you have updated a post or page on the Live site.

I hope this makes as much sense as it does in my head.

I have recently got my head around setting up a localhost environment for my existing website. I have downloaded my files, downloaded my database and successfully connected everything to a MAMP localhost.

I am using this to make css changes but I also want to use it to create new pages, change menus and create page templates etc.

Going from local to live is where I am struggling.

I understand that you need to upload the new site files via FTP and upload the changes to the database, however, my site is a constantly changing site for a local football team and the live database will have various new posts since I downloaded it last.

How can I upload my local database to reflect the changes I have made without overwriting new changes on the live database?

1 Answer

Greg Harris
Greg Harris
43,362 Points

This is a question of what specifically are you modifying in the database locally that you want to upload to the live server. As you already stated, you understand uploading your FTP files.

What are you updating locally? is that table or are those tables also being updated live?

If those specific tables aren't being changed on the live server, you could go into PHPMyAdmin and do an SQL export fo the table and then open up your live instance and run the query.

Maybe this is outside your toolbox???

The main thing that I will be updating on my live site is new blog posts ie club news updates. Im right in thinking that these new posts will be saved to the live database and if I upload my local database it would overwrite and the new content would be lost?

Im not very proficient with database's and wouldn't be comfortable with them at this stage.