0
votes

I'm in the process of completely re-coding a client's website. Their current site is using WordPress for their blog only; The rest of the website is just hand-coded PHP. Their entire new site will be utilizing WordPress.

My question is, how do I import just the existing blog database into my current WordPress setup? In other words, I've installed a fresh WordPress into the new website's directory, and already added a bunch of pages and custom post types. Now I have to import all of the blog posts and comments from the old site, but I'm afraid of overwriting everything currently in the new database. How can I import the posts and comments without altering anything I've already completed?

Thank you for any insight you can provide.

1

1 Answers

1
votes

You can do that by doing following steps:

1) Go to old wp admin panel and click Tools > Export, on opening page select Post from options and click export

enter image description here

2) After export XML, go to your new wp site admin panel and click Tools > Import. If it is first time to import, you will see a selection page for importer. Select Wordpress and install wordpress importer

enter image description here

3) You are near to complete. Open up Wordpress importer and upload XML file which you have export and downloaded from old wp site.

enter image description here

That's it. You can see your posts and comments on your new wp site