wamp 修改www目录

来源:互联网 发布:淘宝卖正品鞋的店铺 编辑:程序博客网 时间:2024/05/05 21:27

我的情况

Wamp版本:2.2

WAMP2.2安装目录:C:/

www目录:D:/wamp/www/

变更目录:E:/HbuilderProjects/

 

一 主要过程:

1)修改 D:\wamp\bin\apache\Apache2.2.21\conf \httpd.conf(实现更改默认网站路径,即将Http://localhost定向到自己的默认目录:E:/HbuilderProjects/

2)拷贝并修改index.php(使新默认网站路径中的index.php可以正常显示,如果不需要Index.php可以略过此步)

3)修改D:\wamp\wampmanager.ini 和C:\wamp\wampmanager.tpl(改菜单中的www 目录指向)

 

二 具体修改方法全过程:

l  第一步:修改C:\wamp\bin\apache\Apache2.2.17\conf \httpd.conf

178查找: DocumentRoot "c:/wamp/www/"

修改: DocumentRoot "E:/HbuilderProjects/"

205查找: <Directory "c:/wamp/www/">

修改: <Directory "E:/HbuilderProjects/">

l  第二步:拷贝并修改index.php

1)拷贝:

将D:/wamp/www/拷贝至E:/HbuilderProjects/

2)查找:

//chemin jusqu'au fichier de conf de WampServer

$wampConfFile = '../wampmanager.conf';

//chemin jusqu'aux fichiers alias

$aliasDir = '../alias/';

3)修改:

//chemin jusqu'au fichier de conf de WampServer

$wampConfFile = 'D:/wamp/wampmanager.conf';

        //chemin jusqu'aux fichiers alias

$aliasDir = 'D:/wamp/alias/';

l  第三步:修改wampmanager.iniwampmanager.tpl

1 修改D:\wamp\wampmanager.ini:

(1)打开:D:\wamp\wampmanager.ini

290(2)查找:Type: item; Caption: "www 目录"; Action: shellexecute; FileName: "D:/wamp/www"; Glyph: 2

(3)修改:Type: item; Caption: "www 目录"; Action: shellexecute; FileName: "E:/HbuilderProjects"; Glyph: 2

2 修改D:\wamp\wampmanager.tpl

1)打开:C:\wamp\wampmanager.tpl

1232)查找:Type: item; Caption: "${w_wwwDirectory}"; Action: shellexecute; FileName: "${wwwdir}"; Glyph: 2

3)修改:Type: item; Caption: "${w_wwwDirectory}"; Action: shellexecute; FileName: "E:/HbuilderProjects"; Glyph: 2

完成所有步骤,保存文件,至此修改成功。

0 0