Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress

Joe Li
Joe Li
1,689 Points

Central navigation in Wordpress with Bootstrap 4?

I'm trying to do justify-content-between on the li items on the navbar but it doesn't seem to work? Help please :)

Joe Li
Joe Li
1,689 Points

This is what I have so far:

  <div class="container">
    <div class="row">
        <nav class="navbar navbar-expand-md navbar-light bg-light col">
            <?php
                  $defaults = array(
                    'theme_location' => 'primary-menu',
                    'container' => 'div',
                    'container_class' => 'collapse navbar-collapse',
                    'menu_class' => 'nav navbar-nav'
                  );
                  wp_nav_menu( $defaults );
              ?>
        <button class="navbar-toggler" type="button" data-toggle="collapse" data-target=".navbar-collapse" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
            <span class="navbar-toggler-icon"></span>
        </button>
        </nav>
    </div>
  </div>