php - In responsive mode my dropdown isn't climbing up -


<!doctype html> <html>  <?php include 'includes/head.php'; ?> <body> <?php include 'includes/header.php'; ?> 

head.php:-

<head> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" type="text/css" href="css/bootstrap.min.css"> <link rel="stylesheet" type="text/css" href="css/style.css"> <script src="js/jquery-2.2.0.min.js"></script> <script src="js/bootstrap.min.js"></script> <title>ait project</title> </head> 

header.php:-

<nav class="navbar navbar-default navbar-fixed-top"> <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>      <li class="dropdown">     <a class="dropdown-toggle" data-toggle="dropdown" href="#">page 1     <span class="caret"></span></a>     <ul class="dropdown-menu">       <li><a href="#">page 1-1</a></li>       <li><a href="#">page 1-2</a></li>       <li><a href="#">page 1-3</a></li>      </ul>   </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> 

as reduce display size bootstrap navbar goes responsive mode. when click button whole menu drops down doesn't climb up. responsive navbar on dropping down in responsive mode carousel gets hidden navbar the carousel

there typo/blank space in header.php row 4: data- target="#mynavbar"

...should data-target="#mynavbar"

when fixing code working, see https://plnkr.co/edit/gbdhaqbgfvj57bqhzmdv?p=preview click on "hamburger menu" left expands menu; 1 more click collapse. want/expect?


Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -