473,385 Members | 1,830 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,385 software developers and data experts.

How to Destroy Session,

malav123
217 100+
Hi,
suppose User is login and if he closes window witout logout so in such situation i want to destoy the session of particular user as well as also wants to change the status in database.... I tried many things but i still don't get the desired solution.... so please give me solution for such Problem....
thanks in advance....
Mar 20 '08 #1
1 1012
Plater
7,872 Expert 4TB
Sessions timeout (expire) after 20mins (default time) of inactivity.
You can set that timer to lower if need be.

You could also implement an "ajax" type solution that sends a "heartbeat" request back to the server as long as your user is on one of your pages.
Mar 20 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Bob Bedford | last post by:
I've this code I've included in ALL my pages: session_cache_limiter('private, must-revalidate'); if(!session_is_registered("ID")){ if(!session_id()) session_start(); $UserID = 0; if...
0
by: Tuckbros | last post by:
Hi everybody, I am making a small site. This site uses sessions and I need to store pictures for each session. I solved this problem thanks to the session_set_save_handler() function. Sessions...
3
by: Derek Fountain | last post by:
The documentation says session_destroy() "destroys all of the data associated with the current session". Um, like what? The docs further say that you should remove all information in the _SESSION...
16
by: LP | last post by:
Hello, I am trying to use .NET with Excel. I installed Office 2003 and selected ..NET programming suport option, so it installed all those PIA, as MS sugests. But I can not find a way to destroy...
1
by: Shun | last post by:
Hello How to destroy an session thanks Shun
3
by: Amar | last post by:
Hi all, I want to use a cookie that will destroy after closing the browser, in my application. I am able to destroy my cookie after log out,but don't know how to destroy this when I will ...
5
by: Steve D | last post by:
I am not sure where to post this as it probably a combination of client and server script I am looking for. Basically I am trying to find out how to destroy a PHP session when the user navigates...
5
by: bnashenas1984 | last post by:
Hi I'm using IIS on windows XP SP2 just for designing my website. Everything is working fine except session_destroy. When I destroy the session with php nothing happends and session is still...
3
by: T. Wintershoven | last post by:
Hi all, After a visitor has loged in, a session is started. The session is destroyed after the visitor clicked "Log out'. When the visitor forgets to log out and closes the browser...
1
by: kummu4help | last post by:
Hi, i am posting data from a.php to b.php; a.php is something like this <html> <head> <body> <form method="post" action="b.php"> </form> </body>
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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...

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.