summaryrefslogtreecommitdiff
path: root/search_cgi
diff options
context:
space:
mode:
authorHiltjo Posthuma <hiltjo@codemadness.org>2020-01-10 21:24:04 +0100
committerKatolaZ <katolaz@freaknet.org>2020-01-11 05:49:53 +0000
commitcfc0cf2ef6d86f50df5b91b2a1dbe358713100f8 (patch)
tree4b2e38bce1a65444c669b1a5ef0c079cf8e77a48 /search_cgi
parent870f04f257a54bcecce171542329819b4db0537c (diff)
search_cgi: minor UI tweaks
- autofocus input field. - make labels for radio boxes clickable to select the corresponding input.
Diffstat (limited to 'search_cgi')
-rwxr-xr-xsearch_cgi10
1 files changed, 5 insertions, 5 deletions
diff --git a/search_cgi b/search_cgi
index 1c8b791..9f47c26 100755
--- a/search_cgi
+++ b/search_cgi
@@ -22,11 +22,11 @@ print_head(){
echo "body{padding: 20px; margin: 40px auto;line-height: 1.6;font-size: 18px; color:#444;}"
echo "</style></head>"
echo "<body><div>Search for: </div><form method='GET' action='/cgi-bin/search_cgi'>"
- echo "<div><input type='text' name='query'></input></div>"
- echo "<div>in: <input type='radio' name='type' value='url' checked>url</input>"
- echo "<input type='radio' name='type' value='descr'>description</input>"
- echo "<input type='radio' name='type' value='read'>readme</input>"
- echo "<input type='radio' name='type' value='all'>all</input>"
+ echo "<div><input type='text' name='query' autofocus></input></div>"
+ echo "<div>in: <input type='radio' name='type' id="type_url" value='url' checked><label for="type_url">url</label></input>"
+ echo "<input type='radio' name='type' id="type_descr" value='descr'><label for="type_descr">description</label></input>"
+ echo "<input type='radio' name='type' id="type_readme" value='read'><label for="type_readme">readme</label></input>"
+ echo "<input type='radio' name='type' id="type_all" value='all'><label for="type_all">all</label></input>"
echo "</div>"
echo "<input type='submit' value='Search!'></input>"
echo "</form>"