Show vehicle positions with the Google Maps v3 API

Most people are already familiar with Google Maps, so why not utilise that to present your business data to your users. Today I am going to show you how to use the Google Maps API to track vehicles using their AVL data. This is something I have done for the Fire Service to show the location of Fire Engines across the county.
For this we are going to need the following:
  • JQuery
  • The Google Maps JavaScript API
  • A page that displays the google map
  • Some JavaScript to pull the vehicle locations
  • A PHP Script to serve the vehicle locations
  • A way to generate dynamic icons

Generating Dynamic Icons for Google Maps with PHP

Google Maps provides a standard Marker marker image that looks like this and whilst I do not intend to offend Ji Lee, this icon can be replaced with an image of your choice. By using PHP to create an image dynamically on the fly you can have images that provide much more information.

Read more

Categories PHP

My Singleton

If you have not come across design patterns, they are well worth reading up on. There is a great overview for PHP developers at IBM.

Read more

Categories PHP