$aLangPrefOrder = getPreferredLanguages();
$oGeocode->setLanguagePreference($aLangPrefOrder);
+ /*
+ if (isset($aLangPrefOrder['name:de'])) $oGeocode->setReverseInPlan(true);
+ if (isset($aLangPrefOrder['name:ru'])) $oGeocode->setReverseInPlan(true);
+ if (isset($aLangPrefOrder['name:ja'])) $oGeocode->setReverseInPlan(true);
+ if (isset($aLangPrefOrder['name:pl'])) $oGeocode->setReverseInPlan(true);
+ */
+
function loadParamsToGeocode($oGeocode, $aParams, $bBatch = false)
{
if (isset($aParams['addressdetails'])) $oGeocode->setIncludeAddressDetails((bool)$aParams['addressdetails']);
if (!$sQuery)
{
$oGeocode->setStructuredQuery(@$aParams['amenity'], @$aParams['street'], @$aParams['city'], @$aParams['county'], @$aParams['state'], @$aParams['country'], @$aParams['postalcode']);
+ $oGeocode->setReverseInPlan(false);
}
else
{
}
exit;
}
- $oGeocode->setIncludePolygonAsText($bAsPoints);
+ $oGeocode->setIncludePolygonAsPoints($bAsPoints);
$oGeocode->setIncludePolygonAsText($bAsText);
$oGeocode->setIncludePolygonAsGeoJSON($bAsGeoJSON);
$oGeocode->setIncludePolygonAsKML($bAsKML);
loadParamsToGeocode($oGeocode, $_GET, false);
- if (isset($_GET['batch']))
+ if (CONST_Search_BatchMode && isset($_GET['batch']))
{
$aBatch = json_decode($_GET['batch'], true);
$aBatchResults = array();