mirror of
https://github.com/searxng/searxng.git
synced 2025-07-13 00:09:18 +02:00
[mod] add 'Accept-Language' HTTP header to online processores
Most engines that support languages (and regions) use the Accept-Language from the WEB browser to build a response that fits to the language (and region). - add new engine option: send_accept_language_header Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
This commit is contained in:
parent
a2badb4fe4
commit
8df1f0c47e
21 changed files with 52 additions and 26 deletions
|
@ -440,6 +440,7 @@ engine is shown. Most of the options have a default value or even are optional.
|
|||
engine: example
|
||||
shortcut: demo
|
||||
base_url: 'https://{language}.example.com/'
|
||||
send_accept_language_header: false
|
||||
categories: general
|
||||
timeout: 3.0
|
||||
api_key: 'apikey'
|
||||
|
@ -488,6 +489,13 @@ engine is shown. Most of the options have a default value or even are optional.
|
|||
use multiple sites using only one engine, or updating the site URL without
|
||||
touching at the code.
|
||||
|
||||
``send_accept_language_header`` :
|
||||
Several engines that support languages (or regions) deal with the HTTP header
|
||||
``Accept-Language`` to build a response that fits to the locale. When this
|
||||
option is activated, the language (locale) that is selected by the user is used
|
||||
to build and send a ``Accept-Language`` header in the request to the origin
|
||||
search engine.
|
||||
|
||||
``categories`` : optional
|
||||
Define in which categories this engine will be active. Most of the time, it is
|
||||
defined in the code of the engine, but in a few cases it is useful, like when
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue