• CustomX

    (@customx)


    Hello,

    I am using the Optimizer theme and created a child theme to make 2 changes in the style.css. The .single_wrap adjustment works fine, but the page_head is ignored. When I use Inspect Element on Google Chrome I can tell the parent style.css overides the child style.css for this part. Page_head is the title banner on my pages. Anyone know what’s up?

    Tom

    style.css

    /*
     Theme Name:   optimizer_child
     Template:     optimizer
    */
    
    /* =Theme customization starts here
    -------------------------------------------------------------- */
    .single_wrap {
      margin-left: auto;
      margin-right: auto;
      float: none;
    }
    
    .page_head {
      min-height: 100px;
    }

    functions.php

    <?php
    
    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' );
    }

    Website: http://www.gelnagels-gina.be

  • The topic ‘Child theme style.css is ignored’ is closed to new replies.