Forum

ErrorDocument

Thorsten
8 April 2013, 01:52
Hiawatha is some great Software - but i have a little (noob-like) question.
How do i define custom errorpages in a .hiawatha file?

Btw: is there a complete documetation for using .hiawatha-files?

Hiawatha version: Hiawatha v8.2
Operating System: Windows 7 x86
Hugo Leisink
8 April 2013, 07:38
Via the ErrorHandler option. The manual page has all the information you need.
Thorsten
18 April 2013, 17:53
You are kidding me, right?
There isn't much information.
How should it look like?
Hugo Leisink
18 April 2013, 18:09
No, I'm not kidding. There is even an example in the manual page...
Shamus
25 April 2013, 01:14
Yes, but is doesn't explain it at all. For example, how would I specify a specific html file for it to use? What if I wanted it to link to http://www.thebest404pageever.com/ on 404 errors?
Hugo Leisink
25 April 2013, 09:22
First, after seeing the 404 website you mentioned, nobody ever wants to do that.

The ErrorHandler, as explained in the manual page, only allows you to specify a file in disk. If you want to redirect to another website, try this UrlToolkit rule:
UrlToolkit {
ToolkitID = 404page
RequestURI exists Return
Match .* Redirect http://www.thebest404pageever.com/
}
This topic has been closed.