• Not sure if anyone has done this before, but I’m pretty new to PHP and WordPress so figured I’d create my first plugin as a little excersise for my girlfriend’s WordPress blog.

    You can see an example of it here : http://www.jenniferlondin.com/blog

    Basically it adds a clock to your site, which you can adjust the timezone for depending on where you live.

    It adds an additional administration panel under options in which you can set your time zone, and a location ( if you wish ) of where you are, and this then stores those as values into a pre-created(*) table in your wp_database, then simply renders it out to screen passing those variables back for use anywhere in your blog templates.

    It’s very bespoke for my girlfriend but wouldn’t take much to hack it for your own needs .

    (*) NOTE : The table needs to be created first in order for this to work. I wasn’t sure how to script that so I manually created it with MySQL administration. I’ve added the necessary MySQL script in the comments on this plugin.

    The clock graphic is provided by http://www.worldtimeserver.com/

    See what you think, not sure if it’s of use, but that I’d offer it out there incase 😀

    Download it here :

    http://www.tonycollings.com/downloads/whereami.php

    Upload to your plugins directory & activate. ( Make sure you created the database first ! or you’ll get lots of nice INSERT and UPDATE errors 😀 )

Viewing 1 replies (of 1 total)
  • Thread Starter tonycollings

    (@tonycollings)

    I’ve noticed the download link above doesn’t work ( it tries to compile and run the script ), so I’ve added an archive here

    http://www.tonycollings.com/downloads/whereami.zip

    UPDATE: I’ve added a bit more functionality. I’ve taken the value’s you enter into the location field and render out links to Google Earth™ and Google Maps™ ( it works a treat ). There is also an option to remove the links in case the location you specify cannot be found on Google Earth™ / Google Maps™. I figured I’d put this in so that people had the option to either add the links or not.

    Handy if Google Earth™ / Google Maps™ cannot find your location

Viewing 1 replies (of 1 total)

The topic ‘Download my World Clock Plugin’ is closed to new replies.