GeoRSS to KML through Drupal

I was working at the end of last week on pulling GeoRSS-enabled feeds into Drupal and attaching the location information for each item to the nodes created from each item. Once it's within the flexible world of Drupal, all the benefits of having attached geodata then apply.

With the number of GeoRSS enabled feeds around the world slowly growing, the opportunity to make your own geospatial mashup machine (borrowing the name slightly from Zacker's Drupal Mashup Machine screencast) is now here.

Much of the functionality was already there in contributed modules - aggregator2 module to pull in feeds (not sure what's going to happen to this module in the future) and location module to store location data for nodes. Then my recently released KML module can feed all of this information back out in different ways (eg by tags assigned to the incoming feeds), GMap module can display them on top of Google Maps.

The only part that was missing was the bit to pull geodata from the incoming RSS feeds, based on the GeoRSS standards, of which Version 1 was released last week. To do this I created a little module (GeoRSS module) that tied aggregator2 module and the location API together.

The functionality here overlaps slightly with the location module in that it already inserted geographic information into RSS feeds being sent out by Drupal, but I prefer to use the module as an API to store the information and then extend it in other ways. In the future the GeoRSS module could be extended to deal with more complex geodata than simple points, being able to cope with lines and areas as well if that time comes along and people have that need.