Forum Moderators: phranque

Message Too Old, No Replies

ErrorDocument 503 based on server name (language specific 503 page)

         

chitech

7:16 am on Jun 25, 2013 (gmt 0)

10+ Year Member



I want to show a maintenance page based on the servername so it show the right language. Is it possible to achieve something like this?


<VirtualHost>
ServerName xxx.com
ServerAlias xxx.nl
ServerAlias xxx.it

ProxyPass ...
ProxyPassReverse ...


if xxx.com
ErrorDocument 503 http://maintenance.com/com
if xxx.nl
ErrorDocument 503 http://maintenance.com/nl
if xxx.it
ErrorDocument 503 http://maintenance.com/it
else
ErrorDocument 503 http://maintenance.com/default

</VirtualHost>

g1smd

9:19 am on Jun 25, 2013 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



ErrorDocument 503 /error503.php

In the script, generate or "include" the correct information for the viewer based on the requested hostname.

NEVER specify protocol and hostname in the ErrorDocument directive. That will generate a 302 response, not the one you wanted.