浏览代码

[fix] gigablast https + url params

Adam Tauber 9 年前
父节点
当前提交
47b4a85fe3
共有 1 个文件被更改,包括 5 次插入5 次删除
  1. 5
    5
      searx/engines/gigablast.py

+ 5
- 5
searx/engines/gigablast.py 查看文件

@@ -1,8 +1,8 @@
1 1
 """
2 2
  Gigablast (Web)
3 3
 
4
- @website     http://gigablast.com
5
- @provide-api yes (http://gigablast.com/api.html)
4
+ @website     https://gigablast.com
5
+ @provide-api yes (https://gigablast.com/api.html)
6 6
 
7 7
  @using-api   yes
8 8
  @results     XML
@@ -22,8 +22,8 @@ paging = True
22 22
 number_of_results = 5
23 23
 
24 24
 # search-url, invalid HTTPS certificate
25
-base_url = 'http://gigablast.com/'
26
-search_string = 'search?{query}&n={number_of_results}&s={offset}&xml=1&qh=0&uxid={uxid}&rand={rand}'
25
+base_url = 'https://gigablast.com/'
26
+search_string = 'search?{query}&n={number_of_results}&s={offset}&format=xml&qh=0&rxiyd={rxiyd}&rand={rand}'
27 27
 
28 28
 # specific xpath variables
29 29
 results_xpath = '//response//result'
@@ -40,7 +40,7 @@ def request(query, params):
40 40
         query=urlencode({'q': query}),
41 41
         offset=offset,
42 42
         number_of_results=number_of_results,
43
-        uxid=randint(10000, 10000000),
43
+        rxiyd=randint(10000, 10000000),
44 44
         rand=int(time()))
45 45
 
46 46
     params['url'] = base_url + search_path