Can you not use  response.sendRedirect("index.jsp")??

If you can manage to get the handle for the HttpServletResponse object??

or else, you can include this code in JSP page to get the handle to it.

I am not sure I got your problem correct.

Regards,
Sripada


Ron Quartel wrote:

> I have created the following session listener class which works but now I
> want to redirect the client to the start page of the application (index.jsp)
> if they are trying to enter the application from another page.
>
> Easy peasy lemon squeezey in asp using global.asa but at a loss with java.
>
> Any help greatly appreciated.
>
> Code shown below.
>
> Ron Quartel.
>
> import java.util.*;
> import javax.servlet.*;
> import javax.servlet.http.*;
>
> public class SessionListener implements HttpSessionListener{
>
>     public SessionListener() {
>     }
>
>     public void sessionCreated(HttpSessionEvent hse) {
>         System.out.println("Session started");
>         //redirect to start page if not alread there i.e index.jsp.
>     }
>
>     public void sessionDestroyed(HttpSessionEvent hse) {}
>
> }
>
> ===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
> For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.html
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to