Archive for the ‘thydzikGoogleMap’ Category

Karratha Geocaches (Pilbara, Western Australia)

Tuesday, April 15th, 2008

From time to time I would like to share some of my Australian travels. It doesn’t really fit in technology or projects. Karratha is 1535km north of Perth, Western Australia.

The XML for the map below was made with RoboGEO, which synchronises GPS data with photographs using the timestamp. The XML map data was then displayed as a Google map using my WordPress plugin thydzikGoogleMap.

One of the features of thydzikGoogleMap is the ability to show XML Google maps, while maintaining the internal links to photographs.

thydzikGoogleMap v1.1

Thursday, April 10th, 2008

thydzikGoogleMap v1.1 has been released with major updates:

  • cross-domain XML files can be used as the map data, see example below.
  • due to WordPress plugin repository automatically zipping plugins, the main plugin folder is changed. Anyone upgrading from v1.0, requires deletion of old folder.
  • Lots of code improvements, was a bug with displaying the default marker style.
  • Works with RoboGeo produced XML files.

The below example shows cross-domain support, I am using the XML file found in my second blog

http://sonyaandtravis.com/../china2007.xml

Download here

thydzikGoogleMap – an inline Google map plugin for WordPress

Friday, January 18th, 2008

thydzikGoogleMap is a WordPress plugin that creates inline Google maps in your WordPress posts. There are two main advantages over other existing Google maps plugins and they are:

  1. Ease of use, to create a Google map simply type thydzikGoogleMap(mapdata.xml, 600, 480) in your post on its own line.
  2. thydzikGoogleMap uses XML map data, this allows for maximum configurability, and supports multiple points and lines.

Please note, this is my first attempt at any ‘real’ php coding and my first attempt at creating a WordPress plugin. I am pretty sure I have not coded things optimally, the main thing is it does work. I have tried to minimise the return of errors and the plugin not working. Comments welcome on any suggestions or bugs.

Few notes:

  • a markers folder is included with numbered pointers, these are used only when icon=”x” (where x is an integer), if this is excluded or pointers are alphabetical default Googles pointers will be used.
  • if width and height is excluded, the default width and height (460 and 345 respectively), found in the configuration page will be used.
  • thydzikGoogleMap automatically centres and zooms in on the points and lines, this may not always give the best results.
  • thydzikGoogleMap will produce a Google map only if the XML file is found, this was made so that examples i.e. thydzikGoogleMap(mapdata.xml) could be posted without producing a Google map.
  • thydzikGoogleMap searches post text using the_content and replaces valid thydzikGoogleMap with HTML and Javascript to produce a Google map. This might not be the best way to achieve this.
  • Only 1 Google map per post with be converted, however, multiple maps can exist when multiple posts are displayed.
  • thydzikGoogleMap produces valid XHTML.
  • thydzikGoogleMap has only been tested on the default Kubrick theme, WordPress version 2.3.2.

Download thydzikGoogleMap