bp_embed_activity_cache

Fetch an activity item's cached embeds.

Description

bp_embed_activity_cache( (string) $cache, (int) $id, (string) $cachekey ); 

Used during via .

Parameters (3)

0. $cache (string)
An empty string passed by BP_Embed::parse_oembed() for functions like this one to filter.
1. $id (int)
The ID of the activity item.
2. $cachekey (string)
The cache key generated in BP_Embed::parse_oembed().

Usage

  1. if ( !function_exists( 'bp_embed_activity_cache' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'buddypress/bp-activity/bp-activity-functions.php'; 
  3.  
  4. // An empty string passed by BP_Embed::parse_oembed() for 
  5. // functions like this one to filter. 
  6. $cache = ''; 
  7.  
  8. // The ID of the activity item. 
  9. $id = -1; 
  10.  
  11. // The cache key generated in BP_Embed::parse_oembed(). 
  12. $cachekey = ''; 
  13.  
  14. // NOTICE! Understand what this does before running. 
  15. $result = bp_embed_activity_cache($cache, $id, $cachekey); 
  16.  

Defined (1)

The function is defined in the following location(s).

/bp-activity/bp-activity-functions.php  
  1. function bp_embed_activity_cache( $cache, $id, $cachekey ) { 
  2. return bp_activity_get_meta( $id, $cachekey );