Get taxonomy terms for all the wordpress posts in an archive

I am using the following function to display the selected taxonomy terms in a archive page.

echo get_the_term_list( $post->ID, 'dt_portfolio_category', '<ul class="styles"><li>', ',</li><li>', '</li></ul>' );

The above function only displays taxonomy terms of the first posts not all of them.

Is there any way of doing it ?
Also the terms should not repeat, they should come only once.

Read more here: Get taxonomy terms for all the wordpress posts in an archive

Leave a Reply

Your email address will not be published. Required fields are marked *