Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

VBScript asp help

  • 25-07-2014 03:50PM
    #1
    Registered Users, Registered Users 2 Posts: 191 ✭✭


    hello Guys,

    I am making a website and coming accross issues.

    basically there is 4 pages, and to get to those login pages you must login through the login.asp page. This works fine.

    But for security reasons i want to put a session time out on it so it redirects to the login screen after eg 10 mins and user must login again

    Ive looked and looked so hopefully some1 can help.

    Sample code im using for the login is below.

    thank you



    [HTML]<%@ Language=VBScript %>
    <%
    if Request("password1")="mypassword1" then
    Session("loginokay") = True

    end if
    %>
    <% Session.Timeout=1

    if Session.Timeout=null then
    Session("loginokay") = False

    end if
    %>[/HTML]


Comments

  • Registered Users, Registered Users 2 Posts: 9,585 ✭✭✭DublinWriter


    Google Global.asax - you'll need to put the relevant code in the session timeout event.


Advertisement