mirror of
https://github.com/searxng/searxng
synced 2024-01-01 18:24:07 +00:00
[fix] opensearch autocomplete
This commit is contained in:
parent
52a817f5c1
commit
879bac8adb
@ -6,7 +6,7 @@
|
||||
<LongName>searx metasearch</LongName>
|
||||
{% if method == 'get' %}
|
||||
<Url type="text/html" method="get" template="{{ host }}?q={searchTerms}"/>
|
||||
{% if client.autocompleter %}
|
||||
{% if autocomplete %}
|
||||
<Url type="application/x-suggestions+json" method="get" template="{{ host }}autocompleter">
|
||||
<Param name="format" value="x-suggestions" />
|
||||
<Param name="q" value="{searchTerms}" />
|
||||
@ -16,7 +16,7 @@
|
||||
<Url type="text/html" method="post" template="{{ host }}">
|
||||
<Param name="q" value="{searchTerms}" />
|
||||
</Url>
|
||||
{% if client.autocompleter %}
|
||||
{% if autocomplete %}
|
||||
<!-- TODO, POST REQUEST doesn't work -->
|
||||
<Url type="application/x-suggestions+json" method="get" template="{{ host }}autocompleter">
|
||||
<Param name="format" value="x-suggestions" />
|
||||
|
@ -350,7 +350,6 @@ def preferences():
|
||||
|
||||
return resp
|
||||
return render('preferences.html',
|
||||
client=settings.get('client', None),
|
||||
locales=settings['locales'],
|
||||
current_locale=get_locale(),
|
||||
current_language=lang or 'all',
|
||||
@ -369,7 +368,6 @@ def stats():
|
||||
return render(
|
||||
'stats.html',
|
||||
stats=stats,
|
||||
client=settings.get('client', None)
|
||||
)
|
||||
|
||||
|
||||
@ -392,8 +390,7 @@ def opensearch():
|
||||
|
||||
ret = render('opensearch.xml',
|
||||
method=method,
|
||||
host=get_base_url(),
|
||||
client=settings['client'])
|
||||
host=get_base_url())
|
||||
|
||||
resp = Response(response=ret,
|
||||
status=200,
|
||||
|
Loading…
Reference in New Issue
Block a user