Is it possible to set the maximum number of characters entered in a search bar?
Starting with version 2.8.0 of the Elastic Search and version 1.27.0 of the Advanced Search modules, a new feature to limit the search query length. was added. You need to install the
'amasty/module-advanced-search-subscription-functionality’ package from composer suggest to use this functionality (the functionality is available as a part of
an active product subscription or support subscription).
When the module is installed, you will be able to add Max Characters value to the according field in Amasty > Advanced Search > Configuration > General:
- If the field is empty, there is no front-end restriction on the maximum search query length.
- If the field contains a value, only search queries whose length is less than or equal to the specified number are used for front-end search. All characters in the query are counted.
- The field accepts only positive whole numbers.
- The value in the Max Characters field must be greater than the value specified in the Min Characters field.
Related Articles
Can Elastic Search be optimized to enhance search speed?
This article explores key issues related to Elasticsearch performance and offers actionable solutions to enhance your search operations. From addressing slow queries to managing resource utilization during reindexing, these techniques will help you ...
How to ensure accurate search results with special characters?
Special characters in search queries can complicate the search experience in eCommerce platforms. To ensure accurate and error-free search results, it’s important to handle these characters properly. 1. Enable Special Characters Handling Navigate to ...
The module doesn't let me add more than 100 products to an attachment. How to fix it?
The extension itself doesn’t have any limits on the number of products to be assigned to the attachment. However, the maximum number of products that can be assigned to an attachment on its edit page is controlled by a PHP variable and the server ...
Does the module use answers for search results?
Starting with version 2.15.0 of the FAQ and Product Questions module, it is possible to include questions in search results based on the text of their answers. The feature is available with an active product or support subscription upon installation ...
I'd like to sort the search results, is it possible?
The Elastic Search extension provides the functionality to create relevance rules for moving the position of specific products in the search results. Please find the details about creating relevance rules in our guide. If our Improved Sorting ...