Lamp (Linux + Apache + MySQL + PERL/PHP/Python) is an open Resource Network Development Platform Based on Linux, Apache, MySQL, and PHP. It is hailed as a golden combination of php development.
1. Ubuntu
Install the lamp component in the environment
System-> System Management-> New Software Package Manager, open new software package, edit-> MARK software package by Task Group-> select lamp server.
(After you reinstall Ubuntu to the latest version of ubuntu10.10, you have not set up the Software Package Manager in the new software package manager.-edit-use the task tag group package --
Actually, only two commands are required.
Sudo apt-Get install tasksel
Task tag group
Sudo tasksel install lamp-Server
2. Install phpMyAdmin
System-> System Management-> New Software Package Manager, open the new software package search phpMyAdmin, and mark the installation.
Or sudo
Apt-Get install phpMyAdmin
Create a hard connection between phpMyAdmin and apache2. For example, run the command: sudo ln in the/home/dreamcatcher/WWW directory of my www.
-S/usr/share/phpMyAdmin
/Home/dreamcatcher/WWW can open http: // localhost/phpMyAdmin in the address bar of the browser.
3. Enable mod_rewrite module
Sudo a2enmod rewrite
4. apachesupports .htm. html. php
Sudo gedit/etc/apache2/apache2.conf
Add
Addtype application/X-httpd-PHP. php. htm. html
Solve the Problem of Garbled text in Firefox, or this file, and add
Adddefacharcharset UTF-8
Here the UTF-8 can also be replaced by gb2312 according to the actual situation.
5. Restart Apache
Sudo/etc/init. d/apache2 restart
6. Start MYSQL: mysql-u root-P. Enter the password as prompted.
If:
* Restarting Web Server apache2
Apache2: cocould not reliably determine the server's fully qualified domain name, using 127.0.1.1 for servername
Apache2: cocould not reliably determine the server's fully qualified domain name, using 127.0.1.1 for servername
Continue sudo gedit/etc/apache2/apache2.conf
Add servername 127.0.0.1 to the end of the file.
Note: Remember the following commands and locations:
Sudo/etc/init. d/apache2 restart (restart Apache)
Sudo gedit/etc/PhP5/apache2/PHP. ini (configure PHP. INI)
Sudo gedit/etc/apache2/apache2.conf (configure apache2.conf)
/Var/www/cgi-bin/(CGIProgram)