We begin with an introduction about why child themes are so important and then dig right into how to create one. In this tutorial we will create a child theme for the TwentyTwenty theme.

Download the Twenty Twenty child theme here.

Code for your functions.php file

/* child style */
function childtheme_enqueue_styles() {
wp_dequeue_style( 'twentytwenty-style' );
wp_enqueue_style( 'parent_style', get_template_directory_uri() . '/style.css' );
wp_enqueue_style( 'child-style', get_stylesheet_directory_uri() . '/style.css' , false,filemtime( get_stylesheet_directory() . '/style.css' ), 'all' );
}
add_action( 'wp_enqueue_scripts', 'childtheme_enqueue_styles', 999 );

Disclaimer: You can help support content creation. If you click some of my links, WP Explainer may get a compensation. I only partner with companies and products that I’d happily recommend to my audience.

Follow on Youtube

Follow to recieve the latest tutorials and courses

Related tutorials

Mailgun tutorial

Mailgun tutorial for beginners

Learn to setup the reliable email delivery service Mailgun with two techniques: API key and SMTP

Free WordPress Cookie Plugin – CookieYes Tutorial

Free WordPress Cookie Plugin – CookieYes Tutorial

In this tutorial you will learn to install and setup the FREE WordPress cookie plugin: CookieYes

Webtoffee GDPR Cookie Consent tutorial

Webtoffee GDPR Cookie Consent tutorial

In this tutorial you will learn to install and setup the best cookie consent plugin for WordPress: Webtoffee Cookie Consent

Polylang tutorial – Time efficient setup

In this tutorial you will learn how to quickly setup a multilanguage website using the free Polylang plugin.

The 4 step checklist for changing your WordPress website

Using these 4 steps to make changes to your WordPress website, will save valuable time.

How to install SSL on your WordPress site

How to install SSL on your WordPress site

In this quick tutorial you will learn how to get a green lock on your domains address bar by installing a Let's Encrypt certificate on your WordPress site.

Get the updates

Be the first to recieve the latest tutorials and courses.

"*" indicates required fields

This field is for validation purposes and should be left unchanged.