⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mod_autoindex.html

📁 这个是我在web培训时老师提供的手册
💻 HTML
📖 第 1 页 / 共 4 页
字号:
      </code></p></div>

      <p><a href="../content-negotiation.html">Content negotiation</a>
      will be performed if <code class="directive"><a href="../mod/core.html#options">Options</a></code>
      <code>MultiViews</code> is in effect. If <var>filename</var> resolves
      to a static <code>text/html</code> document (not a CGI script) and
      either one of the <code class="directive"><a href="../mod/core.html#options">options</a></code>
      <code>Includes</code>或<code>IncludesNOEXEC</code> is enabled,
      the file will be processed for server-side includes (see the
      <code class="module"><a href="../mod/mod_include.html">mod_include</a></code> documentation).</p>
    </div>

    <p>If the file specified by <code class="directive">HeaderName</code> contains
    the beginnings of an HTML document (&lt;html&gt;, &lt;head&gt;, etc.)
    then you will probably want to set <a href="#indexoptions.suppresshtmlpreamble"><code>IndexOptions
    +SuppressHTMLPreamble</code></a>, so that these tags are not
    repeated.</p>

</div>
<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
<div class="directive-section"><h2><a name="IndexIgnore" id="IndexIgnore">IndexIgnore</a> <a name="indexignore" id="indexignore">指令</a></h2>
<table border="1" cellpadding="0" cellspacing="0" bordercolor="#AAAAAA" class="directive">
<tr><th><a href="directive-dict.html#Description">说明</a></th><td>Adds to the list of files to hide when listing 
a directory</td></tr>
<tr><th><a href="directive-dict.html#Syntax">语法</a></th><td><code>IndexIgnore <var>file</var> [<var>file</var>] ...</code></td></tr>
<tr><th><a href="directive-dict.html#Context">作用域</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
<tr><th><a href="directive-dict.html#Override">覆盖项</a></th><td>Indexes</td></tr>
<tr><th><a href="directive-dict.html#Status">状态</a></th><td>基本(B)</td></tr>
<tr><th><a href="directive-dict.html#Module">模块</a></th><td>mod_autoindex</td></tr>
</table>
    <p><code class="directive">IndexIgnore</code> directive adds to the
    list of files to hide when listing a directory. <var>File</var> is a
    shell-style wildcard expression or full
    filename. Multiple IndexIgnore directives add
    to the list, rather than the replacing the list of ignored
    files. By default, the list contains <code>.</code> (the current
    directory).</p>

    <div class="example"><p><code>
      IndexIgnore README .htaccess *.bak *~
    </code></p></div>

