Tagged: categories, Portfolio, Tags
-
AuthorPosts
-
August 11, 2016 at 11:55 am #671253
Hi guys,
Just returned from my holidays, so I might still be in “seventh heaven” and unable to see obvious things… ;-)
How can I get my portfolio categories and tags to be show on the portfolio item on the website? I have looked and looked again, but cannot find any shortcode for this in the Avia Layout Builder.
Please advise.
Thanks & regards,
MoniqueAugust 15, 2016 at 6:38 am #672521Hey Monique,
Thank you for using Enfold.
Those info should display automatically if you use the default editor. If you want to display it in the portfolio item created with the advance layout builder, please follow this link: https://kriesi.at/support/topic/show-portfolio-category-on-portfolio-pages/#post-540059
Best regards,
IsmaelAugust 15, 2016 at 10:29 am #672586Hi Ismael,
I am using advance layout builder, so I followed the instructions in the thread you mentioned. It works but only partially:
1) I can only see the first category (most items have more categories).
2) Is it possible to have the categories clickable so that when visitors click on them they see an overview of all portfolio items of that category?Thanks & regards,
MoniqueAugust 17, 2016 at 9:22 am #673578Hi,
1-2.) Replace the code with this:
function show_portfolio_category_func() { global $post; $the_terms = get_the_terms( $post->ID , 'portfolio_entries'); $output = ''; foreach($the_terms as $term) { $termlink = get_term_link($term->term_id, $term->taxonomy); $output .= '<span class="portfolio_cat"><a href='.$termlink.'>'.$term->name.' </a></span>'; } return $output; } add_shortcode('portfolio_category', 'show_portfolio_category_func');Best regards,
IsmaelAugust 17, 2016 at 9:46 am #673590Hi Ismael,
Works! That’s great! A little CSS and it looks beautiful too :-)
Can you flag this topic as closed please? (Btw: can I do this myself or do you need to do that?)
Thanks & best regards,
MoniqueAugust 18, 2016 at 6:51 am #674050 -
AuthorPosts
- The topic ‘Show categories and tags in portfolio’ is closed to new replies.
