Advertisement
Guest User

Untitled

a guest
Sep 3rd, 2016
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. <?php
  2.  
  3. session_start();
  4.  
  5. if(!isset($_SESSION['email']) || !isset($_SESSION['senha'])) {
  6.  
  7. header("location: login.php");
  8. exit;
  9.  
  10. } else {
  11.  
  12. echo "<center>Voçe esta logado! :D<center>";
  13. }
  14.  
  15. ?>
  16.  
  17. <?php
  18.  
  19. $host = "localhost";
  20. $user = "root";
  21. $pass = "";
  22. $banco = "Cadastro";
  23.  
  24. $conexao = mysql_connect($host, $user, $pass) or die(mysql_error());
  25. mysql_select_db($banco) or die(mysql_error());
  26. ?>
  27.  
  28.  
  29.  
  30.  
  31.  
  32. <!DOCTYPE html>
  33. <html>
  34. <head>
  35. <title>Painel</title>
  36. </head>
  37. <body>
  38.  
  39. <a href="logout.php">Sair</a>
  40.  
  41. </body>
  42. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement