google autocomplete service test
HTML
<script>
function initMap() {
var service = new google.maps.places.AutocompleteService();
service.getQueryPredictions({
input: 'Lo',
location: new google.maps.LatLng(51.508742,-0.120850),
radius: 50000,
components: { country: 'uk' }
}, function () {
console.log(arguments);
});
}
</script>
<script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?v=3.exp&signed_in=true&libraries=places&callback=initMap"></script>
JavaScript
sav=3.exp&signed_in=true&libraries=places&callback=initMap"></script>