pub / serci

Search the web with !keywords
git clone https://https://src.jayvii.de/pub/serci.git
Home | Log | Files | Exports | Refs | README | RSS

commit ca790c29734691489483489a183e7bb8d2a514ca
parent 7a75a30f13b9108eb90bbff3d9947357d9ed4534
Author: JayVii <jayvii[AT]posteo[DOT]de>
Date:   Thu, 17 Oct 2024 21:55:57 +0200

fix: re-structure FAQs

Diffstat:
Mindex.php | 215+++++++++++++++++++++++++++++++++++++++++++++----------------------------------
1 file changed, 122 insertions(+), 93 deletions(-)

diff --git a/index.php b/index.php @@ -265,103 +265,132 @@ } ?> - <hr> - <h3 id="faqs">About serĉi</h3> - <?php $fsi = array_key_first($searches); /* Used within examples */ ?> + <!-- FAQs / About-Section --> + <section id="faqs"> - <h4>What does serĉi mean?</h4> - <p> - It is the Esperanto term for - <a - href="https://m.dict.cc/esperanto-english/ser%C4%89i.html" - target="_blank" - > - to search - </a>. - This may not be the most creative name for such a software project, - but to the best of my knowledge, it is a unique one. - </p> + <?php + /* Used within examples */ + $fsi = array_key_first($searches); + ?> - <h4>What are keywords?</h4> - <p> - An idea lent from the search Engine - <a href="https://duckduckgo.com/bangs" target="_blank"> - DuckDuckGo - </a>, which has been utilized by many others since. They call their - keywords bangs, but it is the same concept and usability. In - essence, keywords are shortcuts for searching on other websites. - </p> - <p> - For example, you can conduct a search on the website - <a href="<?php echo $searches[$fsi]["website"]; ?>" target="_blank"> - <?php echo $searches[$fsi]["name"]; ?> - </a> - directly from <?php echo $_SERVER["SERVER_NAME"]; ?> by adding the - keyword <code>!<?php echo $searches[$fsi]["keywords"][0]; ?></code> - to your search query. - </p> - <p> - You can find all keywords associated with each search engine in the - <a href="#engines">list above</a>. - </p> + <h3>About serĉi</h3> - <h4>How can I use serĉi?</h4> - <p> - You can try serĉi directly <a href="#searchbar">on this site</a> or - <a href="https://src.jayvii.de/pub/serci" target="_blank"> - host it yourself - </a>! It barely needs any server resources, no database or lots of - RAM. serĉi has minimal footprint (also on user data: there are - <strong>NONE</strong>). - </p> - <p> - Either type your search directly into the - <a href="#searchbar">search bar at the very top</a> - or add the search to your browser by rightclicking in the URL-bar of - your web browser and choose - <emph>add serĉi - Search with !keywords</emph>. - </p> - <p> - Some browsers (for example Firefox on Android / Fennec) allow to - configure custom search engines via a so-called search URL. Simply - list following URL as <emph>search-URL</emph> there and choose it as - your default search option: - </p> - <pre>https://<?php echo $_SERVER["SERVER_NAME"]; ?>/?q=%s</pre> - <p> - You can also choose the default search engine, used by serĉi as - fallback, when no keyword is given, through the URL instead of - choosing it from the <a href="#engines">list above</a>, in case you - do not want serĉi to store any cookie on your device. For example, - if you wanted to use - <a href="<?php echo $searches[$fsi]["website"]; ?>" target="_blank"> - <?php echo $searches[$fsi]["name"]; ?> - </a> - as your default search, you could use following search-URL: - </p> - <pre><?php - echo "https://" . $_SERVER["SERVER_NAME"] . - "/?default_search=" . $fsi . "&q=%s"; - ?></pre> + <!-- meaning of name --> + <h4>What does serĉi mean?</h4> + <p> + It is the Esperanto term for + <a + href="https://m.dict.cc/esperanto-english/ser%C4%89i.html" + target="_blank" + > + to search + </a>. + This may not be the most creative name for such a software + project but to the best of my knowledge, it is a unique one. + </p> - <h4>Choosing a default search without cookies or Javascript</h4> - <p> - You can simply choose a default search by adding the - <code>default_search</code> URL parameter. For example, if you - wanted to use - <a href="<?php echo $searches[$fsi]["website"]; ?>" target="_blank"> - <?php echo $searches[$fsi]["name"]; ?> - </a> - as your default search, you can simply add - <code>/?default_search=<?php echo $fsi; ?></code> to the serĉi URL: - <br> - <a href="/?default_search=<?php echo $fsi; ?>"> - <?php - echo "https://" . $_SERVER["SERVER_NAME"] . - "/?default_search=" . $fsi; - ?> - </a> - </p> + <!-- what are keywords --> + <h4>What are keywords?</h4> + <p> + An idea lent from the search Engine + <a href="https://duckduckgo.com/bangs" target="_blank"> + DuckDuckGo + </a>, which has been utilized by many others since. They call + their keywords bangs, but it is the same concept and usability. + In essence, keywords are shortcuts for searching on other + websites. + </p> + <p> + For example, you can conduct a search on the website + <a + href="<?php echo $searches[$fsi]["website"]; ?>" + target="_blank" + > + <?php echo $searches[$fsi]["name"]; ?> + </a> + directly from <?php echo $_SERVER["SERVER_NAME"]; ?> by adding + the keyword + <code>!<?php echo $searches[$fsi]["keywords"][0]; ?></code> to + your search query. + </p> + <p> + You can find all keywords associated with each search engine in + the <a href="#engines">list above</a>. + </p> + + <!-- no js or cookies --> + <h4>Choosing a default search without cookies or Javascript</h4> + <p> + You can simply choose a default search by adding the + <code>default_search</code> URL parameter. For example, if you + wanted to use + <a + href="<?php echo $searches[$fsi]["website"]; ?>" + target="_blank" + > + <?php echo $searches[$fsi]["name"]; ?> + </a> + as your default search, you can simply add + <code>/?default_search=<?php echo $fsi; ?></code> to the serĉi + URL: + <br> + <a href="/?default_search=<?php echo $fsi; ?>"> + <?php + echo "https://" . $_SERVER["SERVER_NAME"] . + "/?default_search=" . $fsi; + ?> + </a> + </p> + + <!-- how to use --> + <h4>How can I use serĉi?</h4> + <p> + You can try serĉi directly <a href="#searchbar">on this site</a> + or + <a + href="https://src.jayvii.de/pub/serci/#hosting" + target="_blank" + > + host it yourself + </a>! + It barely needs any server resources, no database or lots of + RAM. serĉi has minimal footprint (also on user data: there are + <strong>NONE</strong>). + </p> + <p> + Either type your search directly into the + <a href="#searchbar">search bar at the very top</a> + or add the search to your browser by rightclicking in the + URL-bar of your web browser and choose + <emph>add serĉi - Search with !keywords</emph>. + </p> + <p> + Some browsers (for example Firefox on Android / Fennec) allow to + configure custom search engines via a so-called search URL. + Simply list following URL as <emph>search-URL</emph> there and + choose it as your default search option: + </p> + <pre>https://<?php echo $_SERVER["SERVER_NAME"]; ?>/?q=%s</pre> + <p> + You can also choose the default search engine, used by serĉi as + fallback, when no keyword is given, through the URL instead of + choosing it from the <a href="#engines">list above</a>, in case + you do not want serĉi to store any cookie on your device. For + example, if you wanted to use + <a + href="<?php echo $searches[$fsi]["website"]; ?>" + target="_blank" + > + <?php echo $searches[$fsi]["name"]; ?> + </a> + as your default search, you could use following search-URL: + </p> + <pre><?php + echo "https://" . $_SERVER["SERVER_NAME"] . + "/?default_search=" . $fsi . "&q=%s"; + ?></pre> + + </section> </body>