Spaces:
Build error
Build error
Commit
·
4128a8b
1
Parent(s):
c3eb0fd
Update templates/index.html
Browse files- templates/index.html +42 -44
templates/index.html
CHANGED
@@ -1,46 +1,44 @@
|
|
1 |
-
<!DOCTYPE html>
|
2 |
<html>
|
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 |
-
</body>
|
46 |
</html>
|
|
|
|
|
1 |
<html>
|
2 |
+
<head>
|
3 |
+
<title>Dubbing Video</title>
|
4 |
+
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
|
5 |
+
</head>
|
6 |
+
<body>
|
7 |
+
<h1>Dubbing Video</h1>
|
8 |
+
<form action="{{ url_for('dub_video') }}" method="post" enctype="multipart/form-data">
|
9 |
+
<label for="video_file">Upload Video:</label>
|
10 |
+
<input type="file" name="video_file" id="video_file">
|
11 |
+
<br><br>
|
12 |
+
<label for="video_url">Import from URL:</label>
|
13 |
+
<input type="text" name="video_url" id="video_url">
|
14 |
+
<br><br>
|
15 |
+
<label for="language">Select Language:</label>
|
16 |
+
<select name="language" id="language">
|
17 |
+
<option value="hi">Hindi</option>
|
18 |
+
</select>
|
19 |
+
<br><br>
|
20 |
+
<input type="submit" value="Dub Video">
|
21 |
+
</form>
|
22 |
+
{% if result %}
|
23 |
+
<br><br>
|
24 |
+
<a href="{{ result }}" download>Download Dubbed Video</a>
|
25 |
+
{% endif %}
|
26 |
+
<br><br>
|
27 |
+
{% if progress %}
|
28 |
+
<div id="progress-bar" style="width: 500px; height: 20px; border: 1px solid #ccc;">
|
29 |
+
<div id="progress" style="height: 100%; width: {{ progress }}%; background-color: #4CAF50;"></div>
|
30 |
+
</div>
|
31 |
+
{% endif %}
|
32 |
+
<script>
|
33 |
+
function updateProgress(progress) {
|
34 |
+
$("#progress").css("width", progress + "%");
|
35 |
+
}
|
36 |
+
$(document).ready(function() {
|
37 |
+
var source = new EventSource("/progress");
|
38 |
+
source.onmessage = function(event) {
|
39 |
+
updateProgress(event.data);
|
40 |
+
};
|
41 |
+
});
|
42 |
+
</script>
|
43 |
+
</body>
|
|
|
44 |
</html>
|