Advertisement
Guest User

Untitled

a guest
Dec 17th, 2018
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.57 KB | None | 0 0
  1. <html>
  2. <head>
  3. <style>
  4. body {
  5. font-family: Arial;
  6. }
  7. table tr td {
  8. border-collapse: collapse;
  9. }
  10. </style>
  11. <?php
  12. $test = "Vul het formulier in!";
  13. $pee = "";
  14. $seee = "";
  15. $ptt = "";
  16. $sttt = "";
  17. $pdd = "";
  18. $sddd = "";
  19. if($_GET)
  20. {
  21.  
  22. $aee = $_GET["ae"];
  23. $att = $_GET["at"];
  24. $add = $_GET["ad"];
  25.  
  26. $see = $_GET["se"];
  27. $seee = $aee * $see;
  28.  
  29. $stt = $_GET["st"];
  30. $sttt = $att * $stt;
  31.  
  32. $sdd = $_GET["sd"];
  33. $sddd = $add * $sdd;
  34.  
  35. $pee = $_GET["pe"];
  36. $ptt = $_GET["pt"];
  37. $pdd = $_GET["pd"];
  38.  
  39. }
  40. ?>
  41. </head>
  42. <form action="#" method="GET">
  43. <body>
  44. <table border="1" rowspan="4">
  45. <tr>
  46. <td></td>
  47. <td><b><i>Producten</i></b></td>
  48. <td><b>Aantal</b></td>
  49. <td><b>Stukprijs in euro's</b></td>
  50. </tr>
  51. <tr>
  52. <td><i>1</i></td>
  53. <td><input type="text" name="pe"></td>
  54. <td><input type="text" name="ae" value="0"></td>
  55. <td><input type="text" name="se" value="0"></td>
  56. </tr>
  57. <tr>
  58. <td><i>2</i></td>
  59. <td><input type="text" name="pt"></td>
  60. <td><input type="text" name="at" value="0"></td>
  61. <td><input type="text" name="st" value="0"></td>
  62. </tr>
  63. <tr>
  64. <td><i>3</i></td>
  65. <td><input type="text" name="pd"></td>
  66. <td><input type="text" name="ad" value="0"></td>
  67. <td><input type="text" name="sd" value="0"></td>
  68. </tr>
  69. <tr>
  70. <td colspan="2"><input type="submit" name="berekenen" value="Versturen"></td>
  71. <td colspan="2">
  72. </td>
  73. </tr>
  74. </table>
  75. <?php
  76. echo "Product 1 zijn/is $pee , de totaalprijs is $seee";
  77. echo "<br>";
  78. echo "Product 2 zijn/is $ptt , de totaalprijs is $sttt";
  79. echo "<br>";
  80. echo "Product 3 zijn/is $pdd , de totaalprijs is $sddd";
  81. echo "<br>";
  82. if (empty($pee)) {
  83. echo "Veld 1 is niet ingevuld";
  84. }
  85. echo "<br>";
  86. if (empty($ptt)) {
  87. echo "Veld 2 is niet ingevuld";
  88. }
  89. echo "<br>";
  90. if (empty($pdd)) {
  91. echo "Veld 3 is niet ingevuld";
  92. }
  93. ?>
  94. </body>
  95. <form>
  96. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement