Skip to content

Instantly share code, notes, and snippets.

@thecodepoetry
Last active May 26, 2023 10:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save thecodepoetry/4cabd3ffaa600acaccb9 to your computer and use it in GitHub Desktop.
Save thecodepoetry/4cabd3ffaa600acaccb9 to your computer and use it in GitHub Desktop.
Display tags single portfolio portfolio - The7
function add_portfolio_tags_after_post($content){
if (is_single() && 'dt_portfolio' == get_post_type() ) {
$tags = get_the_term_list( get_the_ID(), 'dt_portfolio_tags', '', '', '');
$content .= '<div class="entry-tags">'.$tags.'</div>';
}
return $content;
}
add_filter( "the_content", "add_portfolio_tags_after_post" );
@thecodepoetry
Copy link
Author

Code will go in functions.php

@salweb
Copy link

salweb commented Jun 8, 2017

Hello, after entering the code in function.php, the tags appear in the portfolio section. When I click on a tag to see all jobs related to it, I return error 404. Page not found and the page link is
http://www.site.ext/www/portfolio-tags/tag-name/
You know how to fix this problem?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment