diff --git a/searx/engines/__init__.py b/searx/engines/__init__.py index 96b074ae9..73a63f0a3 100644 --- a/searx/engines/__init__.py +++ b/searx/engines/__init__.py @@ -53,6 +53,8 @@ if not 'engines' in settings or not settings['engines']: for engine_data in settings['engines']: engine_name = engine_data['engine'] engine = load_module(engine_name + '.py') + if not hasattr(engine, 'paging'): + engine.paging = False for param_name in engine_data: if param_name == 'engine': continue @@ -156,7 +158,7 @@ def score_results(results): return sorted(results, key=itemgetter('score'), reverse=True) -def search(query, request, selected_engines): +def search(query, request, selected_engines, pageno=1): global engines, categories, number_of_searches requests = [] results = {} @@ -171,10 +173,14 @@ def search(query, request, selected_engines): engine = engines[selected_engine['name']] + if pageno > 1 and not engine.paging: + continue + request_params = default_request_params() request_params['headers']['User-Agent'] = user_agent request_params['category'] = selected_engine['category'] request_params['started'] = datetime.now() + request_params['pageno'] = pageno request_params = engine.request(query, request_params) callback = make_callback( diff --git a/searx/static/css/style.css b/searx/static/css/style.css index de831e382..a6e76b726 100644 --- a/searx/static/css/style.css +++ b/searx/static/css/style.css @@ -151,8 +151,6 @@ tr:hover td { background: #DDDDDD; } #results { margin: 10px; padding: 0; } -#result_count { font-size: 0.8em; margin: 2px 0 2px 0; padding: 0 } - #suggestions { position: absolute; left: 54em; width: 12em; margin: 0 2px 5px 5px; padding: 0 2px 2px 2px; } #suggestions span { display: block; font-size: 0.8em; margin: 0 2px 10px 2px; padding: 0; } #suggestions form { display: block; } diff --git a/searx/templates/results.html b/searx/templates/results.html index 238671878..fc5527296 100644 --- a/searx/templates/results.html +++ b/searx/templates/results.html @@ -11,10 +11,6 @@ {% endif %} -