Guest User

Untitled

a guest
Dec 3rd, 2016
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. include "conect_BD.php";
  2.  
  3. $id_usuario = "select id_usuario as num from USUARIOS where login = '".$_POST['Usuario']"' and password = '".$_POST['Clave']"'";
  4. $value = "select count (*) as tot from CLIENTES where usuario_id = '10' ";
  5.  
  6. $result = $conn->query($id_usuario);
  7. $row = $result->fetch_assoc();
  8. echo "<h1 align='center'> Registro Exitoso <h1>" ;
  9. $result2 = $conn->query($value);
  10. if($result2->num_rows==1){
  11. $row2 = $result2->fetch_assoc();
  12. if($row2["tot"] > 0){
  13. <form action=" inicio_cliente.php"> </form>
  14. }
  15. else{
  16. <form action = "inicio_trabajador.php"></form>
  17. }
  18. }
  19.  
  20. }
  21. $conn->close();
Advertisement
Add Comment
Please, Sign In to add comment