Support » Plugin: Testimonial Rotator » Shortcode for Excerpts

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Hal Gatewood


    Unfortunetly there is now way to do this without modifying the plugin. If you want to do it, go into


    change line 429 from

    $slide .= " <div class=\"text\">" . apply_filters( 'the_content', get_the_content() ) . "</div>\n";


    $slide .= " <div class=\"text\">" . get_the_excerpt() . "</div>\n";

    Hi Hal and others,

    I had a problem getting the shortcode to display the testimonials in a excerpt fashion, using for example [testimonial_rotator id=690 show_size=excerpt limit_length=265]

    Based on Testemonial Rotator Version 1.3.7 I got it to work.
    Not sure if this is the best solution since I am not an experienced developer, but this worked for me. I’m open to feedback from the pro’s 🙂

    Modification 1 to testimonial-rotator.php:
    Adding this line at the first section of function testimonial_rotator($atts)
    $show_size = isset($atts['show_size']) ? $atts['show_size'] : "";

    Modification 2 to testimonial-rotator.php:
    Replacing this part to function testimonial_rotator($atts)
    $postcontent=apply_filters( 'the_content', get_the_content() ) ;


    if ($show_size == "excerpt") {
      $postcontent=apply_filters( 'the_content', get_the_excerpt() ) ;
     else {
      $postcontent=apply_filters( 'the_content', get_the_content() ) ;

    Hope this helps people out!

    Would much appreciate it if a solution like this is included in the next version of the plugin.

    – Frank

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Shortcode for Excerpts’ is closed to new replies.