I was hoping someone could clearly explain an easy way of logging the time of a user when they are s开发者_运维问答igned into my website. I want to be able to log this time and then display it for an administrator to view.
Thanks in advance,
Filipe
You could combine the users table with ci_sessions table to access the user_agent, ip_address and last_activity columns (last_activity is a timestamp, so use with from_unixtime(last_activity) to get even more info for the admin.
Tank_auth created user table should have a last_login column. You can query that to get the login times.
精彩评论