app->db()->prepare("SELECT UserID,RegionID FROM Presence WHERE RegionID != '00000000-0000-0000-0000-000000000000' ORDER BY RegionID ASC"); $statement->execute(); $tpl = $this->app->template('online-display.php'); if ($statement->rowCount() == 0) { $tpl->unsafeVar('online-users', '

Es ist niemand online!

'); } else { $table = ''; $entryColor = true; $opensim = new OpenSim($this->app->db()); while ($row = $statement->fetch()) { $table = $table.''; $entryColor = !$entryColor; } $tpl->unsafeVar('online-users', $table.'
NameRegion
'.trim($opensim->getUserName($row['UserID'])).''.$opensim->getRegionName($row['RegionID']).'
'); } $tpl->render(); } }