Skip Navigation

[Resolved] output first level taxonomies only at view

This support ticket is created 6 years, 5 months ago. 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.

This topic contains 2 replies, has 2 voices.

Last updated by Akhil 6 years, 5 months ago.

Author
Posts
#916920

hi. i looked at this page:

https://toolset.com/forums/topic/displaying-only-the-main-taxonomies-not-subchildren-on-a-custom-post/

i would like to output top level ONLY tax at view -layout .

my current code is simple :


[wpv-taxonomy-title]

taxonomy name : directory

How do i achieve this pls .

I have 2 views as usual for main and subcategories .

#916942

I explained how to achieve something similar here today:
https://toolset.com/forums/topic/i-need-to-display-child-taxonomies-conditionally/#post-916918

It displays a list of Terms according their hierarchy, and hence, can be modified to show just first level (parent) taxonomies.

This, does not require 2 Views like I show in the other post.
It requires just Ione view, where you query the Taxonomy and add a Query Filter to it that says:
"Select terms with parent: Parent Is: none"

That will then display a list of Parent Terms only, if you insert the View to a Page.
Of course, before in the View's Loop you will need to add some ShortCodes so to display some data of the Terms.

#916944

Thanks Beda, yes i did look at the thread to find the solutions. cheers