Skip Navigation

[Résolu] I would like to paginate through detail pages of search results

Ce fil est résolu. Voici une description du problème et la solution proposée.

Problem:
I would like to paginate through detail pages of search results of single posts within search result

Solution:
It needs to add custom code to paginate through the single posts of view's search results.

You can find the proposed solution, in this case with the following reply:
https://toolset.com/forums/topic/i-would-like-to-paginate-through-detail-pages-of-search-results/#post-1252597

Relevant Documentation:

This support ticket is created Il y a 4 années et 10 mois. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 6 réponses, has 2 voix.

Last updated by chrisH-10 Il y a 4 années et 10 mois.

Assisted by: Minesh.

Auteur
Publications
#1251381

Tell us what you are trying to do?
I would like to have a user driven search result listing. Once the user digs into the detail page I would like to let them to paginate (single detail page by single detail page) through the result set (that you can't see any more).

Is there any documentation that you are following?
Couldn't find anything quite like it.

Is there a similar example that we can see?
hidden link

What is the link to your site?
This is the page with the filter - hidden link
The detail pages should have arrow navigation like they do on hidden link.

--
My initial thought is to create a detail page view that I had the a view parameters (but different output template) and pass along the query string parameters from the initial listing page?
(a) not sure that can actually work?
(b) is there a better way?

#1251451

Minesh
Supporter

Languages: Anglais (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Well - have you check the following Doc that may help you:
=> https://toolset.com/documentation/post-relationships/how-to-create-custom-searches-and-relationships-for-users/

#1251865

Hi Minesh, thank for the link. I had seen that and didn't find it relevant. I just re-read it and don't see any connection to my question. Let me try to clarify my question.

1. I would like show the user a listing page like hidden link
2. I want each detail page to allow the user back/next navigation within the result set that the user generated by using the filter as shown in step 1 above.

This can be seen (without filter options) when you click on any tile on hidden link to get to a detail page (e.g. hidden link) once on this detail page note the back/next arrow in the upper right to get to the next record.
Now, on this site there is no filter option so back/next goes through all records. I essentially want to adding filtering (done for listing) that carries through to navigation on detail pages.

#1251923

Minesh
Supporter

Languages: Anglais (English )

Timezone: Asia/Kolkata (GMT+05:30)

1. I would like show the user a listing page like hidden link
=> Ok, So, the thing is that, custom search is not supported with User Type view. Custom search is only possible with only post type view and post type archives.

If you try to create custom search view with User type view, you will see the following notice displayed with "Custom Search Settings" section:

Only Views listing posts can have custom search inputs. 

2. I want each detail page to allow the user back/next navigation within the result set that the user generated by using the filter as shown in step 1 above.
=> Yes, you can add pagination controls using "Search and Pagination" section but you can not add filters to filter the results.

#1251939

Minesh, to help me communicate better, where did you get this idea that I am asking about a "User Type view"?

#1252597

Minesh
Supporter

Languages: Anglais (English )

Timezone: Asia/Kolkata (GMT+05:30)

1. I would like show the user a listing page like hidden link
=> It looks like I confused due to word "user a listing page" and I misunderstood somehow that you want to list users user listing page.

As I understand now:
- you have custom search view where you can filter the results
- you wish that prev-next links added to the single posts page should work within the search results (filtered results) - correct?

If yes, the thing is that, you can apply the pagination to your view, but on view, you added the items/posts which is when you click on it, it will be redirected to single post page where view's pagination will not have any controls as you are on single post page.

So, either its achieved if you can display one item per page using view's pagination, that means you do not need to go to single post page otherwise there is no such solution as on single page views control is lost and we do not know what are the filtered results as well as what is prev and next post of views filtered results when you are on single post page.

It can be achieved using some custom code, please check the following related ticket:
=> https://toolset.com/forums/topic/how-to-show-next-previous-child-post/#post-508649

Its not the same but, you should write a shortcode that query the same results as per the view and fetch the prev and next accordingly.

#1253099

Thanks for the link, it's not quite the same but I'll create a shortcode and pass the query parameters and index of the clicked item to the detail page so I can navigate back and forth as suggested.

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.