So, you mistakenly tampered with a code on your theme files editor and your blog broke? You can restore the blog using the exported XML file.

In my post on blog maintenance strategies and management, I wrote about how I often exported my whole blog and saved on my external hard drive. This is where the exported file comes in handy.

To restore your blog, this can be done in two ways depending on what broke.

Using a staging site or the free WordPress CMS.

Reinstalling WordPress afresh.

Post-image-in-post-Ad

Let me breakdown the steps to each.

Exported XML file 2
Image by freepik

***

Using a staging site or the free WordPress CMS.

Creating a staging site simply means, creating a site that is not meant for the public eye. You can do this by creating a subdomain or on a WordPress accessible only on your computer.

I like to use this method if I’m only looking for a part of the site and what broke did not affect the whole site.

1. To do this, watch this video to create a subdomain or a free WordPress CMS for Apple or Window users.

2. Install WordPress on the subdomain using the steps in this post to re-install and set up a fresh WordPress. Do not add any images or posts or pages. Your exported XML file already has that.

Post-image-in-post-Ad

3. When you are done with the basic settings, go to ToolsImport.

Reinstalling WordPress 3

4. Scroll to the WordPressInstall now. This will install the plugin.

Reinstalling WordPress 4

5. Go to the Plugin tab and activate the WordPress Importer.

6. Go back to ToolsImport. Scroll to the WordPressRun Importer. On the Import WordPressChoose file.

Post-image-in-post-Ad

Reinstalling WordPress 5

7. Ensure that the correct file name is selected. Click Upload file and import.

Reinstalling WordPress 6

8. Select the Author for the Posts and pages you are importing. Tick the Download and import file attachments and Submit.

Reinstalling WordPress 7

9. Once import is completed, crosscheck you post, pages, templates etc, to ensure they are displaying well and that’s it.

Post-image-in-post-Ad

If the error occurred only on one page, you could use this staged site to correct the original site.

 

***

Reinstalling WordPress afresh.

If what broke on your site is not something you can easily find, you might have to delete the WordPress you have and re-install.

To do this, go to Services My Services. On the hosting plan, click Active and go to the CPanel:

  1. From the CPanel, scroll down to Software WordPress Manager by Softaculous.

Install Your WordPress 1

Post-image-in-post-Ad

2. When it opens, go to the domain you want to uninstall. Click on the down arrow.

Reinstalling WordPress 1

3. Next, click on Remove to uninstall the WordPress. That’s all.

Reinstalling WordPress 2

4. After you have removed the WordPress, go back to WordPress Manager by Softaculous, use the steps in this post to re-install and set up a fresh WordPress. Do not add any images or posts or pages. Your exported XML file already has that.

5. Follow steps 3 to 9 above in Using a staging site to restore and import your XML file. That’s it.

***

I hope this has helped you. If you have any questions, drop them in the comments below.

Read Also: Creating a Structure for your blog.

***

Happy blogging…