"...highly cost effective."
— Alexander Sawyer What They Say

Church Theme Content Plugin

The Church Theme Content plugin for WordPress provides compatible themes with church-related post types, taxonomies and fields. All of our themes use this plugin.

This is a developer guide. Regular users only need to install the plugin to use it with a compatible theme.

Purpose

The plugin provides functionality enabling the user to manage sermonseventspeople and locations to be displayed by a compatible theme.

Experienced WordPress developers agree that functionality like this does not belong in themes since themes are intended only for controlling the appearance of a WordPress site. Content that users might expect to take with them if they switch themes should “live” in a plugin.

Similarly, our approach is not to display content using the plugin since themes offer more control for that purpose.

Developers

The Church Theme Content plugin was made in a way that other church theme developers can take advantage of it. A couple benefits are that you will save time and be helping to accomplish better data portability among church websites powered by WordPress.

This guide assumes you have some proficiency with WordPress Theme Development or are willing to learn (here are some good resources).

Basic Usage

You can do this in your theme’s functions.php file using the after_setup_theme hook.

This will enable all post types, taxonomies and fields.

Recommended Usage

Notice the comment above says, “It is recommended to explicitly specify taxonomies and fields used by theme so plugin updates don’t reveal unsupported features.” Below is an example from one of our themes showing how to do that. This code would replace the block of code under Plugin Features above.

Field Overrides

Did you notice field_overrides above? You can use this to change how a field is presented to the user. Maybe you want to change the title or description. Here’s one example of doing so for a couple Person fields.

You can change other things like the field’s default value and whether or not it can be left empty. Look into the {feature}-fields.php files in includes/admin to see which field settings you can override.

Showing Content

Showing content is the territory of your theme. This plugin simply provides the user with a way to manage church-related content. We believe in a clear separation of functionality and presentation. Content should be theme-independent and belongs in a plugin like this. Similarly, themes are best for showing content.

Post Types, Taxonomies and Fields

You can get full details on the post types and taxonomies that the plugin registers in:

Church Theme Framework

If you’d like an extra hand in presenting content from this plugin, have a look at our Church Theme Framework. Like this plugin, you can enable many useful features with a flick of add_theme_support. Helper functions also make development quicker and easier.

Complete Example

Browse the code from one of our commercial themes for a complete example of a finished theme using this plugin.

Modifying Post Types

You may want to change the name or slug of a post type. There are filters used throughout the the Church Theme Content plugin that let you do things like this. Please see the code in includes/post-types.php.

Notice for the sermon post type the filter is ctc_post_type_sermon_args. Using that, you can change the labels, slug, etc. You can do this either with a child theme (or your own functionality plugin) so that changes are not lost during updates. Other post types have a similar filter.

Additional Notes

  • Sermon audio podcasting is built-in. When an audio URL is provided, it is used in the sermons feed as an enclosure. See Sermon Podcasting for details.
  • Events can be set to automatically recur. This is accomplished with WordPress’s scheduling feature.

Changelog

View the releases on GitHub.