Skip to content

Instantly share code, notes, and snippets.

@jacobarriola
Created November 7, 2014 21:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jacobarriola/f680f5a1ffef9d69ced7 to your computer and use it in GitHub Desktop.
Save jacobarriola/f680f5a1ffef9d69ced7 to your computer and use it in GitHub Desktop.
Snippet for loading parent stylesheet in WordPress when creating child theme. Sits in functions.php of child directory.
<?php
// Load parent style sheet
add_action( 'wp_enqueue_scripts', 'enqueue_parent_theme_style' );
function enqueue_parent_theme_style() {
wp_enqueue_style( 'parent-style', get_template_directory_uri().'/style.css' );
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment