I have created a custom taxonomy (intervenant) including some custom fields and wants to display those fields inside a WordPress archive page.
So, I created a new content template for the 'intervenant' archive.
In order to retrieve the right info, I have also created a taxonomy Views for 'intervenant'. In this Views, I have set up the different needed fields.
Now, I'm trying to insert this Views inside the archive content template but did not succeed to define the right filter to apply to the Views.
The url of the archive is : hidden link and I tried several different parameter on the taxonomy Views without success (defined by the current post or define by the page where the Views is integrated ...)
Sorry but this is concerning a client's site and I'm not able to give you access.
Can you provide some guidelines in order to check if I have used the right parameters ?
Thanks
Pat
No problem lets see how best we can work with this info.
So On your taxonomy view you want to essentially list out the taxonomy fields of the taxonomy that is assigned to the post that the archive is looping through.
You will need to add a query filter for Taxonomy Term filter and set that filter to current post see screenshot
What happens if you add the taxonomy title to this view using this shortcode [wpv-taxonomy-title] does the title display? or are you getting No results found.
I have also tried with the first possibility (Set bu the page where the Views is inserted) and here, I'm getting 4 results (including the right one).
If I chose "Terms with the ID defined by a shortcode", then no item found.
If I chose the "One of these" possibility and place the name of the one I want to display, then, I'm getting the right one and only this one!
Here is my code in the Views archive (the taxonomy Views is "presentation-dun-intervenant" . I can say that the loop in this Views is working well, meaning the results are really those linked with the dedicated "intervenant":
First, the taxonomy (intervenant) is linked to the WC products.
What I want to do is the following :
- When someone clicks on a taxonomy link, he is redirected to the taxonomy page.
- On this page, I want to display some terms field of this taxonomy and the list of products that are have this taxonomy.
If I'm right, the archive taxonomy Views will display the products related to the taxonomy and this is working. What I searching for, is to display the taxonomy terms fields in top of this page.
Thank you for the clarity let us work on this in steps.
First, the taxonomy (intervenant) is linked to the WC products.
Do you already have this working ?
When someone clicks on a taxonomy link, he is redirected to the taxonomy page.
Is this already working ?
- On this page, I want to display some terms field of this taxonomy and the list of products that are have this taxonomy.
When you click the taxonomy link it should already take you to the taxonomy archive that will already be listing out the appropriate products. So what you need is to display the custom fields of that taxonomy correct?
After looking again this issue, it seems I had not made it the right way. I made some evolution and now, everything is working fine.
Sorry for using your time and thanks for helping.
REgards
Pat