Advertisement
melody45

Register

Mar 25th, 2015
181
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.91 KB | None | 0 0
  1. <?php
  2. include 'includes/db_connect.php';
  3. $title = $_POST['title'];
  4. $fname = $_POST['fname'];
  5. $lname = $_POST['lname'];
  6. $uname = $_POST['uname'];
  7. $pass = $_POST['pass'];
  8. $phone = $_POST['phone'];
  9. $email = $_POST['email'];
  10. $address = $_POST['address'];
  11. $age = $_POST['age'];
  12. $height = $_POST['height'];
  13. $weight = $_POST['weight'];
  14. $notes = $_POST['notes'];
  15. $status = 0;
  16. $flag = 0;
  17.  
  18.  
  19. $sql = "INSERT INTO users (`title`, `first_name`, `last_name`, `phone`, `u_email`, `address`, `age`, `height`, `weight`, `notes`, `u_name`, `u_pass`, `u_status`, `flag`)
  20. VALUES ('$title', '$fname', '$lname', '$phone', '$email', '$address', '$age', '$height', '$weight', '$notes', '$uname', '$pass', '$status', '$flag')";
  21.  
  22.  
  23. if (mysqli_query($conn, $sql)) {
  24. echo "<script>location.href='success.php'</script>";
  25. } else {
  26. echo "<script>location.href='failure.php'</script>";
  27. }
  28.  
  29. mysqli_close($conn);
  30. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement