Răsfoiți Sursa

Make Bet start

Axel Nordh 4 ani în urmă
părinte
comite
df18fc9bf4
2 a modificat fișierele cu 16 adăugiri și 1 ștergeri
  1. 5 0
      OddsJavaFx/src/web/makeBet.php
  2. 11 1
      OddsJavaFx/src/web/matchTable.php

+ 5 - 0
OddsJavaFx/src/web/makeBet.php

@@ -0,0 +1,5 @@
+<?php 
+
+echo "Make Bet</br>";
+var_dump($_POST);
+

+ 11 - 1
OddsJavaFx/src/web/matchTable.php

@@ -23,12 +23,16 @@ $matches = $conn->getMatches($countryId, $leagueId);
             <th>Odds 1</th>
             <th>(Odds X)</th>
             <th>Odds 2</th>
-        
+        	<th>Bet home (true)/away (false)</th>
+        	<th>Bet Odds</th>
+        	<th>Bet Amount</th>
+        	<th>&nbsp;</th>
         </tr>
     </thead>
     <tbody>
 <?php 
     foreach ($matches as $match) {
+        echo "<form action='makeBet.php' method='post'>";
         echo "<tr>";
         echo "<td>".$match['gameDate'] . "</td>";
         echo "<td>".$match['homeTeamName'] . "</td>";
@@ -36,6 +40,12 @@ $matches = $conn->getMatches($countryId, $leagueId);
         echo "<td>". round(100 / $match['homeWinPercent'], 2) . "</td>";
         echo "<td>". round(100 / $match['drawPercent'], 2) . "</td>";
         echo "<td>". round(100 / $match['awayWinPercent'], 2) . "</td>";
+        echo "<td><input id='betHome' type='checkbox'/></td>";
+        echo "<td><input id='betOdds' type='number'/></td>";
+        echo "<td><input id='betAmount' type='number'/></td>";
+        echo "<td><input id='button' type='submit'/></td>";
+        echo "</form>";
+        echo "</tr>";
     }
 ?>
 </tbody>