日本综合一区二区|亚洲中文天堂综合|日韩欧美自拍一区|男女精品天堂一区|欧美自拍第6页亚洲成人精品一区|亚洲黄色天堂一区二区成人|超碰91偷拍第一页|日韩av夜夜嗨中文字幕|久久蜜综合视频官网|精美人妻一区二区三区

RELATEED CONSULTING
相關(guān)咨詢
選擇下列產(chǎn)品馬上在線溝通
服務(wù)時(shí)間:8:30-17:00
你可能遇到了下面的問題
關(guān)閉右側(cè)工具欄

新聞中心

這里有您想知道的互聯(lián)網(wǎng)營銷解決方案
winxpapache用php建本地虛擬主機(jī)的方法

1 在C:\WINDOWS\system32\drivers\etc\hosts
添加如下代碼:
127.0.0.1 localhost
127.0.0.1 x.test.com x.test1.com x.test2.com
注:x.test.com(假設(shè)的DNS)
2 在E:\WAMP\Apache2.2\conf\extra\httpd-vhosts.conf
修改內(nèi)容:
NameVirtualHost *

ServerAdmin web@xxx.com
DocumentRoot E:/WAMP/www
ServerName localhost
ErrorLog logs/localhost-error_log
CustomLog logs/localhost-access_log common


ServerAdmin web@xxx.com
DocumentRoot E:/WAMP/www/app (應(yīng)用目錄)
ServerName test.com
ServerAlias x.test.com admin.teeume.com
ErrorLog logs/x.test.com-error_log
CustomLog logs/x.test.com-access_log common


ServerAdmin web@xxx.com
DocumentRoot E:/WAMP/www/app/assets
ServerName x.test1.com
ErrorLog logs/img.test1.com-error_log
CustomLog logs/img.test1.com-access_log common

#自己建的目錄

ServerAdmin web@xxx.com
DocumentRoot E:/WAMP/www/test/assets
ServerName x.test2.com
ErrorLog logs/img.test2.com-error_log
CustomLog logs/img.test2.com-access_log common

============================
3 檢查是否關(guān)聯(lián)php
在E:\WAMP\Apache2.2\conf 找到httpd.conf
在末尾是否有如下在代碼:
############start for php5
LoadModule php5_module E:/WAMP/php5/php5apache2_2.dll
PHPIniDir E:/WAMP/php5
AddType application/x-httpd-php .php .phtml .php5
AddType application/x-httpd-php-source .phps
#####end for php5
若無則添加上以代碼。
4 查找
# Virtual hosts
#Include conf/extra/httpd-vhosts.conf
改為
# Virtual hosts
Include conf/extra/httpd-vhosts.conf
5 查找

DirectoryIndex index.html

改為

DirectoryIndex index.html index.html.var index.php

6 查找
改為 (www為apache應(yīng)用目錄)
7 查找 DocumentRoot "E:/WAMP/Apache2.2/htdocs"
改為 DocumentRoot "E:/WAMP/www"
8 查找 ServerRoot "E:/XXX/Apache2.2" (apache安裝目錄)
改為 ServerRoot "E:/WAMP/Apache2.2" (apache服務(wù)器目錄)
9 x.test.com x.test1.com x.test2.com
分別輸入以上三個(gè)進(jìn)行測試

集寧網(wǎng)站制作公司哪家好,找創(chuàng)新互聯(lián)公司!從網(wǎng)頁設(shè)計(jì)、網(wǎng)站建設(shè)、微信開發(fā)、APP開發(fā)、成都響應(yīng)式網(wǎng)站建設(shè)等網(wǎng)站項(xiàng)目制作,到程序開發(fā),運(yùn)營維護(hù)。創(chuàng)新互聯(lián)公司從2013年創(chuàng)立到現(xiàn)在10年的時(shí)間,我們擁有了豐富的建站經(jīng)驗(yàn)和運(yùn)維經(jīng)驗(yàn),來保證我們的工作的順利進(jìn)行。專注于網(wǎng)站建設(shè)就選創(chuàng)新互聯(lián)公司。

當(dāng)前標(biāo)題:winxpapache用php建本地虛擬主機(jī)的方法
轉(zhuǎn)載來于:http://www.dlmjj.cn/article/deeeg.html