

 <header id="header" class="fixed-top" style="background-color:#116496;">
      
	  <div class="container" >
      <div class="logo float-left hidden-xs hidden-sm">       
        <a href="index.php" class="scrollto"><img src="../img/logo.png" alt="" class="img-fluid"></a> 
      </div>
	  
	  
	   <div class="row about-container">
	   <div class="col-8 col-sm-8 col-md-8 hidden-md hidden-lg" align="right">
	   <div class="logo">
   
        <a href="index.php" class="scrollto" ><img src="../img/logo.png"   alt="" class="img-fluid "></a>
		</div></div>
		 <!--<div class="col-4 col-sm-4 col-md-4 hidden-md hidden-lg" align="right">
		  <a href="#intro" class="scrollto" style=" color:white; font-size:15px;" >
              <i class="fa fa-sign-in" aria-hidden="true"></i>	<br>Login	
		</div>-->
		</a>	  
        </div>


      <nav class="main-nav float-right d-none d-lg-block" >
        <ul>
          <li class="active hidden-xs hidden-sm" ><a href="index.php">Dashboard</a></li>
		   <li class="active hidden-md hidden-lg"  style="font-size:20px;"><a href="index.php"><i class="fa fa-home" aria-hidden="true"></i> </a></li>
		  
          <?php                    
            $nav_sql = "SELECT * FROM nav  where navfor='$_SESSION[uid]' ORDER BY npositon ASC limit 5";
            $nav_run = mysqli_query($con, $nav_sql);
            while ( $nav_rows = mysqli_fetch_assoc($nav_run) ) {

                $sql2 = "SELECT * FROM nav_page_type_master WHERE id = '$nav_rows[nname]' ";
                $run2 = mysqli_query($con, $sql2);
                $rows2 = mysqli_fetch_assoc($run2);

                $sql3 = "SELECT * FROM nav_page_template_master WHERE id = '$nav_rows[nlink]' ";
                $run3 = mysqli_query($con, $sql3);
                $rows3 = mysqli_fetch_assoc($run3);

                $navHeader =  $rows2['page_header_name']  ;
                $navUrl = $rows3['template_name'].'?sec='.$rows2['page_type'];

                echo "
                <li><a href='$navUrl'>$navHeader</a></li>
                ";
             }
          ?> 

        <li class="drop-down"><a href="">Others</a>
            <ul>
              <?php                    
            $nav_sql = "SELECT * FROM nav  where navfor='$_SESSION[uid]' ORDER BY npositon ASC limit 5,15";
            $nav_run = mysqli_query($con, $nav_sql);
            while ( $nav_rows = mysqli_fetch_assoc($nav_run) ) {
                $sql2 = "SELECT * FROM nav_page_type_master WHERE id = '$nav_rows[nname]' ";
                $run2 = mysqli_query($con, $sql2);
                $rows2 = mysqli_fetch_assoc($run2);

                $sql3 = "SELECT * FROM nav_page_template_master WHERE id = '$nav_rows[nlink]' ";
                $run3 = mysqli_query($con, $sql3);
                $rows3 = mysqli_fetch_assoc($run3);

                $navHeader =  $rows2['page_header_name']  ;
                $navUrl = $rows3['template_name'].'?sec='.$rows2['page_type'];
                
                echo "
                <li><a href='$navUrl'>$navHeader</a></li>
                ";
             }
          ?> 
            </ul>
          </li>
         
      <li><a href="#logoutModal" data-toggle="modal" data-toggle="modal" class="text-decoration-none" style="color: red;"> Logout <i class="fas fa-sign-out-alt fa-lg fa-fw"></i>
            </a>
          </li>
        </ul>
      </nav><!-- .main-nav -->
      
    </div>
  </header>

<div class="modal fade" id="logoutModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title" id="exampleModalLabel">Ready to Leave?</h5>
                <button class="close" type="button" data-dismiss="modal" aria-label="Close">
                    <span aria-hidden="true">×</span>
                </button>
            </div>
            <div class="modal-body">Select "Logout" below if you are ready to end your current session.</div>
            <div class="modal-footer">
                <button class="btn btn-secondary" type="button" data-dismiss="modal">Cancel</button>
                <a class="btn btn-primary" href="logout.php">Logout</a>
            </div>
        </div>
    </div>
</div>