Child Theme Style Issues

ZT Started by Zoe Turton · September 24, 2019 at 7:34 pm · 3 replies 1 voice Last reply 6 years, 9 months ago
ZT
Zoe Turton Original poster Member
#1

I’ve created a child theme but it’s not handling styles correctly, and there are a couple weird things about it.

1. I would expect to need to enqueue the KrystalPro parent styles in my child theme’s functions.php file, but the parent styles load with just the style.css plus an empty functions.php
2. The custom CSS I have in my child theme’s style.css don’t seem to be getting enqueued, though the style.css file is definitely loading because when I empty it out to test, the page load results in the error that it should.

Searching around online indicates that this may be an issue with the way the parent them handles style dependencies – do you know if there’s a special theme-specific way I need to be enqueuing my styles, or if there’s a known bug or workaround, or anything like that?

My style.css just has this:
/*
Theme Name: KrystalPro Child
Template: krystalpro
*/
.example-css-class .for-spiraclethemes-post {
text-align: center
}

And my functions.php is only loading custom widgets:
<?php
require get_stylesheet_directory() . ‘/inc/widgets.php’;

And again, with the above style and functions files, it does load the parent styles but doesn’t accept my customizations.

Post a reply

Join the conversation. Be kind — this is a public forum.

Replying to Child Theme Style Issues

By posting, your reply becomes public (unless marked private).