How To Set Up Local Web Server – Learn Web Development Without Subscribing To Web Hosting

By setting up local web server on your own desktop or laptop, you can start to learn web development without first buying a domain name and subscribing to a web hosting. Other than these cost savings, professional web developers also love to build websites on local web server as :

1)   You can develop websites offline; you do not necessary need to rely on internet speed which could be “excruciatingly” slow at times which bottleneck development time.

2)   The locally developed website can act as a backup; in case the client might just crash or mess up the site when he/she take over the site initially.

3)   Serve as a “copy” (aka template) if you happen to build similar sites.

4)   It is not exactly professional to build your site live as anyone who happen to know or stumble upon your domain name can see the development in progress; though you can add a Maintenance plugin if you’re on WordPress platform.

So, how do you actually convert your computer to be a local web server? There are, in fact, quite many ways to do that. If you’re only interest in learning WordPress (the best CMS or platform), a simple solution might be to use InstantWP.com. However, I’d strongly recommend to set up local web server with the famous and popular XAMPP from Apache Friends – just type “xampp” in Google or go directly to https://www.apachefriends.org.

XAMPP is a free open-source which literally convert your computer into a full-fledge local web server including Apache, MySQL (database server), PHP and Perl – giving you a complete PHP and web development environment.

XAMPP might not be the most light-weight or simplest open-source to create local web server – see https://alternativeto.net/software/xampp/, but its collaboration and partnership with Bitnami providing free all-in-one Add-ons including WordPress, Joomla!, Magento, MOODLE and many other popular open-source apps on top of XAMPP is a great plus! One need not install ie. WordPress manually which might be so-confusing and time consuming for newbies.

Best of all, XAMPP is available for the top 3 operating systems – Windows, Linux and (Mac) OS X. You’ll be looking at the same old so familiar interface irregardless of whichever OS you’re using.

Once you’ve downloaded, installed and started XAMPP, all you need to do is to fire up your browser and access the URL https://localhost/xampp/ and you’ll see :

xampp

To setup – for example – WordPress, just go to https://bitnami.com/stacks to download the latest version of WordPress app. Once you’ve downloaded and run the app, your WordPress will be up and running at https://localhost:8080/wordpress/ (note the :8080 after localhost).

Back to https://bitnami.com/, you can see that there are tons of one-click apps or web platforms which you can build ie. Joomla! (2nd best CMS), Drupal (another CMS), Moodle (#1 e-learning) , Magento (magnificent e-store), phpBB (forum; discussion board) … it’s a fantastic development playground!

The next question – Okay, now I have the site developed on my local searver and I’ve acquired my commercial web hosting, how do I deploy it live (to the production server)? Well, if it’s WordPress, my favourite is to use plugin – Backup Buddy and WP Duplicator are my top picks. The more generic way is :

  1. EXPORT the database of your site with phpMyAdmin (under Tools) in https://localhost/xampp/.
  2. Transfer/copy all the site files (with respective directory structure) to the production server via FTP client.
  3. Create a new database (with All Privileges granted to User) in production server cPanel’s phpMyAdmin.
  4. Edit the config file ie. wp-config.php (for WordPress) with the right path and database details (database name, username and password).
  5. Fixing broken links and updating path ie. /localhost/site to domainname.com.

 

Similar Posts