Skip to main content

WordPress On Windows – A Step By Step Install Guide

Following steps are based on my personal experience of installing WordPress and other required software on Windows Vista Enterprise. But based on the documentation I referred and reference in this post, these steps will work on Windows XP, Windows 2003 Server, Windows Vista and Windows 2008 server. 

These steps are so easy that anyone can follow whether regardless of any past experience with Apache, PHP, MySQL or WordPress. I am a .NET developer and never used Apache, PHP, MySQL before. So if I can do it then anyone can :).

I use XAMPP for my installation. XAMPP  provide an easy and one step installation of Apache, MySQL which are needed by WordPress.  There are two type of packages that you can download. XAMPP and XAMPP Lite. XAMPP comes with an installer while for XAMPP Lite you will have to run some batch files to install and run/stop services. I chose to install XAMPP (installer version).

imageimage

Step 1: Download XAMPP from http://www.apachefriends.org/en/xampp-windows.html#646. The current version of XAMPP 1.7.1 includes:

  • Apache HTTPD 2.2.11 + Openssl 0.9.8i
  • MySQL 5.1.33
  • PHP 5.2.9
  • phpMyAdmin 3.1.3.1
  • XAMPP CLI Bundle 1.3
  • FileZilla FTP Server 0.9.31
  • Mercury Mail Transport System 4.62

  Step 2: Install the XAMPP: Double click at xampp-win32-1.7.1-installer.exe to start the installation process.

image

image

image

image

image

Click on Install to install the XAMPP.

Step 3: stop IIS and all IIS services: Start command prompt and run following command to stop IIS and all IIS services. (further reading: more options to run apache & IIS side by side are listed in the further reading section below).

C:>net stop http /y

image

Step 4: Start Apache & MySql: Go to Start->All Programs->Apache Friends and click at XAMPP Control Panel.

image

image

Click on Start button to start Apache & MySql

image

To test open a new browser (like IE or Firefox) and type http://localhost.

image

Step 5: Create empty database and user account in MySql. To do this open http://localhost and click on phpMyAdmin (left side bar). This will show the admin screen to manage MySql database and other things. 

image

Click on Privilege option in top menu and then click at “Add New User” link.

image

Enter a new User name, Select host as Local and enter a password for the user. Then under Database for User select “Create database with same name and grant all privileges”.Click on Go button to create the user.

image

Click on Go button to create the user and a new database. On complete it will show following screen.

image

Scroll down and go to the section where it says “Change Login Information / Copy User”. Select Any Host in the Host dropdown and keep the default option “keep the old one” in the “Create a new user with the same privileges and”. Then click at Go button.

image

You can go to Databases option in top menu and verify the database created and privileges are correct.

image

image

Step 6: Add a host file entry: Open the host file in a text editor like notepad. The host file is located at C:\Windows\System32\drivers\etc\hosts. Add following line in the last.

127.0.0.1        php.lakshadev.net

Note: You can use something else in place of php.lakshadev.net. It could be anything like www.myphpdev.com or www.mylocalwp.com.

This is necessary step as you will get a warning message is you try to install WordPress MU using localhost. This also provide you a better looking URL for your local blogs.

image

Step 7: Download & Extract WordPress MU: Download WordPress MU from http://mu.wordpress.org/download/. (see more download options below).

Unzip the download file into a temporary folder. It'll create a wordpress-mu-xxx folder where xx is version-number. Change the folder name to blogs or something else that meaningful to you.

Copy this blogs folder in the web folder which is htdocs folder. If you have selected default option during XAMPP install then you will find it at C:\Program Files\xampp\htdocs.

Step 8: Install WordPress MU: Open a new browser (like IE or Firefox) and type http://php.lakshadev.net/blogs/. Remember php.lakshadev.net is the DNS we created in step 6 and blogs is a folder we copied in step 7.

image Page 1

image Page 2

 

image

Step 9: Installation is Done and you can click on Log In link to log in to your local WordPress site. You can also import your live blog to your local WordPress blog so you can browse them localy without internet connectivity and have a backup too.

Ability to browse locally was the primary reason I did this project so I can have a local copy of my blog on my machine.

I hope this will help everyone. Following are some reference links that may help you as well. Please let me know if these steps works for you or if you face any issue. I would try my best to help you with any issues.

