How to Get Google My Maps Location Pins in Latitude and Longitude - google-maps

I have created a custom map via http://www.google.com/mymaps/ and have added a few locations.
Is there a way for me to retrieve these locations (in lat and lng format) via Google Map Javascript API?

First you will need to export your map as a KML layer. To see how to do that, you can read about it here.
After that, you will need to import your KML layer to Google Maps. Here is an example.
Then you can use KML Feature Details and use position to get lat/long

Related

How to search saved gps coordinates on a rout from source to destination on google map?

I am trying to develop website that shows all the major landmarks on a rout from source to destination using google map.
I have saved those major landmarks GPS coordinates in my database.
But, I do not know how can I search my saved GPS coordinates and find out which of them are on the rout shown by google map.
You may create a polyline from the path of the route(may be e.g. retrieved via route.overview_path) and then use the method google.maps.geometry.poly.isLocationOnEdge() of the geometry-library to check the landmark-coordinates against the polyline.

How can I display data on a Google Maps without the Lat and Long?

I'm using Google Maps API to display some information to my users. But I want the data is country and state specific. Now is there a way to display data to a state and country without having to provide the LAT and LONG?
I want to highlight the state and once the use click on it display some information.
The Google Maps API v3 uses geographical coordinates (latitude and longitude) for location information on the map. To position state and or country polygons on the map you will need data for them (which will need to include their geographic coordinates). There are publicly available polygons, the Natural Earth data set being one that is available in FusionTables.
See this similar question
or this one

Get latitude and longitude points in Google Maps polyline

I want to draw Polylines with the Google Maps JavaScript API. Is there a tool that will help me get the latitude and longitude points by just clicking on the map, then exporting an array of lat-long pairs?
I imagine something like the personalized maps service (My Places) in Google Maps where you can click-snap on the roads to specify your own driving directions. I'd like to take that one step further. That is, to export an array of lat-long pairs that specify the roads traveled.
I know this answer might be a little late but today I was trying to figure out what I believe to be the same issue as this question. So, you can draw the points on the map then get that encoded polyline with Google's Interactive Polyline Encoder Utility then I recommend using Mapbox polyline utility to convert the overview_polyline to latitude and longitude pairs values. The latitude and longitude pairs are also on Googles Utility but it is a bit of a hassle to continuously copy each coordinate.
For more information about the Mapbox Polyline Utility process:
http://zevross.com/blog/2014/09/23/convert-google-directions-to-geojson-points-or-polylines/
And here is Google's Encoder Utility:
https://developers.google.com/maps/documentation/utilities/polylineutility
You can use the Drawing Tools library:
http://code.google.com/apis/maps/documentation/javascript/overlays.html#drawing_tools
which will give you an encoded polyline. You can use that to draw a line, or you can decode it to get the specific points using the geometry library:
http://code.google.com/apis/maps/documentation/javascript/geometry.html

Exporting OpenStreet map to Image - Using Google Maps API

I know Google Maps API Terms of Service do not permit you to save their map data.
However OpenStreet does.
I want to use Google Maps API (ver 2) with the OpenStreet map layer and my own map layers - and have a button to export the map to an image.
How can I do this?
You can use a spatial index or a space-filling-curve to make your own map.

How to build our own user define

Can we create a user define custom base google map on which we can add our predefine landmark points?
Now in application we access google map with original information. Our GPS device returns location of current point with some description such as your vehicle is .. distance away from some xxx location.
So can we build to some user define google map on which we can add custom landmarks on google map, then we access that custom url to access google map.
You can create a customized google map page, with your own landmark points. You need to check out the Google Maps API Reference.
To create markers ('predefined landmark points') on the map you need to instantiate GMarker objects in Javascript using your latitude, longitude data.
Not quite clear on the last part of your question, but if you asking about linking to Google Maps at a particular latitude longitude, you can build a URL to do that:
http://maps.google.com.au/?ll=<latitude>,<longitude>&spn=<degrees high>,<degrees wide>
For example:
http://maps.google.com.au/?ll=-15.623037,18.388672&spn=65.61535,79.013672