ez projects / ezsearchpro / forum / general / set sort_by parameter properly
You need to be logged in to post messages in the forums. New users may register here.
Member since: Posts: 52 |
Sunday 27 June 2010 1:58:10 pm Just a notice...
After installing ezsearchpro, you have to set your sort_by parameter to "ranking". For example if you use template search like this: {set search=fetch(content,search, hash(text,$search_text, class_id,$search_class_array, sort_by,array('published',false()), offset,$view_parameters.offset, limit,$page_limit))} you should change it to: {set search=fetch(content,search, hash(text,$search_text, class_id,$search_class_array, sort_by,array('ranking',false()), offset,$view_parameters.offset, limit,$page_limit))} This should be mentioned in the docs, so that people don't have to inspect the code in order to find it out. -- |
|
|
Member since: Posts: 171 |
Monday 28 June 2010 8:57:59 am Thanks, I'll add it.
You can also use several sort_by values like other fetch functions: {set search=fetch(content,search, hash(text,$search_text, class_id,$search_class_array, sort_by, array( array('ranking',false()), array('published',false())), offset,$view_parameters.offset, limit,$page_limit))} -- |
You need to be logged in to post messages in the forums. New users may register here.