retrieving lat/long of location using google.maps.geocoder

前端 未结 5 642
感动是毒
感动是毒 2020-12-10 11:36

i have been trying to use some ajax to save venue location in my application and stumbled across the following code on stack overflow

function getLatLong(add         


        
5条回答
  •  粉色の甜心
    2020-12-10 12:01

    This is not the answer but don't use Pa and Qa always use the lng() and lat() functions:

     place.geometry.location
    {...}
        Pa: 56.240477
        Qa: -0.902655999999979
        toString: function(){return"("+this.lat()+", "+this.lng()+")"}
        equals: function(a){return!a?k:Cd(this.lat(),a.lat())&&Cd(this.lng(),a.lng())}
        lat: function(){return this[a]}
        lng: function(){return this[a]}
        toUrlValue: function(a){a=Hd(a)?a:6;return $d(this.lat(),a)+","+$d(this.lng(),a)}
    

提交回复
热议问题