Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added a score history page on clicking score history button #77

Merged
merged 2 commits into from
Jan 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions QuickQuiz
Submodule QuickQuiz added at 11a36c
5 changes: 2 additions & 3 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ <h1>Kviz</h1>
<div class="flex-row">
<a class="btn" href="/Dark/index.html">Dark Theme</a>
<a class="btn" href="/Light/index.html">Light Theme</a>
<a class="btn" href="#" onclick="toggleScoreHistory()">Score History</a>
<a class="btn" href="score.html">Score History</a>
</div>
</div>

Expand All @@ -36,8 +36,7 @@ <h1>Kviz</h1>

<!-- Score History Section -->
<div id="score-history">
<h2>Score History</h2>
<ul id="score-list"></ul>

</div>
</body>
</html>
Expand Down
84 changes: 84 additions & 0 deletions score.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Score History</title>
<style>
body {
font-family: Arial, sans-serif;
margin: 20px;
background-color: #f0f0f0;
}

h1 {
text-align: center;
color: #333;
}

table {
width: 100%;
border-collapse: collapse;
margin-top: 20px;
background-color: #fff;
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

th, td {
border: 1px solid #ddd;
padding: 12px;
text-align: left;
}

th {
background-color: #f2f2f2;
}

tbody tr:nth-child(even) {
background-color: #f9f9f9;
}

tbody tr:hover {
background-color: #e0e0e0;
}
</style>
</head>
<body>

<h1>Score History</h1>

<table>
<thead>
<tr>
<th>Date</th>
<th>Player</th>
<th>Score</th>
</tr>
</thead>
<tbody>
<tr>
<td>2024-01-25</td>
<td>Player 1</td>
<td>1500</td>
</tr>
<tr>
<td>2024-01-24</td>
<td>Player 2</td>
<td>1200</td>
</tr>
<tr>
<td>2024-01-23</td>
<td>Player 3</td>
<td>1800</td>
</tr>
<tr>
<td>2024-01-22</td>
<td>Player 4</td>
<td>1350</td>
</tr>
<!-- Add more rows as needed -->
</tbody>
</table>

</body>
</html>