owen

On the #wordpress channel on IRC, someone had requested some adjustments to the Countdown plugin that I wrote a while back, so I took a look at that project and decided to make a few small updates.

Countdown displays a list of dates to remember. You create a list of events, and Countdown outputs those events on your blog. The events can recur, so you can put in single dates like “06-04 Owen’s Birthday (Observed)” and it will show that on the same day every year.

There are some more complex recurring settings, too, like the ever helpful:

1st sun apr Daylight Savings Starts

Note that this event recurs on the first Sunday of every April.

Previous users will recognize these settings from before, but I have added a few new little things to sweten up the plugin.

On small thing is a new set of date modifiers. You can now say:

2 days before 10-25

or:

the mon after 08-02

Which is especially useful when using it with the new Easter date:

the fri before easter Good Friday

But those are just the new date settings. In addition to those, there is a whole new administration panel for setting Countdown options.

On the configuration page, you can set the output format for events and dates, and also edit the event list.

Using the new formatting options, you could (for example) output the date as part of an image URL, and display a graphic instead of just the date. Or you could feed the date to some javascript code (that you create) to have it render your dates specially based on criteria of your choosing.

You can also use the formatting to change the dates for your locale, which was a big requested feature. You’re no longer locked into the format provided with Countdown, and can now specify your own format using the PHP date() format characters.

One more interesting thing on the new admin panel is the “Add Event” form. It helps you create new events for the event list without having to remember the formatting. (Was it really that hard to learn, anyway?) Not all of the options are available there, but the most used ones are. Everything else is written up in the documentation on RedAlt.

Finally, the plugin has included support for the beta of Matt Read’s Installer plugin. The Installer lets you install plugins directly from their zip files, and manages their files. You can easily remove plugins that you’ve installed with the Installer plugin.

Also - the main reason why I bring this up - the Installer will tell you if there are updates available for your plugins, and will automatically download and install them on a button click. Only plugins that include certain headers can provide this facility, and I have added these headers to Countdown. (This may be added to all of my plugins, assuming this format becomes well-accepted.)

If you’re a plugin developer, you may want to check out the Installer and see about adding those headers to your own plugins. And instead of fretting about how to host an XMLRPC server to transmit your updates, check out the RedAlt Plugin Version Service, which can handle all that for you.

Note that the Installer and the Plugin Version Service are still young, some in Beta, and while they seem to be mostly working, there’s still room for improvement. Feedback will be appreciated.