When I load this code below I have a box that pops up with LAT.LNG Any way to remove this please?
$.getJSON('/aircraft.json', function(data) {
$.each( data.aircraft, function(i, value) {
var myLatlng = new google.maps.LatLng(value.lat, value.lon);
alert(myLatlng);
var marker = new google.maps.Marker({
position: myLatlng,
icon: '/airplane.jpg',
map: map,
title: "text "+value.lon
});
});
Assuming this is your site.
In your code there is a function to retrieve and handle the coodrinates from a JSON input /aircrat.json
. This function contains a line alert(myLatlng)
. That line is making your popup.alert
is a function to make a default 'alert' to the user with the contained info.
$.getJSON('/aircraft.json', function(data) {
$.each( data.aircraft, function(i, value) {
var myLatlng = new google.maps.LatLng(value.lat, value.lon);
// alert(myLatlng);
var marker = new google.maps.Marker({
position: myLatlng,
icon: '/airplane.jpg',
map: map,
title: "text "+value.lon
});
});
I have commented out the offending line in the code above.