Skip Navigation

[Resolved] Shortcode for archive taxonomy NAME, not term name, not slug

This thread is resolved. Here is a description of the problem and solution.

Problem:

The user wanted to display the taxonomy name on the archive page.

Solution:

Suggested to use the shortcode "wpv-archive-title".

Relevant Documentation:

https://toolset.com/documentation/programmer-reference/views/views-shortcodes/#wpv-archive-title

This support ticket is created 2 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.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9: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/Karachi (GMT+05:00)

This topic contains 3 replies, has 2 voices.

Last updated by rusty 2 years, 5 months ago.

Assisted by: Waqar.

Author
Posts
#2223453

I'm trying to display the taxonomy name on the archive page. Not the term, not the slug, but the actual name of the taxonomy. E.g. if I have a flat taxonomy called "Color choice" and the terms are red, blue and green, when clicking on a the tag "red", I want to show at the top of the archive page "Color choice: red". It is very simple to show the taxonomy term name (in this case, red), but how do I display the actual name of the taxonomy, but not the slug. The slug is "color-choice", but I want the name "Color choice". This same archive is used for several taxonomies, so the taxonomy name has to be dynamic. Is this even possible?

#2223777

Waqar
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Hi,

Thank you for contacting us and I'd be happy to assist.

You can use the shortcode "wpv-archive-title", which will show the Taxonomy name as well as the current taxonomy's term name, just the way you want.
https://toolset.com/documentation/programmer-reference/views/views-shortcodes/#wpv-archive-title

regards,
Waqar

#2224287

That is the shortcode I'm currently using, but it's outputting the term name, not the taxonomy name, BUT, I just switched the theme and it's working correctly, so I'll have to figure that one out myself. Thank you!

#2224289

My issue is resolved now. Thank you!

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