Install Apache
Open Terminal and type:
sudo apt-get install apache2 |
At the end of installation you will see a message saying:
* Starting web server apache2
apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
It’s nothing to worry about because most personal computers don’t have one.
Test Apache
Open a web browser and point it to URL:
You should see a message saying:
It works! |
This is the default web page for this server. |
The web server software is running but no content has been added, yet. |
Install PHP
Open up Terminal again and type in the following command:
sudo apt-get install php5 libapache2-mod-php5 |
Test PHP
In the terminal, type this command:
sudo pluma /var/www/ test .php |
This will create a new php file in Pluma text editor. Copy/Paste this line into the .php file.
<?php phpinfo(); ?> |
Save and close the file.
From a web browser, try to load the file:
It should render a page with all information on the PHP installation.
Install MySQL
Still in the Terminal, type this command:
sudo apt-get install mysql-server |
You will be prompted with Configuring mysql-server dialog to setup a root password. It’s recommended that you set a password.
Install phpMyAdmin
sudo apt-get install libapache2-mod-auth-mysql php5-mysql phpmyadmin |
In Configuring phpmyadmin window, press spacebar to check apache2 and press TAB key to move to and press Enter.
Choose when asked to configure database for phpmyadmin with dbconfig-common.
Test phpMyAdmin
From the browser, open this address:
You should see phpMyAdmin’s login page and be able to login using ‘root’ as Username and the password you setup earlier when you installed MySQL.
1 Comment
chandan
Hmmm! What you call yourself???