Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • #242703


    1. Child Theme
    I installed and activated the Enfold Child Theme ( with Enfold v 2.6.2 as the parent theme. In the child theme, I imported the parent theme’s settings – however, the entire site design & css breaks. Also, the child theme changes the selected menus which were set for the main navigation. Do you have a child theme compatible with the latest Enfold version?

    2. Changing the Layout of the Sidebar to 2 units
    Also — what I am trying to achieve is to make the left side bar on pages smaller (*two* columns instead of *three*). So what I need to do is edit the template code so that the aside class says ‘two’ instead of ‘three’:

    <aside class="sidebar sidebar_left smartphones_sidebar_active three alpha units" role="complementary" itemscope="itemscope" itemtype="">...</aside>

    and change <div class="template-page content nine units">...</div> to say *ten* instead of *nine*.

    What is the best way to achieve this whilst maintaining compatibility with all future auto-updates?

    • This topic was modified 5 months ago by  gorans. Reason: cleaning up formatting

    Hi gorans!

    1) Any child theme set up as a child of enfold is compatible though when importing in the parent theme settings you may need to tweak things a bit. At the very least go into the styling options and re-save your settings and then the same in your WordPress menus manager.

    2) The functions.php has the settings for the layouts on lines 141-144. You can copy and past theme into your child theme to overwrite the data.



    Thanks Devin

    1) worked — I had the redo the menus and now everything appears the same.

    2) The layout override I’m having issues with. Because the Child functions.php is loaded before the parent’s file, it means that when I override the line:
    $avia_config['layout']['sidebar_left'] = array('content' => 'nine', 'sidebar' => 'three alpha' ,'meta' => 'two alpha', 'entry' => 'nine'); to have my settings, it is again overwritten by the parent theme’s function.php.

    I don’t want to have to copy & paste all the functions.php file from the parent into the child because then any updates to the parent won’t go through to the child theme. Is there a nicer ‘DRY’ way to do this? Ideally the parent functions.php should check to determine if that variable is set before setting the defaults.



    By way of update. I figured out how to achieve item (2)

    In the child theme’s function.php I added the following:

    function change_sidebar_left_layout() {
        global $avia_config;
        $avia_config['layout']['sidebar_left'] = array('content' => 'ten', 'sidebar' => 'two alpha' ,'meta' => 'two alpha', 'entry' => 'eight');
    add_action('init', 'change_sidebar_left_layout');

    Please let me know if that is the correct way to do it.



    That is a great way to do it yes.

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.