I am getting an error with this hack.
I have found that putting this hack in global.php rather than index.php I am getting more members using the Chat Room as they can see more easily who is in the chat room. Many of them only visit the index page once and then don't see it again until they log-out.
However, if I install the code into the global.php file then when someone is in the chat room the Who's Online Page doesn't work nor do a lot of the user profiles. THe pages instead return this error.
If you have any thoughts as to what might be causing this it would be appreciated.
Code:
Database error in vBulletin 3.0.5:
Invalid SQL:
SELECT userid, username, IF(displaygroupid=0, user.usergroupid, displaygroupid) AS displaygroupid
FROM user AS user
WHERE userid IN (0Array)
mysql error: Unknown column '0Array' in 'where clause'
mysql error number: 1054