参考 http://www.120xcjl.com  Apache为mysql以及自己的项目设置虚拟路径 1.Apache2.2\conf\httpd.conf中释放:

  Include conf/extra/httpd-vhosts.conf(去掉前面的#)

  2.httpd.conf中增加

  #项目文件夹DWM目录,注意不要使用中文定义目录与文件夹

  #

  # Possible values for the Options directive are "None", "All",

  # or any combination of:

  # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews

  #

  # Note that "MultiViews" must be named *explicitly* --- "Options All"

  # doesn't give it to you.

  #

  # The Options directive is both complicated and important. Please see

  # http://httpd.apache.org/docs/2.2/mod/core.html#options

  # for more information.

  #

  Options FollowSymLinks

  #

  # AllowOverride controls what directives may be placed in .htaccess files.

  # It can be "All", "None", or any combination of the keywords:

  # Options FileInfo AuthConfig Limit

  #

  AllowOverride None

  #

  # Controls who can get stuff from this server.

  #

  Order allow,deny

  Allow from all

  #phpMyAdmin的安装路径

  #

  #

  # Possible values for the Options directive are "None", "All",

  # or any combination of:

  # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews

  #

  # Note that "MultiViews" must be named *explicitly* --- "Options All"

  # doesn't give it to you.

  #

  # The Options directive is both complicated and important. Please see

  # http://httpd.apache.org/docs/2.2/mod/core.html#options

  # for more information.

  #

  Options Indexes FollowSymLinks

  #

  # AllowOverride controls what directives may be placed in .htaccess files.

  # It can be "All", "None", or any combination of the keywords:

  # Options FileInfo AuthConfig Limit

  #

  AllowOverride None

  #

  # Controls who can get stuff from this server.

  #

  Order allow,deny

  Allow from all

  3.在文件Apache2.2\conf\extra\httpd-vhosts.conf中增加:

  复制代码 代码如下:

  #放在第一个

  ServerAdmin webmaster@dummy-host2.ies.inventec

  DocumentRoot "D:\work\test"

  ServerName test

  ErrorLog "logs/dummy-host2.ies.inventec-error.log"

  CustomLog "logs/dummy-host2.ies.inventec-access.log" common

  ServerAdmin webmaster@dummy-host2.ies.inventec

  DocumentRoot "C:\Program Files\phpMyAdmin-2.11.4"

  ServerName mysql

  ErrorLog "logs/dummy-host2.ies.inventec-error.log"

  CustomLog "logs/dummy-host2.ies.inventec-access.log" common

  ServerAdmin webmaster@dummy-host2.ies.inventec

  DocumentRoot "C:\Program Files\Apache Software Foundation\Apache2.2\htdocs"

  ServerName localhost

  ErrorLog "logs/dummy-host2.ies.inventec-error.log"

  CustomLog "logs/dummy-host2.ies.inventec-access.log" common

Apache为mysql以及自己的项目设置虚拟路径的更多相关文章

  1. 详细解说Tomcat 设置虚拟路径的几种方法及为什么设置虚拟路径

    说明:此次使用的是Tomcat 7.0 很多朋友都会很疑惑,既然我们都知道在Tomcat服务器上部署项目只要将项目打包,然后放到webapps目录下就可以了,为什么还需要配置虚拟路径?的确,把项目放到 ...

  2. appserv 设置虚拟路径httpd.conf的配置

    总结 1 打开appserv的安装目录,找到httpd.conf文件,分别去掉下面两行文字前面的#号. #LoadModule vhost_alias_module modules/mod_vhost ...

  3. tomcat 设置虚拟路径的4种方法

    通常使用方法1或者方法2  方法1 (添加配置文件):推荐使用,不需要重启服务器 在Tomcat根目录下的/conf/Catalina/localhost/ 路径下新建一个filename.xml,并 ...

  4. jsp网页在浏览器中不显示图片_eclipse环境下配置tomcat中jsp项目的虚拟路径

    遇到的问题是这种,在jsp网页中嵌入了本地的图片,由于会用到上传到服务器的图片,所以没有放到项目里面,而是把全部图片单独放到一个文件夹里,然后打算使用绝对路径把要显示的图片显示出来.比方是放在了E盘的 ...

  5. Tomcat之——配置项目有虚拟路径

    转载请注明出处:http://blog.csdn.net/l1028386804/article/details/47024863 非常easy,在Tomcat的Server.xml文件里的Host节 ...

  6. Eclipse对web项目设置请求路径(与项目名称不同)

    可以在下图位置,进行修改 也可以修改项目的路径下的.settings文件夹下的org.eclipse.wst.common.component的value属性 <property name=&q ...

  7. tomcat设置虚拟路径映射服务器指定的物理路径

    在tomcat的server.xml中的host标签中加入如下标签: <Context crossContext="false" debug="1" do ...

  8. 使用eclipse在tomcat中设置项目启动的虚拟路径

    很多时候我们在启动项目的时候都会在浏览器输入"localhost:+端口号+项目名称" 其实tomcat是可以省去这种麻烦的,通过设置项目的虚拟路径就可访问项目了 第一步 选择ec ...

  9. jsp文件调用本地文件的方法(Tomcat server.xml 设置虚拟目录)

    JSP文件: <video id="my-video" class="video-js" controls preload="auto" ...

随机推荐

  1. Python【第三篇】文件操作、字符编码

    一.文件操作 文件操作分为三个步骤:文件打开.操作文件.关闭文件,但是,我们可以用with来管理文件操作,这样就不需要手动来关闭文件. 实现原理: import contextlib @context ...

  2. python学习day11 函数Ⅲ (内置函数与lambda表达式)

    函数Ⅲ(内置函数&lambda表达式) 1.函数小高级 函数可以当做变量来使用: def func(): print(123) func_list = [func, func, func] # ...

  3. JS 防抖函数和节流函数

    文章转载自:木上有水 什么是防抖?什么是节流? 工作中我们经常会用一些方法监听某些事件的完成,比如scroll.resize.keyup等. 常规事件触发的时候,比如scroll,会在短时间内触发多次 ...

  4. 洛谷P2120 [ZJOI2007]仓库建设 斜率优化DP

    做的第一道斜率优化\(DP\)QwQ 原题链接1/原题链接2 首先考虑\(O(n^2)\)的做法:设\(f[i]\)表示在\(i\)处建仓库的最小费用,则有转移方程: \(f[i]=min\{f[j] ...

  5. Springboot 6.Springboot 返回cookies信息的验证和post接口开发及常见错误解决

    在介绍之前先将一个小插件:lombok  ,在prefrence里面点击plugins,然后搜索lombok,进行install就可以了 首先将pom文件里面的lombok引进来 <depend ...

  6. [SDOI2006] 保安站岗

    题目链接 第一遍不知道为什么就爆零了…… 第二遍改了一下策略,思路没变,结果不知道为什么就 A 了??? 树形 DP 经典问题:选择最少点以覆盖树上所有点(边). 对于本题,设 dp[i][0/1][ ...

  7. grafana-Admin密码重置

    1)查看Grafana配置文件,确定grafana.db的路径 [paths] ;data = /var/lib/grafana [database] # For "sqlite3" ...

  8. Moving Average

    移动平均算法Demo #!/usr/bin/python2.7 # Fetch data from BD and analyse. import json import urllib import t ...

  9. Geometric regularity criterion for NSE: the cross product of velocity and vorticity 1: $u\times \om$

    在 [Chae, Dongho. On the regularity conditions of suitable weak solutions of the 3D Navier-Stokes equ ...

  10. 一些Js操作

    一.after()和before()方法的区别 after()——其方法是将方法里面的参数添加到jquery对象后面去:    如:A.after(B)的意思是将B放到A后面去:    before( ...