Online Map Service Using Google Maps API and Other JavaScript Libraries: An Open Source Method

There has seen increasing interest in developing online map services using Google Maps Application Programming Interface (API), Yahoo! Maps API, Microsoft Bing Maps API, Nokia Ovi Maps API, and ESRI ArcGIS API. However, such online map services are mainly “mashups” in nature, meaning that they utilize Maps API as a platform and combine other spatial data from multiple sources to create new services. The objective of this chapter is to demonstrate an online mapping application that focuses not only on the functionality to display points of interest with customized icons and the information associated with them, but also on the sophisticated functionalities for marker clustering, searching, filtering, and tabbed interface that offer the user the capability to manipulate the data, which is lacking in most documented web mapping services. A case study of developing an online map service to display the locations of hundreds of gardens on the Internet for the United States Department of Agriculture (USDA) People’s Garden initiative is presented. Google Maps API, Google Geocoder and other JavaScript libraries such as jQuery, XML, MarkerClusterer, Spry Framework for Ajax, all free and open source, are employed to develop this online map service. It is anticipated that the online map service demonstrated here can be used in most of the web browsers such as Microsoft Internet Explorer (IE) 7.0+, Google Chrome, Mozilla Firefox, and Apple Safari.