Build a wordpress blog based on Apache-Php-MySQL in Debian

Source: Internet
Author: User
Tags apache php wordpress database wordpress blog
Building wordpress blog wordpress based on Apache-Php-MySQL in Debian is a popular blog building framework, providing a convenient way for people who do not know html, css, and js to build a blog. I have built a wordpress blog on my laptop. here I will write down the detailed building process.

My system information is as follows:

The procedure is as follows.

1. install the apache2 server

The apache2-doc is the description and configuration file of the apache server, and the libapache2-mod-php5 is the apache php module library file.


After successful installation, restart the apache2 server,

Enter http: // localhost in the address bar of the browser. the following page is displayed, indicating that the apache2 server has been installed successfully.

2. apache2 configuration information:

A. the configuration file directory of apache2 is/etc/apache2. in debian, the configuration file is split into several subfolders in the directory. you can view the files in the directory:

Apache2.conf is the main configuration file, which contains ports. the conf file is used to configure the listening port of the server. in addition, the mod-enabled and sites-enabled and conf-enabled sub-directories have one. conf file. for detailed configuration instructions, see the corresponding instructions.

B. when apache2 is installed, a user named www-data will be created, and all apache-related processes will be started and executed by this user. when accessing localhost in a browser, run the top command:

The first record is the process overhead of the apache2 server.

C. the default webpage and script directory of apache2 are/var/www/html. all webpages stored in this directory (except the index page) can be accessed through http: // localhost/filename. if the directory contains aboutme.html, you can enter http: // localhost/aboutme.html in the browser to access the service.

3. install php:

The php5-mysql is php and mysql database interface, in order to use mysql database must install this package.

After the installation is complete, you can use the following method to check whether php installation is successful:

A. in the/var/www/html Directory, write the following phpinfo. php file:

 

Visit the page http: // localhost/phpinfo. php in the browser. if the following page appears, the php installation is successful.

Click the scroll bar on the right of the page to see the various modules and components supported by php below. it looks quite a lot.

4. install mysql:

After the installation is complete, refresh the phpinfo page and go down to the center. mysql and mysqli are displayed, indicating that msyql has been installed successfully.

5. download the wordpress compressed file:

Access the http://cn.wordpress.org, as shown in. there is a compressed package in the middle of the right for download, click to download.

You can also copy the link and download it with wget (it seems that wget is faster ):


Decompress the downloaded file:

Put the decompressed file in the wordpress folder and check the content:

Most files or folders starting with wp are saved in these folders. the scripts for configuring the blog and the page framework displayed to visitors are saved in the database.

Because the default webpage storage directory is/var/www/html, it takes effect only when the files in the folder are moved to the directory. Therefore, perform the following operations:

Mv-R wordpress/var/www/html

This operation replaces the original html directory with the wordpress directory.

Now open http: // localhost in the browser and you will see the page for starting wordpress configuration:


Then, follow the steps to create the corresponding wordpress database in mysql. The entire blog is complete!

Below is my blog (I copied some content from the internet ...) :

(-End -)

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.