5 Copyright (C) 2015 Felix Kästner, consearch @ f p u n k t k . de
7 This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
9 This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
11 You should have received a copy of the GNU General Public License along with this program; if not, see http://www.gnu.org/licenses/.
15 if ( isset($_GET['dse']) and preg_match('/^[0-9a-z]{1,5}$/', $_GET['dse']) === 1 ) { // TODO: prevent injection, check whether dse is a valid searchengine
19 if ( isset($_GET['get']) and $_GET['get'] === "opensearchdescription" ) {
20 echo '<?xml version="1.0" encoding="UTF-8"?>
21 <OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/">
22 <ShortName>consearch';
23 if ( $dse ) { echo " ($dse)"; }
25 <Description>conveniently use different searchengines</Description>
26 <Tags>consearch</Tags>
27 <Contact>consearch @ f p u n k t k . de</Contact>
28 <Url type="text/html" template="https://www.fpunktk.de/consearch/index.php';
29 if ( $dse ) { echo "?dse=$dse"; }
30 echo '#{searchTerms}" />
31 <Image height="16" width="16" type="image/png">https://www.fpunktk.de/consearch/consearch.png</Image>
32 </OpenSearchDescription>';
41 <meta charset="UTF-8">
42 <meta http-equiv="content-type" content="text/html; charset=UTF-8">
43 <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
44 <title>consearch</title>
45 <link rel="icon" href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAACMuuz63rNKAAAAK0lEQVQI12P4/58BiM4cZ9gdDUVnboNE/n8Hoc6JDLvLGLrLGF4DyWlAcQBYKBgvsgbJOAAAAABJRU5ErkJggg==" type="image/png">
46 <link rel="search" type="application/opensearchdescription+xml" href="index.php?get=opensearchdescription<?php if ( $dse ) { echo "&dse=$dse"; } ?>" title="consearch<?php if ( $dse ) { echo " ($dse)"; } ?>">
48 <style type="text/css">
56 background-color: #8CBAEC;
58 margin: 0ex auto 10mm;
74 margin: 0px -5px 3mm 0px; /* trbl */
77 border: 1px solid black;
78 width: 13ex; /* 13ex 11ch */
79 width: 11ch; /* used twice because some browsers don't understand it */
89 <script type="text/javascript">
91 var b64images = new Object();
92 b64images["az.png"] = "iVBORw0KGgoAAAANSUhEUgAAABAAAAAQEAYAAABPYyMiAAAABmJLR0T///////8JWPfcAAAACXBIWXMAAABIAAAASABGyWs+AAACxklEQVRIx62Vy0/TQRDHf0BpES8gnkAKXjAYSIjhgAeMCf4VeMELBhMvJIAgUEBSD/QPwHjkYeUEJ+ACnuSREB6BXohRoKYQXk1bCGrbrzM7bhb6sPHxuUx/292d787MzlpQOBxiBwfFHh0hDd8VwIECOFYkz4srEkcPD8X294u12y354Xan3sBs8VIBVFbeJYCSklsEUFZWTgD3FMD8/AciebfUx+nr+yUgHE6n/LkCsBRATo6NAIqKbhJAbq7DwfHT43l51wjgkwIZODmx0in9rDCOtW1peUYAXxWA1/ueAGy2XMLMGxsbJ9I5Nn6sdFPOzs4J4I0CaGtrJ4BQKBzmeP1QAJsKoLDwBmEEuN2vCWTESlc8ial4pwAeKoCqqmoCcDrLCE6FnWABWQQwMPCK+AsBiTQ2PibMyex2yXl1tQhoaHhEAPn514nLAph/EDA6OkYk10BXl9wGHaHd3T0CKCgoJP5jBJqbnxJmQy1gYeEjYeYtKDgFughlfnt7B5GpL/xGQEfHC8I4zsrKJoD6+gcER4gBSkudhPlfX8fs7BwC2NuTCP1xBPQ1M7m9mgpty8tvE0Bd3X3CjFdU3CFYgN/P+6TulUpAPB6L8UA0enGR3LO+KExOm5qeEMBbhWnJ3xTA8LBc29PTYDAUkva7uMj7bmz09vJ3MMjXNkUE1ta6u9n91pbHI53A789cRFpwcn5jsWiU7eamNPr1dZeLrc/n8SQ1ItEq7O/PzbGdnOReD8zO1tbKwqEhtgcHUoTh8M6OrOWOCQQCsm51tbOT7dQUvxHA0hIX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jhUMTY6NTY6NTArMDE6MDBB6/VSAAAAAElFTkSuQmCC";
100 b64images["sh.png"] = "iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAACXBIWXMAAABIAAAASABGyWs+AAAA+VBMVEU5gqrgrR82f6jfqBw3gqo4gqs4g6s5g6tBiK9Dia9Fi7BGi7FHjLFMj7NTk7Zemrtmn75noL92qcV/r8mAr8mNt86UvNKcwdWewtaixdioyNq10N+60+LJ3ejN4OrS4+zY5+/a6O/fqx7frCDfrCHfrSHgriXhsS3isjHitTjjtjnjtjvjtz3kuUPkukblvErlvU7mvU7mvlDnwVrrynLr8vbs8/ftz3/w9vnx2pzx257x3KHy36jy9/nz4a325772+fv36cT36cX3+vv579T79OL79eP89uf8/f38/f79+vH9/v7++/X+/Pf+/Pj+/fn+/fr+/fv///8t5hX9AAAABHRSTlNaWuDgiHwzrgAAAAFiS0dEUg1gLZAAAACxSURBVBgZPcEHQsJQAAPQ0H6NAxXEvRCCW9xbcRdx4Mj9D2OLlveAiJzuuKd7EBcQheFl564Ug5xz342EQdZsfyfJy9vP54mEMHpm+1brG1t7TUkII6e2k/NmQz3gQNWZr+fL4zVJICvOPWxLIFlZ9b+7usBMaXal5VR3VyADM8UFp44EhuLU5MT42NCMU4cCOW+/P7UuXm1/7Ajkkvse60LERefa+4qBqHzvP9ebigu/AGwyxwJqEuAAAAAldEVYdGRhdGU6Y3JlYXRlADIwMTUtMDUtMjJUMTg6MTk6NDArMDI6MDCIMpBxAAAAJXRFWHRkYXRlOm1vZGlmeQAyMDE1LTA1LTIyVDE4OjE5OjIzKzAyOjAwDug71wAAAABJRU5ErkJggg==";
101 b64images["uu.png"] = "iVBORw0KGgoAAAANSUhEUgAAABAAAAAQEAIAAADAAbR1AAAABnRSTlMAAAAAAABupgeRAAAABmJLR0T///////8JWPfcAAAACXBIWXMAAABIAAAASABGyWs+AAAAMklEQVQ4y2NgwAC/f3d3YyMh4NGj8HBsJAlg1IKBB1eukEOOW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MTMtMTAtMjhUMTY6NTY6NTUrMDE6MDAT09r1AAAAAElFTkSuQmCC";
104 b64images["yt.png"] = "iVBORw0KGgoAAAANSUhEUgAAABAAAAAQEAYAAABPYyMiAAAABmJLR0T///////8JWPfcAAAACXBIWXMAAABIAAAASABGyWs+AAABV0lEQVRIx8VUO24CMRD1AaighQaugoREQ8UVtkTcgJqWDiIaOj4CKR3bI0EDAmkRoUWCDtOwDZ+JncXxb511siR5zezM88w8j+1F8IDnDYeVCkCtViwmEvCJfN5xBgOATmcy2e3g6UBa4AMAGHe7ov9b0Eqv16MRnQRrrO7cdRuNQoHzjlOvz2b6Bkx+pIDzeb/v9XjiZnO93u8Avi/H1QZs3b8LaLer1VTKLChSgO8fDv2+WPhyud04Px7rRzCdct7z5CNkl9hawF+DCHgjoJ+5XDIpWzrKsHg8m80GdrulfREnTDAXDARGr/vKovgFnyhALlgul0qiz0Zn4hlcArEe808njKldLlerHwlQJ6Tzcn6z2WqFCYwh4Hu8KiD8DlkIYCNUwfj5fLEQ468EYr0XAosJHI/pNP1xMItxJiP6tpblqfkYy7wggAKh6Odmf7vt1gd93wGWV/JQKq7UWwAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAxNC0wNy0xMVQxNzowNTo0NyswMjowMKiZycMAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMTMtMTAtMjhUMTY6NTY6NTYrMDE6MDAiO8BoAAAAAElFTkSuQmCC";
105 b64images["imdb.png"] = "iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAaVBMVEUAAAC6pB303yPx3CPu1yPq0yPmziPiyCPfxSPcwCN4bREAAACplBoQDgKUgxczLAjXvSLCrh5tYBF0aREjHwVYTA5qWxFbUA6RfxeulB1xZBGhixq5oh4OCwLUtiPRsyLNrSLGpCKLexYQiDEbAAAAAXRSTlMAQObYZgAAAAlwSFlzAAAASAAAAEgARslrPgAAAHFJREFUGBkFwTFSAzEAADGtbXAITApK/v9AOhguuSABACgAwBJ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+Pn6+/z9D21gkgAAAAFiS0dEAIgFHUgAAADOSURBVBjTY2BgYGDhZ0AFqq7iXLIK3AzCPFABxWRtn4QeXzUzHaiAUllXVmJ1UlSGBITP69XZU9qdXlESywwRkHfv6enIrs0s8uCECHCFNPaEFfYARTVEmUACWjFtLrnBleHlad5yIL5QSm6rrZFPZ0RVnnMgB1BA1NHJICfe3s/fLdVBAKRCzCa/Jci8oMaz3E4KbCafcXN7XEeoqZWuIcQSacuGps68np66ehNBsAA7q2aAdXtkcXSHvjLU6RwiFnoqMpLqHAj/sjHCmQCutDB5t6/XDgAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAxNS0wNS0xOFQxNDo1OTowMSswMjowMCdFvu4AAAAldEVYdGRhdGU6bW9kaWZ5ADIwMTUtMDUtMThUMTQ6NTg6MjkrMDI6MDDIECR2AAAAAElFTkSuQmCC";
112 // for f in *.ico; do for q in {0..100}; do convert -quality $q $f ${f%*.ico}$q.png; done; echo "b64images[\"${f%*.ico}.png\"] = \"$(base64 $(\ls -1S ${f%*.ico}*.png | tail -n 1) | tr -d '\n')\";"; done
114 // for f in *.png; do echo "b64images[\"${f}\"] = \"$(base64 $f | tr -d '\n')\";"; done > tmp.js
117 var se = new Object(); // object of search engines
118 // se["keyword"] = ["displayed name, max 7 chars", "url to which the querystring can be append", "b64images name"];
119 se["ii"] = ["ixquick", "https://eu.ixquick.com/do/search?q=", "ixquick.png"];
120 se["id"] = ["ixq_de", "https://eu.ixquick.com/do/search?l=deutsch&q=", "ixquick.png"];
121 se["wp"] = ["wp_de", "https://de.wikipedia.org/wiki/Spezial:Search?search=", "wp.png"];
122 se["wpe"] = ["wp_en", "https://en.wikipedia.org/wiki/Special:Search?search=", "wp.png"];
123 se["sp"] = ["strtpge", "https://startpage.com/do/search?query=", "sp.png"];
124 se["dd"] = ["dd_go", "https://duckduckgo.com/html/?ka=n&kh=1&kl=wt-wt&kp=-1&kt=n&kv=1&ky=-1&q=", "dd.png"];
125 se["gg"] = ["google", "https://www.google.com/search?hl=de&safe=off&q=", "gg.png"];
126 se["si"] = ["sp_img", "https://startpage.com/do/search?cat=pics&query=", "sp.png"];
127 se["gi"] = ["gg_img", "https://www.google.com/images?hl=de&safe=off&q=", "gg.png"];
128 se["wb"] = ["wb", "http://www.woerterbuch.info/?query=", "wb.png"];
129 se["leo"] = ["leo", "https://dict.leo.org/ende/index_en.html#/searchLoc=0&resultOrder=basic&multiwordShowSingle=on&search=", "leo.png"];
130 se["ud"] = ["ud", "http://www.urbandictionary.com/define.php?term=", "ud.png"];
131 se["gt"] = ["gg_tl", "https://translate.google.de/?hl=de&tab=wT#en|de|", "gg.png"];
132 se["osm"] = ["osm", "https://www.openstreetmap.org/?query=", "osm.png"];
133 se["gm"] = ["g-maps", "https://www.google.de/maps/preview?hl=de&q=", "gm.png"];
134 se["uu"] = ["uu_wiki", "http://wiki.ubuntuusers.de/", "uu.png"];
135 se["man"] = ["u_man", "http://manpages.ubuntu.com/cgi-bin/search.py?ie=UTF-8&titles=Title&q=", "man-u.png"];
136 se["ups"] = ["ups", "http://packages.ubuntu.com/search?searchon=names&suite=all§ion=all&keywords=", "man-u.png"];
137 se["yt"] = ["youtube", "https://www.youtube.com/results?search_query=", "yt.png"];
138 se["imdb"] = ["imdb", "http://www.imdb.com/find?s=all&q=", "imdb.png"];
139 se["az"] = ["amazon", "https://www.amazon.de/s/?url=search-alias%3Daps&field-keywords=", "az.png"];
140 se["php"] = ["php.net", "http://de2.php.net/manual-lookup.php?lang=de&pattern=", "php.png"];
141 se["sh"] = ["slfhtml", "https://wiki.selfhtml.org/index.php?search=", "sh.png"];
142 se["down"] = ["down", "http://www.downforeveryoneorjustme.com/", "down.png"];
143 se["fefe"] = ["fefe", "https://blog.fefe.de/?q=", ""];
144 se["wtr"] = ["wtr-ol", "http://www.wetteronline.de/?searchpcid=pc_city_weather&searchpid=p_city_weather&pid=p_search&searchstring=", ""];
145 se["wtrc"] = ["wtr.com", "http://www.wetter.com/suche/?o=location&q=", ""];
146 se["gh"] = ["github", "https://github.com/search?utf8=✓&q=", ""];
147 se["bb"] = ["bing", "https://www.bing.com/search?q=", ""];
148 se["mdn"] = ["mdn", "https://developer.mozilla.org/search?q=", ""];
149 se["ctan"] = ["ctan", "http://ctan.org/search/?phrase=", ""];
150 se["gpg"] = ["gpg_key", "https://pgp.mit.edu/pks/lookup?op=index&fingerprint=on&search=", ""];
152 function display_searchbuttons() {
153 document.getElementById("searchbuttons").innerHTML = "";
155 document.getElementById("searchbuttons").innerHTML += '<button type="button" value="' + se[kw][0] + '" onclick=\'location.href="' + se[kw][1] + '" + document.getElementById("querystring").value\'><img src="data:image/png;base64,' + b64images[se[kw][2]] + '" alt=""> ' + se[kw][0] + "</button> \n";
159 function parse_fragmentstring() {
160 var fragmentstring = document.URL.substr( document.URL.split("#")[0].length + 1 );
161 if ( fragmentstring == "" ) {
162 display_searchbuttons();
163 document.getElementById("querystring").focus();
165 fragmentarr = fragmentstring.replace("%20", "+").split("+");
168 // first word in query is a search engine keyword
170 location.href = se[kw][1] + fragmentarr.join(" ");
174 // use a default searchengine
175 echo ' if ( kw != "nd" ) {
176 location.href = se["' . $dse . '"][1] + fragmentarr.join(" ");
179 document.getElementById("querystring").value = fragmentarr.join(" ");
180 display_searchbuttons();
184 // display all buttons and write the fragmentstring into the querystring input
185 echo ' document.getElementById("querystring").value = fragmentarr.join(" ");
186 display_searchbuttons();
197 <body onload="parse_fragmentstring();">
199 <h1><a href="">fpunktk.de/consearch</a></h1>
202 <p style="color: red; font-size: 200%; font-weight: bold;">
203 please enable javascript
208 <label><input id="querystring" type="text"></label>
211 <div id="searchbuttons">
215 <a href="https://github.com/fpunktk/consearch">about</a>