First release of my Google Maps App

octubre 16, 2007 at 5:26 pm Deja un comentario

As wordpress.com don’t let me insert any javascript or iframes here, this is an screenshot of my first release of my first Google Map App:

GoogleMaps screenshot

Here is how it works:

  • The polygon data is loaded using Dojo’s xhrPost.
  • The data is prepared on a C# WebService and formatted using JSON. The WebService serves only the polygons of the Google Map view port (using bounds.getNortEast and bounds.getSouthWest) .. and it’s not sending any data which is already sent to help a little the performance. To achive this, I used a table that “remembers” all the data already sent for a given session.
  • For every polygon received, a GMap Polygon objected is created (new GPolygon). As I am using the 2.x API version, I am attaching the “onclick” event to trigger a function to show the extended information:
     GEvent.addListener(polygon, "click", function(point) { } );
  • This triggered event calls another xhrPost for the polygon ID and retrieves another JSON string with the polygon details. This is formatted inside JavaScript and shown using openInfoWindowTabsHtml.

I have invested about 40 hours so far in this pet project. This is a “freelance” job for my ex employer.

I will add some functinalities and comment them here soon. :)

Thanks to the guys at Dojo for their excellent AJAX toolkit.

Entrada archivada en:Proyectos Mascota. Etiquetas:.

Tonatiuh Bravo El primer jalapeño de un hurón

Deja un comentario

Fill in your details below or click an icon to log in:

Logo de WordPress.com

You are commenting using your WordPress.com account. Log Out / Cambiar )

Twitter picture

You are commenting using your Twitter account. Log Out / Cambiar )

Facebook photo

You are commenting using your Facebook account. Log Out / Cambiar )

Connecting to %s

Trackback este articulo  |  Suscríbete a los comentarios vía RSS Feed


Feeds


Seguir

Get every new post delivered to your Inbox.