apache在windows虚拟目录配置帮助 [英] apache on windows virtual directory config help

查看:264
本文介绍了apache在windows虚拟目录配置帮助的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Windows XP上通过Xampplite运行Apache,并且可以使用帮助配置我的虚拟目录。这是我希望在我的开发盒上做的:

I'm running Apache on Windows XP via Xampplite, and could use help configuring my virtual directory. Here's what I'm hoping to do on my dev box:


  1. 我希望我的源文件在xampp htdocs dir之外。 li>
  2. 在我的本地计算机上,我可以访问 http:// myproject

  3. 我的本地网络上的其他人可以通过my.ip.address / myproject访问项目

  4. 保持本地主机指向xampp的htdocs文件夹, 。

我有1& 2工作通过编辑Windows主机文件,并在xampp的apache \conf\extra\httpd-vhosts.conf文件中添加一个虚拟目录。我不立即看到如何做3而不乱七八。

I've got 1 & 2 working by editing the windows hosts file, and adding a virtual directory in xampp's apache\conf\extra\httpd-vhosts.conf file. I don't immediately see how to do 3 without messing up 4.

推荐答案

想象:使用 / strong>为#3而不是VirtualHost,因此:

Figured it out: use Alias for #3, instead of VirtualHost, thus:

Alias /myproject "C:/path/to/my/project"
<Directory "C:/path/to/my/project">
  Options Indexes FollowSymLinks MultiViews ExecCGI
  AllowOverride All
  Order allow,deny
  Allow from all
</Directory>

这篇关于apache在windows虚拟目录配置帮助的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