public/wordpress/wp-content/plugins/wp-courseware/includes/controllers/students.php
/**
	 * Shortcode Student Accounts Display.
	 *
	 * @since 4.3.0
	 *
	 * @param array $atts The array of shortcode attributes.
	 */
Shortcode Student Accounts Display.

@param array $atts The array of shortcode attributes.
Shortcode Student Accounts Display . @param array $atts The array of shortcode attributes .
public function account_display( $atts = array() ) {
		global $wp;
		if ( ! is_user_logged_in() ) {
			$message = apply_filters( 'wpcw_student_account_message', '' );
			if ( ! empty( $message ) ) {
				wpcw_add_notice( $message );
			}
			if ( ! empty( $_GET['password-reset'] ) ) {
				wpcw_add_notice( __( 'Your password has been reset successfully.', 'wp-courseware' ) );
			}
			if ( isset( $wp->query_vars['lost-password'] ) ) {
				$this->lost_password_display();
			} elseif ( isset( $wp->query_vars['register'] ) ) {
				wpcw_get_template( 'account/form-register.php' );
			} else {
				wpcw_get_template( 'account/form-login.php' );
			}
		} else {
			if ( isset( $wp->query_vars['student-logout'] ) ) {
				wpcw_add_notice( sprintf( __( 'Are you sure you want to log out? <a href="%s">Confirm and log out</a>', 'wp-courseware' ), wpcw_logout_url() ) );
			}
			wpcw_get_template( 'account/account.php' );
		}
	}
public function account_display ( $ atts = array ( ) ) { global $ wp ; if ( ! is_user_logged_in ( ) ) { $ message = apply_filters ( 'wpcw_student_account_message' , '' ) ; if ( ! empty ( $ message ) ) { wpcw_add_notice ( $ message ) ; } if ( ! empty ( $ _GET [ 'password-reset' ] ) ) { wpcw_add_notice ( __ ( 'Your password has been reset successfully.' , 'wp-courseware' ) ) ; } if ( isset ( $ wp -> query_vars [ 'lost-password' ] ) ) { $ this -> lost_password_display ( ) ; } elseif ( isset ( $ wp -> query_vars [ 'register' ] ) ) { wpcw_get_template ( 'account/form-register.php' ) ; } else { wpcw_get_template ( 'account/form-login.php' ) ; } } else { if ( isset ( $ wp -> query_vars [ 'student-logout' ] ) ) { wpcw_add_notice ( sprintf ( __ ( 'Are you sure you want to log out? <a href="%s">Confirm and log out</a>' , 'wp-courseware' ) , wpcw_logout_url ( ) ) ) ; } wpcw_get_template ( 'account/account.php' ) ; } }
Shortcode Student Accounts Display.
Shortcode Student Accounts Display .
// After password reset, add confirmation message.