windows下面虚拟主机
1. wondows xp + apmserv 5.2.6 端口8088
2.httpd.config文件
1. ServerRoot "D:/APMServ/APMServ5.2.6/Apache"
Listen 8088
ServerName 127.0.0.1:8088
DocumentRoot "D:/APMServ/APMServ5.2.6/www/"
(原文未变)
2.要么将几台<virtualhost>标签全放在 D:\APMServ\APMServ5.2.6\Apache\conf\apmserv\vhost.conf 文件中(谁在前谁是默认的虚拟主机)
被httpd.config包含 ,要么将他们全部写在httpd.config中 (若有更多台虚拟主机可按原样改动后添加)
NameVirtualHost *:8088
<VirtualHost *:8088>
ServerName www.test.com
ServerAlias *.test.com
DocumentRoot "D:/APMServ/APMServ5.2.6/www/test"
<Directory "D:/APMServ/APMServ5.2.6/www/test">
Options FollowSymLinks IncludesNOEXEC Indexes
DirectoryIndex index.html index.htm default.htm index.php default.php index.cgi default.cgi index.pl default.pl index.shtml
AllowOverride None
Order Deny,Allow
Allow from all
</Directory>
</VirtualHost> NameVirtualHost *:8088
<VirtualHost *:8088>
ServerName www.testone.com
ServerAlias *.testone.com
DocumentRoot "D:/APMServ/APMServ5.2.6/www/testone"
<Directory "D:/APMServ/APMServ5.2.6/www/testone">
Options FollowSymLinks IncludesNOEXEC Indexes
DirectoryIndex index.html index.htm default.htm index.php default.php index.cgi default.cgi index.pl default.pl index.shtml
AllowOverride None
Order Deny,Allow
Allow from all
</Directory>
</VirtualHost>
3.C:\WINDOWS\system32\drivers\etc\hosts 文件用文本编辑器打开添加下边内容(若有更多台虚拟主机可按原样改动后添加)
127.0.0.1 localhost
127.0.0.1 testone.com
127.0.0.1 www.testone.com
127.0.0.1 testtwo.com
127.0.0.1 www.testtwo.com
4.本机打开任意浏览器 输入URL www.test.com 或者 www.testone.com 会显示出 D:/APMServ/APMServ5.2.6/www/test 或者 "D:/APMServ/APMServ5.2.6/www/testone 中的 默认页(index.php 或index.html……)
windows下面虚拟主机的更多相关文章
- windows安装虚拟主机virtualbox遇到的困难
本来想到可以在windows安装虚拟主机virtualbox,但是怎么自己的windows是盗版的,由于主题已经被破解了,所以不能安装结果强制性的进入pe然后从网上下载的dll文件复制到 c/wind ...
- nginx for windows 中虚拟主机路径设置问题
由于Windows版本的Nginx其实是在Cygwin环境下编译的,所以Nginx使用的是Cygwin的路径格式,所以在Nginx的配置文件nginx.conf中,路径既不能使用*nix的格式,也不能 ...
- 在基于Windows系统的PHP虚拟主机上实现域名的301永久重定向
作者:荒原之梦 原文链接:http://zhaokaifeng.com/?p=581 操作背景: 当网站在更换或添加域名.进行网址规范化或删除旧页面时,出于对用户使用体验和搜索引擎优化方面的考虑就需要 ...
- Linux服务器配置多台虚拟主机
2016年11月4日15:59:12 LAMP环境 参考:http://blog.itblood.com/nginx-same-ip-multi-domain-configuration.html 在 ...
- 在Windows Azure虚拟机上开发Windows 8 应用
前提条件 Windows Azure开发者账号:如果您拥有微软MSDN Subscription账户,那么意味着您可免费申请Windows Azure开发者账号. 创建虚拟机 点击Windows Az ...
- Windows 2008 R2 X64 安装WebsitePanel(WSP虚拟主机管理面板)
Windows 2008 R2 X64 安装WebsitePanel(WSP2.0虚拟主机管理面板) 估计很多同学都还不知道WebsitePanel是什么东东吧,Web ...
- windows和mac下分别配置虚拟主机
windows下配置 1.找到apache的配置文件,httpd.conf 2.找到 LoadModule rewrite_module modules/mod_rewrite.so 去掉前边的# 3 ...
- Vagrant安装完lnmp后,配置linux和windows共享文件并配置虚拟主机访问项目
虚拟机目录下的Vagrantfile文件是vagrant的配置文件,如果想把虚拟机当作一台服务器,可以通过ip访问,需要修改配置文件进行配置. (1)第一步:打开虚拟机目录下的Vagrantfile文 ...
- windows下apache配置虚拟主机
因为有多个laravel项目需要配置根目录到public下面,所以要配置多个虚拟主机 方法一:添加端口号 第一步:进入apache的目录 Apache24\conf 找到 httpd.conf 文件, ...
随机推荐
- mysql学习笔记4
用phpmyadmin创建数据库时出现 #1064 - You have an error in your SQL syntax; check the manual that corresponds ...
- Curl的编译
下载 curl的官网:https://curl.haxx.se/ libcurl就是一个库,curl就是使用libcurl实现的. curl是一个exe,也可以说是整个项目的名字,而libcurl就是 ...
- How to: Declare encoding UTF-8 in python
References: http://stackoverflow.com/questions/12238307/declaring-encoding-in-python http://stackove ...
- Generate GUID using vbscript
在 .msi 中 的 Component table,查看 ComponentId 列,是一个16进制数的字符串, 用 InstallShield IDE 添加一个 component ,Compon ...
- php结合jquery异步上传图片(ajaxSubmit)
php结合jquery异步上传图片(ajaxSubmit),以下为提交页面代码: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transi ...
- python27读书笔记0.3
#-*- coding:utf-8 -*- ##D.has_key(k): A predicate that returns True if D has a key k.##D.items(): Re ...
- 使用pdb调试python
python pdb调试 python -m pdb myscript.py #注意这会重启myscript.py,这样启动的话,代码每一行都是一个节点 也可以在程序中这么设置断点: import p ...
- 2016041601 - linux上安装maven
在linux系统中安装maven,个人目前使用ubuntu15.1系统. 要想使用maven,前提条件必须配置好java. 1.检查java信息. 命令:echo $JAVA_HOME 和java - ...
- 在类库中无法使用ConfigurationManager
需要先引用DLL文件: C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.configuration.dll 然后才可以使用 System.Co ...
- 使用ssh公钥实现免密码登录
使用ssh公钥实现免密码登录 ssh 无密码登录要使用公钥与私钥.linux下可以用用ssh-keygen生成公钥/私钥对,下面我以CentOS为例. 有机器A(10.207.160.34),B(10 ...