[Zope] NotFound (404) and Unauthorized (401) error page redirects
Kamal Gill
gill@library.ucsf.edu
Mon, 2 Dec 2002 14:48:39 -0800
I need some advice on how to create an Unauthorized (401) error page
redirect.
I've discovered how to create a NotFound (404) error page redirect by
adding the following code to the top of the "standard_error_message"
DTML method, which is located in the root folder...
<dtml-if "error_type=='NotFound'">
<dtml-call expr="RESPONSE.redirect('/notfound.html', lock=1)">
</dtml-if>
However, when I replace 'NotFound' with 'Unauthorized' (--please DO NOT
try this on your production Zope server--), anyone who tries to log
into the Zope management interface (ZopeServer/manage) is redirected to
the unauthorized page.
Basically, I need to know the Zope analog of Apache's "ErrorDocument
401 /unauthorized.html" directive.
Many thanks.
- Kamal