Hi,

<jsp:forward .../> in JSP

and

response.sendRedirect(loaction) in servlets

Amit
> -----Original Message-----
> From: Amornkul, Woody [SMTP:[EMAIL PROTECTED]]
> Sent: Friday, January 07, 2000 4:55 AM
> To:   [EMAIL PROTECTED]
> Subject:      HELP: How to redirect to a file?
>
> Hi,
>         With CGI, I can redirect the browser to a new file by the
> following
> two lines:
>
>                 printf("HTTP/1.0 302 Found\n");
>                 printf("Location: <path/filename>\n");
>
>         The save box will appear to allow me to save the file.
>
>         Can this be done with Java Servlet?
>         I tried the following codes but it displays the content to the
> broswer instead.
>
>                 res.setStatus(res.SC_MOVED_TEMPORARILY);
>                 res.setHeader("Location", site);
>
> Thank you in advance,
> Woody
>
> ==========================================================================
> =
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> JSP-INTEREST".
> FAQs on JSP can be found at:
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.html

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html

Reply via email to