<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <link rel="stylesheet" href="Css/Css.css"> <title></title> </head> <body> <?php include "classes/Estrutura.Class.php"; $Es = new Estrutura(); include "classes/Sql.Class.php"; $Db = new Sql(); $con = $Db->Conectar("diario"); if ($_GET['acao'] == "atividades") { $atividade = $Db->Select(1, $con, "*", "atividades", "id=" . $_GET['id'], "", ""); $Es->Cabeca(1, "Atividade: " . $atividade['nome'], 1); ?> <h3>Definições Técnicas - <a class='bot' href='Editar/Formulario.php?acao=atividades&id=<?php echo $atividade['id']; ?> '>Editar</a></h3> <table border='1'> <tr> <td>Nome </td> <td><?php echo $atividade['nome']; ?>
$Es->Cabeca(2, "Login", 1); ?> <body onload='load()'> <div id="conteudo"> <?php if ($_GET['acao'] != 0) { if ($_GET['acao'] == 1) { $Acesso->FormCadastro(); } else { if ($_GET['acao'] == 2) { $sql = $Db->Login($_POST['login'], $_POST['senha']); $con = $Db->Conectar(); $res = mysql_query($sql, $con) or die("Erro: " . mysql_error($con)); $dados = \mysql_fetch_array($res); if ($dados['login'] != $_POST['login']) { $_SESSION['login'] = $_POST['login']; $_SESSION['senha'] = $_POST['senha']; $sql = "INSERT INTO users(login,senha,nome) VALUES ('" . $_POST['login'] . "','" . $_POST['senha'] . "','" . $_POST['nome'] . "');"; $res = mysql_query($sql, $con) or die("Erro: " . mysql_error($con)); header("Location: Acesso.php?erro=null&acao=0"); } else { header("Location: Acesso.php?erro=3&acao=2"); } } } } else { $Acesso->EntradaDados();