mirror of
https://github.com/searxng/searxng.git
synced 2025-08-03 02:22:22 +02:00
[enh] add supported_languages on engines and auto-generate languages.py
This commit is contained in:
parent
e58949b76f
commit
149802c569
34 changed files with 666 additions and 128 deletions
|
@ -36,7 +36,7 @@ content_xpath = './/div[@class="text-container typo typo_text_m typo_line_m orga
|
|||
|
||||
|
||||
def request(query, params):
|
||||
lang = params['language'].split('_')[0]
|
||||
lang = params['language'].split('-')[0]
|
||||
host = base_url.format(tld=language_map.get(lang) or default_tld)
|
||||
params['url'] = host + search_url.format(page=params['pageno'] - 1,
|
||||
query=urlencode({'text': query}))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue