Spaces:
Running
Running
Update index.html
Browse files- index.html +18 -30
index.html
CHANGED
@@ -7,25 +7,7 @@
|
|
7 |
<link rel="stylesheet" href="style.css" />
|
8 |
<script>
|
9 |
|
10 |
-
|
11 |
-
let url = String(url_in)
|
12 |
-
console.log(url);
|
13 |
-
|
14 |
-
var framediv = document.getElementById('cap');
|
15 |
-
let child = framediv.lastElementChild;
|
16 |
-
while (child) {
|
17 |
-
framediv.removeChild(child);
|
18 |
-
child=framediv.lastElementChild;
|
19 |
-
}
|
20 |
-
const iframediv = document.createElement('iframe');
|
21 |
-
iframediv.src = 'https://docs.google.com/viewer?url=' + url +'&embedded=true';
|
22 |
-
iframediv.width = '100%';
|
23 |
-
iframediv.height = '1000px';
|
24 |
-
iframediv.frameborder="0";
|
25 |
-
framediv.appendChild(iframediv);
|
26 |
-
}
|
27 |
-
function () {
|
28 |
-
const urlParams = new URLSearchParams(window.location.search);
|
29 |
var p_pdf = urlParams.get('pdfurl')
|
30 |
var p_mod = urlParams.get('mod')
|
31 |
var p_len = urlParams.get('len')
|
@@ -56,21 +38,27 @@ function () {
|
|
56 |
console.log(p_pau)
|
57 |
} else {
|
58 |
p_pau = "1";
|
59 |
-
};
|
60 |
-
|
61 |
-
|
62 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
63 |
}
|
|
|
|
|
64 |
</script>
|
65 |
</head>
|
66 |
<body>
|
67 |
-
<div
|
68 |
-
<h1>Welcome to your static Space!</h1>
|
69 |
-
<p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
|
70 |
-
<p>
|
71 |
-
Also don't forget to check the
|
72 |
-
<a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
|
73 |
-
</p>
|
74 |
</div>
|
75 |
</body>
|
76 |
</html>
|
|
|
7 |
<link rel="stylesheet" href="style.css" />
|
8 |
<script>
|
9 |
|
10 |
+
const urlParams = new URLSearchParams(window.location.search);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
11 |
var p_pdf = urlParams.get('pdfurl')
|
12 |
var p_mod = urlParams.get('mod')
|
13 |
var p_len = urlParams.get('len')
|
|
|
38 |
console.log(p_pau)
|
39 |
} else {
|
40 |
p_pau = "1";
|
41 |
+
};
|
42 |
+
|
43 |
+
var framediv = document.getElementById('cap');
|
44 |
+
let child = framediv.lastElementChild;
|
45 |
+
while (child) {
|
46 |
+
framediv.removeChild(child);
|
47 |
+
child=framediv.lastElementChild;
|
48 |
+
}
|
49 |
+
const iframediv = document.createElement('iframe');
|
50 |
+
iframediv.src = 'https://broadfield-fast-voice-full.hf.space/?pdfurl=' + p_pdf+'&mod='+p_mod+'&len='+p_len+'&nos='+p_nos+'&wid='+p_wid+'&pau='+p_pau;
|
51 |
+
iframediv.width = '100%';
|
52 |
+
iframediv.height = '1000px';
|
53 |
+
iframediv.frameborder="0";
|
54 |
+
framediv.appendChild(iframediv);
|
55 |
}
|
56 |
+
|
57 |
+
})
|
58 |
</script>
|
59 |
</head>
|
60 |
<body>
|
61 |
+
<div id='cap'>
|
|
|
|
|
|
|
|
|
|
|
|
|
62 |
</div>
|
63 |
</body>
|
64 |
</html>
|