[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date
][Minivend by thread
]
Returning specific # of matches in a multilevel search
Hello,
I'm trying to take any kind of search result and be able to sort them by
category and show only 5 results from each category. I've tried various
incarnations of the [sort] tag
e.g. [sort table:cateogry:f -1 +5 table:description:f]
to no avail (it only returns the first 5 matches not the first 5 matches for
each category).
I think this would be a very useful feature since you could show the 5 most
popular matches for each category and have a link to the full category
search.
I have been able to extract the categories and put them each into differnet
scratch variables like so:
[search-list]
[on-change cat2]
[condition][item-field subcategory][/condition]
[set name="subcat[item-increment]" interpolate=1][item-field
subcategory][/set]
[scratch subcat[item-increment]]<br>
[else]
[/else]
[/on-change cat2]
[/search-list]
and from there i could do a
[tag each products] and do an in-page search for each category found but
since our catalog is something like 10,000 records i did not think this
would be a very efficient way of doing this.
If anyone has any suggestions or little perls of wisdom, i would be very
appreciative.
thanks again,
mike k.