no results showing for a collection
Hey Low,
We're struggling with Low Search on this particular project.
Previous dev had failed to set custom fields as searchable for a given channel. Rectified that and then created our collection, set the weight etc. Rebuilt the index and then searched for 'Hawaii' which is in the entry title of one of our entries.
That entry is both open and isn't in the future but yet search results returned null.
We stripped back the search and results just to have
{exp:low_search:form result_page="search/results" collection="events" form_class="search-form"}
Search
{/exp:low_search:form}
{exp:low_search:results query="{segment_3}" collection="events" limit="10"}
{if count == 1}
- {/if}
- {title}
{if count == total_results}
{if no_results}No search results{/if}
{/exp:low_search:results}
but that has no result either.
If we exclude the collection parameter, the results tag is returning entries from a channel that doesn't have a collection set.
What are we missing?
Cheers,
S
Replies
stevieg_83 26 Jun 2014 14:59
The entries are also showing as indexed in the db.
Low 26 Jun 2014 15:02
Can you re-post your Form tag? You can use http://pastie.org/ or http://pastebin.com/ for large chunks of code.
Also, what's the URI for a search that doesn't give you the correct results? Finally, enable template debugging and copy/paste all lines mentioning Low Search here.
stevieg_83 26 Jun 2014 15:18
So the URL is /search/results/ containing this code
https://gist.github.com/stevieg83/b12...
The results tag initially gives no results. I'd have expected it to return 100 entries in that collection by default?
When I search for hawaii, the url turns to /search/results/eyJyZXN1bHRfcGFnZSI6InNlYXJjaFwvcmVzdWx0cyIsImtleXdvcmRzIjoiSGF3YWlpIn0
and finds nothing.
Here's the template debugging https://gist.github.com/stevieg83/29b...
interesting that fixed order returns 2 entry ids with the keyword we want.
Low 26 Jun 2014 15:46
The fact that the fixed_order param is set, implies that entries are found, but are negated by native filters/params like status etc. Can you think of any other params that might do that for those entries?
stevieg_83 26 Jun 2014 15:59
Oh man, he'd hidden the expiry date in publish layouts and I missed it.
Sheesh! What a time suck.
Thank you as always. Appreciated.