Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: add_signup_meta

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

This hook occurs 3 times in this file.

Line Code
345       * @since 3.0.0
346       *
347       * @param array $meta {
348       *     An array of default site meta variables.
349       *
350       *     @type int $lang_id     The language ID.
351       *     @type int $blog_public Whether search engines should be discouraged from indexing the site. 1 for true, 0 for false.
352       * }
353       */
354      $meta = apply_filters( 'add_signup_meta', $meta );
355
356      wpmu_create_blog( $domain, $path, $blog_title, $current_user->ID, $meta, $wpdb->siteid );
357      confirm_another_blog_signup($domain, $path, $blog_title, $current_user->user_login, $current_user->user_email, $meta);
358      return true;
359 }
360
361 /**
362  * Confirm a new site signup
363  *
 
Line Code
476           return false;
477      }
478
479      if ( 'blog' == $_POST['signup_for'] ) {
480           signup_blog($user_name, $user_email);
481           return false;
482      }
483
484      /** This filter is documented in wp-signup.php */
485      wpmu_signup_user( $user_name, $user_email, apply_filters( 'add_signup_meta', array() ) );
486
487      confirm_user_signup($user_name, $user_email);
488      return true;
489 }
490
491 /**
492  * New user signup confirmation
493  *
494  * @since MU
 
Line Code
600      if ( $errors->get_error_code() ) {
601           signup_blog($user_name, $user_email, $blogname, $blog_title, $errors);
602           return false;
603      }
604
605      $public = (int) $_POST['blog_public'];
606      $meta = array ('lang_id' => 1, 'public' => $public);
607
608      /** This filter is documented in wp-signup.php */
609      $meta = apply_filters( 'add_signup_meta', $meta );
610
611      wpmu_signup_blog($domain, $path, $blog_title, $user_name, $user_email, $meta);
612      confirm_blog_signup($domain, $path, $blog_title, $user_name, $user_email, $meta);
613      return true;
614 }
615
616 /**
617  * New site signup confirmation
618  *