Advertisement
Guest User

Untitled

a guest
Nov 27th, 2017
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. <?php
  2. $user='root';
  3. $password='';
  4. $id=$_POST['id'];
  5. $imie=$_POST['imie'];
  6. $nazwisko=$_POST['nazwisko'];
  7. $data=$_POST['data'];
  8. $miejsce=$_POST['miejsce'];
  9. $conn = mysqli_connect('localhost',$user,$password) or die ("Błąd Logowania");
  10. mysqli_select_db($conn,'4iag1') or die ("Błąd wyboru bazy");
  11. $wynik=mysqli_query($conn," INSERT INTO Osoby values ('$id','$imie','$nazwisko','$data','$miejsce')");
  12. ?>
  13. <form method="POST" action="">
  14. ID<input type="text" name="id"></br>
  15. Imie<input type="text" name="imie"></br>
  16. Nazwisko<input type="text" name="nazwisko"></br>
  17. data<input type="date" name="data"></br>
  18. miejsce<input type="text" name="miejsce"></br>
  19. <input type="submit" value="Dodaj">
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement