Support

Account

Home Forums Gutenberg How to implement 2-column layout? Reply To: How to implement 2-column layout?

  • I would suggest building your sidebar as widget. WP recently integrated Gutenberg into the widgets aswel.

    To register a sidebar:

    if (function_exists('register_sidebar'))
    {
       // Define Sidebar Widget Area
       register_sidebar(array(
           'name' => __('Sidebar'),
           'description' => __('Sidebar voor de vervolgpagina\'s'),
           'id' => 'sidebar',
           'before_widget' => '<div id="%1$s" class="%2$s">',
           'after_widget' => '</div>',
           'before_title' => '<h3>',
           'after_title' => '</h3>'
       ));
    }

    Then implement this code in your sidebar area:
    <?php if (!function_exists('dynamic_sidebar') || !dynamic_sidebar('sidebar')) ?>