apache配置文件

httpd-vhost.conf文件中:

<VirtualHost *:80>
    ServerAdmin [email protected]
    DocumentRoot "D:\workspace\OradtWeb1.0_bug\Public"
    ServerName work10bug.com
    ErrorLog "logs/my.work10bug.com-error.log"
    CustomLog "logs/my.work10bug.com-access.log" common
    <Directory />
        Options FollowSymLinks
    AllowOverride All
        Order allow,deny
        IndexOptions Charset=UTF-8
        Allow from all
  </Directory>
</VirtualHost>

httpd.conf文件中:

ServerName localhost:80

#
# Deny access to the entirety of your server‘s filesystem. You must
# explicitly permit access to web content directories in other
# <Directory> blocks below.
#
<Directory />
    Options All
    AllowOverride all
</Directory>

------------------

DocumentRoot "D:/xampp/htdocs"
<Directory "D:/xampp/htdocs">
    #
    # 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.4/mod/core.html#options
    # for more information.
    #
    Options Indexes FollowSymLinks Includes ExecCGI

#
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   AllowOverride FileInfo AuthConfig Limit
    #
    AllowOverride All

#
    # Controls who can get stuff from this server.
    #
    Require all granted
</Directory>

-----------------------

#
# "D:/xampp/cgi-bin" should be changed to whatever your ScriptAliased
# CGI directory exists, if you have that configured.
#
<Directory "D:/xampp/cgi-bin">
    AllowOverride All
    Options FollowSymLinks
    Require all granted
</Directory>

时间: 2024-08-10 23:24:24

apache配置文件的相关文章

apache 配置文件修改

:set nu vi编辑器显示行号: :set nonu  取消行号: :123 到达123行: 修改apache配置文件httpd.conf user 程序执行者: ServerName 网站域名: DocumentRoot 网站根目录: apache 的服务权限: <Directory /> Options FollowSymLinks indexs (允许有快捷方式,和在没有默认首页的情况下以列表显示文件夹) 建议改为  Options none AllowOverride None O

Apache 配置文件解析及虚拟机配置示例

配置文件详细解析Apache配置文件默认位于/usr/local/apache2/conf目录下,在该目录下最主要的配置文件是httpd.conf文件,还有一些位于extra目录下的附加配置文件.此外original目录中存有所有这些配置文件的副本.Apache HTTP Sever主配置文件主要由指令以及容器组成,容器使用<容器名称>开始,</容器名称>结尾,容器的指令一般仅在局部有效.下面是对主配置文件重点指定的具体描述.SeverRoot指令ServerRoot指令设置Apa

Apache配置文件不完全翻译

# 配置服务器生成页面的页脚 On|Off|EMail ServerSignature Off # 选择性输出服务器相关信息:Full|Major|Minimal|Minor|OS|Prod ServerTokens Full # Apache的安装目录 ServerRoot "D:/EnvPHP/Apache2.4" # 默认监听端口号 Listen 80 # 设置管理员的邮箱地址 ServerAdmin [email protected] # 设置了服务器用于辨识自己的主机名和端口

Apache配置文件服务器

配置Apache文件服务器: apache配置文件服务器httpd.conf中这两个模块必须不被注释LoadModule autoindex_module modules/mod_autoindex.soLoadModule dir_module modules/mod_dir.so 然后到D:\Apache24\conf\extra目录下修改httpd-autoindex.confFancyIndexing 开启目录浏览修饰HTMLTable 此选择与FancyIndexing一起构建一个简单

【PHP_检查apache配置文件语法是否出错的方法】

1.在apache安装目录中中找到httpd.exe(D:\Program Files\amp\apache\bin) 2.在环境变量中的path中加入httpd.exe的路径 3.重开一个cmd,输入 httpd -t即可看到apache配置文件语法检查结果

Apache配置文件详解

Apache配置文件详解   *此为用yum安装的apache文件的各项解释和编译安装后的apache配置文件大同小异,仅做参考 httpd 的配置文件是: /etc/httpd/conf/httpd.conf [ //查看配置文件 # grep -v "#" /etc/httpd/conf/httpd.conf //当服务器响应主机头(header)信息时显示Apache 的版本和操作系统名称 ServerTokens OS //设置服务器的根目录 ServerRoot "

Apache配置文件详解之httpd.conf(2)

一. <directory>     </directory>语指令句 (说明:<directory>path</directory>主要是对目录文件访问权限的控制) 我们都知道Apache配置文件:httpd.conf文件中有这么几行内容,如下 <Directory />    AllowOverride none    Require all denied</Directory> 这几句内容告诉我们Apache默认对根目录的访问权

Python脚本--Apache配置文件

通过python脚本来修改apache的配置文件: 该脚本可以解析apache配置文件,找到VirtualHost部分,替换DocumentRoot. #!/usr/bin/python from cStringIO import StringIO import re vhost_start = re.compile(r'<VirtualHost\s+(.*?)>') vhost_end = re.compile(r'</VirtualHost>') docroot_re = re

Apache配置文件httpd.conf内容翻译

本文已经废弃,现在apache2不依靠httpd.conf来配置. Ubuntu下默认的配置文件是/etc/apache2/sites-available/default 可以修改上面文件来修改apache2配置 目录 [隐藏] 1 原文说明 2 文件全局说明 3 第一区:全局环境参数 4 第二区:“主”服务配置 5 第三区:虚拟主机 原文说明 引自www.linuxsir.org 原文地址:http://www.7880.com/Info/Article-3df0ef00.html 文件全局说

httpd (apache) 配置文件(httpd.conf)英文对中文的详解

最近几天看了一些关于httpd的书籍,顺便把学习到的知识记录下来,算不上很精通, 只是些皮毛,可以帮助一些英文不好的 刚接触Linux 下httpd的同学,有错的请评论纠正. httpd特性和功能: 事先创建进程 按需求维持适当的进程 模块化设计,核心比较小,各种功能都模块添加 支持运行配置,支持单独编译模块 支持多种方式的虚拟主机配置:(基于ip的虚拟主机,基于端口的虚拟主机,基于域名的虚拟主机) 支持https协议(mod_ssl) 支持用户认证 支持基于IP或主机名的ACL 支持每个目录的