Search page not matching autocomplete results
-
Hi,
I’m setting up Algolia to test on my site and have been working on autocomplete to get contents of ACF fields into my search results – this has been achieved with plenty of help, https://www.ads-software.com/support/topic/testing-algolia-on-staging-site-questions/
Now I need to make my Search page reflective of this too. I’m using the
Use Algolia with instantsearch.js
option on my Search page settings. But when I hit return on the wordwinklepicker
which is a unique word that I know only appears on my homepage in an ACF field, whilst it shows up in autocomplete, when I go to the search results page, I have zero results.My understanding is that instantsearch just uses the
wp_searchable_posts
index – is that correct?Looking at that index, I can see that it does indeed contain the
acf_content
on the homepage record which I added in previous filteralgolia_searchable_post_shared_attributes
when I was getting autocomplete working. But it seems that this content isn’t being considered by instantsearch. How do I make instantsearch look atcontent
andacf_content
for my Pages? I did notice this filteralgolia_searchable_post_content
in the wiki, but I’m not sure how I’d use it or if that’s the correct route?Also, my Search page is displaying results from Products and other post types as well, which I currently don’t want as I’m only testing pages. I don’t think there is any way for me to exclude post types from the Search page like I can do with autocomplete in the UI is there? I can see that my
wp_searchable_posts
index is 21K records whereas I only have 80 pages, so that’s probably the reason. How do I go about just sending pages to this index?Many thanks
The page I need help with: [log in to see the link]
- The topic ‘Search page not matching autocomplete results’ is closed to new replies.