-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhackathons.html
215 lines (195 loc) · 9.75 KB
/
hackathons.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
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Karla:wght@400;500;700&display=swap" rel="stylesheet">
<script src="https://kit.fontawesome.com/8663eb90fc.js" crossorigin="anonymous"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" href="css/hackathons.css">
<title>Hackathons | SoCollab</title>
<!-- Credits to: https://www.webslesson.info/2017/04/csv-file-to-html-table-using-ajax-jquery.html -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js"></script>
<!-- <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" /> -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script>
// This reads the External Hackathons
$(document).ready(function () {
$('#load_data_external').click(function () {
$.ajax({
url: "assets/Hackathons & Competitions For School of Computing - External Hackathons.csv",
dataType: "text",
success: function (data) {
var csv_data = data.split(/\r?\n|\r/);
var table_data = '<table class="table table-bordered table-striped">';
for (var count = 0; count < csv_data.length; count++) {
var cell_data = csv_data[count].split(",");
table_data += '<tr>';
for (var cell_count = 0; cell_count < cell_data.length; cell_count++) {
if (count === 0) {
table_data += '<th>' + cell_data[cell_count] + '</th>';
}
else {
table_data += '<td>' + cell_data[cell_count] + '</td>';
}
}
table_data += '</tr>';
}
table_data += '</table>';
$('#external_hackathons_table').html(table_data);
}
});
});
});
</script>
<script>
// This reads the Internal Hackathons
$(document).ready(function () {
$('#load_data_internal').click(function () {
$.ajax({
url: "assets/Hackathons & Competitions For School of Computing - Internal Hackathons.csv",
dataType: "text",
success: function (data) {
var csv_data = data.split(/\r?\n|\r/);
var table_data = '<table class="table table-bordered table-striped">';
for (var count = 0; count < csv_data.length; count++) {
var cell_data = csv_data[count].split(",");
table_data += '<tr>';
for (var cell_count = 0; cell_count < cell_data.length; cell_count++) {
if (count === 0) {
table_data += '<th>' + cell_data[cell_count] + '</th>';
}
else {
table_data += '<td>' + cell_data[cell_count] + '</td>';
}
}
table_data += '</tr>';
}
table_data += '</table>';
$('#internal_hackathons_table').html(table_data);
}
});
});
});
</script>
<script>
// This function is to manage the tabs
function openTabs(evt, tabName) {
// Declare all variables
var i, tabcontent, tablinks;
// Get all elements with class="tabcontent" and hide them
tabcontent = document.getElementsByClassName("tabcontent");
for (i = 0; i < tabcontent.length; i++) {
tabcontent[i].style.display = "none";
}
// Get all elements with class="tablinks" and remove the class "active"
tablinks = document.getElementsByClassName("tablinks");
for (i = 0; i < tablinks.length; i++) {
tablinks[i].className = tablinks[i].className.replace(" active", "");
}
// Show the current tab, and add an "active" class to the button that opened the tab
document.getElementById(tabName).style.display = "block";
evt.currentTarget.className += " active";
}
</script>
</head>
<body>
<!-- <div id="navbar">
<img src="assets/logo.png" width="40" id="logo">
<p id="logo">NUS Computing Club</p>
<div id="options">
<p><a href="index.html">Home</a></p>
<p><a href="seniorsharings.html">Senior Sharings</a></p>
<p><a href="pilotproject.html">Pilot Project</a></p>
<p><a href="medium.html">Medium</a></p>
<p><a style="color: #78e08f;" href="hackathons.html">Hackathons</a></p>
</div>
</div> -->
<div class="socollab-navbar">
<div class="socollab-active">
<img src="assets/logo.png" width="40" style="padding-left:10px; padding-top:8px; background-color: #60a3bc;" id="socollab-logo">
</div>
<!-- Navigation links (hidden by default) -->
<div id="socollab-links">
<p><a href="index.html">Home</a></p>
<p><a href="seniorsharings.html">Senior Sharings</a></p>
<p><a href="pilotprojects.html">Pilot Projects</a></p>
<p><a href="medium.html">Medium</a></p>
<p><a href="hackathons.html">Hackathons</a></p>
</div>
<!-- "Hamburger menu" / "Bar icon" to toggle the navigation links -->
<a href="javascript:void(0);" class="socollabicon" onclick="myFunction()">
<i class="fa fa-bars"></i>
</a>
</div>
<div id="main-container">
<img src="assets/banner_hackathon.jpg" alt="Hackathons" id="banner-hackathon-img">
<p id="about-para">
Due to the overwhelming amount of hacakthons which take place both within and outside NUS, the Academic
Wing
has come up with this excel tracker which allows all students from the School of Computing to easily
navigate through a range of hackathons offered. This way we ensure students do not miss opportunities
and
make the most out of their university life.
</p>
<div class="tab">
<button class="tablinks" name="load_data_external" id="load_data_external"
onclick="openTabs(event, 'External Hackathons')" style="color:white">External Hackathons</button>
<button class="tablinks" name="load_data_internal" id="load_data_internal"
onclick="openTabs(event, 'Internal Hackathons')" style="color:white">Internal Hackathons</button>
</div>
<!-- Tab content -->
<div id="External Hackathons" class="tabcontent">
<div class="container">
<div class="table-responsive">
<div id="external_hackathons_table"></div>
</div>
</div>
</div>
<div id="Internal Hackathons" class="tabcontent">
<div class="container">
<div class="table-responsive">
<div id="internal_hackathons_table"></div>
</div>
</div>
</div>
</div>
<div id="footer">
<div id="footer-details">
<!-- <p id="footer-logo">NUS Computing Club</p> -->
<img src="assets/footer_logo.png" id="footer-logo">
<div id="socials">
<a target="_blank" href="https://www.facebook.com/nuscomputing"><i
class="fa-brands fa-facebook-f"></i></a>
<a target="_blank" href="https://www.instagram.com/NUSComputingClub"><i
class="fa-brands fa-instagram"></i></a>
<a target="_blank" href="https://t.me/nuscomputingclub"><i class="fa-brands fa-telegram"></i></a>
<a target="_blank" href="https://www.youtube.com/channel/UCVd-qsSFF328UUqcNxudy0w"><i
class="fa-brands fa-youtube"></i></a>
<a target="_blank" href="https://github.com/NUSComputingDev"><i class="fa-brands fa-github"></i></a>
<a target="_blank" href="mailto:[email protected]"><i class="fa-solid fa-envelope"></i></a>
</div>
<p id="disclaimers">
Copyright © NUS Students' Computing Club • <a style="text-decoration: none; color: white;"
href="https://nuscomputing.com/privacy/">Privacy Policy</a>
</p>
</div>
<!-- <p id="feedback" style="line-height: 35px;">
Got feedback? Send it our way! <br> <a target="_blank" href="https://feedback.nuscomputing.com">feedback.nuscomputing.com</a>
</p> -->
</div>
<script>
function myFunction() {
var x = document.getElementById("socollab-links");
if (x.style.display === "block") {
x.style.display = "none";
} else {
x.style.display = "block";
}
}
</script>
</body>
</html>