|
|
@@ -7,6 +7,7 @@ $countryId = $_POST['countrySelector'];
|
|
|
$leagueId = $_POST['leagueSelector'];
|
|
|
|
|
|
$matches = $conn->getMatches($countryId, $leagueId);
|
|
|
+$leagueInfo = $conn->getLeagueInfo($leagueId);
|
|
|
|
|
|
?>
|
|
|
<head>
|
|
|
@@ -41,9 +42,9 @@ $matches = $conn->getMatches($countryId, $leagueId);
|
|
|
echo "<td>".$match['gameDate'] . "</td>";
|
|
|
echo "<td>".$match['homeTeamName'] . "</td>";
|
|
|
echo "<td>".$match['awayTeamName'] . "</td>";
|
|
|
- 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>". round((100 / $match['homeWinPercent']) * $leagueInfo['betMargin'], 2) . "</td>";
|
|
|
+ echo "<td>". round((100 / $match['drawPercent']) * $leagueInfo['betMargin'], 2) . "</td>";
|
|
|
+ echo "<td>". round((100 / $match['awayWinPercent']) * $leagueInfo['betMargin'], 2) . "</td>";
|
|
|
echo "<td><input id='betHome' name='betHomeName' type='checkbox'/></td>";
|
|
|
echo "<td><input id='betOdds' name='betOddsName' type='number' step='.01'/></td>";
|
|
|
echo "<td><input id='betAmount' name='betAmountName' type='number' step='.01'/></td>";
|