Migrate WordPress From Localhost To Live Server


You have a working wordpress website on your localhost server and when you need to migrate or copy the same wordpress website to your live server, what should you do ?

To install a fresh copy of wordpress and put all the data again and again is very frustrating.

I think almost all the wordpress developers face this problem. I have a solution to this problem.

There is a very simple way to get rid of this problem.

You just need to download the SQL file from your database and make a copy of your wordpress website folder.

Now open the wp-config.php which is present at the root directory and write the database details you have for your live server.

Now open the SQL file in the editor (I prefer Adobe Dreamweaver), and find http://localhost/yourfoldername/ and replace this with http://www.mywebsite.com/.

You are all done. Just upload the folder through any FTP client and upload the database and enjoy your website fully functional like your local version.

Install WordPress with Multiple Domains or Subdomains


To change WordPress from the standard single site install to a WordPress Multisite which allows you to create a network of sites you need to:

  1. Update your wp-config.php file.
  2. Choose the structure of your Multisite in terms of whether you want to use sub-domains or sub-directories.
  3. Add the extra lines your WordPress installation generates into your wp-config.php.
  4. Add the generated mod_rewrite rules to your .htaccess file, replacing other WordPress rules.

You do this as follows:

Updating your wp-config.php file

  1. Locate your wp-config.php file on your hard drive.
  2. Open your wp-config.php file for editing.
  3. Add the following line to your wp-config.php file:
define('WP_ALLOW_MULTISITE', true);

above where it says /* That’s all, stop editing! Happy blogging. */: Continue reading