Configuration of Apache under Windows Server 2003

Source: Internet
Author: User
Tags web services

1. To avoid conflicts with IIS, be sure to stop the World Web Services service or simply uninstall IIS before installing Apache. This allows you to choose Apache as the Default Web Server, using port 80.

2, Apache operation after the permission set. This is a lot different from windows. Permissions are set in the configuration file. Open the configuration file httpd.conf and locate the following configuration section:

<directory/>
    Options followsymlinks
    allowoverride None order
    deny,allow
    deny
from all </Directory>

Changing the deny from "all" to allow from all solves the problem. Reference Links: http://www.piaoyi.org/php/apache-403-Forbidden.html

3, configure the virtual host. In order for the virtual host configuration to be stored in a separate configuration file, you need to include the configuration file in the main configuration file by using the Include method.

Include conf/extra/httpd-vhosts.conf

This statement is commented out by default, and the previous # number is deleted. Reference Links: http://blog.oolanguage.com/erpingwu/windows-%E4%B8%8B-apache-virtual-hosts-%E7%AE%80%E5%8D%95%E9%85%8D%E7%BD%AE/

4, configure PHP. In the configuration file, add the PHP module with the following code:

#加载php模块

LoadModule Php5_module D:/php5/php5apache2_2.dll

#指定php配置文件所在位置

Phpinidir "d:/php5/"

5, set the default document. Find the DirectoryIndex configuration section with the following code:

<ifmodule dir_module>
    directoryindex index.php index.html
<IfModule>
6, a virtual host corresponding to multiple domain names.
A, the domain name resolution to the corresponding server IP address.
b, set the Vhost configuration section of the Serveralias, the code is as follows:
Serveralias www.ljf.cn ljf.cn *.docs.ljf.cn
Multiple domain names are separated by spaces, and wildcard characters are called universal Domain name resolution. This feature is better than IIS,
can easily do an IP corresponding to multiple domain name resolution. To accept a generic domain name on IIS, it is necessary to use an IP corresponding to an empty host header.
Reference URL: HTTP://WWW.PHPUP.NET/POST/18

This article starts: 剑锋 blog respects the author, please keep the link.

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.