Update index.html
Browse files- index.html +4 -4
index.html
CHANGED
|
@@ -95,11 +95,11 @@
|
|
| 95 |
event.preventDefault();
|
| 96 |
const text = document.getElementById("embed-input").value;
|
| 97 |
fetch("/embed", {
|
| 98 |
-
method: "
|
| 99 |
headers: {
|
| 100 |
"Content-Type": "application/json"
|
| 101 |
},
|
| 102 |
-
body: JSON.stringify({
|
| 103 |
})
|
| 104 |
.then(response => response.json())
|
| 105 |
.then(data => {
|
|
@@ -112,11 +112,11 @@
|
|
| 112 |
const text = document.getElementById("search-input").value;
|
| 113 |
const n = document.getElementById("n-input").value;
|
| 114 |
fetch("/search", {
|
| 115 |
-
method: "
|
| 116 |
headers: {
|
| 117 |
"Content-Type": "application/json"
|
| 118 |
},
|
| 119 |
-
body: JSON.stringify({
|
| 120 |
})
|
| 121 |
.then(response => response.json())
|
| 122 |
.then(data => {
|
|
|
|
| 95 |
event.preventDefault();
|
| 96 |
const text = document.getElementById("embed-input").value;
|
| 97 |
fetch("/embed", {
|
| 98 |
+
method: "POST",
|
| 99 |
headers: {
|
| 100 |
"Content-Type": "application/json"
|
| 101 |
},
|
| 102 |
+
body: JSON.stringify({query: text})
|
| 103 |
})
|
| 104 |
.then(response => response.json())
|
| 105 |
.then(data => {
|
|
|
|
| 112 |
const text = document.getElementById("search-input").value;
|
| 113 |
const n = document.getElementById("n-input").value;
|
| 114 |
fetch("/search", {
|
| 115 |
+
method: "POST",
|
| 116 |
headers: {
|
| 117 |
"Content-Type": "application/json"
|
| 118 |
},
|
| 119 |
+
body: JSON.stringify({query: text, n: n})
|
| 120 |
})
|
| 121 |
.then(response => response.json())
|
| 122 |
.then(data => {
|