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.

Archive /

Our old forums are still available as a read-only archive.

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

Site search module


Go to End


6 Posts   3922 Views

Avatar
kf

Community Member, 3 Posts

28 August 2008 at 5:11pm

Hi,

I want to enable search on a silverstripe site. What is the best way to do that? I tried googling a bit, and found some information about a SilverStripe Search module, but I can't find it.

Avatar
grilldan

Community Member, 135 Posts

28 August 2008 at 5:20pm

There's a Google search widget.

http://silverstripe.com/google-custom-search-widget/

That might help you.

Avatar
Liam

Community Member, 470 Posts

28 August 2008 at 5:21pm

There is no module, at least I don't think, so you have to follow the tutorial - http://doc.silverstripe.com/doku.php?id=tutorial:4-site-search

Looks like a lot of work, but it's not. Mainly just copy and pasting things. You can search the docs for more info on making a bit more advance if need be.

I also believe in the future it will come bundled with SS.

Avatar
kf

Community Member, 3 Posts

28 August 2008 at 5:50pm

Thanks for the suggestions! I guess I can use the site search from the tutorial to start with.

I'm going to build a site where users must log on for additional access, and I want that to be searchable as well. By the same token, users that aren't logged in shouldn't be able to search content they don't have access to. What would be the correct way to do that? Filter relevant results out from $form->getResults() before displaying anything?

Avatar
Liam

Community Member, 470 Posts

29 August 2008 at 3:15am

Most likely, yes.

This page helps describe how to limit search results in the section near the bottom - http://doc.silverstripe.com/doku.php?id=recipes:simplesearch

Might be a good start.

Avatar
Tareq

Community Member, 8 Posts

5 September 2008 at 10:47pm

Hi All ,
I m trying for search from tutorial 4 but it unable to show me any search , not even displaying me any html content on header from Page.ss

please suggest me to execute search stuff.

Thanking you.