• How would I be able to add at least 1 more widget area on front page to insert another content category. Example would be to duplicate Front Page: Content Middle Left/Right Section?

    Thanks in advance!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Add the below code on widgets.php below the function function colormag_widgets_init() line number 14

    register_sidebar( array(
          'name'            => __( 'Example ', 'colormag' ),
          'id'              => 'colormag_example',
          'description'     => __( 'Shows widgets at Example.', 'colormag' ),
          'before_widget'   => '<aside id="%1$s" class="widget %2$s clearfix">',
          'after_widget'    => '</aside>',
          'before_title'    => '<h3 class="widget-title"><span>',
          'after_title'     => '</span></h3>'
       ) );

    This will register the widget area.

    Now to call this widget on front page. Add the below code on front-page.php

    if( is_active_sidebar( 'colormag_example' ) ) {
                if ( !dynamic_sidebar( 'colormag_example' ) ):
                endif;
             }

    below the line number 40 of front-page.php.

    If not work, please feel free to ask. While adding code, do it carefully.

    Note: Child theme is recommended to customize theme.

    Thread Starter dino9930

    (@dino9930)

    I may be missing something, but I am unable to find Widgets.php, it’s not listed under templates in the Editor.

    Please access this file through FTP. Theme customization is not recommended from editor. I already mentioned you about Child theme. No all file can access through editor.

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Adding More Content to Front Page’ is closed to new replies.