diff --git a/ajax.php b/ajax.php index 6b41af9..e3af8b5 100644 --- a/ajax.php +++ b/ajax.php @@ -11,6 +11,10 @@ $logLinesMMDVM = getMMDVMLog(); $reverseLogLinesMMDVM = $logLinesMMDVM; array_multisort($reverseLogLinesMMDVM,SORT_DESC); //$lastHeard = $_SESSION['lastHeard']; +if ($_GET['section'] == "mode") { + $mode = getActualMode(getLastHeard($reverseLogLinesMMDVM, TRUE), $mmdvmconfigs); + echo $mode; +} if ($_GET['section'] == "lastHeard") { $lastHeard = getLastHeard($reverseLogLinesMMDVM, FALSE); echo '{"data": '.json_encode($lastHeard)."}"; diff --git a/include/functions.php b/include/functions.php index c6da803..59ba735 100644 --- a/include/functions.php +++ b/include/functions.php @@ -328,7 +328,7 @@ function getActualMode($metaLastHeard, $mmdvmconfigs) { if (startsWith($mode, "DMR")) { $mode = "DMR"; } - if ($listElem[6] ==="") { + if ($listElem[7] ==="") { return $mode; } else { $now = new DateTime(); diff --git a/include/repeaterinfo.php b/include/repeaterinfo.php index 0f4979b..e3fc998 100644 --- a/include/repeaterinfo.php +++ b/include/repeaterinfo.php @@ -13,7 +13,7 @@ "; - echo"