Would someone please tell me how I enable site seach?
In 3.x it was a simple matter of adding FulltextSearchable::enable(); to mysite/_config.php but when I attempt this in 4.0 it throws an error on /dev/build.
Someone on here told me I need to add FulltextSearchable::enable(); to app/_config.php but version 4.0 doesn’t have an app subfolder. It has mysite in its place. From what I can see app came later, in 4.1+.
I tried adding the following to mysite/_config.php:
use SilverStripe\ORM\Search;
FulltextSearchable::enable();
But it threw an error on /dev/build (class ‘FulltextSearchable’ not found)
I then tried adding the following to /mysite/_config/theme.yml:
I’ve just been struggling with this. The documentation is pretty sparse, but I found this little gem from Uncle Cheese which helped me a lot - SS ajax site search · GitHub
Also, this only works with MySQL 5.6+, so if your host has 5.5 you’ll need to look at converting the relevant tables to MyISAM, an area which I haven’t quite got to grips with yet