bp_core_signup_blog

Create a blog and user based on data supplied at user registration.

Description

bp_core_signup_blog( (string) $blog_domain, (string) $blog_path, (string) $blog_title, (string) $user_name, (string) $user_email, (string) $usermeta ); 

Parameters (6)

0. $blog_domain (string)
Domain requested by user.
1. $blog_path (string)
Path requested by user.
2. $blog_title (string)
Title as entered by user.
3. $user_name (string)
User_login of requesting user.
4. $user_email (string)
Email address of requesting user.
5. $usermeta (string)
Miscellaneous metadata for the user.

Usage

  1. if ( !function_exists( 'bp_core_signup_blog' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'buddypress/bp-members/bp-members-functions.php'; 
  3.  
  4. // Domain requested by user. 
  5. $blog_domain = ''; 
  6.  
  7. // Path requested by user. 
  8. $blog_path = ''; 
  9.  
  10. // Title as entered by user. 
  11. $blog_title = ''; 
  12.  
  13. // user_login of requesting user. 
  14. $user_name = ''; 
  15.  
  16. // Email address of requesting user. 
  17. $user_email = ''; 
  18.  
  19. // Miscellaneous metadata for the user. 
  20. $usermeta = ''; 
  21.  
  22. // NOTICE! Understand what this does before running. 
  23. $result = bp_core_signup_blog($blog_domain, $blog_path, $blog_title, $user_name, $user_email, $usermeta); 
  24.  

Defined (1)

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

/bp-members/bp-members-functions.php  
  1. function bp_core_signup_blog( $blog_domain, $blog_path, $blog_title, $user_name, $user_email, $usermeta ) { 
  2. if ( ! is_multisite() || ! function_exists( 'wpmu_signup_blog' ) ) { 
  3. return false; 
  4.  
  5. /** 
  6. * Filters the result of wpmu_signup_blog(). 
  7. * This filter provides no value and is retained for 
  8. * backwards compatibility. 
  9. * @since 1.2.2 
  10. * @param void $value 
  11. */ 
  12. return apply_filters( 'bp_core_signup_blog', wpmu_signup_blog( $blog_domain, $blog_path, $blog_title, $user_name, $user_email, $usermeta ) );