Advertisement
Guest User

Registration Form

a guest
Jan 26th, 2012
884
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 12.69 KB | None | 0 0
  1. <div id="login">
  2.  
  3.         <?php do_action( 'bp_before_register_page' ) ?>
  4.  
  5.         <div id="form-container">
  6.  
  7.             <form action="" name="signup_form" id="signup_form" class="standard-form" method="post" enctype="multipart/form-data">
  8.  
  9.             <?php if ( 'request-details' == bp_get_current_signup_step() ) : ?>
  10.  
  11.                 <h1>Create Account</h1>
  12.                 <div id="register-progress-bar" class="step-1">Step 1 of 3</div>
  13.  
  14.                 <?php do_action( 'template_notices' ) ?>
  15.  
  16.                 <?php do_action( 'bp_before_account_details_fields' ) ?>
  17.  
  18.                 <div class="register-section" id="basic-details-section">
  19.  
  20.                     <?php /***** Basic Account Details ******/ ?>
  21.  
  22.                     <h4><?php _e( 'Account Details', 'buddypress' ) ?></h4>
  23.  
  24.                     <label for="signup_username"><?php _e( 'Username', 'buddypress' ) ?> <?php _e( '(required)', 'buddypress' ) ?></label>
  25.                     <?php do_action( 'bp_signup_username_errors' ) ?>
  26.                     <input type="text" name="signup_username" id="signup_username" value="<?php bp_signup_username_value() ?>" />
  27.                     <p class="description">One word, all lowercase letters.</p>
  28.  
  29.                     <label for="signup_email"><?php _e( 'Email Address', 'buddypress' ) ?> <?php _e( '(required)', 'buddypress' ) ?></label>
  30.                     <?php do_action( 'bp_signup_email_errors' ) ?>
  31.                     <input type="text" name="signup_email" id="signup_email" value="<?php bp_signup_email_value() ?>" />
  32.  
  33.                     <label for="signup_password"><?php _e( 'Choose a Password', 'buddypress' ) ?> <?php _e( '(required)', 'buddypress' ) ?></label>
  34.                     <?php do_action( 'bp_signup_password_errors' ) ?>
  35.                     <input type="password" name="signup_password" id="signup_password" value="" />
  36.  
  37.                     <label for="signup_password_confirm"><?php _e( 'Confirm Password', 'buddypress' ) ?> <?php _e( '(required)', 'buddypress' ) ?></label>
  38.                     <?php do_action( 'bp_signup_password_confirm_errors' ) ?>
  39.                     <input type="password" name="signup_password_confirm" id="signup_password_confirm" value="" />
  40.  
  41.                 </div><!-- #basic-details-section -->
  42.  
  43.                 <?php do_action( 'bp_after_account_details_fields' ) ?>
  44.  
  45.                 <?php /***** Extra Profile Details ******/ ?>
  46.  
  47.                 <?php if ( bp_is_active( 'xprofile' ) ) : ?>
  48.  
  49.                     <?php do_action( 'bp_before_signup_profile_fields' ) ?>
  50.  
  51.                     <div class="register-section" id="profile-details-section">
  52.  
  53.                         <h4><?php _e( 'Profile Details', 'buddypress' ) ?></h4>
  54.  
  55.                         <?php /* Use the profile field loop to render input fields for the 'base' profile field group */ ?>
  56.                         <?php if ( bp_is_active( 'xprofile' ) ) : if ( bp_has_profile( 'profile_group_id=1' ) ) : while ( bp_profile_groups() ) : bp_the_profile_group(); ?>
  57.  
  58.                         <?php while ( bp_profile_fields() ) : bp_the_profile_field(); ?>
  59.  
  60.                             <div class="editfield">
  61.  
  62.                                 <?php if ( 'textbox' == bp_get_the_profile_field_type() ) : ?>
  63.  
  64.                                     <label for="<?php bp_the_profile_field_input_name() ?>"><?php bp_the_profile_field_name() ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'buddypress' ) ?><?php endif; ?></label>
  65.                                     <?php do_action( 'bp_' . bp_get_the_profile_field_input_name() . '_errors' ) ?>
  66.                                     <input type="text" name="<?php bp_the_profile_field_input_name() ?>" id="<?php bp_the_profile_field_input_name() ?>" value="<?php bp_the_profile_field_edit_value() ?>" />
  67.  
  68.                                 <?php endif; ?>
  69.  
  70.                                 <?php if ( 'textarea' == bp_get_the_profile_field_type() ) : ?>
  71.  
  72.                                     <label for="<?php bp_the_profile_field_input_name() ?>"><?php bp_the_profile_field_name() ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'buddypress' ) ?><?php endif; ?></label>
  73.                                     <?php do_action( 'bp_' . bp_get_the_profile_field_input_name() . '_errors' ) ?>
  74.                                     <textarea rows="5" cols="40" name="<?php bp_the_profile_field_input_name() ?>" id="<?php bp_the_profile_field_input_name() ?>"><?php bp_the_profile_field_edit_value() ?></textarea>
  75.  
  76.                                 <?php endif; ?>
  77.  
  78.                                 <?php if ( 'selectbox' == bp_get_the_profile_field_type() ) : ?>
  79.  
  80.                                     <label for="<?php bp_the_profile_field_input_name() ?>"><?php bp_the_profile_field_name() ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'buddypress' ) ?><?php endif; ?></label>
  81.                                     <?php do_action( 'bp_' . bp_get_the_profile_field_input_name() . '_errors' ) ?>
  82.                                     <select name="<?php bp_the_profile_field_input_name() ?>" id="<?php bp_the_profile_field_input_name() ?>">
  83.                                         <?php bp_the_profile_field_options() ?>
  84.                                     </select>
  85.  
  86.                                 <?php endif; ?>
  87.  
  88.                                 <?php if ( 'multiselectbox' == bp_get_the_profile_field_type() ) : ?>
  89.  
  90.                                     <label for="<?php bp_the_profile_field_input_name() ?>"><?php bp_the_profile_field_name() ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'buddypress' ) ?><?php endif; ?></label>
  91.                                     <?php do_action( 'bp_' . bp_get_the_profile_field_input_name() . '_errors' ) ?>
  92.                                     <select name="<?php bp_the_profile_field_input_name() ?>" id="<?php bp_the_profile_field_input_name() ?>" multiple="multiple">
  93.                                         <?php bp_the_profile_field_options() ?>
  94.                                     </select>
  95.  
  96.                                 <?php endif; ?>
  97.  
  98.                                 <?php if ( 'radio' == bp_get_the_profile_field_type() ) : ?>
  99.  
  100.                                     <div class="radio">
  101.                                         <span class="label"><?php bp_the_profile_field_name() ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'buddypress' ) ?><?php endif; ?></span>
  102.  
  103.                                         <?php do_action( 'bp_' . bp_get_the_profile_field_input_name() . '_errors' ) ?>
  104.                                         <?php bp_the_profile_field_options() ?>
  105.  
  106.                                         <?php if ( !bp_get_the_profile_field_is_required() ) : ?>
  107.                                             <a class="clear-value" href="javascript:clear( '<?php bp_the_profile_field_input_name() ?>' );"><?php _e( 'Clear', 'buddypress' ) ?></a>
  108.                                         <?php endif; ?>
  109.                                     </div>
  110.  
  111.                                 <?php endif; ?>
  112.  
  113.                                 <?php if ( 'checkbox' == bp_get_the_profile_field_type() ) : ?>
  114.  
  115.                                     <div class="checkbox">
  116.                                         <span class="label"><?php bp_the_profile_field_name() ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'buddypress' ) ?><?php endif; ?></span>
  117.  
  118.                                         <?php do_action( 'bp_' . bp_get_the_profile_field_input_name() . '_errors' ) ?>
  119.                                         <?php bp_the_profile_field_options() ?>
  120.                                     </div>
  121.  
  122.                                 <?php endif; ?>
  123.  
  124.                                 <?php if ( 'datebox' == bp_get_the_profile_field_type() ) : ?>
  125.  
  126.                                     <div class="datebox">
  127.                                         <label for="<?php bp_the_profile_field_input_name() ?>_day"><?php bp_the_profile_field_name() ?> <?php if ( bp_get_the_profile_field_is_required() ) : ?><?php _e( '(required)', 'buddypress' ) ?><?php endif; ?></label>
  128.                                         <?php do_action( 'bp_' . bp_get_the_profile_field_input_name() . '_errors' ) ?>
  129.  
  130.                                         <select name="<?php bp_the_profile_field_input_name() ?>_day" id="<?php bp_the_profile_field_input_name() ?>_day">
  131.                                             <?php bp_the_profile_field_options( 'type=day' ) ?>
  132.                                         </select>
  133.  
  134.                                         <select name="<?php bp_the_profile_field_input_name() ?>_month" id="<?php bp_the_profile_field_input_name() ?>_month">
  135.                                             <?php bp_the_profile_field_options( 'type=month' ) ?>
  136.                                         </select>
  137.  
  138.                                         <select name="<?php bp_the_profile_field_input_name() ?>_year" id="<?php bp_the_profile_field_input_name() ?>_year">
  139.                                             <?php bp_the_profile_field_options( 'type=year' ) ?>
  140.                                         </select>
  141.                                     </div>
  142.  
  143.                                 <?php endif; ?>
  144.  
  145.                                 <?php do_action( 'bp_custom_profile_edit_fields' ) ?>
  146.  
  147.                                 <p class="description"><?php bp_the_profile_field_description() ?></p>
  148.  
  149.                             </div>
  150.  
  151.                         <?php endwhile; ?>
  152.  
  153.                         <input type="hidden" name="signup_profile_field_ids" id="signup_profile_field_ids" value="<?php bp_the_profile_group_field_ids() ?>" />
  154.  
  155.                         <?php endwhile; endif; endif; ?>
  156.  
  157.                     </div><!-- #profile-details-section -->
  158.  
  159.                     <?php do_action( 'bp_after_signup_profile_fields' ) ?>
  160.  
  161.                 <?php endif; ?>
  162.  
  163.                 <?php if ( bp_get_blog_signup_allowed() ) : ?>
  164.  
  165.                     <?php do_action( 'bp_before_blog_details_fields' ) ?>
  166.  
  167.                     <?php /***** Blog Creation Details ******/ ?>
  168.  
  169.                     <div class="register-section" id="blog-details-section">
  170.  
  171.                         <h4><?php _e( 'Blog Details', 'buddypress' ) ?></h4>
  172.  
  173.                         <div class="editfield">
  174.                                
  175.                                 <p><input type="checkbox" name="signup_with_blog" id="signup_with_blog" value="1"<?php if ( (int) bp_get_signup_with_blog_value() ) : ?> checked="checked"<?php endif; ?> /> <?php _e( 'Yes, I\'d like to create a new site', 'buddypress' ) ?></p>
  176.                                
  177.                         </div>
  178.  
  179.                         <div id="blog-details"<?php if ( (int) bp_get_signup_with_blog_value() ) : ?>class="show"<?php endif; ?>>
  180.  
  181.                             <div class="editfield">
  182.                            
  183.                                     <label for="signup_blog_url"><?php _e( 'Blog URL', 'buddypress' ) ?> <?php _e( '(required)', 'buddypress' ) ?></label>
  184.                                     <?php do_action( 'bp_signup_blog_url_errors' ) ?>
  185.        
  186.                                     <?php if ( is_subdomain_install() ) : ?>
  187.                                         http:// <input type="text" name="signup_blog_url" id="signup_blog_url" value="<?php bp_signup_blog_url_value() ?>" /> .<?php echo preg_replace( '|^https?://(?:www\.)|', '', site_url() ) ?>
  188.                                     <?php else : ?>
  189.                                         <?php echo site_url() ?>/ <input type="text" name="signup_blog_url" id="signup_blog_url" value="<?php bp_signup_blog_url_value() ?>" />
  190.                                     <?php endif; ?>
  191.                            
  192.                             </div>
  193.                             <div class="editfield">
  194.        
  195.                                     <label for="signup_blog_title"><?php _e( 'Site Title', 'buddypress' ) ?> <?php _e( '(required)', 'buddypress' ) ?></label>
  196.                                     <?php do_action( 'bp_signup_blog_title_errors' ) ?>
  197.                                     <input type="text" name="signup_blog_title" id="signup_blog_title" value="<?php bp_signup_blog_title_value() ?>" />
  198.  
  199.                             </div>
  200.                             <div class="editfield">
  201.                            
  202.                                     <span class="label"><?php _e( 'I would like my site to appear in search engines, and in public listings around this network.', 'buddypress' ) ?></span>
  203.                                     <?php do_action( 'bp_signup_blog_privacy_errors' ) ?>
  204.        
  205.                                     <label><input type="radio" name="signup_blog_privacy" id="signup_blog_privacy_public" value="public"<?php if ( 'public' == bp_get_signup_blog_privacy_value() || !bp_get_signup_blog_privacy_value() ) : ?> checked="checked"<?php endif; ?> /> <?php _e( 'Yes' ) ?></label>
  206.                                     <label><input type="radio" name="signup_blog_privacy" id="signup_blog_privacy_private" value="private"<?php if ( 'private' == bp_get_signup_blog_privacy_value() ) : ?> checked="checked"<?php endif; ?> /> <?php _e( 'No' ) ?></label>
  207.                            
  208.                             </div>
  209.  
  210.                         </div>
  211.  
  212.                     </div><!-- #blog-details-section -->
  213.  
  214.                     <?php do_action( 'bp_after_blog_details_fields' ) ?>
  215.  
  216.                 <?php endif; ?>
  217.  
  218.                 <?php do_action( 'bp_before_registration_submit_buttons' ) ?>
  219.  
  220.                 <p class="signup-submit">
  221.                     <input type="submit"name="signup_submit" id="signup_submit" value="Submit and Continue" />
  222.                 </p>
  223.  
  224.                 <?php do_action( 'bp_after_registration_submit_buttons' ) ?>
  225.  
  226.                 <?php wp_nonce_field( 'bp_new_signup' ) ?>
  227.  
  228.             <?php endif; // request-details signup step ?>
  229.  
  230.             <?php if ( 'completed-confirmation' == bp_get_current_signup_step() ) : ?>
  231.  
  232.                 <h1>Check Your Email</h1>
  233.                 <div id="register-progress-bar" class="step-2">Step 2 of 3</div>
  234.  
  235.                 <?php do_action( 'template_notices' ) ?>
  236.  
  237.                 <?php if ( bp_registration_needs_activation() ) : ?>
  238.                     <p class="instructions">Please click the link in the email we just sent you to activate your account. If you did not get the email try checking your Spam folder.</p>
  239.                 <?php else : ?>
  240.                     <p><?php _e( 'You have successfully created your account! Please log in using the username and password you have just created.', 'buddypress' ) ?></p>
  241.                    
  242.                     <div id="login-box">
  243.                
  244.                         <form name="login-form" id="sidebar-login-form" class="standard-form" action="<?php echo site_url( 'wp-login.php', 'login_post' ) ?>" method="post">
  245.                             <label><?php _e( 'Username', 'buddypress' ) ?><br />
  246.                             <input type="text" name="log" id="sidebar-user-login" class="input" value="<?php echo esc_attr(stripslashes($user_login)); ?>" /></label>
  247.                
  248.                             <label><?php _e( 'Password', 'buddypress' ) ?><br />
  249.                             <input type="password" name="pwd" id="sidebar-user-pass" class="input" value="" /></label>
  250.                
  251.                             <p class="forgetmenot"><label><input name="rememberme" type="checkbox" id="sidebar-rememberme" value="forever" /> <?php _e( 'Remember Me', 'buddypress' ) ?></label></p>
  252.                
  253.                             <?php do_action( 'bp_sidebar_login_form' ) ?>
  254.                             <input type="submit" name="wp-submit" id="sidebar-wp-submit" value="<?php _e('Log In'); ?>" tabindex="100" />
  255.                             <input type="hidden" name="testcookie" value="1" />
  256.                         </form>
  257.                    
  258.                     </div>
  259.                 <?php endif; ?>
  260.  
  261.             <?php endif; // completed-confirmation signup step ?>
  262.  
  263.             <?php do_action( 'bp_custom_signup_steps' ) ?>
  264.  
  265.             </form>
  266.  
  267.         </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement