Barry Hughes WordPress Developer

Bolting new views on to The Events Calendar

6 December 2017 (updated 6 December 2017)

The Events Calendar is a useful calendaring plugin for WordPress providing a number of default views (list, month and day views) through which visitors can browse published events.

Sometimes those default views are all you need — they are well crafted and look great out of the box in most cases. Other times, in order to make those calendar views really mesh with the active theme (or with other facets of a project), some stylistic changes may need to be made via custom CSS or by altering the HTML output.

That’s great and the process for doing so is pretty well documented, but an alternative approach I wanted to explore was to take an existing view and use it as the foundation for an entirely new view with a look and feel all of its own. In other words, instead of customizing list view (for example) I wanted to leave it as it is and simply use it as the foundation for a new view that would run side-by-side with it and act in a very similar way, but look quite different .

I took this idea and ran with it a little and the work so far can be found in this repo. It’s pretty basic and won’t win any medals, but setting some shortcomings aside it does show how remarkably simple it is to take list view, repackage it as a new type of grid view with some trivial CSS and then have that new “grid view” in place and running alongside the original list view.

This is just an experiment at this point and there are a number of wrinkles making it unsuitable for production use, but it should be a fun thing to hack on and already provides a mostly working extra view for minimal cost/overhead.

🖇 WordPress Dev | MT plugins | The Events Calendar