mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
some formatting cleanups, introduce some more FIXMEs to look at, plus replace mysql_fetch_array by mysql_fetch_assoc, for great justice
git-svn-id: http://www.observium.org/svn/observer/trunk@2029 61d68cd4-352d-0410-923a-c4978735b2b8
This commit is contained in:
@@ -58,7 +58,7 @@ $rate_95th = $rate_data['rate_95th'] * 1000;
|
||||
$rate_average = $rate_data['rate_average'] * 1000;
|
||||
|
||||
$bi_q = mysql_query("SELECT * FROM bills WHERE bill_id = $bill_id");
|
||||
$bi_a = mysql_fetch_array($bi_q);
|
||||
$bi_a = mysql_fetch_assoc($bi_q);
|
||||
$bill_name = $bi_a['bill_name'];
|
||||
|
||||
$countsql = mysql_query("SELECT count(`delta`) FROM `bill_data` WHERE `bill_id` = '$bill_id' AND `timestamp` >= '$datefrom' AND `timestamp` <= '$dateto'");
|
||||
@@ -84,7 +84,7 @@ $dur = $end - $start;
|
||||
$sql = "SELECT *, UNIX_TIMESTAMP(timestamp) AS formatted_date FROM bill_data WHERE bill_id = $bill_id AND timestamp >= $datefrom AND timestamp <= $dateto ORDER BY timestamp ASC";
|
||||
$data = mysql_query($sql);
|
||||
|
||||
while ($row = mysql_fetch_array($data))
|
||||
while ($row = mysql_fetch_assoc($data))
|
||||
{
|
||||
@$timestamp = $row['formatted_date'];
|
||||
if (!$first) { $first = $timestamp; }
|
||||
|
Reference in New Issue
Block a user