Show building name/location name on map
See original GitHub issueI need to show building name/location name on map like this
Are there any ways to support this feature? Thank you.
// This example requires the Places library. Include the libraries=places
// parameter when you first load the API. For example:
// <script src="https://maps.googleapis.com/maps/api/js?key=YOUR_API_KEY&libraries=places">
function initMap() {
var map = new google.maps.Map(document.getElementById('map'), {
center: {lat: -33.866, lng: 151.196},
zoom: 15
});
var infowindow = new google.maps.InfoWindow();
var service = new google.maps.places.PlacesService(map);
service.getDetails({
placeId: 'ChIJN1t_tDeuEmsRUsoyG83frY4'
}, function(place, status) {
if (status === google.maps.places.PlacesServiceStatus.OK) {
var marker = new google.maps.Marker({
map: map,
position: place.geometry.location
});
google.maps.event.addListener(marker, 'click', function() {
infowindow.setContent('<div><strong>' + place.name + '</strong><br>' +
'Place ID: ' + place.place_id + '<br>' +
place.formatted_address + '</div>');
infowindow.open(map, this);
});
}
});
}
Issue Analytics
- State:
- Created 7 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
Give a place a private label - Android - Google Maps Help
Labeled places show up on your map, in search suggestions, in the "Your places" screen, and in Google Photos. ... At the bottom,...
Read more >How to register my building name on Google Maps
Login to Google Map Maker using your google account, using satellite imagery and other land mark locate your building and add your building...
Read more >Call Me By Your Name Filming Locations in Northern Italy
Want to know where ABSOLUTELY ALL of the Call Me By Your Name locations are in Italy? This is a FULL guide plus...
Read more >Terraform - Building an Output Map
For example, one map that shows Resource Group Name, location, tags? Variable Definition variable "resource_groups" { description ...
Read more >Using a Floor Plan or Custom Map in Dashboard - Cisco Meraki
Deleting/Renaming Custom Floor Plans · Select the Edit button next to the floor plan you'd like to rename · Name, location or image...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
+1
@istarkov ?