From 0b2317f6f9f5184296ca0e686c26dce1cedada60 Mon Sep 17 00:00:00 2001 From: phl0 Date: Mon, 23 Jan 2017 15:30:22 +0100 Subject: [PATCH] Set dB values to superscript --- include/functions.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/include/functions.php b/include/functions.php index dfb41cd..91d3f33 100644 --- a/include/functions.php +++ b/include/functions.php @@ -273,10 +273,10 @@ function getHeardList($logLines, $onlyLast) { else if (constant("RSSI") == "max") $rssiVal = preg_replace('/-\d+\/(-\d+)\/-\d+ dBm/', "\\1", $rssiString); else if (constant("RSSI") == "avg") $rssiVal = preg_replace('/-\d+\/-\d+\/(-\d+) dBm/', "\\1", $rssiString); else $rssiVal = preg_replace('/-\d+\/-\d+\/(-\d+) dBm/', "\\1", $rssiString); - if ($rssiVal > "-53") $rssi = "
S9+40dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; - else if ($rssiVal > "-63") $rssi = "
S9+30dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; - else if ($rssiVal > "-73") $rssi = "
S9+20dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; - else if ($rssiVal > "-83") $rssi = "
S9+10dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; + if ($rssiVal > "-53") $rssi = "
S9 +40dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; + else if ($rssiVal > "-63") $rssi = "
S9 +30dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; + else if ($rssiVal > "-73") $rssi = "
S9 +20dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; + else if ($rssiVal > "-83") $rssi = "
S9 +10dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; else if ($rssiVal > "-93") $rssi = "
S9 ($rssiVal dBm)(min/max/avg)
$rssiString
"; else if ($rssiVal > "-99") $rssi = "
S8 ($rssiVal dBm)(min/max/avg)
$rssiString
"; else if ($rssiVal > "-105") $rssi = "
S7 ($rssiVal dBm)(min/max/avg)
$rssiString
"; @@ -300,10 +300,10 @@ function getHeardList($logLines, $onlyLast) { else if (constant("RSSI") == "max") $rssiVal = preg_replace('/-\d+\/(-\d+)\/-\d+ dBm/', "\\1", $rssiString); else if (constant("RSSI") == "avg") $rssiVal = preg_replace('/-\d+\/-\d+\/(-\d+) dBm/', "\\1", $rssiString); else $rssiVal = preg_replace('/-\d+\/-\d+\/(-\d+) dBm/', "\\1", $rssiString); - if ($rssiVal > "-53") $rssi = "
S9+40dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; - else if ($rssiVal > "-63") $rssi = "
S9+30dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; - else if ($rssiVal > "-73") $rssi = "
S9+20dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; - else if ($rssiVal > "-83") $rssi = "
S9+10dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; + if ($rssiVal > "-53") $rssi = "
S9 +40dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; + else if ($rssiVal > "-63") $rssi = "
S9 +30dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; + else if ($rssiVal > "-73") $rssi = "
S9 +20dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; + else if ($rssiVal > "-83") $rssi = "
S9 +10dB ($rssiVal dBm)(min/max/avg)
$rssiString
"; else if ($rssiVal > "-93") $rssi = "
S9 ($rssiVal dBm)(min/max/avg)
$rssiString
"; else if ($rssiVal > "-99") $rssi = "
S8 ($rssiVal dBm)(min/max/avg)
$rssiString
"; else if ($rssiVal > "-105") $rssi = "
S7 ($rssiVal dBm)(min/max/avg)
$rssiString
";