Hi all,
Could anyone suggest to me a way of storing the time and date of when a user logs on in a mySQL database. Any suggestions are greatly appreciated.
Thank You, Gismo
If you're going to be using php to pull the info back out, I usually use [man]time[/man] to generate the timestamp, and store it in a bigint field.
$today = date(r); $sql = "INSERT INTO table SET login='$today'"; mysql_query($sql) or die(mysql_error());
http://us2.php.net/manual/en/function.date.php