Forum Replies Created

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

    (@genesee_baker)

    After a bunch of research, I finally figured it all out. In the functions.php file I put the following code:

    function header_widgets_init() {
    
    	register_sidebar( array(
    		'name' => 'Below Navigation',
    		'id' => 'below_nav_widget',
    		'before_widget' => '<nav>',
    		'after_widget' => '</div>',
    		'before_title' => '<h2 class="rounded">',
    		'after_title' => '</h2>',
    	) );
    }
    add_action( 'widgets_init', 'header_widgets_init' );

    Then in the header.php file under my nav section I put:

    <?php if ( dynamic_sidebar('below_nav_widget') ) : else : endif; ?>

    And everything worked! Good luck!

Viewing 1 replies (of 1 total)