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 trialtracy brown
Courses Plus Student 332 PointsNavbar - The Link to the TeamTreeHouse website located to the right
This is the code for the Navbar: <!-- Navbar --> <nav class="navbar navbar-toggleable-md navbar-light bg-faded"> <button class="navbar-toggler navbar-toggler-right" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button> <a class="navbar-brand" href="#">Navbar</a> <div class="collapse navbar-collapse" id="navbarNav"> <ul class="navbar-nav mr-auto"> <li class="nav-item"> <a class="nav-link" href="#home">Home <span class="sr-only">(current)</span></a> </li> <li class="nav-item"> <a class="nav-link" href="#about">About</a> </li> <li class="nav-item"> <a class="nav-link" href="#speakers">Speakers</a> </li> <li class="nav-item"> <a class="nav-link" href="#schedule">Schedule</a> </li> </ul> </div> <a class "navbar-brand" href="http://www.teamtreehouse.com">Presented by Treehouse</a> </nav>
When I preview it the link to the team treehouse to right is not aligned properly.
2 Answers
Xayaseth Boudsady
21,951 PointsActually I figured it out, it's rather simple.
Just put the class="mr-auto" in the <ul> tag right above the class="navbar-brand"> show in the video.
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav mr-auto"> <!-- From the teachers note, but it here... -->
<li class="nav-item">
<a class="nav-link" href="#home">Home <span class="sr-only">(current)</span></a>
</li>
<li class="nav-item">
<a class="nav-link" href="#about">About</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#speakers">Speakers</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#schedule">Schedule</a>
</li>
</ul>
<a class="navbar-brand" href="http://wwww.teamtreehouse.comf">Presented by Treehouse</a>
</div>
Julie Heckleman
Courses Plus Student 11,412 PointsYou are missing the equal (=) after class in your navbar-brand. Should be class="navbar-brand"
Jeanie Herold
15,555 PointsJeanie Herold
15,555 PointsI think you are just missing your float-sm-right' class for that link:
<a class="navbar-brand float-sm-right mr-0 hidden-xs-down" href="http://www.teamtreehouse.com" target="_blank">Presented by Treehouse</a>