18 lines
412 B
PHP
18 lines
412 B
PHP
|
<?php
|
||
|
if(session_status() !== PHP_SESSION_ACTIVE){
|
||
|
session_start();
|
||
|
}
|
||
|
include('conexao_publica.php');
|
||
|
$sql = "SELECT tipo_usuario FROM consulta_usuarios WHERE tipo_usuario = 'adm'";
|
||
|
$stmt = $con->prepare($sql);
|
||
|
if($stmt->execute())
|
||
|
{
|
||
|
$row = $stmt->get_result()->fetch_assoc();
|
||
|
if(!is_array($row))
|
||
|
{
|
||
|
$_SESSION['setup'] = true;
|
||
|
header('Location: setup/index.php');
|
||
|
}
|
||
|
}
|
||
|
|
||
|
?>
|