I want to add a shortcode (like slider) and html tag like <h2>-------- text -----</h2>. Is that possible?

I have already tried but is not really working. Only normal text is showing, no short code or html tag even. Any idea how or not possible?

i want to use this for own theme. i have one product page. but many category (like 7) and each category will have different slideshow banner. and under there product picture and details. i don't want make each category page separately, i can show shortcode from category description then i can it will be work for me. my shortcode will be [rev_slider slider]

category page code

 <?php if ( category_description() ) :  ?>
  <div class="catdes"><?php echo wpautop( term_description() ); ?></div>
  <?php endif; ?>

function page

remove_filter( 'pre_term_description', 'wp_filter_kses' );

1 Answer 1


For displaying shortcodes you can use do_shortcode

<?php echo do_shortcode( term_description() ); ?>

For HTML the filter should be enough (what you posted worked on my install).

remove_filter( 'pre_term_description', 'wp_filter_kses' );

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.