enable geonames and fix zoom level

This commit is contained in:
Sajjad Anwar 2014-02-18 12:50:46 +05:30
parent efc7eb4804
commit 0b947e817d

View File

@ -91,7 +91,7 @@ var geojsonMarkerOptions = {
},
queryTokenizer: Bloodhound.tokenizers.whitespace,
remote: {
url: "http://api.geonames.org/searchJSON?username=geohacker&featureClass=P&maxRows=5&countryCode=IN&name_startsWith=%QUERY",
url: "http://api.geonames.org/searchJSON?username=geohacker&maxRows=5&countryCode=IN&name_startsWith=%QUERY",
filter: function (data) {
return $.map(data.geonames, function (result) {
return {
@ -141,7 +141,7 @@ var geojsonMarkerOptions = {
map.fitBounds(datum.bounds);
};
if (datum.source === "GeoNames") {
map.setView([datum.lat, datum.lng], 14);
map.setView([datum.lat, datum.lng], 15);
};
if ($(".navbar-collapse").height() > 50) {
$(".navbar-collapse").collapse("hide");