View Full Version : Date/time for user log doesn't work
Anyone has the user logs working? In the user management section I receive a 7 or 8 digit number of login hours and idle time even though I just (fresh-) installed ver 2.
When checking the database for users all times and data are set to zero, e.g. 0000-00-00.
I think it is a bug, you can see the same problem on demo site at http://www.dotproject.net/demo/
Yes, that's what it looks like (I didn't have access to my system when posting this one). Sessions are stored in the database in the user section but all dates are set to 0000-00-00 and 00:00.
I didn't find the time and will to have a deeper look at the code at this time.
Let's hope it'll be fixed soon.
It seems like there are some problems with now() function insert and upate into datetime column when the value of this function is converted to string. I've done a little hack of quote function inside of the classes/query.class.php file to avoid converting datetime stamp to the string. This is just a temp solution and not the best way to fix this problem, but it works for now :)
if (strcasecmp($string, "now()") == 0)
return $db->qstr($string, get_magic_quotes_runtime());
Hope this helps.
I saw this problem and I solved it this way:
On classes/ui.class.php change line 689 to:
$q->addInsert('date_time_in', date('Y-m-d H:i:s'));
line 702 to:
$q->addUpdate('date_time_out', date('Y-m-d H:i:s'));
line 715 to:
$q->addUpdate('date_time_last_action', date('Y-m-d H:i:s'));
These will get things recorded properly.
Now to show the log correctly, change file modules/admin/vw_usr_log.php line 90 to 92 should be:
With the grey theme I can't see the header because of the STYLE="background: #08245b", it's to dark but you can see it on the default theme. Guess I gonna change that to #cccccc (gray).
Hope you like it,
vBulletin® v3.6.4, Copyright ©2000-2013, Jelsoft Enterprises Ltd.