473,402 Members | 2,050 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,402 software developers and data experts.

idle session

Hi,

usually session expires in 20 minutes, well mine is and I want to redirect the user to an error page telling them that their session has expired and they need to login again. How do I code that and where should I put it? Thanks.

-----------------------------
This message is posted by http://Asp.ForumsZone.com

Jul 19 '05 #1
2 2046
You can't do that using ASP, since ASP runs on the server, and once a page
is sent to the client, the server doesn't know anything about it anymore.

Instead, you can create a client-side refresh, eg using a javascript
timer -or- a meta refresh tag, that redirects the user after 20 minutes, eg:

<head>
<meta http-equiv="refresh" content="1200;URL=/loginpage.asp" />
</head.

Cheers
Ken
"Iona" <io**********@hotmail.com> wrote in message
news:49*************@Asp.ForumsZone.com...
: Hi,
:
: usually session expires in 20 minutes, well mine is and I want to redirect
the user to an error page telling them that their session has expired and
they need to login again. How do I code that and where should I put it?
Thanks.
:
: -----------------------------
: This message is posted by http://Asp.ForumsZone.com
:
Jul 19 '05 #2
AHN
On some former page of your application start some session variable and at
the top of the page, in server side code, check if the value you had set is
still there. If the session is over, the variable will be empty, so your
server will know the sesion is over and redirect the client if so. Cheers.

"Iona" <io**********@hotmail.com> wrote in message
news:49*************@Asp.ForumsZone.com...
Hi,

usually session expires in 20 minutes, well mine is and I want to redirect the user to an error page telling them that their session has expired and
they need to login again. How do I code that and where should I put it?
Thanks.
-----------------------------
This message is posted by http://Asp.ForumsZone.com

Jul 19 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Will Seay | last post by:
At the end of this message I've pasted a script we're trying to modify slightly. I don't believe it is VBscript or javascript but these are the closest groups I could find with my limited...
1
by: Moosebumps | last post by:
So say I am working on two separate .py files in IDLE that are part of the same program. Does anyone have problems where when you modify one file, and then run the other, the changes you made in...
0
by: Brian van den Broek | last post by:
Hi all, IDLE refuses to launch, and I believe it is because I attempted to define a custom key-binding that it doesn't like. I was recently defining a custom keybinding in IDLE 1.1 under...
0
by: Romeo | last post by:
Hello, I would like to know how i can detect if a user is online, in idle time or lock session. I know how to do this in C++ but i don't know in C#. In C++, for idle you can use...
6
by: MrBlueSky | last post by:
Hi, I'm trying to use IDLE to develop My First Python App and my head hurts... I've a file called spalvi.py with this in it: from Test import * firstTest("Mike") And a file called Test.py...
2
by: jcmendez | last post by:
Hello everyone. Trying to run idle from a cygwin session on Win2k (yuk, but I must) I'm getting the following error message. It seems something more Windoze-driven that Python driven, and I'm...
20
by: Ilias Lazaridis | last post by:
IDLE has an output format like this: <type 'object'> <type 'type'> <type 'type'> How can I customize it to become like that: <type 'object'> <type 'type'>
5
by: Smokey Grindle | last post by:
is there any way to get how long a session has been idle? thanks!
1
by: reinierjose | last post by:
how to logoff user if his session expired? if a users is idle for 15 minutes, the user will be force to logoff from the system. the system must check for keylogs and mouse activity so that the user...
1
by: Debabrata Jana | last post by:
Hi, I am using Oracle 10g as a database server. I have two schema suppose s1 and s2. Suppose, I login to the s1 schema and as well as s2 schema. These two connection is active in two...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.