• Hello,
    I’m fairly new to wordpress and have been having problems with the child theme. I created a child theme but it appears on the broken themes section saying that the stylesheet is missing. How can I solve this problem?

    functions.php

    <?php

    function enqueue_parent_styles(){
    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’)
    );
    }

    add_action (‘wp_enqueue_scripts’, ‘namescript_scripts_scripts’);
    ?>

    style.css
    /*
    Theme Name: Illdy
    Theme URI: C:\xampp\htdocs\wordpress-4.7\wordpress\wp-content\themes\illdy
    Author: Colorlib
    Author URI: http://colorlib.com
    Description: Illdy is a stunning multipurpose WordPress theme built based on Bootstrap frontend framework making it fully responsive and mobile friendly. This theme is well suited for business, landing page, portfolio or any other creative websites. This leaves heavy lifting to WordPress Customizer therefore you can create your website on live preview mode. Which means that you can see changes happen on your website in real time as you make them
    Version: 1.0.35.2
    License: GNU General Public License v2 or later
    License URI: http://www.gnu.org/licenses/gpl-2.0.html
    Tags: blog, e-commerce, portfolio
    Text Domain: illdy

    @import url(“../illdy/style.css”);

    */
    #header .bottom-header .header-button-two {
    background: red !important;
    }

Viewing 9 replies - 1 through 9 (of 9 total)
  • Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    You haven’t set up the comments at the top of your Child Theme style.css file correctly.
    Replace this:

    
    /*
    Theme Name: Illdy
    Theme URI: C:\xampp\htdocs\wordpress-4.7\wordpress\wp-content\themes\illdy
    Author: Colorlib
    Author URI: http://colorlib.com
    Description: Illdy is a stunning multipurpose WordPress theme built based on Bootstrap frontend framework making it fully responsive and mobile friendly. This theme is well suited for business, landing page, portfolio or any other creative websites. This leaves heavy lifting to WordPress Customizer therefore you can create your website on live preview mode. Which means that you can see changes happen on your website in real time as you make them
    Version: 1.0.35.2
    License: GNU General Public License v2 or later
    License URI: http://www.gnu.org/licenses/gpl-2.0.html
    Tags: blog, e-commerce, portfolio
    Text Domain: illdy
    
    @import url(“../illdy/style.css”);
    
    */
    

    With this:

    
    /*
    Theme Name: illdy Child
    Template: illdy
    */
    

    is what you posted the style.css of the child theme, or of the parent theme?

    Thread Starter relicus

    (@relicus)

    I changed the child’s style.css file comments to the one you provided (Andrew Nevins). It seems like the problem is still persisting. The description says “stylesheet is missing”.

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    It sounds like you might have to post for support on your theme’s support section: https://ww.wp.xz.cn/support/theme/illdy#new-post

    Thread Starter relicus

    (@relicus)

    I decided to try it with the stock template “twentyseventeen” and I get the same results. My style.css comment for the theme is the following:

    /*
    Theme Name: twentyseventeen Child
    Template: twentyseventeen
    */

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Can you show us your website and let us know the name of your child theme folder?

    Thread Starter relicus

    (@relicus)

    Ok so I want to fix it with the twentyseventeen template just to make sure its not my illdy template. I’m currently running a localhost since I’m just learning how to use wordpress. The name of my child theme folders is “twentyseventeen-child” and it’s inside the themes folder where the parent template is at.

    Thanks for all your help so far

    you should have:

    the original parent theme folder with all files, including the style.css:

    /wp-content/themes/twentyseventeen/style.css

    the child theme folder with at least the style.css:

    /wp-content/themes/twentyseventeen-child/style.css

    this child theme style.css should have at least this content:

    /*
    Theme Name: twentyseventeen Child
    Template: twentyseventeen
    */
    Thread Starter relicus

    (@relicus)

    Thanks a lot for your help (Andrew and Michael). For some reason everything was alright but when I created the style.css with wordpad, it gave the file the extension of .txt instead of .css . I was able to make it a .css file and now everything is working properly.

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Child theme says missing stylesheet’ is closed to new replies.