X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/3af152046124403d0feaa32f9c02e23bba97c66b..3c7519444867cd9c6b3003c4c88729df21b8c265:/website/lookup.php?ds=sidebyside diff --git a/website/lookup.php b/website/lookup.php index 39a17ebd..737edc62 100644 --- a/website/lookup.php +++ b/website/lookup.php @@ -1,9 +1,9 @@ getPreferredLanguages(); -$oDB = new Nominatim\DB(); +$oDB = new Nominatim\DB(CONST_Database_DSN); $oDB->connect(); $hLog = logStart($oDB, 'place', $_SERVER['QUERY_STRING'], $aLangPrefOrder); @@ -58,7 +58,7 @@ foreach ($aOsmIds as $sItem) { $oPlace['place_id'], $oPlace['lon'], $oPlace['lat'], - Nominatim\ClassTypes\getProperty($oPlace, 'defdiameter', 0.0001) + Nominatim\ClassTypes\getDefRadius($oPlace) ); if ($aOutlineResult) { @@ -81,5 +81,7 @@ $bShowPolygons = ''; $aExcludePlaceIDs = array(); $sMoreURL = ''; +logEnd($oDB, $hLog, 1); + $sOutputTemplate = ($sOutputFormat == 'jsonv2') ? 'json' : $sOutputFormat; -include(CONST_BasePath.'/lib/template/search-'.$sOutputTemplate.'.php'); +include(CONST_LibDir.'/template/search-'.$sOutputTemplate.'.php');