If you would like to talk about your project call (02) 4474 5861

What is a Child Theme

A WordPress child theme is dependant upon a having another WordPress theme (parent) installed on your site. The child theme (activated in the theme area of WordPress) then uses the core of the functionality and layout of the parent theme.

Identify your theme as a child theme

The minimal files you will need for your child theme is a CSS file called style.css and a functions.php (note functions.php is necessary to enqueue styles correctly, will follow below as stated in codex). The following code (at minimum, will need text in bold) needs to be placed into the start / head section of the style.css file to begin to identify the theme as a child one.

Theme Name: My Child Theme
Theme URI: http://example.com/my-child-theme/
Description: My Child Theme - Custom theme built of Parent Theme
Author: Bjarni Wark
Author URI: http://example.com
Template: ParentTheme
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: responsive-layout, accessibility-ready, 2-column
Text Domain: my-child-theme

Enqueue the parent and child theme stylesheets

The following code makes sure the that parent themes style.css file loads first and then will load the child theme style.css file. Also note that this is only for parent themes that use the one css file called “style.css”.

add_action( 'wp_enqueue_scripts', 'theme_enqueue_styles' );
function theme_enqueue_styles() {
wp_enqueue_style( 'parent-style', get_template_directory_uri() . '/style.css' );

Instinctively creative & thoughtful strategies with result orientated outcomes

Visually communicating effectively with your potential & current customers adds to the good business experience.

BJ2DESIGN combines a wealth of design knowledge with creative business strategies to create result oriented work.

Read More About BJ2DESIGN

creative hand and tools