Child theme and problem with path
-
I installed your “Course” theme and created my child theme to overwrite certain styles.
However, I encountered a problem because in “Course” theme you incorrectly set the path to the style.css file:functions.php, line 43:
wp_register_style( 'course-style', get_stylesheet_directory_uri() . '/style.css', array(), wp_get_theme()->get( 'Version' ) );
The get_stylesheet_directory_uri() function returns the path to my child theme:
wp-content/themes/my-child-theme/style.css?ver=1.0
You should use the get_template_directory_uri() funcion to get path to parent theme:
wp-content/themes/course/style.css?ver=1.0
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- You must be logged in to reply to this topic.