@Paul M
PHP Code:
if ($vbulletin->options['wvt'])
{
$groups = explode(',',$vbulletin->options['wvtgrps']);
if (in_array($vbulletin->userinfo['usergroupid'],$groups) OR in_array(0,$groups))
{
$show['wvt'] = true;
}
else
{
$show['wvt']= false;
}
}
else
{
$show['wvt']= false;
}
This is the end of your Plugin code.
So you are checking if the display is enabled, and if the User is member of a usergroup that is allowed to view it.
Now, if it turns out that display is disabled or the user ist not allowed to view, you've already done the query and processing ...