asked on
ASKER
ASKER
ASKER
No its a server side script that is just a ASP if Statement. This is not a Java or VB script.
Thats why I want the <%If CALLJAVASCRIPT %> statement to call the Javascript to close the window.
ASKER
<%
If (Session("ETuserGood") = False or IsNull(Session("ETuserGood")) = True) and Request.ServerVariables("PATH_INFO") <> "/login.asp" then
URL=Request.ServerVariables("server_name")
Response.Redirect "http://"&URL&"/login.asp"
End If
If (Request.ServerVariables("PATH_INFO") = "/login.asp" and Session("ETuserGood") = True) Then
URL=Request.ServerVariables("server_name")
Response.Redirect "http://"&URL&"/index.asp"
End If
%>
ASKER
ASKER
ASKER
$('#expireMessage').countdown({until: shortly,
expiryText: '<div class="over">It\'s all over</div>'});
$('#expireMessageStart').click(function() {
shortly = new Date();
shortly.setSeconds(shortly.getSeconds() + 5.5);
$('#expireMessage').countdown('option', {until: shortly});
});
Instead of displaying text, just call a js or jquery function to close the self window. One of the problems as you know the session can time out for other reasons besides time so you are making an estimate. If you have your server session set for 15 minutes, I would set the js timer for a little less.
<script>
window.parent.AjaxfunctionToReloadPageWithTheLoginPage;
window.self.close
</script>
then this would probably keep the session alive..?I does. It is really the idle time out on the app pool that people forget about that is the cause of premature time outs. The ajax call would prevent that from happening. If you set the idle time out to 7 minutes and the ajax call is every 5 minutes, it will take a long time to time out.
ASKER
JavaScript is a dynamic, object-based language commonly used for client-side scripting in web browsers. Recently, server side JavaScript frameworks have also emerged. JavaScript runs on nearly every operating system and in almost every mainstream web browser.
TRUSTED BY
Somehow in your wording it is not completely clear?
Thank you.