From 8df1f0c47e03fe7525c40a2856dba950bab8998b Mon Sep 17 00:00:00 2001 From: Markus Heiser Date: Mon, 1 Aug 2022 17:01:59 +0200 Subject: [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 --- searx/engines/google_images.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'searx/engines/google_images.py') diff --git a/searx/engines/google_images.py b/searx/engines/google_images.py index a65c0ce37..e1f676dd6 100644 --- a/searx/engines/google_images.py +++ b/searx/engines/google_images.py @@ -51,6 +51,7 @@ paging = False use_locale_domain = True time_range_support = True safesearch = True +send_accept_language_header = True filter_mapping = {0: 'images', 1: 'active', 2: 'active'} @@ -125,7 +126,6 @@ def request(query, params): """Google-Video search request""" lang_info = get_lang_info(params, supported_languages, language_aliases, False) - logger.debug("HTTP header Accept-Language --> %s", lang_info['headers']['Accept-Language']) query_url = ( 'https://' -- cgit v1.2.3