diff options
author | renyhp <renyhp@disroot.org> | 2020-11-22 18:00:21 +0100 |
---|---|---|
committer | renyhp <renyhp@disroot.org> | 2020-11-22 18:16:43 +0100 |
commit | b00f77059c93bc91f706b5f0c51f7db752669b09 (patch) | |
tree | 06fbc91fdd4ef0e1fd23ce1286815c45b5c0a16c /searx/webapp.py | |
parent | 2fc3b17c85512280173bb47f449cc2faa64b0501 (diff) | |
download | searxng-b00f77059c93bc91f706b5f0c51f7db752669b09.tar.gz searxng-b00f77059c93bc91f706b5f0c51f7db752669b09.zip |
Add preference for displaying advanced settings
Diffstat (limited to 'searx/webapp.py')
-rwxr-xr-x | searx/webapp.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/searx/webapp.py b/searx/webapp.py index 2a93c3765..c0530a834 100755 --- a/searx/webapp.py +++ b/searx/webapp.py @@ -545,6 +545,9 @@ def index_error(output_format, error_message): def index(): """Render index page.""" + # UI + advanced_search = request.form.get('advanced_search', request.preferences.get_value('advanced_search')) + # redirect to search if there's a query in the request if request.form.get('q'): query = ('?' + request.query_string.decode()) if request.query_string else '' @@ -553,6 +556,7 @@ def index(): return render( 'index.html', selected_categories=get_selected_categories(request.preferences, request.form), + advanced_search=advanced_search, ) |