</div>
<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
<div class="directive-section"><h2><a name="IndexOptions" id="IndexOptions">IndexOptions</a> <a name="indexoptions" id="indexoptions">指令</a></h2>
<table border="1" cellpadding="0" cellspacing="0" bordercolor="#AAAAAA" class="directive">
<tr><th><a href="directive-dict.html#Description">说明</a></th><td>Various configuration settings for directory 
indexing</td></tr>
<tr><th><a href="directive-dict.html#Syntax">语法</a></th><td><code>IndexOptions  [+|-]<var>option</var> [[+|-]<var>option</var>] ...</code></td></tr>
<tr><th><a href="directive-dict.html#Context">作用域</a></th><td>server config, virtual host, directory, .htaccess</td></tr>
<tr><th><a href="directive-dict.html#Override">覆盖项</a></th><td>Indexes</td></tr>
<tr><th><a href="directive-dict.html#Status">状态</a></th><td>基本(B)</td></tr>
<tr><th><a href="directive-dict.html#Module">模块</a></th><td>mod_autoindex</td></tr>
</table>
    <p><code class="directive">IndexOptions</code> directive specifies the
    behavior of the directory indexing. <var>Option</var> can be one
    of</p>

    <dl>
      <dt><a name="indexoptions.descriptionwidth" id="indexoptions.descriptionwidth">DescriptionWidth=[<var>n</var> | *]</a> (<em>Apache 2.0.23 and
      later</em>)</dt>

      <dd>The <code>DescriptionWidth</code> keyword allows you to
      specify the width of the description column in
      characters.</dd>

      <dd><code>-DescriptionWidth</code> (or unset) allows
      <code class="module"><a href="../mod/mod_autoindex.html">mod_autoindex</a></code> to calculate the best width.</dd>

      <dd><code>DescriptionWidth=<var>n</var></code> fixes the column width to
      <var>n</var> bytes wide.</dd>

      <dd><code>DescriptionWidth=*</code> grows the column to the
      width necessary to accommodate the longest description
      string.</dd>

      <dd><strong>See the section on <code class="directive"><a href="#adddescription">AddDescription</a></code> for dangers
      inherent in truncating descriptions.</strong></dd>

      <dt><a name="indexoptions.fancyindexing" id="indexoptions.fancyindexing">FancyIndexing</a></dt>

      <dd>This turns on fancy indexing of directories.</dd>

      <dt><a name="indexoptions.foldersfirst" id="indexoptions.foldersfirst">FoldersFirst</a> (<em>Apache
      2.0.23 and later</em>)</dt>

      <dd>If this option is enabled, subdirectory listings will
      <em>always</em> appear first, followed by normal files in the
      directory. The listing is basically broken into two
      components, the files and the subdirectories, and each is
      sorted separately and then displayed subdirectories-first.
      For instance, if the sort order is descending by name, and
      <code>FoldersFirst</code> is enabled, subdirectory
      <code>Zed</code> will be listed before subdirectory
      <code>Beta</code>, which will be listed before normal files
      <code>Gamma</code>和<code>Alpha</code>. <strong>This option
      only has an effect if <a href="#indexoptions.fancyindexing"><code>FancyIndexing</code></a> is also enabled.</strong></dd>

      <dt><a name="indexoptions.htmltable" id="indexoptions.htmltable">HTMLTable</a> (<em>Experimental,
      Apache 2.0.23 and later</em>)</dt>

      <dd>This experimental option with FancyIndexing constructs a
      simple table for the fancy directory listing. Note this will
      confuse older browsers. It is particularly necessary if file
      names or description text will alternate between
      left-to-right and right-to-left reading order, as can happen
      on WinNT or other utf-8 enabled platforms.</dd>

      <dt><a name="indexoptions.iconsarelinks" id="indexoptions.iconsarelinks">IconsAreLinks</a></dt>

      <dd>This makes the icons part of the anchor for the filename, for
      fancy indexing.</dd>

      <dt><a name="indexoptions.iconheight" id="indexoptions.iconheight">IconHeight[=<var>pixels</var>]</a></dt>

      <dd>Presence of this option, when used with IconWidth, will cause
      the server to include <code>height</code>和<code>width</code>
      attributes in the <code>img</code> tag for the file icon. This allows
      browser to precalculate the page layout without having to wait until
      all the images have been loaded. If no value is given for the option,
      it defaults to the standard height of the icons supplied with the Apache
      software.</dd>

      <dt><a name="indexoptions.iconwidth" id="indexoptions.iconwidth">IconWidth[=<var>pixels</var>]</a></dt>

      <dd>Presence of this option, when used with <code>IconHeight</code>,
      will cause the server to include <code>height</code>和<code>width</code> attributes in the <code>img</code> tag for
      the file icon. This allows browser to precalculate the page
      layout without having to wait until all the images have been
      loaded. If no value is given for the option, it defaults to
      the standard width of the icons supplied with the Apache
      software.</dd>

      <dt><a name="indexoptions.ignorecase" id="indexoptions.ignorecase">IgnoreCase</a></dt>

      <dd>If this option is enabled, names are sorted in a case-insensitive 
      manner.  For instance, if the sort order is ascending by name, and 
      IgnoreCase is enabled, file Zeta  will be listed after file alfa 
      (Note: file GAMMA will always be listed before file gamma). </dd>

      <dt><a name="indexoptions.ignoreclient" id="indexoptions.ignoreclient">IgnoreClient</a></dt>

      <dd>This option causes <code class="module"><a href="../mod/mod_autoindex.html">mod_autoindex</a></code> to ignore all
      query variables from the client, including sort order (implies
      <code><a href="#indexoptions.suppresscolumnsorting">SuppressColumnSorting</a></code>.)</dd>

      <dt><a name="indexoptions.namewidth" id="indexoptions.namewidth">NameWidth=[<var>n</var>
               | *]</a></dt>

      <dd>The <code>NameWidth</code> keyword allows you to specify the width
      of the filename column in bytes.</dd>

      <dd><code>-NameWidth</code> (or unset) allows <code class="module"><a href="../mod/mod_autoindex.html">mod_autoindex</a></code> to calculate the best width.</dd>

      <dd><code>NameWidth=<var>n</var></code> fixes the column width to
      <var>n</var> bytes wide.</dd>

      <dd><code>NameWidth=*</code> grows the column to the necessary
      width.</dd>

      <dt><a name="indexoptions.scanhtmltitles" id="indexoptions.scanhtmltitles">ScanHTMLTitles</a></dt>

      <dd>This enables the extraction of the title from HTML documents
      for fancy indexing. If the file does not have a description
      given by <code class="directive"><a href="#adddescription">AddDescription</a></code>
      then httpd will read the document for the value of the
      <code>title</code> element. This is CPU and disk intensive.</dd>

      <dt><a name="indexoptions.showforbidden" id="indexoptions.showforbidden">ShowForbidden</a></dt>

      <dd>If specified, Apache will show files normally hidden because
      the subrequest returned HTTP_UNAUTHORIZED or HTTP_FORBIDDEN</dd>

      <dt><a name="indexoptions.suppresscolumnsorting" id="indexoptions.suppresscolumnsorting">SuppressColumnSorting</a></dt>

      <dd>If specified, Apache will not make the column headings in a
      FancyIndexed directory listing into links for sorting. The
      default behavior is for them to be links; selecting the
      column heading will sort the directory listing by the values
      in that column. <strong>Prior to Apache 2.0.23, this also
      disabled parsing the Query Arguments for the sort
      string.</strong> That behavior is now controlled by <a href="#indexoptions.ignoreclient">IndexOptions
      IgnoreClient</a> in Apache 2.0.23.</dd>

      <dt><a name="indexoptions.suppressdescription" id="indexoptions.suppressdescription">SuppressDescription</a></dt>

      <dd>This will suppress the file description in fancy indexing
      listings. By default, no file descriptions are defined, and
      so the use of this option will regain 23 characters of screen
      space to use for something else. See <code class="directive"><a href="#adddescription">AddDescription</a></code> for information about setting the file
      description. See also the <code><a href="#indexoptions.descriptionwidth">DescriptionWidth</a></code>
      index option to limit the size of the description column.</dd>

      <dt><a name="indexoptions.suppresshtmlpreamble" id="indexoptions.suppresshtmlpreamble">SuppressHTMLPreamble</a></dt>

      <dd>If the directory actually contains a file specified by the
      <code class="directive"><a href="#headername">HeaderName</a></code>
      directive, the module usually includes the contents of the file
      after a standard HTML preamble (<code>&lt;html&gt;</code>, <code>&lt;head&gt;</code>, <em>et cetera</em>). The
      <code>SuppressHTMLPreamble</code> option disables this behaviour,
      causing the module to start the display with the header file
      contents. The header file must contain appropriate HTML instructions
      in this case. If there is no header file, the preamble is generated
      as usual.</dd>

      <dt><a name="indexoptions.suppressicon" id="indexoptions.suppressicon">SuppressIcon</a> (<em>Apache
      2.0.23 and later</em>)</dt>

      <dd>This will suppress the icon in fancy indexing listings.
      Combining both <code>SuppressIcon</code>和<code>SuppressRules</code> yields proper HTML 3.2 output, which
      by the final specification prohibits <code>img</code>和<code>hr</code> elements from the <code>pre</code> block (used to
      format FancyIndexed listings.)</dd>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -