Child Theme

  • Author
    Posts
  • #4818

    rmsite
    Participant

    Hi.
    I bought the PRO version and created a kid theme for it. But the access codes do not work. And when I create partners-for example, do not work, just the parent theme. This is my functions.php:

    add_action( ‘wp_enqueue_scripts’, ‘child_enqueue_styles’,99);
    function child_enqueue_styles() {
    $parent_style = ‘parent-style’;
    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 ) );
    }
    if ( get_stylesheet() !== get_template() ) {
    add_filter( ‘pre_update_option_theme_mods_’ . get_stylesheet(), function ( $value, $old_value ) {
    update_option( ‘theme_mods_’ . get_template(), $value );
    return $old_value; // prevent update to child theme mods
    }, 10, 2 );
    add_filter( ‘pre_option_theme_mods_’ . get_stylesheet(), function ( $default ) {
    return get_option( ‘theme_mods_’ . get_template(), $default );
    } );
    }

  • #4821

    8Degree Themes
    Keymaster

    Hi there,

    Thank you for writing in.
    Please try to add the following Code:

    < ?php if ( ! function_exists( 'zincypro_child_setup' ) ) :

    function zincypro_child_setup() {

    load_child_theme_textdomain( 'zincy-pro-child', get_stylesheet_directory() . '/languages' );

    }
    endif; // zincypro_setup
    add_action( 'after_setup_theme', 'zincypro_child_setup' );

    function zincypro_child_scripts() {
    wp_enqueue_style( 'zincypro-style-parent', get_template_directory_uri().'/style.css',array('zincypro-bx-slider-style') );
    }
    add_action( 'wp_enqueue_scripts', 'zincypro_child_scripts' );

    if ( get_stylesheet() !== get_template() ) {
    add_filter( 'pre_update_option_theme_mods_' . get_stylesheet(), function ( $value, $old_value ) {
    update_option( 'theme_mods_' . get_template(), $value );
    return $old_value; // prevent update to child theme mods
    }, 10, 2 );
    add_filter( 'pre_option_theme_mods_' . get_stylesheet(), function ( $default ) {
    return get_option( 'theme_mods_' . get_template(), $default );
    } );
    }

    Thank you!!

  • #4822

    rmsite
    Participant

    Hi, please it´s my functions.php:

    <?php
    add_action( ‘wp_enqueue_scripts’, ‘child_enqueue_styles’,99);
    function child_enqueue_styles() {
    $parent_style = ‘parent-style’;
    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 ) );
    }

    if ( ! function_exists( ‘zincypro_child_setup’ ) ) :

    function zincypro_child_setup() {

    load_child_theme_textdomain( ‘zincy-pro-child’, get_stylesheet_directory() . ‘/languages’ );

    }

    endif; // zincypro_setup

    add_action( ‘after_setup_theme’, ‘zincypro_child_setup’ );

    function zincypro_child_scripts() {

    wp_enqueue_style( ‘zincypro-style-parent’, get_template_directory_uri().’/style.css’,array(‘zincypro-bx-slider-style’) );

    }

    add_action( ‘wp_enqueue_scripts’, ‘zincypro_child_scripts’ );

    if ( get_stylesheet() !== get_template() ) {
    add_filter( ‘pre_update_option_theme_mods_’ . get_stylesheet(), function ( $value, $old_value ) {
    update_option( ‘theme_mods_’ . get_template(), $value );
    return $old_value; // prevent update to child theme mods
    }, 10, 2 );
    add_filter( ‘pre_option_theme_mods_’ . get_stylesheet(), function ( $default ) {
    return get_option( ‘theme_mods_’ . get_template(), $default );
    } );
    }

  • #4823

    rmsite
    Participant

    I don´t have a languages folder on child theme!

  • #4868

    8Degree Themes
    Keymaster

    Hello There,

    Did you get this to working? If not please let me know I will try to help you out.

    Thanks!

  • #4873

    rmsite
    Participant

    The problem has been solved with the code. Thank you.

You must be logged in to reply to this topic.

Our New Release - Eight Degree Pro

Eight Degree Pro is a flexible WordPress theme with modern and mobile friendly design. This multipurpose WP template is suitable for building any kind of websites from blogs and portfolios to businesses. It comes with 3 predesigned demos with one click demo import features. Simply import the demo data and start customizing.

We've Launch offer 40% discount to our exclusive clients like you! Use coupon code customer during checkout. Get the theme only for $33 now (only for few days!)

Click on the below image for more detail.

Eight Degree Pro  WordPress Corporate Business Premium Theme

Please post your questions in the respective forum above.

All questions related to our Pro theme will be answered in less than 24 hours. All questions related to our Free theme will be answered in less than 48 hours.
Our Facebook page is the best place to get updated with themes, documentation, question/answers. Please like us here: