<?php
    session_start();
    //ob_start();
    include "../../db.php";
    if ( !isset($_SESSION['uid']) && !isset($_SESSION['uref']) && !isset($_SESSION['utype']) )
        header("Location: logout.php");
?>
<!DOCTYPE html>
<html lang="en">
<head>
  <?php include "includes/meta.php"; ?>             
    <?php include "includes/css.php"; ?>
    <link href="css/all.min.css" rel="stylesheet" type="text/css">
    <link href="css/alltable.css" rel="stylesheet">    

   
</head>

<body>

  <!--==========================
  Header
  ============================-->
   <?php include "includes/header2.php"; ?>
  
  <!-- #header -->

  <!--==========================
    Intro Section
  ============================-->





   <div class="container" style="height: 100%;">         
     <div class="row  justify-content-center ">

 <div class="col-12 col-sm-8 col-md-8" style="padding-top:100px;">
                
    

<!--============================== -->
    <p class="h2 mb-4 text-gray-800 text-center">Welcome, <?php echo $_SESSION["uname"]; ?></p>
    <p class="small text-center mb-4"> Welcome, to Admin Panel, Here you can do the following things. </p>
    <br><br>
    </div>

        <div class="row justify-content-center">
                <?php                    
                    $nav_sql = "SELECT * FROM nav  where navfor='$_SESSION[uid]' ORDER BY npositon ASC";
                    $nav_run = mysqli_query($con, $nav_sql);
                    while ( $nav_rows = mysqli_fetch_assoc($nav_run) ) {
                        ?>

                             <div class="col-6 col-lg-2 col-md-3 col-sm-4 mb-4">
                                    <a href='<?php echo $nav_rows['nlink']; ?>' class="text-decoration-none">
                                        <div class="card bg-success text-white shadow h-100" data-toggle="tooltip" title="Securely Change Password">
                                            <div class="card-body px-0 px-sm-3">
                                                <div class="row mx-0">
                                                    <div class="col-8 fs-cus pr-0 pr-sm-2">
                                                        <?php echo $nav_rows['nname']; ?>
                                                     </div>
                                                    <div class="col-4 text-right pl-0 pl-sm-2"><i class="fas fa-tags fa-lg fa-fw"></i></div>
                                                </div>
                                            </div>
                                        </div>
                                    </a>
                                </div>

                        <?php
                    }
                ?>   
        </div>
                             
        
 
<!--============================== -->
        
                
                
                   </div>
   </div>
   
 <br>

 <!--==========================
    Footer
  ============================-->
    <?php include "includes/ft.php"; ?>
  
  <!-- #footer -->


</body>
</html>



 
 
  

  <!-- JavaScript Libraries -->
  <?php include "includes/js.php"; ?>

