count persons in the group

Agusanz

Active Member
Jul 18, 2015
239
148
88
You can do that like this:
Code:
foreach($ts3->clientList() as $client)
{
    $userCount = 0;
    $groupId = 6;
    foreach (explode(",", $client["client_servergroups"]) as $userGroup)
    {
        if($userGroup == $groupId)
        {
            $userCount = $userCount + 1;
        }
    }
}
 
Top