My Content Management
[resolved] Using in widget + disabling Excerpt link to 'read more' (2 posts)

  1. dalenapier
    Posted 4 years ago #

    I couldn't find a straightforward to display a single testimonial in the sidebar, so I added code to my functions.php that lets me use short code in the sidebar text widgets.

    In doing this, it works great apart from one thing:

    I'm displaying the excerpt of the testimonial, and it's displaying a 'read more'/'Continue reading' link as if it were coming from the loop.

    I really just want the text by itself, as I have a link at the bottom of this widget to the page containing all full testimonials.

    Any recommendations?


  2. Joe Dolson
    Plugin Author

    Posted 4 years ago #

    That's actually a theme-determined element, not controlled by the plug-in. Your theme probably adds a filter to 'excerpt_more' and 'get_the_excerpt' to generate that link. You could edit that filter to exclude this post type, however. You can detect a particular post type using

    if  ( is_singular( 'mcm_testimonial' ) ) {
    // do action specific to this post type

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • My Content Management
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic