XAMPP

closeThis post was published 3 years 5 months 29 days ago.
Therefore, it is likely to be outdated and may no longer be valid.

Developing web sites is fun (well, it can be). Setting up a development environment, however, is not always a fun thing to do. It’s not easy to install an Apache web server and it gets harder if you want to add MySQL, PHP and Perl and getting all this to work together is not for the faint hearted.

That is, unless you use XAMPP (cross-platform, Apache, MySQL, PHP and Perl) from apachefriends.org.

Why? It’s a breeze to install (and uninstall!); it’s open source, it’s cross-platform and, it’s free.

A brief overview of how to install on Windows:

  1. Download the Windows installer
  2. Run the Windows installer and follow the wizard
  3. Once the wizard has finished navigate to
    http://localhost/ or http://127.0.0.1 (they are synonymous)
  4. Select your language
  5. You’ll then be presented with the XAMPP welcome page (running locally on your machine on an Apache web server)

To get started with your own site, you need to locate the root directory of your newly-installed web server. It’s called htdocs and, if you followed the default installation, it’s found in
C:\Program Files\xampp\htdocs.

Create a new directory in htdocs called, for example, my-first-site (or anything you want).

Next, create a simple web page
(copy the following code into Notepad and save as "index.html").

<html>
  <head>
    <title>My first XAMPP page</title>
  </head>
  <body>
    <p>Hello world!</p>
  </body>
</html>

Finally, copy the index.html file into the my-first-site directory to
C:\Program Files\xampp\htdocs\my-first-site\.

To see if it works navigate to http://localhost/my-first-site/ in your favourite web browser (which of course, is Firefox!).

Tags: , , , ,

Please leave a comment or subscribe to the feed and get future articles delivered to your feed reader or inbox.

Comments

No comments yet.

Leave a comment

(required)

(required)