Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Clearing a DB after all users log out

Status
Not open for further replies.

SteelDragon

Programmer
Feb 1, 2001
134
US
I have a CF chat site that users log in and out of, my problem is two parts, 1) How can I write something in to the logout page so that when the LAST user logs out the database that holds their chat is cleared? and 2) How can I set it up or can I so that when their text scrolls beyond the visble area it is removed from the database? Any suggestions would be greatly appreciated!!!!

SteelDragon
 
1. I take it you are tracking when they input data by username or id in a session variable. But this right before you clear their session on the logout page.
<Cfouput query etc.>
delete
from table
where username = #session.username# or #session.id#>

2. Not sure, would have to see the site.


CFPROGRAMMER
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top