O'Reilly logo

Google Maps JavaScript API Cookbook by Balkan Uraz, Alper Dincer

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Finding places with the autocomplete option

The Google Maps JavaScript API offers a variety of ways to search for places and additional information. You can apply nearby searches and have detailed information about places together with their geometry, as you have observed in the recipe named Searching and showing nearby places in this chapter.

How about having a text field control with an autocomplete feature for searching places? You can hardcode it, but there is no need to do so, as Google already has a feature exactly for this.

In this recipe, we will go over the autocomplete feature of the places library for the Google Maps JavaScript API.

Getting ready

This recipe will make use of the concepts related to the places library introduced in the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required