Full installation record of PHP + MySQL + Apache + WordPress

Source: Internet
Author: User
Tags install wordpress
Full installation record of PHP + MySQL + Apache + WordPress

I recently saw that other people's blogs on the Internet are WordPress, so I was eager to buy a PHP space as my blog space for years. This is simple, I will test the installation of the local machine. I studied Java in college, and now I am working on rails, which is really useless to PhP, xin Hao, I don't have any spam on PHP in my computer. I will talk about the installation process below.

Environment: Windows XP + PhP 5.2 + MySQL 5.0 + Apache 2.2 + WordPress 2.7

Install the PHP runtime environment:

1. Download php5.2 from the PHP official website. Zip is the best compressed version. Put it under D: \ Program Files.

2. Download the installation version of apache2.2 from the Apache website and install it on drive D. The directory after installation is D: \ Program Files \ Apache Software Foundation \ apache2.2.

3, (1) Copy all DLL files in the PHP folder to C:/Windows/system32/(including all DLL files in the ext folder in the PhP5 directory)

(2) Change the "php. ini-recommended" file to "php. ini" and copy it to "C:/Windows" and rename it "php. ini"

4. Modify PHP. ini. Note that both PHP. ini files need to be modified.

(1) Find the "extension_dir" field and assign it to the ext directory in the PHP decompression path, for example, "d: \ Program Files \ PHP 5.2 \ Ext"

(2) Search for the CGI. force_redirect string. The default value is 1. Change it to 0. and cancel the previous number.

(3) Search for the following four sentences and remove the previous ones.

Extension = php_mbstring.dll (wide character, used to support phpMyAdmin to avoid character display problems)
Extension = php_mcrypt.dll (used to support phpMyAdmin)
Extension = php_mysql.dll (MySQL module, which can be used to access the MySQL database)
Extension = php_mysqli.dll (MySQL module)

It is better to add the following expansion:

Extension = php_bz2.dll
Extension = php_curl.dll
Extension = php_gettext.dll
Extension = php_pdo_mysql.dll
Extension = php_zip.dll

5. Configure Apache to support PhP5

Open the "conf" folder under the Apache installation directory. Apache configuration mainly relies on httpd. conf to open the file with a compilation tool and modify some of the fields:

(1) The default value of the listen field is 80. You can modify the value of this port to change the port of the Apache service (if there is no conflict, do not modify it)

(2) DocumentRoot: This is the directory where your webpage files are stored. By default, it is the "htdocs" folder under the Apache installation directory. You can also change it to another directory on the local machine and use an absolute path.

For example: DocumentRoot "E:/phpwork/" (PhP working directory), but I did not modify it, copy the folder directly to

6. Set the start page:
In this place, you can copy my configuration or add the required start page file name. Note that file names are separated by spaces instead of commas.
<Ifmodule dir_module>
Directoryindex index. php index.html default. php default.html index.htm
</Ifmodule>

7. Configure the PHP Module

Loadmodule php5_module "D:/program files/php5.2/php5apache2_2.dll"
Addtype application/X-httpd-PHP. php
Phpinidir "D:/program files/php5.2"

8. Test PHP

Create helloworld. php In htdocs

<? PHP

Echo "helloworld! <Br> ";

Phpinfo ();

?>

 

Input: http: // localhost: 80/helloworld. php

Output result:

Install Wordpress:

1. Download WordPress 2.7 and copy it to the htdocs directory of Apache.

2. Follow the WordPress readme instructions.

(1) decompress the WordPress compressed package to an empty folder.
(2) Open the wp-config-sample.php with any text editor and fill in the information about the database. Note that the database here should be created in MySQL in advance, for example, the database is WordPress
(3), save and rename the wp-config-sample.php to the wp-config.php.
(4) Upload the entire WordPress folder to the server. Upload to the htdocs directory of Apache
(5) Access http: // localhost: 80/WordPress/WP-admin/install. php In the browser. WordPress automatically creates a database table. If an error occurs, carefully check the database information filled in by the wp-config.php. Yes, the error persists. Go to the support forum to find a solution.
(6) Remember the background logon password generated by the system.
(7) after entering the required information, the installation script will take you to the logon page. The logon username is admin. After logging on, click "user" to change the password.

3. Test success page:

Exceptions:

This exception occurs because the extension extension I configured for PHP. INI is not completely allowed!

Finally, let's take a look at the interface after my installation is successful. Although it is very uugly now, the next step will be to upload it to the Internet space and start my blog tour!

Ref:

Http://www.cnblogs.com/java-zhu/archive/2008/08/10/1264520.html

Related Article

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.