Post by 3dwebdesign » Fri Mar 28, 2025 10:15 pm

I have an interesting problem with the search engine in OpenCart 2.3. When I search for phrases like "vitamin C" and "vitamin D", vitamin E and all the like (without quotes), I keep getting the same results. Can anyone help by reminding me what is causing this and how I can fix it so that it searches correctly and finds the right products?

I don't think this is a problem only on my site, ever since installing this version of this site, the search engine has been working this way :o

Newbie

Posts

Joined
Fri Sep 04, 2020 7:07 pm


Post by ADD Creative » Sat Mar 29, 2025 12:52 am

The search query uses LIKE %...% for each part of the search string. So C would match any product that has an C in the name.

www.add-creative.co.uk


Guru Member

Posts

Joined
Sat Jan 14, 2012 1:02 am
Location - United Kingdom

Post by grgr » Sat Mar 29, 2025 7:21 am

If that is just the default opencart search you have, then I would well recommend installatin a search extension.

-
Image Image Image
VIEW ALL EXTENSIONS * EXTENSION SUPPORT * WEBSITE * CUSTOM REQUESTS


User avatar
Active Member

Posts

Joined
Mon Mar 28, 2011 4:08 pm
Location - UK

Post by 3dwebdesign » Mon Mar 31, 2025 2:19 pm

Ok, if search query uses LIKE %...%, how can I change it to find the right products without losing the correct results. Because when searching for longer phrases, the results returned by the search are perfect. The problem is only when one of the phrases is one letter, when there are two or more, everything is fine.

Newbie

Posts

Joined
Fri Sep 04, 2020 7:07 pm


User avatar
Guru Member
Online

Posts

Joined
Mon Aug 22, 2011 11:01 pm
Location - London Gatwick, United Kingdom

Post by 3dwebdesign » Mon Mar 31, 2025 6:48 pm

@paulfeakins, thanks, will try it.

Newbie

Posts

Joined
Fri Sep 04, 2020 7:07 pm

Who is online

Users browsing this forum: Bing [Bot] and 82 guests