Skip to content

Instantly share code, notes, and snippets.

@renatoeufe
Created February 25, 2013 04:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save renatoeufe/5027843 to your computer and use it in GitHub Desktop.
Save renatoeufe/5027843 to your computer and use it in GitHub Desktop.
recuperar lat e lng do google maps com marker draggable
window.google.maps.Marker.prototype.getLat = function () {
var position = this.getPosition();
return position[Object.keys(position)[0]];
};
window.google.maps.Marker.prototype.getLng = function () {
var position = this.getPosition();
return position[Object.keys(position)[1]];
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment