It’s time to open another door of the Drupal Advent Calendar! Behind today’s door we find the Events track of Drupal CMS, and we hand over to track lead Martin Anderson-Clutz to tell us some more about it.
Managing dates and times is a common need for Drupal sites, and the Drupal CMS Events recipe aims to make this easier than ever. To be clear, the intended use case is a site that posts multiple, short events. Events like Drupalcamps that comprise sessions, a schedule, and more should look at the Drupal Event Platform instead.
A Smart Date field provides an intuitive way to enter dates and times, including all day events, and more natural-language output formatting.
An event can also optionally specify a location name and address. If provided, the address will be geo-coded using the (free) Nominatim service, and displayed in a map using Leaflet. Because the Leaflet map tiles are third-party assets and can therefore have privacy implications, by default they won’t load until the user opts in to display the map, or updates their privacy settings to load third-party content.
What’s next for the Events recipe? A few ideas have been discussed: showing and managing events using an interactive calendar, Drupal-native event registration, and even a simple way to update the configuration to allow for recurring events. If you have any other ideas, please join the discussion in the #starshot channel of Drupal slack!
Existing sites not built with Drupal CMS can already add sophisticated event handling using the contrib Events recipe, which already has a rich ecosystem of companion recipes. In addition to posting and managing dates, these add-ons provide a variety of capabilities that may eventually make their way into Drupal CMS, including the ability associate reusable locations.
Martin Anderson-Clutz (mandclu) is a Senior Solutions Engineer for Acquia, and has been involved in the Drupal project for over 18 years. He maintains a lengthy list of modules and recipes. He also hosts the “Module of the Week” slot on the popular Talking Drupal podcast.
Comments