Google maps embed API fallback coordinates - google-maps

I have a website that contains a database of places, mostly stores and small businesses, and i want to add a google map for every business on the site. I have a name and coordinates for each business, but not all of them are listed on google maps. If i make a Google Maps Embed API map like this:
https://www.google.com/maps/embed/v1/place?key=APIKEY&q=Place name
I will get a marker on that place, but if that place is not found, is it possible to make it put a marker on the coordinates provided?
I know i can just use the coordinates without any name, but in case the place is listed on google maps, querying its name instead of coordinates will display details about the place

Yes you can still place a marker as long as you have the lat and long.
You can add your business to Google Map over here.

Related

Google Maps Places API, need to get same markers as on Google emded

Good day !
I'm developing custom service, that will grab params form Google Maps url, like https://www.google.nl/maps/search/fietsenmaker/#52.1285737,5.0837216,13z/data=!3m1!4b1?hl=en. From this example it's possible to take search param, longitude, latitude and zoom level. All this params will pass to Google Places API and markers will be drawn on Google map. The main problem, i can't get this markers look same as on embed Google Maps. Here is attachment:
In simple words:
Need to dynamically embed map with listing of places, that was originally in search param and place map center according lat/long with original markers as on embed map.
Any ideas ?
Thanks !
Google Embed API will allow you to embed maps with starting params, like map center, object name. You can find it here https://developers.google.com/maps/documentation/embed/guide
Good luck everybody !

How do I specify a marker in a url using a name and lat/long for the new Google Maps?

I tried generating a url as per the answer by Everton Cunha here: What parameters should I use in a Google Maps URL to go to a lat-lon? i.e.
http://maps.google.com/?q=MY%20LOCATION#lat,long
This works for me in Google Maps in what is now called "Classic Mode", but in the new Google Maps, it places a marker, displays the lat/long next to it, and the marker does not display any information when I click on it, and the nearest address appears in the search box. I need a url that places the marker at the specified lat/long, and also includes some text describing what the marker is.

How to retrieve a static map showing city or municipality boundaries

I'm not sure where to start looking in the documentation, but I'm trying to load map images of cities with their boundaries outlined.
Like this...
Any help getting started would be greatly appreciated, I'm pretty new to the maps api.
Thanks
There is currently no way to request a map with boundaries automatically rendered on it. Your best bet is to pull the polygon information from another system and render using an encoded polyline if you're using the Static Map API or regular overlays in the JavaScript API.
Google Static Map API
Here it is
here, some links to help you:
Geographical boundaries of states/provinces -> Google Maps Polygon
EInsert extension
Boundary Draw - Google Map Application
Getting neighbourhood boundaries from Google Maps API
https://stackoverflow.com/questions/8441467/can-you-draw-custom-search-boundaries-in-google-map
Ability to draw boundaries on Google Maps

Search a google map I have created and embedded into my website

I have a Google map I have created to highlight the location of several support groups by adding my own pins using my maps and embedding this into my website.
Is there a Google widget of any description to allows people to search my custom map and find their nearest support group (or nearest pin).
I have read through the Google maps stuff but cant seem to find anything that meets my requirements.
Any help appreciated.
The map has no clue about which markers or overlays you have put on it. Therefore there are no way you can do what you want using Google Maps directly. You can however do something else.
When you create your markers/overlays and place them on the map you can add them to an array. When you users then enters a location you can search through that array to find the markers that are closest to the location the user has entered. Google Maps API has a method for getting the distance between two latlngs, but you can also use an ordinary Haversine formula for calculating it.
Once you have found the closest markers it is not hard making sure they are the only ones that are shown on the map.

Place markers through search in Google maps API (static)

I am currently working with the Google Maps API and returning static maps (images) from the API.
I need to place markers on the map. The documentation says how to place markers on the map by defining long/lat values: http://code.google.com/apis/maps/documentation/staticmaps/#Markers
My problem is that i donĀ“t know where to place the markers. I want a google maps search phrase to determine the placement of the markers. Is that possible?
To sum up:
I want to submit a search phrase to the API and have a static map (image) returned with markers matching my search phrase.
You can place markers based on an address:
http://maps.google.com/maps/api/staticmap?center=55.665149742004,12.5627200816055&zoom=12&size=640x640&sensor=false&maptype=hybrid&markers=color:blue|label:S|smallegade%201,%20frederiksberg
Yes, it's possible. Try this:
http://code.google.com/intl/pl/apis/maps/documentation/geocoding/
This particular link regards to Maps API Web Services, but there are others api, for javascript for instance.
Generaly you need Geocoging that tranlate address to latitude and longitude
I believe you can not search a term in Maps Static version. It is not in the accepted parameters: https://developers.google.com/maps/documentation/maps-static/dev-guide#Usage
Try using Embed or JavaScript versions instead.