修改mysql安装服务名称(Apache为mysql以及自己的项目设置虚拟路径)
修改mysql安装服务名称
Apache为mysql以及自己的项目设置虚拟路径
1.Apache2.2\conf\httpd.conf中释放:
Include conf/extra/httpd-vhosts.conf(去掉前面的#)
2.httpd.conf中增加
<Directory "E:/work/test"> #项目文件夹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
</Directory>
<Directory "C:/phpMyAdmin"> #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
</Directory>
3.在文件Apache2.2\conf\extra\httpd-vhosts.conf中增加:
复制代码 代码如下:
<VirtualHost *:80> #放在第一个
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
</VirtualHost>
<VirtualHost *:80>
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
</VirtualHost>
<VirtualHost *:80>
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
</VirtualHost>
4.在windows\system32\drivers\etc\hosts檔中增加:(是hosts檔,不是hosts.msn之类的)
127.0.0.1 test
127.0.0.1 mysql
5.在浏览器中输入:
http://mysql/index.php //查看数据库设置是否成功
http://test/index.php //查看项目路径设置是否成功
- 如何使用自定义discuz代码(Apache,IIS下Discuz x1.5伪静态设置方法)
- apache服务配置详解(Apache Web服务器的完全安装指南)
- apache安全配置使用教程(正确配置与维护Apache安全性设置方法)
- apache安全配置(apache在win2003下的安全设置配合文件夹权限目录,很好很安全)
- apache静态化怎么用(apache中访问不了伪静态页面的解决方法)
- apache2.4支持php5.5吗(WINDOWS下php5.2.4+mysql6.0+apache2.2.4+ZendOptimizer-3.3.0配置)
- ssl服务器搭建的步骤(windows apache环境下部署SSL证书让网站支持https的配置方法)
- 如何认识服务器(关于Nginx、Apache、Tomcat三个WEB服务器的区别和认知)
- apache配置详解(apache2.2和php5.2.17在windows下整合过程的错误解决方法)
- clickhouse 底层架构(使用 Apache Superset 可视化 ClickHouse 数据的两种方法)
- apache域名绑定(Apache配置独立域名的方法)
- idea中tomcat快速部署(IDEA编辑器整合Apache Tomcat的详细教程)
- apache虚拟目录配置(Apache 添加虚拟目录注意事项)
- apache服务器设置301(Apache Rewrite实现URL的301跳转和域名跳转)
- xampp在什么操作系统中不能使用(xampp apache启动失效问题的解决方法)
- apachessl证书怎么获取(Apache SSL服务器配置SSL详解)
- 阴生环境 耐阴地被植物,你知道哪些(阴生环境耐阴地被植物)
- 常见的喜阴植物有哪些 养室内盆栽就在这里选(常见的喜阴植物有哪些)
- 这8种耐阴植物,营造阴生植物花境,也是一个不错的选择(营造阴生植物花境)
- 览邦G08 Plus SMART WATCH 测评⑱ 全独立这才是智能手表该有的样子(览邦G08PlusSMART)
- 荣耀手表 GS 3 真机亮相 不支持无线充电(荣耀手表GS3)
- 通过体温就能为智能手表充电 原来是用NASA在空间站用的黑科技(通过体温就能为智能手表充电)
热门推荐
- mysql删除数据库的命令(MySQL 线上数据库清理数据的方法)
- 加载页面执行css动画效果(纯CSS实现预加载动画效果)
- 宝塔面板服务器设置(宝塔面板解决网站云服务器偶尔出现CPU100%的情况)
- docker-compose查看服务状态(Docker+DockerCompose封装web应用的方法步骤)
- mysql update 多个字段(mysql update case 更新字段值不固定的操作)
- drools动态执行规则(使用swoole 定时器变更超时未支付订单状态的解决方案)
- vue函数中的默认参数(Vue3中SetUp函数的参数props、context详解)
- EasyUI DateBox设置默认值
- 阿里云ssl证书安装教程(阿里云申请的 CA Wosin 证书,在Windows iis下导入证书的步骤分享)
- docker swarm管理(Docker Swarm 服务编排之命令详解)
排行榜
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9