jordonpeter01 commited on
Commit
848a109
·
verified ·
1 Parent(s): 1bf1310

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +38 -17
index.html CHANGED
@@ -1,19 +1,40 @@
1
- <!doctype html>
2
  <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <meta name="viewport" content="width=device-width" />
6
- <title>My static Space</title>
7
- <link rel="stylesheet" href="style.css" />
8
- </head>
9
- <body>
10
- <div class="card">
11
- <h1>Welcome to your static Space!</h1>
12
- <p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
13
- <p>
14
- Also don't forget to check the
15
- <a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
16
- </p>
17
- </div>
18
- </body>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
19
  </html>
 
1
+ <!DOCTYPE html>
2
  <html>
3
+ <head>
4
+ <title>Player de vídeo estilo YouTube</title>
5
+ <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css">
6
+ </head>
7
+ <body>
8
+ <div class="container">
9
+ <div class="row">
10
+ <div class="col-md-8 offset-md-2">
11
+ <h1>Player de vídeo</h1>
12
+ <form id="video-form">
13
+ <div class="form-group">
14
+ <label for="video-url">URL do vídeo:</label>
15
+ <input type="text" class="form-control" id="video-url" placeholder="Cole a URL do vídeo">
16
+ </div>
17
+ <button type="submit" class="btn btn-primary">Reproduzir</button>
18
+ </form>
19
+ <div id="video-player" class="mt-4"></div>
20
+ </div>
21
+ </div>
22
+ </div>
23
+ <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"></script>
24
+ <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js"></script>
25
+ <script>
26
+ $(document).ready(function() {
27
+ $("#video-form").submit(function(event) {
28
+ event.preventDefault();
29
+ var videoUrl = $("#video-url").val();
30
+ var videoPlayer = `
31
+ <video width="640" height="480" controls>
32
+ <source src="${videoUrl}" type="video/mp4">
33
+ </video>
34
+ `;
35
+ $("#video-player").html(videoPlayer);
36
+ });
37
+ });
38
+ </script>
39
+ </body>
40
  </html>