<!DOCTYPE html>
<html>
		<title>
		Rabio - Rapid Business Information Organizer
	  </title>
<head>
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="./bootstrap/css/bootstrap.min.css">
  <script src="./jquery/jquery-3.4.1.js"></script>
  <script src="./bootstrap/js/bootstrap.min.js"></script>
    <link rel="stylesheet" href="./fontawesome/css/all.css" > 
	<link rel="stylesheet" href="./css/w3.css">	
	


<style>
body {
	background: linear-gradient(-30deg, #00bfff, #ffffe0, #add8e6, #d3d3d3);
	background-size: 400% 400%;
	animation: gradient 5s ease infinite;
}

@keyframes gradient {
	0% {
		background-position: 0% 50%;
	}
	50% {
		background-position: 100% 50%;
	}
	100% {
		background-position: 0% 50%;
	}
}
</style>

</head>
<body>
	<h1 class="text-light"></h1>
<?php
// 1ST TIME NEW USER CHECK
include('r_dbc.php');
$sqlmid = "select count(*) as cntmembers from members";

$resultmid = mysqli_query($conn, $sqlmid);

if (mysqli_num_rows($resultmid) > 0) {
      while($rowmid = mysqli_fetch_assoc($resultmid)) {
		$cntmembers		= $rowmid["cntmembers"];
    }
} 
mysqli_close($conn);

?>


<br><br><br><br>

<div class="container">
<div class="table-responsive"> 



	<table class='table' >
		<tr>
			<th style='text-align:center;width: 30%'>
				<h1 class="w3-animate-opacityd" >
				Rapid Business Information Organizer
				</h1>
			</th>
		</tr>
<?php 
	if ($cntmembers > 0) 
		{ 
?>
		<tr>
			<td style='text-align:center;width: 30%' class="w3-animate-opacity" >
				<br><br><br>	
				<a href="./secl/index.php">
				<div class="d-grid gap-2">
					<button type="button" class="btn btn-primary btn-block btn-lg">Login</button>
				</div>
				<br><br><br>
				</a>
			</td>
		</tr>
<?php 
	}
	if ($cntmembers == 0) 
		{ 
?>
		<tr>
			<td style='text-align:center;width: 30%' class="w3-animate-opacity" >
				<br><br><br>	
				<a href="register.php?newuser=admin">
				<button type="button" class="btn btn-danger btn-block btn-lg">Rabio Setup <br> Please Register Administrator User</button>
				<br><br><br>
				</a>
			</td>
		</tr>
<?php
		}
?>

<!--
		<tr>
			<td style='text-align:center;width: 30%' class="w3-animate-opacityd" >
				<h5><strong><a href="help/index.php?lang=<?php echo $lang ?>&pid=<?php echo $pid ?>" target=_blank style="color:olive" ><span style='color:blue'><i class="fas fa-question-circle"></i></span>	Documentation </a>	</strong></h5>
			</td>
		</tr>		
-->		
		<tr>
			<td style='text-align:center;width: 30%' class="w3-animate-opacityd" >
				<a href="https://www.rabio.eu">
				www.Rabio.eu
				</a>
			</td>
		</tr>		
	</table>		



  </div>
</div>
<!-- bakcground image close div -->
</div>
</body>
</html>