Advertisement
Guest User

Untitled

a guest
Feb 9th, 2016
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.79 KB | None | 0 0
  1. <?php
  2. $servername = "localhost";
  3. $username = "u454126282_luca";
  4. $password = "lucafraser";
  5. $dbname = "u454126282_stage";
  6.  
  7. // Create connection
  8. $conn = new mysqli($servername, $username, $password, $dbname);
  9. // Check connection
  10. if ($conn->connect_error) {
  11. die("Connection failed: " . $conn->connect_error);
  12. }
  13. ?>
  14.  
  15. <!DOCTYPE html>
  16. <html>
  17. <head>
  18. <link rel="stylesheet" href="javascript.js">
  19. <link rel="stylesheet" href="layout.css">
  20. <title>Bestuur wijzigen</title>
  21. <link rel="icon" href="images/favicon.png">
  22. </head>
  23. <body>
  24. <ul class="horizontal gray">
  25. <li><a class="active" href="index.php">Bestuur</a></li>
  26. <li><a href="bestuurWijzigen.php">Bestuur wijzigen</a></li>
  27. <li><a href="bestuurToevoegen.php">Bestuur toevoegen</a></li>
  28. </ul>
  29. <form action="index.php">
  30. <table class="table" border="1" frame="void" rules="rows">
  31. <tr>
  32. <td><label for="naam">Kies een bestuurslid</label></td>
  33. <td>
  34. <select id="kiezen"></select>
  35. <?php
  36. $query = "SELECT * FROM Leden";
  37. $result = $conn->query($query);
  38. while($row=mysqli_fetch_array($result, MYSQLI_ASSOC)){
  39. echo "<option value='".$row['ID']."'>".$row['Voornaam']."</option>";
  40. }
  41. ?>
  42.  
  43. <select id="kiezen"></select>
  44. </td>
  45. </tr>
  46. <tr>
  47. <td><label for="functie">Functie</label></td>
  48. <td>
  49. <select>
  50. <option value="#" selected="">Voorzitter</option>
  51. <option value="#">Secretaris</option>
  52. <option value="#">Penningmeester</option>
  53. </select>
  54. </td>
  55. </tr>
  56.  
  57. <tr>
  58. <td><button type="submit" class="button">Opslaan</button</td>
  59. </tr>
  60. </tbody></table>
  61. </form>
  62. </body>
  63. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement