diff options
author | Renato Botelho <garga@FreeBSD.org> | 2013-02-17 11:34:44 -0300 |
---|---|---|
committer | Renato Botelho <garga@FreeBSD.org> | 2013-02-17 11:34:44 -0300 |
commit | 5705c60a24ce8a5887dda0f7c1a73231de42827e (patch) | |
tree | e03f1e22e4292db3ff8904fd043842259a05eb22 /usr/local/www/widgets/widgets/captive_portal_status.widget.php | |
parent | 290296cdc05747b65145077e2715e7c4e2ae60aa (diff) | |
download | pfsense-5705c60a24ce8a5887dda0f7c1a73231de42827e.zip pfsense-5705c60a24ce8a5887dda0f7c1a73231de42827e.tar.gz |
Revert "Merge pull request #417 from miken32/cp-database-fix"
It breaks customizations, it's not a good time for such big change.
This reverts commit 40c7b1a98bfdc61261154adaac5fdefc234ecb08, reversing
changes made to d896f86751bae79625197da6c80d709fdf185448.
Diffstat (limited to 'usr/local/www/widgets/widgets/captive_portal_status.widget.php')
-rw-r--r-- | usr/local/www/widgets/widgets/captive_portal_status.widget.php | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/usr/local/www/widgets/widgets/captive_portal_status.widget.php b/usr/local/www/widgets/widgets/captive_portal_status.widget.php index 1393fc0..2db0a2a 100644 --- a/usr/local/www/widgets/widgets/captive_portal_status.widget.php +++ b/usr/local/www/widgets/widgets/captive_portal_status.widget.php @@ -46,7 +46,7 @@ require_once("captiveportal.inc"); if (($_GET['act'] == "del") && (!empty($_GET['zone']))) { $cpzone = $_GET['zone']; - captiveportal_disconnect_client($_GET['id'], RADIUS_TERM_ADMIN_RESET); + captiveportal_disconnect_client($_GET['id']); } flush(); @@ -65,9 +65,9 @@ $cpdb_all = array(); foreach ($a_cp as $cpzone => $cp) { $cpdb = captiveportal_read_db(); foreach ($cpdb as $cpent) { - $cpent['zone'] = $cpzone; + $cpent[10] = $cpzone; if ($_GET['showact']) - $cpent['lastactivity'] = captiveportal_get_last_activity($cpent['ip']); + $cpent[11] = captiveportal_get_last_activity($cpent[2]); $cpdb_all[] = $cpent; } } @@ -100,15 +100,15 @@ if ($_GET['order']) { </tr> <?php foreach ($cpdb_all as $cpent): ?> <tr> - <td class="listlr"><?=$cpent['ip'];?></td> - <td class="listr"><?=$cpent['mac'];?> </td> - <td class="listr"><?=$cpent['username'];?> </td> + <td class="listlr"><?=$cpent[2];?></td> + <td class="listr"><?=$cpent[3];?> </td> + <td class="listr"><?=$cpent[4];?> </td> <?php if ($_GET['showact']): ?> - <td class="listr"><?=htmlspecialchars(date("m/d/Y H:i:s", $cpent['allow_time']));?></td> - <td class="listr"><?php if ($cpent['lastactivity'] && ($cpent['lastactivity'] > 0)) echo htmlspecialchars(date("m/d/Y H:i:s", $cpent['lastactivity']));?></td> + <td class="listr"><?=htmlspecialchars(date("m/d/Y H:i:s", $cpent[0]));?></td> + <td class="listr"><?php if ($cpent[11] && ($cpent[11] > 0)) echo htmlspecialchars(date("m/d/Y H:i:s", $cpent[11]));?></td> <?php endif; ?> <td valign="middle" class="list" nowrap> - <a href="?order=<?=$_GET['order'];?>&showact=<?=$_GET['showact'];?>&act=del&zone=<?=$cpent['zone'];?>&id=<?=$cpent['sessionid'];?>" onclick="return confirm('Do you really want to disconnect this client?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td> + <a href="?order=<?=$_GET['order'];?>&showact=<?=$_GET['showact'];?>&act=del&zone=<?=$cpent[10];?>&id=<?=$cpent[5];?>" onclick="return confirm('Do you really want to disconnect this client?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td> </tr> <?php endforeach; ?> </table> |