-
Notifications
You must be signed in to change notification settings - Fork 4
/
index.html
65 lines (62 loc) · 1.95 KB
/
index.html
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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Upload photos for Yearbook 2016</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
<style media="screen">
body {
text-align: center;
background-color: #564946;
color: white;
}
.main-div {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -60%);
}
.footer {
position: absolute;
bottom: 3px;
right: 6px;
font-size: 20px;
color: white;
}
</style>
</head>
<body>
<div class="footer">
Designed and Maintained by the
Students' Alumni Cell.
</div>
<div class="container-fluid main-div">
<div class="col-md-3">
</div>
<div class="col-md-6">
<h1>Yearbook Center 2016</h1>
<h3>Enter your roll number to begin uploading photos:</h3>
<form class="" id="rollnumber" action="addRollToSession.php" method="post">
<input class="form-control" type="text" name="rollnumber" value="" placeholder="Roll Number" required>
<br>
<input class="btn btn-lg btn-success" type="submit" value="Submit Roll Number">
</form>
</div>
<div class="col-md-3">
</div>
</div>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script src="//netdna.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
<script>
$(document).ready(function () {
$('form#rollnumber').on('submit', function (e) {
if (!$("input[name=rollnumber]").val().toUpperCase().match(/[0-9]{2}[A-Z]{2}[0-9A-Z]{5}/g)) {
alert('Invalid Roll Number.\nIt should be something like 15TH****');
e.preventDefault();
}
});
});
</script>
</body>
</html>