<?php
$db = new SQLite3('api/.db.db');
$log_check = $db->query("SELECT * FROM users");
//$log_check = $db->query("SELECT * FROM users WHERE id='1'");
$roe = $log_check->fetchArray();
$curr = basename($_SERVER['PHP_SELF']);
$page = substr($curr, 0, 3);

// if (!isset($_SESSION['loggedinlive'])) {
// 	header("location:"."index.php");
// 	exit();
// }
?>
<head>
  <meta charset="utf-8" />
  <link rel="apple-touch-icon" sizes="76x76" href="assets/img/apple-icon.png">
  <link rel="icon" type="image/png" href="assets/img/favicon.png">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
  <title>
    APP STORE ADMIN PANEL V2.1 (English)
  </title>
  <meta content='width=device-width, initial-scale=1.0, shrink-to-fit=no' name='viewport' />
  <!--     Fonts and icons     -->
  <link rel="stylesheet" type="text/css" href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700|Roboto+Slab:400,700|Material+Icons" />
  <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/latest/css/font-awesome.min.css">
  <!-- CSS Files -->
  <link href="assets/css/material-dashboard.css?v=2.1.2" rel="stylesheet" />
  <!-- CSS Just for demo purpose, don't include it in your project -->
  <link href="assets/demo/demo.css" rel="stylesheet" />
</head>

<body class="">
  <div class="wrapper">
    <div class="sidebar" data-color="purple" data-background-color="white" data-image="assets/img/sidebar-1.jpg">
      <div class="logo"><a href="key.php" class="simple-text logo-normal">
          <img src="assets/img/appstore.png" width="150"><br>
		   <h5>Welcome, <b><?php echo($_SESSION['name'])?>!</h5>
        </a></div>
      <div class="sidebar-wrapper">
        <ul class="nav">
          <li class="nav-item ">
            <a class="nav-link" href="key.php">
              <i class="material-icons">store</i>
              <p>App Stores</p>
            </a>
          </li><!--
          <li class="nav-item ">
            <a class="nav-link" href="notificacoes.php">
              <i class="material-icons">notifications</i>
              <p>Notificações</p>
            </a>-->
		    <li class="nav-item ">
            <a class="nav-link" href="usuario.php">
              <i class="material-icons">person</i>
              <p>Users</p>
            </a>
          </li>
		                <li class="nav-item">
            <a class="nav-link collapsed" href="#" data-toggle="collapse" data-target="#collapsePages" aria-expanded="true" aria-controls="collapsePages">
              <i class="material-icons">cloud_upload</i>
              <P>CLOUD UPLOAD</P>
            </a>
            <div id="collapsePages" class="collapse" aria-labelledby="headingPages" data-parent="#accordionSidebar">
            <a class="collapse-item nav-item nav-link" href="https://www.mediafire.com/login/" target="_blank"><i class="material-icons">upload_file</i></i><p> Mediafire</p></a>
            <a class="collapse-item nav-item nav-link" href="https://db.tt" target="_blank"><i class="material-icons">upload_file</i></i><p> DropBox</p></a>
            <a class="collapse-item nav-item nav-link" href="https://mega.nz/" target="_blank"><i class="material-icons">upload_file</i></i><span> Mega</p></a>
            </div>
		    <li class="nav-item ">
            <a class="nav-link" href="logs.php">
              <i class="material-icons">content_paste</i>
              <p>System Logs</p>
            </a>
          </li>
          <li class="nav-item ">
            <a class="nav-link" href="logout.php">
              <i class="material-icons">logout</i>
              <p>Logout</p>
            </a>
          </li>
        </ul>
      </div>
    </div>