wordpress is a use of the PHP language developed blog platform, users can support PHP and MySQL server content management system ( Cms open source project The GNU General Public License
Pre-Preparation:
WordPress installation Package: Official website address http://cn.wordpress.org/
1. Installing apache2.0
sudo apt-get install apache2
Open http://localhost/in the browser
or http://127.0.0.1.
If it appears
It works!
That proves OK.
To restart Apache:
sudo /etc/init.d/apache2 restart
2. Install PHP
In turn, turn on the terminal:
sudo apt-get install php5 //安装PHP5sudo apt-get install libapache2-mod-php5 //配置APACHE+PHPsudo /etc/init.d/apache2 restart //重启apache
Test:
Open it
gksudo gedit /var/www/testphp.php
Then you can enter something (Welcome to my personal website) and save it.
Then enter http://127.0.0.1/testphp.php in the browser
or http://localhost/testphp.php.
If it shows what you're typing, it's a success.
3. Install MySQL
sudo apt-get install mysql-server
Installation complete Follow the prompts to set the root password
4. Let Apache, PHP support MySQL
sudo apt-get install libapache2-mod-auth-mysqlsudo apt-get install php5-mysqlsudo /etc/init.d/apache2 restart
At this point apache2+php 5.2.4.2+mysql5.0.51 's environment is complete.
5. Install phpMyAdmin:
sudo apt-get install phpmyadmin
At this point the phpMyAdmin folder is installed under/usr/share/phpmyadmin, in order to be able to access the phpMyAdmin in the browser, you need to make a soft connection to the folder under/var/www:
Go to the/var/www folder and perform the following actions in this directory:
sudo ln -s /usr/share/phpmyadmin
At this point, type http://localhost/phpmyadmin in the browser and go to the admin interface
6. Create a new MySQL database for WordPress:
Here you can refer to the official documentation
Note: The following instructions refer to phpMyAdmin 2.6.0, and the phpMyAdmin user interface may be slightly different for different versions.
If you do not have a WordPress-related database in the left-side database drop-down menu, you need to create one:
Name the WordPress database (You can use ' wordpress ' or ' blog '), enter it into the Add new database (Create new) input box, and click Add Database (Create).
Click the home icon at the top left to go back to the main screen and click (privileges) (permissions). If there are no WordPress-related users in the user list, create one:
Click Add New User (add a new)
Choose a user name for WordPress (' root ' is recommended) and enter it into the username (user name) input box. (Make sure that the "Use text field:" In the drop-down menu is selected)
Choose a password with a higher level of secrecy (preferably a combination of uppercase and lowercase letters, numbers, and symbols) and enter it into the password (Password) input box. (Make sure the "Use text field:" In the drop-down menu is selected), enter the password again in the Re-type input box
Remember the user name and password you set.
Leave all options under all permissions (Global privileges) in the default state
Click Go.
Return to the permissions (privileges) interface, click the View permission (check privileges) icon on the WordPress user you just created. In the Detailed database permissions (database-specific privileges) interface, select the WordPress database that you created earlier in the Add permission to the following drop-down menu. The page then refreshes the permissions details for that WordPress database. Click Select All, select All permissions (check all), and then click Go.
On the results page, note the host name hostname (typically localhost) after the top server:.
7. Unzip the tar.gz compression pack of WordPress
sudo tar-zxvf wordpress-3.8-zh_cn.tar.gz
Get the WordPress folder and then edit the wp-config.php file as required, mainly to provide the name of the database (such as WordPress here), user name (such as root), password (such as the password you typed when installing MySQL). Note that there are no wp-config.php files in the WordPress folder, only wp-config-sample.php files can be modified directly in the above file, and then renamed directly.
8. Move WordPress to the/var/www directory
sudo cp -a ./wordpress /var/www
Access http://localhost/wordpress/wp-admin/install.php in the browser if successful access, the WordPress environment is built. If the wp-config.php configuration information has not been modified in the previous step, entering this page will provide a graphical interface for you to configure, with the content consistent with the above.
After the completion of the building, you can visit their personal site through http://localhost/wordpress, buy a space to buy a domain name, the site can be thrown up through the outside network access.
Build WordPress Environment under Ubuntu