Lamp Build Environment
Created Tuesday 300 Months 2012
installation process
First Step installation Apache2
sudo apt-get install apache2 second Step installing PHP module
sudo apt-get install php5 third step installing MySQL
sudo apt-get install Mysql-server
sudo apt-get install mysql-client Fourth Step other module installation
sudo apt-get install LIBAPACHE2-MOD-PHP5
sudo apt-get install Libapache2-mod-auth-mysql
sudo apt-get install Php5-mysql
sudo apt-get install PHP5-GD Fifth Step test Apache is working properly
Open the browser and enter localhost to see if there is an IT works! page display. Directory is the sixth step of/var/www Modify permissions/var/www
sudo chomod 777/var/www Seventh Step installation phpMyAdmin
sudo apt-get install phpMyAdmin
Select Apache2 during the installation process and click OK. The next option is to configure the database and enter the password. Eighth Step Test phpMyAdmin
sudo ln-s/usr/share/phpmyadmin/var/www
Then run http://localhost/phpmyadmin directly to see if there is any database management software appearing. Configuration process
First step enabling the Mod_rewrite module
sudo a2enmod rewrite
Restart Apache server: sudo/etc/init.d/apache2 restart or sudo service apache2 Restart the second step of setting Apache support. htm. html. php
sudo gedit/etc/apache2/apache2.conf&
Add the following sentence: AddType application/x-httpd-php. php. htm. html third Step Test PHP Web page
Edit the mysql_test.php code as follows:
<?php$link = mysql_connect ("localhost", "root", "password");
if (! $link) die (' Could not connect: '. Mysql_error ()); Elseecho "MySQL configuration is correct!"; Mysql_close ($link);? >
Access http://localhost/mysql_test.php display ' MySQL is configured correctly ' on behalf of the correct configuration. Fourth step third step here appeared garbled after solution
Open config file sudo gedit/etc/apache2/apache2.conf&
Add the following code: Adddefaultcharset UTF-8. Configure OK.
-
Top
-
6
Ubuntu Build Lamp Environment