How to create link to google map with opened info and window - google-maps

I need to create link on google maps with marker + infowindow
I found this link:
url http://www.google.com/maps?q=41.0082,28.9784(INFO_WINDOW)
used to work before. But now it doesn't work anymore.

That is the "old"/"classic" Google Maps, it no longer works.
Some options:
Look at the embed API
Create a Google Maps Javascript API v3 map of your own that supports that functionality (example)

Related

Google Maps - Link from static image with markers to full maps.google.com

I need to redirect from a static google maps image via the Static Maps API to maps.google.com.
I have multiple markers on the map. Example: "http://maps.googleapis.com/maps/api/staticmap?size=235x227&maptype=roadmap&markers=37.970982,23.724559|37.971487,23.724953|37.973291,23.726862"
I need the proper url format that, when the image is clicked, will redirect to maps.google.com with all markers placed on the map. I cant find the documentation on how to do this.
There are no way to add markers into the google maps now.. so the answer is no.
However, you can build a custom page, which uses the google maps API and you can add markers that way.
I built a sample page here in github.
so for your map:
you can wrap it with an a element which link to your page with the same option like this sample:
http://kylelam.github.io/SO/customMarkers.html?size=235x227&maptype=roadmap&markers=37.970982,23.724559|37.971487,23.724953|37.973291,23.726862

How to load new google maps with API v3

Classic My Maps on maps.google.com will no longer be available.
Now we must use new maps. I would like to embed them to the website, without iframe that google suggests.
Before this change I used simple kml layer:
var kmlLayer = new google.maps.KmlLayer('https://maps.google.com/maps/ms?ie=UTF8&t=m&authuser=0&msa=0&output=kml&msid=212840568890456843825.0004c1fba0c8371a81c2b');";
kmlLayer.setMap(gMap);
But during the automatic update of my maps it was broken, if I use the same link - I got empty icons. Here is the new map (converted by google), can I load it using API V3 as I did before?
https://www.google.com/maps/d/viewer?mid=zhJ_pzBRPGN8.kCI6hT4Kq0Ao
In other words:
I want to create maps here: https://www.google.com/maps/d/
And to embed them using API v3, but where can I get a link to the layer? Central coordinate, zoom level?
Change the KML Layer link to:
https://mapsengine.google.com/map/kml?mid=zhJ_pzBRPGN8.kCI6hT4Kq0Ao&lid=zhJ_pzBRPGN8.kZ0hfyeW-GtI
I grabbed this link from the "Share", "Download KML" URL on the Map that you linked to.

Google Maps - visitor generated marker

I found a WP extension for adding a Google Maps plugin which supports visitor-generated markers.
http://www.wpgmaps.com/visitor-generated-markers-add-on/
Does anyone know how this is done using GoogleMaps JavaScript API v3?
Thanks already!
Best regards
If you look at their demo map, it's using Google Maps API to add their markers. See their JS at http://www.wpgmaps.com/wp-content/plugins/wp-google-maps-pro/js/core.js?ver=5.34p
And you can see they're loading the markers data from an XML file, e.g. at http://www.wpgmaps.com/wp-content/uploads/wp-google-maps/6markers.xml?u=9690
So when you submit their form to add a marker, it's saving it server-side into that XML file. This will be WPGmaps' own server-side code for doing that. And it's their own javascript that loads in that XML file, loops over it and calls the Google Maps functions for adding markers and infowindows.

Google Maps V3 Show Map on Google Maps Link

I am using a javascript Google Maps V3 to show the location of places I have on my site, I can only offer a small view on my site so anyone who wants to see the larger map on google should either click on the Google icone on the bottom left, or in some cases I saw a link/button on the map stating "click to show on Google Maps".
So my question is how to show the link/button on my map that can open the same location on google maps site.
Google map provides an option to customize the link by adding some parameters for viewing map.
You can get the list of parameters here:
http://alvarestech.com/temp/routeconverter/RouteConverter/navigation-formats/src/main/doc/googlemaps/Google_Map_Parameters.htm
You'll need to pass the parameters to the link.
Example: https://www.google.com.au/maps/preview/#,,
You can also refer this post for more details: How do I link to Google Maps with a particular longitude and latitude?

Custom map in Google Map?

On a website I see they use Google Map, but the map looks special and is different from other Google Maps I saw. Is that special-looking map provided by Google Maps or made by the website themselves?
I checked "My Maps" on Google Maps and didn't find related options.
A website with special-looking Google Map tiles
It's called Styled Maps. See the documentation and examples here: https://developers.google.com/maps/documentation/javascript/styling?hl=en