customizing Search

Hello

The search results are not looking like i want it to have it. Also some text needs german strings. I discovered, that DBSeach.cfc is responsible for the output of a search.

What is the best way to change it? I think, i use the code of this cfc in my on theme related plugin. Of course i need also a copy of the code, which calls the functions in the cfc.

Is this the best or at least regular way to deal with such situations? The same “problem” affects also the results comment form. There, i need an additional field and i like to check the comment for spam.

Thanks

Martin, in your theme you can alter the search results by using the search.cfm view and the search.cfm layout. This way you have full UI control of the search.

By default we ship with a simple database search engine in the form of DBSearch.cfc. However, we have created an interface called ISearchAdapter. You can create your own CFC that implements this interface and then register it via the Settings Panel. Then COntentBox will use your own search engine instead of the core one so you can do what you want, your way :slight_smile:

signature0.jpg

Luis F. Majano
CEO
Ortus Solutions, Corp
www.ortussolutions.com

ColdBox Platform: http://www.coldbox.org
Linked In: http://www.linkedin.com/pub/3/731/483
Blog: http://www.luismajano.com
IECFUG Manager: http://www.iecfug.com

Social: twitter.com/lmajano facebook.com/lmajano

Thany you Luis, i will try it. I have no idea why i didn’t realized, that a search template exists :wink: