- case 'former country':
- continue 2;
- case 'sea':
- $fMaxDist = 60; // effectively turn it off
- $sURL .= "&viewbox=".($aRecord['lon']-$fMaxDist).",".($aRecord['lat']+$fMaxDist).",".($aRecord['lon']+$fMaxDist).",".($aRecord['lat']-$fMaxDist);
- break;
- case 'country':
- case 'island':
- case 'islands':
- case 'continent':
- $fMaxDist = 60; // effectively turn it off
- $sURL .= "&featuretype=country";
- $sURL .= "&viewbox=".($aRecord['lon']-$fMaxDist).",".($aRecord['lat']+$fMaxDist).",".($aRecord['lon']+$fMaxDist).",".($aRecord['lat']-$fMaxDist);
- break;
- case 'prefecture japan':
- $aRecord['name'] = trim(str_replace(' Prefecture',' ', $aRecord['name']));
- case 'state':
- case '#us state':
- case 'county':
- case 'u.s. state':
- case 'u.s. state symbols':
- case 'german state':
- case 'province or territory of canada';
- case 'indian jurisdiction';
- case 'province';
- case 'french region':
- case 'region of italy':
- case 'kommune':
- case '#australia state or territory':
- case 'russian federal subject':
- $fMaxDist = 4;
- $sURL .= "&featuretype=state";
- $sURL .= "&viewbox=".($aRecord['lon']-$fMaxDist).",".($aRecord['lat']+$fMaxDist).",".($aRecord['lon']+$fMaxDist).",".($aRecord['lat']-$fMaxDist);
- break;
- case 'protected area':
- $fMaxDist = 1;
- $sURL .= "&nearlat=".$aRecord['lat'];
- $sURL .= "&nearlon=".$aRecord['lon'];
- $sURL .= "&viewbox=".($aRecord['lon']-$fMaxDist).",".($aRecord['lat']+$fMaxDist).",".($aRecord['lon']+$fMaxDist).",".($aRecord['lat']-$fMaxDist);
- break;
- case 'settlement':
- $bUnknown = true;
- case 'french commune':
- case 'italian comune':
- case 'uk place':
- case 'italian comune':
- case 'australian place':
- case 'german place':
- case '#geobox':
- case 'u.s. county':
- case 'municipality':
- case 'city japan':
- case 'russian inhabited locality':
- case 'finnish municipality/land area':
- case 'england county':
- case 'israel municipality':
- case 'russian city':
- case 'city':
- $fMaxDist = 0.2;
- $sURL .= "&featuretype=settlement";
- $sURL .= "&viewbox=".($aRecord['lon']-0.5).",".($aRecord['lat']+0.5).",".($aRecord['lon']+0.5).",".($aRecord['lat']-0.5);
- break;
- case 'mountain':
- case 'mountain pass':
- case 'river':
- case 'lake':
- case 'airport':
- $fMaxDist = 0.2;
- $sURL .= "&viewbox=".($aRecord['lon']-0.5).",".($aRecord['lat']+0.5).",".($aRecord['lon']+0.5).",".($aRecord['lat']-0.5);
-
- case 'ship begin':
- $fMaxDist = 0.1;
- $aTypes = array('wreck');
- $sURL .= "&viewbox=".($aRecord['lon']-0.01).",".($aRecord['lat']+0.01).",".($aRecord['lon']+0.01).",".($aRecord['lat']-0.01);
- $sURL .= "&nearlat=".$aRecord['lat'];
- $sURL .= "&nearlon=".$aRecord['lon'];
- break;
- case 'road':
- case 'university':
- case 'company':
- case 'department':
- $fMaxDist = 0.005;
- $sURL .= "&viewbox=".($aRecord['lon']-0.01).",".($aRecord['lat']+0.01).",".($aRecord['lon']+0.01).",".($aRecord['lat']-0.01);
- $sURL .= "&bounded=1";
- $sURL .= "&nearlat=".$aRecord['lat'];
- $sURL .= "&nearlon=".$aRecord['lon'];
- break;
- default:
- $bUnknown = true;
- $fMaxDist = 0.005;
- $sURL .= "&viewbox=".($aRecord['lon']-0.01).",".($aRecord['lat']+0.01).",".($aRecord['lon']+0.01).",".($aRecord['lat']-0.01);
-// $sURL .= "&bounded=1";
- $sURL .= "&nearlat=".$aRecord['lat'];
- $sURL .= "&nearlon=".$aRecord['lon'];
- echo "-- Unknown: ".$aRecord['infobox_type']."\n";
- break;
+ case 'former country':
+ continue 2;
+ case 'sea':
+ $fMaxDist = 60; // effectively turn it off
+ $sURL .= '&viewbox='.($aRecord['lon']-$fMaxDist).','.($aRecord['lat']+$fMaxDist).','.($aRecord['lon']+$fMaxDist).','.($aRecord['lat']-$fMaxDist);
+ break;
+ case 'country':
+ case 'island':
+ case 'islands':
+ case 'continent':
+ $fMaxDist = 60; // effectively turn it off
+ $sURL .= '&featuretype=country';
+ $sURL .= '&viewbox='.($aRecord['lon']-$fMaxDist).','.($aRecord['lat']+$fMaxDist).','.($aRecord['lon']+$fMaxDist).','.($aRecord['lat']-$fMaxDist);
+ break;
+ case 'prefecture japan':
+ $aRecord['name'] = trim(str_replace(' Prefecture', ' ', $aRecord['name']));
+ // intentionally no break
+ case 'state':
+ case '#us state':
+ case 'county':
+ case 'u.s. state':
+ case 'u.s. state symbols':
+ case 'german state':
+ case 'province or territory of canada':
+ case 'indian jurisdiction':
+ case 'province':
+ case 'french region':
+ case 'region of italy':
+ case 'kommune':
+ case '#australia state or territory':
+ case 'russian federal subject':
+ $fMaxDist = 4;
+ $sURL .= '&featuretype=state';
+ $sURL .= '&viewbox='.($aRecord['lon']-$fMaxDist).','.($aRecord['lat']+$fMaxDist).','.($aRecord['lon']+$fMaxDist).','.($aRecord['lat']-$fMaxDist);
+ break;
+ case 'protected area':
+ $fMaxDist = 1;
+ $sURL .= '&nearlat='.$aRecord['lat'];
+ $sURL .= '&nearlon='.$aRecord['lon'];
+ $sURL .= '&viewbox='.($aRecord['lon']-$fMaxDist).','.($aRecord['lat']+$fMaxDist).','.($aRecord['lon']+$fMaxDist).','.($aRecord['lat']-$fMaxDist);
+ break;
+ case 'settlement':
+ $bUnknown = true;
+ // intentionally no break
+ case 'french commune':
+ case 'italian comune':
+ case 'uk place':
+ case 'italian comune':
+ case 'australian place':
+ case 'german place':
+ case '#geobox':
+ case 'u.s. county':
+ case 'municipality':
+ case 'city japan':
+ case 'russian inhabited locality':
+ case 'finnish municipality/land area':
+ case 'england county':
+ case 'israel municipality':
+ case 'russian city':
+ case 'city':
+ $fMaxDist = 0.2;
+ $sURL .= '&featuretype=settlement';
+ $sURL .= '&viewbox='.($aRecord['lon']-0.5).','.($aRecord['lat']+0.5).','.($aRecord['lon']+0.5).','.($aRecord['lat']-0.5);
+ break;
+ case 'mountain':
+ case 'mountain pass':
+ case 'river':
+ case 'lake':
+ case 'airport':
+ $fMaxDist = 0.2;
+ $sURL .= '&viewbox='.($aRecord['lon']-0.5).','.($aRecord['lat']+0.5).','.($aRecord['lon']+0.5).','.($aRecord['lat']-0.5);
+ break;
+ case 'ship begin':
+ $fMaxDist = 0.1;
+ $aTypes = array('wreck');
+ $sURL .= '&viewbox='.($aRecord['lon']-0.01).','.($aRecord['lat']+0.01).','.($aRecord['lon']+0.01).','.($aRecord['lat']-0.01);
+ $sURL .= '&nearlat='.$aRecord['lat'];
+ $sURL .= '&nearlon='.$aRecord['lon'];
+ break;
+ case 'road':
+ case 'university':
+ case 'company':
+ case 'department':
+ $fMaxDist = 0.005;
+ $sURL .= '&viewbox='.($aRecord['lon']-0.01).','.($aRecord['lat']+0.01).','.($aRecord['lon']+0.01).','.($aRecord['lat']-0.01);
+ $sURL .= '&bounded=1';
+ $sURL .= '&nearlat='.$aRecord['lat'];
+ $sURL .= '&nearlon='.$aRecord['lon'];
+ break;
+ default:
+ $bUnknown = true;
+ $fMaxDist = 0.005;
+ $sURL .= '&viewbox='.($aRecord['lon']-0.01).','.($aRecord['lat']+0.01).','.($aRecord['lon']+0.01).','.($aRecord['lat']-0.01);
+ // $sURL .= "&bounded=1";
+ $sURL .= '&nearlat='.$aRecord['lat'];
+ $sURL .= '&nearlon='.$aRecord['lon'];
+ echo '-- Unknown: '.$aRecord['infobox_type']."\n";
+ break;