It means that the client should look for the requested page in the alternate
location (url) given in the response ONLY for this request, i.e. next
requests should be for the original URL.
>From the HTTP 1.1 spec:
10.3.8 307 Temporary Redirect
The requested resource resides temporarily under a different URI. Since the
redirection MAY be altered on occasion,
the client SHOULD continue to use the Request-URI for future requests. This
response is only cacheable if
indicated by a Cache-Control or Expires header field.
The temporary URI SHOULD be given by the Location field in the response.
Unless the request method was
HEAD, the entity of the response SHOULD contain a short hypertext note with
a hyperlink to the new URI(s) , since
many pre-HTTP/1.1 user agents do not understand the 307 status. Therefore,
the note SHOULD contain the
information necessary for a user to repeat the original request on the new
URI.
If the 307 status code is received in response to a request other than GET
or HEAD, the user agent MUST NOT
automatically redirect the request unless it can be confirmed by the user,
since this might change the conditions
under which the request was issued.
-----Original Message-----
From: Dario Novakovic [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 02, 2001 18:06
To: [EMAIL PROTECTED]
Subject: Re: redirect to a static page from tomcat to apache
why does it say in api docs that sendRedirect() "Sends a temporary redirect
response"? what is temporary in this case?
----- Original Message -----
From: "Boaz Shaham" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, 02 January, 2001 08:53
Subject: RE: redirect to a static page from tomcat to apache
> how about
>
> // response is HttpServletResponse
> response.sendRedirect("/foo/x.html");
>
>
>
> -----Original Message-----
> From: Randy Paries [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 02, 2001 02:25
> To: [EMAIL PROTECTED]
> Subject: redirect to a static page from tomcat to apache
>
>
> Hello,
>
> Is there anyway to do a forward from a servlet in tomcat to a static page
> that apache only knows.
> ie.
> apache knows that /foo is /home/foo.
>
> but when the servlet executes and does the following(see snippet below),
> Tomcat does not know where /foo is mapped to. If I set up a context in
> server.xml it will work. But then for my app it gets more complicated ,
> because x.html is a frame that calls two cgi programs. And of course
tomcat
> doesn't know about these guys.
>
> So what are my options?
>
> IS there way to set up a cgi-bin directory under tomcat?
>
> Thanks
>
> >From within a servlet.
> ---------------------------------------------------------------------
> String URL = "/foo/x.html";
> RequestDispatcher disp =
> getServletConfig().getServletContext().getRequestDispatcher(jspURL);
> disp.forward(req,res);
> ---------------------------------------------------------------------
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]