|
@@ -26,9 +26,10 @@ include_once 'WebFunctions.php';
|
|
|
<?php
|
|
<?php
|
|
|
$betAmount = 0.25;
|
|
$betAmount = 0.25;
|
|
|
$bank = 500;
|
|
$bank = 500;
|
|
|
-echo '<label>Bank: </label><form><input type="number" id="bankInput" size="10" value="' .
|
|
|
|
|
|
|
+echo '<label for="bank">Bank: </label><input type="number" name="bank" id="bank" size="10" value="' .
|
|
|
$bank .
|
|
$bank .
|
|
|
- '"></form>';
|
|
|
|
|
|
|
+ '">' .
|
|
|
|
|
+ '<output class="bank-output" for="bank"></output>';
|
|
|
$database = new Database();
|
|
$database = new Database();
|
|
|
$matches = $database->getTodaysPrioMatches();
|
|
$matches = $database->getTodaysPrioMatches();
|
|
|
$wf = new WebFunctions();
|
|
$wf = new WebFunctions();
|
|
@@ -48,6 +49,19 @@ $wf->createOutstandingBetsTable();
|
|
|
} );
|
|
} );
|
|
|
</script>
|
|
</script>
|
|
|
|
|
|
|
|
|
|
+<script>
|
|
|
|
|
+ const bank = document.querySelector("#bank");
|
|
|
|
|
+ const output = document.querySelector(".bank-output");
|
|
|
|
|
+
|
|
|
|
|
+ output.textContent = bank.value;
|
|
|
|
|
+
|
|
|
|
|
+ bank.addEventListener("input", () => {
|
|
|
|
|
+ output.textContent = bank.value;
|
|
|
|
|
+ console.log("Bank updated " + output.textContent);
|
|
|
|
|
+ })
|
|
|
|
|
+
|
|
|
|
|
+</script>
|
|
|
|
|
+
|
|
|
|
|
|
|
|
<!-- Script to handle submit button -->
|
|
<!-- Script to handle submit button -->
|
|
|
</body>
|
|
</body>
|