katstar01
8/25/2016 - 8:23 PM

function for loading parent stylesheet in a child theme https://codex.wordpress.org/Child_Themes

function for loading parent stylesheet in a child theme

https://codex.wordpress.org/Child_Themes

<?php

function child_enqueue_styles() {
      $parent_style = 'parent-style'; 

    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', 'child_enqueue_styles' );