Available:*
Library | Item Barcode | Call Number | Material Type | Item Category 1 | Status |
---|---|---|---|---|---|
Searching... | 30000010293829 | TK5105.8885.A52 P87 2006 | Open Access Book | Book | Searching... |
On Order
Summary
Summary
Until recently, building interactive web-based mapping applications has been a cumbersome affair. This changed when Google released its powerful Maps API. Beginning Google Maps Applications with PHP and Ajax was written to help you take advantage of this technology in your own endeavorswhether you're an enthusiast playing for fun or a professional building for profit. This book covers version 2 of the API, including Google's new Geocoding service.
Authors Jeffrey Sambells, Cameron Turner, and Michael Purvis get rolling with examples that require hardly any code at all, but you'll quickly become acquainted with many facets of the Maps API. They demonstrate powerful methods for simultaneously plotting large data sets, creating your own map overlays, and harvesting and geocoding sets of addresses. You'll see how to set up alternative tile sets and where to access imagery to use for them. The authors even show you how to build your own geocoder from scratch, for those high-volume batch jobs.
As well as providing hands-on examples of real mapping projects, this book supplies a complete reference for the Maps API, along with the relevant aspects of JavaScript, CSS, PHP, and SQL. Visit the authors' website for additional tips and advice.
Table of Contents
Foreword | p. xv |
About the Authors | p. xix |
About the Technical Reviewer | p. xxi |
Acknowledgments | p. xxiii |
Part 1 Your First Google Maps | |
Chapter 1 Introducing Google Maps | p. 3 |
KML: Your First Map | p. 3 |
Wayfaring: Your Second Map | p. 5 |
Adding the First Point | p. 6 |
Adding the Flight Route | p. 7 |
Adding the Destination Point | p. 8 |
Adding a Driving Route | p. 9 |
What's Next? | p. 10 |
Chapter 2 Getting Started | p. 13 |
The First Map | p. 13 |
Keying Up | p. 13 |
Examining the Sample Map | p. 15 |
Specifying a New Location | p. 16 |
Separating Code from Content | p. 18 |
Cleaning Up | p. 20 |
Basic Interaction | p. 21 |
Using Map Control Widgets | p. 21 |
Creating Markers | p. 21 |
Opening Info Windows | p. 23 |
A List of Points | p. 26 |
Using Arrays and Objects | p. 26 |
Iterating | p. 28 |
Summary | p. 29 |
Chapter 3 Interacting with the User and the Server | p. 31 |
Going on a Treasure Hunt | p. 32 |
Creating the Map and Marking Points | p. 33 |
Starting the Map | p. 33 |
Listening to User Events | p. 35 |
Asking for More Information with an Info Window | p. 37 |
Creating an Info Window on the Map | p. 38 |
Embedding a Form into the Info Window | p. 39 |
Avoiding an Ambiguous State | p. 44 |
Controlling the Info Window Size | p. 46 |
Using Google's Ajax Object | p. 48 |
Saving Data with GXmlHttp | p. 49 |
Parsing the XML Document Using DOM Methods | p. 54 |
Retrieving Markers from the Server | p. 57 |
Adding Some Flair | p. 59 |
Summary | p. 62 |
Chapter 4 Geocoding Addresses | p. 63 |
Creating an XML File with the Address Data | p. 63 |
Using Geocoding Web Services | p. 65 |
Requirements for Consuming Geocoding Services | p. 66 |
The Google Maps API Geocoder | p. 67 |
The Yahoo Geocoding API | p. 75 |
Geocoder.us | p. 80 |
Geocoder.ca | p. 83 |
Services for Geocoding Addresses Outside Google's Coverage | p. 85 |
Caching Lookups | p. 86 |
Building a Store Location Map | p. 90 |
Summary | p. 93 |
Part 2 Beyond the Basics | |
Chapter 5 Manipulating Third-Party Data | p. 97 |
Using Downloadable Text Files | p. 97 |
Downloading the Database | p. 98 |
Parsing CSV Data | p. 101 |
Optimizing the Import | p. 102 |
Using Your New Database Schema | p. 106 |
Screen Scraping | p. 113 |
A Scraping Example | p. 114 |
Screen Scraping Considerations | p. 117 |
Summary | p. 118 |
Chapter 6 Improving the User Interface | p. 119 |
CSS: A Touch of Style | p. 119 |
Maximizing Your Map | p. 120 |
Adding Hovering Toolbars | p. 121 |
Creating Collapsible Side Panels | p. 124 |
Scripted Style | p. 126 |
Switching Up the Body Classes | p. 126 |
Resizing with the Power of JavaScript | p. 129 |
Populating the Side Panel | p. 131 |
Getting Side Panel Feedback | p. 134 |
Warning, Now Loading | p. 136 |
Data Point Filtering | p. 139 |
Showing and Hiding Points | p. 140 |
Discovering Groupings | p. 140 |
Creating Filter Buttons | p. 141 |
Summary | p. 143 |
Chapter 7 Optimizing and Scaling for Large Data Sets | p. 145 |
Understanding the Limitations | p. 145 |
Streamlining Server-Client Communications | p. 146 |
Optimizing Server-Side Processing | p. 148 |
Server-Side Boundary Method | p. 149 |
Server-Side Common Point Method | p. 155 |
Server-Side Clustering | p. 161 |
Custom Detail Overlay Method | p. 167 |
Custom Tile Method | p. 176 |
Optimizing the Client-Side User Experience | p. 186 |
Client-Side Boundary Method | p. 187 |
Client-Side Closest to a Common Point Method | p. 188 |
Client-Side Clustering | p. 191 |
Further Optimizations | p. 196 |
Summary | p. 198 |
Chapter 8 What's Next for the Google Maps API? | p. 199 |
Driving Directions | p. 199 |
Integrated Google Services | p. 200 |
KML Data | p. 202 |
More Data Layers | p. 202 |
Beyond the Enterprise | p. 204 |
Interface Improvements | p. 204 |
Summary | p. 205 |
Part 3 Advanced Map Features and Methods | |
Chapter 9 Advanced Tips and Tricks | p. 209 |
Debugging Maps | p. 209 |
Interacting with the Map from the API | p. 210 |
Helping You Find Your Place | p. 211 |
Force Triggering Events with GEvent | p. 212 |
Creating Your Own Events | p. 214 |
Creating Map Objects with GOverlay | p. 214 |
Choosing the Pane for the Overlay | p. 214 |
Creating a Quick Tool Tip Overlay | p. 216 |
Creating Custom Controls | p. 220 |
Creating the Control Object | p. 222 |
Creating the Container | p. 222 |
Positioning the Container | p. 222 |
Using the Control | p. 223 |
Adding Tabs to Info Windows | p. 223 |
Creating a Tabbed Info Window | p. 224 |
Gathering Info Window Information and Changing Tabs | p. 226 |
Creating a Custom Info Window | p. 226 |
Creating the Overlay Object and Containers | p. 232 |
Drawing a LittleInfoWindow | p. 232 |
Implementing Your Own Map Type, Tiles, and Projection | p. 237 |
GMapType: Gluing It Together | p. 237 |
GProjection: Locating Where Things Are | p. 238 |
GTileLayer: Viewing Images | p. 244 |
The Blue Marble Map: Putting It All Together | p. 247 |
Summary | p. 258 |
Chapter 10 Lines, Lengths, and Areas | p. 261 |
Starting Flat | p. 261 |
Lengths and Angles | p. 262 |
Areas | p. 263 |
Moving to Spheres | p. 266 |
The Great Circle | p. 266 |
Great-Circle Lengths | p. 268 |
Area on a Spherical Surface | p. 269 |
Working with Polylines | p. 274 |
Building the Polylines Demo | p. 274 |
Expanding the Polylines Demo | p. 280 |
What About UTM Coordinates? | p. 281 |
Running Afoul of the Date Line | p. 283 |
Summary | p. 284 |
Chapter 11 Advanced Geocoding Topics | p. 285 |
Where Does the Data Come From? | p. 285 |
Sample Data from Government Sources | p. 286 |
Sources of Raw GIS Data | p. 289 |
Geocoding Based on Postal Codes | p. 290 |
Grabbing the TIGER/Line by the Tail | p. 294 |
Understanding and Defining the Data | p. 295 |
Parsing and Importing the Data | p. 299 |
Building a Geocoding Service | p. 305 |
Summary | p. 311 |
Part 4 Appendixes | |
Appendix A Finding the Data You Want | p. 315 |
Knowing What to Look For: Search Tips | p. 315 |
Finding the Information | p. 315 |
Specifying Search Terms | p. 316 |
Watching for Errors | p. 316 |
The Cat Came Back: Revisiting the TIGER/Line | p. 316 |
More on Airports | p. 318 |
The Government Standard: The Geonames Data | p. 319 |
Shake, Rattle, and Roll: The NOAA Goldmine | p. 319 |
For the Space Aficionado in You | p. 321 |
Crater Impacts | p. 321 |
UFO/UAP Sightings | p. 322 |
Appendix B Google Maps API | p. 323 |
class GMap2 | p. 323 |
GMap2 Constructor | p. 323 |
GMap2 Methods | p. 324 |
class GMapOptions | p. 328 |
GMapOptions Properties | p. 328 |
enum GMapPane | p. 328 |
GMapPane Constants | p. 329 |
class GKeyboardHandler | p. 329 |
GKeyboardHandler Bindings | p. 329 |
GKeyboardHandler Constructor | p. 329 |
interface GOverlay | p. 329 |
GOverlay Constructor | p. 330 |
GOverlay Static Method | p. 330 |
GOverlay Abstract Methods | p. 330 |
class GInfoWindow | p. 330 |
GInfoWindow Methods | p. 330 |
GInfoWindow Event | p. 331 |
class GInfoWindowTab | p. 331 |
GInfoWindowTab Constructor | p. 331 |
class GInfoWindowOptions | p. 331 |
GInfoWindowOptions Properties | p. 331 |
class GMarker | p. 331 |
GMarker Constructor | p. 332 |
GMarker Methods | p. 332 |
GMarker Events | p. 332 |
class GMarkerOptions | p. 333 |
GMarkerOptions Properties | p. 333 |
class GPolyline | p. 333 |
GPolyline Constructor | p. 333 |
GPolyline Methods | p. 333 |
GPolyline Event | p. 334 |
class Glcon | p. 334 |
Glcon Constructor | p. 334 |
Glcon Constant | p. 334 |
Glcon Properties | p. 334 |
class GPoint | p. 335 |
GPoint Constructor | p. 335 |
GPoint Properties | p. 335 |
GPoint Methods | p. 335 |
class GSize | p. 335 |
GSize Constructor | p. 336 |
GSize Properties | p. 336 |
GSize Methods | p. 336 |
class GBounds | p. 336 |
GBounds Constructor | p. 336 |
GBounds Properties | p. 336 |
GBounds Methods | p. 336 |
class GLatLng | p. 337 |
GLatLng Constructor | p. 337 |
GLatLng Methods | p. 337 |
GLatLng Properties | p. 338 |
class GLatLngBounds | p. 338 |
GLatLngBounds Constructor | p. 338 |
GLatLngBounds Methods | p. 338 |
interface GControl | p. 339 |
GControl Constructor | p. 339 |
GControl Methods | p. 339 |
class GControl | p. 339 |
GControl Constructors | p. 339 |
class GControlPosition | p. 339 |
GControlPosition Constructor | p. 340 |
enum GControlAnchor | p. 340 |
GControlAnchor Constants | p. 340 |
class GMapType | p. 340 |
GMapType Constructor | p. 340 |
GMapType Methods | p. 340 |
GMapType Constants | p. 341 |
GMapType Event | p. 341 |
class GMapTypeOptions | p. 341 |
GMapTypeOptions Properties | p. 342 |
interface GTileLayer | p. 342 |
GTileLayer Constructor | p. 342 |
GTileLayer Methods | p. 342 |
GTileLayer Event | p. 343 |
class GCopyrightCollection | p. 343 |
GCopyrightCollection Constructor | p. 343 |
GCopyrightCollection Methods | p. 343 |
GCopyrightCollection Event | p. 343 |
class GCopyright | p. 343 |
GCopyright Constructor | p. 343 |
GCopyright Properties | p. 344 |
interface GProjection | p. 344 |
GProjection Methods | p. 344 |
class GMercatorProjection | p. 344 |
GMercatorProjection Constructor | p. 344 |
GMercatorProjection Methods | p. 345 |
namespace GEvent | p. 345 |
GEvent Static Methods | p. 345 |
GEvent Event | p. 346 |
class GEventListener | p. 346 |
namespace GXmlHttp | p. 346 |
GXmlHttp Static Method | p. 346 |
namespace GXml | p. 346 |
GXml Static Methods | p. 347 |
class GXslt | p. 347 |
GXslt Static Methods | p. 347 |
namespace GLog | p. 347 |
GLog Static Methods | p. 347 |
enum GGeoStatusCode | p. 347 |
GGeoStatusCode Constants | p. 348 |
class GClientGeocoder | p. 348 |
GClientGeocoder Constructor | p. 348 |
GClientGeocoder Methods | p. 348 |
class GGeocodeCache | p. 348 |
GGeocodeCache Constructor | p. 349 |
GGeocodeCache Methods | p. 349 |
class GFactualGeocodeCache | p. 349 |
GFactualGeocodeCache Constructor | p. 349 |
GFactualGeocodeCache Method | p. 349 |
Functions | p. 349 |
Index | p. 351 |