Update index.html
Browse files- index.html +10 -3
index.html
CHANGED
@@ -15,6 +15,8 @@
|
|
15 |
<meta property="og:description" content="Video Player"/>
|
16 |
<meta property="og:image" content="https://huggingface.co/datasets/jbilcke-hf/ai-tube-index/resolve/main/videos/165a6c81-3747-44a4-93a5-46b87353cd02.webp"/>
|
17 |
<!--meta http-equiv="refresh" content="0; url=https://jbilcke-hf-ai-tube.hf.space/"-->
|
|
|
|
|
18 |
<style>
|
19 |
.container {
|
20 |
position: relative;
|
@@ -48,11 +50,16 @@
|
|
48 |
const urlParams = new URLSearchParams(queryString);
|
49 |
const vid = urlParams.get("video");
|
50 |
console.log(vid)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
51 |
document.getElementById("myFrame").src = vid;
|
52 |
|
53 |
-
document.querySelector('meta[name="twitter:player"]').setAttribute("content", "https://omnibus-video-card.static.hf.space/index.html?video="+vid);
|
54 |
-
document.querySelector('meta[name="twitter:stream"]').setAttribute("content", "https://omnibus-video-card.static.hf.space/index.html?video="+vid);
|
55 |
-
|
56 |
</script>
|
57 |
</body>
|
58 |
</html>
|
|
|
15 |
<meta property="og:description" content="Video Player"/>
|
16 |
<meta property="og:image" content="https://huggingface.co/datasets/jbilcke-hf/ai-tube-index/resolve/main/videos/165a6c81-3747-44a4-93a5-46b87353cd02.webp"/>
|
17 |
<!--meta http-equiv="refresh" content="0; url=https://jbilcke-hf-ai-tube.hf.space/"-->
|
18 |
+
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
|
19 |
+
|
20 |
<style>
|
21 |
.container {
|
22 |
position: relative;
|
|
|
50 |
const urlParams = new URLSearchParams(queryString);
|
51 |
const vid = urlParams.get("video");
|
52 |
console.log(vid)
|
53 |
+
$('meta[name=twitter:player]').remove();
|
54 |
+
$('meta[name=twitter:stream]').remove();
|
55 |
+
$('head').append( '<meta name="twitter:player" content="https://omnibus-video-card.static.hf.space/index.html?video="+vid>' );
|
56 |
+
$('head').append( '<meta name="twitter:stream" content="https://omnibus-video-card.static.hf.space/index.html?video="+vid>' );
|
57 |
+
console.log($('meta[name=twitter:player]').attr('content'));
|
58 |
+
console.log($('meta[name=twitter:stream]').attr('content'));
|
59 |
+
//document.querySelector('meta[name="twitter:player"]').setAttribute("content", "https://omnibus-video-card.static.hf.space/index.html?video="+vid);
|
60 |
+
//document.querySelector('meta[name="twitter:stream"]').setAttribute("content", "https://omnibus-video-card.static.hf.space/index.html?video="+vid);
|
61 |
document.getElementById("myFrame").src = vid;
|
62 |
|
|
|
|
|
|
|
63 |
</script>
|
64 |
</body>
|
65 |
</html>
|