WordPress is well known as a open source blog-publishing platform. It is considered as the number one blogging tool in its category. With its latest releases, it has extended its potential well beyond blogging, moving toward an even more advanced, robust and very powerful content management solution, and so much more.

In this tutorial I am going to explain about how to install wordpress in your local computer having the operating system Ubuntu Linux 12.04 Precise Pangolin. To make local host of your PC we will install LAMP. It stands for Linux, Apache, MySQL, php (and/or Perl).

Open the terminal(Ctrl+Alt+t) of ubuntu and the following commands.

To install Apache:

$sudo apt-get install apache2

Now to confirm the installation of Apache2 open http://127.0.0.1 in your web browser, you will see It Works! default page of Apache.

To install Mysql:

$sudo apt-get install mysql-server

During the installation you will be asked to insert the mysql root password.

To install php:

$sudo apt-get install php5 libapache2-mod-php5

After this installation restart Apache .

sudo /etc /init.d/apache2 restart]

Now check if php is working :

$sudo vi /var/www/info.php

and add

<?php phpinfo(); ?>

save and exit. Now open browser and type : http://ip/info.php or http://localhost/info.php

To install phpmyadmin:

Let us also install phpmyadmin . phpmyadmin helps to take control over our database.

$sudo apt-get install phpmyadmin

You will be prompted to screen – press space to select apache2 server and enter.

To create database Type:

mysql -u root -p

Use above command to log in mysql server as root user, you will be asked to provide root user password.You will find yourself at Mysql > client prompt.

CREATE DATABASE wordpress;

Use above command to create database, database name should be WordPress.

CREATE USER wordpressuser;

Use above command to create a new user of username wordpressuser.

SET PASSWORD FOR wordpressuser = PASSWORD(“password”);

The above command use to create a password password to user wordpressuser;

GRANT ALL PRIVILEGES ON wordpress.* TO [email protected] IDENTIFIED BY ‘password’;

Above command use to grant the user all permissions on the database.

Exit

To quit mysql

Install WordPress

Download WordPress 3.4.1 file from their website and unzip the downloaded wordpress.zip in /var/www.

Open http://localhost/wordpress You should reach the default WordPress installation page. If you have not modified any of the files inside the folder you should see a screen stating that there is no WordPress config file.

Go ahead and click the “Create a Configuration File” button to continue.

Read the contents of the next page and click the “Lets Go” button. This page just explains that you will need to input some data and information over the next few step to set up the configuration file correctly.

Now we need start inputting some information for our setup. Go ahead and complete these details.

* Enter your database name that you gave the MySQL database when you created it earlier in PHPMyAdmin.

* Enter User Name and Password of the MySQL user to be able to read from the database.

* Database Host is as default “localhost“.

* Table Prefix – It is better if you change the name of table prefix.

If all go wells and the script was able to communicate with MySQL you should be moved onto the next step that states that you have made it through this part of the installation. You will also see the button: “Run the install”. Go ahead and click this button to continue.

Fill out your details and click the “Install WordPress” button.

At last you will get the login page. Click this “Log In” button to access you new WordPress dashboard. Use the username and password you entered earlier during installation.