安装 Apache2:
sudo apt-get install apache2
安装PHP模块:
sudo apt-get install php5
编辑测试页:()
sudo gedit /var/www/testphp.php
安装Mysql
sudo apt-get install mysql-server
mysqladmin -u root password db_user_password
#db_user_password替换为密码
安装Mysql模块
sudo apt-get install libapache2-mod-auth-mysql
sudo apt-get install php5-mysql
sudo apt-get install php5-gd
sudo /etc/init.d/apache2 restart
安装phpmyadmin
sudo apt-get install phpmyadmin
sudo ln -s /usr/share/phpmyadmin/ /var/www/
测试:http://localhost/phpmyadmin/