Fortunately the web server has no idea what is happening on the client side
with regards to layout etc.  I say "fortunately" because so many browsers
display content differently it would be almost impossible to make sure your
client-side code appeared the same on everyone's screen.  You need to use
something like JavaScript on the client page to manipulate the UI.  For
example:

<%      // code to check if user session has expired
        if(userExpired == true)
        {
%>
                <script language="JavaScript">
                        top.location.href = "login.jsp";
                </script>
<%
        }
%>

-----Original Message-----
From: Ronak Shah [mailto:[EMAIL PROTECTED]]
Sent: Thursday, September 09, 1999 8:04 AM
To: [EMAIL PROTECTED]
Subject: How to set target attribute when redirecting to another JSP


I want to know if there is a way to set HTML "TARGET" attribute (want to set
TARGET="_top") when I redirect to another JSP page.

I understand that this mechanism is not a standard UI practice. This is
needed when a user logs in and enters a framed version of HTML UI. A session
is created as part of logging in. All the user actions are updated on a
separate content pane. If the user does not perform any activity for
significant time (like more than 30 minutes for most web servers), the
session becomes invalid. At this point if the user performs an action on the
UI then corresponding JSP page detects that session is invalid and redirects
the user to Login page. This requires the page to be rendered in "_top"
frame.

Ronak

===========================================================================
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