custom-error.xml.ja revision 7db9f691a00ead175b03335457ca296a33ddf31b
<?xml version="1.0" encoding="iso-2022-jp"?>
<!DOCTYPE manualpage SYSTEM "/style/manualpage.dtd">
<?xml-stylesheet type="text/xsl" href="/style/manual.ja.xsl"?>
<!-- English revision: 1.1 -->
<manualpage metafile="custom-error.xml.meta">
<relativepath href="."/>
<title>$B%+%9%?%`%(%i!<%l%9%]%s%9(B</title>
<summary>
<p>$B%&%'%V%^%9%?!<$,2?$i$+$N%(%i!<$dLdBj$KBP$9$k(B
Apache $B$NH?1~$r@_Dj$G$-$k$h$&$K$9$kDI2C5!G=$rDs6!$7$^$9!#(B</p>
<p>$B%5!<%P$,%(%i!<$dLdBj$rH/8+$7$?>l9g$NH?1~$r!"(B
$B%+%9%?%^%$%:$7$FDj5A$9$k$3$H$,$G$-$^$9!#(B</p>
<p>$B%9%/%j%W%H$N<B9T$,<:GT$7$F(B "500 Server Error"
$B$rH/@8$5$;$?$H$7$^$9!#$3$N>l9g$NH?1~$r!"$h$j9%$^$7$$%F%-%9%H$d!"JL$N(B
URL ($BFbIt5Z$S30It(B) $B$X$N%j%@%$%l%/%7%g%s$KCV$-49$($k$3$H$,$G$-$^$9!#(B
</p>
</summary>
<section id="behavior">
<title>$BF0:n(B</title>
<section>
<title>$B8E$$F0:n(B</title>
<p>NCSA httpd 1.3 $B$O!"8E$/$FB`6~$J%(%i!<(B/$BLdBj%a%C%;!<%8$r(B
$BJV$7$F$$$^$7$?!#$=$l$O$7$P$7$P%f!<%6$K$OL50UL#$G$"$j!"(B
$B$^$?$=$l$rH/@8$5$;$?860x$r5-O?$9$kJ}K!$bDs6!$7$F$$$^$;$s$G$7$?!#(B</p>
</section>
<section>
<title>$B?7$7$$F0:n(B</title>
<ol>
<li>NCSA $B$N%O!<%I%3!<%I$5$l$?%a%C%;!<%8$NBe$o$j$K(B
$BB>$N%F%-%9%H$rI=<((B</li>
<li>$B%m!<%+%k$N(B URL $B$K%j%@%$%l%/%H(B</li>
<li>$B30It$N(B URL $B$K%j%@%$%l%/%H(B</li>
</ol>
<p>$B$9$k$h$&$K%5!<%P$r@_Dj$G$-$^$9!#(B</p>
<p>$BJL$N(B URL $B$K%j%@%$%l%/%H$9$k$3$H$OLr$KN)$A$^$9$,!"(B
$B$=$l$O@bL@$r$7$?$j!"$h$jL@3N$K8m$j(B/$BLdBj$r5-O?$7$?$j$9$k$?$a$K(B
$B2?$+>pJs$rEA$($i$l$k$H$-$K8B$j$^$9!#(B</p>
<p>$B$3$l$r<B8=$9$k$?$a$K!"(B Apache $B$O?7$7$/(B CGI $B$N$h$&$J4D6-JQ?t$r(B
$BDj5A$7$^$9(B:</p>
<example>
REDIRECT_HTTP_ACCEPT=*/*, image/gif,
image/x-xbitmap, image/jpeg<br />
REDIRECT_HTTP_USER_AGENT=Mozilla/1.1b2 (X11; I; HP-UX
A.09.05 9000/712)<br />
REDIRECT_PATH=.:/bin:/usr/local/bin:/etc<br />
REDIRECT_QUERY_STRING=<br />
REDIRECT_REMOTE_ADDR=121.345.78.123<br />
REDIRECT_REMOTE_HOST=ooh.ahhh.com<br />
REDIRECT_SERVER_NAME=crash.bang.edu<br />
REDIRECT_SERVER_PORT=80<br />
REDIRECT_SERVER_SOFTWARE=Apache/0.8.15<br />
REDIRECT_URL=/cgi-bin/buggy.pl
</example>
<p>$BF,$KIU$/(B <code>REDIRECT_</code> $B$KCmL\$7$F$/$@$5$$!#(B</p>
<p>$B>/$J$/$H$b(B <code>REDIRECT_URL</code> $B$H(B
<code>REDIRECT_QUERY_STRING</code> $B$O?7$7$$(B URL (CGI $B%9%/%j%W%H$+(B
CGI $B%$%s%/%k!<%I$G$"$k$H2>Dj$5$l$^$9(B) $B$KEO$5$l$^$9!#(B
$BB>$NJQ?t$O!"%(%i!<$dLdBj$,5/$-$kA0$KB8:_$7$?>l9g$K$@$1B8:_$7$^$9!#(B
$B$b$7$"$J$?$N@_Dj$7$?(B <directive
module="core">ErrorDocument</directive> $B$,(B <em>$B30It(B</em>$B%j%@%$%l%/%H(B
(<em>$B$9$J$o$A(B</em>$B!"(B<code>http:</code>
$B$N$h$&$JBN7OL>$+$i;O$^$k$9$Y$F$N$b$N!#$?$H$(F1$8%[%9%H$r;X$7$F$$$F$b(B)
$B$J$i$P!"$3$l$i$O(B<strong>$B$^$C$?$/(B</strong>$B@_Dj$5$l$^$;$s!#(B</p>
</section>
</section>
<section id="configuration">
<title>$B@_Dj(B</title>
<p><directive module="core">AllowOverride</directive> $B$,E,@Z$K@_Dj$5$l$F$$$l$P!"(B
.htaccess $B%U%!%$%k$G(B <directive module="core">ErrorDocument</directive>
$B$r;HMQ$9$k$3$H$,$G$-$^$9!#(B</p>
<p>$B$3$3$K!"$$$/$D$+$NNc$r5s$2$^$9!#(B</p>
<example>
ErrorDocument 500 /cgi-bin/crash-recover <br />
ErrorDocument 500 "Sorry, our script crashed. Oh dear" <br />
ErrorDocument 500 http://xxx/ <br />
ErrorDocument 404 /Lame_excuses/not_found.html <br />
ErrorDocument 401 /Subscription/how_to_subscribe.html
</example>
<p>$B9=J8(B</p>
<example>
ErrorDocument &lt;3-digit-code&gt; &lt;action&gt;
</example>
<p>action ($BF0:n(B) $B$O!"(B</p>
<ol>
<li>$BI=<($5$l$k$Y$-%F%-%9%H!#%F%-%9%H$K$O0zMQId(B (") $B$r$D$1$^$9!#(B
$B0zMQId$N8e$KB3$/$b$N$,2?$G$bI=<($5$l$^$9!#(B
<em>$BCm0U(B : (") $B$OI=<($5$l$^$;$s(B</em></li>
<li>$B%j%@%$%l%/%H@h$N30It(B URL </li>
<li>$B%j%@%$%l%/%H@h$N%m!<%+%k(B URL </li>
</ol>
</section>
<section id="custom">
<title>$B%+%9%?%`%(%i!<%l%9%]%s%9$H%j%@%$%l%/%H(B</title>
<p>$B%9%/%j%W%H(B/SSI $B$KDI2C$N4D6-JQ?t$,MxMQ2DG=$K$J$k$h$&$K!"(B
$B%j%@%$%l%/%H$5$l$?(B URL $B$KBP$9$k(B Apache $B$NF0:n$,JQ99$5$l$^$7$?!#(B</p>
<section>
<title>$B8E$$F0:n(B</title>
<p>$B%j%@%$%l%/%H$5$l$?%9%/%j%W%H$OI8=`$N(B CGI
$B4D6-JQ?t$rMxMQ2DG=$G$7$?!#$7$+$7!"$I$3$+$i%j%@%$%l%/%H(B
$B$5$l$?$+$N>pJs$ODs6!$5$l$F$$$^$;$s$G$7$?!#(B</p>
</section>
<section>
<title>$B?7$7$$F0:n(B</title>
<p>$B%j%@%$%l%/%H$5$l$?@h$N%9%/%j%W%H$,;HMQ2DG=$J$h$&$K!"(B
$B?7$7$$$?$/$5$s$N4D6-JQ?t$,=i4|2=$5$l$^$9!#?7$7$$JQ?t$O!"$=$l$>$l(B
<code>REDIRECT_</code> $B$G;O$^$j$^$9!#(B
<code>REDIRECT_</code> $B$G;O$^$k4D6-JQ?t$O%j%@%$%l%/%H$5$l$kA0$KB8:_$7$F$$$?(B
CGI $B4D6-JQ?t$NF,$K(B <code>REDIRECT_</code> $B$rIU$1$F:n@.$5$l$^$9!#(B
<em>$B$9$J$o$A(B</em>$B!"(B<code>HTTP_USER_AGENT</code> $B$O(B
<code>REDIRECT_HTTP_USER_AGENT</code> $B$K$J$j$^$9!#(B
$B$3$l$i$N?7$7$$JQ?t$K2C$($F!"(BApache $B$O!"(B
$B%9%/%j%W%H$,%j%@%$%l%/%H85$N%H%l!<%9$r=u$1$k$?$a$K(B
<code>REDIRECT_URL</code> $B$H(B <code>REDIRECT_STATUS</code>
$B$rDj5A$7$^$9!#%"%/%;%9%m%0$K$O85$N(B URL $B$H%j%@%$%l%/%H$5$l$?(B URL
$B$NN>J}$,5-O?$5$l$^$9!#(B</p>
<p>ErrorDocument $B$,(B CGI $B%9%/%j%W%H$X$N%m!<%+%k%j%@%$%l%/%H$r(B
$B;XDj$7$F$$$k>l9g$O!"$=$l$r5/F0$9$k$3$H$K$J$C$?%(%i!<$N>uBV$r(B
$B%/%i%$%"%s%H$^$G3N<B$KEA$($k$?$a$K(B <code>"Status:" </code>
$B%X%C%@$r4^$`$Y$-$G$9!#Nc$($P!"(BErrorDocument $BMQ$N(B Perl
$B%9%/%j%W%H$O0J2<$N$h$&$J$b$N$r4^$`$+$b$7$l$^$;$s!#(B
</p>
<example>
... <br />
print "Content-type: text/html\n"; <br />
printf "Status: %s Condition Intercepted\n", $ENV{"REDIRECT_STATUS"}; <br />
...
</example>
<p>$B%9%/%j%W%H$,(B <code>404 Not Found</code> $B$N$h$&$J(B
$BFCDj$N%(%i!<%3%s%G%#%7%g%s$r07$&$?$a$@$1$K;H$o$l$k>l9g$O!"(B
$BBe$o$j$KFCDj$N%3!<%I$H%(%i!<%F%-%9%H$r;HMQ$9$k$3$H$,$G$-$^$9!#(B</p>
</section>
</section>
</manualpage>