<?php require 'common.php'; try { $nntpClient = new \Web\News\Nntp(NNTP_HOST); $groups = $nntpClient->listGroups(); } catch (Exception $e) { error($e->getMessage()); } head(); ?> <table border="0" cellpadding="6" cellspacing="0"> <tr> <td> <table class="stripped"> <tr> <th>name</th> <th>messages</th> <th>rss</th> <th>rdf</th> </tr> <?php foreach ($groups as $group => $details) { echo " <tr>\n"; echo " <td><a class=\"active{$details['status']}\" href=\"/{$group}\">{$group}</a></td>\n"; echo " <td align=\"right\">", $details['high'] - $details['low'] + 1, "</td>\n"; echo " <td>"; if ($details['status'] != 'n') { echo "<a href=\"group.php?group={$group}&format=rss\">rss</a>"; } echo "</td>\n";