• Hi Everyone,

    first thanks to the developers for this great theme. I just started working with it a little bit ago and so far really like it.

    There is one thing I’m having a bit of trouble with at the moment and thats how to properly include the child themes ‘responsive.css’ – afte the parent themes responsive.css.

    I created a child theme in the folder ‘accesspress-lite-child’ (all according to wordpress instructions) and in my
    functions.php
    i have tried it like this:

    function theme_enqueue_styles() {
        wp_enqueue_style( 'parent-style', get_template_directory_uri() . '/style.css' );
    
    	  wp_enqueue_style( 'parent-responsive', get_template_directory_uri() . '/css/responsive.css' );
    
        wp_enqueue_style( 'child-responsive', get_stylesheet_directory_uri() . '/css/responsive.css',  array( 'parent-responsive'));
    }
    
    add_action( 'wp_enqueue_scripts', 'theme_enqueue_styles' );

    This doesnt work completely – I now load the parent responsive css file twice – once with the id ‘parent-responsive’, then my css is loaded and at the end as the last .css file this one is loaded:
    <link rel=’stylesheet’ id=’accesspresslite-responsive-css’ href=’https://dev.myurl.com/wp-content/themes/accesspress-lite/css/responsive.css?ver=4.3.1&#8242; type=’text/css’ media=’all’ />

    How can do I load my responsive css after this one?

    Thanks for any ideas!

Viewing 1 replies (of 1 total)
  • Thread Starter MrSlartibartfast

    (@mrslartibartfast)

    Nobody has an idea?

    I’m doing this different at the moment:
    Adding responsive styles with their media queries to the style.css of the child theme.

    That works and overrules the styles from the accesspress-lite responsive.css

    In any case, I would like make a nicer solution and load the ‘child’ responsive.css after the themes responsive.css.

    Please let me know if you have an idea how to that.

    Cheers!

Viewing 1 replies (of 1 total)
  • The topic ‘Enque reponsive child style for mobile display’ is closed to new replies.