View Full Version : Vbuletin 3.8.x Global Variables not found
s_cocis
01-14-2012, 11:28 AM
Hi
in style "whosonlinebit" I would like to insert the date of registration "joindata" (in the new column ) in addition to
$userinfo[aimicon]
$userinfo[icqicon]
$userinfo[msnicon]
$userinfo[yahooicon]
$userinfo[skypeicon]
that are already present.
The variable $userinfo[joindata] does not work and does not work even the variable $globals[joindata].
can you help me ?
THZ
Sandro
Try this: create a new plugin using hook location online_query and this code:
$hook_query_fields .= " , FROM_UNIXTIME(user.joindate, '%M %D, %Y') as join_date ";
Then use {vb:raw userinfo.join_date} $userinfo[join_date] in the template.
s_cocis
01-15-2012, 07:10 AM
Try this: create a new plugin using hook location online_query and this code:
$hook_query_fields .= " , FROM_UNIXTIME(user.joindate, '%M %D, %Y') as join_date ";
Then use {vb:raw userinfo.join_date} in the template.
with VB3 ?
with VB3 ?
Oops - sorry. I fixed it.
Also I should have mentioned, you can format the date however you want by changing the '%M %D, %Y' string. Here's the mysql doc page for the FROM_UNIXTIME() function: http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html#function_from-unixtime
...and a page that shows the tokens available for the format string: http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html#function_date-format
s_cocis
01-15-2012, 03:00 PM
Oops - sorry. I fixed it.
Also I should have mentioned, you can format the date however you want by changing the '%M %D, %Y' string. Here's the mysql doc page for the FROM_UNIXTIME() function: http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html#function_from-unixtime
...and a page that shows the tokens available for the format string: http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html#function_date-format
THANK YOU VERY MUCH ! :D
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.