在windows2000_pro下安装apache和php以及配置问题
我是一个初学者,我安装了apache后,按照
这里要做的是对C:Apache2confhttpd.conf这个文件进行修改,用记事本打开:
找到:
#NameVirtualHost *
修改为:
NameVirtualHost 127.0.0.1
找到:
<VirtualHost 127.0.0.1>
修改下面几行:
ServerAdmin (你刚才安装时候输入的管理员信箱)
DocumentRoot c:Apache2htdocs
ServerName Apache2
ErrorLog c:Apache2logserror_log
CustomLog c:Apache2logsaccess_log common
</VirtualHost>
找到:
AddType application/x-tar .tgz
在下面添加以下两行:
AddType application/x-httpd-php .php
AddType image/x-icon .ico
找到:
#LoadModule ssl_module modules/mod_ssl.so
在下面添加一行:
LoadModule php4_module C:phpsapiphp4apache2.dll
增加默认文件:
找到DirectoryIndex * 这行,可以这样修改,添加默认的文件名:
DirectoryIndex index.php default.php index.htm index.html default.htm default.html
保存文件,重起apache服务器。</P< p>
进行了设置以后其中我是把apache安装在C:\Program Files\Apache Group\Apache2这个目录下的我设置的ServerName 是我在公司的域名
但是启动以后报:Syntax error on line 953 of C:\Program Files\Apache Group\Apache2\conf\httpd.conf:
DocumentRoot takes one argument,Root directory of the document tree
NOt the errors or message above, and press the <Esc> exit
我把NameVirtualHost 127.0.0.1:8080
<VirtualHost 127.0.0.1:8080>
ServerAdmin hyw@softwise.com.cn
DocumentRoot C:\Program Files\Apache Group\Apache2\htdocs
ServerName cactus.softwise.com.cn
ErrorLog C:\Program Files\Apache Group\Apache2\logs\error.log
CustomLog C:\Program Files\Apache Group\Apache2\logs\access.log common
</VirtualHost>
请高手指教一下,谢谢,最后能有详细的步骤,还有关于php的配置
我安装的是apache_2.0.53-win32-x86-no_ssl.msi和php-4.3.11-Win32.zip
但是现在有php-5.0.4-Win32.zip