Quick configuration of ubuntu PHP Environment

Source: Internet
Author: User

Quick configuration of ubuntu PHP Environment From URL: http://www.5x54.com Author: 5x54 install apache2: copy content to clipboard

Code:

sudo apt-get install apache2

Install the PHP module:

Copy content to clipboard

Code:

sudo apt-get install php5
sudo apt-get install php5-gd

Edit test page:

Copy content to clipboard

Code:

sudo gedit /var/www/testphp.php

Install MySQL

Copy content to clipboard

Code:

Sudo apt-Get install mysql-Server
Mysqladmin-u Root Password db_user_password
# Replace db_user_password with the password

Install the MySQL Module

Copy content to clipboard

Code:

sudo apt-get install libapache2-mod-auth-mysql
sudo apt-get install php5-mysql

Configure PHP. ini:

Copy content to clipboard

Code:

sudo gedit /etc/php5/apache2/php.ini

Remove the file after the file:

Copy content to clipboard

Code:

extension=mysql.so
extension=gd.so

Install phpMyAdmin site URL: http://www.5x54.com Author: 5x54

Copy content to clipboard

Code:

sudo apt-get install phpmyadmin

Test: http: // localhost/PHPmyAdmin/
Restart Apache

Copy content to clipboard

Code: sudo /etc/init.d/apache2 restart

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.