Advertisement
Guest User

loginform

a guest
Mar 10th, 2011
218
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 2.08 KB | None | 0 0
  1.         <?php do_action( 'bp_before_sidebar_me' ) ?>
  2.  
  3.         <div id="sidebar-me">
  4.             <a href="<?php echo bp_loggedin_user_domain() ?>">
  5.                 <?php bp_loggedin_user_avatar( 'type=thumb&width=40&height=40' ) ?>
  6.             </a>
  7.  
  8.             <h4><?php echo bp_core_get_userlink( bp_loggedin_user_id() ); ?></h4>
  9.             <a class="button logout" href="<?php echo wp_logout_url( bp_get_root_domain() ) ?>"><?php _e( 'Log Out', 'buddypress' ) ?></a>
  10.  
  11.             <?php do_action( 'bp_sidebar_me' ) ?>
  12.         </div>
  13.  
  14.         <?php do_action( 'bp_after_sidebar_me' ) ?>
  15.  
  16.         <?php if ( function_exists( 'bp_message_get_notices' ) ) : ?>
  17.             <?php bp_message_get_notices(); /* Site wide notices to all users */ ?>
  18.         <?php endif; ?>
  19.  
  20.     <?php else : ?>
  21.  
  22.         <?php do_action( 'bp_before_sidebar_login_form' ) ?>
  23.  
  24.         <p id="login-text">
  25.             <?php _e( 'To start connecting please log in first.', 'buddypress' ) ?>
  26.             <?php if ( bp_get_signup_allowed() ) : ?>
  27.                 <?php printf( __( ' You can also <a href="%s" title="Create an account">create an account</a>.', 'buddypress' ), site_url( BP_REGISTER_SLUG . '/' ) ) ?>
  28.             <?php endif; ?>
  29.         </p>
  30.  
  31.         <form name="login-form" id="sidebar-login-form" class="standard-form" action="<?php echo site_url( 'wp-login.php', 'login_post' ) ?>" method="post">
  32.             <label><?php _e( 'Username', 'buddypress' ) ?><br />
  33.             <input type="text" name="log" id="sidebar-user-login" class="input" value="<?php echo esc_attr(stripslashes($user_login)); ?>" tabindex="97" /></label>
  34.  
  35.             <label><?php _e( 'Password', 'buddypress' ) ?><br />
  36.             <input type="password" name="pwd" id="sidebar-user-pass" class="input" value="" tabindex="98" /></label>
  37.  
  38.             <p class="forgetmenot"><label><input name="rememberme" type="checkbox" id="sidebar-rememberme" value="forever" tabindex="99" /> <?php _e( 'Remember Me', 'buddypress' ) ?></label></p>
  39.  
  40.             <?php do_action( 'bp_sidebar_login_form' ) ?>
  41.             <input type="submit" name="wp-submit" id="sidebar-wp-submit" value="<?php _e('Log In'); ?>" tabindex="100" />
  42.             <input type="hidden" name="testcookie" value="1" />
  43.         </form>
  44.  
  45.         <?php do_action( 'bp_after_sidebar_login_form' ) ?>
  46.  
  47.     <?php endif; ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement