While integrating bootswatch theme the horizontal menu becomes a drop down menu in ASP.NET

135 Views Asked by At

I am trying to fix a css problem that changed the horizontal menu to drop down when it was not supposed to.

Dropdown menu instead of a horizontal menu

All i did was replace the bootstrap.css with one from bootswatch.com

1

There are 1 best solutions below

0
On

Go to your layout page and put in "navbar-expand-md" (or -sm or -lg) like this:

<div class="navbar navbar-expand-md navbar-inverse navbar-fixed-top">
        <div class="container">
            <div class="navbar-header">
                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                </button>
                @Html.ActionLink("Vidly", "Index", "Home", new { area = "" }, new { @class = "navbar-brand" })
            </div>
            <div class="navbar-collapse collapse">
                <ul class="nav navbar-nav">
                    <li>@Html.ActionLink("Home", "Index", "Home")</li>
                    <li>@Html.ActionLink("About", "About", "Home")</li>
                    <li>@Html.ActionLink("Contact", "Contact", "Home")</li>
                </ul>
            </div>
        </div>
    </div>