summaryrefslogtreecommitdiff
path: root/searx/engines/duckduckgo.py
diff options
context:
space:
mode:
authorDalf <alex@al-f.net>2014-01-05 13:58:17 +0100
committerDalf <alex@al-f.net>2014-01-05 13:58:17 +0100
commitbf56ec4fb1199ab46feeacb8a045d28b287baf47 (patch)
tree072296037bb52f8deae26e2f64b338fa8b50bd7c /searx/engines/duckduckgo.py
parent49c85fce51c2b8431013d9269999eac5a6a9c038 (diff)
downloadsearxng-bf56ec4fb1199ab46feeacb8a045d28b287baf47.tar.gz
searxng-bf56ec4fb1199ab46feeacb8a045d28b287baf47.zip
[mod] bing and duckduckgo engines : add / rename locale parameter
Diffstat (limited to 'searx/engines/duckduckgo.py')
-rw-r--r--searx/engines/duckduckgo.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/searx/engines/duckduckgo.py b/searx/engines/duckduckgo.py
index d591854a5..4bf770972 100644
--- a/searx/engines/duckduckgo.py
+++ b/searx/engines/duckduckgo.py
@@ -3,10 +3,11 @@ from urllib import urlencode
from searx.utils import html_to_text
url = 'https://duckduckgo.com/'
-search_url = url + 'd.js?{query}&l=us-en&p=1&s=0'
+search_url = url + 'd.js?{query}&p=1&s=0'
+locale = 'us-en'
def request(query, params):
- params['url'] = search_url.format(query=urlencode({'q': query}))
+ params['url'] = search_url.format(query=urlencode({'q': query, 'l': locale}))
return params