Forums / Developer / Exclude on the search engine some class

Exclude on the search engine some class

Author Message

justin kazadi

Thursday 04 June 2009 1:58:16 am

Hi,

i'am using Ez 4.0.1 . i want to including on the search engine somme content class so i have using this code :

{def $search=fetch('content', 'search',
                      hash('text', $search_text,                           
			                     'class_id', array( '46', '16', '50', '51', '70', '57', '56' ),
                           'offset', $view_parameters.offset,
                           'limit', $page_limit))}

but the search engine search all the content class.

i don't know if is there an mistakes on my code.

The theory is when we know everything and nothing works.
The practice is when everything works and nobody knows why.
If the practice and theory are met, nothing works and we do not know why.

Albert Einstein

Ivo Lukac

Thursday 04 June 2009 7:17:18 am

You should have something like this in site.ini:

[SearchSettings]
SearchViewHandling=template

http://www.linkedin.com/in/ivolukac
http://www.netgen.hr/eng/blog
http://twitter.com/ilukac

justin kazadi

Friday 05 June 2009 12:29:45 am

Thanks i'm gonna try it.

The theory is when we know everything and nothing works.
The practice is when everything works and nobody knows why.
If the practice and theory are met, nothing works and we do not know why.

Albert Einstein