BP_Activity_oEmbed_Extension::set_oembed_response_data( int $item_id )

Sets the oEmbed response data for our activity item.

Description

Parameters

$item_id

(int) (Required) The activity ID.

Return

(array)

Source

File: bp-activity/classes/class-bp-activity-oembed-extension.php

	protected function set_oembed_response_data( $item_id ) {
		$activity = new BP_Activity_Activity( $item_id );

		return array(
			'content'      => $activity->content,
			'title'        => __( 'Activity', 'buddyboss' ),
			'author_name'  => bp_core_get_user_displayname( $activity->user_id ),
			'author_url'   => bp_core_get_user_domain( $activity->user_id ),

			// Custom identifier.
			'x_buddypress' => 'activity'
		);
	}

Changelog

Changelog
Version Description
BuddyPress 2.6.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.