Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
12/08/2016 02:38:06 AM (8 years ago)
Author:
boonebgorges
Message:

Introduce bp_activity_excerpt_length().

This function provides a centralized filter for controlling
the length of activity excerpts generated throughout BP.

Props sanket.parmar.
Fixes #7321.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-activity/bp-activity-filters.php

    r11256 r11280  
    451451    $append_text    = apply_filters( 'bp_activity_excerpt_append_text', __( '[Read more]', 'buddypress' ) );
    452452
    453     /**
    454      * Filters the excerpt length for the activity excerpt.
    455      *
    456      * @since 1.5.0
    457      *
    458      * @param int $value Number indicating how many words to trim the excerpt down to.
    459      */
    460     $excerpt_length = apply_filters( 'bp_activity_excerpt_length', 358 );
     453    $excerpt_length = bp_activity_get_excerpt_length();
    461454
    462455    $args = wp_parse_args( $args, array( 'ending' => __( '…', 'buddypress' ) ) );
Note: See TracChangeset for help on using the changeset viewer.