how to display a video by using wp_trim_words in front end ?
-
I want to trim the words of post content that’s why I used wp_trim words. But when I include a video in post content then it shows the video link and trimmed text in the frontend. I want to show the video not the video link trimmed text in the frontend. To solve the problem what can be used instead of wp_trim_words?
here is my code below
<div class="post-body"> <?php echo wp_trim_words( get_the_content(), 25, ''); ?> <p> <a>" class="btn btn-color btn- sm">Read More</a> </p>
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘how to display a video by using wp_trim_words in front end ?’ is closed to new replies.