As mentioned by others I have followed this tutorial and got the search facility showing up on the screen. However it produces no results. When I type in a nonsense string that wont be found there is no message coming up telling me that the search was unsuccessful so it feels like the results feature is not being found. I would greatly appreciate help on finding what I have done wrong.
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.
Please post your code and the error you're getting.
No Errors are being generated. When I enter a valid search string the screen refreshs but nothing else happens. there is no message when an invalid string is entered and not found. The files that I modified for this feature are page.php, page.ss and page_results.ss. I have attached these files.
Hi, Just had problems with search myself. I found that the Page.php file had the following line at the bottom.
return $this->customise($data)->renderWith(array('Page_results', 'Page')); so it was looking for a file titled Page_results.ss. But my actual file was PageResults.ss. The fix is to rename them to match. I changed the page.php file to look for PageResults.ss and it all started working. In retrospect, perhaps I should have done it the other way by renaming the file.