MYHOSPITALNOW.COM

Find Trusted Doctors & Hospitals

Discover healthcare providers, compare hospitals, and explore treatment options worldwide.

Free Treatment Quotes • Doctor Search • Hospital Comparison

Find Healthcare Options

www.myhospitalnow.com

How to Move a Live WordPress Site to Local Server

Why we are discussing on this topic because we are here to tell you when any developer of WordPress wants to test new themes, plugins, or another development testing. then he creates a local setup of any WordPress site. so let’s look below how to do this?

first of all, you have to take a backup of WordPress site and create a database for it in your localhost/phpmyadmin. Click on New button for creating a new database ( eg. aiaviation ) and put a name for database and click on create button.

PhpMyAdmin Create database form with New clicked and aiaviation entered as the database name

Step 2: then take database backup and import in the database and click on Go button.

PhpMyAdmin Import tab for the aiaviation database with file chooser for the SQL backup

Step 3: put the backup file in your xampp location (eg.: C:\xampp\htdocs)

Windows Explorer showing aiaviationacademy.com site folder in C:\xampp\htdocs
file location in xampp

Step 4: Then go to your backup file location and open wp-config.php file in editor

WordPress site files in the xampp htdocs folder with wp-config.php selected
wp-config.php file

Step 5: Then change to your wp-config file like- ‘DB_NAME’, ‘DB_USER’, ‘DB_PASSWORD’, ‘DB_HOST’ and add below two lines to your wp-config file
define(‘WP_HOME’,’http://aiacademy/’);
define(‘WP_SITEURL’,’http://aiacademy/’);

Step 6: now go to your database and select your options table and change siteurl & home column url

PhpMyAdmin mooju_options table with siteurl and home values changed to http://aiacademy/
mooju_options table column editing

Step 7: Now you have to edit your virtual host file httpd-vhosts.conf and hosts file. for this, you have to open notepad as administrator.

Windows Explorer at C:\xampp\apache\conf\extra with httpd-vhosts.conf highlighted
apache vhosts file location
Windows Explorer at C:\Windows\System32\drivers\etc with the hosts file highlighted
hosts file location

Step 8: add this lines to hosts file
127.0.0.1 aiacademy
::1 aiacademy

Step 9: after that add below lines to httpd-vhosts.conf and change DocumentRoot, ErrorLog, CustomLog and Directory location with your site name and location.

after all above setup your site will be available in localhost and you can make changes. if you find any bug then you check out bugs on stackoverflow and wordpress support page .

Thanks for supporting us and if you have any question then comment us we will give you the best solution to this topic.

Find Trusted Cardiac Hospitals

Compare heart hospitals by city and services — all in one place.

Explore Hospitals
MotoShare.in provides the perfect two-wheeler for every occasion—daily commuting, weekend escapes, tourist exploration, or test-riding your dream bike. Simplify your mobility with us!

Related Posts

How to install WordPress on Windows using XAMPP? Part-1

How to install WordPress on localhost XAMPP? What is the WordPress? WordPress is a free and open-source (Content Management System) which is based on PHP and MySql….

Read More

Xampp Troubleshooting Guide

Log Levels of Apache, MySql, PHPMyAdmin, PHP, Composer Apache MySQL PHPMyAdmin PHPMyAdmin’s log level is primarily controlled by the PHP configuration, as it’s a PHP application. PHP…

Read More

How to Install & configure Xampp and WordPress in Linux?

How to setup WAMP server in Linux? Referece: https://www.apachefriends.org/index.html How to create mysql user, database and grant a permission to a database in mysql? Reference https://www.digitalocean.com/community/tutorials/how-to-create-a-new-user-and-grant-permissions-in-mysql How…

Read More

How to Install WordPress in Windows using XAMPP?

In this article, I’m going to describe how to Install WordPress on your Local PC.  Follow this some easy step, and learn how to install WordPress on…

Read More

How to fix an error of PhpMyAdmin access denied in xamp mySql.

Error resolving of PhpMyAdmin access denied. For most first time install, accessing http://localhost/PhpMyAdmin will directly take us to the PhpMyAdmin web interface without asking for password or…

Read More

What is WordPress and How to Install it?

What is WordPress? WordPress is one of the simplest, most popular way to create your own website or blog. It is a free and open-source content management…

Read More