-
Notifications
You must be signed in to change notification settings - Fork 0
/
bet.php
215 lines (176 loc) · 6.59 KB
/
bet.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
<html>
<?php include("navBar.php");
function filter($str)
{
return filter_var($str, FILTER_SANITIZE_STRING);
}
if (isset($_POST['matchNum']) && isset($_POST['name'])) {
if (($_POST['matchNum'] != "") && ($_POST['name'] != "")){
include("databaseLibrary.php");
$matchNum = filter($_POST['matchNum']);
$RedScorePredict = filter($_POST['RedScorePredict']);
$BlueScorePredict = filter($_POST['BlueScorePredict']);
$TotalAutoRed = filter($_POST['TotalAutoRed']);
$TotalAutoBlue = filter($_POST['TotalAutoBlue']);
$Winner = filter($_POST['Winner']);
$name = filter($_POST['name']);
$ID = $matchNum . "-" . $name;
betInput(
$matchNum,
$RedScorePredict,
$BlueScorePredict,
$TotalAutoRed,
$TotalAutoBlue,
$Winner,
$name,
$ID
);
}
}
?>
<head>
<link href="bootstrap/css/bootstrap.min.css" rel="stylesheet">
<link href="bootstrap-material-design-master/dist/css/ripples.min.css" rel="stylesheet">
<link href="bootstrap-material-design-master/dist/css/material-wfont.min.css" rel="stylesheet">
<script src="jquery-1.11.2.min.js"></script>
<script src="sorttable.js"></script>
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
<style>
#overallForm {
font-size: 15px;
display: inline-block;
}
</style>
<div class="container row-offcanvas row-offcanvas-left">
<div class="well column col-lg-12 col-sm-12 col-xs-12" id="content">
<a>
<h2><b><u>Bet Page:</u></b></h2>
</a>
<form action="" method="post" enctype="multipart/form-data">
<div class="form-group">
<b><text class="col-lg-2 control-label">Match Number: </text></b>
<div class="col-lg-10">
<input type="text" class="form-control" id="matchNum" name="matchNum" placeholder=" " value="<?php echo ((isset($_GET["matchNum"])) ? htmlspecialchars($_GET["matchNum"]) : ""); ?>">
</div>
</div>
<br></br>
<div class="form-group">
<b><text class="col-lg-2 control-label">Name: </text></b>
<div class="col-lg-10">
<input type="text" class="form-control" id="name" name="name" placeholder=" ">
</div>
</div>
<div class="col-lg-2">
<b><br>Auto Balls Scored by Red Alliance: </b>
</div>
<div class="col-lg-10">
<input type="text" class="form-control" id="TotalAutoRed" name="TotalAutoRed" placeholder=" ">
<br>
</div>
<div class="col-lg-2">
<b><br>Auto Balls Scored by Blue Alliance: </b>
</div>
<div class="col-lg-10">
<input type="text" class="form-control" id="TotalAutoBlue" name="TotalAutoBlue" placeholder=" ">
<br>
</div>
<div class="col-lg-2">
<b><br>Which Alliance will get more climb points:</b>
</div>
<div class="col-lg-10">
<select name="BlueScorePredict" class="form-control">
<option value="" disabled selected>Choose option</option>
<option value='blue'>Blue</option>
<option value='red'>Red</option>
<option value='equal'>Equal</option>
</select>
</div>
<div class="col-lg-2">
<b><br>Which Alliance will Win: </b>
</div>
<div class="col-lg-10">
<select name="Winner" class="form-control">
<option value="" disabled selected>Choose Winner</option>
<option value='blue'>Blue</option>
<option value='red'>Red</option>
<option value='Tie'>Tie</option>
</select>
<br>
</div>
<div class="col-lg-2">
<b><br>Margin of Victory:</b>
</div>
<div class="col-lg-10">
<input type="text" class="form-control" id="RedScorePredict" name="RedScorePredict" placeholder=" ">
</div>
<div class="col-lg-12 col-sm-12 col-xs-12">
<input id="Bet" type="submit" class="btn btn-primary" value="Submit Data" onclick="">
</form>
</div>
<br>
</div>
</div>
<style>
/* The container */
.container2 {
display: inline-block;
position: relative;
cursor: pointer;
font-size: 22px;
bottom: 10px;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
/* Hide the browser's default checkbox */
.container2 input {
position: absolute;
opacity: 0;
cursor: pointer;
height: 0;
width: 0;
margin-left: 100%;
}
/* Create a custom checkbox */
.checkmark {
position: absolute;
top: 0;
left: 0;
height: 25px;
width: 25px;
background-color: #eee;
border-radius: 5px;
}
.container:hover input~.checkmark {
background-color: orange;
}
.container2 input:checked~.checkmark {
background-color: rgb(15, 129, 120);
}
/* Create the checkmark/indicator (hidden when not checked) */
.checkmark:after {
content: "";
position: absolute;
display: none;
}
/* Show the checkmark when checked */
.container2 input:checked~.checkmark:after {
display: block;
}
/* Style the checkmark/indicator */
.container2 .checkmark:after {
left: 9px;
top: 5px;
width: 5px;
height: 10px;
border: solid white;
border-width: 0 3px 3px 0;
-webkit-transform: rotate(45deg);
-ms-transform: rotate(45deg);
transform: rotate(45deg);
}
</style>
<?php include("footer.php"); ?>