Advertisement
Guest User

Untitled

a guest
Apr 22nd, 2018
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.71 KB | None | 0 0
  1. <?php //Query
  2. $Naam = $_POST['Naam'];
  3. $Email = $_POST['Email'];
  4. $Adres = $_POST['Adres'];
  5. $tel = $_POST['tel'];
  6. $Reason = $_POST['Reason'];
  7. $quest = $_POST['quest'];
  8.  
  9.  
  10. //Verbinden
  11. $user = "root";
  12. $password = "";
  13. $host = "localhost";
  14. $dbname = "jd";
  15.  
  16. //connection to the database
  17. $con=($GLOBALS["___mysqli_ston"] = mysqli_connect(localhost, root,));
  18.  
  19.  
  20. //INSERT
  21. $query = " INSERT INTO Contact (Naam, E-mail, Adres, Telefoon / Gsm, Waarom?, Vraag) VALUES ('$Naam', '$Email', '$Adres', '$tel', '$Reason', '$quest') ";
  22. $result = mysqli_query($GLOBALS["___mysqli_ston"], $query);
  23.  
  24. if( $result )
  25. {
  26. echo 'Success';
  27. }
  28. else
  29. {
  30. echo 'Query Failed';
  31. }
  32.  
  33. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement