A child theme, in WordPress, according to the definition in the Codex, is
…a theme that inherits the functionality and styling of another theme
Creating a child theme is the recommended way to change the appearance of your theme.
These are the basic instructions to create a child theme for the Twenty Sixteen theme:
- create the directory wp-content/themes/twentysixteen-child
- create the file style.css inside the dir, containing the following lines
12345678910111213/** Theme Name: Twenty Sixteen* Theme URI:* Author: FC* Author URI:* Description: Twenty Sixteen child theme* Template: twentysixteen* Version: 1.0* License: GNU General Public License v2 or later* License URI: http://www.gnu.org/licenses/gpl-2.0.html* Tags: one-column, two-columns, right-sidebar, accessibility-ready, custom-background, custom-colors, custom-header, custom-menu, editor-style, featured-images, flexible-header, microformats, post-formats, rtl-language-support, sticky-post, threaded-comments, translation-ready, blog* Text Domain: twentysixteen-child*/ - replace the author in the Author line with your name
- create the file functions.php inside the twentysixteen-child dir, containing the following lines
123456789101112131415<?phpfunction my_theme_enqueue_styles() {$parent_style = 'twentysixteen-style'; // This is 'twentyfifteen-style' for the Twenty Fifteen theme.wp_enqueue_style( $parent_style, get_template_directory_uri() . '/style.css' );wp_enqueue_style( 'child-style',get_stylesheet_directory_uri() . '/style.css',array( $parent_style ),wp_get_theme()->get('Version'));}add_action( 'wp_enqueue_scripts', 'my_theme_enqueue_styles' );?> - Go to WordPress Administration->Appearance->Themes, and activate your new TwentySixteen-child theme.
- If you have modified any theme option, you may have to re-save it.
- All done.
Further details, as creating a child theme from an already modified parent theme, can be found in the Codex