View Single Post
Old 04-28-2008, 09:33 AM   #11 (permalink)
Tanax
The Prestige
Upcoming Programmer Inquisitive 
 
Tanax's Avatar
 
Join Date: Sep 2007
Location: Sweden, Stockholm
Posts: 1,080
Thanks: 115
Tanax is on a distinguished road
Default

Quote:
Originally Posted by sarmenhb View Post
do this

add a new column to the userlogin table named ip
then

grab the users ip address who logs in and save it into the table.
then for every page visited if your using either cookies or sessions check to see if the userlogin that is being used matches the existing ip address in the database.

if the user decides to log out , still keep that ip address in the databse. when the user tries to re-login and his ip address is different than the one existing in the database, tell the user that they must change their password because they are logging in from a computer that wasnt used when the last user logged in.

so every time a user logs in and his ip doesnt match the one existing in the database they gotta change the password, this eventually gets on everyones last nerve and the users who dont have logins will eventually either quit or get their selves their own logins.

if you want the code on how to do all this, let me know i'll type it out.
But still, it's just one single user account in the database.
I want to record how many people are online on THAT SAME ACCOUNT at the SAME TIME.
__________________
Tanax is offline  
Reply With Quote