| | |
response.sendRedirect()
Please support our JSP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
Thread Solved |
•
•
Join Date: Jul 2009
Posts: 93
Reputation:
Solved Threads: 1
Hi,
I would like to know if it's possible to specify the "target='FrameName'" in response.sendRedirect("Home.jsp") by any chance?
I tried this:
But it doesn't work... The target remains the same.
Thanks,
-Ashton.
I would like to know if it's possible to specify the "target='FrameName'" in response.sendRedirect("Home.jsp") by any chance?
I tried this:
JSP Syntax (Toggle Plain Text)
<!-- Security Check --> <form action="Login" target="_top"> <% if ((String) request.getSession(false).getAttribute("sessionStatus") == null) { response.sendRedirect("Login?pageTimeout=yes"); } %> </form> <!-- Security Check -->
But it doesn't work... The target remains the same.
Thanks,
-Ashton.
•
•
Join Date: Jul 2009
Posts: 93
Reputation:
Solved Threads: 1
0
#3 Oct 31st, 2009
Hi,
I found an easy script to do this:
Place that script in your <head></head> tags, then call it like this:
Thanks,
-Ashton.
I found an easy script to do this:
JSP Syntax (Toggle Plain Text)
<script type="text/javascript"> function breakout() { <% if ((String) request.getSession(false).getAttribute("sessionStatus") == null) { %> if (window.top != window.self) { window.top.location="Login" } <% } %> } </script>
Place that script in your <head></head> tags, then call it like this:
JSP Syntax (Toggle Plain Text)
<body onload="javascript:breakout();">
Thanks,
-Ashton.
![]() |
Other Threads in the JSP Forum
- Previous Thread: help me with the following JSP code
- Next Thread: how can i run jsp
Views: 831 | Replies: 2
| Thread Tools | Search this Thread |
Tag cloud for frames, jsp, redirect, response, sessions
.htaccess 301 adware ajax apache array asp.net c# combobox connection cookies database destroy dropdownlist duplicate explorer frames frameworks gc_maxlifetime glassfish google htaccess integer internet java javaee javascript jsf jsp links malware mvc2 mvcmodel2 mysql netbeans network parameters passing persist php ping project python question redirect redirecting request.getparameter response runtime scriptlets servlet sessions sql ssl tomcat tutorial unset url urllib2 virus vista






