summaryrefslogtreecommitdiffstats
path: root/usr/local/www
diff options
context:
space:
mode:
authorRenato Botelho <garga@FreeBSD.org>2014-05-29 11:29:55 -0300
committerRenato Botelho <garga@FreeBSD.org>2014-05-29 11:29:55 -0300
commitae73fcb1702b7b20ff127a32dac2b5d873288fbd (patch)
tree3745ceea2ebc6ffec6115151b8407583690dc353 /usr/local/www
parent36b9bb281e4f88b7b82f39b1717ade4783167bca (diff)
parent7786daaa9dbc3243e4e057ad0bfd1089ec19e8c6 (diff)
downloadpfsense-ae73fcb1702b7b20ff127a32dac2b5d873288fbd.zip
pfsense-ae73fcb1702b7b20ff127a32dac2b5d873288fbd.tar.gz
Merge pull request #1220 from ExolonDX/branch_master_01
Diffstat (limited to 'usr/local/www')
-rw-r--r--usr/local/www/diag_tables.php39
1 files changed, 22 insertions, 17 deletions
diff --git a/usr/local/www/diag_tables.php b/usr/local/www/diag_tables.php
index d9c8f84..e181c80 100644
--- a/usr/local/www/diag_tables.php
+++ b/usr/local/www/diag_tables.php
@@ -91,14 +91,15 @@ exec("/sbin/pfctl -t " . escapeshellarg($tablename) . " -T show", $entries);
exec("/sbin/pfctl -sT", $tables);
include("head.inc");
-include("fbegin.inc");
-
?>
+<body>
+<?php include("fbegin.inc"); ?>
<?php if ($savemsg) print_info_box($savemsg); ?>
-<form method='post'>
+<form method="post" action="diag_tables.php">
<script type="text/javascript">
+//<![CDATA[
function method_change(entrytype) {
window.location='diag_tables.php?type=' + entrytype;
}
@@ -114,58 +115,62 @@ include("fbegin.inc");
}
});
}
+//]]>
</script>
<?=gettext("Table:");?>
-<select id='type' onChange='method_change(jQuery("#type").val());' name='type'>
+<select id="type" onchange="method_change(jQuery('#type').val());" name="type">
<?php foreach ($tables as $table) {
- echo "<option name='{$table}' value='{$table}'";
+ echo "<option value=\"{$table}\"";
if ($tablename == $table)
- echo " selected ";
+ echo " selected=\"selected\"";
echo ">{$table}</option>\n";
}
?>
</select>
-<p/>
+<br/><br/>
-<table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0">
+<table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0" summary="tables">
<tr>
<td class="listhdrr"><?=gettext("IP Address");?></td>
</tr>
<?php $count = 0; foreach($entries as $entryA): ?>
<?php $entry = trim($entryA); ?>
- <tr id='<?=$entry?>'>
+ <tr id="<?=$entry?>">
<td>
<?php echo $entry; ?>
</td>
<td>
<?php if ( ($tablename != "bogons") && ($tablename != "bogonsv6") ) { ?>
- <a onClick='del_entry("<?=htmlspecialchars($entry)?>");'>
- <img img src="/themes/<?=$g['theme'];?>/images/icons/icon_x.gif">
- <?php } ?>
+ <a onclick="del_entry('<?=htmlspecialchars($entry)?>');">
+ <img src="/themes/<?=$g['theme'];?>/images/icons/icon_x.gif" alt="delete" />
</a>
+ <?php } ?>
</td>
</tr>
<?php $count++; endforeach; ?>
<?php
if($count == 0)
if( ($tablename == "bogons") || ($tablename == "bogonsv6") )
- echo "<p/>" . gettext("No entries exist in this table.") . "&nbsp&nbsp" . "<input name='Download' type='submit' class='formbtn' value='" . gettext("Download") . "'> " . gettext(" the latest bogon data.");
+ echo "<tr><td>" . gettext("No entries exist in this table.") . "&nbsp;&nbsp;" . "<input name=\"Download\" type=\"submit\" class=\"formbtn\" value=\"" . gettext("Download") . "\" /> " . gettext(" the latest bogon data.");
else
- echo "<p/>" . gettext("No entries exist in this table.");
+ echo "<tr><td>" . gettext("No entries exist in this table.");
?>
<?php
if($count > 0)
if( ($tablename == "bogons") || ($tablename == "bogonsv6") ) {
$last_updated = exec('/usr/bin/grep -i -m 1 -E "^# last updated" /etc/' . escapeshellarg($tablename));
- echo "<p/>&nbsp<b>$count</b> " . gettext("entries in this table.") . "&nbsp&nbsp" . "<input name='Download' type='submit' class='formbtn' value='" . gettext("Download") . "'> " . gettext(" the latest bogon data.") . "<br />" . "$last_updated";
+ echo "<tr><td>&nbsp;<b>$count</b> " . gettext("entries in this table.") . "&nbsp;&nbsp;" . "<input name=\"Download\" type=\"submit\" class=\"formbtn\" value=\"" . gettext("Download") . "\" /> " . gettext(" the latest bogon data.") . "<br />" . "$last_updated";
}
else
- echo "<p/>" . gettext("Delete") . " <a href='diag_tables.php?deleteall=true&type=" . htmlspecialchars($tablename) . "'>" . gettext("all") . "</a> " . "<b>$count</b> " . gettext("entries in this table.");
+ echo "<tr><td>" . gettext("Delete") . " <a href=\"diag_tables.php?deleteall=true&amp;type=" . htmlspecialchars($tablename) . "\">" . gettext("all") . "</a> " . "<b>$count</b> " . gettext("entries in this table.");
?>
-
+</td></tr>
</table>
+</form>
<?php include("fend.inc"); ?>
+</body>
+</html>
OpenPOWER on IntegriCloud