Apache
$ Sudo apt-Get install apache2
Test http: // localhost in a browser
PHP
$ Sudo apt-Get install PhP5 libapache2-mod-php5
Restart the apache service
$ Sudo/etc/init. d/apache2 restart
Test installation
$ Sudo gedit/var/www/testphp. php
Add test statement
<? PHP phpinfo ();?>
Save and exit.
Test http: // localhost/testphp. php In the browser
$ Sudo RM/var/www/testphp. php
MySQL
$ Sudo apt-Get install mysql-Server
By default, MySQL only allows access from the local machine. If you want to access from another host, www.linuxidc.com can edit the configuration file/etc/MySQL/My. CNF.
$ Sudo gedit/etc/MySQL/My. CNF
Comment out the line bind-address = 127.0.0.1, save, and exit.
$ Sudo/etc/init. d/MySQL restart
MySQL Administrator
$ Sudo apt-Get install mysql-Admin
Applications-> System Tools-> MySQL Administrator
MySQL for Apache HTTP Server
$ Sudo apt-Get install libapache2-mod-auth-mysql php5-mysql phpMyAdmin
PHP and MySQL collaboration
$ Sudo gedit/etc/PhP5/apache2/PHP. ini
Remove the; number comment in the line "; Extension = mysql. So ".
Restart Apache
Sudo/etc/init. d/apache2 restart