I'm new to this. It took me about 20 hours to figure out this really simple procedure that now takes about ten minutes to do from scratch. I didn't see it in one place anywhere, so here it is now.

1. Download the latest copy of XAMPP and install it on your C:\ (or main) drive. I found it worked better locating it at C:\ directly and not in Program Files. It is really easy to install XAMPP. One important point is to make sure you have Skype turned off, or alternatively in Skype go to Tools > Options > Advanced > Connections > Uncheck "Use port 80 and 443 as alternatives for incoming connections", and click "save".

2. Open the c:\xampp\htdocs folder and create a subfolder call "drupal" (C:\xampp\htdocs\drupal). Download the latest copy of Drupal, and extract it into this folder. Make sure the unpacked drupal folders and files are in a directory called "drupal" as above and are not in something like C:\xampp\htdocs\drupal\drupal-6.4.

3. Decide on a password for your administrator (root) account. Let's say you choose "twinkle" (but pick something else!). Write it down somewhere where you won't lose it.

4. Open the file "c:\xampp\htdocs\drupal\sites\default\default.settings.php" in Wordpad (don't use Notepad!) and modify two lines as below (but use your own password and not "twinkle"). For the second line, you will have to delete the "#" (comment mark) at the beginning of the line.

....................
$db_url = 'mysql://root:twinkle@localhost/drupal';
....................
$base_url = 'http://localhost/drupal';
....................

5. Save the modified file. Now copy this "default.settings.php" file to the same directory, and name it "settings.php". You should now have two identical files in your "c:\xampp\htdocs\drupal\sites\default" folder, with one called "settings.php" and one called "default.settings.php".

6. Browse to http://localhost/phpmyadmin. Log in with user name "root" and password "twinkle" (except use the password you set, don't use "twinkle"!). Don't do anything except create a new database called "drupal". Type "drupal" (without the " marks!) in the box marked "Create new database" and click on the button "Create" just to the right of it. You should get a screen confirming the database has been created.

7. Browse to http://localhost/drupal/install.php and follow the simple instructions and you will have installed Drupal.

8. Note that if you browse to http://localhost/drupal before doing step 7, you will get an error message saying the object doesn't exist. If you browse to http://localhost/drupal after doing step 7, it will be fine.

And that is all.

Comments

dnewkerk’s picture

Hi Paul -

I'm David, and I'm one of the many volunteers on the Drupal documentation team :) I wanted to thank you for writing this up. If you'd like, you can post this info as a page in the handbook. Here's some info on how you can get involved in contributing documentation... it's really simple (in my case I can't code much, but I can write Drupal lessons haha).

If you'd like to add the page, I'd suggest maybe here: http://drupal.org/node/add/book/parent/161975
This would add it as a sub-page of the XAMPP guide... you could call it something like "Installing Drupal on XAMPP - simplified!" :) Or anything you'd like that describes your page.
You can add a "child page" under any other documentation page using the "Add child page" link at the bottom of every page in the handbook.

Again, thanks and welcome to Drupal!

-- David
absolutecross.com
[new guide/lesson in progress: Creating a CCK and Views powered Drupal site - feedback welcome]

dulloldfart’s picture

Thanks, David.

I've added the page where you suggested, with the addition of the paragraph below, which I forgot.

5a. Browse to http://localhost/security and enter the MySQL user and passsword "root" and "twinkle" (but your password, of course). Stop and restart MySQL in the XAMPP control panel (takes ten seconds).

-- Paul

swankoid’s picture

I made a really stupid mistake when doing this, i seemed to be following all the instructions perfectly but couldn't connect to localhost/drupal. Then I realized it was because I hadn't extracted the drupal files in the proper way (I had just dragged them into my drupal folder from the zip folder) the file folders where missing making the filepaths used later useless! Just thought I'd mention this in case anyone else out there is making the same mistake :0)

rom12’s picture

nice write up !
just wanted to add that some folks might extract drupal to their download folder and then copy it over to C:\xampp\htdocs\drupal

So to add to step 2.)
Before copying make sure that you have selected the Folders Option to 'View Hidden Folders'. If this doesnt happen then the .htacess file isnt copied and the installation will be unsucessful.
So make sure you copy all files and folders (hidden ones included) to C:\xampp\htdocs\drupal in order to ensure a proper installation.