Home / Forums / WoodMart support forum / Search Not Working for Short Part Numbers
Home › Forums › WoodMart support forum › Search Not Working for Short Part Numbers
Search Not Working for Short Part Numbers
- This topic has 4 replies, 2 voices, and was last updated 5 months ago by
Aizaz Imtiaz Awan.
-
AuthorPosts
-
January 28, 2026 at 4:27 pm #706427
charliedesignermanParticipantHello,
I’m wondering if there is a way to adjust the search functionality on our website to allow searches that start with only two characters or two numbers.
We have several products with short part numbers that are only two digits. For example, one of our backup alarms has the part number 60, but the current search won’t return results for searches shorter than your minimum character limit. This makes it difficult for customers to find products by part number.
Could you please let us know if this limitation can be adjusted, or if there are any plugins or search tools you would recommend that support short (two-character or two-number) searches?
Thanks so much for your help
January 29, 2026 at 9:00 am #706484Hello,
Try to add the following PHP code snippet to the child theme functions.php file to fix this.
add_filter( 'woodmart_ajax_search_symbols_count', function (){ return 2; } );Best Regards,
January 29, 2026 at 5:45 pm #706599
charliedesignermanParticipantWhen I search for part number 60 on our site, the results return multiple products that contain “60” in their part numbers, and the exact product I’m looking for does not appear first.
Ideally, I would like part number 60 to be prioritized and shown first in the search results, specifically this product:
https://staging2.warninglightsinc.com/product/backup-alarm-die-cast-60/Is there a way to adjust the search behavior so that exact SKU or part number matches are shown first? Or would adding a specific search filter (such as prioritizing SKU over partial matches) help produce cleaner and more accurate results?
Thanks so much for your help — I really appreciate it.
January 29, 2026 at 6:31 pm #706605
charliedesignermanParticipantAdditionally, when I type the part number 60 and press the Return / Enter key, the search results do not display properly and instead show the message:
“No products were found matching your selection.”January 30, 2026 at 1:04 pm #706678Hello,
The two-character limit you mentioned applies only to the AJAX live search results — this can be adjusted using the snippet you added.
Regarding showing exact matches first (for example, prioritizing SKU or part number), there is no option in the theme settings to do this. Implementing that behavior would require custom development, which is beyond the scope of our standard support policy.
Best Regards,
-
AuthorPosts
- You must be logged in to create new topics. Login / Register