InvalidValueError:我的代码中不是HTMLInputElement的实例

时间:2017-04-06 18:03:17

标签: javascript jquery

我的javascript代码和html代码是。当我尝试运行代码时,它会在chrome中显示InvalidValueError。

rank

HTML代码:`

   google.maps.event.addDomListener(window, 'load', intilize);
   function intilize() {
    var autocomplete = new google.maps.places.Autocomplete(document.getElementById("textarea"));

    google.maps.event.addListener(autocomplete, 'place_changed', function () {

    var place = autocomplete.getPlace();
    var location = "Address: " + place.formatted_address + "<br/>";
    location += "Latitude: " + place.geometry.location.A + "<br/>";
    location += "Longitude: " + place.geometry.location.F;

    });

};

0 个答案:

没有答案