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.

General Questions

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Search not working

Go to End

28 Posts   3629 Views


16 August 2011 at 7:22pm Community Member, 46 Posts


For some reason the search function isn't working... Is there a module I've got to install or is there a function I need to enable in SS?

URL to the site is..

Kind regards,



16 August 2011 at 11:05pm (Last edited: 16 August 2011 11:18pm), Community Member, 141 Posts


check if you have this line in your /mysite/_config.php:

and if you have this in your template where the search form should appear:


Edit: Don't forget to rebuild the database by visiting after adding Fulltext... to your _config.php
Edit2: This link might also help: [url][/url]


17 August 2011 at 3:43am Community Member, 46 Posts

Still not working.... I've added FulltextSearchable::enable(); where you said it should be.. I've also checked the template which now looks like this

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">
<html xmlns="">

      <% base_tag %>
      <link rel="shortcut icon" href="/favicon.ico" />


<div id="Wrapper">
   <div id="Header">
      <h1><span>Christina French</h1>
<p class="tagline">Artist & Tutor</p>
<input type="text" class="search" value="Search" />
<div id="Nav">
   <% include Navigation %>

<div class="clear"></div>

<div id="Footer">
   <% include Footer %>



Any ideas why it's still not working?.. Cache has been flushed 3 times now,




17 August 2011 at 5:36pm Community Member, 107 Posts

i am not sure if i can help, but try plasing the $SearchForm just under the <body> & test it, it may be conflectiong with something else above it in the code!!.. give it a try..

.... For now, i Need your help!!.. i saw your website, What gallery did you use (Gallery page).. i really need it.. Can you give me the link to that module..

Thank you


19 August 2011 at 11:35pm Community Member, 46 Posts

Thanks for your advice... I'll give it a try.

regarding the gallery you can find it here


20 August 2011 at 5:16am Community Member, 107 Posts

thank you.. i am using the gallery now.. its the best.. but i need to get it to do the following:
if there is ONLY one album, Do not show albums list!!
can it be done..


4 September 2011 at 5:40pm Community Member, 46 Posts

Anybody have any ideas what I may be doing wrong with this search issue?

What page do I place the $SearchForm line?... I've currently placed it in:


It's currently the first line after the body tag


4 September 2011 at 9:30pm Forum Moderator, 1091 Posts

The reason it doesn't work, is that your searchform isn't a form at all. it's just a simple textinput without any submit action:

   <div id="Header">
    <h1><span>Christina French</span></h1>
<p class="tagline">Artist &amp; Tutor</p>
<input class="search" value="Search" type="text">

so for some reason placing $SearchForm in your template seems to only return that single field. How is your searchform created? Did you create a SearchForm() method yourself, or use some custom template?

Go to Top