blob: 7954464aa5c17093b81d1eea4b7ed711193ffe59 [file] [log] [blame]
<?xml version="1.0" encoding="EUC-JP"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="ja" xml:lang="ja"><head><!--
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
This file is generated from xml source: DO NOT EDIT
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
-->
<title>mod_alias - Apache HTTP ¥µ¡¼¥Ð</title>
<link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
<link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
<link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" />
<link href="../images/favicon.ico" rel="shortcut icon" /></head>
<body>
<div id="page-header">
<p class="menu"><a href="../mod/">¥â¥¸¥å¡¼¥ë</a> | <a href="../mod/directives.html">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">ÍѸì</a> | <a href="../sitemap.html">¥µ¥¤¥È¥Þ¥Ã¥×</a></p>
<p class="apache">Apache HTTP ¥µ¡¼¥Ð ¥Ð¡¼¥¸¥ç¥ó 2.1</p>
<img alt="" src="../images/feather.gif" /></div>
<div class="up"><a href="./"><img title="&lt;-" alt="&lt;-" src="../images/left.gif" /></a></div>
<div id="path">
<a href="http://www.apache.org/">Apache</a> &gt; <a href="http://httpd.apache.org/">HTTP ¥µ¡¼¥Ð</a> &gt; <a href="http://httpd.apache.org/docs-project/">¥É¥­¥å¥á¥ó¥Æ¡¼¥·¥ç¥ó</a> &gt; <a href="../">¥Ð¡¼¥¸¥ç¥ó 2.1</a> &gt; <a href="./">¥â¥¸¥å¡¼¥ë</a></div>
<div id="page-content">
<div id="preamble"><h1>Apache ¥â¥¸¥å¡¼¥ë mod_alias</h1>
<div class="toplang">
<p><span>Available Languages: </span><a href="../en/mod/mod_alias.html" hreflang="en" rel="alternate" title="English">&nbsp;en&nbsp;</a> |
<a href="../ja/mod/mod_alias.html" title="Japanese">&nbsp;ja&nbsp;</a> |
<a href="../ko/mod/mod_alias.html" hreflang="ko" rel="alternate" title="Korean">&nbsp;ko&nbsp;</a></p>
</div>
<div class="outofdate">This translation may be out of date. Check the
English version for recent changes.</div>
<table class="module"><tr><th><a href="module-dict.html#Description">ÀâÌÀ:</a></th><td>¥Û¥¹¥È¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¾å¤Î¤¤¤í¤¤¤í¤Ê°ã¤¦¾ì½ê¤ò
¥É¥­¥å¥á¥ó¥È¥Ä¥ê¡¼¤Ë¥Þ¥Ã¥×¤¹¤ëµ¡Ç½¤È¡¢
URL ¤Î¥ê¥À¥¤¥ì¥¯¥È¤ò¹Ô¤Ê¤¦µ¡Ç½¤òÄ󶡤¹¤ë</td></tr>
<tr><th><a href="module-dict.html#Status">¥¹¥Æ¡¼¥¿¥¹:</a></th><td>Base</td></tr>
<tr><th><a href="module-dict.html#ModuleIdentifier">¥â¥¸¥å¡¼¥ë¼±ÊÌ»Ò:</a></th><td>alias_module</td></tr>
<tr><th><a href="module-dict.html#SourceFile">¥½¡¼¥¹¥Õ¥¡¥¤¥ë:</a></th><td>mod_alias.c</td></tr></table>
<h3>³µÍ×</h3>
<p>¤³¤Î¥â¥¸¥å¡¼¥ë¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï¥µ¡¼¥Ð¤Ë¥ê¥¯¥¨¥¹¥È¤¬ÅþÃ夷¤¿¤È¤­¤Ë
URL ¤ÎÁàºî¤äÀ©¸æ¤ò¤¹¤ë¤³¤È¤ò²Äǽ¤Ë¤·¤Þ¤¹¡£<code class="directive"><a href="#alias">Alias</a></code>
¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤È <code class="directive"><a href="#scriptalias">ScriptAlias</a></code>
¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï
URL ¤È¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¤Î¥Ñ¥¹¤ò¥Þ¥Ã¥×¤¹¤ë¤¿¤á¤Ë»ÈÍѤµ¤ì¤Þ¤¹¡£¤³¤ì¤Ï
<code class="directive"><a href="../mod/core.html#documentroot">DocumentRoot</a></code>
¤Î²¼¤Ë¤Ê¤¤¥É¥­¥å¥á¥ó¥È¤ò¥¦¥§¥Ö¤Î¥É¥­¥å¥á¥ó¥È¥Ä¥ê¡¼¤Î°ìÉô¤È¤·¤Æ
Á÷¤é¤ì¤ë¤è¤¦¤Ë¤·¤Þ¤¹¡£<code class="directive"><a href="#scriptalias">ScriptAlias</a></code>
¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ë¤Ï¥Þ¥Ã¥×Àè¤Î¥Ç¥£¥ì¥¯¥È¥ê¤¬ CGI
¥¹¥¯¥ê¥×¥È¤Î¤ß¤Ç¤¢¤ë¤³¤È¤ò¼¨¤¹¤È¤¤¤¦Äɲäθú²Ì¤¬¤¢¤ê¤Þ¤¹¡£
</p>
<p><code class="directive"><a href="#redirect">Redirect</a></code> ¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï
¥¯¥é¥¤¥¢¥ó¥È¤Ë°ã¤Ã¤¿
URL ¤Ë¿·¤·¤¤¥ê¥¯¥¨¥¹¥È¤òÁ÷¤ë¤è¤¦¤Ë»Ø¼¨¤·¤Þ¤¹¡£¤³¤ì¤Ï¡¢
¥ê¥½¡¼¥¹¤¬¿·¤·¤¤¾ì½ê¤Ë°ÜÆ°¤·¤¿¤È¤­¤Ë¤è¤¯»ÈÍѤµ¤ì¤Þ¤¹¡£</p>
</div>
<div id="quickview"><h3 class="directives">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</h3>
<ul id="toc">
<li><img alt="" src="../images/down.gif" /> <a href="#alias">Alias</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#aliasmatch">AliasMatch</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#redirect">Redirect</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#redirectmatch">RedirectMatch</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#redirectpermanent">RedirectPermanent</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#redirecttemp">RedirectTemp</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#scriptalias">ScriptAlias</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#scriptaliasmatch">ScriptAliasMatch</a></li>
</ul>
<h3>¥È¥Ô¥Ã¥¯</h3>
<ul id="topics">
<li><img alt="" src="../images/down.gif" /> <a href="#order">½èÍý¤Î½çÈÖ</a></li>
</ul><h3>»²¾È</h3>
<ul class="seealso">
<li><code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code></li>
<li><a href="../urlmapping.html">URL ¤«¤é¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¾å¤Î°ÌÃ֤ؤΥޥåԥó¥°</a></li>
</ul></div>
<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
<div class="section">
<h2><a name="order" id="order">½èÍý¤Î½çÈÖ</a></h2>
<p>ÍÍ¡¹¤Ê¥³¥ó¥Æ¥­¥¹¥ÈÃæ¤Ç¤Î Alias ¤ä Redirect ¤Ï¾¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤È
Ʊ¤¸¤è¤¦¤Ëɸ½à¤Î <a href="../sections.html#mergin">¥Þ¡¼¥¸µ¬Â§</a> ¤Ë
½¾¤Ã¤Æ½èÍý¤µ¤ì¤Þ¤¹¡£¤¿¤À¤·¡¢(Î㤨¤Ð <code class="directive"><a href="../mod/core.html#virtualhost">&lt;VirtualHost&gt;</a></code> ¥»¥¯¥·¥ç¥ó¤ÎÃæ¤Î¤è¤¦¤Ë) Ê£¿ô¤Î Alias ¤ä Redirect ¤¬
Ʊ¤¸¥³¥ó¥Æ¥­¥¹¥ÈÃæ¤Ë¸½¤ì¤¿¾ì¹ç¤Ï·è¤Þ¤Ã¤¿½çÈ֤ǽèÍý¤µ¤ì¤Þ¤¹¡£</p>
<p>¤Þ¤º¡¢Alias ¤ÎÁ°¤Ë¤¹¤Ù¤Æ¤Î Redirect ¤¬½èÍý¤µ¤ì¤Þ¤¹¡£¤Ç¤¹¤«¤é¡¢<code class="directive"><a href="#redirect">Redirect</a></code> ¤« <code class="directive"><a href="#redirectmatch">RedirectMatch</a></code> ¤Ë¥Þ¥Ã¥Á¤¹¤ë¥ê¥¯¥¨¥¹¥È¤Ë¤Ï
Alias ¤Ï·è¤·¤ÆŬÍѤµ¤ì¤Þ¤»¤ó¡£¼¡¤Ë¡¢Alias ¤È Redirect ¤¬ÀßÄê¥Õ¥¡¥¤¥ëÃæ¤Î
½çÈÖ¤ËŬÍѤµ¤ì¡¢ºÇ½é¤Ë¥Þ¥Ã¥Á¤·¤¿¤â¤Î¤¬Í¥À褵¤ì¤Þ¤¹¡£</p>
<p>¤Ç¤¹¤«¤é¡¢Æó¤Ä°Ê¾å¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤¬Æ±¤¸¥Ñ¥¹¤ËŬÍѤµ¤ì¤ë¤È¤­¤Ï¡¢
¤¹¤Ù¤Æ¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Î¸ú²Ì¤òÆÀ¤ë¤¿¤á¤Ë¤Ï¤è¤ê¾Ü¤·¤¤¥Ñ¥¹¤òÀè¤Ë½ñ¤¯
ɬÍפ¬¤¢¤ê¤Þ¤¹¡£Î㤨¤Ð¡¢¼¡¤ÎÀßÄê¤Ï´üÂÔÄ̤ê¤ÎÆ°ºî¤ò¤·¤Þ¤¹:</p>
<div class="example"><p><code>
Alias /foo/bar /baz<br />
Alias /foo /gaq
</code></p></div>
<p>¤·¤«¤·¡¢¾åµ­¤ÎÆó¤Ä¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Î½çÈÖ¤¬µÕ¤Ë¤Ê¤ë¤È¡¢
<code>/foo</code> <code class="directive"><a href="#alias">Alias</a></code> ¤¬
¾ï¤Ë <code>/foo/bar</code> <code class="directive"><a href="#alias">Alias</a></code> ¤è¤êÀè¤Ë¥Þ¥Ã¥Á¤·¤Þ¤¹¤Î¤Ç¡¢¸å¼Ô¤Ï
·è¤·¤ÆŬÍѤµ¤ì¤ë¤³¤È¤Ï¤¢¤ê¤Þ¤»¤ó¡£</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="Alias" id="Alias">Alias</a> <a name="alias" id="alias">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">ÀâÌÀ:</a></th><td>URL ¤ò¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¤Î°ÌÃ֤˥ޥåפ¹¤ë</td></tr>
<tr><th><a href="directive-dict.html#Syntax">¹½Ê¸:</a></th><td><code>Alias <var>URL-path</var>
<var>file-path</var>|<var>directory-path</var></code></td></tr>
<tr><th><a href="directive-dict.html#Context">¥³¥ó¥Æ¥­¥¹¥È:</a></th><td>¥µ¡¼¥ÐÀßÄê¥Õ¥¡¥¤¥ë, ¥Ð¡¼¥Á¥ã¥ë¥Û¥¹¥È</td></tr>
<tr><th><a href="directive-dict.html#Status">¥¹¥Æ¡¼¥¿¥¹:</a></th><td>Base</td></tr>
<tr><th><a href="directive-dict.html#Module">¥â¥¸¥å¡¼¥ë:</a></th><td>mod_alias</td></tr>
</table>
<p><code class="directive">Alias</code> ¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï¥É¥­¥å¥á¥ó¥È¤ò
¥í¡¼¥«¥ë¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¤Î
<code class="directive"><a href="../mod/core.html#documentroot">DocumentRoot</a></code>
°Ê³°¤Î¾ì½ê¤ËÊݴɤ¹¤ë¤³¤È¤ò²Äǽ¤Ë¤·¤Þ¤¹¡£
URL ¤Î (% ¤¬Éü¹æ¤µ¤ì¤¿) ¥Ñ¥¹¤¬ <var>url-path</var> ¤Ç»Ï¤Þ¤ë¤â¤Î¤Ï
<var>directory-filename</var>
¤Ç»Ï¤Þ¤ë¥í¡¼¥«¥ë¥Õ¥¡¥¤¥ë¤Ë¥Þ¥Ã¥×¤µ¤ì¤Þ¤¹¡£</p>
<div class="example"><h3>Îã</h3><p><code>
Alias /image /ftp/pub/image
</code></p></div>
<p>http://myserver/image/foo.gif ¤Ø¤Î¥ê¥¯¥¨¥¹¥È¤ËÂФ·¤Æ¡¢¥µ¡¼¥Ð¤Ï
¥Õ¥¡¥¤¥ë /ftp/pub/image/foo.gif ¤òÊÖ¤·¤Þ¤¹¡£</p>
<p>¤â¤· <var>url-path</var> ¤ÎºÇ¸å¤Ë /
¤ò½ñ¤¤¤¿¤Ê¤é¡¢¥µ¡¼¥Ð¤¬¥¨¥¤¥ê¥¢¥¹¤òŸ³«¤¹¤ë¤¿¤á¤Ë¤Ï¡¢ºÇ¸å¤Î /
¤¬É¬Íפˤʤ뤳¤È¤ËÃí°Õ¤·¤Æ¤¯¤À¤µ¤¤¡£¤¹¤Ê¤ï¤Á¡¢<code>Alias /icons/
/usr/local/apache/icons/</code> ¤È¤¤¤¦¤â¤Î¤ò»ÈÍѤ·¤Æ¤¤¤ë¾ì¹ç¤Ï¡¢
<code>/icons</code> ¤È¤¤¤¦ url ¤Ï¥¨¥¤¥ê¥¢¥¹¤µ¤ì¤Þ¤»¤ó¡£</p>
<p>¥¨¥¤¥ê¥¢¥¹¤Î<em>¹Ô¤­Àè</em>¤ò´Þ¤ó¤Ç¤¤¤ë <code class="directive"><a href="../mod/core.html#directory">&lt;Directory&gt;</a></code>
¥»¥¯¥·¥ç¥ó¤òÄɲ乤ëɬÍפ¬¤¢¤ë¤«¤â¤·¤ì¤Ê¤¤¤³¤È¤ËÃí°Õ¤·¤Æ¤¯¤À¤µ¤¤¡£
¥¨¥¤¥ê¥¢¥¹¤ÎŸ³«¤Ï <code class="directive"><a href="../mod/core.html#directory">&lt;Directory&gt;</a></code>
¥»¥¯¥·¥ç¥ó¤òÄ´¤Ù¤ëÁ°¤Ë¹Ô¤Ê¤ï¤ì¤Þ¤¹¤Î¤Ç¡¢
¥¨¥¤¥ê¥¢¥¹¤Î¹Ô¤­Àè¤Î <code class="directive"><a href="../mod/core.html#directory">&lt;Directory&gt;</a></code> ¥»¥¯¥·¥ç¥ó¤Î¤ß
¸ú²Ì¤¬¤¢¤ê¤Þ¤¹¡£
(¤·¤«¤·¡¢<code class="directive"><a href="../mod/core.html#location">&lt;Location&gt;</a></code>
¥»¥¯¥·¥ç¥ó¤Ï¥¨¥¤¥ê¥¢¥¹¤¬½èÍý¤µ¤ì¤ëÁ°¤Ë¼Â¹Ô¤µ¤ì¤Þ¤¹¤Î¤Ç¡¢
¤³¤Á¤é¤ÏŬÍѤµ¤ì¤Þ¤¹¡£)</p>
<p>Æäˡ¢<code>Alias</code> ¤ò
<code class="directive"><a href="../mod/core.html#documentroot">DocumentRoot</a></code>
¥Ç¥£¥ì¥¯¥È¥ê¤Î³°Â¦¤ËÇÛÃÖ¤·¤¿¾ì¹ç¤Ï¡¢¹Ô¤­Àè¤Î¥Ç¥£¥ì¥¯¥È¥ê¤ËÂФ¹¤ë
¥¢¥¯¥»¥¹¸¢¸Â¤òÌÀ¼¨Åª¤ËÀ©¸Â¤·¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¤Ç¤·¤ç¤¦¡£</p>
<div class="example"><h3>Îã</h3><p><code>
Alias /image /ftp/pub/image<br />
&lt;Directory /ftp/pub/image&gt;<br />
<span class="indent">
Order allow,deny<br />
Allow from all<br />
</span>
&lt;/Directory&gt;
</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="AliasMatch" id="AliasMatch">AliasMatch</a> <a name="aliasmatch" id="aliasmatch">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">ÀâÌÀ:</a></th><td>Àµµ¬É½¸½¤ò»È¤Ã¤Æ URL ¤ò¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¤Î°ÌÃ֤˥ޥåפ¹¤ë</td></tr>
<tr><th><a href="directive-dict.html#Syntax">¹½Ê¸:</a></th><td><code>AliasMatch <var>regex</var>
<var>file-path</var>|<var>directory-path</var></code></td></tr>
<tr><th><a href="directive-dict.html#Context">¥³¥ó¥Æ¥­¥¹¥È:</a></th><td>¥µ¡¼¥ÐÀßÄê¥Õ¥¡¥¤¥ë, ¥Ð¡¼¥Á¥ã¥ë¥Û¥¹¥È</td></tr>
<tr><th><a href="directive-dict.html#Status">¥¹¥Æ¡¼¥¿¥¹:</a></th><td>Base</td></tr>
<tr><th><a href="directive-dict.html#Module">¥â¥¸¥å¡¼¥ë:</a></th><td>mod_alias</td></tr>
</table>
<p>¤³¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï <code class="directive"><a href="#alias">Alias</a></code>
¤È¤Û¤È¤ó¤ÉƱ¤¸¤Ç¤¹¤¬¡¢´Êñ¤ÊÀèƬ¤«¤é¤Î¥Þ¥Ã¥Á¤ò¹Ô¤Ê¤¦¤Î¤Ç¤Ï¤Ê¤¯¡¢
ɸ½àÀµµ¬É½¸½¤òÍøÍѤ·¤Þ¤¹¡£¤³¤³¤Ç»ØÄꤵ¤ì¤¿Àµµ¬É½¸½¤È URL ¤Î¥Ñ¥¹
¤¬¹ç¤¦¤«¤É¤¦¤«¤òÄ´¤Ù¡¢¹ç¤¦¾ì¹ç¤Ï³ç¸Ì¤Ç³ç¤é¤ì¤¿¥Þ¥Ã¥Á¤ò
Í¿¤¨¤é¤ì¤¿Ê¸»úÎó¤ÇÃÖ¤­´¹¤¨¡¢¤½¤ì¤ò¥Õ¥¡¥¤¥ë̾¤È¤·¤Æ»ÈÍѤ·¤Þ¤¹¡£¤¿¤È¤¨¤Ð¡¢
<code>/icons</code> ¥Ç¥£¥ì¥¯¥È¥ê¤ò»È¤¦
¤¿¤á¤Ë¤Ï°Ê²¼¤Î¤è¤¦¤Ê¤â¤Î¤¬»ÈÍѤǤ­¤Þ¤¹:</p>
<div class="example"><p><code>
AliasMatch ^/icons(.*) /usr/local/apache/icons$1
</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="Redirect" id="Redirect">Redirect</a> <a name="redirect" id="redirect">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">ÀâÌÀ:</a></th><td>¥¯¥é¥¤¥¢¥ó¥È¤¬°ã¤¦ URL ¤ò¼èÆÀ¤¹¤ë¤è¤¦¤Ë³°Éô¤Ø¤Î¥ê¥À¥¤¥ì¥¯¥È¤ò
Á÷¤ë</td></tr>
<tr><th><a href="directive-dict.html#Syntax">¹½Ê¸:</a></th><td><code>Redirect [<var>status</var>] <var>URL-path</var>
<var>URL</var></code></td></tr>
<tr><th><a href="directive-dict.html#Context">¥³¥ó¥Æ¥­¥¹¥È:</a></th><td>¥µ¡¼¥ÐÀßÄê¥Õ¥¡¥¤¥ë, ¥Ð¡¼¥Á¥ã¥ë¥Û¥¹¥È, ¥Ç¥£¥ì¥¯¥È¥ê, .htaccess</td></tr>
<tr><th><a href="directive-dict.html#Override">¾å½ñ¤­:</a></th><td>FileInfo</td></tr>
<tr><th><a href="directive-dict.html#Status">¥¹¥Æ¡¼¥¿¥¹:</a></th><td>Base</td></tr>
<tr><th><a href="directive-dict.html#Module">¥â¥¸¥å¡¼¥ë:</a></th><td>mod_alias</td></tr>
</table>
<p>Redirect ¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï¸Å¤¤ URL ¤ò¿·¤·¤¤¤â¤Î¤Ø¥Þ¥Ã¥×¤·¤Þ¤¹¡£
¿·¤·¤¤ URL ¤¬¥¯¥é¥¤¥¢¥ó¥È¤ËÊÖ¤µ¤ì¤Þ¤¹¡£¤½¤·¤Æ¡¢
¥¯¥é¥¤¥¢¥ó¥È¤Ï¿·¤·¤¤¥¢¥É¥ì¥¹¤ò¤â¤¦°ì²ó¼èÆÀ¤·¤è¤¦¤È¤·¤Þ¤¹¡£
<var>URL-path</var> (% ¤¬Éü¹æ¤µ¤ì¤¿) ¥Ñ¥¹¤Ç»Ï¤Þ¤ë¥É¥­¥å¥á¥ó¥È¤Ø¤Î
¤¹¤Ù¤Æ¤Î¥ê¥¯¥¨¥¹¥È¤Ï <var>URL</var> ¤Ç»Ï¤Þ¤ë¿·¤·¤¤
(% ¤¬Éä¹æ²½¤µ¤ì¤¿) URL ¤Ø¤Î¥ê¥À¥¤¥ì¥¯¥È¥¨¥é¡¼¤¬ÊÖ¤µ¤ì¤Þ¤¹¡£</p>
<div class="example"><h3>Îã</h3><p><code>
Redirect /service http://foo2.bar.com/service
</code></p></div>
<p>¥¯¥é¥¤¥¢¥ó¥È¤Ï http://myserver/service/foo.txt
¤Ø¤Î¥ê¥¯¥¨¥¹¥È¤ò¹Ô¤Ê¤¦¤È¡¢Âå¤ï¤ê¤Ë http://foo2.bar.com/service/foo.txt
¤ò¥¢¥¯¥»¥¹¤¹¤ë¤è¤¦¤Ë¹ð¤²¤é¤ì¤Þ¤¹¡£</p>
<div class="note"><h3>Ãí°Õ</h3><p>ÀßÄê¥Õ¥¡¥¤¥ëÃæ¤Î½çÈ֤˴ؤï¤é¤º¡¢
Redirect ·Ï¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï Alias
¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤È ScriptAlias ¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤è¤ê¤âÍ¥À褵¤ì¤Þ¤¹¡£
¤Þ¤¿¡¢.htaccess ¥Õ¥¡¥¤¥ë¤ä <code class="directive"><a href="../mod/core.html#directory">&lt;Directory&gt;</a></code>
¥»¥¯¥·¥ç¥ó¤ÎÃæ¤Ç»È¤ï¤ì¤Æ¤¤¤¿¤È¤·¤Æ¤â¡¢<var>URL-path</var>
¤ÏÁêÂХѥ¹¤Ç¤Ï¤Ê¤¯¡¢´°Á´¤Ê URL ¤Ç¤Ê¤±¤ì¤Ð¤Ê¤ê¤Þ¤»¤ó¡£</p></div>
<p>¤â¤· <var>status</var> °ú¿ô¤¬Í¿¤¨¤é¤ì¤Æ¤¤¤Ê¤±¤ì¤Ð¡¢¥ê¥À¥¤¥ì¥¯¥È¤Ï
"temporary" (HTTP ¥¹¥Æ¡¼¥¿¥¹ 302) ¤Ë¤Ê¤ê¤Þ¤¹¡£¤³¤ì¤Ï¥¯¥é¥¤¥¢¥ó¥È¤Ë
¥ê¥½¡¼¥¹¤¬°ì»þŪ¤Ë°ÜÆ°¤·¤¿¤È¤¤¤¦¤³¤È¤ò¼¨¤·¤Þ¤¹¡£<var>Status</var>
°ú¿ô¤Ï ¾¤Î HTTP ¤Î¥¹¥Æ¡¼¥¿¥¹¥³¡¼¥É¤òÊÖ¤¹¤¿¤á¤Ë»ÈÍѤ¹¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹:</p>
<dl>
<dt>permanent</dt>
<dd>±Êµ×¤Ë¥ê¥À¥¤¥ì¥¯¥È¤ò¤¹¤ë¥¹¥Æ¡¼¥¿¥¹ (301) ¤òÊÖ¤·¤Þ¤¹¡£
¤³¤ì¤Ï¥ê¥½¡¼¥¹¤¬±Êµ×¤Ë°ÜÆ°¤·¤¿¤È¤¤¤¦¤³¤È¤ò°ÕÌ£¤·¤Þ¤¹¡£</dd>
<dt>temp</dt>
<dd>°ì»þŪ¤Ê¥ê¥À¥¤¥ì¥¯¥È¥¹¥Æ¡¼¥¿¥¹ (302)
¤òÊÖ¤·¤Þ¤¹¡£¤³¤ì¤¬¥Ç¥Õ¥©¥ë¥È¤Ç¤¹¡£</dd>
<dt>seeother</dt>
<dd>"See Other" ¥¹¥Æ¡¼¥¿¥¹ (303) ¤òÊÖ¤·¤Þ¤¹¡£
¤³¤ì¤Ï¥ê¥½¡¼¥¹¤¬Â¾¤Î¤â¤Î¤ÇÃÖ¤­´¹¤¨¤é¤ì¤¿¤³¤È¤ò°ÕÌ£¤·¤Þ¤¹¡£</dd>
<dt>gone</dt>
<dd>"Gone" ¥¹¥Æ¡¼¥¿¥¹ (410) ¤òÊÖ¤·¤Þ¤¹¡£¤³¤ì¤Ï¥ê¥½¡¼¥¹¤¬±Êµ×¤Ë
ºï½ü¤µ¤ì¤¿¤³¤È¤ò°ÕÌ£¤·¤Þ¤¹¡£¤³¤Î¥¹¥Æ¡¼¥¿¥¹¤¬»ÈÍѤµ¤ì¤¿¾ì¹ç¡¢
<var>url</var> °ú¿ô¤Ï¾Êά¤µ¤ì¤Ê¤±¤ì¤Ð¤Ê¤ê¤Þ¤»¤ó¡£</dd>
</dl>
<p><var>Status</var> ¤ÎÃͤ˥¹¥Æ¡¼¥¿¥¹¥³¡¼¥É¤ò¿ôÃͤÇÍ¿¤¨¤ë¤³¤È¤Ç
¾¤Î¥¹¥Æ¡¼¥¿¥¹¥³¡¼¥É¤âÊÖ¤¹¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£¥¹¥Æ¡¼¥¿¥¹¤¬ 300 ¤È 399
¤Î´Ö¤Ë¤¢¤ë¾ì¹ç¡¢<var>url</var> °ú¿ô¤Ï¸ºß¤·¤Æ¤¤¤Ê¤±¤ì¤Ð¤¤¤±¤Þ¤»¤ó¡£
¤½¤Î¾¤Î¾ì¹ç¤Ï¾Êά¤µ¤ì¤Æ¤¤¤Ê¤±¤ì¤Ð¤Ê¤ê¤Þ¤»¤ó¡£¤¿¤À¤·¡¢
¥¹¥Æ¡¼¥¿¥¹¤Ï Apache ¤Î¥³¡¼¥É¤¬ÃΤäƤ¤¤ë¤â¤Î¤Ç¤¢¤ëɬÍפ¬¤¢¤ê¤Þ¤¹
(http_protocol.c ¤Î´Ø¿ô <code>send_error_response</code>
¤ò¸«¤Æ¤¯¤À¤µ¤¤)¡£</p>
<p>Îã:</p>
<div class="example"><h3>Îã</h3><p><code>
Redirect permanent /one http://example.com/two<br />
Redirect 303 /three http://example.com/other
</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="RedirectMatch" id="RedirectMatch">RedirectMatch</a> <a name="redirectmatch" id="redirectmatch">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">ÀâÌÀ:</a></th><td>¸½ºß¤Î URL ¤Ø¤ÎÀµµ¬É½¸½¤Î¥Þ¥Ã¥Á¤Ë¤è¤ê
³°Éô¤Ø¤Î¥ê¥À¥¤¥ì¥¯¥È¤òÁ÷¤ë</td></tr>
<tr><th><a href="directive-dict.html#Syntax">¹½Ê¸:</a></th><td><code>RedirectMatch [<var>status</var>] <var>regex</var>
<var>URL</var></code></td></tr>
<tr><th><a href="directive-dict.html#Context">¥³¥ó¥Æ¥­¥¹¥È:</a></th><td>¥µ¡¼¥ÐÀßÄê¥Õ¥¡¥¤¥ë, ¥Ð¡¼¥Á¥ã¥ë¥Û¥¹¥È, ¥Ç¥£¥ì¥¯¥È¥ê, .htaccess</td></tr>
<tr><th><a href="directive-dict.html#Override">¾å½ñ¤­:</a></th><td>FileInfo</td></tr>
<tr><th><a href="directive-dict.html#Status">¥¹¥Æ¡¼¥¿¥¹:</a></th><td>Base</td></tr>
<tr><th><a href="directive-dict.html#Module">¥â¥¸¥å¡¼¥ë:</a></th><td>mod_alias</td></tr>
</table>
<p>¤³¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï <code class="directive"><a href="#redirect">Redirect</a></code>
¤È¤Û¤È¤ó¤ÉƱ¤¸¤Ç¤¹¤¬¡¢´Êñ¤ÊÀèƬ¤«¤é¤Î¥Þ¥Ã¥Á¤ò¹Ô¤Ê¤¦¤Î¤Ç¤Ï¤Ê¤¯¡¢
ɸ½àÀµµ¬É½¸½¤òÍøÍѤ·¤Þ¤¹¡£¤³¤³¤Ç»ØÄꤵ¤ì¤¿Àµµ¬É½¸½¤È URL-path
¤¬¹ç¤¦¤«¤É¤¦¤«¤òÄ´¤Ù¡¢¹ç¤¦¾ì¹ç¤Ï³ç¸Ì¤Ç³ç¤é¤ì¤¿¥Þ¥Ã¥Á¤ò
Í¿¤¨¤é¤ì¤¿Ê¸»úÎó¤ÇÃÖ¤­´¹¤¨¡¢¤½¤ì¤ò¥Õ¥¡¥¤¥ë̾¤È¤·¤Æ»ÈÍѤ·¤Þ¤¹¡£
¤¿¤È¤¨¤Ð¡¢¤¹¤Ù¤Æ¤Î GIF ¥Õ¥¡¥¤¥ë¤òÊÌ¥µ¡¼¥Ð¤ÎƱÍͤÊ̾Á°¤Î JPEG
¥Õ¥¡¥¤¥ë¤Ë¥ê¥À¥¤¥ì¥¯¥È¤¹¤ë¤Ë¤Ï¡¢°Ê²¼¤Î¤è¤¦¤Ê¤â¤Î¤ò»È¤¤¤Þ¤¹:
</p>
<div class="example"><p><code>
RedirectMatch (.*)\.gif$ http://www.anotherserver.com$1.jpg
</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="RedirectPermanent" id="RedirectPermanent">RedirectPermanent</a> <a name="redirectpermanent" id="redirectpermanent">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">ÀâÌÀ:</a></th><td>¥¯¥é¥¤¥¢¥ó¥È¤¬°ã¤¦ URL ¤ò¼èÆÀ¤¹¤ë¤è¤¦¤Ë³°Éô¤Ø¤Î±Êµ×Ū¤Ê
¥ê¥À¥¤¥ì¥¯¥È¤òÁ÷¤ë</td></tr>
<tr><th><a href="directive-dict.html#Syntax">¹½Ê¸:</a></th><td><code>RedirectPermanent <var>URL-path</var> <var>URL</var></code></td></tr>
<tr><th><a href="directive-dict.html#Context">¥³¥ó¥Æ¥­¥¹¥È:</a></th><td>¥µ¡¼¥ÐÀßÄê¥Õ¥¡¥¤¥ë, ¥Ð¡¼¥Á¥ã¥ë¥Û¥¹¥È, ¥Ç¥£¥ì¥¯¥È¥ê, .htaccess</td></tr>
<tr><th><a href="directive-dict.html#Override">¾å½ñ¤­:</a></th><td>FileInfo</td></tr>
<tr><th><a href="directive-dict.html#Status">¥¹¥Æ¡¼¥¿¥¹:</a></th><td>Base</td></tr>
<tr><th><a href="directive-dict.html#Module">¥â¥¸¥å¡¼¥ë:</a></th><td>mod_alias</td></tr>
</table>
<p>¤³¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï¥¯¥é¥¤¥¢¥ó¥È¤Ë Redirect ¤¬±Êµ×Ū¤Ê¤â¤Î
(¥¹¥Æ¡¼¥¿¥¹ 301) ¤Ç¤¢¤ë¤³¤È¤òÃΤ餻¤Þ¤¹¡£
<code>Redirect premanent</code> ¤È¤Þ¤Ã¤¿¤¯Æ±¤¸¤Ç¤¹¡£</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="RedirectTemp" id="RedirectTemp">RedirectTemp</a> <a name="redirecttemp" id="redirecttemp">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">ÀâÌÀ:</a></th><td>¥¯¥é¥¤¥¢¥ó¥È¤¬°ã¤¦ URL ¤ò¼èÆÀ¤¹¤ë¤è¤¦¤Ë³°Éô¤Ø¤Î°ì»þŪ¤Ê
¥ê¥À¥¤¥ì¥¯¥È¤òÁ÷¤ë</td></tr>
<tr><th><a href="directive-dict.html#Syntax">¹½Ê¸:</a></th><td><code>RedirectTemp <var>URL-path</var> <var>URL</var></code></td></tr>
<tr><th><a href="directive-dict.html#Context">¥³¥ó¥Æ¥­¥¹¥È:</a></th><td>¥µ¡¼¥ÐÀßÄê¥Õ¥¡¥¤¥ë, ¥Ð¡¼¥Á¥ã¥ë¥Û¥¹¥È, ¥Ç¥£¥ì¥¯¥È¥ê, .htaccess</td></tr>
<tr><th><a href="directive-dict.html#Override">¾å½ñ¤­:</a></th><td>FileInfo</td></tr>
<tr><th><a href="directive-dict.html#Status">¥¹¥Æ¡¼¥¿¥¹:</a></th><td>Base</td></tr>
<tr><th><a href="directive-dict.html#Module">¥â¥¸¥å¡¼¥ë:</a></th><td>mod_alias</td></tr>
</table>
<p>¤³¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï¥¯¥é¥¤¥¢¥ó¥È¤Ë Redirect
¤¬°ì»þŪ¤Ê¤â¤Î¤Ç¤¢¤ë (¥¹¥Æ¡¼¥¿¥¹ 302) ¤³¤È¤òÃΤ餻¤Þ¤¹¡£
<code>Redirect temp</code> ¤È¤Þ¤Ã¤¿¤¯Æ±¤¸¤Ç¤¹¡£</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="ScriptAlias" id="ScriptAlias">ScriptAlias</a> <a name="scriptalias" id="scriptalias">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">ÀâÌÀ:</a></th><td>URL ¤ò¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¤Î°ÌÃ֤إޥåפ·¡¢¥Þ¥Ã¥×Àè¤ò
CGI ¥¹¥¯¥ê¥×¥È¤Ë»ØÄê</td></tr>
<tr><th><a href="directive-dict.html#Syntax">¹½Ê¸:</a></th><td><code>ScriptAlias <var>URL-path</var>
<var>file-path</var>|<var>directory-path</var></code></td></tr>
<tr><th><a href="directive-dict.html#Context">¥³¥ó¥Æ¥­¥¹¥È:</a></th><td>¥µ¡¼¥ÐÀßÄê¥Õ¥¡¥¤¥ë, ¥Ð¡¼¥Á¥ã¥ë¥Û¥¹¥È</td></tr>
<tr><th><a href="directive-dict.html#Status">¥¹¥Æ¡¼¥¿¥¹:</a></th><td>Base</td></tr>
<tr><th><a href="directive-dict.html#Module">¥â¥¸¥å¡¼¥ë:</a></th><td>mod_alias</td></tr>
</table>
<p><code class="directive">ScriptAlias</code> ¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï¡¢Âоݥǥ£¥ì¥¯¥È¥ê¤Ë
<code class="module"><a href="../mod/mod_cgi.html">mod_cgi</a></code> ¤Î cgi-script
¥Ï¥ó¥É¥é¤Ç½èÍý¤µ¤ì¤ë CGI
¥¹¥¯¥ê¥×¥È¤¬¤¢¤ë¤³¤È¤ò¼¨¤¹°Ê³°¤Ï
<code class="directive"><a href="#alias">Alias</a></code>
¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤ÈƱ¤¸¿¶¤ëÉñ¤¤¤ò¤·¤Þ¤¹¡£
URL ¤Î (% ¤¬Éü¹æ¤µ¤ì¤¿) ¥Ñ¥¹¤¬ <var>URL-path</var> ¤Ç»Ï¤Þ¤ë¤â¤Î¤Ï
¥í¡¼¥«¥ë¤Î¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¤Î
¥Õ¥ë¥Ñ¥¹¤Ç¤¢¤ëÆóÈÖÌܤΰú¿ô¤Ë¥Þ¥Ã¥×¤µ¤ì¤Þ¤¹¡£</p>
<div class="example"><h3>Îã</h3><p><code>
ScriptAlias /cgi-bin/ /web/cgi-bin/
</code></p></div>
<p><code>http://myserver/cgi-bin/foo</code>
¤Ø¤Î¥ê¥¯¥¨¥¹¥È¤ËÂФ·¤Æ¥µ¡¼¥Ð¤Ï¥¹¥¯¥ê¥×¥È
<code>/web/cgi-bin/foo</code> ¤ò¼Â¹Ô¤·¤Þ¤¹¡£</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="ScriptAliasMatch" id="ScriptAliasMatch">ScriptAliasMatch</a> <a name="scriptaliasmatch" id="scriptaliasmatch">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">ÀâÌÀ:</a></th><td>URL ¤òÀµµ¬É½¸½¤ò»È¤Ã¤Æ¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¤Î°ÌÃ֤إޥåפ·¡¢¥Þ¥Ã¥×Àè¤ò
CGI ¥¹¥¯¥ê¥×¥È¤Ë»ØÄê</td></tr>
<tr><th><a href="directive-dict.html#Syntax">¹½Ê¸:</a></th><td><code>ScriptAliasMatch <var>regex</var>
<var>file-path</var>|<var>directory-path</var></code></td></tr>
<tr><th><a href="directive-dict.html#Context">¥³¥ó¥Æ¥­¥¹¥È:</a></th><td>¥µ¡¼¥ÐÀßÄê¥Õ¥¡¥¤¥ë, ¥Ð¡¼¥Á¥ã¥ë¥Û¥¹¥È</td></tr>
<tr><th><a href="directive-dict.html#Status">¥¹¥Æ¡¼¥¿¥¹:</a></th><td>Base</td></tr>
<tr><th><a href="directive-dict.html#Module">¥â¥¸¥å¡¼¥ë:</a></th><td>mod_alias</td></tr>
</table>
<p>¤³¤Î¥Ç¥£¥ì¥¯¥Æ¥£¥Ö¤Ï <code class="directive"><a href="#scriptalias">ScriptAlias</a></code>
¤È¤Û¤È¤ó¤ÉƱ¤¸¤Ç¤¹¤¬¡¢´Êñ¤ÊÀèƬ¤«¤é¤Î¥Þ¥Ã¥Á¤ò¹Ô¤Ê¤¦¤Î¤Ç¤Ï¤Ê¤¯¡¢
ɸ½àÀµµ¬É½¸½¤òÍøÍѤ·¤Þ¤¹¡£¤³¤³¤Ç»ØÄꤵ¤ì¤¿Àµµ¬É½¸½¤È URL-path
¤¬¹ç¤¦¤«¤É¤¦¤«¤òÄ´¤Ù¡¢¹ç¤¦¾ì¹ç¤Ï³ç¸Ì¤Ç³ç¤é¤ì¤¿¥Þ¥Ã¥Á¤ò
Í¿¤¨¤é¤ì¤¿Ê¸»úÎó¤ÇÃÖ¤­´¹¤¨¡¢¤½¤ì¤ò¥Õ¥¡¥¤¥ë̾¤È¤·¤Æ»ÈÍѤ·¤Þ¤¹¡£
¤¿¤È¤¨¤Ð¡¢É¸½à¤Î <code>/cgi-bin</code>
¤ò»ÈÍѤ¹¤ë¤è¤¦¤Ë¤¹¤ë¤¿¤á¤Ë¤Ï¡¢°Ê²¼¤Î¤è¤¦¤Ê¤â¤Î¤ò»È¤¤¤Þ¤¹:
</p>
<div class="example"><p><code>
ScriptAliasMatch ^/cgi-bin(.*) /usr/local/apache/cgi-bin$1
</code></p></div>
</div>
</div>
<div class="bottomlang">
<p><span>Available Languages: </span><a href="../en/mod/mod_alias.html" hreflang="en" rel="alternate" title="English">&nbsp;en&nbsp;</a> |
<a href="../ja/mod/mod_alias.html" title="Japanese">&nbsp;ja&nbsp;</a> |
<a href="../ko/mod/mod_alias.html" hreflang="ko" rel="alternate" title="Korean">&nbsp;ko&nbsp;</a></p>
</div><div id="footer">
<p class="apache">Copyright 1999-2004 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p>
<p class="menu"><a href="../mod/">¥â¥¸¥å¡¼¥ë</a> | <a href="../mod/directives.html">¥Ç¥£¥ì¥¯¥Æ¥£¥Ö</a> | <a href="../faq/">FAQ</a> | <a href="../glossary.html">ÍѸì</a> | <a href="../sitemap.html">¥µ¥¤¥È¥Þ¥Ã¥×</a></p></div>
</body></html>