How to filter the_content to show only shortcodes? (2 posts)

  1. Navjot Singh
    Posted 6 years ago #

    I have a blog where in sidebar, I need to fetch posts belonging to video category. Now Videos are embedded using shortcodes. But since the_content is used to show the posts in sidebar, any text and even image in a video post gets shown in sidebar which makes it messy.

    How to filter the_content so that only shortcodes display in that sidebar and rest of content gets filtered out.

  2. MichaelH
    Posted 6 years ago #

Topic Closed

This topic has been closed to new replies.

About this Topic