bp_group_cover_refresh

The BuddyPress cover bp group cover refresh function.

Description

bp_group_cover_refresh(); 

Usage

  1. if ( !function_exists( 'bp_group_cover_refresh' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'buddypress-cover/bp-cover-group.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = bp_group_cover_refresh(); 
  7.  

Defined (1)

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

/bp-cover-group.php  
  1. function bp_group_cover_refresh() { 
  2. global $bp; 
  3. $group_id=bp_get_current_group_id();  
  4. if(empty($group_id)) 
  5. return false;  
  6. $image=groups_get_groupmeta($group_id, 'bp_cover_group', true);  
  7. $filter = " <div class='cover'> 
  8. <img class='bp-cover-top'  
  9. src='$image'width='100%' style='width: 100%;'> </div>"; 
  10. $filter .='<div id="bpci-polaroid-upload-group"> </div><div id="profile-mass">'.__("Drag cover", "bp-cover").'</div> '; 
  11. echo $filter;  
  12. die(); 
  13. }