Php environment configuration (windows environment)

Source: Internet
Author: User
1. download apache_228-win32-x86-no_ssl (1) msi, php-525-Win32zip. Link: 2. create the following Directory: do not empty & amp; 26684; F: apache 3. install apache. After the installation is complete, enter 127001 in the browser and prompt itworks instructions for installation

1. download the apache_2.2.8-win32-x86-no_ssl (1).msiw.php-5.2.5-win32.zip. Link:

2. create the following Directory: Do not use spaces

F: \ apache

3. install apache. After the installation is complete, enter 127.0.01 in the browser and prompt it works to indicate that the installation is successful. Note that iis must be uninstalled before installation.

F: \ apache \ Apache2.2

4. decompress php

F: \ apache \ php

5. rename F: \ apache \ php. ini-dist to F: \ apache \ php. ini.

6. open F: \ apache \ php. ini. Find the row where the string extension = php_gd2.dll is located (row 611), remove the semicolon at the beginning of the row, locate the row where the module listed in the following table in the following rows, and remove the semicolon at the same time.

Extension = php_gd2.dll
Extension = php_mbstring.dll
Extension = php_mhash.dll
Extension = php_mime_magic.dll
Extension = php_ming.dll
Extension = php_mysql.dll

7. Add F: \ apache \ php and F: \ apache \ php \ ext to the system environment variable.

8. create a first. php file under F: \ apache \ Apache2.2 \ htdocs. The file content is as follows:



PHP testing


Hello World

';?>


9. enter http: // 127.0.0.1/first. php in the browser. The html source code is displayed. Open F: \ apache \ Apache2.2 \ conf \ httpd. conf.

In row 125 (find the two sentences # LoadModule version_module modules/mod_version.so
# LoadModule vhost_alias_module modules/mod_vhost_alias.so add the following two sentences in these two sentences)

1.
LoadModule php5_module "F:/apache/php/php5apache2_2.dll"
PHPIniDir "F:/apache/php /"

2. add a row in row 383

AddType application/x-httpd-php. php

10. restart the php server. Enter http: // 127.0.0.1/first. php in the browser. HelloWorld appears. Success

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.