X-Git-Url: https://fpunktk.de/gitweb/?p=consearch.git;a=blobdiff_plain;f=index.php;h=3f1966dc993291449dcfece9a5dbc18444627075;hp=c87d1444519d33d4f1e2d24cef17720662d3cdb3;hb=4da2fde952254a7571c58fbf3085917f2846fe2c;hpb=bab4c7311008f2083613f3b4cea4804742911f0f;ds=sidebyside diff --git a/index.php b/index.php index c87d144..3f1966d 100644 --- a/index.php +++ b/index.php @@ -72,7 +72,9 @@ input { } button { margin: 0px -5px 3mm 0px; /* trbl */ - padding: -4px; + padding: 3px; + background: none; + border: 1px solid black; width: 13ex; /* 13ex 11ch */ width: 11ch; /* used twice because some browsers don't understand it */ height: 13mm; @@ -138,8 +140,10 @@ se["yt"] = ["youtube", "https://www.youtube.com/results?search_query=", "yt.png" se["imdb"] = ["imdb", "http://www.imdb.com/find?s=all&q=", "imdb.png"]; se["az"] = ["amazon", "https://www.amazon.de/s/?url=search-alias%3Daps&field-keywords=", "az.png"]; se["php"] = ["php.net", "http://de2.php.net/manual-lookup.php?lang=de&pattern=", "php.png"]; -se["sh"] = ["slfhtml", "http://de.selfhtml.org/navigation/suche/index.htm?Suchanfrage=", "sh.png"]; +se["sh"] = ["slfhtml", "https://wiki.selfhtml.org/index.php?search=", "sh.png"]; se["down"] = ["down", "http://www.downforeveryoneorjustme.com/", "down.png"]; +se["fefe"] = ["fefe", "https://blog.fefe.de/?q=", ""]; +se["wtr"] = ["wtr.com", "http://www.wetter.com/suche/?o=location&q=", ""]; function display_searchbuttons() { document.getElementById("searchbuttons").innerHTML = ""; @@ -155,17 +159,22 @@ function parse_fragmentstring() { document.getElementById("querystring").focus(); } else { fragmentarr = fragmentstring.replace("%20", "+").split("+"); - if ( se[fragmentarr[0]] ) { - // first word in query is a keyword - kw = fragmentarr[0]; + kw = fragmentarr[0]; + if ( se[kw] ) { + // first word in query is a search engine keyword fragmentarr.shift(); location.href = se[kw][1] + fragmentarr.join(" "); } else { - // there is no keyword