I have a Bootstrap3 navigation bar with a drop down menu.
I want my exit form to appear in this drop-down list. This is not a visible form, just a button to exit the form.
I tried this:
<div class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button">Dropdown<span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#">Foo</a></li>
<li><form action="/logout" method="post"><button type="submit" class="btn btn-link navbar-btn navbar-link">Log off</button></form></li>
</ul>
</li>
</ul>
</div>
But it is spelled incorrectly.
How do I match normal links for a drop down list? I hope I do not need to manually configure css and what is the built-in way to do this?
source
share