From 6226bdb70faa0fcb594ea252b3e07aeed8b59df8 Mon Sep 17 00:00:00 2001 From: Romain d'Alverny Date: Wed, 22 Feb 2012 00:08:00 +0000 Subject: prepare for mirrors list update --- en/downloads/get/index.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/en/downloads/get/index.php b/en/downloads/get/index.php index edabd31ff..5c1a11e6c 100644 --- a/en/downloads/get/index.php +++ b/en/downloads/get/index.php @@ -71,6 +71,9 @@ try { $g_mirs2 = array(); foreach ($alt_mirrors as $country => $mirs): + if (substr($country, 0, 3) == '_C:') + continue; + foreach ($mirs as $mir): $g_mirs2[$countries[$country]][$mir['city']][] = $mir['url']; endforeach; @@ -80,6 +83,7 @@ try { $alternative_mirrors = ''; foreach ($g_mirs2 as $country => $cities): + $s = array(); foreach ($cities as $city => $mirrors2) { $mirs = array(); foreach ($mirrors2 as $m) { @@ -88,8 +92,9 @@ try { $mirs[] = sprintf('%s://%s', $pm['scheme'], $alt_dl_link, $pm['host']); } - $alternative_mirrors .= sprintf('%s%s%s', $country, $city, implode(', ', $mirs)); + $s[] = sprintf('%s%s', $city, implode(', ', $mirs)); } + $alternative_mirrors .= sprintf('%s%s', count($cities), $country, implode('', $s)); endforeach; $dl2_mirror_alt = sprintf($_t['dl_mirror_loc'], -- cgit v1.2.1