This function has been deprecated.

bp_get_member_latest_update( array|string $args = '' )

Get the latest update from the current member in the loop.

Description

Parameters

$args

(Optional) Array of optional arguments.

  • 'length'
    (int) Truncation length. Default: 225.
  • 'view_link'
    (bool) Whether to provide a 'View' link for truncated entries. Default: false.

Default value: ''

Return

(string)

Source

File: bp-core/deprecated/buddyboss/1.0.php

	function bp_get_member_latest_update( $args = '' ) {
		global $members_template;

		_deprecated_function( __FUNCTION__, '1.0.0' );

		// $defaults = array(
		// 	'length'    => 225,
		// 	'view_link' => true
		// );

		// $r = wp_parse_args( $args, $defaults );
		// extract( $r );

		// if ( !bp_is_active( 'activity' ) || empty( $members_template->member->latest_update ) || !$update = maybe_unserialize( $members_template->member->latest_update ) )
		// 	return false;

		// /**
		//  * Filters the excerpt of the latest update for current member in the loop.
		//  *
		//  * @since BuddyPress 1.2.5
		//  * @since BuddyPress 2.6.0 Added the `$r` parameter.
		//  *
		//  * @param string $value Excerpt of the latest update for current member in the loop.
		//  * @param array  $r     Array of parsed arguments.
		//  */
		// $update_content = apply_filters( 'bp_get_activity_latest_update_excerpt', trim( strip_tags( bp_create_excerpt( $update['content'], $length ) ) ), $r );

		// $update_content = sprintf( _x( '- "%s"', 'member latest update in member directory', 'buddyboss' ), $update_content );

		// // If $view_link is true and the text returned by bp_create_excerpt() is different from the original text (ie it's
		// // been truncated), add the "View" link.
		// if ( $view_link && ( $update_content != $update['content'] ) ) {
		// 	$view = __( 'View', 'buddyboss' );

		// 	$update_content .= '<span class="activity-read-more"><a href="' . bp_activity_get_permalink( $update['id'] ) . '" rel="nofollow">' . $view . '</a></span>';
		// }

		// /**
		//  * Filters the latest update from the current member in the loop.
		//  *
		//  * @since BuddyPress 1.2.0
		//  * @since BuddyPress 2.6.0 Added the `$r` parameter.
		//  *
		//  * @param string $update_content Formatted latest update for current member.
		//  * @param array  $r              Array of parsed arguments.
		//  */
		// return apply_filters( 'bp_get_member_latest_update', $update_content, $r );
	}

Changelog

Changelog
Version Description
3.1.0 This function has been deprecated.
BuddyPress 1.2.0 Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.