Solved

Login tracking...

Posted on 2001-08-14
6
192 Views
Last Modified: 2013-12-24
I have an application that tracks users, and only allows one user to use their logon at that time...

The question that I have is how do I track a users time spent logged in? I have the start time inserted into a table called http_refer and want to be able to pull information that pertains to the record where the Start time was inserted...

So the user that logged in at 10am (referer_ID=218) will be logged out at 10:30am with that same referer_ID...

The table info is connected to the http_referer table using the info.company_ID (Pk) and the http_referer.company_ID (Fk).

If anyone can understand what I am talking about AND can help me, that would be great...

Gordon
0
Comment
Question by:webmaster256
6 Comments
 
LVL 19

Expert Comment

by:cheekycj
ID: 6385018
0
 
LVL 19

Accepted Solution

by:
cheekycj earned 34 total points
ID: 6385037
Ignore my last comment...

Here is a decent way to track a user's time.

When the user logs in update a FirstLoggedIn timestamp.

Now everytime this user requests a new page update another field LastLoggedIn timestamp.  Now with every request this field will be updated but you should get a pretty acurate read on the time spent.

It is a hit on the DB though.. with all the updates.

CJ
0
 
LVL 1

Assisted Solution

by:snakehollywood
snakehollywood earned 33 total points
ID: 6402138
But then if you use client variables stored in a database, this is also a hit on every page. So you can kill 2 birds with one stone and read info from the clientstorage database to setermine how many people are logged in.
0
 

Assisted Solution

by:brettstil
brettstil earned 33 total points
ID: 6432849
You also need to be aware of the session timeout settings.  The CF default, I believe, is 20 minutes.  If a user clicks a logout button, then you know exactly when they logged out.  But if their session times out instead, you could either use the last page view time or the last page view time plus the session timeout as the "logout" time.
0
 
LVL 35

Expert Comment

by:mrichmon
ID: 10837368
No comment has been added lately, so it's time to clean up this question.
I will leave the following recommendation in the Cleanup topic area:

Split cheekycj & snakehollywood & brettstil

Please leave any comments here within the next four days.

mrichmon
EE Cleanup Volunteer
0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
remove Handler and Add Handler for one file 3 44
Website Test Question 6 114
IPA - can it be run on a web server? 3 175
AWS New EC2 Instance and EBS Storage 2 78
A web service (http://en.wikipedia.org/wiki/Web_service) is a software related technology that facilitates machine-to-machine interaction over a network. This article helps beginners in creating and consuming a web service using the ColdFusion Ma…
Introduction This article explores the design of a cache system that can improve the performance of a web site or web application.  The assumption is that the web site has many more “read” operations than “write” operations (this is commonly the ca…
In a recent question (https://www.experts-exchange.com/questions/28997919/Pagination-in-Adobe-Acrobat.html) here at Experts Exchange, a member asked how to add page numbers to a PDF file using Adobe Acrobat XI Pro. This short video Micro Tutorial sh…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question