<?php 
		include("connection/conn.php");
		if($_SESSION['adminuser']==''){
		header("location:index.php");
		exit();
	}
       	$adjacents = 3;
		$select_1="select * from Manage_Member order by id desc";
		$query_1=mysqli_query($link,$select_1);
		$total_pages=mysqli_num_rows($query_1);
		$path="dat=$dat&dat1=$dat1&centername=$centername";
		$targetpage="manage-member.php"; 	   
		$limit=2000; 								
		$page=$_GET['page'];
		if($page){
			$start=($page - 1) * $limit; 
		}		
		else
		{
			$start=0;		
		}
		$sql="select * from Manage_Member order by id desc LIMIT $start, $limit";
		$result=mysqli_query($link,$sql);
		$count=mysqli_num_rows($result);
		if($page==0) 
		$page=1;					              
		$prev=$page-1;							
		$next=$page+1;							
		$lastpage=ceil($total_pages/$limit);		
		$lpm1=$lastpage-1;		
	// Export Data In CSV Format	
	
?>
<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8" />
		<meta name="viewport" content="width=device-width, initial-scale=1.0" />
		<title>Administrator | Manage Team Member</title>
		<link href="css/bootstrap.css" rel="stylesheet" />
		<link href="css/style.css" rel="stylesheet" />
		<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
		<link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css' />
	</head>
	
	<body>
		<div id="wrapper">
			<?php
				include("top-header.php");
				include("right-sec.php");
			?>
			<div id="page-wrapper" >
				<div id="page-inner">
					<div class="row">
						<div class="col-md-12">
							<h3 class="page-header">
								Manage  Team Member Section<small></small>
							</h3>
							<div class="search-sec">
								<form action="">
									<div class="row">
										<div class="col-md-3 col-xs-6 p-0">	
											<div class="form-group form-select">
											
											</div>		
										</div>
																	

										<div class="col-md-2 col-xs-6 p-0">	
											
										</div>
									</div>
								</form>
							</div>
							<div class="table-sec">
							    <div class="btn_sec">
									<ul>
										<li class="btn_add"><a href="add-member.php"><i class="fa fa-plus"></i> Add Team Member</a></li>
									</ul>
								</div>
								<table>
									<tr>
										<th>Id</th>
										<th>Name</th>
										<th>Email id</th>
										<th>Mobile No</th>
										<th>Qualification</th>
										<th>Address</th>
										<th>Images</th>
																
										<th>Status</a></th>
									</tr>
									<?php
									  $i=1;
									  while($find=mysqli_fetch_array($result)){
										$color = (($i%2) == 0)?"#e7f3ff":"#FFFFFF";
										
								?>
									<tr>
										<td><?php echo $i;?></td>
										
									
										<td><?php echo $find['Name'];?></td>
									
										<td><?php echo $find['Email'];?></td>
									
									
										<td><?php echo $find['Mobile'];?></td>
										<td><?php echo $find['qualification'];?></td>
									
										<td><?php echo $find['Address'];?></td>
									
									<td> <img src="https://aryansinstitute.com/members_img/<?php echo $find['Images']?>" style="width:80px; height:80px"></td>
									
									
										<td>
										    
											<ul class="table-ul">
												
												<li><a href="update-member.php?id=<?php echo $find['id'];?>"><i class="edit fa fa-pencil"></i></a></li>
												
												<li><a href="delete-member.php?id=<?php echo $find['id'];?>" onclick="return confirm('are you sure delete this Member?');"><i class="delete fa fa-trash"></i></a></li>
											</ul>
										</td>
									</tr>
									  <?php $i++; } ?>
									
								</table>
							</div>
						</div>
					</div> 
				</div>
			</div>
			<footer class="footer-sec">
				<div class="container">
					<div class="row">
						<div class="col-md-12">
							<p class="text-center">All right reserved. Template Design by: <a href="">Anshul Chittouria</a></p>
						</div>
					</div>
				</div>
			</footer>
		</div>
		
		
		<!-- jQuery Js -->
		<script src="js/jquery-1.10.2.js"></script>
		<script src="js/bootstrap.min.js"></script>
		<script src="js/jquery.metisMenu.js"></script>
		<script src="js/custom-scripts.js"></script>
	</body>
</html>
