-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgreeting_video.html
More file actions
96 lines (89 loc) · 3.54 KB
/
Copy pathgreeting_video.html
File metadata and controls
96 lines (89 loc) · 3.54 KB
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>SignConnect | Greeting Video</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet">
<link href="https://unpkg.com/aos@2.3.1/dist/aos.css" rel="stylesheet">
<style>
body {
background: linear-gradient(to right, #e0f7fa, #e1f5fe);
font-family: 'Segoe UI', sans-serif;
min-height: 100vh;
display: flex;
flex-direction: column;
}
.main-content {
flex: 1;
}
.navbar {
background: linear-gradient(to right, #43cea2, #185a9d);
}
.logo-img {
height: 40px;
margin-right: 10px;
}
</style>
</head>
<body>
<!-- Navbar -->
<nav class="navbar navbar-expand-lg navbar-dark shadow">
<div class="container">
<a class="navbar-brand d-flex align-items-center" href="index.html">
<img src="assets/logo.png" alt="Logo" class="logo-img">
<span>SignConnect</span>
</a>
<div class="collapse navbar-collapse">
<ul class="navbar-nav ms-auto">
<li class="nav-item"><a class="nav-link" href="index.html">Home</a></li>
<li class="nav-item"><a class="nav-link" href="numbers.html">Numbers</a></li>
<li class="nav-item"><a class="nav-link" href="dashboard.html">Dashboard</a></li>
</ul>
</div>
</div>
</nav>
<!-- Main Content -->
<div class="container text-center main-content py-5">
<h1 id="video-title" class="text-primary mb-4"></h1>
<video id="video-player" width="640" height="360" controls>
<source id="video-source" src="" type="video/mp4">
Your browser does not support the video tag.
</video>
<div class="mt-4">
<a href="greetings.html" class="btn btn-primary">Back to Greetings Learning</a>
</div>
</div>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
<script src="https://unpkg.com/aos@2.3.1/dist/aos.js"></script>
<script>
AOS.init();
// Video links for each greeting
const videoLinks = {
"GoodAfternoon": "Basic_Greetings/GoodAfternoon.mp4",
"GoodEvening": "Basic_Greetings/GoodEvening.mp4",
"GoodMorning": "Basic_Greetings/GoodMorning.mp4",
"GoodNight": "Basic_Greetings/GoodNight.mp4",
"Hello": "Basic_Greetings/Hello.mp4",
"Hi": "Basic_Greetings/Hi.mp4",
"Namaste": "Basic_Greetings/Namaste.mp4"
};
// Get the greeting from the URL query parameter
const urlParams = new URLSearchParams(window.location.search);
const greeting = urlParams.get('greeting');
// Elements for video and title
const videoPlayer = document.getElementById('video-player');
const videoSource = document.getElementById('video-source');
const videoTitle = document.getElementById('video-title');
// Check if a valid greeting was provided
if (greeting && videoLinks[greeting]) {
videoTitle.textContent = `Sign for ${greeting}`;
videoSource.src = videoLinks[greeting];
videoPlayer.load();
videoPlayer.play();
} else {
videoTitle.textContent = "Invalid Greeting";
videoSource.src = "";
}
</script>
</body>
</html>