Install configuration Apache2.2.3 on Windows and implement multiple sites

Source: Internet
Author: User

Apache for Windows

1. Download Apache for Windows

Information about the latest version of Apache can be found on the http://httpd.apache.org/download.cgi. You should download the Apache for Windows version with the. msi extension. This is a single Microsoft Installer file that contains Apache that can be installed and run immediately.

2. Install Apache for Windows

Run the previously downloaded Apache. msi file. The installer asks for the following information:

Network domain Your server has or is about to register DNS domains. For example, your server's full name DNS domain name is server.mydomain.net, you should enter here: mydomain.net, local words set to localhost

Server name your server's full name DNS domain name, as in the case you should enter here: server.mydomain.net, local words set to localhost

Administrator ' s email address to the server admin. This address will be displayed to the client on the default error page.

For whom to install Apache if you want Apache to listen on port 80 and be installed as a service (even if no one is logged in, Apache will still be running), select "For all Users, on Port, as a Service-rec Ommended "If you want to install Apache as a personal trial, or if you already have a WWW server running on port 80, select" Only for the "," port 8080, when started manually "。

The installation type selection typical installs everything except the source code and libraries that the development module needs to use. Choose Custom to customize which items to install. The full installation requires approximately 13MB of disk space, which does not contain the space used for your Web site files.

Where to install installs the Apache folder, which defaults to the Apache2 subfolder under the C:\Program Files\apache Group folder. You can also select a different folder, such as: D:\Apache2.2

Note: Before installing, completely uninstall the previous version of Apache and delete all directories and files because the newly installed profile does not overwrite the old pre-existing configuration file, and the old file may cause the Apache service to fail to start.

3, configure Apache support PHP

Find DirectoryIndex index.html Index.html.var after adding index.htm index.php (default index.php homepage file)

Modular Installation of PHP

Find #LoadModule Ssl_module modules/mod_ssl.so This line, add a line after this row

LoadModule Php5_module D:/php/php/php5apache2.dll

Where D:/php/php/php5apache2.dll is the location of the Php5apache2.dll in your PHP directory

And then find AddType application/x-gzip gz. tgz, join a line after this row

AddType application/x-httpd-php. php

(In fact: the above two lines of red, you can directly add to the end of the httpd.conf file can also be)

Note: The Php5Apache2.dll provided by PHP do not actually apply in apache2.2.x

Workaround:

Download the file and unzip it. A total of three files.

Vcredist_x86.exe

Php5apache2.dll

Httpd.exe.manifest

Okay, here we go.

1. Overwrite the Php5apache2.dll file in your original PHP directory with the Php5apache2.dll.

2. Copy the Httpd.exe.manifest file to your Apache installation directory under the Bin folder.

3. Double-click to run Vcredist_x86.exe installation. (If the. NET Framework 2 is already installed in your system, you can skip this step)

Finish it! Go and reboot your apache2.2 try it.

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.