Skip to content

SearXNG is a free internet metasearch engine which aggregates results from various search services and databases. Users are neither tracked nor profiled.

follow up changes in search_category_on_select

Noemi Vanyi074521fd8a28
diff --git a/searx/static/plugins/js/search_on_category_select.js b/searx/static/plugins/js/search_on_category_select.js
index 5ecc2cdb9..a6dd447a0 100644
--- a/searx/static/plugins/js/search_on_category_select.js
+++ b/searx/static/plugins/js/search_on_category_select.js
@@ -4,9 +4,7 @@ $(document).ready(function() {
$('#categories input[type="checkbox"]').each(function(i, checkbox) {
$(checkbox).prop('checked', false);
});
- $('#categories label').removeClass('btn-primary').removeClass('active').addClass('btn-default');
- $(this).removeClass('btn-default').addClass('btn-primary').addClass('active');
- $($(this).children()[0]).prop('checked', 'checked');
+ $(document.getElementById($(this).attr("for"))).prop('checked', true);
if($('#q').val()) {
$('#search_form').submit();
}