• Resolved Giang Le

    (@gianghl1983)


    Hi,

    Can we limit number of results and Pagination features?

    Br,

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Hey @gianghl1983

    Sorry about the long delay in reply here. Are you still curious about this? or did you manage to find a way to achieve what you’re hoping for?

    Thread Starter Giang Le

    (@gianghl1983)

    @tw2113 Still looking for the solution here :D. Could you please guide me the direction for this?

    Many thanks!

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Noted. That said, limit the number of results to what? For example, are the parameters for just to a specific post type? To posts that aren’t password protected? Something else?

    Thread Starter Giang Le

    (@gianghl1983)

    @tw2113 E.g I have 25 posts contain ‘keyword’ in title, so I just want so 10 result in the list and pagination 1-2-3 at bottom of result window…

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Sounds like just standard pagination and posts per pages details. Checking on some things with others on our team regarding this and if it’s going to be controlled by soemthing shipped with the plugin, or if that’s all going to be controlled by theme/site settings.

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Passing this along paraphrased.

    You only want to index the posts that contain keyword in title? If that is accurate, then you should be able to hook into algolia_should_index_post and algolia_should_index_searchable_post and then they could make decisions about whether to index the post or not.

    As for the number of results per page, assuming you’re using the PHP search, you could hook into algolia_search_params and filter the hitsPerPage (which defaults to the value of posts_per_page).

    Thread Starter Giang Le

    (@gianghl1983)

    @tw2113 The search in Title is just for example…What I want is to show ALL result not to limit them. E.g: There are 24 results then the search result of Algolia will show 10 and has an AJAX pagination in result window for others (Page: 1 – 2 – 3).

    Br,

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Noted. I believe the last part of my passed along information still holds true for what you’re trying to achieve overall, but it doesn’t yet answer setting up the pagination parts as well as clicking through to the secondary pages. I also think this type of detail tends to work slightly better with just “load more” buttons etc instead of numbered pages along the bottom. However I also have to believe that could be achieved somehow as well. Sorry if I’m sounding a little vague.

    Thread Starter Giang Le

    (@gianghl1983)

    @tw2113 Cool! I am looking forward to that. You may have a settings for Load more on Pagination and number of results…(I saw Ajax Search Pro integrated this feature quite well in their search result window)

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Number of Results and Pagination?’ is closed to new replies.