473,662 Members | 2,536 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

session related issue

Hi Friends.
in my application i am facing problems in maintaining session state. I
am working on asp.net 2.0.
So i didnt checked the session on each page and almost the project is
completed. Now problem is like after 20 minutes the session gets
ended.so session related errors are coming when any operation like
insert or update is performed after that 20 minutes. how can i
redirect that page to login page after session timeout.I hav to write
code on each page or is there any other method to solve my problem...
(Though i can increase the session timeout period but i dont want
that). Waiting for ur reply.
thanks
Priyabrata

Mar 7 '07 #1
2 1185
Since the Session ends on the server side, the client can do a redirect as
long as it knows the length of the Session. One method is to use JavaScript
on the client, using the setTimeout() JavaScript method to wait for 21
minutes (or just after the length of the Session) to fire a method that
sends the browser to the login page.

--
HTH,

Kevin Spencer
Microsoft MVP

Help test our new betas,
DSI PrintManager, Miradyne Component Libraries:
http://www.miradyne.net

"pintu" <pr************ **@gmail.comwro te in message
news:11******** **************@ t69g2000cwt.goo glegroups.com.. .
Hi Friends.
in my application i am facing problems in maintaining session state. I
am working on asp.net 2.0.
So i didnt checked the session on each page and almost the project is
completed. Now problem is like after 20 minutes the session gets
ended.so session related errors are coming when any operation like
insert or update is performed after that 20 minutes. how can i
redirect that page to login page after session timeout.I hav to write
code on each page or is there any other method to solve my problem...
(Though i can increase the session timeout period but i dont want
that). Waiting for ur reply.
thanks
Priyabrata

Mar 7 '07 #2
You can set up a Javascript bit to force the person to the login at that
time you estimate the timeout has occurred, although timeout is server side
and you cannot truly tell. If you do this, make sure you abandon session in
case you arrived early.

I do this in the master page, so it is on every form and programatically
avoid doing it on the login page.

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

*************** *************** ***************
Think outside the box!
*************** *************** ***************
"pintu" <pr************ **@gmail.comwro te in message
news:11******** **************@ t69g2000cwt.goo glegroups.com.. .
Hi Friends.
in my application i am facing problems in maintaining session state. I
am working on asp.net 2.0.
So i didnt checked the session on each page and almost the project is
completed. Now problem is like after 20 minutes the session gets
ended.so session related errors are coming when any operation like
insert or update is performed after that 20 minutes. how can i
redirect that page to login page after session timeout.I hav to write
code on each page or is there any other method to solve my problem...
(Though i can increase the session timeout period but i dont want
that). Waiting for ur reply.
thanks
Priyabrata
Mar 7 '07 #3

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

Similar topics

27
7111
by: mrbog | last post by:
Tell me if my assertion is wrong here: The only way to prevent session hijacking is to NEVER store authentication information (such as name/password) in the session. Well, to never authenticate a user from information you got from the session. Each secure app on a site must challenge the user for name and password, each and every time the user accesses it (not just once and then store it in the session). If a secure app is multi-page,...
13
2348
by: jamie howard | last post by:
Hello there - we have a fairly busy server and we just started to have problems with PHP sessions failing. We've never had this problem before and to be honist, out server traffic is lower than it has been in prior months - so I'm really not sure what could cause this. Could anyone suggest some potentiol avenues to explore for reasons that could cause PHP sessions to fail? Thanks for any suggestions!
1
2139
by: tamer.yousef | last post by:
We are working on an old asp project and we noticed that some users get kicked out of the session right after they log in. I investigated the issue and I found the cause: 1- The user login successfuly. 2- He gets redirected to the menu screen. that's when I set some cookies to cookie("cookie name").expires = Now. that when the session starts to disapear, once the user tries to access other pages (or even refresh), the ASPSESSIONID...
5
5276
by: fbwhite | last post by:
I know this issue has been brought up many times, but I have tried many of the solutions to no avail. I wanted to give my specific case to see if someone could be of any help. We are using the sessionstate inproc mode and users are randomly losing their session. I do not believe it is happening across all users at one time. It seems to happen to different users at different times, but I am only going off heresay. The aspnet worker...
11
7905
by: Joseph Geretz | last post by:
I've been looking at two approaches for the maintenance of Session state for a Web Service application. One approach uses the old familiar Session object which I've used in the past for Web applications. As far as I can see, the Session approach is non-standard since Web Services are supposed to be agnostic with respect to their clients. It seems that cookies are outside the Web Service standard; therefore, such a Web Service application...
43
3412
by: davidkoree | last post by:
I mean not about cookie. Does it have something to do with operating system or browser plugin? I appreciate any help.
13
8659
by: Samir Chouaieb | last post by:
Hello, I am trying to find a solution to a login mechanism for different domains on different servers with PHP5. I have one main domain with the user data and several other domains that need a login to show data. I want the user to login only once when he visits any of my domains.
9
7793
by: Josh | last post by:
I run a Joomla website and am familiar with php in some but not all aspects. Currently I am trying to find some solutions related to session handling. Am I correct in saying that "login" is kept in sessions? I can see active sessions in my mysql database, but is that the only place this information is stored? Sessions and cookies I know are related also, but how specifically (session info stored in cookies?)? Right now, when users...
3
2789
by: sandeepsandeep | last post by:
Hi, I am facing one problem related to session out. In my PHP page I am using PHP session and from that page I am opening one popup. Pop up PHP code also uses Session variable. I am able to get session variable at first time. But after closing the window my php session is getting terminated. Is this related to PHP code or any configuration issue? Because the same code is running on one server without any issue and on other server it is...
0
8432
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8764
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8633
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
5654
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4180
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4347
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2762
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1993
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1752
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.