Skip Navigation

[Resolved] How to show only specific tags?

This support ticket is created 3 years, 4 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.

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 4 replies, has 2 voices.

Last updated by StanleyT8485 3 years, 4 months ago.

Assisted by: Minesh.

Author
Posts
#2150169

Tell us what you are trying to do?
I want to show only specific tags for the posts outputted in Views. P.S: I am using the Views in classic mode.

I have a View that shows a list of posts. Each post have their own tags. I want to show the tags of each post BUT only selected tags not all of them. For example, here is a screenshot: hidden link of a View result showing all the tags for that post. I want to only show "Biology" and "Psychology" instead of all of them.

In my Views, I am using this shortcode to show the tags [wpv-post-taxonomy type="post_tag" separator=""]. However, it is showing all of them.

I have also tried creating a separate taxonomy View to show the tags I want to show but that didn't work.

The ideal solution for me would be to have the filter in the shortcode itself. For example, [wpv-post-taxonomy type="post_tag" separator="" filter="Biology, Nursing"]

Any help would be greatly appreciated!

#2150397

Minesh
Supporter

Languages: English (English )

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

Hello. Thank you for contacting the Toolset support.

There is no such filter or feature available using which you can customize the output of the shortcode:
- [wpv-post-taxonomy type="post_tag" separator=""]

You will have to write your own custom shortcode where you should define and white list the terms you want to display and that shortcode only return the white listed terms out of the found terms from the [wpv-post-taxonomy type="post_tag" separator=""] shortcode.

#2150483

Hey Minesh,
Is there any other solution to my issue other than creating a custom shortcode?

#2150503

Minesh
Supporter

Languages: English (English )

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

Unfortunately - No.

#2150509

My issue is resolved now. Thank you!