Ready to get started?Download WordPress


HMS Testimonials
[resolved] Truncate Testimonials in Widget? (3 posts)

  1. thinkspot
    Posted 1 year ago #

    Hi there,

    I'm currently fiddling around with your plugin and I was wondering, whether it's possible to limit the testimonials shown in the widget to a certain number of characters, i.e. prevent lengthy testimonials from screwing up the layout of a multi-column frontpage.

    Any hints will be greatly appreciated!

    Kind regards,


  2. Jeff K
    Plugin Author

    Posted 1 year ago #

    Not at this time. I will look at adding that feature in the future.

    Great idea!

  3. Jeff K
    Plugin Author

    Posted 1 year ago #

    Hey Matt, I just uploaded another update this morning 2.0.6 that adds filters.

    After you update, do the following:

    In your themes functions.php file add the following code:

    function limit_testimonial_text($text) {
    	return substr($text, 0, 100);
    add_filter('hms_testimonials_system_testimonial', 'limit_testimonial_text');

    It will then limit the testimonial text to 100 characters. If you need it more or less, adjust the 100 number.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic


No tags yet.