why not keep a application.object to store current user names/id's and the
time for the last page request... write a short script in application.cfm
that will ignore/purge inactive users, say after 30 minutes.  Simultaneous
logins will be avoided, and if users forget to log out before closing the
browser window, they only have to wait a half hour to get back in... if you
wanted to get really fancy, put a javascript in your pages that monitors
window.close and opens a logout.cfm script in a new window that closes
itself...

credit is due on the application idea - it's not my own - several tutorial
scripts exist that will let you do this.  I can't throw you any URLs but
they shouldn't be too hard to find...

neil

-----Original Message-----
From: Peter Alexandrou [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 18, 2000 1:56 AM
To: CF-Talk
Subject: Re: Preventing Simultaneous Logins


I can think of many similar solutions but they are all useless because most
of the time users simply close their browsers or their sessions expire.

Surely someone out there has tackled this problem successfully?

----- Original Message -----
From: "Pete Freitag" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Wednesday, October 18, 2000 2:15 PM
Subject: RE: Preventing Simultaneous Logins


> Keep a log of when people login, and when they log out (could get very
> large, but you could purge it daily).  Then when someone logs in do the
> following...
>
> SELECT username FROM audit_table
> WHERE
> username = '#form.username#' AND
> timestamp > #DateAdd("n", -30, Now())#
> ORDER BY action
>
> That will see if  the user has been around in the last half hour
>
> Action could be a boolean field 1 being login 0 being logout
> <cfif audit.recordcount>
> <cfif audit.action>
> already logged in <cfabort>
> </cfif>
> </cfif>
> login...
>
> The problem with this entire process, is that there is no destructor
called
> when a session disappears, or times out.
>
> ______________________________________________
> Pete Freitag ([EMAIL PROTECTED])
> CFDEV.COM / NETDesign Inc.
> ColdFusion Developer Resources
> http://www.cfdev.com/
>
> -----Original Message-----
> From: Peter Alexandrou [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, October 17, 2000 7:37 PM
> To: CF-Talk
> Subject: Preventing Simultaneous Logins
>
>
> Hi guys,
>
> I'm new to the mailing list and have a quick question for y'all.
>
> What is the best way to prevent a userID being logged in twice i.e.
someone
> logs in with "login1" and then another user logs in with the same ID.
>
> Thanks,
>
> Peter Alexandrou
> Technical Leader
>
> tapestry communications : www.tapestry.net.au
> phone : 0411 445 111
> e-mail : [EMAIL PROTECTED]
>
> --------------------------------------------------------------------------
--
> --------------------
> Archives: http://www.mail-archive.com/[email protected]/
> Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send
a
> message with 'unsubscribe' in the body to
[EMAIL PROTECTED]
>
> --------------------------------------------------------------------------
----------------------
> Archives: http://www.mail-archive.com/[email protected]/
> Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send
a message with 'unsubscribe' in the body to
[EMAIL PROTECTED]

----------------------------------------------------------------------------
--------------------
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send a
message with 'unsubscribe' in the body to [EMAIL PROTECTED]


_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com

------------------------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send a message 
with 'unsubscribe' in the body to [EMAIL PROTECTED]

Reply via email to