Two more new toys for the blog

The uber-geekiness came through this weekend as I finally finished the two little geek projects that I have been trying to find time to do. First, the weather for Buffalo is now delivered to this page by my weather plugin, and second is the introduction of the Buffalo snow-meter. You may think it is a bit early for that, but in Buffalo, it is not uncommon for Halloween snow.


As for my weather plugin, I wrote it from scratch because all the other plug-ins out there used the old NOAA METAR data. The data is accurate, but it was designed back in the day when bandwidth was precious and everything is transmitted using codes, which need to be known by the consumer.

NOAA has been delivering weather data via XML for about 2 years now so I rewrote the plugin to use that stream. There is alot less client side processing and more customization so I’ll take this moment to pat myself on the back.

The snow-meter uses some clumsy data that NOAA provides that looks alot like a spreadsheet export. The text file they provide is almost 1.5 MB and requires alot of parsing to get the data. We’ll see if global warming will bring more snow, or just more slush.

2 Responses to “Two more new toys for the blog”

  1. Sean McKendall Says:

    I thought I’d try your weather plugin, but I’m having a little trouble. After configuring the php file and testing it out, I get the following error: “Fatal error: Call to a member function on a non-object in d:\webroot\weather.php on line 177″. This line of code is “$wpdb->query($query);”. I’m guessing that has to do with WordPress. Not being *that* familiar with PHP, is there any way I can change your plugin to work without using WordPress? If not, no big deal at all. Just thought I’d give it a try.

  2. Administrator Says:

    Sean, I’ll be putting together another version that will be more generic. The WordPress framework provides alot of DB management, and query functions that make development really easy, so I may just copy off there stuff to begin with.

Leave a Reply