How To Install Wordpress 3.0
Installing WordPress Locally on Windows Running a Apache, MySQL, PHP (WAMP) Web Server.
In this how-to we will create a website (www.example.com), set up a database, and install wordpress into the /blog URL-space. This tutorial should take about 5 minutes to do.
We'll assume that you already have a PHP & MySQL web server such as Wamp-Developer installed and ready.
- Create a website container.
- Download the latest version of Wordpress.
- Place the Wordpress files into the website's folder.
- Create a database for Wordpress.
- Create and update the Wordpress configuration file (wp-config.php).
- Run the wp-admin/install.php file to finish the installation process.
1. Create A Website Container
First we'll need to create a website, composed of a DocumentRoot folder and a VirtualHost configuration. The DocumentRoot folder is a folder that contains the website files, and a VirtualHost configuration tells Apache about the existance of the website. If you already have a website ready, skip this step.
Using Wamp-Developer, go to the Websites Tab, Site Operations Section, and click Add. Enter the following information and click Continue.
Domain Name: www.example.com Domain Aliases: example.com
This will create and set up everything for you.
2. Download Wordpress
Go to wordpress.com and download the latest version of Wordpress: latest.zip. Once downloaded, open this zip file by double-clicking it, and you'll find a folder named "wordpress" inside. This folder contains all of the Wordpress files needed to set up a blog.
3. Unzip (Extract) & Place The Wordpress Files
Using Wamp-Developer, go to the Websites Tab, and select your website in the list by single-clicking it. Then click the DocumentRoot button. This will open the DocumentRoot folder into which we will extract and place the downloaded zip file's "wordpress" folder.
At this point, you can either extract the "wordpress" folder to the DocumentRoot folder directly, or simply copy-paste it in from the opened zip file into the opened DocumentRoot folder.
Rename the newly copied "wordpress" folder as "blog" by single-clicking on it's name. Changing the folder name will allow us to access Wordpress via URL http://www.example.com/blog
4. Create A Database
Wordpress uses a database to store all of its data (blog posts, pages, comments, some setting and information, etc). We'll create a new database for it, and also a database user that it will use to connect/login to MySQL (our database software). This can be done either via phpMyAdmin (a browser-based user interface to MySQL) or via MySQL's command shell (for advanced users). We'll use phpMyAdmin.
Make sure that the Apache2.2 & MySQL Services are running. Using Wamp-Developer, go to the System Tab, and click the phpMyAdmin button. This will open a new browser (IE, Firefox, Chrome, etc) tab or window and you'll see the login prompt for phpMyAdmin. Enter the following information (leave the password field blank, as it is (by default) not set for this user under Wamp-Developer):
User name: root Password:
Now that you are logged in, using phpMyAdmin, go to the Databases Tab, and create a new database named "wordpress".
Then click the Privileges Tab, and select "Add a new User". Create a user named 'wordpress' with password 'wp_pass' and host 'localhost' for that database. The option to "Grant all privileges on database 'wordpress'" should already be selected for you (if not, select it).
5. Create & Update The Wordpress Configuration File
Wordpress reads its core database setting from a configuration file named wp-config.php. We will first create a copy of this file from the included example file and then update it with the settings for our database and database user.
In the blog folder, find file wp-config-sample.php. Rename this file to wp-config.php (remove the '-sample' part) by single-clicking on its name. Next, open this file by right-click it, and selecting 'Open With --> Notepad'.
Locate the following lines:
/** The name of the database for WordPress */ define('DB_NAME', 'database_name_here'); /** MySQL database username */ define('DB_USER', 'username_here'); /** MySQL database password */ define('DB_PASSWORD', 'password_here');
Update the above lines to:
/** The name of the database for WordPress */ define('DB_NAME', 'wordpress'); /** MySQL database username */ define('DB_USER', 'wordpress'); /** MySQL database password */ define('DB_PASSWORD', 'wp_pass');
Save changes to this file by selecting menu 'File --> Save'. Close this file.
6. Finish The Installation Process
Now that we have everything set up, we can finish the installation process by running the wp-admin/install.php file which will read our wp-config.php settings and populate the database with the proper data.
Using your browser, go to URL http://www.example.com/blog and enter: the blog title, the user name and password to use for your account (don't confuse this with the database user information), and your email address. Then click "Install Wordpress".
Enjoy your new blog.