Unable to load child theme style.css - by Fusion01

This topic has 11 replies, 2 voices, and was last updated 4 years, 8 months ago ago by Olga Barlow

  • Avatar: Fusion01
    Fusion01
    Participant
    September 29, 2020 at 11:06

    Serious issues here, the file is not being enqueued, I’ve done a clean install and still no joy. I’ve been in WP dev for 7 yrs now and this is a first without any solution and taken a day out of my life. Disabled all plugins, changed the enqueue code but nothing makes this CSS file load on the front-end, nothing! New child theme folder generated / new demo install / required core and plugins loaded… WTF?!!!

    // enqueue styles for child theme
    function example_enqueue_styles() {

    // enqueue parent styles
    wp_enqueue_style(‘parent-theme’, get_template_directory_uri() .’/style.css’);

    }
    add_action(‘wp_enqueue_scripts’, ‘example_enqueue_styles’);

    Please, contact administrator
    for this information.
    10 Answers
    Avatar: Olga Barlow
    Olga Barlow
    Participant
    September 29, 2020 at 17:06

    Hello,

    If you need XStore child theme you can download it here https://www.8theme.com/downloads
    Download it and check the code in the functions.php file to call parent theme styles correctly.

    Regards

    Avatar: Fusion01
    Fusion01
    Participant
    September 29, 2020 at 17:25

    I have this DEFAULT code in the child theme’s functions.php file yet the file is not being loaded on the front-end, in spite of the child theme loaded in rthe WP back-end (Appearance) without any fault. Theme states child theme V.1 in the config options.

    Avatar: Fusion01
    Fusion01
    Participant
    September 29, 2020 at 17:25
    <?php
    
    add_action( 'wp_enqueue_scripts', 'theme_enqueue_styles' );
    function theme_enqueue_styles() {
    	etheme_child_styles();
    }
    Avatar: Olga Barlow
    Olga Barlow
    Participant
    September 29, 2020 at 17:45

    Hello,

    That’s strange. Do you have any server cache or CDN?
    Could you, please, provide us with FTP access to your site to check the issue in more detail?

    Regards

    Avatar: Fusion01
    Fusion01
    Participant
    September 29, 2020 at 17:46
    /*
     Theme Name:   Thusana
     Theme URI:    https://www.8theme.com/
     Description:  XStore Child Theme
     Author:       8theme
     Author URI:   https://www.8theme.com
     Template:     xstore
     Version:      1.0
     Text Domain:  xstore-child
    */

    ALL DEFAULT IN STYLE.CSS (child theme). Style.css will not load.

    Avatar: Fusion01
    Fusion01
    Participant
    September 29, 2020 at 17:48

    I have, private login details supplied in first post.

    NO CDN. All caching is set to off until site dev is complete. No server ZIP / GZIP etc yet set.

    Avatar: Olga Barlow
    Olga Barlow
    Participant
    September 29, 2020 at 17:53

    Hello,

    You used the file generator http://prntscr.com/uq2k87 that combined all the styles to 1 file. It was the reason that you did not see the child theme styles as a separate file.
    Check now.

    Regards

    Avatar: Fusion01
    Fusion01
    Participant
    September 29, 2020 at 18:10

    OK now that fixed it, sorry this is a pile of poo. This shouldn’t happen. I’ve lost endless time and frustration to this. Why with combine do the custom styles not get applied?! This is an issue you should admit requires fixing.

    Avatar: Fusion01
    Fusion01
    Participant
    September 29, 2020 at 18:12

    Irrespective thery should still be *applied*, this was not the case.

    Avatar: Olga Barlow
    Olga Barlow
    Participant
    September 30, 2020 at 07:14

    Hello,

    Issue with file generation will be fixed in next theme update. So, just don’t generate the file till the next update. Remove the generated file if you have already generated this.

    Regards

  • Viewing 11 results - 1 through 11 (of 11 total)

The issue related to '‘Unable to load child theme style.css’' has been successfully resolved, and the topic is now closed for further responses

Helpful Topics

We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.