Responsive Bootstrap

1

I have a web template that tested your responsiveness. As I am decreasing the width , the menu will also decrease and stay in perfect condition. This "perfection" is up to 760px. When I do this, it's as if the menu has been zooming down to 760px in perfect condition. So I wanted to know how I make this Bootstrap effect on the menu? Example: template .

My code:

<!DOCTYPE html>
<html lang="pt-br">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Menu</title>
<link href="css/bootstrap.min.css" rel="stylesheet">
<link href="css/custom.css" rel="stylesheet">
<style type="text/css">
    .container{margin-top: 20px; max-width:1004px; border:solid 1px #CCC;}
</style>
   </head>
  <body>
    <div class="container">
    <div class="row">
        <div class="col-md-6 imagem">
            <img src="imgs/logo.png" height="68" width="228">
        </div>
        <div class="col-md-6 imagem1">
            <div class="iconInput">
                <i class="glyphicon glyphicon-search pull-right" style="margin-right: 15px"></i>
                <input type="text" name="" value="" class="form-control inpuT" placeholder="Pesquisar">
            </div>
        </div>
    </div>
    <div class="row">
        <nav class="navbar navbar-inverse" role="navigation">
            <div class="navbar-header">
                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#collapse">
                    <span class="sr-only">Toggle navigation</span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                </button>
            </div>
            <div class="collapse navbar-collapse" id="collapse">
                <ul class="nav nav-pills">
                    <li>
                        <a href=""><i class="glyphicon glyphicon-home"  aria-hidden="true" style="color: #FFF;"></i></a>
                    </li>
                    <li class="dropdown">
                        <a href="#" class="dropdown-toggle cor-letra" data-toggle="dropdown" role="button" aria-expanded="false">CLOTHING</a>
                        <ul class="dropdown-menu" role="menu">
                            <li class="dist"><a href="#" style="color: #FFF; margin-bottom: 6px; padding: 6px 15px;">WOMEN CLOTHING</a></li>
                            <li><a href="#" style="color: #FFF; margin-bottom: 6px;  padding: 6px 15px;">MEN CLOTHING</a></li>
                            <li><a href="#" style="color: #FFF; margin-bottom: 6px;  padding: 6px 15px">INFANT CLOTHING</a></li>
                        </ul>
                    </li>
                    <li class="dropdown">
                        <a href="#" class="dropdown-toggle cor-letra" data-toggle="dropdown" role="button" aria-expanded="false">SHOES</a>
                        <ul class="dropdown-menu" role="menu">
                            <li class="dist" style="margin-bottom: 6px;"><a href="#" style="color: #FFF; padding: 6px 15px;">CASUAL SHOES</a></li>
                            <li><a href="#" style="color: #FFF; margin-bottom: 6px; padding: 6px 15px;">FANCY SHOES</a></li>
                            <li><a href="#" style="color: #FFF;margin-bottom: 6px; padding: 6px 15px;">SPORT SHOES</a></li>
                        </ul>
                    </li>
                    <li>
                        <a href="#" class="dropdown-toggle cor-letra" data-toggle="dropdown" role="button" aria-expanded="false">ACCESSORIES</a>
                    </li>
                    <li class="dropdown">
                        <a href="#" class="dropdown-toggle cor-letra" data-toggle="dropdown" role="button" aria-expanded="false">JEWELLERY</a>
                        <ul class="dropdown-menu" role="menu">
                            <li class="dist" style="margin-bottom: 6px;"><a href="#" style="color: #FFF ;padding: 6px 15px;">RINGS</a></li>
                            <li><a href="#" style="color: #FFF; margin-bottom: 6px; padding: 6px 15px;">BRACELETS</a></li>
                            <li><a href="#" style="color: #FFF; margin-bottom: 6px; padding: 6px 15px;">OTHER</a></li>
                        </ul>
                    </li>
                    <li>
                        <a href="#" class="dropdown-toggle cor-letra" data-toggle="dropdown" role="button" aria-expanded="false">FURNITURE</a>
                    </li>
                    <li>
                        <a href="#" class="dropdown-toggle cor-letra" data-toggle="dropdown" role="button" aria-expanded="false">SWEETS & CANDY</a>
                    </li>
                    <li>
                        <a href="#" class="dropdown-toggle cor-letra" data-toggle="dropdown" role="button" aria-expanded="false">UNIQUE GIFTS</a>
                    </li>
                </ul>
            </div>
        </nav>
        <img src="imgs/linha.png" height="3" width="1004" alt="" style="margin-top: -19px;" class="img-responsive">
    </div>
</div>

 <!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
<script src="js/jquery.min.js"></script>
<!-- Include all compiled plugins (below), or include individual files as needed -->
<script src="js/bootstrap.min.js"></script>
  </body>
  </html>
    
asked by anonymous 25.10.2015 / 06:04

1 answer

2

You have here several examples of Bootstrap Navigation Bars to suit your needs. In this case what you are looking for, is of the following structure:

<nav class="navbar navbar-inverse">
  <div class="container-fluid">
    <div class="navbar-header">
      <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#myNavbar">
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span> 
      </button>
      <a class="navbar-brand" href="#">WebSiteName</a>
    </div>
    <div class="collapse navbar-collapse" id="myNavbar">
      <ul class="nav navbar-nav">
        <li class="active"><a href="#">Home</a></li>
        <li><a href="#">Page 1</a></li>
        <li><a href="#">Page 2</a></li> 
        <li><a href="#">Page 3</a></li> 
      </ul>
      <ul class="nav navbar-nav navbar-right">
        <li><a href="#"><span class="glyphicon glyphicon-user"></span> Sign Up</a></li>
        <li><a href="#"><span class="glyphicon glyphicon-log-in"></span> Login</a></li>
      </ul>
    </div>
  </div>
</nav>

Here's a online example in jsFiddle .

    
25.10.2015 / 15:56