diff options
author | Michael Newton <miken32@gmail.com> | 2013-02-14 21:14:38 -0800 |
---|---|---|
committer | Michael Newton <miken32@gmail.com> | 2013-02-14 21:14:38 -0800 |
commit | 91ca7e9fa01bec4e6c9e83674cb109806a67df51 (patch) | |
tree | 42c12f1b96fef68dacd2561e13917140a1023376 /usr/local/www/status_captiveportal.php | |
parent | 2ccc41c1c537994e10c9deb4ac061ce55edb6537 (diff) | |
download | pfsense-91ca7e9fa01bec4e6c9e83674cb109806a67df51.zip pfsense-91ca7e9fa01bec4e6c9e83674cb109806a67df51.tar.gz |
use associative array for captive portal to prevent confusion, messiness, and abuse
Diffstat (limited to 'usr/local/www/status_captiveportal.php')
-rwxr-xr-x | usr/local/www/status_captiveportal.php | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/usr/local/www/status_captiveportal.php b/usr/local/www/status_captiveportal.php index 2e303b6..370420c 100755 --- a/usr/local/www/status_captiveportal.php +++ b/usr/local/www/status_captiveportal.php @@ -156,16 +156,16 @@ if (!empty($cpzone)) { </tr> <?php foreach ($cpdb as $cpent): ?> <tr> - <td class="listlr"><?=$cpent[2];?></td> - <td class="listr"><?=$cpent[3];?> </td> - <td class="listr"><?=$cpent[4];?> </td> - <td class="listr"><?=htmlspecialchars(date("m/d/Y H:i:s", $cpent[0]));?></td> + <td class="listlr"><?=$cpent['ip'];?></td> + <td class="listr"><?=$cpent['mac'];?> </td> + <td class="listr"><?=$cpent['username'];?> </td> + <td class="listr"><?=htmlspecialchars(date("m/d/Y H:i:s", $cpent['allow_time']));?></td> <?php if ($_GET['showact']): - $last_act = captiveportal_get_last_activity($cpent[2]); ?> + $last_act = captiveportal_get_last_activity($cpent['ip']); ?> <td class="listr"><?php if ($last_act != 0) echo htmlspecialchars(date("m/d/Y H:i:s", $last_act));?></td> <?php endif; ?> <td valign="middle" class="list" nowrap> - <a href="?zone=<?=$cpzone;?>&order=<?=$_GET['order'];?>&showact=<?=htmlspecialchars($_GET['showact']);?>&act=del&id=<?=$cpent[5];?>" onclick="return confirm('<?=gettext("Do you really want to disconnect this client?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" title="<?=gettext("Disconnect");?>"></a></td> + <a href="?zone=<?=$cpzone;?>&order=<?=$_GET['order'];?>&showact=<?=htmlspecialchars($_GET['showact']);?>&act=del&id=<?=$cpent['sessionid'];?>" onclick="return confirm('<?=gettext("Do you really want to disconnect this client?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" title="<?=gettext("Disconnect");?>"></a></td> </tr> <?php endforeach; endif; ?> </table> |