mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
update changelog, clean up files
git-svn-id: http://www.observium.org/svn/observer/trunk@1893 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
@@ -6,7 +6,8 @@ include("config.php");
|
||||
include("includes/functions.php");
|
||||
|
||||
$alert_query = mysql_query("SELECT *, A.id as id FROM `alerts` as A, `devices` as D where A.device_id = D.device_id AND alerted = '0'");
|
||||
while ($alert = mysql_fetch_array($alert_query)) {
|
||||
while ($alert = mysql_fetch_array($alert_query))
|
||||
{
|
||||
$id = $alert['id'];
|
||||
$host = $alert['hostname'];
|
||||
$date = $alert['time_logged'];
|
||||
@@ -14,12 +15,12 @@ while ($alert = mysql_fetch_array($alert_query)) {
|
||||
$alert_text .= "$date $host $msg";
|
||||
|
||||
mysql_query("UPDATE `alerts` SET alerted = '1' WHERE `id` = '$id'");
|
||||
|
||||
}
|
||||
|
||||
if($alert_text) {
|
||||
if ($alert_text)
|
||||
{
|
||||
echo("$alert_text");
|
||||
# `echo '$alert_text' | gnokii --sendsms <NUMBER>`;
|
||||
}
|
||||
|
||||
?>
|
||||
?>
|
||||
Reference in New Issue
Block a user