Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Form Questions /

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

[Solved] SearchForm doesn't always work.


Go to End


3 Posts   1550 Views

Avatar
_Vince

Community Member, 165 Posts

1 April 2011 at 3:35pm

Having an odd problem.

A customer has a site with a SearchForm. The search finds pages containing the word "tax" but cannot find the words "GST" and "FBT", which are on the same page.

I'm totally stumped.

Why is this happening and, more importantly, how do I fix it? :?

Avatar
_Vince

Community Member, 165 Posts

3 April 2011 at 7:52am

Edited: 03/04/2011 8:45am

*bump*

I have tried creating a page that contains the words "FBT GST blah blah blah Hutt" and the SearchForm finds "blah" and "Hutt" but it doesn't find "FBT" or GST".

Any ideas? Anyone? I am having the same problem with SS 2.4.3 and 2.4.5

Avatar
_Vince

Community Member, 165 Posts

3 April 2011 at 6:02pm

Ok, sorted.

There's a MySQL parameter called ft_min_word_len that defines the smallest word it on which the database will do a full text search.

I edited /etc/mysql/my.cnf adding the line

set-variable = ft_min_word_len=3

retarted the MySQL service and now it finds "GST" and "FBT" without problems.