Chapter 61. Application: Creating Custom Google Maps

IN THIS CHAPTER

  • The basics of Google mapping

  • Converting a physical address into geocoordinates

  • XML as a map language

  • Using Ajax to create Google maps

Seeing as how JavaScript is an incredibly practical technology, it's only fitting that this book should end with what may be the most practical of all JavaScript examples: a custom interactive map based upon Google's popular Google Maps tool. Google Maps is an online mapping tool that utilizes asynchronous JavaScript and XML (Ajax) to provide a traditional vector map view, along with a satellite photography view, and even a hybrid view that overlays vector street information onto the photographic satellite map. One of the features that makes Google Maps so interesting is the fact that it is customizable through a programming interface that Google has made available to web developers. Both JavaScript and XML factor heavily into Google Maps and how you go about customizing it. This chapter introduces you to the inner workings of Google Maps and guides you through a complete map customization example.

A Google Maps Primer

Although Google Maps is plenty of fun to tinker with purely from a user's perspective in terms of exploring the built-in map features, it's the development potential that truly makes it an exciting technology. In 2005 Google made available to the public an application programming interface (API) for Google Maps that allows web developers to build custom mapping applications. ...

Get JavaScript® Bible, Seventh Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.