Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: preprocess_signup_form

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

Line Code
968                break;
969           case 'default':
970           default:
971                $user_email = isset( $_POST['user_email'] ) ? $_POST['user_email'] : '';
972                /**
973                 * Fires when the site sign-up form is sent.
974                 *
975                 * @since 3.0.0
976                 */
977                do_action( 'preprocess_signup_form' );
978                if ( is_user_logged_in() && ( 'all' === $active_signup || 'blog' === $active_signup ) ) {
979                     signup_another_blog( $newblogname );
980                } elseif ( ! is_user_logged_in() && ( 'all' === $active_signup || 'user' === $active_signup ) ) {
981                     signup_user( $newblogname, $user_email );
982                } elseif ( ! is_user_logged_in() && ( 'blog' === $active_signup ) ) {
983                     _e( 'Sorry, new registrations are not allowed at this time.' );
984                } else {
985                     _e( 'You are logged in already. No need to register again!' );
986                }