sudo apt-get update && sudo apt-get upgrade && sudo apt-get dist-upgrade
Apache
sudo apt-get install apache2 apache2-utils libapache2-mod-php5 which apache2 apache2 -v *Uninstall: sudo apt-get remove --purge apache2 apache2-utils sudo apt-get remove apache2* sudo apt-get autoremove
MySql
sudo apt-get install mysql-server-5.6 mysql-client-5.6 which mysql mysql -V *Uninstall: sudo apt-get autoremove --purge mysql-server-5.6 sudo apt-get autoremove --purge mysql-client-5.6
PHP
sudo apt-get install php5 php5-gd php5-mysql php5-curl php5-cli php5-cgi php5-dev php5-mcrypt which php php -v
PhpMyAdmin
sudo add-apt-repository -y ppa:ondrej/php sudo apt-get update sudo apt-get install phpmyadmin
reference 1
Make first look for a file called index.php.
sudo nano /etc/apache2/mods-enabled/dir.conf
Modify like below:
<IfModule mod_dir.c>
DirectoryIndex **index.php** index.html index.cgi index.pl index.xhtml index.htm
</IfModule>
Then restart
sudo service apache2 restart
sudo nano /etc/apache2/apache2.conf
Add line below:
Include /etc/phpmyadmin/apache.conf
Then restart
sudo service apache2 restart
Notice: If show Error below:
[alias:warn] [pid 22355] AH00671: The Alias directive in /etc/phpmyadmin/apache.conf at line 3 will probably never match because it overlaps an earlier Alias.
Then remove above line below:
Include /etc/phpmyadmin/apache.conf
And restart:
sudo service apache2 restart
If phpmyadmin show error on UI Panel like below:
The mcrypt extension is missing. Please check your PHP configuration.
So,do below:
sudo updatedb locate mcrypt.ini
Should show it located at /etc/php5/mods-available
locate mcrypt.so
Edit mcrypt.ini and change extension to match the path to mcrypt.so, example:
extension=/usr/lib/php5/20121212/mcrypt.so
Then exec and restart:
sudo php5enmod mcrypt sudo service apache2 restart