Written by on

Block Updates and Using Custom Templates with Blocks

I know you are all focused on the release of BackupBuddy 3.0 on Wednesday; however, I do not want our Builder users to miss out on the updated Church Block (announced Monday). There were no major (salute) changes to core functionality of the block itself, but we did add the ability to use the block with any Builder Child Theme (cool, I know).

I know what you are thinking: “This block is awesome, but how much will it cost me now that I can use it with any child theme?” How about $1,000,000 (queue Dr. Evil laughter)? We all know that’s a joke right? Okay, just checking.

This block technically does not cost you anything at all, assuming you are a licensed Builder user. If not, you will need to purchase Builder or a Builder Child Theme. This goes for all our blocks (currently Church, Events and Restaurant – more coming soon).

Enough with the nonsense, here’s what you came for.

Custom Templates

By making the Church Block usable with any theme, we have to cut a few custom styles that you find on City Church; thus, making the block a little more generic in nature. Although this gives us the ability to use the block with any child theme, it does make the customization look, well… nonexistent.

Thanks to WordPress (and our forward thinking) there is a way to add your own custom templates to your theme, overriding the default templates provided by the block. The best way to do this is simply open up your preferred FTP, duplicate/copy the block’s template files and drop them into your theme.

Note: Always copy the files and never move them. They will act as a fallback if for some reason your template files are erased.

Here is where a good knowledge how WordPress handles custom post types and their templates. Essentially, you will need to name the template files based on the view (single or archive) that you desire and attach the name of the post type to the end. This works perfect for the Church Block because they are already named correctly. However, you would need to rename the file(s) accordingly in order for the post type template to work properly.

Now all you have to do is rearrange the items (title, date, content, et cetera) however you like and you have yourself a custom template for the block. Once you have the content arranged, you can add your own CSS to put your pretty touch on your new content layout.

Simple right?

If you have any other questions, let’s discuss them below.



Sale Ends Today! Save 35% OFF BackupBuddy Get the coupon