bp_registration_options_display_activity_posting

Add activity item for newly approved member.

Description

bp_registration_options_display_activity_posting( (int) $user_id ); 

Parameters (1)

0. $user_id (int)
ID of the approved user.

Usage

  1. if ( !function_exists( 'bp_registration_options_display_activity_posting' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'bp-registration-options/includes/core.php'; 
  3.  
  4. // ID of the approved user. 
  5. $user_id = -1; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = bp_registration_options_display_activity_posting($user_id); 
  9.  

Defined (1)

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

/includes/core.php  
  1. function bp_registration_options_display_activity_posting( $user_id ) { 
  2. if ( bp_is_active( 'activity' ) ) { 
  3. bp_activity_add( array( 
  4. 'user_id' => $user_id,  
  5. 'component' => buddypress()->members->id,  
  6. 'type' => 'new_member',  
  7. ) );