Passer la navigation

[Résolu] Create a dynamic filter of a view using the page it is show on

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

Problem:

The issue here is that the user wanted to add a static filter to their view so that it can be filtered by the taxonomy of the current page.

Solution:

This can be done by following the instructions in our documentation below.
https://toolset.com/course-lesson/passing-arguments-to-views/

This support ticket is created Il y a 4 years, 7 months. 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.

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

Fuseau horaire du supporter : America/Jamaica (GMT-05:00)

Ce sujet contient 2 réponses, a 2 voix.

Dernière mise à jour par adriS Il y a 4 years, 7 months.

Assisté par: Shane.

Auteur
Publications
#2193063

Tell us what you are trying to do?
This website is a tourism directory. So I want to create a view for accommodation that can be used on all the town' accommodation pages. But it would use the page it displaying on's custom taxonomy for the towns.

So the page Aberdeen Accommodation I want to place the Accommodation Directory view and it should only show accommodations (post type stay) that also have the same custom Town's taxonomy

Is there any documentation that you are following? Can not find

Is there a similar example that we can see? https://toolset.com/forums/topic/custom-taxonomy-dynamically-choose-all-filter/ but I do not understand it, don't think it is exactly what I have in mind.

What is the link to your site? lien caché
Bit I do not have content yet to display

#2193203

Shane
Supporter

Les langues: Anglais (English )

Fuseau horaire: America/Jamaica (GMT-05:00)

Hi Adri,

Thank you for getting in touch.

For filtering a view based on the current page's taxonomy I would recommend the instructions in the link below.
https://toolset.com/course-lesson/passing-arguments-to-views/

If you're having any issues please let me know.
Thanks,
Shane

#2193855

My issue is resolved now. Thank you!