References, Notes and Further Reading:

  • WordPress Download Options: There are two download available for WordPress. WordPress and WordPress MU. I chose to install WordPress MU in which MU stand for multi users. WordPress MU allow creating multiple blogs in one installation with one database. 

    You can learn more about WordPress MU at http://mu.wordpress.org/about/. You can also download single user (normal) WordPress from http://www.wordpress.org/download/.

  • In the instructions above I suggested to stop IIS & all IIS services. This will allow you to use IIS as well as Apache on same machine BUT not at the same time (side by side). 

    But if you want to run IIS and apache side by side then please follow the steps listed in following forum comment section.

    Can I run Apache and IIS on the same PC? - http://p2p.wrox.com/book-beginning-php-apache-mysql-web-development-isbn-978-0-7645-5744-6/12789-can-i-run-apache-iis-same-pc.html. Scroll down and look for Agrikk reply “A long overdue update to my own quetion”.

    1- Extract the httpcfg.exe utility from the support tools area on the Win2003 CD.
    2 - stop all IIS services: net stop http /y
    3 - have IIS listen only on the IP address I'd designated for IIS: httpcfg set iplisten -i 192.168.1.253
    4 - make sure: httpcfg query iplisten (the ip's listed are the only ip addresses that IIS will be listening on and no other)
    5- restart IIS Services: net start w3svc

    Voila! Apache is listening on its default ports on 192.168.1.254 and IIS is listening on its default ports on 192.168.1.253

Comments

  1. WordPress is the world's most popular blogging platform, and it is used by millions of people worldwide - some of them use it to promote their products and services, while others use it just to keep in touch with their loved ones. Either way, WordPress is easy to operate, feature-rich and it comes with a myriad of useful plugins that can enhance the user experience. See more wordpress two factor authentication

    ReplyDelete
  2. Your writing has impressed me. It’s simple, clear and precise. I will definitely recommend you to my friends and family. Regards and good luck

    freelance wordpress developer

    ReplyDelete
  3. I admire your unique way of writing especially the style of using the idioms and phrases which is mind-blowing.


    search engine optimization service india

    ReplyDelete
  4. The resource that you mentioned here is something that I have been looking from quite a time. And finally it ended with such a nice blog post.

    freelance wordpress developer

    ReplyDelete

Post a Comment

Popular posts from this blog

SharePoint WebPart Error - Unable to add selected web part (s) – MOSS 2007

ISSUE: Recently I faced this issue that when I try to deploy my WebPart.  Unable to add selected web part(s). WebPartName: Cannon unregister UpdatePanel with ID ‘ctl00RTMPanel’ since it was not registerd with the ScripManager. This might occure if the UpdatePanel was removed from the control tree and later added again, which is not supported. Parameter name: updatePanel.   I faced this issue twice and both the time the issue was not what display here. This could be sure to any error in the WebPart. Following are list resolution from multiple instances.   RESOLUTION: 1. Check the WebPartName.webpart file. Check whether you have a proper PublicKeyToken value. When I face the issue the value was PublicKeyToken=$PublicKeyToken$. If you have used WSP builder then in the Visual Studio you will find this file at \WebPartsProject\12\TEMPLATE\FEATURES\WebPartName\WebPartName.webpart. Sometime when you create a new WebPart using WSP builder then you do not get

TIME – 25 Best Blogs of 2009

Every year Time makes a list of best blogs in the world. They chose 25 blogs from millions of blogs in the world, spanning politics, housekeeping, astronomy and everything in between. Below if a direct link to the TIME website for the list. I also copied it to easy comparison of last year best with this year best blogs.   25 Best Blogs of 2009     25 Best Blogs 2008   25 Best Blogs of 2009 Talking Points Memo The Huffington Post Lifehacker Metafilter The Daily Dish by Andrew Sullivan Freakonomics BoingBoing Got2BeGreen Zen Habits The Conscience of a Liberal: Paul Krugman Crooks and Liars Generación Y Mashable Slashfood Official Google Blog synthesis bleat /Film Seth Godin's Blog Deadspin: Spor

Howto Run Your HTML Static Website Locally In IIS On Windows PC

WHAT & WHY: As a developer many time you may wish if you could run your static HTML website locally on your computer (Windows 7, Windows Vista, Windows XP, Windows 2008). Although with Static website, you could easily download and double click the index.html or home.html file to open and run other pages. But this will not give you the real world senario. For example you will not able to use a path like /images/home-page-banner.jpg. You will have to use a relative paths like ../images/home-page-banner.jpg. Following are very easy steps to do so. These steps are for Static HTML website. I will also post steps for more advance websites that uses ASP, ASP.NET, Dotnetnuke etc and uses database server.   WHAT YOU NEED: 1. IIS Server installed on your local machine 2. FTP username, password to download files form your FTP server 3. Administrative rights on local machine. Many task will display messages requesting Administrative privilege to run the task.    STEPS: 1.