Customization

Child Themes

August 17, 2026 1 min read

Edit template files through a child theme. Editing Consulting Company directly means losing your work the next time the theme updates.

Creating one

Create /wp-content/themes/consulting-company-child/ containing a single style.css:

/*
Theme Name: Consulting Company Child
Template: consulting-company
Version: 1.0
*/

The Template: line must read exactly consulting-company — that is what links the child to the parent.

Then add functions.php to load both stylesheets:

<?php
add_action( 'wp_enqueue_scripts', function () {
    wp_enqueue_style( 'consulting-company-parent', get_template_directory_uri() . '/style.css' );
    wp_enqueue_style(
        'consulting-company-child',
        get_stylesheet_uri(),
        array( 'consulting-company-parent' ),
        wp_get_theme()->get( 'Version' )
    );
} );

Activate the child under Appearance → Themes. Customizer settings are stored per theme, so you will need to set them again after switching.

Overriding a template

Copy the file from the parent into the child, keeping the same path — for example template-parts/frontpage.php — and edit the copy. WordPress uses the child’s version.

Leave a comment