Override templates

Every template file in Rural Blog, what it does, and how to replace one from a child theme.

Copy a file from the parent theme into your child theme, keeping the same path, and WordPress loads yours instead.

wp-content/themes/rural-blog/template-parts/content.php
                     ↓ copy to
wp-content/themes/rural-blog-child/template-parts/content.php

That is the whole mechanism.

The templates

FileRenders
index.phpEvery listing: blog home, posts page, category, tag, author, date, CPT archive
single.phpA single post
page.phpA page
search.phpSearch results
404.phpNot found
comments.phpThe comment thread and form
searchform.phpThe search form
header.phpEverything to the start of the content
footer.phpThe footer, scroll-to-top and the mobile panel
template-archives.phpThe Archives page template

The template parts

FileRenders
template-parts/content.phpOne post in a listing — all three display modes
template-parts/content-single.phpThe body of a single post
template-parts/content-page.phpThe body of a page
template-parts/content-search.phpOne search result
template-parts/content-archives.phpThe Archives page body
template-parts/content-none.php“Nothing here”
template-parts/archive-header.phpThe title/description block above a listing
template-parts/author-bio.phpThe author box
template-parts/tags.phpThe tag list
template-parts/sticky-label.phpThe Pinned post label

Before you copy anything

Check there is not a setting for it. Most of what people reach for a template override to do is a Customizer control — the meta position, the display mode, whether the author box appears.

Check there is not a hook for it. Adding an ACF field to the meta row is the rural_blog_meta action, not a copy of content.php. See Hooks and filters.

Copy the smallest file that does the job. Overriding template-parts/tags.php is a file you will never have to look at again; overriding index.php is a file you now maintain against every future release.

Functions, not templates

The theme’s template tags are all wrapped in if ( ! function_exists() ), so a child theme can define its own version of one before the parent loads and the parent will step aside. rural_blog_post_meta(), rural_blog_post_thumbnail(), rural_blog_pagination(), rural_blog_site_branding() and the rest are all replaceable this way.

Define yours in the child’s functions.php — it loads first — and the parent skips its own.

This is often cleaner than copying a template: you replace one function rather than inheriting a whole file’s future changes.

Keeping up with updates

An overridden file is frozen at the version you copied. When the parent changes that file in a later release, your copy does not get the change — including bug fixes.

Note which files you have overridden and skim the changelog at each update for changes that touch them.

Last updated September 12, 2026

Something missing or out of date? Ask us and we will fix the page.