module

Location services integration for Activity Stream

I was working the other night to create an integration module that would tie the existing Activity Stream module for Drupal into the Brightkite location-based social network.

The idea is that users can check in at their current location using Brightkite and have their Drupal site update their location within the site based on their last known location - handy if you want a little map that shows where you are, for example, but you could do whatever you wanted with those locations, and even use them to extend a social network you might be building up in Drupal.

While I was fighting with the SimplePie feed parsing library to work out why it didn't like the feeds from Brightkite, John McKerrell suggested that some integration for his new Mapme.at service would be nice too.

So, the first two services to be supported by the new Activity Stream location services project are Brightkite and Mapme.at. I'd also like to extend this to other services like Yahoo's Fire Eagle and Google Latitude at some point, but neither of them are quite so simple to integrate with, the former because it has no public location feeds for users and requires authentication, and the latter because it doesn't share any of its data at all (boo!).

In their most basic form, the modules pull in the updates from these services and they get included in your activity stream along with your Twitter updates and the like, but also if you have Location module installed and the user locations module enabled (plus a patch for Activity Stream for now), your user will be updated with the latest coordinates from the location service you use.

Categories: Geographic Drupal

Availability calendars for Drupal

Back at the start of the year when I was building a website for some self-catering cottages on the Isle of Man, I needed to replace some availability calendar functionality that I'd originally coded for the site back in 2000 or so.

As I was moving the site to Drupal, the availability calendar solution really needed to be something that was fully integrated as a Drupal module. I had checked out a couple of modules and the two that I found (Availability and OpenResort) didn't really do what I was looking for, so I went about customising the Availability module to do what I wanted.

Preview of Availability Calendars module for Drupal

Soon enough, the module had changed shape quite considerably, so it didn't feel like it would fit back into the original module. After about six months of running the module, the new Availability Calendars module got released back to the community last night.

If you run a small accommodation provider business (like a self-catering cottage, a bed and breakfast, a guesthouse, etc.) and are using Drupal to power your site, you might find this module quite useful. It will allow you to show an availability calendar for each node of a certain type (e.g. cottages, rooms, etc.), change the availability for each day, and also leave a note (such as a rental price) next to each week.

If you have any issues with the module or would like to request new features, please add a comment to the issue queue.

Categories: Drupal

Furthering the OpenStreetMap module

Having started implementing a Drupal module for OpenStreetMap back in October I have spent a few hours here and there on pushing it forwards. Here's a quick update.

The module is at a stage now where you can download data for a specific region from OpenStreetMap, parse it, filter it by certain tags (and their values, if desired) and then create basic location-enabled Drupal nodes based on the results. Because it ties into the existing location module any other modules which rely on the location API can begin to use these new OpenStreetMap nodes, for example by plotting them on a map, by making the information available through RSS feeds or by displaying them in Google Earth.

I also started working on an OpenLayers module, and at work have been putting effort into improving the MapBuilder module that Nedjo Rogers started a year or so ago. Both of these modules will allow us to reduce dependence in Drupal on commercial mapping providers, instead moving towards using data from other, standards compliant, sources.

Assuming there aren't too many distractions over the coming week or so, I hope to have at least an alpha-quality OpenStreetMap module available soon. Phase one of the module will simply be allowing site admins to keep their local information site up-to-date with geodata from OpenStreetMap. Future phases will almost certainly allow for editing of data and the publishing of that back to the OpenStreetMap project.

Categories: Geographic Drupal
Syndicate content