You, Too, Can Create Interactive Maps3 Mar, 2008 By: Andrew G. Roe,P.E.
Even those with no programming training can use the widely available application programming interfaces to create maps.
Most of us are fairly adept at working with maps. After all, the GIS, engineering, and architecture fields are largely focused on drawings, maps, and associated data. Likewise, most of us have probably used Web-based mapping services such as Google and MapQuest to find directions to a restaurant, and shared this information by copying and pasting screenshots, driving directions, and Web links.
But did you know you can publish your own interactive maps and embed them in a personalized document or Web page? The technology has become more accessible in recent years, so you don't need to be a Web programmer to create an interactive map — one that allows you to zoom and pan in real time.
First, let's review how the technology works and how it has evolved to become so accessible. For those who are intimidated, bored, or nauseated by anything related to computer programming, I promise to be brief. If you can make it through this article and copy and paste text, you should be able to handle creating an interactive map. For those of you familiar with Web programming, much of this will likely be review.
Web pages are typically driven by HTML (hypertext markup language) code. The flashy pictures, maps, and text you see on Web sites are supported in the background by code that determines how the items appear. In the early days of the Internet, programmers had to generate hundreds of lines of code to build a simple Web site. Development tools introduced in the late 1990s simplified Web development for the masses and put many professional Web programmers out of work.
The Google and MapQuest APIs come with some licensing restrictions. Google, for example, will issue you a free code to publish interactive maps on Web sites that are free to consumers and generate no more than 15,000 geocode requests per day.
Try It Right Now
For demonstration purposes, let's look at the GoogleMaps API. All you need to try this is a text editor and a Web browser. In your text editor (Notepad or something similar), copy and paste the following code into a blank file.
Save the file as a text file, but with the extension .htm (e.g., GoogleMapTest.htm). Open the file in a Web browser, and you should see a map of the Minneapolis–St. Paul area.
After using the code to pull up this map in a browser, you can use Google's panning and zooming tools just as you would on Google's Web site.
Google has simplified the process even further by providing a link that allows you to copy and paste HTML code without even opening a text editor. (Click "Link to this page" on the Google Maps Web site to try that out.)
About the Author: Andrew G. Roe
Autodesk Technical Evangelist Lynn Allen guides you through a different AutoCAD feature in every edition of her popular "Circles and Lines" tutorial series. For even more AutoCAD how-to, check out Lynn's quick tips in the Cadalyst Video Gallery. Subscribe to Cadalyst's free Tips & Tools Weekly e-newsletter and we'll notify you every time a new video tip is published. All exclusively from Cadalyst!