Hitachi

Hitachi Application Server V10 Definition Reference Guide (For UNIX® Systems)


2.3.46 ErrorDocument

ErrorDocument customizes the message to be displayed on the web browser when an error occurs.

Description

ErrorDocument is specified to customize the message to be displayed on the web browser when an error occurs.

text

Specify the character string by enclosing it in "".

local_URL

Enter / at the beginning to specify the content of the local site.

full_URL

Enter the URL starting with http:// or https:// to specify the content of another site.

The error status number, text, local URL, full URL, and whether they can be specified for this directive, is shown below:

Error status number (meaning)

Text

Local URL

Full URL

400 (Bad Request)

Y

N

N

401 (Authorization Required)

Y

Y

N

403 (Forbidden)

Y

Y

Y

404 (Not Found)

Y

Y

Y

405 (Method Not Allowed)

Y

Y

Y

406 (Not Acceptable)

Y

Y

Y

408 (Request Time-out)

N

N

N

410 (Gone)

Y

Y

Y

411 (Length Required)

Y

N

N

412 (Precondition Failed)

Y

Y

Y

413 (Request Entity Too Large)

Y

Y

Y

414 (Request-URI Too Large)

Y

N

N

416 (Requested Range Not Satisfiable)

Y

Y

Y

417 (Expectation Failed)

Y

N

N

500 (Internal Server Error)

Y

Y

Y

501 (Method Not Implemented)

Y

Y

Y

502 (Bad Gateway)

Y

Y

N

503 (Service Temporarily Unavailable)

Y#

Y#

Y#

506 (Variant Also Negotiates)

Y

Y

Y

(Legend)

Y: Can be specified

N: Cannot be specified

#

To customize the message that was returned from the flow restriction functionality, use the QOSResponse directive or the QOSRedirect directive.

Be aware of the following points when using this directive:

Syntax

ErrorDocument error_status_number {text|local_URL|full_URL}

Locations where it can be written

httpsd.conf, <VirtualHost>, <Directory>, and .htaccess

Overwrite permission

FileInfo level

Example

ErrorDocument 500 "Server Error."
ErrorDocument 404 /missing.html
ErrorDocument 403 http://some.other_server.com/subscription_info.html
ErrorDocument 404 http://[2001::123:4567:89ab:cdef]/missing.html