1
0
mirror of https://github.com/searxng/searxng.git synced 2024-11-09 14:40:11 +01:00
searxng/searx/templates/simple/opensearch.xml

22 lines
1.3 KiB
XML
Raw Normal View History

2014-08-18 10:44:46 +02:00
<?xml version="1.0" encoding="utf-8"?>
[fix] improve OpenSearch description Some HTTP-Clients do have issues with the ``opensearch.xml`` from SearXNG (related [1][2]) while other OpenSearch descriptions[3] (e.g. from qwant) work flawles. Inspired by the OpenSearch description from qwant and with informations from the specification[4] the ``opensearch.xml`` has been *improved*. - convert `<Url>` methods from lower case to upper case (`POST`|`GET`) - add `<moz:SearchForm>` and `xmlns:moz="http://www.mozilla.org/2006/browser/search/"` - add `<Query role="example" searchTerms="SearXNG" />` [4] OpenSearch description documents should include at least one Query element of `role="example"` that is expected to return search results. Search clients may use this example query to validate that the search engine is working properly. - modified `<LongName>` to SearXNG - modified `<Description>` the word 'hackable' scares uninitiated users and was removed - add the `type="image/png"` to `<Image>` Test can be done by:: make run Visit http://127.0.0.1:8888/ and add the search engine to your WEB-Browser / test with different WEB-Browser from desktop and Smartphones (are there any iOS user here, please test on Safari and Chrome). [1] https://app.element.io/#/room/#searxng:matrix.org/$xN_abdKhNqUlgXRBrb_9F3pqOxnSzGQ1TG0s0G9hQVw [2] https://github.com/searxng/searxng/issues/431 [3] https://developer.mozilla.org/en-US/docs/Web/OpenSearch [4] https://github.com/dewitt/opensearch/blob/master/opensearch-1-1-draft-6.md#the-query-element Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2022-08-11 18:37:12 +02:00
<OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/" xmlns:moz="http://www.mozilla.org/2006/browser/search/">
<ShortName>{{ instance_name }}</ShortName>
[fix] improve OpenSearch description Some HTTP-Clients do have issues with the ``opensearch.xml`` from SearXNG (related [1][2]) while other OpenSearch descriptions[3] (e.g. from qwant) work flawles. Inspired by the OpenSearch description from qwant and with informations from the specification[4] the ``opensearch.xml`` has been *improved*. - convert `<Url>` methods from lower case to upper case (`POST`|`GET`) - add `<moz:SearchForm>` and `xmlns:moz="http://www.mozilla.org/2006/browser/search/"` - add `<Query role="example" searchTerms="SearXNG" />` [4] OpenSearch description documents should include at least one Query element of `role="example"` that is expected to return search results. Search clients may use this example query to validate that the search engine is working properly. - modified `<LongName>` to SearXNG - modified `<Description>` the word 'hackable' scares uninitiated users and was removed - add the `type="image/png"` to `<Image>` Test can be done by:: make run Visit http://127.0.0.1:8888/ and add the search engine to your WEB-Browser / test with different WEB-Browser from desktop and Smartphones (are there any iOS user here, please test on Safari and Chrome). [1] https://app.element.io/#/room/#searxng:matrix.org/$xN_abdKhNqUlgXRBrb_9F3pqOxnSzGQ1TG0s0G9hQVw [2] https://github.com/searxng/searxng/issues/431 [3] https://developer.mozilla.org/en-US/docs/Web/OpenSearch [4] https://github.com/dewitt/opensearch/blob/master/opensearch-1-1-draft-6.md#the-query-element Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2022-08-11 18:37:12 +02:00
<LongName>SearXNG metasearch</LongName>
<Description>SearXNG is a metasearch engine that respects your privacy.</Description>
2014-08-18 10:44:46 +02:00
<InputEncoding>UTF-8</InputEncoding>
[fix] improve OpenSearch description Some HTTP-Clients do have issues with the ``opensearch.xml`` from SearXNG (related [1][2]) while other OpenSearch descriptions[3] (e.g. from qwant) work flawles. Inspired by the OpenSearch description from qwant and with informations from the specification[4] the ``opensearch.xml`` has been *improved*. - convert `<Url>` methods from lower case to upper case (`POST`|`GET`) - add `<moz:SearchForm>` and `xmlns:moz="http://www.mozilla.org/2006/browser/search/"` - add `<Query role="example" searchTerms="SearXNG" />` [4] OpenSearch description documents should include at least one Query element of `role="example"` that is expected to return search results. Search clients may use this example query to validate that the search engine is working properly. - modified `<LongName>` to SearXNG - modified `<Description>` the word 'hackable' scares uninitiated users and was removed - add the `type="image/png"` to `<Image>` Test can be done by:: make run Visit http://127.0.0.1:8888/ and add the search engine to your WEB-Browser / test with different WEB-Browser from desktop and Smartphones (are there any iOS user here, please test on Safari and Chrome). [1] https://app.element.io/#/room/#searxng:matrix.org/$xN_abdKhNqUlgXRBrb_9F3pqOxnSzGQ1TG0s0G9hQVw [2] https://github.com/searxng/searxng/issues/431 [3] https://developer.mozilla.org/en-US/docs/Web/OpenSearch [4] https://github.com/dewitt/opensearch/blob/master/opensearch-1-1-draft-6.md#the-query-element Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2022-08-11 18:37:12 +02:00
<Image type="image/png">{{ url_for('static', filename='img/favicon.png', _external=True) }}</Image>
{% if opensearch_method == 'GET' %}
<Url rel="results" type="text/html" method="{{ opensearch_method }}" template="{{ url_for('search', _external=True) }}?q={searchTerms}"/>
2014-08-18 10:44:46 +02:00
{% else %}
[fix] improve OpenSearch description Some HTTP-Clients do have issues with the ``opensearch.xml`` from SearXNG (related [1][2]) while other OpenSearch descriptions[3] (e.g. from qwant) work flawles. Inspired by the OpenSearch description from qwant and with informations from the specification[4] the ``opensearch.xml`` has been *improved*. - convert `<Url>` methods from lower case to upper case (`POST`|`GET`) - add `<moz:SearchForm>` and `xmlns:moz="http://www.mozilla.org/2006/browser/search/"` - add `<Query role="example" searchTerms="SearXNG" />` [4] OpenSearch description documents should include at least one Query element of `role="example"` that is expected to return search results. Search clients may use this example query to validate that the search engine is working properly. - modified `<LongName>` to SearXNG - modified `<Description>` the word 'hackable' scares uninitiated users and was removed - add the `type="image/png"` to `<Image>` Test can be done by:: make run Visit http://127.0.0.1:8888/ and add the search engine to your WEB-Browser / test with different WEB-Browser from desktop and Smartphones (are there any iOS user here, please test on Safari and Chrome). [1] https://app.element.io/#/room/#searxng:matrix.org/$xN_abdKhNqUlgXRBrb_9F3pqOxnSzGQ1TG0s0G9hQVw [2] https://github.com/searxng/searxng/issues/431 [3] https://developer.mozilla.org/en-US/docs/Web/OpenSearch [4] https://github.com/dewitt/opensearch/blob/master/opensearch-1-1-draft-6.md#the-query-element Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2022-08-11 18:37:12 +02:00
<Url rel="results" type="text/html" method="{{ opensearch_method }}" template="{{ url_for('search', _external=True) }}">
<Param name="q" value="{searchTerms}" />
</Url>
{% endif %}
{% if autocomplete %}
[fix] improve OpenSearch description Some HTTP-Clients do have issues with the ``opensearch.xml`` from SearXNG (related [1][2]) while other OpenSearch descriptions[3] (e.g. from qwant) work flawles. Inspired by the OpenSearch description from qwant and with informations from the specification[4] the ``opensearch.xml`` has been *improved*. - convert `<Url>` methods from lower case to upper case (`POST`|`GET`) - add `<moz:SearchForm>` and `xmlns:moz="http://www.mozilla.org/2006/browser/search/"` - add `<Query role="example" searchTerms="SearXNG" />` [4] OpenSearch description documents should include at least one Query element of `role="example"` that is expected to return search results. Search clients may use this example query to validate that the search engine is working properly. - modified `<LongName>` to SearXNG - modified `<Description>` the word 'hackable' scares uninitiated users and was removed - add the `type="image/png"` to `<Image>` Test can be done by:: make run Visit http://127.0.0.1:8888/ and add the search engine to your WEB-Browser / test with different WEB-Browser from desktop and Smartphones (are there any iOS user here, please test on Safari and Chrome). [1] https://app.element.io/#/room/#searxng:matrix.org/$xN_abdKhNqUlgXRBrb_9F3pqOxnSzGQ1TG0s0G9hQVw [2] https://github.com/searxng/searxng/issues/431 [3] https://developer.mozilla.org/en-US/docs/Web/OpenSearch [4] https://github.com/dewitt/opensearch/blob/master/opensearch-1-1-draft-6.md#the-query-element Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2022-08-11 18:37:12 +02:00
<Url rel="suggestions" type="application/x-suggestions+json" method="{{ opensearch_method }}" template="{{ url_for('autocompleter', _external=True) }}?q={searchTerms}"/>
2014-08-18 10:44:46 +02:00
{% endif %}
<Url rel="self" type="application/opensearchdescription+xml" method="{{ opensearch_method }}" template="{{ url_for('opensearch', _external=True) }}" />
[fix] improve OpenSearch description Some HTTP-Clients do have issues with the ``opensearch.xml`` from SearXNG (related [1][2]) while other OpenSearch descriptions[3] (e.g. from qwant) work flawles. Inspired by the OpenSearch description from qwant and with informations from the specification[4] the ``opensearch.xml`` has been *improved*. - convert `<Url>` methods from lower case to upper case (`POST`|`GET`) - add `<moz:SearchForm>` and `xmlns:moz="http://www.mozilla.org/2006/browser/search/"` - add `<Query role="example" searchTerms="SearXNG" />` [4] OpenSearch description documents should include at least one Query element of `role="example"` that is expected to return search results. Search clients may use this example query to validate that the search engine is working properly. - modified `<LongName>` to SearXNG - modified `<Description>` the word 'hackable' scares uninitiated users and was removed - add the `type="image/png"` to `<Image>` Test can be done by:: make run Visit http://127.0.0.1:8888/ and add the search engine to your WEB-Browser / test with different WEB-Browser from desktop and Smartphones (are there any iOS user here, please test on Safari and Chrome). [1] https://app.element.io/#/room/#searxng:matrix.org/$xN_abdKhNqUlgXRBrb_9F3pqOxnSzGQ1TG0s0G9hQVw [2] https://github.com/searxng/searxng/issues/431 [3] https://developer.mozilla.org/en-US/docs/Web/OpenSearch [4] https://github.com/dewitt/opensearch/blob/master/opensearch-1-1-draft-6.md#the-query-element Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
2022-08-11 18:37:12 +02:00
<Query role="example" searchTerms="SearXNG" />
<moz:SearchForm>{{ url_for('search', _external=True) }}</moz:SearchForm>
2014-08-18 10:44:46 +02:00
</OpenSearchDescription>