From 8fa0bce46c4f84d09547a5cc148f3b3c08b2983d Mon Sep 17 00:00:00 2001 From: dg9vh Date: Tue, 28 Mar 2017 20:20:10 +0000 Subject: [PATCH] makes switchRefl. only working on DMRplus-Network, not on BM because options-line in MMDVM.ini is not supported by BrandMeister --- include/functions.php | 29 ++++++++++++----------------- index.php | 6 +++--- version.php | 2 +- 3 files changed, 16 insertions(+), 21 deletions(-) diff --git a/include/functions.php b/include/functions.php index bdd2bef..974b077 100644 --- a/include/functions.php +++ b/include/functions.php @@ -858,23 +858,8 @@ function getGitVersion(){ } } -function getDMRReflectors($network) { - $refls = array(); - switch ($network) { - case "DMRPLUS": - $refls = getDMRReflectorsFromURL("http://ham-dmr.de/reflector.db"); - break; - case "BRANDMEISTER": - $refls = getDMRReflectorsFromURL("http://185.79.71.94/reflector.db"); - break; - - } - return $refls; - -} - -function getDMRReflectorsFromURL($url) { - $data = file_get_contents($url); +function getDMRReflectors() { + $data = file_get_contents("http://ham-dmr.de/reflector.db"); $rows = explode("\n",$data); $refls = array(); foreach($rows as $row) { @@ -882,4 +867,14 @@ function getDMRReflectorsFromURL($url) { } return $refls; } + +function getBrandMeisterDMRMasterList() { + $data = file_get_contents("http://185.79.71.94/dmr/dmrmaster.php"); + $rows = explode("\n",$data); + $masters = array(); + foreach($rows as $row) { + $masters[] = str_getcsv($row,"@",''); + } + return $masters; +} ?> diff --git a/index.php b/index.php index ab21365..7f62ff2 100644 --- a/index.php +++ b/index.php @@ -135,15 +135,15 @@ if (defined("ENABLENETWORKSWITCHING")) {