summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--search.html9
1 files changed, 7 insertions, 2 deletions
diff --git a/search.html b/search.html
index c35817d..ed9efab 100644
--- a/search.html
+++ b/search.html
@@ -4,8 +4,8 @@ layout: page
<script src="/assets/js/lunr.min.js"></script>
<p>
-<input></input>
-<button>Submit</button>
+<input id="input_qterm"></input>
+<button id="qsubmit">Submit</button>
</p>
<h1>Search results for <span id="qterm"></span></h1>
@@ -64,4 +64,9 @@ layout: page
document.getElementById("results").appendChild(el);
}
document.getElementById("qterm").textContent = queryterm;
+
+ const qbox = document.getElementById("input_qterm");
+ document.getElementById("qsubmit").onclick = ev => {
+ alert(qbox.value);
+ };
</script>