-----------------------------
Please read the FAQ!
<http://java.apache.org/faq/>
-----------------------------


If you want a way to just pass your pages through then you should either send a 
redirect or just return a generated page.

e.g. before writing anything to the output stream call:
res.sendRedirect("my error page location");

If you just want to include some unformatted text with your response you can send:

res.sendError(res.SC_FORBIDDEN, "some text"); //this should get logged by the server
or
res.setStatus(res.SC_FORBIDDEN, "some text"); // shouldn't get logged by the server.


You can also call either of those without the message text. Either way your user will 
see whatever the server wants to give as an
error page. (Which, I believe, is configurable on most servers.)

HTH

***********************************************************
Brett Knights                             626-432-5767 work
[EMAIL PROTECTED]                 626-355-1017 home
***********************************************************

>
> I am deciding whether to send a 200 OK message ( as per
> normal ) or a 403 Forbidden response, and not using Apache
> <Location> rules at all.
>
> My problem is only that the page I generate for my 403 is not
> returned by Apache.  In fact if I set the response code to
> 200 OK Apache replaces my page.
>
> ErrorDocument allows four ways to specify which error page to
> return, text, locally generated from cgi, local page and
> remote page.  As I generate responses from any of a number of
> servlets none of these seem appropriate.  I need a way to
> just pass my pages through.
>
>       Thanks again,
>               Gary




--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://java.apache.org/main/mail.html>
Problems?:           [EMAIL PROTECTED]

Reply via email to