okay } else { // user is currently NOT on a scope page => like file display page => next destination using this page is projectlist! $currentscope['target'] = "projectlist"; } if ($regionid > 0) { $region = Factory::getObjectByID($regionid); $regiondata = $region->getDisplayData(); $regiondata['name'] = $regiondata['data']['name']['value']['value']; $regiondata['regiontype'] = $region->getRegiontypeName(); $regiondata['regiontypeid'] = $region->getRegiontypeID(); $regiondata['population'] = $regiondata['data']['population']['value']; // for example "23438434343" $regiondata['area'] = $regiondata['data']['area']['value']; // for example "23438434343" $regiondata['links'] = $regiondata['links']; if ($regiondata['regiontypeid'] == 7) { // city -- get zones // get zones $regiondata['zones'] = $region->getZones(); #var_dump($regiondata['zones']); } else { // not a city -- get biggest cities // subregions from this region (cities) $regiondata['cities'] = $region->getSubregions(6, 0, 15); $regiondata['largestcities'] = $region->getSubregions(6, 1, 15); #var_dump($regiondata['largestcities']); } $center = $region->getCenter(); if ($center && $center['lat'] != "" && $center['lng'] != "") { // lat+lng not empty $regiondata['lat'] = $center['lat']; $regiondata['lng'] = $center['lng']; $regiondata['zoom'] = $region->getZoomlevel(); } $subregions = $region->getSubRegions($region->getChildRegiongroupID(), 1, 200); } else { $regiondata['name'] = t("World"); $regiondata['regiontype'] = "world"; $regiondata['population'] = "7,100,000,000"; $regiondata['area'] = "510,072,000 km²"; $regiondata['lat'] = 0; $regiondata['lng'] = -6; $regiondata['zoom'] = 1; $subregions = Region::getContinents(); }; foreach ($subregions as $k => $v){ $subregion = Factory::getObjectByID($k); $subregioncenter = $subregion->getCenter(); if ($subregioncenter && $subregioncenter['lat'] != "" && $subregioncenter['lng'] != "") { // lat+lng not empty $subregions[$k]['location'] = array( "lat" => $subregioncenter['lat'], "lng" => $subregioncenter['lng'], "zoom" => $subregion->getZoomlevel() ); } } /* echo "
"; var_dump($subregions); echo ""; */ ?>
: $region) { $currentitem = $key+1; echo ' $currentscope['channel'], "region" => $region['id'], "company" => $currentscope['company'], "stream" => $currentscope['stream'], "collection" => $currentscope['collection'], "recognition" => $currentscope['recognition'], "target" => $currentscope['target']), $_SESSION['account_language'], 'scope', 'absolute') . '">' . $region['name'] . ''; if($currentitem != count($regionquery)){ echo ", "; } else { echo "."; } } ?>