summaryrefslogtreecommitdiffstats
path: root/usr/local/www/diag_logs.php
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2006-10-07 01:39:48 +0000
committerScott Ullrich <sullrich@pfsense.org>2006-10-07 01:39:48 +0000
commit0541e3028973d93b8337429f9266bfdd9ce74353 (patch)
tree82966e8cf48196605c6b917941445e77ef21225e /usr/local/www/diag_logs.php
parentfa626e70d014bf172f2aa541c6844432be830b0b (diff)
downloadpfsense-0541e3028973d93b8337429f9266bfdd9ce74353.zip
pfsense-0541e3028973d93b8337429f9266bfdd9ce74353.tar.gz
Add filtering capabilities to system log so that operators can identify information quicker.
Diffstat (limited to 'usr/local/www/diag_logs.php')
-rwxr-xr-xusr/local/www/diag_logs.php26
1 files changed, 21 insertions, 5 deletions
diff --git a/usr/local/www/diag_logs.php b/usr/local/www/diag_logs.php
index bcb8605..44cb566 100755
--- a/usr/local/www/diag_logs.php
+++ b/usr/local/www/diag_logs.php
@@ -45,6 +45,12 @@ if ($_POST['clear']) {
system_syslogd_start();
}
+if ($_GET['filtertext'])
+ $filtertext = $_GET['filtertext'];
+
+if ($_POST['filtertext'])
+ $filtertext = $_POST['filtertext'];
+
$pgtitle = "Diagnostics: System logs: System";
include("head.inc");
@@ -79,12 +85,22 @@ include("head.inc");
<tr>
<td colspan="2" class="listtopic">Last <?=$nentries;?> system log entries</td>
</tr>
- <?php dump_clog($system_logfile, $nentries, true, array(), array("racoon", "ntpd", "pppoe")); ?>
+ <?php
+ if($filtertext)
+ dump_clog($system_logfile, $nentries, true, array("$filtertext"), array("racoon", "ntpd", "pppoe"));
+ else
+ dump_clog($system_logfile, $nentries, true, array(), array("racoon", "ntpd", "pppoe"));
+ ?>
<tr>
- <td>
- <br>
- <form action="diag_logs.php" method="post">
- <input name="clear" type="submit" class="formbtn" value="Clear log">
+ <td align="left" valign="top">
+ <form id="filterform" name="filterform" action="diag_logs.php" method="post" style="margin-top: 14px;">
+ <input id="submit" name="clear" type="submit" class="formbtn" value="<?=gettext("Clear log");?>" />
+ </form>
+ </td>
+ <td align="right" valign="top" >
+ <form id="clearform" name="clearform" action="diag_logs.php" method="post" style="margin-top: 14px;">
+ <input id="filtertext" name="filtertext" value="<?=gettext($filtertext);?>" />
+ <input id="filtersubmit" name="filtersubmit" type="submit" class="formbtn" value="<?=gettext("Filter");?>" />
</form>
</td>
</tr>
OpenPOWER on IntegriCloud