From 90a469e3568b8f81a50fb31b520ecc5654956f05 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 10 Feb 2015 23:28:39 -0600 Subject: [PATCH 0001/1694] Update wp-members-email.php * applied new code standards * rebuilt admin notification email to follow new regular email structure with more filters * added $toggle to headers filter that is used in both emails so that headers could be filtered based on the email being sent (i.e. sending plain text for admin notification vs html for others. --- wp-members-email.php | 231 ++++++++++++++++++++++++++----------------- 1 file changed, 142 insertions(+), 89 deletions(-) diff --git a/wp-members-email.php b/wp-members-email.php index 53d80f4a..b99abfde 100644 --- a/wp-members-email.php +++ b/wp-members-email.php @@ -36,13 +36,13 @@ * @param array $wpmem_fields Array of the WP-Members fields (defaults to null). * @param array $fields Array of the registration data (defaults to null). */ -function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, $field_data = null ) -{ +function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, $field_data = null ) { + /** * Determine which email is being sent */ - switch( $toggle ) { - + switch ( $toggle ) { + case 0: //this is a new registration $arr = get_option( 'wpmembers_email_newreg' ); @@ -66,45 +66,46 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, $arr = get_option( 'wpmembers_email_repass' ); $arr['toggle'] = 'repass'; break; - + } /** get the user ID */ $user = new WP_User( $user_id ); - - /** userdata for default shortcodes */ + + /** userdata for default shortcodes */ $arr['user_id'] = $user_id; $arr['user_login'] = stripslashes( $user->user_login ); $arr['user_email'] = stripslashes( $user->user_email ); $arr['blogname'] = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); - $arr['exp_type'] = ( WPMEM_USE_EXP == 1 ) ? get_user_meta( $user_id, 'exp_type', 'true' ) : ''; - $arr['exp_date'] = ( WPMEM_USE_EXP == 1 ) ? get_user_meta( $user_id, 'expires', 'true' ) : ''; + $arr['exp_type'] = ( WPMEM_USE_EXP == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; + $arr['exp_date'] = ( WPMEM_USE_EXP == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; $arr['wpmem_msurl'] = get_option( 'wpmembers_msurl', null ); $arr['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); $arr['do_shortcodes'] = true; $arr['add_footer'] = true; $arr['disable'] = false; - + /* Apply filters (if set) for the sending email address */ global $wpmem_mail_from, $wpmem_mail_from_name; add_filter( 'wp_mail_from', 'wpmem_mail_from' ); add_filter( 'wp_mail_from_name', 'wpmem_mail_from_name' ); $default_header = ( $wpmem_mail_from && $wpmem_mail_from_name ) ? 'From: ' . $wpmem_mail_from_name . ' <' . $wpmem_mail_from . '>' : ''; - + /** * Filters the email headers. * * @since 2.7.4 * - * @param mixed The email headers. + * @param mixed $default_header The email headers. + * @param string $toggle Toggle to determine what email is being generated (newreg|newmod|appmod|repass|admin). */ - $arr['headers'] = apply_filters( 'wpmem_email_headers', $default_header ); - + $arr['headers'] = apply_filters( 'wpmem_email_headers', $default_header, $toggle ); + /** handle backward compatibility for customizations that may call the email function directly */ - if( ! $wpmem_fields ) { + if ( ! $wpmem_fields ) { $wpmem_fields = get_option( 'wpmembers_fields' ); } - + /** * Filter the email. * @@ -128,12 +129,12 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, /** * If emails are not disabled, continue the email process */ - if( ! $disable ) { + if ( ! $disable ) { /** * Legacy email filters applied */ - switch( $toggle ) { + switch ( $toggle ) { case 'newreg': //this is a new registration @@ -184,18 +185,18 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, break; } - + /** Get the email footer if needed */ $foot = ( $add_footer ) ? get_option ( 'wpmembers_email_footer' ) : ''; - + /** if doing shortcode replacements **/ - if( $do_shortcodes ) { + if ( $do_shortcodes ) { /** Setup default shortcodes */ $shortcd = array( '[blogname]', '[username]', '[password]', '[reglink]', '[members-area]', '[exp-type]', '[exp-data]' ); $replace = array( $blogname, $user_login, $password, $reg_link, $wpmem_msurl, $exp_type, $exp_date ); /** Setup custom field shortcodes */ - foreach( $wpmem_fields as $field ) { + foreach ( $wpmem_fields as $field ) { $shortcd[] = '[' . $field[2] . ']'; $replace[] = get_user_meta( $user_id, $field[2], true ); } @@ -205,22 +206,22 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, $body = str_replace( $shortcd, $replace, $body ); $foot = ( $add_footer ) ? str_replace( $shortcd, $replace, $foot ) : ''; } - + /** Append footer if needed **/ $body = ( $add_footer ) ? $body . "\r\n" . $foot : $body; /* Send the message */ wp_mail( $user_email, stripslashes( $subj ), stripslashes( $body ), $headers ); - + } - + return; } endif; -if( ! function_exists( 'wpmem_notify_admin' ) ): +if ( ! function_exists( 'wpmem_notify_admin' ) ): /** * Builds the email for admin notification of new user registration * @@ -232,68 +233,71 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, * @param array $wpmem_fields * @param array $field_data */ -function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) -{ +function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { + $wp_user_fields = array( 'user_login', 'user_nicename', 'user_url', 'user_registered', 'display_name', 'first_name', 'last_name', 'nickname', 'description' ); - $user = get_userdata( $user_id ); - $blogname = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); - - $user_ip = get_user_meta( $user_id, 'wpmem_reg_ip', true ); - $reg_link = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); - $act_link = get_bloginfo ( 'wpurl' ) . "/wp-admin/user-edit.php?user_id=".$user_id; - $exp_type = ( WPMEM_USE_EXP == 1 ) ? get_user_meta( $user_id, 'exp_type', 'true' ) : ''; - $exp_date = ( WPMEM_USE_EXP == 1 ) ? get_user_meta( $user_id, 'expires', 'true' ) : ''; + /** get the user ID */ + $user = get_userdata( $user_id ); - $field_str = ''; + /** get the email stored values */ + $arr = get_option( 'wpmembers_email_notify' ); + + /** userdata for default shortcodes */ + $arr['user_id'] = $user_id; + $arr['user_login'] = stripslashes( $user->user_login ); + $arr['user_email'] = stripslashes( $user->user_email ); + $arr['blogname'] = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); + $arr['user_ip'] = get_user_meta( $user_id, 'wpmem_reg_ip', true ); + $arr['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); + $arr['act_link'] = get_bloginfo ( 'wpurl' ) . "/wp-admin/user-edit.php?user_id=".$user_id; + $arr['exp_type'] = ( WPMEM_USE_EXP == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; + $arr['exp_date'] = ( WPMEM_USE_EXP == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; + $arr['do_shortcodes'] = true; + $arr['add_footer'] = true; + $arr['disable'] = false; + + $field_arr = array(); foreach ( $wpmem_fields as $meta ) { - if( $meta[4] == 'y' ) { + if ( $meta[4] == 'y' ) { $name = $meta[1]; - if( ! in_array( $meta[2], wpmem_get_excluded_meta( 'email' ) ) ) { - if( ( $meta[2] != 'user_email' ) && ( $meta[2] != 'password' ) ) { - if( $meta[2] == 'user_url' ) { + if ( ! in_array( $meta[2], wpmem_get_excluded_meta( 'email' ) ) ) { + if ( ( $meta[2] != 'user_email' ) && ( $meta[2] != 'password' ) ) { + if ( $meta[2] == 'user_url' ) { $val = esc_url( $user->user_url ); - } elseif( in_array( $meta[2], $wp_user_fields ) ) { + } elseif ( in_array( $meta[2], $wp_user_fields ) ) { $val = esc_html( $user->$meta[2] ); } else { - $val = esc_html( get_user_meta( $user_id, $meta[2], 'true' ) ); + $val = esc_html( get_user_meta( $user_id, $meta[2], true ) ); } - - $field_str.= "$name: $val \r\n"; + $field_arr[ $name ] = $val; } } } } - - /** Setup default shortcodes */ - $shortcd = array( '[blogname]', '[username]', '[email]', '[reglink]', '[exp-type]', '[exp-data]', '[user-ip]', '[activate-user]', '[fields]' ); - $replace = array( $blogname, $user->user_login, $user->user_email, $reg_link, $exp_type, $exp_date, $user_ip, $act_link, $field_str ); - - /** create the custom field shortcodes */ - foreach( $wpmem_fields as $field ) { - $shortcd[] = '[' . $field[2] . ']'; - $replace[] = get_user_meta( $user_id, $field[2], true ); - } - - $arr = get_option( 'wpmembers_email_notify' ); - - $subj = str_replace( $shortcd, $replace, $arr['subj'] ); - $body = str_replace( $shortcd, $replace, $arr['body'] ); - - $foot = get_option ( 'wpmembers_email_footer' ); - $foot = str_replace( $shortcd, $replace, $foot ); - - $body.= "\r\n" . $foot; - + $arr['field_arr'] = $field_arr; + + /* Apply filters (if set) for the sending email address */ + global $wpmem_mail_from, $wpmem_mail_from_name; + add_filter( 'wp_mail_from', 'wpmem_mail_from' ); + add_filter( 'wp_mail_from_name', 'wpmem_mail_from_name' ); + $default_header = ( $wpmem_mail_from && $wpmem_mail_from_name ) ? 'From: ' . $wpmem_mail_from_name . ' <' . $wpmem_mail_from . '>' : ''; + /** - * Filters the admin notification email. + * Filters the email headers. * - * @since 2.8.2 + * @since 2.7.4 * - * @param string $body The admin notification email body. + * @param mixed $default_header The email headers (default = null). + * @param string $toggle Toggle to determine what email is being generated (newreg|newmod|appmod|repass|admin). */ - $body = apply_filters( 'wpmem_email_notify', $body ); - + $arr['headers'] = apply_filters( 'wpmem_email_headers', $default_header, $toggle ); + + /** handle backward compatibility for customizations that may call the email function directly */ + if ( ! $wpmem_fields ) { + $wpmem_fields = get_option( 'wpmembers_fields' ); + } + /** * Filters the address the admin notification is sent to. * @@ -301,26 +305,75 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) * * @param string The email address of the admin to send to. */ - $admin_email = apply_filters( 'wpmem_notify_addr', get_option( 'admin_email' ) ); + $arr['admin_email'] = apply_filters( 'wpmem_notify_addr', get_option( 'admin_email' ) ); - /* Apply filters (if set) for the sending email address */ - global $wpmem_mail_from, $wpmem_mail_from_name; - add_filter( 'wp_mail_from', 'wpmem_mail_from' ); - add_filter( 'wp_mail_from_name', 'wpmem_mail_from_name' ); - $default_header = ( $wpmem_mail_from && $wpmem_mail_from_name ) ? 'From: ' . $wpmem_mail_from_name . ' <' . $wpmem_mail_from . '>' : ''; - /** - * Filters the email headers. + * Filter the email. * - * @since 2.7.4 + * This is a new and more powerful filter than was previously available for + * emails. This new filter passes the email subject, body, user ID, and several + * other settings and parameters for use in the filter function. It also passes + * an array of the WP-Members fields, and an array of the posted registration + * data from the register function. + * + * @since 2.9.8 * - * @param mixed The email headers (default = null). + * @param array $arr An array containing email body, subject, user id, and additional settings. + * @param array $wpmem_fields An array of the WP-Members fields. + * @param array $field_arr An array of the posted registration data. */ - $headers = apply_filters( 'wpmem_email_headers', $default_header ); - - /* Send the message */ - wp_mail( $admin_email, stripslashes( $subj ), stripslashes( $body ), $headers ); + $arr = apply_filters( 'wpmem_notify_filter', $arr, $wpmem_fields, $field_data ); + /** extract the array **/ + extract( $arr ); + + /** + * If emails are not disabled, continue the email process + */ + if ( ! $disable ) { + + /** split field_arr into field_str */ + $fields_str = ''; + foreach ( $field_arr as $key => $val ) { + $field_str.= $key . ': ' . $val . "\r\n"; + } + + /** Get the email footer if needed */ + $foot = ( $add_footer ) ? get_option ( 'wpmembers_email_footer' ) : ''; + + /** if doing shortcode replacements **/ + if ( $do_shortcodes ) { + /** Setup default shortcodes */ + $shortcd = array( '[blogname]', '[username]', '[email]', '[reglink]', '[exp-type]', '[exp-data]', '[user-ip]', '[activate-user]', '[fields]' ); + $replace = array( $blogname, $user->user_login, $user->user_email, $reg_link, $exp_type, $exp_date, $user_ip, $act_link, $field_str ); + + /** create the custom field shortcodes */ + foreach ( $wpmem_fields as $field ) { + $shortcd[] = '[' . $field[2] . ']'; + $replace[] = get_user_meta( $user_id, $field[2], true ); + } + + /* Get the subject, body, and footer shortcodes */ + $subj = str_replace( $shortcd, $replace, $subj ); + $body = str_replace( $shortcd, $replace, $body ); + $foot = ( $add_footer ) ? str_replace( $shortcd, $replace, $foot ) : ''; + } + + /** Append footer if needed **/ + $body = ( $add_footer ) ? $body . "\r\n" . $foot : $body; + + /** + * Filters the admin notification email. + * + * @since 2.8.2 + * + * @param string $body The admin notification email body. + */ + $body = apply_filters( 'wpmem_email_notify', $body ); + + /* Send the message */ + wp_mail( $admin_email, stripslashes( $subj ), stripslashes( $body ), $headers ); + } } endif; @@ -336,7 +389,7 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) function wpmem_mail_from( $email ) { global $wpmem_mail_from; $wpmem_mail_from = ( get_option( 'wpmembers_email_wpfrom' ) ) ? get_option( 'wpmembers_email_wpfrom' ) : $email; - return $wpmem_mail_from; + return $wpmem_mail_from; } @@ -348,10 +401,10 @@ function wpmem_mail_from( $email ) { * @param string $name * @return string $name */ -function wpmem_mail_from_name( $name ) { +function wpmem_mail_from_name( $name ) { global $wpmem_mail_from_name; $wpmem_mail_from_name = ( get_option( 'wpmembers_email_wpname' ) ) ? stripslashes( get_option( 'wpmembers_email_wpname' ) ) : $name; - return $wpmem_mail_from_name; + return $wpmem_mail_from_name; } -/** End of File **/ \ No newline at end of file +/** End of File **/ From a640330f2ef6a6347be6793a16dd5098bfc897fc Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 10 Feb 2015 23:37:05 -0600 Subject: [PATCH 0002/1694] Update wp-members-sidebar.php * added redirect_to parameter as a widget entry --- wp-members-sidebar.php | 60 ++++++++++++++++++++++-------------------- 1 file changed, 32 insertions(+), 28 deletions(-) diff --git a/wp-members-sidebar.php b/wp-members-sidebar.php index 77ecca6c..a33d76af 100644 --- a/wp-members-sidebar.php +++ b/wp-members-sidebar.php @@ -61,37 +61,32 @@ function wpmem_inc_status() * * @since 2.4 * + * @param string $post_to A URL to redirect to upon login, default null. * @global string $wpmem_regchk * @global string $user_login */ -function wpmem_do_sidebar() +function wpmem_do_sidebar( $post_to = null ) { global $wpmem_regchk; $url = get_bloginfo('url'); // used here and in the logout - //this returns us to the right place - if( isset( $_REQUEST['redirect_to'] ) ) { - $post_to = $_REQUEST['redirect_to']; - - } elseif( is_home() || is_front_page() ) { - $post_to = $_SERVER['REQUEST_URI']; - - } elseif( is_single() || is_page() ) { - $post_to = get_permalink(); - - } elseif( is_category() ) { - global $wp_query; - $cat_id = get_query_var( 'cat' ); - $post_to = get_category_link( $cat_id ); - - } elseif( is_search() ) { - $post_to = $url . '/?s=' . get_search_query(); - - } else { - - $post_to = $_SERVER['REQUEST_URI']; - + if ( ! $post_to ) { + if ( isset( $_REQUEST['redirect_to'] ) ) { + $post_to = $_REQUEST['redirect_to']; + } elseif ( is_home() || is_front_page() ) { + $post_to = $_SERVER['REQUEST_URI']; + } elseif ( is_single() || is_page() ) { + $post_to = get_permalink(); + } elseif ( is_category() ) { + global $wp_query; + $cat_id = get_query_var( 'cat' ); + $post_to = get_category_link( $cat_id ); + } elseif ( is_search() ) { + $post_to = $url . '/?s=' . get_search_query(); + } else { + $post_to = $_SERVER['REQUEST_URI']; + } } // clean whatever the url is @@ -291,7 +286,10 @@ function form( $instance ) { /* Default widget settings. */ - $defaults = array( 'title' => __('Login Status', 'wp-members') ); + $defaults = array( + 'title' => __('Login Status', 'wp-members'), + 'redirect_to' => '', + ); $instance = wp_parse_args( ( array ) $instance, $defaults ); /* Title input */ ?> @@ -299,6 +297,10 @@ function form( $instance )

+

+ + +

'; echo $after_widget; } } -/** End of File **/ \ No newline at end of file +/** End of File **/ From 1d547c7924bb7719531d75d84167688a86401e37 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 10 Feb 2015 23:39:50 -0600 Subject: [PATCH 0003/1694] Update wp-members-core.php * corrected get_user_meta 'true' --- wp-members-core.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-members-core.php b/wp-members-core.php index 9954f2c6..3afc5636 100644 --- a/wp-members-core.php +++ b/wp-members-core.php @@ -584,7 +584,7 @@ function wpmem_check_activated( $user, $username, $password ) } // activation flag must be validated - $active = get_user_meta( $user->ID, 'active', 1 ); + $active = get_user_meta( $user->ID, 'active', true ); if( $active != 1 ) { return new WP_Error( 'authentication_failed', __( 'ERROR: User has not been activated.', 'wp-members' ) ); } @@ -988,4 +988,4 @@ function wpmem_wplogin_stylesheet() { echo ''; } -/** End of File **/ \ No newline at end of file +/** End of File **/ From 29573d4f29e12c77b418cb8f22f853e57a6486a9 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 11 Feb 2015 13:40:57 -0600 Subject: [PATCH 0004/1694] Update users.php corrected get_user_meta 'true' --- users.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/users.php b/users.php index 1b4c2943..cafbcf7d 100644 --- a/users.php +++ b/users.php @@ -45,7 +45,7 @@ function wpmem_user_profile() foreach( $wpmem_fields as $meta ) { - $val = get_user_meta( $user_id, $meta[2], 'true' ); + $val = get_user_meta( $user_id, $meta[2], true ); $valtochk = ''; $chk_tos = true; @@ -65,7 +65,7 @@ function wpmem_user_profile() '; - $val = get_user_meta( $user_id, $meta[2], 'true' ); + $val = get_user_meta( $user_id, $meta[2], true ); if( $meta[3] == 'checkbox' || $meta[3] == 'select' ) { $valtochk = $val; $val = $meta[7]; @@ -125,4 +125,4 @@ function wpmem_profile_update() } } -/** End of File **/ \ No newline at end of file +/** End of File **/ From c1c25667d393a36086f6d2a8a0bfeef2e17095e1 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 11 Feb 2015 13:42:25 -0600 Subject: [PATCH 0005/1694] Update user-profile.php corrected get_user_meta 'true' --- admin/user-profile.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/admin/user-profile.php b/admin/user-profile.php index fe392846..5c243e64 100644 --- a/admin/user-profile.php +++ b/admin/user-profile.php @@ -69,7 +69,7 @@ function wpmem_admin_fields() '; - $val = htmlspecialchars( get_user_meta( $user_id, $meta[2], 'true' ) ); + $val = htmlspecialchars( get_user_meta( $user_id, $meta[2], true ) ); if( $meta[3] == 'checkbox' || $meta[3] == 'select' ) { $valtochk = $val; $val = $meta[7]; @@ -91,7 +91,7 @@ function wpmem_admin_fields() // see if reg is moderated, and if the user has been activated if( WPMEM_MOD_REG == 1 ) { - $user_active_flag = get_user_meta( $user_id, 'active', 'true' ); + $user_active_flag = get_user_meta( $user_id, 'active', true ); switch( $user_active_flag ) { case '': @@ -121,13 +121,13 @@ function wpmem_admin_fields() // if using subscription model, show expiration // if registration is moderated, this doesn't show if user is not active yet. if( WPMEM_USE_EXP == 1 ) { - if( ( WPMEM_MOD_REG == 1 && get_user_meta( $user_id, 'active', 'true' ) == 1 ) || ( WPMEM_MOD_REG != 1 ) ) { + if( ( WPMEM_MOD_REG == 1 && get_user_meta( $user_id, 'active', true ) == 1 ) || ( WPMEM_MOD_REG != 1 ) ) { wpmem_a_extenduser( $user_id ); } } ?> - + @@ -160,11 +160,11 @@ function wpmem_admin_update() $chk_pass = false; foreach( $wpmem_fields as $meta ) { if( $meta[6] == "n" && $meta[3] != 'password' && $meta[3] != 'checkbox' ) { - ( isset( $_POST[$meta[2]] ) ) ? $fields[$meta[2]] = $_POST[$meta[2]] : false; + ( isset( $_POST[ $meta[2] ] ) ) ? $fields[ $meta[2] ] = $_POST[ $meta[2] ] : false; } elseif( $meta[2] == 'password' && $meta[4] == 'y' ) { $chk_pass = true; } elseif( $meta[3] == 'checkbox' ) { - $fields[$meta[2]] = ( isset( $_POST[$meta[2]] ) ) ? $_POST[$meta[2]] : ''; + $fields[ $meta[2] ] = ( isset( $_POST[ $meta[2] ] ) ) ? $_POST[ $meta[2] ] : ''; } } @@ -211,4 +211,4 @@ function wpmem_admin_update() return; } -/** End of File **/ \ No newline at end of file +/** End of File **/ From 23762d706489582ab26f3d560a8654fde1accca7 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 11 Feb 2015 13:42:58 -0600 Subject: [PATCH 0006/1694] Update users.php corrected get_user_meta 'true' --- admin/users.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/users.php b/admin/users.php index ce5d2329..656f7a24 100644 --- a/admin/users.php +++ b/admin/users.php @@ -305,7 +305,7 @@ function wpmem_add_user_column_content( $value, $column_name, $user_id ) { * If the column is "active", then return the value or empty. * Returning in here keeps us from displaying another value. */ - return ( get_user_meta( $user_id , 'active', 'true' ) != 1 ) ? __( 'No' ) : ''; + return ( get_user_meta( $user_id , 'active', true ) != 1 ) ? __( 'No' ) : ''; } else { return; } @@ -444,4 +444,4 @@ function wpmem_a_pre_user_query( $user_search ) $user_search->query_where = str_replace( 'WHERE 1=1', $replace_query, $user_search->query_where ); } -/** End of File **/ \ No newline at end of file +/** End of File **/ From b0e06e4e5571739c9003a2e74a2a069cc64a0d6d Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 11 Feb 2015 14:59:20 -0600 Subject: [PATCH 0007/1694] Update tab-fields.php corrected error checking for adding new fields --- admin/tab-fields.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index eb075835..be1ab7c4 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -173,9 +173,9 @@ function wpmem_update_fields( $action ) global $add_field_err_msg; // error check that field label and option name are included and unique - $add_field_err_msg = ( ! $_POST['add_name'] ) ? __( 'Field Label is required for adding a new field. Nothing was updated.', 'wp-members' ) : false; - $add_field_err_msg = ( ! $_POST['add_option'] ) ? __( 'Option Name is required for adding a new field. Nothing was updated.', 'wp-members' ) : false; - + $add_field_err_msg = ( $_POST['add_name'] == '' ) ? __( 'Field Label is required for adding a new field. Nothing was updated.', 'wp-members' ) : false; + $add_field_err_msg = ( $_POST['add_option'] == '' ) ? __( 'Option Name is required for adding a new field. Nothing was updated.', 'wp-members' ) : false; + // check for duplicate field names $chk_fields = array(); foreach ( $wpmem_fields as $field ) { @@ -536,4 +536,4 @@ function wpmem_a_field_table( $wpmem_fields ) Date: Sat, 14 Feb 2015 23:46:36 -0600 Subject: [PATCH 0008/1694] added functions for updating user_status functions for updating user_status in wp_users --- admin/users.php | 44 ++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 42 insertions(+), 2 deletions(-) diff --git a/admin/users.php b/admin/users.php index 656f7a24..a06311d8 100644 --- a/admin/users.php +++ b/admin/users.php @@ -24,7 +24,9 @@ add_action( 'admin_notices', 'wpmem_users_admin_notices' ); add_filter( 'views_users', 'wpmem_users_views' ); add_filter( 'manage_users_columns', 'wpmem_add_user_column' ); -add_action( 'manage_users_custom_column', 'wpmem_add_user_column_content', 10, 3 ); +add_action( 'manage_users_custom_column', 'wpmem_add_user_column_content', 10, 3 ); +add_action( 'wpmem_post_register_data', 'wpmem_set_new_user_non_active' ); +add_action( 'wpmem_user_activated', 'wpmem_set_activated_user' ); if( WPMEM_MOD_REG == 1 ) { add_filter( 'user_row_actions', 'wpmem_insert_activate_link', 10, 2 ); } @@ -305,7 +307,7 @@ function wpmem_add_user_column_content( $value, $column_name, $user_id ) { * If the column is "active", then return the value or empty. * Returning in here keeps us from displaying another value. */ - return ( get_user_meta( $user_id , 'active', true ) != 1 ) ? __( 'No' ) : ''; + return ( get_user_meta( $user_id , 'active', 'true' ) != 1 ) ? __( 'No' ) : ''; } else { return; } @@ -444,4 +446,42 @@ function wpmem_a_pre_user_query( $user_search ) $user_search->query_where = str_replace( 'WHERE 1=1', $replace_query, $user_search->query_where ); } + +/** + * Use wpmem_post_register_data to set the user_status field to 2 using wp_update_user + * http://codex.wordpress.org/Function_Reference/wp_update_user + * + * @uses wpmem_set_user_status + * @param $fields + */ +function wpmem_set_new_user_non_active( $fields ) { + wpmem_set_user_status( $fields['ID'], 2 ) + return; +} + + +/** + * Use wpmem_user_activated to set the user_status field to 0 using wp_update_user + * + * @uses wpmem_set_user_status + * @param $user_id + */ +function wpmem_set_activated_user( $user_id ) { + wpmem_set_user_status( $user_id, 0 ) + return; +} + + +/** + * Updates the user_status value in the wp_users table + * + * @param $user_id + * @param $status + */ +function wpmem_set_user_status( $user_id, $status ) { + global $wpdb; + $wpdb->update( $wpdb->users, array( 'user_status' => $status ), array( 'ID' => $user_id ) ); + return; +} + /** End of File **/ From 2f7411ffefc8deafd9a155849e2216c84c0a2f76 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 14 Feb 2015 23:53:10 -0600 Subject: [PATCH 0009/1694] Update wp-members.php Added version data --- wp-members.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/wp-members.php b/wp-members.php index 90d351ae..c1f52601 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 2.9.8.1 +Version: 2.9.9 alpha Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ /** initial constants **/ -define( 'WPMEM_VERSION', '2.9.8.1' ); +define( 'WPMEM_VERSION', '2.9.9' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); @@ -332,4 +332,4 @@ function wpmem_mu_new_site( $blog_id, $user_id, $domain, $path, $site_id, $meta } -/** End of File **/ \ No newline at end of file +/** End of File **/ From 26f21fc4bce31686e49104c0f1930aa5ef406278 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 14 Feb 2015 23:57:56 -0600 Subject: [PATCH 0010/1694] Update readme.txt --- readme.txt | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/readme.txt b/readme.txt index 54574228..ccbad9c2 100644 --- a/readme.txt +++ b/readme.txt @@ -133,8 +133,14 @@ WP-Members 2.9.8 is mostly minor updates with the exception of a change to the p == Changelog == -= 2.9.8.1 = -* Fixed a bug that causes the login page shortcode to fail if the new redirect_to parameter is not included. If you use the login page shortcode, you should update. += 2.9.9 = +* code standards in wp-members-email.php +* rebuilt admin notification email to follow new regular email structure with more filters in wp-members-email.com +* added $toggle to headers filter that is used in both emails so that headers could be filtered based on the email being sent (i.e. sending plain text for admin notification vs html for others. in wp-members-email.php +* added redirect_to parameter as a widget entry in wp-members-sidebar.php +* corrected error checking for adding new fields in /admin/tab-fields.php +* added functions for updating user_status in wp_users table in /admin/users.php +* fixed get_user_meta 'true' error in wp-members-core.php, users.php, /admin/users.php, /admin/user-profile.php = 2.9.8 = * Fixed bug in settings update that caused the stored version number to be erased. @@ -412,7 +418,7 @@ Admin Panel Updates: * Add field dialog was updated and improved. * Added an admin process to edit existing fields. * Added new option in the plugin options to load one of the predefined stylesheets from a dropdown. -* Block/Unblock post meta box added to the post/page editor – no need to use custom fields anymore (this feature actually updates the custom fields accordingly, so you can use custom fields if you want to). +* Block/Unblock post meta box added to the post/page editor – no need to use custom fields anymore (this feature actually updates the custom fields accordingly, so you can use custom fields if you want to). * Added dropdown selector for preloaded stylesheets - no need to enter the location of the preloaded stylesheets to use them. New Filters: @@ -426,4 +432,4 @@ New Filters: Other Updates: -* Added a new pre-loaded stylesheet for Twenty Twelve theme. New installs will default to this style. Note: with the addition of the new style selector in the admin panel, you can easily toggle between the preloaded stylesheets. You can also add your own using the new wpmem_admin_style_list filter, enter the URL location in the Custom Stylesheet field, or load one using wp_enqueue_scripts. \ No newline at end of file +* Added a new pre-loaded stylesheet for Twenty Twelve theme. New installs will default to this style. Note: with the addition of the new style selector in the admin panel, you can easily toggle between the preloaded stylesheets. You can also add your own using the new wpmem_admin_style_list filter, enter the URL location in the Custom Stylesheet field, or load one using wp_enqueue_scripts. From fa2c79bdf26d1b182a8e407c64c0c8f768c2fc2a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 16 Feb 2015 15:31:27 -0600 Subject: [PATCH 0011/1694] Update wp-members-install.php Added update function for updating active users using user_status field --- wp-members-install.php | 39 +++++++++++++++++++++++++++------------ 1 file changed, 27 insertions(+), 12 deletions(-) diff --git a/wp-members-install.php b/wp-members-install.php index f49b43ab..75b09112 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -79,20 +79,22 @@ function wpmem_do_install() update_option( 'wpmembers_dialogs', $wpmem_dialogs_arr, '', 'yes' ); // using update_option to allow for forced update - append_tos( 'new' ); + wpmem_append_tos( 'new' ); - append_email(); + wpmem_append_email(); // if it's a new install, use the Twenty Twelve stylesheet update_option( 'wpmembers_style', plugin_dir_url ( __FILE__ ) . 'css/generic-no-float.css', '', 'yes' ); } else { - update_captcha(); + wpmem_update_active(); - update_dialogs(); + wpmem_update_captcha(); - append_email(); + wpmem_update_dialogs(); + + wpmem_append_email(); $wpmem_settings = get_option( 'wpmembers_settings' ); @@ -117,7 +119,7 @@ function wpmem_do_install() $wpmem_settings[3] // 11 ignore warnings ); update_option( 'wpmembers_settings', $wpmem_newsettings ); - append_tos( '2.2+' ); + wpmem_append_tos( '2.2+' ); break; case 10: // count($wpmem_settings) > 4 && count($wpmem_settings) < 12 @@ -139,7 +141,7 @@ function wpmem_do_install() $wpmem_settings[9] // 11 ignore warnings ); update_option( 'wpmembers_settings', $wpmem_newsettings ); - append_tos( '2.2+'); + wpmem_append_tos( '2.2+'); break; case 12: @@ -173,7 +175,7 @@ function wpmem_do_install() * * @since 2.4 */ -function append_tos( $upgrade ) +function wpmem_append_tos( $upgrade ) { // check if _tos has been put in before; if not, populate dummy data if( !get_option('wpmembers_tos') ) { @@ -200,7 +202,7 @@ function append_tos( $upgrade ) * * @since 2.7 */ -function append_email() +function wpmem_append_email() { //email for a new registration @@ -342,7 +344,7 @@ function append_email() * * @since 2.9.3 */ -function update_dialogs() +function wpmem_update_dialogs() { $wpmem_dialogs_arr = get_option( 'wpmembers_dialogs' ); $do_update = false; @@ -370,7 +372,7 @@ function update_dialogs() * * @since 2.9.5 */ -function update_captcha() +function wpmem_update_captcha() { $captcha_settings = get_option( 'wpmembers_captcha' ); @@ -398,4 +400,17 @@ function update_captcha() } -/** End of File **/ \ No newline at end of file +function wpmem_update_active(){ + global $wpdb; + $users = get_users( array( 'fields'=>'ID' ) ); + $is_active = get_user_meta( $user, 'active', true ); + foreach( $users as $user ){ + if( ! $is_active || $is_active != 1 ) { + $wpdb->update( $wpdb->users, array( 'user_status' => '2' ), array( 'ID' => $user ) ); + } elseif( $is_active == 1 ) { + $wpdb->update( $wpdb->users, array( 'user_status' => '0' ), array( 'ID' => $user ) ); + } + } + return; +} +/** End of File **/ From 02071b807bde861f5ce31cf992780e265eca8740 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 18 Feb 2015 13:50:12 -0600 Subject: [PATCH 0012/1694] Corrected error checking when adding new fields --- admin/tab-fields.php | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index be1ab7c4..d7e1612e 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -171,18 +171,23 @@ function wpmem_update_fields( $action ) check_admin_referer( 'wpmem-add-fields' ); global $add_field_err_msg; + + $add_field_err_msg = false; // error check that field label and option name are included and unique - $add_field_err_msg = ( $_POST['add_name'] == '' ) ? __( 'Field Label is required for adding a new field. Nothing was updated.', 'wp-members' ) : false; - $add_field_err_msg = ( $_POST['add_option'] == '' ) ? __( 'Option Name is required for adding a new field. Nothing was updated.', 'wp-members' ) : false; - + $add_field_err_msg = ( $_POST['add_name'] == '' ) ? __( 'Field Label is required for adding a new field. Nothing was updated.', 'wp-members' ) : $add_field_err_msg; + $add_field_err_msg = ( $_POST['add_option'] == '' ) ? __( 'Option Name is required for adding a new field. Nothing was updated.', 'wp-members' ) : $add_field_err_msg; + + //$option_len = strlen( $_POST['add_option'] ); + $add_field_err_msg = ( !preg_match("/^[A-Za-z0-9_]*$/", $_POST['add_option'] ) ) ? __( 'Option Name must contain only letters, numbers, and underscores', 'wp-members' ) : $add_field_err_msg; + // check for duplicate field names $chk_fields = array(); foreach ( $wpmem_fields as $field ) { $chk_fields[] = $field[2]; } - $add_field_err_msg = ( in_array( $_POST['add_option'], $chk_fields ) ) ? __( 'A field with that option name already exists', 'wp-members' ) : false; - + $add_field_err_msg = ( in_array( $_POST['add_option'], $chk_fields ) ) ? __( 'A field with that option name already exists', 'wp-members' ) : $add_field_err_msg; + // error check option name for spaces and replace with underscores $us_option = $_POST['add_option']; $us_option = preg_replace( "/ /", '_', $us_option ); @@ -198,7 +203,7 @@ function wpmem_update_fields( $action ) $arr[6] = ( $us_option == 'user_nicename' || $us_option == 'display_name' || $us_option == 'nickname' ) ? 'y' : 'n'; if( $_POST['add_type'] == 'checkbox' ) { - $add_field_err_msg = ( ! $_POST['add_checked_value'] ) ? __( 'Checked value is required for checkboxes. Nothing was updated.', 'wp-members' ) : false; + $add_field_err_msg = ( ! $_POST['add_checked_value'] ) ? __( 'Checked value is required for checkboxes. Nothing was updated.', 'wp-members' ) : $add_field_err_msg; $arr[7] = ( isset( $_POST['add_checked_value'] ) ) ? $_POST['add_checked_value'] : false; $arr[8] = ( isset( $_POST['add_checked_default'] ) ) ? $_POST['add_checked_default'] : 'n'; } From 2f59bd5ffc38290eab5f399dcc0796b034683044 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 26 Feb 2015 10:43:23 -0600 Subject: [PATCH 0013/1694] Update wp-members.php Implemented fixes for determining the stylesheet path --- wp-members.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/wp-members.php b/wp-members.php index c1f52601..805448cc 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 2.9.9 alpha +Version: 2.9.8.1 Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ /** initial constants **/ -define( 'WPMEM_VERSION', '2.9.9' ); +define( 'WPMEM_VERSION', '2.9.8.1' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); @@ -131,8 +131,8 @@ function wpmem_init() /** * define the stylesheet */ - $wpmem_style = get_option( 'wpmembers_cssurl', null ); - $wpmem_style = ( ! $wpmem_style ) ? get_option( 'wpmembers_style', null ) : $wpmem_style; + $wpmem_style = get_option( 'wpmembers_style', null ); + $wpmem_style = ( $wpmem_style == 'use_custom' || ! $wpmem_style ) ? get_option( 'wpmembers_cssurl', null ) : $wpmem_style; define( 'WPMEM_CSSURL', $wpmem_style ); From 5d0c558b8caf98e755860b90e89105b398e3f39f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 26 Feb 2015 10:44:23 -0600 Subject: [PATCH 0014/1694] Update utilities.php Changes to correct what the stylesheet path should be --- utilities.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/utilities.php b/utilities.php index 2757be82..8843c7d7 100644 --- a/utilities.php +++ b/utilities.php @@ -191,8 +191,7 @@ function wpmem_texturize( $content ) * @uses wp_enqueue_style */ function wpmem_enqueue_style() { - $css_path = ( WPMEM_CSSURL != null ) ? WPMEM_CSSURL : WP_PLUGIN_URL . '/' . str_replace( basename( __FILE__ ), "", plugin_basename( __FILE__ ) ) . "css/wp-members.css"; - wp_register_style( 'wp-members', $css_path, '', WPMEM_VERSION ); + wp_register_style( 'wp-members', WPMEM_CSSURL, '', WPMEM_VERSION ); wp_enqueue_style ( 'wp-members' ); } endif; @@ -323,4 +322,4 @@ function wpmem_use_ssl() { return ( is_ssl() ) ? 'https://' : 'http://'; } -/** End of File **/ \ No newline at end of file +/** End of File **/ From 80991cacd8900ff25e98dab1dab8ae14643e1808 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 26 Feb 2015 14:06:09 -0600 Subject: [PATCH 0015/1694] Update users.php --- admin/users.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/users.php b/admin/users.php index a06311d8..775060e7 100644 --- a/admin/users.php +++ b/admin/users.php @@ -455,7 +455,7 @@ function wpmem_a_pre_user_query( $user_search ) * @param $fields */ function wpmem_set_new_user_non_active( $fields ) { - wpmem_set_user_status( $fields['ID'], 2 ) + wpmem_set_user_status( $fields['ID'], 2 ); return; } @@ -467,7 +467,7 @@ function wpmem_set_new_user_non_active( $fields ) { * @param $user_id */ function wpmem_set_activated_user( $user_id ) { - wpmem_set_user_status( $user_id, 0 ) + wpmem_set_user_status( $user_id, 0 ); return; } From 1216e16e05c1e815b7a5b400c61f2ad4d32938ce Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 26 Feb 2015 15:42:20 -0600 Subject: [PATCH 0016/1694] Update wp-members-install.php fixed the update users to active to only run if moderation is enabled. --- wp-members-install.php | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/wp-members-install.php b/wp-members-install.php index 75b09112..808e2de5 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -88,8 +88,6 @@ function wpmem_do_install() } else { - wpmem_update_active(); - wpmem_update_captcha(); wpmem_update_dialogs(); @@ -120,6 +118,7 @@ function wpmem_do_install() ); update_option( 'wpmembers_settings', $wpmem_newsettings ); wpmem_append_tos( '2.2+' ); + wpmem_update_active( 0 ); break; case 10: // count($wpmem_settings) > 4 && count($wpmem_settings) < 12 @@ -142,6 +141,7 @@ function wpmem_do_install() ); update_option( 'wpmembers_settings', $wpmem_newsettings ); wpmem_append_tos( '2.2+'); + wpmem_update_active( $wpmem_settings[5] ); break; case 12: @@ -164,6 +164,7 @@ function wpmem_do_install() $wpmem_settings[11] // 11 ignore warnings ); update_option( 'wpmembers_settings', $wpmem_newsettings ); + wpmem_update_active( $wpmem_settings[5] ); break; } } @@ -400,15 +401,17 @@ function wpmem_update_captcha() } -function wpmem_update_active(){ - global $wpdb; - $users = get_users( array( 'fields'=>'ID' ) ); - $is_active = get_user_meta( $user, 'active', true ); - foreach( $users as $user ){ - if( ! $is_active || $is_active != 1 ) { - $wpdb->update( $wpdb->users, array( 'user_status' => '2' ), array( 'ID' => $user ) ); - } elseif( $is_active == 1 ) { - $wpdb->update( $wpdb->users, array( 'user_status' => '0' ), array( 'ID' => $user ) ); +function wpmem_update_active( $mod ) { + if( $mod == 1 ) { + global $wpdb; + $users = get_users( array( 'fields'=>'ID' ) ); + foreach( $users as $user ){ + $is_active = get_user_meta( $user, 'active', true ); + if( ! $is_active || $is_active != 1 ) { + $wpdb->update( $wpdb->users, array( 'user_status' => '2' ), array( 'ID' => $user ) ); + } elseif( $is_active == 1 ) { + $wpdb->update( $wpdb->users, array( 'user_status' => '0' ), array( 'ID' => $user ) ); + } } } return; From c38574b2bdb45f3a630f0daa44194ee0d2cf8b87 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 5 Mar 2015 14:09:14 -0600 Subject: [PATCH 0017/1694] added new action wpmem_user_deactivated and new function wpmem_set_deactivated_user to improve user deactivation. --- admin/users.php | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/admin/users.php b/admin/users.php index 775060e7..1f6889e8 100644 --- a/admin/users.php +++ b/admin/users.php @@ -27,6 +27,7 @@ add_action( 'manage_users_custom_column', 'wpmem_add_user_column_content', 10, 3 ); add_action( 'wpmem_post_register_data', 'wpmem_set_new_user_non_active' ); add_action( 'wpmem_user_activated', 'wpmem_set_activated_user' ); +add_action( 'wpmem_user_deactivated', 'wpmem_set_deactivated_user' ); if( WPMEM_MOD_REG == 1 ) { add_filter( 'user_row_actions', 'wpmem_insert_activate_link', 10, 2 ); } @@ -393,6 +394,7 @@ function wpmem_a_activate_user( $user_id, $chk_pass = false ) */ function wpmem_a_deactivate_user( $user_id ) { update_user_meta( $user_id, 'active', 0 ); + do_action( 'wpmem_user_deactivated', $user_id ); } @@ -448,7 +450,7 @@ function wpmem_a_pre_user_query( $user_search ) /** - * Use wpmem_post_register_data to set the user_status field to 2 using wp_update_user + * Use wpmem_post_register_data to set the user_status field to 2 using wp_update_user. * http://codex.wordpress.org/Function_Reference/wp_update_user * * @uses wpmem_set_user_status @@ -461,7 +463,7 @@ function wpmem_set_new_user_non_active( $fields ) { /** - * Use wpmem_user_activated to set the user_status field to 0 using wp_update_user + * Use wpmem_user_activated to set the user_status field to 0 using wp_update_user. * * @uses wpmem_set_user_status * @param $user_id @@ -472,6 +474,18 @@ function wpmem_set_activated_user( $user_id ) { } +/** + * Use wpmem_user_deactivated to set the user_status field to 2 using wp_update_user. + * + * @uses wpmem_set_user_status + * @param $user_id + */ +function wpmem_set_deactivated_user( $user_id ) { + wpmem_set_user_status( $user_id, 2 ); + return; +} + + /** * Updates the user_status value in the wp_users table * From fae1d164bb981e4537a5690857628f4db8621eb7 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 8 Mar 2015 14:03:29 -0500 Subject: [PATCH 0018/1694] Update wp-members-core.php added "echo" parameter for wpmem_login_status function (defaults to true) --- wp-members-core.php | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/wp-members-core.php b/wp-members-core.php index 3afc5636..23efd183 100644 --- a/wp-members-core.php +++ b/wp-members-core.php @@ -706,12 +706,20 @@ function wpmem_logout() * * @since 2.0 * - * @uses wpmem_inc_memberlinks() + * @uses wpmem_inc_memberlinks(). + * @param boolean $echo Determines whether function should print result or not (default: true). + * @return string $status The user status string produced by wpmem_inc_memberlinks(). */ -function wpmem_login_status() +function wpmem_login_status( $echo = true ) { - include_once('wp-members-dialogs.php'); - if (is_user_logged_in()) { echo wpmem_inc_memberlinks( 'status' ); } + include_once( 'wp-members-dialogs.php' ); + if ( is_user_logged_in() ) { + $status = wpmem_inc_memberlinks( 'status' ); + if ( $echo ) { + echo $status; + } + return $status; + } } endif; From 31418c4f352ca855a15854af7bbc203731063337 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 8 Mar 2015 14:04:15 -0500 Subject: [PATCH 0019/1694] Update wp-members-dialogs.php added wpmem_status_msg_args and wpmem_login_links_args filters. --- wp-members-dialogs.php | 59 +++++++++++++++++++++++++++++++++++------- 1 file changed, 50 insertions(+), 9 deletions(-) diff --git a/wp-members-dialogs.php b/wp-members-dialogs.php index b85b19ca..5ff3bbc2 100644 --- a/wp-members-dialogs.php +++ b/wp-members-dialogs.php @@ -219,11 +219,32 @@ function wpmem_inc_memberlinks( $page = 'members' ) break; case 'login': + + $args = array( + 'wrapper_before' => '

', + 'wrapper_after' => '

', + 'user_login' => $user_login, + 'welcome' => __( 'You are logged in as %s', 'wp-members' ), + 'logout_text' => __( 'Click to log out', 'wp-members' ), + 'logout_link' => '%s', + 'separator' => '
', + ); + /** + * Filter the status message parts. + * + * @since 2.9.9 + * + * @param array $args. + */ + $args = apply_filters( 'wpmem_login_links_args', $args ); + + /** Assemble the message string **/ + $str = $args['wrapper_before'] + . sprintf( $args['welcome'], $args['user_login'] ) + . $args['separator'] + . sprintf( $args['logout_link'], $args['logout_text'] ) + . $args['wrapper_after']; - $str = '

- ' . sprintf( __( 'You are logged in as %s', 'wp-members' ), $user_login ) . '
- ' . __( 'Click to log out', 'wp-members' ) . ' -

'; /** * Filter the links displayed on the Log In page (logged in state). * @@ -235,10 +256,30 @@ function wpmem_inc_memberlinks( $page = 'members' ) break; case 'status': - $str ='

- ' . sprintf( __( 'You are logged in as %s', 'wp-members' ), $user_login ) . ' | - ' . __( 'click to log out', 'wp-members' ) . ' -

'; + $args = array( + 'wrapper_before' => '

', + 'wrapper_after' => '

', + 'user_login' => $user_login, + 'welcome' => __( 'You are logged in as %s', 'wp-members' ), + 'logout_text' => __( 'click to log out', 'wp-members' ), + 'logout_link' => '%s', + 'separator' => ' | ', + ); + /** + * Filter the status message parts. + * + * @since 2.9.9 + * + * @param array $args. + */ + $args = apply_filters( 'wpmem_status_msg_args', $args ); + + /** Assemble the message string **/ + $str = $args['wrapper_before'] + . sprintf( $args['welcome'], $args['user_login'] ) + . $args['separator'] + . sprintf( $args['logout_link'], $args['logout_text'] ) + . $args['wrapper_after']; break; } @@ -344,4 +385,4 @@ function wpmem_page_user_edit( $wpmem_regchk, $content ) } endif; -/** End of File **/ \ No newline at end of file +/** End of File **/ From 4d50620ef38c4b4b0d27a42e2f4bd323cb251a82 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 9 Mar 2015 09:22:37 -0500 Subject: [PATCH 0020/1694] new dummy comments template to securify comments, remove empty password, confirm, and email confirm fields from export --- admin/user-export.php | 56 +++++++++++++++++++++------------------ lib/comments_template.php | 7 +++++ wp-members-core.php | 21 ++++++++++++++- wp-members-sidebar.php | 2 +- wp-members.php | 5 ++-- 5 files changed, 61 insertions(+), 30 deletions(-) create mode 100644 lib/comments_template.php diff --git a/admin/user-export.php b/admin/user-export.php index 452acca9..26046ce4 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -24,15 +24,15 @@ * @param array $args * @param array $users */ -function wpmem_export_users( $args, $users = null ) -{ +function wpmem_export_users( $args, $users = null ) { $today = date( "m-d-y" ); /** Setup defaults **/ $defaults = array( - 'export' => 'all', - 'filename' => 'wp-members-user-export-' . $today . '.csv', - 'export_fields' => array() + 'export' => 'all', + 'filename' => 'wp-members-user-export-' . $today . '.csv', + 'export_fields' => array(), + 'exclude_fields' => array( 'password', 'confirm_password', 'confirm_email' ), ); /** merge $args with defaults and extract **/ @@ -64,16 +64,18 @@ function wpmem_export_users( $args, $users = null ) /** do the header row */ $hrow = "User ID,Username,"; - foreach( $wpmem_fields as $meta ) { - $hrow.= $meta[1] . ","; + foreach ( $wpmem_fields as $meta ) { + if ( ! in_array( $meta[2], $exclude_fields ) ) { + $hrow.= $meta[1] . ","; + } } - $hrow.= ( WPMEM_MOD_REG == 1 ) ? __( 'Activated?', 'wp-members' ) . "," : ''; - $hrow.= ( WPMEM_USE_EXP == 1 ) ? __( 'Subscription', 'wp-members' ) . "," . __( 'Expires', 'wp-members' ) . "," : ''; + $hrow .= ( WPMEM_MOD_REG == 1 ) ? __( 'Activated?', 'wp-members' ) . "," : ''; + $hrow .= ( WPMEM_USE_EXP == 1 ) ? __( 'Subscription', 'wp-members' ) . "," . __( 'Expires', 'wp-members' ) . "," : ''; - $hrow.= __( 'Registered', 'wp-members' ) . ","; - $hrow.= __( 'IP', 'wp-members' ); - $data = $hrow . "\r\n"; + $hrow .= __( 'Registered', 'wp-members' ) . ","; + $hrow .= __( 'IP', 'wp-members' ); + $data = $hrow . "\r\n"; /** * we used the fields array once, @@ -86,31 +88,33 @@ function wpmem_export_users( $args, $users = null ) * build the data, delimit by commas, wrap fields with double quotes, * use \n switch for new line */ - foreach( $users as $user ) { + foreach ( $users as $user ) { $user_info = get_userdata( $user ); - $data.= '"' . $user_info->ID . '","' . $user_info->user_login . '",'; + $data .= '"' . $user_info->ID . '","' . $user_info->user_login . '",'; $wp_user_fields = array( 'user_email', 'user_nicename', 'user_url', 'display_name' ); - foreach( $wpmem_fields as $meta ) { - if( in_array( $meta[2], $wp_user_fields ) ){ - $data.= '"' . $user_info->$meta[2] . '",'; - } else { - $data.= '"' . get_user_meta( $user, $meta[2], true ) . '",'; + foreach ( $wpmem_fields as $meta ) { + if ( ! in_array( $meta[2], $exclude_fields ) ) { + if ( in_array( $meta[2], $wp_user_fields ) ){ + $data .= '"' . $user_info->$meta[2] . '",'; + } else { + $data .= '"' . get_user_meta( $user, $meta[2], true ) . '",'; + } } } - $data.= ( WPMEM_MOD_REG == 1 ) ? '"' . ( get_user_meta( $user, 'active', 1 ) ) ? __( 'Yes' ) : __( 'No' ) . '",' : ''; - $data.= ( WPMEM_USE_EXP == 1 ) ? '"' . get_user_meta( $user, "exp_type", true ) . '",' : ''; - $data.= ( WPMEM_USE_EXP == 1 ) ? '"' . get_user_meta( $user, "expires", true ) . '",' : ''; + $data .= ( WPMEM_MOD_REG == 1 ) ? '"' . ( get_user_meta( $user, 'active', 1 ) ) ? __( 'Yes' ) : __( 'No' ) . '",' : ''; + $data .= ( WPMEM_USE_EXP == 1 ) ? '"' . get_user_meta( $user, "exp_type", true ) . '",' : ''; + $data .= ( WPMEM_USE_EXP == 1 ) ? '"' . get_user_meta( $user, "expires", true ) . '",' : ''; - $data.= '"' . $user_info->user_registered . '",'; - $data.= '"' . get_user_meta( $user, "wpmem_reg_ip", true ). '"'; - $data.= "\r\n"; + $data .= '"' . $user_info->user_registered . '",'; + $data .= '"' . get_user_meta( $user, "wpmem_reg_ip", true ). '"'; + $data .= "\r\n"; /** update the user record as being exported */ - if( $export != 'all' ){ + if ( $export != 'all' ){ update_user_meta( $user, 'exported', 1 ); } } diff --git a/lib/comments_template.php b/lib/comments_template.php new file mode 100644 index 00000000..06b552ad --- /dev/null +++ b/lib/comments_template.php @@ -0,0 +1,7 @@ +'; } -/** End of File **/ + +/** + * Securifies the comments. + * + * If the user is not logged in and the content is blocked + * (i.e. wpmem_block() returns true), function loads a + * dummy/empty comments template. + * + * @since 2.9.9 + * + * @return string $template The location of the comments template. + */ +function wpmem_securify_comments( $template ) { + if ( ! is_user_logged_in() && wpmem_block() ) { + return dirname( __FILE__ ) . '/lib/comments-template.php'; + } + return $template; +} + +/** End of File **/ \ No newline at end of file diff --git a/wp-members-sidebar.php b/wp-members-sidebar.php index a33d76af..177e6fe9 100644 --- a/wp-members-sidebar.php +++ b/wp-members-sidebar.php @@ -298,7 +298,7 @@ function form( $instance )

- +

the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 2.9.8.1 +Version: 2.9.9 Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ /** initial constants **/ -define( 'WPMEM_VERSION', '2.9.8.1' ); +define( 'WPMEM_VERSION', '2.9.9' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); @@ -169,6 +169,7 @@ function wpmem_init() add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu add_action( 'user_register', 'wpmem_wp_reg_finalize' ); // handles wp native registration add_action( 'login_enqueue_scripts', 'wpmem_wplogin_stylesheet' ); // styles the native registration + add_filter( 'comments_template', 'wpmem_securify_comments', 20, 1 ); // securifies the comments add_filter( 'allow_password_reset', 'wpmem_no_reset' ); // no password reset for non-activated users add_filter( 'the_content', 'wpmem_securify', 1, 1 ); // securifies the_content From cff4d4dd3ceedb50560611558373869f999aba1f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 9 Mar 2015 12:01:06 -0500 Subject: [PATCH 0021/1694] updated readme file --- readme.txt | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/readme.txt b/readme.txt index ccbad9c2..4ceb3b7e 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, block, captcha, community, content, login, member, members, members only, membership, memberships, password, permissions, premium content, protect, protect content, register, registration, restrict access, restrict content, restriction, security, signup, subscriber, subscribers, user, users, wordpress members, wordpress membership, wordpress membership plugin Requires at least: 3.1 Tested up to: 4.1 -Stable tag: 2.9.8.1 +Stable tag: 2.9.9 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,8 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 2.9.8.1 corrects a bug created by the inclusion of the new redirect_to parameter in the login page shortcode. If you use this shortcode, you should apply this update. -WP-Members 2.9.8 is mostly minor updates with the exception of a change to the post meta field used for blocking/unblocking individual posts and pages. Be sure to read the release notes prior to updating. +WP-Members 2.9.9 is mostly minor updates preparing codebase for the 3.0 project. == Screenshots == @@ -134,13 +133,17 @@ WP-Members 2.9.8 is mostly minor updates with the exception of a change to the p == Changelog == = 2.9.9 = -* code standards in wp-members-email.php -* rebuilt admin notification email to follow new regular email structure with more filters in wp-members-email.com -* added $toggle to headers filter that is used in both emails so that headers could be filtered based on the email being sent (i.e. sending plain text for admin notification vs html for others. in wp-members-email.php -* added redirect_to parameter as a widget entry in wp-members-sidebar.php -* corrected error checking for adding new fields in /admin/tab-fields.php -* added functions for updating user_status in wp_users table in /admin/users.php -* fixed get_user_meta 'true' error in wp-members-core.php, users.php, /admin/users.php, /admin/user-profile.php +* Code standards in wp-members-email.php +* Rebuilt admin notification email to follow new regular email structure with more filters in wp-members-email.com +* Added $toggle to headers filter that is used in both emails so that headers could be filtered based on the email being sent (i.e. sending plain text for admin notification vs html for others. in wp-members-email.php +* Added redirect_to parameter as a widget entry in wp-members-sidebar.php +* Corrected flaws in error checking for adding new fields in /admin/tab-fields.php +* Added functions for updating user_status in wp_users table in /admin/users.php +* Fixed get_user_meta 'true' error in wp-members-core.php, users.php, /admin/users.php, /admin/user-profile.php +* Added dummy comments template to protect comments without post password. +* Added new action for deactivting a user (opposite of wpmem_user_activated). +* Added check to remove password, confirm_password, and confirm_email from export (data for these was already skipped, but the field space was there). +* Added wpmem_status_msg_args and wpmem_login_links_args filters. = 2.9.8 = * Fixed bug in settings update that caused the stored version number to be erased. From 844fda78c04cdf16cd075b59f2d556ad2a41871c Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 11 Mar 2015 11:26:07 -0500 Subject: [PATCH 0022/1694] fixes to admin email function after 2.9.9 testing --- wp-members-email.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/wp-members-email.php b/wp-members-email.php index b99abfde..1db37c98 100644 --- a/wp-members-email.php +++ b/wp-members-email.php @@ -39,7 +39,9 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, $field_data = null ) { /** - * Determine which email is being sent + * Determine which email is being sent. + * + * Stored option is an array with keys 'body' and 'subj'. */ switch ( $toggle ) { @@ -291,7 +293,7 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { * @param mixed $default_header The email headers (default = null). * @param string $toggle Toggle to determine what email is being generated (newreg|newmod|appmod|repass|admin). */ - $arr['headers'] = apply_filters( 'wpmem_email_headers', $default_header, $toggle ); + $arr['headers'] = apply_filters( 'wpmem_email_headers', $default_header, 'admin' ); /** handle backward compatibility for customizations that may call the email function directly */ if ( ! $wpmem_fields ) { @@ -333,7 +335,7 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { if ( ! $disable ) { /** split field_arr into field_str */ - $fields_str = ''; + $field_str = ''; foreach ( $field_arr as $key => $val ) { $field_str.= $key . ': ' . $val . "\r\n"; } @@ -353,7 +355,7 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { $replace[] = get_user_meta( $user_id, $field[2], true ); } - /* Get the subject, body, and footer shortcodes */ + /** Get the subject, body, and footer shortcodes */ $subj = str_replace( $shortcd, $replace, $subj ); $body = str_replace( $shortcd, $replace, $body ); $foot = ( $add_footer ) ? str_replace( $shortcd, $replace, $foot ) : ''; From 579fa597d3e6f6440ace02a1507effb4096ce3ca Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 17 Mar 2015 16:23:08 -0500 Subject: [PATCH 0023/1694] 2.9.9 rc1 --- readme.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.txt b/readme.txt index 4ceb3b7e..61bc6a99 100644 --- a/readme.txt +++ b/readme.txt @@ -1,6 +1,6 @@ === WP-Members === Contributors: cbutlerjr -Tags: access, authentication, block, captcha, community, content, login, member, members, members only, membership, memberships, password, permissions, premium content, protect, protect content, register, registration, restrict access, restrict content, restriction, security, signup, subscriber, subscribers, user, users, wordpress members, wordpress membership, wordpress membership plugin +Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 Tested up to: 4.1 Stable tag: 2.9.9 From 5780de9bfbf61ee21a4d0815e9628522df685543 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 19 Mar 2015 13:36:28 -0500 Subject: [PATCH 0024/1694] fixes for really simple captcha --- forms.php | 6 +++--- readme.txt | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/forms.php b/forms.php index 7f4ef675..30ea95de 100644 --- a/forms.php +++ b/forms.php @@ -736,7 +736,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) // if captcha is Really Simple CAPTCHA - if( WPMEM_CAPTCHA == 2 ) { + if( WPMEM_CAPTCHA == 2 && $toggle != 'edit' ) { $row = wpmem_build_rs_captcha(); $rows['captcha'] = array( 'order' => '', @@ -745,9 +745,9 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) 'value' => '', 'row_before' => $row_before, 'label' => $row['label'], - 'field_before' => $field_before, + 'field_before' => ( $wrap_inputs ) ? '
' : '', 'field' => $row['field'], - 'field_after' => $field_after, + 'field_after' => ( $wrap_inputs ) ? '
' : '', 'row_after' => $row_after ); } diff --git a/readme.txt b/readme.txt index 61bc6a99..11ad2c90 100644 --- a/readme.txt +++ b/readme.txt @@ -144,6 +144,7 @@ WP-Members 2.9.9 is mostly minor updates preparing codebase for the 3.0 project. * Added new action for deactivting a user (opposite of wpmem_user_activated). * Added check to remove password, confirm_password, and confirm_email from export (data for these was already skipped, but the field space was there). * Added wpmem_status_msg_args and wpmem_login_links_args filters. +* Corrected Really Simple Captcha, added field wrapper and should not display on user profile edit. = 2.9.8 = * Fixed bug in settings update that caused the stored version number to be erased. From e9a330bfb59ca7da38cf355e017cf04f7d4cdf73 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 19 Mar 2015 16:30:43 -0500 Subject: [PATCH 0025/1694] 2.9.9 rc2 --- admin/admin.php | 14 +++++++++-- admin/post.php | 32 ++++++++++++++--------- admin/user-profile.php | 28 ++++++++++++++++----- admin/users.php | 17 +++++++++++-- wp-members-core.php | 17 +++++++------ wp-members-register.php | 56 ++++++++++++++++++++++++++++++++--------- wp-members.php | 8 +++--- 7 files changed, 127 insertions(+), 45 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index a84313b1..dd2c6641 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -111,8 +111,6 @@ function wpmem_add_captcha_tab( $tabs ) { * Primary admin function * * @since 2.1 - * - * @uses do_action wpmem_admin_do_tab */ function wpmem_admin() { @@ -134,6 +132,18 @@ function wpmem_admin() wpmem_a_do_warnings( $did_update, $wpmem_settings ); + /** + * Fires at the end of creating an admin panel tab. + * + * This action is part of the plugin's admin panel API for adding + * additional admin tabs. This action is for adding content for + * a custom tab. + * + * @since 2.8 + * + * @param string $tab The tab being generated. + * @param array $wpmem_settings The plugin settings. + */ do_action( 'wpmem_admin_do_tab', $tab, $wpmem_settings ); ?> - - + $user_ID, 'user_pass' => $pass1 ) ); /** - * Password change action + * Fires after password change. * * @since 2.9.0 * - * @param int $user_ID The user's numeric ID + * @param int $user_ID The user's numeric ID. */ do_action( 'wpmem_pwd_change', $user_ID ); @@ -857,11 +860,11 @@ function wpmem_reset_password() wpmem_inc_regemail( $user->ID, $new_pass, 3 ); /** - * Password reset action + * Fires after password reset. * * @since 2.9.0 * - * @param int $user_ID The user's numeric ID + * @param int $user_ID The user's numeric ID. */ do_action( 'wpmem_pwd_reset', $user->ID ); diff --git a/wp-members-register.php b/wp-members-register.php index c6986bf2..bde97ce3 100644 --- a/wp-members-register.php +++ b/wp-members-register.php @@ -28,12 +28,6 @@ * * @since 2.2.1 * - * @uses do_action Calls 'wpmem_pre_register_data' action - * @uses do_action Calls 'wpmem_post_register_data' action - * @uses do_action Calls 'wpmem_register_redirect' action - * @uses do_action Calls 'wpmem_pre_update_data' action - * @uses do_action Calls 'wpmem_post_update_data' action - * * @param string $toggle toggles the function between 'register' and 'update'. * @global int $user_ID * @global string $wpmem_themsg @@ -209,7 +203,18 @@ function wpmem_registration( $toggle ) */ $fields = apply_filters( 'wpmem_register_data', $fields ); - // _data hook is before any insertion/emails + /** + * Fires before any insertion/emails. + * + * This action is the final step in pre registering a user. This + * can be used for attaching custom validation to the registration + * process. It cannot be used for changing any user registration + * data. Use the wpmem_register_data filter for that. + * + * @since 2.7.2 + * + * @param array $fields The user's submitted registration data. + */ do_action( 'wpmem_pre_register_data', $fields ); // if the _pre_register_data hook sends back an error message @@ -261,8 +266,14 @@ function wpmem_registration( $toggle ) // set user expiration, if used if( WPMEM_USE_EXP == 1 && WPMEM_MOD_REG != 1 ) { wpmem_set_exp( $fields['ID'] ); } - - // _data hook after insertion but before email + + /** + * Fires after user insertion but before email. + * + * @since 2.7.2 + * + * @param array $fields The user's submitted registration data. + */ do_action( 'wpmem_post_register_data', $fields ); require_once( 'wp-members-email.php' ); @@ -274,7 +285,11 @@ function wpmem_registration( $toggle ) // notify admin of new reg, if needed; if( WPMEM_NOTIFY_ADMIN == 1 ) { wpmem_notify_admin( $fields['ID'], $wpmem_fields ); } - // add action for redirection + /** + * Fires after registration is complete. + * + * @since 2.7.1 + */ do_action( 'wpmem_register_redirect' ); // successful registration message @@ -308,7 +323,18 @@ function wpmem_registration( $toggle ) */ $fields = apply_filters( 'wpmem_register_data', $fields ); - // _pre_update_data hook is before data insertion + /** + * Fires before data insertion. + * + * This action is the final step in pre updating a user. This + * can be used for attaching custom validation to the update + * process. It cannot be used for changing any user update + * data. Use the wpmem_register_data filter for that. + * + * @since 2.7.2 + * + * @param array $fields The user's submitted update data. + */ do_action( 'wpmem_pre_update_data', $fields ); // if the _pre_update_data hook sends back an error message @@ -361,7 +387,13 @@ function wpmem_registration( $toggle ) // update wp_update_user fields wp_update_user( $native_update ); - // _post_update_data hook is after insertion + /** + * Fires at the end of user update data insertion. + * + * @since 2.7.2 + * + * @param array $fields The user's submitted registration data. + */ do_action( 'wpmem_post_update_data', $fields ); return "editsuccess"; exit(); diff --git a/wp-members.php b/wp-members.php index ffc8bdec..cc80c67c 100644 --- a/wp-members.php +++ b/wp-members.php @@ -85,7 +85,7 @@ function wpmem_init() { /** - * Action for pre-initialization of plugin options. + * Fires before initialization of plugin options. * * @since 2.9.0 */ @@ -201,7 +201,7 @@ function wpmem_init() } /** - * Action at the end of initialization of plugin options. + * Fires after initialization of plugin options. * * @since 2.9.0 */ @@ -220,7 +220,7 @@ function wpmem_init() function wpmem_chk_admin() { /** - * Action for initialization of admin options. + * Fires before initialization of admin options. * * @since 2.9.0 */ @@ -260,7 +260,7 @@ function wpmem_chk_admin() } /** - * Action at the end of admin options. + * Fires after initialization of admin options. * * @since 2.9.0 */ From e13cb03a92ff096efa0dee6636a6142ca4d06dcc Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 20 Mar 2015 11:42:26 -0500 Subject: [PATCH 0026/1694] fix for empty user id in fields shortcode --- wp-members-core.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-members-core.php b/wp-members-core.php index ce7541cd..e356823f 100644 --- a/wp-members-core.php +++ b/wp-members-core.php @@ -542,7 +542,7 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) } $user_info = get_userdata( $the_user_ID ); - if( $underscores == 'off' ) { + if( $underscores == 'off' && $user_info ) { $user_info->$field = str_replace( '_', ' ', $user_info->$field ); } From 11a33e75a7b1cbcf7dcc65c8addc2aa38dbcd34b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 21 Mar 2015 17:51:52 -0500 Subject: [PATCH 0027/1694] added option and selection for a specific login page --- admin/tab-options.php | 664 ++++++++++++++++---------------- js/admin.js | 874 +++++++++++++++++++++--------------------- uninstall.php | 161 ++++---- wp-members.php | 673 ++++++++++++++++---------------- 4 files changed, 1201 insertions(+), 1171 deletions(-) diff --git a/admin/tab-options.php b/admin/tab-options.php index 67e1e5db..91aa4a8e 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -1,324 +1,342 @@ -', '', '', '' ), 'wp-members' ); - $help_link = __( sprintf( 'See the %sUsers Guide on plugin options%s.', '', '' ), 'wp-members' ); - ?> -
- -
- -
-

-
- -
-
- -
- -
-
-
-

-
-
- -
    - 9 ) || ( WPMEM_EXP_MODULE == true ) ) { ?> -
  • - - - />   - -
  • - - -
  • - - />   - -
  • - -
  • - - />      . -
  • -
  • - - -
  • -

    - -
  • - -  
    -
    - - -
    -
  • - -
  • - -  
    -
    - - -
    -
  • - -

    -
  • - - -
  • - -
    -
  • - - -
  • -
    -

    - - -
-
-
-
-
-
-
- '; - } - - /* - if we are setting registration to be moderated, - check to see if the current admin has been - activated so they don't accidentally lock themselves - out later - */ - if( $row == 5 ) { - if( isset( $_POST[$post_arr[$row]] ) == 1) { - global $current_user; - get_currentuserinfo(); - $user_ID = $current_user->ID; - update_user_meta( $user_ID, 'active', 1 ); - } - } - } - - $wpmem_attribution = ( isset( $_POST['attribution'] ) ) ? 1 : 0; - update_option( 'wpmembers_attrib', $wpmem_attribution ); - - $wpmem_settings_msurl = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? $_POST['wpmem_settings_msurl'] : ''; - $wpmem_settings_mspage = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_mspage']; - if( $wpmem_settings_mspage ) { update_option( 'wpmembers_msurl', $wpmem_settings_mspage ); } - if( $wpmem_settings_msurl != wpmem_use_ssl() && $wpmem_settings_msurl != 'use_custom' && ! $wpmem_settings_mspage ) { - update_option( 'wpmembers_msurl', trim( $wpmem_settings_msurl ) ); - } - - $wpmem_settings_regurl = ( $_POST['wpmem_settings_regpage'] == 'use_custom' ) ? $_POST['wpmem_settings_regurl'] : ''; - $wpmem_settings_regpage = ( $_POST['wpmem_settings_regpage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_regpage']; - if( $wpmem_settings_regpage ) { update_option( 'wpmembers_regurl', $wpmem_settings_regpage ); } - if( $wpmem_settings_regurl != wpmem_use_ssl() && $wpmem_settings_regurl != 'use_custom' && ! $wpmem_settings_regpage ) { - update_option( 'wpmembers_regurl', trim( $wpmem_settings_regurl ) ); - } - - - $wpmem_settings_cssurl = $_POST['wpmem_settings_cssurl']; - if( $wpmem_settings_cssurl != wpmem_use_ssl() ) { - update_option( 'wpmembers_cssurl', trim( $wpmem_settings_cssurl ) ); - } - - $wpmem_settings_style = ( isset( $_POST['wpmem_settings_style'] ) ) ? $_POST['wpmem_settings_style'] : false; - update_option( 'wpmembers_style', $wpmem_settings_style, false ); - - $wpmem_autoex = array ( - 'auto_ex' => isset( $_POST['wpmem_autoex'] ) ? $_POST['wpmem_autoex'] : 0, - 'auto_ex_len' => isset( $_POST['wpmem_autoex_len'] ) ? $_POST['wpmem_autoex_len'] : '' - ); - update_option( 'wpmembers_autoex', $wpmem_autoex, false ); - - update_option( 'wpmembers_settings', $wpmem_newsettings ); - $wpmem_settings = $wpmem_newsettings; - - - return __( 'WP-Members settings were updated', 'wp-members' ); -} - - -/** - * Create the stylesheet dropdown selection - * - * @since 2.8 - */ -function wpmem_admin_style_list() -{ - $val = get_option( 'wpmembers_style', null ); - $list = array( - 'No Float' => WPMEM_DIR . 'css/generic-no-float.css', - 'Rigid' => WPMEM_DIR . 'css/generic-rigid.css', - 'Twenty Fifteen' => WPMEM_DIR . 'css/wp-members-2015.css', - 'Twenty Fifteen - no float' => WPMEM_DIR . 'css/wp-members-2015-no-float.css', - 'Twenty Fourteen' => WPMEM_DIR . 'css/wp-members-2014.css', - 'Twenty Fourteen - no float' => WPMEM_DIR . 'css/wp-members-2014-no-float.css', - 'Twenty Thirteen' => WPMEM_DIR . 'css/wp-members-2013.css', - 'Twenty Twelve' => WPMEM_DIR . 'css/wp-members-2012.css', - 'Twenty Eleven' => WPMEM_DIR . 'css/wp-members-2011.css', - 'Twenty Ten' => WPMEM_DIR . 'css/wp-members.css', - 'Kubrick' => WPMEM_DIR . 'css/wp-members-kubrick.css', - ); - - /** - * Filters the list of stylesheets in the plugin options dropdown. - * - * @since 2.8.0 - * - * @param array $list An array of stylesheets that can be applied to the plugin's forms. - */ - $list = apply_filters( 'wpmem_admin_style_list', $list ); - - $selected = false; - foreach( $list as $name => $location ) { - $selected = ( $location == $val ) ? true : $selected; - echo '\n"; - } - $selected = ( ! $selected ) ? ' selected' : ''; - echo ''; - - return; -} - - -/** - * Create a dropdown selection of pages - * - * @since 2.8.1 - * - * @param string $val - */ -function wpmem_admin_page_list( $val, $show_custom_url = true ) -{ - $selected = ( $val == 'http://' ) ? 'select a page' : false; - $pages = get_pages(); - - echo ''; - - foreach ( $pages as $page ) { - $selected = ( get_page_link( $page->ID ) == $val ) ? true : $selected; - $option = ''; - echo $option; - } - if( $show_custom_url ) { - $selected = ( ! $selected ) ? ' selected' : ''; - echo ''; - } -} - +', '', '', '' ), 'wp-members' ); + $help_link = __( sprintf( 'See the %sUsers Guide on plugin options%s.', '', '' ), 'wp-members' ); + ?> +
+ +
+ +
+

+
+ +
+
+ +
+ +
+
+
+

+
+
+ +
    + 9 ) || ( WPMEM_EXP_MODULE == true ) ) { ?> +
  • + + + />   + +
  • + + +
  • + + />   + +
  • + +
  • + + />      . +
  • +
  • + + +
  • +

    + +
  • + +  
    +
    + + +
    +
  • + +
  • + +  
    +
    + + +
    +
  • + +
  • + +  
    +
    + + +
    +
  • + +

    +
  • + + +
  • + +
    +
  • + + +
  • +
    +

    + + +
+
+
+
+
+
+
+ '; + } + + /* + if we are setting registration to be moderated, + check to see if the current admin has been + activated so they don't accidentally lock themselves + out later + */ + if( $row == 5 ) { + if( isset( $_POST[$post_arr[$row]] ) == 1) { + global $current_user; + get_currentuserinfo(); + $user_ID = $current_user->ID; + update_user_meta( $user_ID, 'active', 1 ); + } + } + } + + $wpmem_attribution = ( isset( $_POST['attribution'] ) ) ? 1 : 0; + update_option( 'wpmembers_attrib', $wpmem_attribution ); + + $wpmem_settings_msurl = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? $_POST['wpmem_settings_msurl'] : ''; + $wpmem_settings_mspage = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_mspage']; + if( $wpmem_settings_mspage ) { update_option( 'wpmembers_msurl', $wpmem_settings_mspage ); } + if( $wpmem_settings_msurl != wpmem_use_ssl() && $wpmem_settings_msurl != 'use_custom' && ! $wpmem_settings_mspage ) { + update_option( 'wpmembers_msurl', trim( $wpmem_settings_msurl ) ); + } + + $wpmem_settings_regurl = ( $_POST['wpmem_settings_regpage'] == 'use_custom' ) ? $_POST['wpmem_settings_regurl'] : ''; + $wpmem_settings_regpage = ( $_POST['wpmem_settings_regpage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_regpage']; + if( $wpmem_settings_regpage ) { update_option( 'wpmembers_regurl', $wpmem_settings_regpage ); } + if( $wpmem_settings_regurl != wpmem_use_ssl() && $wpmem_settings_regurl != 'use_custom' && ! $wpmem_settings_regpage ) { + update_option( 'wpmembers_regurl', trim( $wpmem_settings_regurl ) ); + } + + $wpmem_settings_logurl = ( $_POST['wpmem_settings_logpage'] == 'use_custom' ) ? $_POST['wpmem_settings_logurl'] : ''; + $wpmem_settings_logpage = ( $_POST['wpmem_settings_logpage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_logpage']; + if( $wpmem_settings_logpage ) { update_option( 'wpmembers_logurl', $wpmem_settings_logpage ); } + if( $wpmem_settings_logurl != wpmem_use_ssl() && $wpmem_settings_logurl != 'use_custom' && ! $wpmem_settings_logpage ) { + update_option( 'wpmembers_logurl', trim( $wpmem_settings_logurl ) ); + } + + $wpmem_settings_cssurl = $_POST['wpmem_settings_cssurl']; + if( $wpmem_settings_cssurl != wpmem_use_ssl() ) { + update_option( 'wpmembers_cssurl', trim( $wpmem_settings_cssurl ) ); + } + + $wpmem_settings_style = ( isset( $_POST['wpmem_settings_style'] ) ) ? $_POST['wpmem_settings_style'] : false; + update_option( 'wpmembers_style', $wpmem_settings_style, false ); + + $wpmem_autoex = array ( + 'auto_ex' => isset( $_POST['wpmem_autoex'] ) ? $_POST['wpmem_autoex'] : 0, + 'auto_ex_len' => isset( $_POST['wpmem_autoex_len'] ) ? $_POST['wpmem_autoex_len'] : '' + ); + update_option( 'wpmembers_autoex', $wpmem_autoex, false ); + + update_option( 'wpmembers_settings', $wpmem_newsettings ); + $wpmem_settings = $wpmem_newsettings; + + + return __( 'WP-Members settings were updated', 'wp-members' ); +} + + +/** + * Create the stylesheet dropdown selection + * + * @since 2.8 + */ +function wpmem_admin_style_list() +{ + $val = get_option( 'wpmembers_style', null ); + $list = array( + 'No Float' => WPMEM_DIR . 'css/generic-no-float.css', + 'Rigid' => WPMEM_DIR . 'css/generic-rigid.css', + 'Twenty Fifteen' => WPMEM_DIR . 'css/wp-members-2015.css', + 'Twenty Fifteen - no float' => WPMEM_DIR . 'css/wp-members-2015-no-float.css', + 'Twenty Fourteen' => WPMEM_DIR . 'css/wp-members-2014.css', + 'Twenty Fourteen - no float' => WPMEM_DIR . 'css/wp-members-2014-no-float.css', + 'Twenty Thirteen' => WPMEM_DIR . 'css/wp-members-2013.css', + 'Twenty Twelve' => WPMEM_DIR . 'css/wp-members-2012.css', + 'Twenty Eleven' => WPMEM_DIR . 'css/wp-members-2011.css', + 'Twenty Ten' => WPMEM_DIR . 'css/wp-members.css', + 'Kubrick' => WPMEM_DIR . 'css/wp-members-kubrick.css', + ); + + /** + * Filters the list of stylesheets in the plugin options dropdown. + * + * @since 2.8.0 + * + * @param array $list An array of stylesheets that can be applied to the plugin's forms. + */ + $list = apply_filters( 'wpmem_admin_style_list', $list ); + + $selected = false; + foreach( $list as $name => $location ) { + $selected = ( $location == $val ) ? true : $selected; + echo '\n"; + } + $selected = ( ! $selected ) ? ' selected' : ''; + echo ''; + + return; +} + + +/** + * Create a dropdown selection of pages + * + * @since 2.8.1 + * + * @param string $val + */ +function wpmem_admin_page_list( $val, $show_custom_url = true ) +{ + $selected = ( $val == 'http://' ) ? 'select a page' : false; + $pages = get_pages(); + + echo ''; + + foreach ( $pages as $page ) { + $selected = ( get_page_link( $page->ID ) == $val ) ? true : $selected; + $option = ''; + echo $option; + } + if( $show_custom_url ) { + $selected = ( ! $selected ) ? ' selected' : ''; + echo ''; + } +} + /** End of File **/ \ No newline at end of file diff --git a/js/admin.js b/js/admin.js index 32e434b8..0d44f3c7 100644 --- a/js/admin.js +++ b/js/admin.js @@ -1,432 +1,442 @@ -/** - * WP-Members Admin JavaScript Functions - * - * Contains the JavaScript functions for WP-Members admin. - * - * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2015 Chad Butler - * WP-Members(tm) is a trademark of butlerblog.com - * - * TableDnD plugin for jQuery : - * Copyright (c) Denis Howlett - * Licensed like jQuery, see http://docs.jquery.com/License. - * - * table.add.row plugin for jQuery : - * Copyright (c) C.F.Wong - * Licensed under the MIT License: http://www.opensource.org/licenses/mit-license.php - * - * @package WordPress - * @subpackage WP-Members - * @author Chad Butler - * @copyright 2006-2015 - */ - - -/** - * JS for field table DnD - * - * @since 2.6 - */ -(function($) { - $(document).ready(function() { - - $("#wpmem-fields").tableDnD({ - onDragClass: "wpmem_tbl_drag", - - onDrop: function(table, row) { - var data = { - action: 'wpmem_a_field_reorder', - orderstring: $.tableDnD.serialize() - } - - $.post( ajaxurl, data, function(response) { - // alert(response); - }) - } - }); - }); -})(jQuery); - - -/** - * TableDnD plug-in for JQuery, allows you to drag and drop table rows - * You can set up various options to control how the system will work - * Copyright (c) Denis Howlett - * Licensed like jQuery, see http://docs.jquery.com/License. - */ -jQuery.tableDnD = { - /** Keep hold of the current table being dragged */ - currentTable : null, - /** Keep hold of the current drag object if any */ - dragObject: null, - /** The current mouse offset */ - mouseOffset: null, - /** Remember the old value of Y so that we don't do too much processing */ - oldY: 0, - - /** Actually build the structure */ - build: function(options) { - // Set up the defaults if any - - this.each(function() { - // This is bound to each matching table, set up the defaults and override with user options - this.tableDnDConfig = jQuery.extend({ - onDragStyle: null, - onDropStyle: null, - // Add in the default class for whileDragging - onDragClass: "tDnD_whileDrag", - onDrop: null, - onDragStart: null, - scrollAmount: 5, - serializeRegexp: /[^\-]*$/, // The regular expression to use to trim row IDs - serializeParamName: null, // If you want to specify another parameter name instead of the table ID - dragHandle: null // If you give the name of a class here, then only Cells with this class will be draggable - }, options || {}); - // Now make the rows draggable - jQuery.tableDnD.makeDraggable(this); - }); - - // Now we need to capture the mouse up and mouse move event - // We can use bind so that we don't interfere with other event handlers - jQuery(document) - .bind('mousemove', jQuery.tableDnD.mousemove) - .bind('mouseup', jQuery.tableDnD.mouseup); - - // Don't break the chain - return this; - }, - - /** This function makes all the rows on the table draggable apart from those marked as "NoDrag" */ - makeDraggable: function(table) { - var config = table.tableDnDConfig; - if (table.tableDnDConfig.dragHandle) { - // We only need to add the event to the specified cells - var cells = jQuery("td."+table.tableDnDConfig.dragHandle, table); - cells.each(function() { - // The cell is bound to "this" - jQuery(this).mousedown(function(ev) { - jQuery.tableDnD.dragObject = this.parentNode; - jQuery.tableDnD.currentTable = table; - jQuery.tableDnD.mouseOffset = jQuery.tableDnD.getMouseOffset(this, ev); - if (config.onDragStart) { - // Call the onDrop method if there is one - config.onDragStart(table, this); - } - return false; - }); - }) - } else { - // For backwards compatibility, we add the event to the whole row - var rows = jQuery("tr", table); // get all the rows as a wrapped set - rows.each(function() { - // Iterate through each row, the row is bound to "this" - var row = jQuery(this); - if (! row.hasClass("nodrag")) { - row.mousedown(function(ev) { - if (ev.target.tagName == "TD") { - jQuery.tableDnD.dragObject = this; - jQuery.tableDnD.currentTable = table; - jQuery.tableDnD.mouseOffset = jQuery.tableDnD.getMouseOffset(this, ev); - if (config.onDragStart) { - // Call the onDrop method if there is one - config.onDragStart(table, this); - } - return false; - } - }).css("cursor", "move"); // Store the tableDnD object - } - }); - } - }, - - updateTables: function() { - this.each(function() { - // this is now bound to each matching table - if (this.tableDnDConfig) { - jQuery.tableDnD.makeDraggable(this); - } - }) - }, - - /** Get the mouse coordinates from the event (allowing for browser differences) */ - mouseCoords: function(ev){ - if(ev.pageX || ev.pageY){ - return {x:ev.pageX, y:ev.pageY}; - } - return { - x:ev.clientX + document.body.scrollLeft - document.body.clientLeft, - y:ev.clientY + document.body.scrollTop - document.body.clientTop - }; - }, - - /** Given a target element and a mouse event, get the mouse offset from that element. - To do this we need the element's position and the mouse position */ - getMouseOffset: function(target, ev) { - ev = ev || window.event; - - var docPos = this.getPosition(target); - var mousePos = this.mouseCoords(ev); - return {x:mousePos.x - docPos.x, y:mousePos.y - docPos.y}; - }, - - /** Get the position of an element by going up the DOM tree and adding up all the offsets */ - getPosition: function(e){ - var left = 0; - var top = 0; - /** Safari fix -- thanks to Luis Chato for this! */ - if (e.offsetHeight == 0) { - /** Safari 2 doesn't correctly grab the offsetTop of a table row - this is detailed here: - http://jacob.peargrove.com/blog/2006/technical/table-row-offsettop-bug-in-safari/ - the solution is likewise noted there, grab the offset of a table cell in the row - the firstChild. - note that firefox will return a text node as a first child, so designing a more thorough - solution may need to take that into account, for now this seems to work in firefox, safari, ie */ - e = e.firstChild; // a table cell - } - - while (e.offsetParent){ - left += e.offsetLeft; - top += e.offsetTop; - e = e.offsetParent; - } - - left += e.offsetLeft; - top += e.offsetTop; - - return {x:left, y:top}; - }, - - mousemove: function(ev) { - if (jQuery.tableDnD.dragObject == null) { - return; - } - - var dragObj = jQuery(jQuery.tableDnD.dragObject); - var config = jQuery.tableDnD.currentTable.tableDnDConfig; - var mousePos = jQuery.tableDnD.mouseCoords(ev); - var y = mousePos.y - jQuery.tableDnD.mouseOffset.y; - //auto scroll the window - var yOffset = window.pageYOffset; - if (document.all) { - // Windows version - //yOffset=document.body.scrollTop; - if (typeof document.compatMode != 'undefined' && - document.compatMode != 'BackCompat') { - yOffset = document.documentElement.scrollTop; - } - else if (typeof document.body != 'undefined') { - yOffset=document.body.scrollTop; - } - - } - - if (mousePos.y-yOffset < config.scrollAmount) { - window.scrollBy(0, -config.scrollAmount); - } else { - var windowHeight = window.innerHeight ? window.innerHeight - : document.documentElement.clientHeight ? document.documentElement.clientHeight : document.body.clientHeight; - if (windowHeight-(mousePos.y-yOffset) < config.scrollAmount) { - window.scrollBy(0, config.scrollAmount); - } - } - - - if (y != jQuery.tableDnD.oldY) { - // work out if we're going up or down... - var movingDown = y > jQuery.tableDnD.oldY; - // update the old value - jQuery.tableDnD.oldY = y; - // update the style to show we're dragging - if (config.onDragClass) { - dragObj.addClass(config.onDragClass); - } else { - dragObj.css(config.onDragStyle); - } - // If we're over a row then move the dragged row to there so that the user sees the - // effect dynamically - var currentRow = jQuery.tableDnD.findDropTargetRow(dragObj, y); - if (currentRow) { - // TODO worry about what happens when there are multiple TBODIES - if (movingDown && jQuery.tableDnD.dragObject != currentRow) { - jQuery.tableDnD.dragObject.parentNode.insertBefore(jQuery.tableDnD.dragObject, currentRow.nextSibling); - } else if (! movingDown && jQuery.tableDnD.dragObject != currentRow) { - jQuery.tableDnD.dragObject.parentNode.insertBefore(jQuery.tableDnD.dragObject, currentRow); - } - } - } - - return false; - }, - - /** We're only worried about the y position really, because we can only move rows up and down */ - findDropTargetRow: function(draggedRow, y) { - var rows = jQuery.tableDnD.currentTable.rows; - for (var i=0; i rowY - rowHeight) && (y < (rowY + rowHeight))) { - // that's the row we're over - // If it's the same as the current row, ignore it - if (row == draggedRow) {return null;} - var config = jQuery.tableDnD.currentTable.tableDnDConfig; - if (config.onAllowDrop) { - if (config.onAllowDrop(draggedRow, row)) { - return row; - } else { - return null; - } - } else { - // If a row has nodrop class, then don't allow dropping (inspired by John Tarr and Famic) - var nodrop = jQuery(row).hasClass("nodrop"); - if (! nodrop) { - return row; - } else { - return null; - } - } - return row; - } - } - return null; - }, - - mouseup: function(e) { - if (jQuery.tableDnD.currentTable && jQuery.tableDnD.dragObject) { - var droppedRow = jQuery.tableDnD.dragObject; - var config = jQuery.tableDnD.currentTable.tableDnDConfig; - // If we have a dragObject, then we need to release it, - // The row will already have been moved to the right place so we just reset stuff - if (config.onDragClass) { - jQuery(droppedRow).removeClass(config.onDragClass); - } else { - jQuery(droppedRow).css(config.onDropStyle); - } - jQuery.tableDnD.dragObject = null; - if (config.onDrop) { - // Call the onDrop method if there is one - config.onDrop(jQuery.tableDnD.currentTable, droppedRow); - } - jQuery.tableDnD.currentTable = null; // let go of the table too - } - }, - - serialize: function() { - if (jQuery.tableDnD.currentTable) { - return jQuery.tableDnD.serializeTable(jQuery.tableDnD.currentTable); - } else { - return "Error: No Table id set, you need to set an id on your table and every row"; - } - }, - - serializeTable: function(table) { - var result = ""; - var tableId = table.id; - var rows = table.rows; - for (var i=0; i 0) result += "&"; - var rowId = rows[i].id; - if (rowId && rowId && table.tableDnDConfig && table.tableDnDConfig.serializeRegexp) { - rowId = rowId.match(table.tableDnDConfig.serializeRegexp)[0]; - } - - result += tableId + '[]=' + rowId; - } - return result; - }, - - serializeTables: function() { - var result = ""; - this.each(function() { - // this is now bound to each matching table - result += jQuery.tableDnD.serializeTable(this); - }); - return result; - } - -} - -jQuery.fn.extend( - { - tableDnD : jQuery.tableDnD.build, - tableDnDUpdate : jQuery.tableDnD.updateTables, - tableDnDSerialize: jQuery.tableDnD.serializeTables - } -); - -/** END TableDnD plugin */ - - -/** - * JS for displaying custom url for: - * * Profile page - * * Register page - * * Custom stylesheet - * - * @since 2.9.6 - */ -(function($) { - $(document).ready(function() { - if ($("#wpmem_mspage_select").val() == 'use_custom') - $("#wpmem_mspage_custom").show(); - else - $("#wpmem_mspage_custom").hide(); - if ($("#wpmem_regpage_select").val() == 'use_custom') - $("#wpmem_regpage_custom").show(); - else - $("#wpmem_regpage_custom").hide(); - if ($("#wpmem_stylesheet_select").val() == 'use_custom') - $("#wpmem_stylesheet_custom").show(); - else - $("#wpmem_stylesheet_custom").hide(); - $("#wpmem_mspage_select").change(function() { - if ($("#wpmem_mspage_select").val() == 'use_custom') - $("#wpmem_mspage_custom").show(); - else - $("#wpmem_mspage_custom").hide(); - }); - $("#wpmem_regpage_select").change(function() { - if ($("#wpmem_regpage_select").val() == 'use_custom') - $("#wpmem_regpage_custom").show(); - else - $("#wpmem_regpage_custom").hide(); - }); - $("#wpmem_stylesheet_select").change(function() { - if ($("#wpmem_stylesheet_select").val() == 'use_custom') - $("#wpmem_stylesheet_custom").show(); - else - $("#wpmem_stylesheet_custom").hide(); - }); - }); -})(jQuery); - - -/** - * JS for displaying additional info for checkbox/dropdowns - * - * @since 2.9.6 - */ -(function($) { - $(document).ready(function() { - $("#wpmem_checkbox_info").hide(); - $("#wpmem_dropdown_info").hide(); - }); - $(document).ready(function() { - $("#wpmem_field_type_select").change(function() { - if ($("#wpmem_field_type_select").val() == 'checkbox') - $("#wpmem_checkbox_info").show(); - else - $("#wpmem_checkbox_info").hide(); - if ($("#wpmem_field_type_select").val() == 'select') - $("#wpmem_dropdown_info").show(); - else - $("#wpmem_dropdown_info").hide(); - }); - }); -})(jQuery); +/** + * WP-Members Admin JavaScript Functions + * + * Contains the JavaScript functions for WP-Members admin. + * + * This file is part of the WP-Members plugin by Chad Butler + * You can find out more about this plugin at http://rocketgeek.com + * Copyright (c) 2006-2015 Chad Butler + * WP-Members(tm) is a trademark of butlerblog.com + * + * TableDnD plugin for jQuery : + * Copyright (c) Denis Howlett + * Licensed like jQuery, see http://docs.jquery.com/License. + * + * table.add.row plugin for jQuery : + * Copyright (c) C.F.Wong + * Licensed under the MIT License: http://www.opensource.org/licenses/mit-license.php + * + * @package WordPress + * @subpackage WP-Members + * @author Chad Butler + * @copyright 2006-2015 + */ + + +/** + * JS for field table DnD + * + * @since 2.6 + */ +(function($) { + $(document).ready(function() { + + $("#wpmem-fields").tableDnD({ + onDragClass: "wpmem_tbl_drag", + + onDrop: function(table, row) { + var data = { + action: 'wpmem_a_field_reorder', + orderstring: $.tableDnD.serialize() + } + + $.post( ajaxurl, data, function(response) { + // alert(response); + }) + } + }); + }); +})(jQuery); + + +/** + * TableDnD plug-in for JQuery, allows you to drag and drop table rows + * You can set up various options to control how the system will work + * Copyright (c) Denis Howlett + * Licensed like jQuery, see http://docs.jquery.com/License. + */ +jQuery.tableDnD = { + /** Keep hold of the current table being dragged */ + currentTable : null, + /** Keep hold of the current drag object if any */ + dragObject: null, + /** The current mouse offset */ + mouseOffset: null, + /** Remember the old value of Y so that we don't do too much processing */ + oldY: 0, + + /** Actually build the structure */ + build: function(options) { + // Set up the defaults if any + + this.each(function() { + // This is bound to each matching table, set up the defaults and override with user options + this.tableDnDConfig = jQuery.extend({ + onDragStyle: null, + onDropStyle: null, + // Add in the default class for whileDragging + onDragClass: "tDnD_whileDrag", + onDrop: null, + onDragStart: null, + scrollAmount: 5, + serializeRegexp: /[^\-]*$/, // The regular expression to use to trim row IDs + serializeParamName: null, // If you want to specify another parameter name instead of the table ID + dragHandle: null // If you give the name of a class here, then only Cells with this class will be draggable + }, options || {}); + // Now make the rows draggable + jQuery.tableDnD.makeDraggable(this); + }); + + // Now we need to capture the mouse up and mouse move event + // We can use bind so that we don't interfere with other event handlers + jQuery(document) + .bind('mousemove', jQuery.tableDnD.mousemove) + .bind('mouseup', jQuery.tableDnD.mouseup); + + // Don't break the chain + return this; + }, + + /** This function makes all the rows on the table draggable apart from those marked as "NoDrag" */ + makeDraggable: function(table) { + var config = table.tableDnDConfig; + if (table.tableDnDConfig.dragHandle) { + // We only need to add the event to the specified cells + var cells = jQuery("td."+table.tableDnDConfig.dragHandle, table); + cells.each(function() { + // The cell is bound to "this" + jQuery(this).mousedown(function(ev) { + jQuery.tableDnD.dragObject = this.parentNode; + jQuery.tableDnD.currentTable = table; + jQuery.tableDnD.mouseOffset = jQuery.tableDnD.getMouseOffset(this, ev); + if (config.onDragStart) { + // Call the onDrop method if there is one + config.onDragStart(table, this); + } + return false; + }); + }) + } else { + // For backwards compatibility, we add the event to the whole row + var rows = jQuery("tr", table); // get all the rows as a wrapped set + rows.each(function() { + // Iterate through each row, the row is bound to "this" + var row = jQuery(this); + if (! row.hasClass("nodrag")) { + row.mousedown(function(ev) { + if (ev.target.tagName == "TD") { + jQuery.tableDnD.dragObject = this; + jQuery.tableDnD.currentTable = table; + jQuery.tableDnD.mouseOffset = jQuery.tableDnD.getMouseOffset(this, ev); + if (config.onDragStart) { + // Call the onDrop method if there is one + config.onDragStart(table, this); + } + return false; + } + }).css("cursor", "move"); // Store the tableDnD object + } + }); + } + }, + + updateTables: function() { + this.each(function() { + // this is now bound to each matching table + if (this.tableDnDConfig) { + jQuery.tableDnD.makeDraggable(this); + } + }) + }, + + /** Get the mouse coordinates from the event (allowing for browser differences) */ + mouseCoords: function(ev){ + if(ev.pageX || ev.pageY){ + return {x:ev.pageX, y:ev.pageY}; + } + return { + x:ev.clientX + document.body.scrollLeft - document.body.clientLeft, + y:ev.clientY + document.body.scrollTop - document.body.clientTop + }; + }, + + /** Given a target element and a mouse event, get the mouse offset from that element. + To do this we need the element's position and the mouse position */ + getMouseOffset: function(target, ev) { + ev = ev || window.event; + + var docPos = this.getPosition(target); + var mousePos = this.mouseCoords(ev); + return {x:mousePos.x - docPos.x, y:mousePos.y - docPos.y}; + }, + + /** Get the position of an element by going up the DOM tree and adding up all the offsets */ + getPosition: function(e){ + var left = 0; + var top = 0; + /** Safari fix -- thanks to Luis Chato for this! */ + if (e.offsetHeight == 0) { + /** Safari 2 doesn't correctly grab the offsetTop of a table row + this is detailed here: + http://jacob.peargrove.com/blog/2006/technical/table-row-offsettop-bug-in-safari/ + the solution is likewise noted there, grab the offset of a table cell in the row - the firstChild. + note that firefox will return a text node as a first child, so designing a more thorough + solution may need to take that into account, for now this seems to work in firefox, safari, ie */ + e = e.firstChild; // a table cell + } + + while (e.offsetParent){ + left += e.offsetLeft; + top += e.offsetTop; + e = e.offsetParent; + } + + left += e.offsetLeft; + top += e.offsetTop; + + return {x:left, y:top}; + }, + + mousemove: function(ev) { + if (jQuery.tableDnD.dragObject == null) { + return; + } + + var dragObj = jQuery(jQuery.tableDnD.dragObject); + var config = jQuery.tableDnD.currentTable.tableDnDConfig; + var mousePos = jQuery.tableDnD.mouseCoords(ev); + var y = mousePos.y - jQuery.tableDnD.mouseOffset.y; + //auto scroll the window + var yOffset = window.pageYOffset; + if (document.all) { + // Windows version + //yOffset=document.body.scrollTop; + if (typeof document.compatMode != 'undefined' && + document.compatMode != 'BackCompat') { + yOffset = document.documentElement.scrollTop; + } + else if (typeof document.body != 'undefined') { + yOffset=document.body.scrollTop; + } + + } + + if (mousePos.y-yOffset < config.scrollAmount) { + window.scrollBy(0, -config.scrollAmount); + } else { + var windowHeight = window.innerHeight ? window.innerHeight + : document.documentElement.clientHeight ? document.documentElement.clientHeight : document.body.clientHeight; + if (windowHeight-(mousePos.y-yOffset) < config.scrollAmount) { + window.scrollBy(0, config.scrollAmount); + } + } + + + if (y != jQuery.tableDnD.oldY) { + // work out if we're going up or down... + var movingDown = y > jQuery.tableDnD.oldY; + // update the old value + jQuery.tableDnD.oldY = y; + // update the style to show we're dragging + if (config.onDragClass) { + dragObj.addClass(config.onDragClass); + } else { + dragObj.css(config.onDragStyle); + } + // If we're over a row then move the dragged row to there so that the user sees the + // effect dynamically + var currentRow = jQuery.tableDnD.findDropTargetRow(dragObj, y); + if (currentRow) { + // TODO worry about what happens when there are multiple TBODIES + if (movingDown && jQuery.tableDnD.dragObject != currentRow) { + jQuery.tableDnD.dragObject.parentNode.insertBefore(jQuery.tableDnD.dragObject, currentRow.nextSibling); + } else if (! movingDown && jQuery.tableDnD.dragObject != currentRow) { + jQuery.tableDnD.dragObject.parentNode.insertBefore(jQuery.tableDnD.dragObject, currentRow); + } + } + } + + return false; + }, + + /** We're only worried about the y position really, because we can only move rows up and down */ + findDropTargetRow: function(draggedRow, y) { + var rows = jQuery.tableDnD.currentTable.rows; + for (var i=0; i rowY - rowHeight) && (y < (rowY + rowHeight))) { + // that's the row we're over + // If it's the same as the current row, ignore it + if (row == draggedRow) {return null;} + var config = jQuery.tableDnD.currentTable.tableDnDConfig; + if (config.onAllowDrop) { + if (config.onAllowDrop(draggedRow, row)) { + return row; + } else { + return null; + } + } else { + // If a row has nodrop class, then don't allow dropping (inspired by John Tarr and Famic) + var nodrop = jQuery(row).hasClass("nodrop"); + if (! nodrop) { + return row; + } else { + return null; + } + } + return row; + } + } + return null; + }, + + mouseup: function(e) { + if (jQuery.tableDnD.currentTable && jQuery.tableDnD.dragObject) { + var droppedRow = jQuery.tableDnD.dragObject; + var config = jQuery.tableDnD.currentTable.tableDnDConfig; + // If we have a dragObject, then we need to release it, + // The row will already have been moved to the right place so we just reset stuff + if (config.onDragClass) { + jQuery(droppedRow).removeClass(config.onDragClass); + } else { + jQuery(droppedRow).css(config.onDropStyle); + } + jQuery.tableDnD.dragObject = null; + if (config.onDrop) { + // Call the onDrop method if there is one + config.onDrop(jQuery.tableDnD.currentTable, droppedRow); + } + jQuery.tableDnD.currentTable = null; // let go of the table too + } + }, + + serialize: function() { + if (jQuery.tableDnD.currentTable) { + return jQuery.tableDnD.serializeTable(jQuery.tableDnD.currentTable); + } else { + return "Error: No Table id set, you need to set an id on your table and every row"; + } + }, + + serializeTable: function(table) { + var result = ""; + var tableId = table.id; + var rows = table.rows; + for (var i=0; i 0) result += "&"; + var rowId = rows[i].id; + if (rowId && rowId && table.tableDnDConfig && table.tableDnDConfig.serializeRegexp) { + rowId = rowId.match(table.tableDnDConfig.serializeRegexp)[0]; + } + + result += tableId + '[]=' + rowId; + } + return result; + }, + + serializeTables: function() { + var result = ""; + this.each(function() { + // this is now bound to each matching table + result += jQuery.tableDnD.serializeTable(this); + }); + return result; + } + +} + +jQuery.fn.extend( + { + tableDnD : jQuery.tableDnD.build, + tableDnDUpdate : jQuery.tableDnD.updateTables, + tableDnDSerialize: jQuery.tableDnD.serializeTables + } +); + +/** END TableDnD plugin */ + + +/** + * JS for displaying custom url for: + * * Profile page + * * Register page + * * Custom stylesheet + * + * @since 2.9.6 + */ +(function($) { + $(document).ready(function() { + if ($("#wpmem_logpage_select").val() == 'use_custom') + $("#wpmem_logpage_custom").show(); + else + $("#wpmem_logpage_custom").hide(); + if ($("#wpmem_regpage_select").val() == 'use_custom') + $("#wpmem_regpage_custom").show(); + else + $("#wpmem_regpage_custom").hide(); + if ($("#wpmem_mspage_select").val() == 'use_custom') + $("#wpmem_mspage_custom").show(); + else + $("#wpmem_mspage_custom").hide(); + if ($("#wpmem_stylesheet_select").val() == 'use_custom') + $("#wpmem_stylesheet_custom").show(); + else + $("#wpmem_stylesheet_custom").hide(); + $("#wpmem_logpage_select").change(function() { + if ($("#wpmem_logpage_select").val() == 'use_custom') + $("#wpmem_logpage_custom").show(); + else + $("#wpmem_logpage_custom").hide(); + }); + $("#wpmem_regpage_select").change(function() { + if ($("#wpmem_regpage_select").val() == 'use_custom') + $("#wpmem_regpage_custom").show(); + else + $("#wpmem_regpage_custom").hide(); + }); + $("#wpmem_mspage_select").change(function() { + if ($("#wpmem_mspage_select").val() == 'use_custom') + $("#wpmem_mspage_custom").show(); + else + $("#wpmem_mspage_custom").hide(); + }); + $("#wpmem_stylesheet_select").change(function() { + if ($("#wpmem_stylesheet_select").val() == 'use_custom') + $("#wpmem_stylesheet_custom").show(); + else + $("#wpmem_stylesheet_custom").hide(); + }); + }); +})(jQuery); + + +/** + * JS for displaying additional info for checkbox/dropdowns + * + * @since 2.9.6 + */ +(function($) { + $(document).ready(function() { + $("#wpmem_checkbox_info").hide(); + $("#wpmem_dropdown_info").hide(); + }); + $(document).ready(function() { + $("#wpmem_field_type_select").change(function() { + if ($("#wpmem_field_type_select").val() == 'checkbox') + $("#wpmem_checkbox_info").show(); + else + $("#wpmem_checkbox_info").hide(); + if ($("#wpmem_field_type_select").val() == 'select') + $("#wpmem_dropdown_info").show(); + else + $("#wpmem_dropdown_info").hide(); + }); + }); +})(jQuery); diff --git a/uninstall.php b/uninstall.php index cd8c2d8b..16ae5683 100644 --- a/uninstall.php +++ b/uninstall.php @@ -1,81 +1,82 @@ -get_col( "SELECT blog_id FROM $wpdb->blogs" ); - $original_blog_id = get_current_blog_id(); - - foreach ( $blog_ids as $blog_id ) { - switch_to_blog( $blog_id ); - wpmem_uninstall_options(); - } - switch_to_blog( $original_blog_id ); - - } else { - wpmem_uninstall_options(); - } -} - - -/** - * Compartmentalizes uninstall - * - * @since 2.9.3 - */ -function wpmem_uninstall_options() -{ - delete_option( 'wpmembers_settings' ); - delete_option( 'wpmembers_fields' ); - delete_option( 'wpmembers_dialogs' ); - delete_option( 'wpmembers_captcha' ); - delete_option( 'wpmembers_tos' ); - delete_option( 'wpmembers_export' ); - delete_option( 'wpmembers_msurl' ); - delete_option( 'wpmembers_regurl' ); - delete_option( 'wpmembers_cssurl' ); - delete_option( 'wpmembers_style' ); - delete_option( 'wpmembers_autoex' ); - delete_option( 'wpmembers_utfields' ); - delete_option( 'wpmembers_attrib' ); - - delete_option( 'wpmembers_email_newreg' ); - delete_option( 'wpmembers_email_newmod' ); - delete_option( 'wpmembers_email_appmod' ); - delete_option( 'wpmembers_email_repass' ); - delete_option( 'wpmembers_email_footer' ); - delete_option( 'wpmembers_email_notify' ); - delete_option( 'wpmembers_email_wpfrom' ); - delete_option( 'wpmembers_email_wpname' ); - - delete_option( 'widget_wpmemwidget' ); -} - +get_col( "SELECT blog_id FROM $wpdb->blogs" ); + $original_blog_id = get_current_blog_id(); + + foreach ( $blog_ids as $blog_id ) { + switch_to_blog( $blog_id ); + wpmem_uninstall_options(); + } + switch_to_blog( $original_blog_id ); + + } else { + wpmem_uninstall_options(); + } +} + + +/** + * Compartmentalizes uninstall + * + * @since 2.9.3 + */ +function wpmem_uninstall_options() +{ + delete_option( 'wpmembers_settings' ); + delete_option( 'wpmembers_fields' ); + delete_option( 'wpmembers_dialogs' ); + delete_option( 'wpmembers_captcha' ); + delete_option( 'wpmembers_tos' ); + delete_option( 'wpmembers_export' ); + delete_option( 'wpmembers_msurl' ); + delete_option( 'wpmembers_regurl' ); + delete_option( 'wpmembers_logurl' ); + delete_option( 'wpmembers_cssurl' ); + delete_option( 'wpmembers_style' ); + delete_option( 'wpmembers_autoex' ); + delete_option( 'wpmembers_utfields' ); + delete_option( 'wpmembers_attrib' ); + + delete_option( 'wpmembers_email_newreg' ); + delete_option( 'wpmembers_email_newmod' ); + delete_option( 'wpmembers_email_appmod' ); + delete_option( 'wpmembers_email_repass' ); + delete_option( 'wpmembers_email_footer' ); + delete_option( 'wpmembers_email_notify' ); + delete_option( 'wpmembers_email_wpfrom' ); + delete_option( 'wpmembers_email_wpname' ); + + delete_option( 'widget_wpmemwidget' ); +} + /** End of File **/ \ No newline at end of file diff --git a/wp-members.php b/wp-members.php index cc80c67c..8c66c741 100644 --- a/wp-members.php +++ b/wp-members.php @@ -1,336 +1,337 @@ -the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 2.9.9 -Author: Chad Butler -Author URI: http://butlerblog.com/ -License: GPLv2 -*/ - - -/* - Copyright (c) 2006-2015 Chad Butler - - The name WP-Members(tm) is a trademark of butlerblog.com - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License, version 2, as - published by the Free Software Foundation. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - You may also view the license here: - http://www.gnu.org/licenses/gpl.html -*/ - - -/* - A NOTE ABOUT LICENSE: - - While this plugin is freely available and open-source under the GPL2 - license, that does not mean it is "public domain." You are free to modify - and redistribute as long as you comply with the license. Any derivative - work MUST be GPL licensed and available as open source. You also MUST give - proper attribution to the original author, copyright holder, and trademark - owner. This means you cannot change two lines of code and claim copyright - of the entire work as your own. The GPL2 license requires that if you - modify this code, you must clearly indicate what section(s) you have - modified and you may only claim copyright of your modifications and not - the body of work. If you are unsure or have questions about how a - derivative work you are developing complies with the license, copyright, - trademark, or if you do not understand the difference between - open source and public domain, contact the original author at: - http://rocketgeek.com/contact/. - - - INSTALLATION PROCEDURE: - - For complete installation and usage instructions, - visit http://rocketgeek.com -*/ - - -/** initial constants **/ -define( 'WPMEM_VERSION', '2.9.9' ); -define( 'WPMEM_DEBUG', false ); -define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); -define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); - -/** initialize the plugin **/ -add_action( 'after_setup_theme', 'wpmem_init', 10 ); - -/** install the pluign **/ -register_activation_hook( __FILE__, 'wpmem_install' ); - - -/** - * Initialize WP-Members. - * - * The initialization function contains much of what was previously just - * loaded in the main plugin file. It has been moved into this function - * in order to allow action hooks for loading the plugin and initializing - * its features and options. - * - * @since 2.9.0 - */ -function wpmem_init() -{ - /** - * Fires before initialization of plugin options. - * - * @since 2.9.0 - */ - do_action( 'wpmem_pre_init' ); - - /** - * start with any potential translation - */ - load_plugin_textdomain( 'wp-members', false, dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); - - - /** - * load options - */ - $wpmem_settings = get_option( 'wpmembers_settings' ); - - /** - * Filter the options before they are loaded into constants. - * - * @since 2.9.0 - * - * @param array $wpmem_settings An array of the WP-Members settings. - */ - $wpmem_settings = apply_filters( 'wpmem_settings', $wpmem_settings ); - - /** - * define constants based on option settings - */ - ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem_settings[1] ) : ''; - ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $wpmem_settings[2] ) : ''; - ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $wpmem_settings[3] ) : ''; - ( ! defined( 'WPMEM_NOTIFY_ADMIN' ) ) ? define( 'WPMEM_NOTIFY_ADMIN', $wpmem_settings[4] ) : ''; - ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $wpmem_settings[5] ) : ''; - ( ! defined( 'WPMEM_CAPTCHA' ) ) ? define( 'WPMEM_CAPTCHA', $wpmem_settings[6] ) : ''; - ( ! defined( 'WPMEM_NO_REG' ) ) ? define( 'WPMEM_NO_REG', $wpmem_settings[7] ) : ''; - ( ! defined( 'WPMEM_USE_EXP' ) ) ? define( 'WPMEM_USE_EXP', $wpmem_settings[9] ) : ''; - ( ! defined( 'WPMEM_USE_TRL' ) ) ? define( 'WPMEM_USE_TRL', $wpmem_settings[10] ) : ''; - ( ! defined( 'WPMEM_IGNORE_WARN' ) ) ? define( 'WPMEM_IGNORE_WARN', $wpmem_settings[11] ) : ''; - - ( ! defined( 'WPMEM_MSURL' ) ) ? define( 'WPMEM_MSURL', get_option( 'wpmembers_msurl', null ) ) : ''; - ( ! defined( 'WPMEM_REGURL' ) ) ? define( 'WPMEM_REGURL', get_option( 'wpmembers_regurl',null ) ) : ''; - - /** - * define the stylesheet - */ - $wpmem_style = get_option( 'wpmembers_style', null ); - $wpmem_style = ( $wpmem_style == 'use_custom' || ! $wpmem_style ) ? get_option( 'wpmembers_cssurl', null ) : $wpmem_style; - define( 'WPMEM_CSSURL', $wpmem_style ); - - - /** - * Filter the location and name of the pluggable file. - * - * @since 2.9.0 - * - * @param string The path to wp-members-pluggable.php. - */ - $wpmem_pluggable = apply_filters( 'wpmem_plugins_file', WP_PLUGIN_DIR . '/wp-members-pluggable.php' ); - - /** - * preload any custom functions, if available - */ - if( file_exists( $wpmem_pluggable ) ) { - include( $wpmem_pluggable ); - } - - - /** - * preload the expiration module, if available - */ - $exp_module = ( in_array( 'wp-members-expiration/module.php', get_option( 'active_plugins' ) ) ) ? true : false; - define( 'WPMEM_EXP_MODULE', $exp_module ); - - - include_once( 'wp-members-core.php' ); - - add_action( 'init', 'wpmem' ); // runs before headers are sent - add_action( 'widgets_init', 'widget_wpmemwidget_init' ); // initializes the widget - add_action( 'wp_head', 'wpmem_head' ); // anything added to header - add_action( 'admin_init', 'wpmem_chk_admin' ); // check user role to load correct dashboard - add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu - add_action( 'user_register', 'wpmem_wp_reg_finalize' ); // handles wp native registration - add_action( 'login_enqueue_scripts', 'wpmem_wplogin_stylesheet' ); // styles the native registration - add_filter( 'comments_template', 'wpmem_securify_comments', 20, 1 ); // securifies the comments - - add_filter( 'allow_password_reset', 'wpmem_no_reset' ); // no password reset for non-activated users - add_filter( 'the_content', 'wpmem_securify', 1, 1 ); // securifies the_content - add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration - add_filter( 'registration_errors', 'wpmem_wp_reg_validate', 10, 3 ); // native registration validation - - - /** - * add the wp-members shortcodes - */ - add_shortcode( 'wp-members', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_field', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logged_in', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logged_out', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logout', 'wpmem_shortcode' ); - - - /** - * load the stylesheet if using the new forms - */ - add_action( 'wp_print_styles', 'wpmem_enqueue_style' ); - - - /** - * if registration is moderated, check for activation (blocks backend login by non-activated users) - */ - if( WPMEM_MOD_REG == 1 ) { - add_filter( 'authenticate', 'wpmem_check_activated', 99, 3 ); - } - - /** - * Fires after initialization of plugin options. - * - * @since 2.9.0 - */ - do_action( 'wpmem_after_init' ); -} - - -/** - * Scripts for admin panels. - * - * Determines which scripts to load and actions to use based on the - * current users capabilities. - * - * @since 2.5.2 - */ -function wpmem_chk_admin() -{ - /** - * Fires before initialization of admin options. - * - * @since 2.9.0 - */ - do_action( 'wpmem_pre_admin_init' ); - - if( is_multisite() && current_user_can( 'edit_theme_options' ) ) { - require_once( WPMEM_PATH . 'admin/admin.php' ); - } - - // if user has a role that can edit users, load the admin functions - if( current_user_can( 'edit_users' ) ) { - require_once( 'admin/admin.php' ); - require_once( 'admin/users.php' ); - include_once( 'admin/user-profile.php' ); - } else { - // user profile actions for non-admins - require_once( WPMEM_PATH . 'users.php' ); - add_action( 'show_user_profile', 'wpmem_user_profile' ); - add_action( 'edit_user_profile', 'wpmem_user_profile' ); - add_action( 'profile_update', 'wpmem_profile_update' ); - } - - // do any admin approved plugin updates need to be processed? - if( isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'wpmem_update' ) { - require_once( 'admin/update.php' ); - } - - // if user has a role that can edit posts, add the block/unblock meta boxes and custom post/page columns - if( current_user_can( 'edit_posts' ) ) { - include_once( 'admin/post.php' ); - add_action( 'add_meta_boxes', 'wpmem_block_meta_add' ); - add_action( 'save_post', 'wpmem_block_meta_save' ); - add_filter( 'manage_posts_columns', 'wpmem_post_columns' ); - add_action( 'manage_posts_custom_column', 'wpmem_post_columns_content', 10, 2 ); - add_filter( 'manage_pages_columns', 'wpmem_page_columns' ); - add_action( 'manage_pages_custom_column', 'wpmem_page_columns_content', 10, 2 ); - } - - /** - * Fires after initialization of admin options. - * - * @since 2.9.0 - */ - do_action( 'wpmem_after_admin_init' ); -} - - -/** - * Adds the plugin options page and JavaScript. - * - * @since 2.5.2 - */ -function wpmem_admin_options() { - if( ! is_multisite() || ( is_multisite() && current_user_can( 'edit_theme_options' ) ) ) { - $plugin_page = add_options_page ( 'WP-Members', 'WP-Members', 'manage_options', 'wpmem-settings', 'wpmem_admin' ); - add_action( 'load-'.$plugin_page, 'wpmem_load_admin_js' ); // enqueues javascript for admin - } -} - - -/** - * Install the plugin options. - * - * @since 2.5.2 - */ -function wpmem_install() { - require_once( 'wp-members-install.php' ); - if( is_multisite() ) { - // if it is multisite, install options for each blog - global $wpdb; - $blogs = $wpdb->get_results(" - SELECT blog_id - FROM {$wpdb->blogs} - WHERE site_id = '{$wpdb->siteid}' - AND spam = '0' - AND deleted = '0' - AND archived = '0' - "); - $original_blog_id = get_current_blog_id(); - foreach ( $blogs as $blog_id ) { - switch_to_blog( $blog_id->blog_id ); - wpmem_do_install(); - } - switch_to_blog( $original_blog_id ); - } else { - // normal single install - wpmem_do_install(); - } -} - - -add_action( 'wpmu_new_blog', 'wpmem_mu_new_site', 10, 6 ); -/** - * Install default plugin options for a newly added blog in multisite. - * - * @since 2.9.3 - * - * @param $blog_id - * @param $user_id - * @param $domain - * @param $path - * @param $site_id - * @param $meta - */ -function wpmem_mu_new_site( $blog_id, $user_id, $domain, $path, $site_id, $meta ) { - require_once( 'wp-members-install.php' ); - switch_to_blog( $blog_id ); - wpmem_do_install(); - restore_current_blog(); -} - - -/** End of File **/ +the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. +Version: 2.9.9 +Author: Chad Butler +Author URI: http://butlerblog.com/ +License: GPLv2 +*/ + + +/* + Copyright (c) 2006-2015 Chad Butler + + The name WP-Members(tm) is a trademark of butlerblog.com + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License, version 2, as + published by the Free Software Foundation. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + + You may also view the license here: + http://www.gnu.org/licenses/gpl.html +*/ + + +/* + A NOTE ABOUT LICENSE: + + While this plugin is freely available and open-source under the GPL2 + license, that does not mean it is "public domain." You are free to modify + and redistribute as long as you comply with the license. Any derivative + work MUST be GPL licensed and available as open source. You also MUST give + proper attribution to the original author, copyright holder, and trademark + owner. This means you cannot change two lines of code and claim copyright + of the entire work as your own. The GPL2 license requires that if you + modify this code, you must clearly indicate what section(s) you have + modified and you may only claim copyright of your modifications and not + the body of work. If you are unsure or have questions about how a + derivative work you are developing complies with the license, copyright, + trademark, or if you do not understand the difference between + open source and public domain, contact the original author at: + http://rocketgeek.com/contact/. + + + INSTALLATION PROCEDURE: + + For complete installation and usage instructions, + visit http://rocketgeek.com +*/ + + +/** initial constants **/ +define( 'WPMEM_VERSION', '2.9.9' ); +define( 'WPMEM_DEBUG', false ); +define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); +define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); + +/** initialize the plugin **/ +add_action( 'after_setup_theme', 'wpmem_init', 10 ); + +/** install the pluign **/ +register_activation_hook( __FILE__, 'wpmem_install' ); + + +/** + * Initialize WP-Members. + * + * The initialization function contains much of what was previously just + * loaded in the main plugin file. It has been moved into this function + * in order to allow action hooks for loading the plugin and initializing + * its features and options. + * + * @since 2.9.0 + */ +function wpmem_init() +{ + /** + * Fires before initialization of plugin options. + * + * @since 2.9.0 + */ + do_action( 'wpmem_pre_init' ); + + /** + * start with any potential translation + */ + load_plugin_textdomain( 'wp-members', false, dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); + + + /** + * load options + */ + $wpmem_settings = get_option( 'wpmembers_settings' ); + + /** + * Filter the options before they are loaded into constants. + * + * @since 2.9.0 + * + * @param array $wpmem_settings An array of the WP-Members settings. + */ + $wpmem_settings = apply_filters( 'wpmem_settings', $wpmem_settings ); + + /** + * define constants based on option settings + */ + ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem_settings[1] ) : ''; + ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $wpmem_settings[2] ) : ''; + ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $wpmem_settings[3] ) : ''; + ( ! defined( 'WPMEM_NOTIFY_ADMIN' ) ) ? define( 'WPMEM_NOTIFY_ADMIN', $wpmem_settings[4] ) : ''; + ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $wpmem_settings[5] ) : ''; + ( ! defined( 'WPMEM_CAPTCHA' ) ) ? define( 'WPMEM_CAPTCHA', $wpmem_settings[6] ) : ''; + ( ! defined( 'WPMEM_NO_REG' ) ) ? define( 'WPMEM_NO_REG', $wpmem_settings[7] ) : ''; + ( ! defined( 'WPMEM_USE_EXP' ) ) ? define( 'WPMEM_USE_EXP', $wpmem_settings[9] ) : ''; + ( ! defined( 'WPMEM_USE_TRL' ) ) ? define( 'WPMEM_USE_TRL', $wpmem_settings[10] ) : ''; + ( ! defined( 'WPMEM_IGNORE_WARN' ) ) ? define( 'WPMEM_IGNORE_WARN', $wpmem_settings[11] ) : ''; + + ( ! defined( 'WPMEM_MSURL' ) ) ? define( 'WPMEM_MSURL', get_option( 'wpmembers_msurl', null ) ) : ''; + ( ! defined( 'WPMEM_REGURL' ) ) ? define( 'WPMEM_REGURL', get_option( 'wpmembers_regurl',null ) ) : ''; + ( ! defined( 'WPMEM_LOGURL' ) ) ? define( 'WPMEM_LOGURL', get_option( 'wpmembers_logurl',null ) ) : ''; + + /** + * define the stylesheet + */ + $wpmem_style = get_option( 'wpmembers_style', null ); + $wpmem_style = ( $wpmem_style == 'use_custom' || ! $wpmem_style ) ? get_option( 'wpmembers_cssurl', null ) : $wpmem_style; + define( 'WPMEM_CSSURL', $wpmem_style ); + + + /** + * Filter the location and name of the pluggable file. + * + * @since 2.9.0 + * + * @param string The path to wp-members-pluggable.php. + */ + $wpmem_pluggable = apply_filters( 'wpmem_plugins_file', WP_PLUGIN_DIR . '/wp-members-pluggable.php' ); + + /** + * preload any custom functions, if available + */ + if( file_exists( $wpmem_pluggable ) ) { + include( $wpmem_pluggable ); + } + + + /** + * preload the expiration module, if available + */ + $exp_module = ( in_array( 'wp-members-expiration/module.php', get_option( 'active_plugins' ) ) ) ? true : false; + define( 'WPMEM_EXP_MODULE', $exp_module ); + + + include_once( 'wp-members-core.php' ); + + add_action( 'init', 'wpmem' ); // runs before headers are sent + add_action( 'widgets_init', 'widget_wpmemwidget_init' ); // initializes the widget + add_action( 'wp_head', 'wpmem_head' ); // anything added to header + add_action( 'admin_init', 'wpmem_chk_admin' ); // check user role to load correct dashboard + add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu + add_action( 'user_register', 'wpmem_wp_reg_finalize' ); // handles wp native registration + add_action( 'login_enqueue_scripts', 'wpmem_wplogin_stylesheet' ); // styles the native registration + add_filter( 'comments_template', 'wpmem_securify_comments', 20, 1 ); // securifies the comments + + add_filter( 'allow_password_reset', 'wpmem_no_reset' ); // no password reset for non-activated users + add_filter( 'the_content', 'wpmem_securify', 1, 1 ); // securifies the_content + add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration + add_filter( 'registration_errors', 'wpmem_wp_reg_validate', 10, 3 ); // native registration validation + + + /** + * add the wp-members shortcodes + */ + add_shortcode( 'wp-members', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_field', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logged_in', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logged_out', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logout', 'wpmem_shortcode' ); + + + /** + * load the stylesheet if using the new forms + */ + add_action( 'wp_print_styles', 'wpmem_enqueue_style' ); + + + /** + * if registration is moderated, check for activation (blocks backend login by non-activated users) + */ + if( WPMEM_MOD_REG == 1 ) { + add_filter( 'authenticate', 'wpmem_check_activated', 99, 3 ); + } + + /** + * Fires after initialization of plugin options. + * + * @since 2.9.0 + */ + do_action( 'wpmem_after_init' ); +} + + +/** + * Scripts for admin panels. + * + * Determines which scripts to load and actions to use based on the + * current users capabilities. + * + * @since 2.5.2 + */ +function wpmem_chk_admin() +{ + /** + * Fires before initialization of admin options. + * + * @since 2.9.0 + */ + do_action( 'wpmem_pre_admin_init' ); + + if( is_multisite() && current_user_can( 'edit_theme_options' ) ) { + require_once( WPMEM_PATH . 'admin/admin.php' ); + } + + // if user has a role that can edit users, load the admin functions + if( current_user_can( 'edit_users' ) ) { + require_once( 'admin/admin.php' ); + require_once( 'admin/users.php' ); + include_once( 'admin/user-profile.php' ); + } else { + // user profile actions for non-admins + require_once( WPMEM_PATH . 'users.php' ); + add_action( 'show_user_profile', 'wpmem_user_profile' ); + add_action( 'edit_user_profile', 'wpmem_user_profile' ); + add_action( 'profile_update', 'wpmem_profile_update' ); + } + + // do any admin approved plugin updates need to be processed? + if( isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'wpmem_update' ) { + require_once( 'admin/update.php' ); + } + + // if user has a role that can edit posts, add the block/unblock meta boxes and custom post/page columns + if( current_user_can( 'edit_posts' ) ) { + include_once( 'admin/post.php' ); + add_action( 'add_meta_boxes', 'wpmem_block_meta_add' ); + add_action( 'save_post', 'wpmem_block_meta_save' ); + add_filter( 'manage_posts_columns', 'wpmem_post_columns' ); + add_action( 'manage_posts_custom_column', 'wpmem_post_columns_content', 10, 2 ); + add_filter( 'manage_pages_columns', 'wpmem_page_columns' ); + add_action( 'manage_pages_custom_column', 'wpmem_page_columns_content', 10, 2 ); + } + + /** + * Fires after initialization of admin options. + * + * @since 2.9.0 + */ + do_action( 'wpmem_after_admin_init' ); +} + + +/** + * Adds the plugin options page and JavaScript. + * + * @since 2.5.2 + */ +function wpmem_admin_options() { + if( ! is_multisite() || ( is_multisite() && current_user_can( 'edit_theme_options' ) ) ) { + $plugin_page = add_options_page ( 'WP-Members', 'WP-Members', 'manage_options', 'wpmem-settings', 'wpmem_admin' ); + add_action( 'load-'.$plugin_page, 'wpmem_load_admin_js' ); // enqueues javascript for admin + } +} + + +/** + * Install the plugin options. + * + * @since 2.5.2 + */ +function wpmem_install() { + require_once( 'wp-members-install.php' ); + if( is_multisite() ) { + // if it is multisite, install options for each blog + global $wpdb; + $blogs = $wpdb->get_results(" + SELECT blog_id + FROM {$wpdb->blogs} + WHERE site_id = '{$wpdb->siteid}' + AND spam = '0' + AND deleted = '0' + AND archived = '0' + "); + $original_blog_id = get_current_blog_id(); + foreach ( $blogs as $blog_id ) { + switch_to_blog( $blog_id->blog_id ); + wpmem_do_install(); + } + switch_to_blog( $original_blog_id ); + } else { + // normal single install + wpmem_do_install(); + } +} + + +add_action( 'wpmu_new_blog', 'wpmem_mu_new_site', 10, 6 ); +/** + * Install default plugin options for a newly added blog in multisite. + * + * @since 2.9.3 + * + * @param $blog_id + * @param $user_id + * @param $domain + * @param $path + * @param $site_id + * @param $meta + */ +function wpmem_mu_new_site( $blog_id, $user_id, $domain, $path, $site_id, $meta ) { + require_once( 'wp-members-install.php' ); + switch_to_blog( $blog_id ); + wpmem_do_install(); + restore_current_blog(); +} + + +/** End of File **/ From 27a263ef6a866e1b85f034d55111e2461bb46e33 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 8 Mar 2015 19:00:58 +0000 Subject: [PATCH 0028/1694] completed code standards update --- wp-members-email.php | 140 +++++++++++++++++++++++++++++-------------- 1 file changed, 94 insertions(+), 46 deletions(-) diff --git a/wp-members-email.php b/wp-members-email.php index 1db37c98..392984d7 100644 --- a/wp-members-email.php +++ b/wp-members-email.php @@ -99,9 +99,9 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, * @since 2.7.4 * * @param mixed $default_header The email headers. - * @param string $toggle Toggle to determine what email is being generated (newreg|newmod|appmod|repass|admin). + * @param string $arr['toggle'] Toggle to determine what email is being generated (newreg|newmod|appmod|repass|admin). */ - $arr['headers'] = apply_filters( 'wpmem_email_headers', $default_header, $toggle ); + $arr['headers'] = apply_filters( 'wpmem_email_headers', $default_header, $arr['toggle'] ); /** handle backward compatibility for customizations that may call the email function directly */ if ( ! $wpmem_fields ) { @@ -124,19 +124,16 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, * @param array $field_data An array of the posted registration data. */ $arr = apply_filters( 'wpmem_email_filter', $arr, $wpmem_fields, $field_data ); - - /** extract the array **/ - extract( $arr ); /** * If emails are not disabled, continue the email process */ - if ( ! $disable ) { + if ( ! $arr['disable'] ) { /** * Legacy email filters applied */ - switch ( $toggle ) { + switch ( $arr['toggle'] ) { case 'newreg': //this is a new registration @@ -147,7 +144,7 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, * * @param string $arr['body'] The body content of the new registration email. */ - $body = apply_filters( 'wpmem_email_newreg', $body ); + $arr['body'] = apply_filters( 'wpmem_email_newreg', $arr['body'] ); break; case 'newmod': @@ -157,9 +154,9 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, * * @since 2.7.4 * - * @param string $body The body content of the moderated registration email. + * @param string $arr['body'] The body content of the moderated registration email. */ - $body = apply_filters( 'wpmem_email_newmod', $body ); + $arr['body'] = apply_filters( 'wpmem_email_newmod', $arr['body'] ); break; case 'appmod': @@ -169,9 +166,9 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, * * @since 2.7.4 * - * @param string $body The body content of the reset password email. + * @param string $arr['body'] The body content of the reset password email. */ - $body = apply_filters( 'wpmem_email_appmod', $body ); + $arr['body'] = apply_filters( 'wpmem_email_appmod', $arr['body'] ); break; case 'repass': @@ -181,21 +178,40 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, * * @since 2.7.4 * - * @param string $body The body content of the approved registration email. + * @param string $arr['body'] The body content of the approved registration email. */ - $body = apply_filters( 'wpmem_email_repass', $body ); + $arr['body'] = apply_filters( 'wpmem_email_repass', $arr['body'] ); break; } /** Get the email footer if needed */ - $foot = ( $add_footer ) ? get_option ( 'wpmembers_email_footer' ) : ''; + $foot = ( $arr['add_footer'] ) ? get_option ( 'wpmembers_email_footer' ) : ''; /** if doing shortcode replacements **/ - if ( $do_shortcodes ) { + if ( $arr['do_shortcodes'] ) { + /** Setup default shortcodes */ - $shortcd = array( '[blogname]', '[username]', '[password]', '[reglink]', '[members-area]', '[exp-type]', '[exp-data]' ); - $replace = array( $blogname, $user_login, $password, $reg_link, $wpmem_msurl, $exp_type, $exp_date ); + $shortcd = array( + '[blogname]', + '[username]', + '[password]', + '[reglink]', + '[members-area]', + '[exp-type]', + '[exp-data]', + ); + + /** Replacement values for default shortcodes */ + $replace = array( + $arr['blogname'], + $arr['user_login'], + $password, + $arr['reg_link'], + $arr['wpmem_msurl'], + $arr['exp_type'], + $arr['exp_date'], + ); /** Setup custom field shortcodes */ foreach ( $wpmem_fields as $field ) { @@ -203,17 +219,17 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, $replace[] = get_user_meta( $user_id, $field[2], true ); } - /* Get the subject, body, and footer shortcodes */ - $subj = str_replace( $shortcd, $replace, $subj ); - $body = str_replace( $shortcd, $replace, $body ); - $foot = ( $add_footer ) ? str_replace( $shortcd, $replace, $foot ) : ''; + /* Do replacements for subject, body, and footer shortcodes */ + $arr['subj'] = str_replace( $shortcd, $replace, $arr['subj'] ); + $arr['body'] = str_replace( $shortcd, $replace, $arr['body'] ); + $foot = ( $arr['add_footer'] ) ? str_replace( $shortcd, $replace, $foot ) : ''; } /** Append footer if needed **/ - $body = ( $add_footer ) ? $body . "\r\n" . $foot : $body; + $arr['body'] = ( $arr['add_footer'] ) ? $arr['body'] . "\r\n" . $foot : $arr['body']; /* Send the message */ - wp_mail( $user_email, stripslashes( $subj ), stripslashes( $body ), $headers ); + wp_mail( $arr['user_email'], stripslashes( $arr['subj'] ), stripslashes( $arr['body'] ), $arr['headers'] ); } @@ -237,9 +253,20 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, */ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { - $wp_user_fields = array( 'user_login', 'user_nicename', 'user_url', 'user_registered', 'display_name', 'first_name', 'last_name', 'nickname', 'description' ); - - /** get the user ID */ + /** WP default user fields **/ + $wp_user_fields = array( + 'user_login', + 'user_nicename', + 'user_url', + 'user_registered', + 'display_name', + 'first_name', + 'last_name', + 'nickname', + 'description', + ); + + /** get the user data */ $user = get_userdata( $user_id ); /** get the email stored values */ @@ -259,6 +286,7 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { $arr['add_footer'] = true; $arr['disable'] = false; + /** builds an array of the user data fields */ $field_arr = array(); foreach ( $wpmem_fields as $meta ) { if ( $meta[4] == 'y' ) { @@ -320,34 +348,54 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { * * @since 2.9.8 * - * @param array $arr An array containing email body, subject, user id, and additional settings. - * @param array $wpmem_fields An array of the WP-Members fields. - * @param array $field_arr An array of the posted registration data. + * @param array $arr An array containing email body, subject, user id, and additional settings. + * @param array $wpmem_fields An array of the WP-Members fields. + * @param array $arr['field_arr'] An array of the posted registration data. */ $arr = apply_filters( 'wpmem_notify_filter', $arr, $wpmem_fields, $field_data ); - /** extract the array **/ - extract( $arr ); - /** * If emails are not disabled, continue the email process */ - if ( ! $disable ) { + if ( ! $arr['disable'] ) { /** split field_arr into field_str */ $field_str = ''; - foreach ( $field_arr as $key => $val ) { + foreach ( $arr['field_arr'] as $key => $val ) { $field_str.= $key . ': ' . $val . "\r\n"; } /** Get the email footer if needed */ - $foot = ( $add_footer ) ? get_option ( 'wpmembers_email_footer' ) : ''; + $foot = ( $arr['add_footer'] ) ? get_option ( 'wpmembers_email_footer' ) : ''; /** if doing shortcode replacements **/ - if ( $do_shortcodes ) { + if ( $arr['do_shortcodes'] ) { + /** Setup default shortcodes */ - $shortcd = array( '[blogname]', '[username]', '[email]', '[reglink]', '[exp-type]', '[exp-data]', '[user-ip]', '[activate-user]', '[fields]' ); - $replace = array( $blogname, $user->user_login, $user->user_email, $reg_link, $exp_type, $exp_date, $user_ip, $act_link, $field_str ); + $shortcd = array( + '[blogname]', + '[username]', + '[email]', + '[reglink]', + '[exp-type]', + '[exp-data]', + '[user-ip]', + '[activate-user]', + '[fields]', + ); + + /** Replacement values for default shortcodes */ + $replace = array( + $arr['blogname'], + $arr['user_login'], + $arr['user_email'], + $arr['reg_link'], + $arr['exp_type'], + $arr['exp_date'], + $arr['user_ip'], + $arr['act_link'], + $field_str, + ); /** create the custom field shortcodes */ foreach ( $wpmem_fields as $field ) { @@ -356,25 +404,25 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { } /** Get the subject, body, and footer shortcodes */ - $subj = str_replace( $shortcd, $replace, $subj ); - $body = str_replace( $shortcd, $replace, $body ); - $foot = ( $add_footer ) ? str_replace( $shortcd, $replace, $foot ) : ''; + $arr['subj'] = str_replace( $shortcd, $replace, $arr['subj'] ); + $arr['body'] = str_replace( $shortcd, $replace, $arr['body'] ); + $foot = ( $arr['add_footer'] ) ? str_replace( $shortcd, $replace, $foot ) : ''; } /** Append footer if needed **/ - $body = ( $add_footer ) ? $body . "\r\n" . $foot : $body; + $arr['body'] = ( $arr['add_footer'] ) ? $arr['body'] . "\r\n" . $foot : $arr['body']; /** * Filters the admin notification email. * * @since 2.8.2 * - * @param string $body The admin notification email body. + * @param string $arr['body'] The admin notification email body. */ - $body = apply_filters( 'wpmem_email_notify', $body ); + $arr['body'] = apply_filters( 'wpmem_email_notify', $arr['body'] ); /* Send the message */ - wp_mail( $admin_email, stripslashes( $subj ), stripslashes( $body ), $headers ); + wp_mail( $admin_email, stripslashes( $arr['subj'] ), stripslashes( $arr['body'] ), $arr['headers'] ); } } endif; From 846b3a4d794649a3d89692c664639033bcb2da53 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 23 Mar 2015 11:23:44 -0500 Subject: [PATCH 0029/1694] 2.9.9 rc3 --- admin/tab-options.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/tab-options.php b/admin/tab-options.php index 91aa4a8e..9eaa6e84 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -103,7 +103,7 @@ function wpmem_a_build_options( $wpmem_settings )  
+  
From be6241a3b69ad0fe0b89905290871656f5a118e4 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 24 Mar 2015 11:12:51 -0500 Subject: [PATCH 0030/1694] added readme.md --- README.md | 308 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 308 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 00000000..a6666a9d --- /dev/null +++ b/README.md @@ -0,0 +1,308 @@ +# WP-Members # +**Contributors:** cbutlerjr + +**Tags:** access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber + +**Requires at least:** 3.1 + +**Tested up to:** 4.1 + +**Stable tag:** 2.9.9 + +**License:** GPLv2 + + +WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. + +## Description ## + +WP-Members™ is a membership plugin for WordPress®. Perfect for newsletters, premium content sites, and more! The plugin restricts selected WordPress® content to registered site members. WP-Members™ puts the registration process on the site front end so it is inline with your content (and thus your branded theme) instead of the native WP login page. WP-Members™ works with no modifications to your theme, but it is scalable for users that want to customize the look and feel, or want to restrict only some content. It is a great tool for sites offering premium content to subscribers, and is adaptable to a variety of applications. + +[vimeo https://vimeo.com/84961265] + +### Features: ### + +* Block posts, pages, both, or none by default +* Block individual posts/pages +* Login/Registration is inline with content rather than the WP login page +* User registration and profile integrated into your theme +* Sidebar login widget +* Create custom registration and profile fields +* Set which fields display and which are required +* Notify admin of new user registrations +* Hold new registrations for admin approval +* Automatically create post excerpts +* Show excerpt on pages/posts for better SEO +* Optional CAPTCHA for registration +* More than 80 action and filter hooks for extensibility + +By default, WordPress® allows all content to be "open" and viewable by anyone and allows the site owner to restrict specific content if desired by setting a password for the post. WP-Members™ operates with the reverse assumption. It restricts all posts by default but allows the site owner to "unblock" content as desired. WP-Members™ also offers the ability to change the default plugin settings. For those that simply want to utilize the member management features and possibly restrict some content, the default setting can easily be toggled to block or unblock pages and/or posts by default. No matter what the default setting, individual posts or pages can be set to be blocked or unblocked at the article level, overriding the default setting. + +The plugin installs with additional registration fields including name, address, phone, and email. Using the WP-Members™ admin panel, you can also create your own custom registration fields and delete existing ones. Changing the field order is simple with a drag-and-drop interface. All of the registration process is inline with your theme and content rather than using the WordPress® login page. This offers you a premium content site with a professional and branded look and feel. It also provides an opportunity for the user to register without leaving the page to do so - less clicks = more conversions. + +There are also some special pages that can be created with simple shortcodes: + +* A User Profile page where registered members can edit their information and change/reset their password. +* A Registration page available for those that need a specific URL for registrations (such as email marketing or banner ad landing pages). Note: this is strictly optional as a registration form can also be included by default on blocked content pages. +* A Login page. This is also an optional page as the login form is included by default on blocked content. But if you need a specific login page, this can be created with a simple shortcode. +* And more! + +The plugin runs on a framework with over 80 action and filter hooks so you can fully customize your implementation. + +In addition to all of the features above, the plugin can be extended with premium add-on modules available from the support site rocketgeek.com. Members of rocketgeek.com have access to support, examples, tutorials, and code snippets that will help you extend and customize the base plugin using the plugin's framework. Some of the add-ons have their own hooks and shortcodes to further extend the plugin's extensibility. [Visit the site for more info](http://rocketgeek.com/about/site-membership-subscription/). + +### What the plugin does not do ### + +WP-Members does not automatically hide absolutely everything from view. The default install of the plugin is designed to use "teaser" content to drive users to want to register. If you want certain content or menu elements completely hidden, there are ways to do that with some customization between your theme and the plugin, but it is not automatic. + + +## Installation ## + +WP-Members™ is designed to run "out-of-the-box" with no modifications to your WP installation necessary. Please follow the installation instructions below. __Most of the support issues that arise are a result of improper installation or simply not reading/following directions__. + +### Basic Install: ### + +The best start is to follow the instructions in the [Quick Start Guide](http://rocketgeek.com/plugins/wp-members/quick-start-guide/). There is also a complete [Users Guide available](http://rocketgeek.com/plugins/wp-members/users-guide/) that covers all of the plugin's features in depth. + +1. Upload the `/wp-members/` directory and its contents to the `/wp-content/plugins/` directory +2. Activate the plugin through the 'Plugins' menu in WordPress® + +You are ready to begin using WP-Members™. Now follow the instructions titled "Locking down your site" below. + +NOTE: Please follow instructions for installation. The vast majority of people that have marked the plugin as "broken" in the plugin compatibility form simply did not read/follow installation instructions. If something is unclear, ask for assistance. + +### Locking down your site: ### + +* To begin restricting posts, you will need to be using the `` link in your posts. Content above to the "more" split will display on summary pages (home, archive, category) but the user will be required to login to view the entire post. You may also use the plugin's auto excerpt setting to create post excerpts automatically. If you do not use the "more" tag or the auto excerpt setting, full post content is going to show on archive templates. +* To begin restricting pages, change the plugin default setting for pages to be blocked. Unlike posts, the `` link is not necessary in the blocking of pages, but __must__ be used if you have the "show excerpts" setting turned on. +* To protect comments, we recommend setting "Users must be registered and logged in to comment" under Settings > Discussion +* Also on the page Settings > General, we recommend making sure "Anyone can register" is unchecked. While not required, this will prevent WP's native registration from colliding with WP-Members™, especially if you are using any of the WP-Members™ additional registration fields. +* Under Settings > Reading, we recommend that "For each article in a feed, show" is set to "Summary." WordPress® installs with full feed settings by default. If you don't change this, your feeds will show full content. + + +### Additional Settings and Information ### + +A full Users Guide is [available here](http://rocketgeek.com/plugins/wp-members/users-guide/). The guide outlines the installation process, and also documents how to use all of the settings. + +### Plugin Extensibility ### + +WP-Members™ is designed to be an out-of-the-box usable plugin, but also have an extensible framework for maximum flexibility and customization. For this purpose, there are a number of shortcodes, filters, and actions that can be used. + +See [this page](http://rocketgeek.com/plugins/wp-members/users-guide/shortcodes/) for a list of shortcodes and their description. + +The plugin has 80 filter and action hooks. For a list of hooks and a description of their use, see [this page](http://rocketgeek.com/plugins/wp-members/users-guide/filter-hooks/) + +The plugin's premium support site has __loads__ of tips, tricks, and sample code for you to make maximum use out of the plugin. [Get more information here](http://rocketgeek.com/about/site-membership-subscription/). Members of the premium support site also have access to premium add-on modules. + + +## Frequently Asked Questions ## + +The FAQs are maintained at http://rocketgeek.com/plugins/wp-members/users-guide/faqs/ + + +## Other Notes ## + +### Statement regarding the name WP-Members™ ### + +WP-Members™ is a trademark of butlerblog.com. + +There are a number of commercial vendors offering products called WP-Members™ or a derivative thereof. Most of these products are neither free, nor are all of them open source. The original plugin hosted here has been publicly available since 2006 and in no way associated with any of these vendors. Tagging your support request in the wordpress.org forums attaches it to this plugin. If you are seeking support for one of these commercial products, you should seek support from the vendor. If you got it from a site other than [here](http://wordpress.org/extend/plugins/wp-members) then it isn't WP-Members™. + +An [official statement is available here](http://butlerblog.com/regarding-wp-members). + +### Regarding RocketGeek.com ### + +Premium priority support is available at the plugin's site [RocketGeek.com](http://rocketgeek.com). A site membership includes priority support, members-only forum access, plugin extensions, and a custom code snippet library. [RocketGeek.com](http://rocketgeek.com) is the only site officially managed for this plugin's support. + + +## Upgrade Notice ## + +WP-Members 2.9.9 is mostly minor updates preparing codebase for the 3.0 project. + +## Screenshots ## + +###1. The default when viewing a blocked post - the plugin will deliver a login screen and registration form in place of blocked content (this default can be changed to other options). +### +![The default when viewing a blocked post - the plugin will deliver a login screen and registration form in place of blocked content (this default can be changed to other options). +](https://ps.w.org/wp-members/assets/screenshot-1.png) + + +###2. Admin Panel - Options Tab - the various option settings for the plugin. +### +![Admin Panel - Options Tab - the various option settings for the plugin. +](https://ps.w.org/wp-members/assets/screenshot-2.png) + + +###3. Admin Panel - Fields Tab - the plugin field manager allows you to manage (or delete) the installed extra fields and field order, and also add your own custom fields. +### +![Admin Panel - Fields Tab - the plugin field manager allows you to manage (or delete) the installed extra fields and field order, and also add your own custom fields. +](https://ps.w.org/wp-members/assets/screenshot-3.png) + + +###4. Admin Panel - Dialogs Tab - the major dialogs that the plugin uses for error and other messages can be edited in the plugin's admin panel. +### +![Admin Panel - Dialogs Tab - the major dialogs that the plugin uses for error and other messages can be edited in the plugin's admin panel. +](https://ps.w.org/wp-members/assets/screenshot-4.png) + + +###5. Admin Panel - Emails Tab - all of the emails that are sent by the plugin can be edited in the admin panel. +### +![Admin Panel - Emails Tab - all of the emails that are sent by the plugin can be edited in the admin panel. +](https://ps.w.org/wp-members/assets/screenshot-5.png) + + +###6. Posts > All Posts - The plugin adds a column to the list of posts and pages to display if a post or page is unblocked or blocked (the opposite of whatver you have set for the plugin's default in the options tab). +### +![Posts > All Posts - The plugin adds a column to the list of posts and pages to display if a post or page is unblocked or blocked (the opposite of whatver you have set for the plugin's default in the options tab). +](https://ps.w.org/wp-members/assets/screenshot-6.png) + + +###7. Posts > Edit Post - The plugin adds a meta box to the post/page editor allowing you to set an individual post to be blocked or unblocked (the opposite of whatver your default setting is). +### +![Posts > Edit Post - The plugin adds a meta box to the post/page editor allowing you to set an individual post to be blocked or unblocked (the opposite of whatver your default setting is). +](https://ps.w.org/wp-members/assets/screenshot-7.png) + + + +## Changelog ## + +### 2.9.9 ### +* Code standards in wp-members-email.php +* Rebuilt admin notification email to follow new regular email structure with more filters in wp-members-email.com +* Added $toggle to headers filter that is used in both emails so that headers could be filtered based on the email being sent (i.e. sending plain text for admin notification vs html for others. in wp-members-email.php +* Added redirect_to parameter as a widget entry in wp-members-sidebar.php +* Corrected flaws in error checking for adding new fields in /admin/tab-fields.php +* Added functions for updating user_status in wp_users table in /admin/users.php +* Fixed get_user_meta 'true' error in wp-members-core.php, users.php, /admin/users.php, /admin/user-profile.php +* Added dummy comments template to protect comments without post password. +* Added new action for deactivting a user (opposite of wpmem_user_activated). +* Added check to remove password, confirm_password, and confirm_email from export (data for these was already skipped, but the field space was there). +* Added wpmem_status_msg_args and wpmem_login_links_args filters. +* Corrected Really Simple Captcha, added field wrapper and should not display on user profile edit. + +### 2.9.8 ### +* Fixed bug in settings update that caused the stored version number to be erased. +* Fixed bug with new email function that causes the wpmem_email_newreg not to apply any filtered changes to the email body. +* Major updates to wpmem_block logic, changing to universal _wpmem_block from two separate metas (block & unblock). +* Fixed bug in the page bulk action that caused the result to end up on the posts page. +* Added wpmem_use_ssl utility function. +* Added use of wpmem_use_ssl function to reCAPTCHA to load correctly (previously handled ssl directly). +* Added use of wpmem_use_ssl function for default input text for custom register page, user profile page, and custom stylesheet settings inputs. +* Added new redirect_to parameter to login page shortcode. +* Fixed checkbox for checked by default on the add new user screen. +* Fixed "admin only" fields to display on the add new user screen. +* Added underscores parameter to the fields shortcode to strip underscores. Defaults to off. +* Updated excerpt logic to not show excerpts on multipage posts if not the first page. +* Added new 2015 stylesheets (currently available, but subject to changes/updates) + +### 2.9.7 ### +* Fixed comparison for the checkbox CSS class in wpmem_create_formfield. +* Corrected wp native registration function for use on localized sites. +* Rebuilt export function, merges the two previous functions into one (export selected and export all) and will allow for calling custom exports. +* Rebuilt user email function. +* Added default "from" headers to email. +* Added new filter wpmem_export_args. +* Added new filter wpmem_email_filter. +* Added a redirect_to parameter to the registration form similar to the login. +* Fixed plugin admin page load for multisite, if user has theme options edit capabilities. + +### 2.9.6 ### +* Updated admin.js to show/hide custom url fields for User Profile page, Register page, and Stylesheet settings. +* Updated options panel to show/hide custom url fields mentioned above. +* Updated admin.js to show/hide checkbox and dropdown extra settings when adding a custom field in Fields. +* Updated fields panel to show/hide extra fields mentioned above. +* Updated reCAPTCHA to automatically change language if the language is (1) set as WPLANG and (2) used by reCAPTCHA. +* Added error checking if Really Simple CAPTCHA is enabled but not installed. +* Updated registration function for improved operation when used with popular cache plugins. + +### 2.9.5 ### + +* Added support for Really Simple CAPTCHA (Really Simple CAPTCHA must also be installed). +* Added support for custom field meta keys as shortcodes in emails. +* Added support for default permalinks when using wpmem_logout shortcode. +* Improved admin notification email to skip metas defined as excluded meta. +* Fixed activation function for activations from user profile omitting passwords (see 2.9.4 bug fix for moderated password registration). + +### 2.9.4 ### + +* Bug fix for moderated password registration (changes in 2.9.3 introduced a bug that caused moderated registration to send a blank password). +* Bug fix for premium PayPal Subscription extension showing expired users, improved user query. +* Fixed user profile update so that wp_update_user is called only once. +* Added [wpmem_logged_out] shortcode to show content to logged out users. Same as [wp-members status="out"] shortcode but can be used on blocked content without changing security status. +* Removed checkbox for adding password and confirmation fields to the User Screen since these are not stored data. + +### 2.9.3 ### + +* Fixed a backend user profile update and create new user issue introduced with some 2.9.2 code improvements. The issue caused the additional fields not to save. +* Added a confirm password and confirm email field to the default install, as well as automatic form validation when used. +* Updated all functions that store/read user data to skip these fields as there is not need to store them, they are simply form validation fields. +* Improved error checking in the admin Fields tab when attempting to add an option name that already exists. +* Added separate registration validation for multisite (refers to WP-Members front end registration only). Multisite has different username requirements and the existing error message was valid, the wording did not fit well for multisite making it confusing. The multisite validation returns the WP error message rather than a custom error message. I may be updating other validation messages in the plugin to utilize this method (while allowing them to be filtered for customization). +* Added a separate install for multisite. +* Updated the template for all localization files (some strings still need translation). + +### 2.9.2 ### + +* Added user ID parameter to wpmem_login_redirect filter. +* Added new action hooks +* Added logout shortcode +* Added wpmem_msg_dialog_arr filter +* Improvements to registration function +* Admin panel updates for smaller screens +* Added bulk block/unblock for posts and pages + +### 2.9.1 ### + +This is primarily a cleanup and fix update with a few new features. + +* Added WP-Members registration fields to WordPress Users > Add New screen. +* Fixed wpmem_test_shortcode error for TOS. +* Plugin options tab - lists notify address for notify admin setting +* Updated default password change success message - removed need to re-login string. +* Make dropdown values in wpmem_create_formfield function translatable strings for localization +* Changed "logout" to "log out" +* Update to register function to check for unset values for WP native fields. +* Moved the path constants to be defined earlier. +* Added $action parameter to most of the login form filters, allows more direct filtering based on form state (login, password reset, password change). + +### 2.9.0 ### + +This is a major update focusing on upgrades to the form building functions, but also includes a number of other changes and improvements. + +Major updates + +* New form building functions include new hooks and a more customizable form building process. +* Form functions moved from wp-members-dialogs.php to new file forms.php +* Sidebar login form also rebuilt in the same way the login and register forms were changed. +* Legacy (old table based) forms completely removed in 2.9 +* Updates to error and dialog messages, removed unnecessary html tags + +Changes in wp-members-core.php + +* updated calling of wpmem_test_shortcode, now it works like has_shortcode, put off deprecating at this time. +* updated shortcode to include tos page, allow for new tags (wpmem_field, wpmem_logged_in) (added new shortcode calls in wp-members.php), and accept id attribute for fields. Added $tag argument, can use shortcode_atts_{$shortcode} filter +* moved wpmem_test_shortcode to utilities.php +* added new action hooks: wpmem_pwd_change and wpmem_pwd_reset +* added new filter hook: wpmem_regchk + +Changes in wp-members.php + +* a pretty major overhaul of this file. Moved all but four declarations that weren't already in functions into the init function. Only two constants are declared before the function. This initialization comes after the theme is setup, so pre-initilization needs, such as loading pluggable functions can be declared in the theme's functions.php file. Pluggable functions do not need to be loaded only from the wp-members-pluggable.php file. +* The file name of the wp-members-pluggable.php file is loaded in a filter hook, wpmem_plugins_file, so you could call it something else or load it from another location. +* New action hooks: wpmem_pre_init, wpmem_after_init, wpmem_pre_admin_init, wpmem_after_admin_init +* New filter hook: wpmem_settings + +Miscellaneous Changes + +* Updates to the html for some of the admin to better fit the new WP admin layout. Old html was compatible, but the new works better. +* Updates to the options tab to better group options +* Updates to native (wp-login.php) registration to include require field indication +* Review of output, localized a few missed strings +* Implementation of changes in localization of field names. English values are now stored in the db (except for custom fields that would be whatever language the user creates the field as). Fields are then translated when displayed, rather than stored as translated strings. +* Updated user profile to fix some issues with checkbox and required fields in users.php +* Updated user export to include wp_users table fields user_url, user_nicename, and display_name fields +* Code cleanup in wpmem_block function +* Updated autoexcerpt function +* New filter hooks for post editor meta box titles: wpmem_admin_post_meta_title, wpmem_admin_page_meta_title +* Some updates to existing stylesheets +* Added new stylesheets, including two with non-floated elements. Generic, non-floated stylesheet new default for fresh installs \ No newline at end of file From 359135b1e1a7c7e37d0ca8325e4af9a63b9fef25 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 25 Mar 2015 13:20:47 -0500 Subject: [PATCH 0031/1694] 2.9.9.1 admin email fix --- wp-members-email.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-members-email.php b/wp-members-email.php index 392984d7..e1414829 100644 --- a/wp-members-email.php +++ b/wp-members-email.php @@ -422,7 +422,7 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { $arr['body'] = apply_filters( 'wpmem_email_notify', $arr['body'] ); /* Send the message */ - wp_mail( $admin_email, stripslashes( $arr['subj'] ), stripslashes( $arr['body'] ), $arr['headers'] ); + wp_mail( $arr['admin_email'], stripslashes( $arr['subj'] ), stripslashes( $arr['body'] ), $arr['headers'] ); } } endif; From 142fe3b98b627a71bba18c37867b14e4f79f24c5 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 26 Mar 2015 08:50:13 -0500 Subject: [PATCH 0032/1694] updated readme.md --- README.md | 36 ++++++++++++++++++++---------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index a6666a9d..8fd7b5a9 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ **Tested up to:** 4.1 -**Stable tag:** 2.9.9 +**Stable tag:** 2.9.9.1 **License:** GPLv2 @@ -18,7 +18,7 @@ WP-Members™ is a free membership management framework for WordPress® t WP-Members™ is a membership plugin for WordPress®. Perfect for newsletters, premium content sites, and more! The plugin restricts selected WordPress® content to registered site members. WP-Members™ puts the registration process on the site front end so it is inline with your content (and thus your branded theme) instead of the native WP login page. WP-Members™ works with no modifications to your theme, but it is scalable for users that want to customize the look and feel, or want to restrict only some content. It is a great tool for sites offering premium content to subscribers, and is adaptable to a variety of applications. -[vimeo https://vimeo.com/84961265] +[vimeo https://youtu.be/x4MEoRLSY_U] ### Features: ### @@ -117,48 +117,49 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http ## Upgrade Notice ## +WP-Members 2.9.9.1 patches an issue with the admin notification email update in 2.9.9. WP-Members 2.9.9 is mostly minor updates preparing codebase for the 3.0 project. ## Screenshots ## -###1. The default when viewing a blocked post - the plugin will deliver a login screen and registration form in place of blocked content (this default can be changed to other options). -### +1. The default when viewing a blocked post - the plugin will deliver a login screen and registration form in place of blocked content (this default can be changed to other options). + ![The default when viewing a blocked post - the plugin will deliver a login screen and registration form in place of blocked content (this default can be changed to other options). ](https://ps.w.org/wp-members/assets/screenshot-1.png) -###2. Admin Panel - Options Tab - the various option settings for the plugin. -### +2. Admin Panel - Options Tab - the various option settings for the plugin. + ![Admin Panel - Options Tab - the various option settings for the plugin. ](https://ps.w.org/wp-members/assets/screenshot-2.png) -###3. Admin Panel - Fields Tab - the plugin field manager allows you to manage (or delete) the installed extra fields and field order, and also add your own custom fields. -### +3. Admin Panel - Fields Tab - the plugin field manager allows you to manage (or delete) the installed extra fields and field order, and also add your own custom fields. + ![Admin Panel - Fields Tab - the plugin field manager allows you to manage (or delete) the installed extra fields and field order, and also add your own custom fields. ](https://ps.w.org/wp-members/assets/screenshot-3.png) -###4. Admin Panel - Dialogs Tab - the major dialogs that the plugin uses for error and other messages can be edited in the plugin's admin panel. -### +4. Admin Panel - Dialogs Tab - the major dialogs that the plugin uses for error and other messages can be edited in the plugin's admin panel. + ![Admin Panel - Dialogs Tab - the major dialogs that the plugin uses for error and other messages can be edited in the plugin's admin panel. ](https://ps.w.org/wp-members/assets/screenshot-4.png) -###5. Admin Panel - Emails Tab - all of the emails that are sent by the plugin can be edited in the admin panel. -### +5. Admin Panel - Emails Tab - all of the emails that are sent by the plugin can be edited in the admin panel. + ![Admin Panel - Emails Tab - all of the emails that are sent by the plugin can be edited in the admin panel. ](https://ps.w.org/wp-members/assets/screenshot-5.png) -###6. Posts > All Posts - The plugin adds a column to the list of posts and pages to display if a post or page is unblocked or blocked (the opposite of whatver you have set for the plugin's default in the options tab). -### +6. Posts > All Posts - The plugin adds a column to the list of posts and pages to display if a post or page is unblocked or blocked (the opposite of whatver you have set for the plugin's default in the options tab). + ![Posts > All Posts - The plugin adds a column to the list of posts and pages to display if a post or page is unblocked or blocked (the opposite of whatver you have set for the plugin's default in the options tab). ](https://ps.w.org/wp-members/assets/screenshot-6.png) -###7. Posts > Edit Post - The plugin adds a meta box to the post/page editor allowing you to set an individual post to be blocked or unblocked (the opposite of whatver your default setting is). -### +7. Posts > Edit Post - The plugin adds a meta box to the post/page editor allowing you to set an individual post to be blocked or unblocked (the opposite of whatver your default setting is). + ![Posts > Edit Post - The plugin adds a meta box to the post/page editor allowing you to set an individual post to be blocked or unblocked (the opposite of whatver your default setting is). ](https://ps.w.org/wp-members/assets/screenshot-7.png) @@ -166,6 +167,9 @@ WP-Members 2.9.9 is mostly minor updates preparing codebase for the 3.0 project. ## Changelog ## +### 2.9.9.1 ### +* Patches an issue with the admin notification email update in 2.9.9. + ### 2.9.9 ### * Code standards in wp-members-email.php * Rebuilt admin notification email to follow new regular email structure with more filters in wp-members-email.com From c7e9c6fa04397b88e8450f0be9c26b39f831339e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 6 Apr 2015 10:30:55 -0500 Subject: [PATCH 0033/1694] added wpmem_settings_loaded action hook, applied code standards --- wp-members.php | 100 +++++++++++++++++++++++++++---------------------- 1 file changed, 55 insertions(+), 45 deletions(-) diff --git a/wp-members.php b/wp-members.php index d6a0d589..b64edae0 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 2.9.9.1 +Version: 3.0 build 2.9.9.1 base Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ /** initial constants **/ -define( 'WPMEM_VERSION', '2.9.9.1' ); +define( 'WPMEM_VERSION', '3.0 build 2.9.9.1 base' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); @@ -82,8 +82,8 @@ * * @since 2.9.0 */ -function wpmem_init() -{ +function wpmem_init() { + /** * Fires before initialization of plugin options. * @@ -92,13 +92,13 @@ function wpmem_init() do_action( 'wpmem_pre_init' ); /** - * start with any potential translation + * Start with any potential translation. */ load_plugin_textdomain( 'wp-members', false, dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); /** - * load options + * Load options. */ $wpmem_settings = get_option( 'wpmembers_settings' ); @@ -112,7 +112,7 @@ function wpmem_init() $wpmem_settings = apply_filters( 'wpmem_settings', $wpmem_settings ); /** - * define constants based on option settings + * define constants based on option settings. */ ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem_settings[1] ) : ''; ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $wpmem_settings[2] ) : ''; @@ -130,12 +130,18 @@ function wpmem_init() ( ! defined( 'WPMEM_LOGURL' ) ) ? define( 'WPMEM_LOGURL', get_option( 'wpmembers_logurl',null ) ) : ''; /** - * define the stylesheet + * Define the stylesheet. */ $wpmem_style = get_option( 'wpmembers_style', null ); $wpmem_style = ( $wpmem_style == 'use_custom' || ! $wpmem_style ) ? get_option( 'wpmembers_cssurl', null ) : $wpmem_style; define( 'WPMEM_CSSURL', $wpmem_style ); - + + /** + * Fires after main settings are loaded. + * + * @since 3.0 + */ + add_action( 'wpmem_settings_loaded' ); /** * Filter the location and name of the pluggable file. @@ -147,39 +153,45 @@ function wpmem_init() $wpmem_pluggable = apply_filters( 'wpmem_plugins_file', WP_PLUGIN_DIR . '/wp-members-pluggable.php' ); /** - * preload any custom functions, if available + * Preload any custom functions, if available. */ - if( file_exists( $wpmem_pluggable ) ) { + if ( file_exists( $wpmem_pluggable ) ) { include( $wpmem_pluggable ); } - /** - * preload the expiration module, if available + * Preload the expiration module, if available. */ $exp_module = ( in_array( 'wp-members-expiration/module.php', get_option( 'active_plugins' ) ) ) ? true : false; define( 'WPMEM_EXP_MODULE', $exp_module ); - + /** + * Load core file. + */ include_once( 'wp-members-core.php' ); - + + /** + * Add actions. + */ add_action( 'init', 'wpmem' ); // runs before headers are sent add_action( 'widgets_init', 'widget_wpmemwidget_init' ); // initializes the widget add_action( 'wp_head', 'wpmem_head' ); // anything added to header add_action( 'admin_init', 'wpmem_chk_admin' ); // check user role to load correct dashboard add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu add_action( 'user_register', 'wpmem_wp_reg_finalize' ); // handles wp native registration - add_action( 'login_enqueue_scripts', 'wpmem_wplogin_stylesheet' ); // styles the native registration - add_filter( 'comments_template', 'wpmem_securify_comments', 20, 1 ); // securifies the comments + add_action( 'login_enqueue_scripts', 'wpmem_wplogin_stylesheet' ); // styles the native registration + /** + * Add filters. + */ add_filter( 'allow_password_reset', 'wpmem_no_reset' ); // no password reset for non-activated users add_filter( 'the_content', 'wpmem_securify', 1, 1 ); // securifies the_content add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration add_filter( 'registration_errors', 'wpmem_wp_reg_validate', 10, 3 ); // native registration validation - + add_filter( 'comments_template', 'wpmem_securify_comments', 20, 1 ); // securifies the comments /** - * add the wp-members shortcodes + * Add shortcodes. */ add_shortcode( 'wp-members', 'wpmem_shortcode' ); add_shortcode( 'wpmem_field', 'wpmem_shortcode' ); @@ -187,17 +199,15 @@ function wpmem_init() add_shortcode( 'wpmem_logged_out', 'wpmem_shortcode' ); add_shortcode( 'wpmem_logout', 'wpmem_shortcode' ); - /** - * load the stylesheet if using the new forms + * Load the stylesheet if using the new forms. */ add_action( 'wp_print_styles', 'wpmem_enqueue_style' ); - /** - * if registration is moderated, check for activation (blocks backend login by non-activated users) + * If registration is moderated, check for activation (blocks backend login by non-activated users). */ - if( WPMEM_MOD_REG == 1 ) { + if ( WPMEM_MOD_REG == 1 ) { add_filter( 'authenticate', 'wpmem_check_activated', 99, 3 ); } @@ -218,8 +228,8 @@ function wpmem_init() * * @since 2.5.2 */ -function wpmem_chk_admin() -{ +function wpmem_chk_admin() { + /** * Fires before initialization of admin options. * @@ -227,30 +237,30 @@ function wpmem_chk_admin() */ do_action( 'wpmem_pre_admin_init' ); - if( is_multisite() && current_user_can( 'edit_theme_options' ) ) { + if ( is_multisite() && current_user_can( 'edit_theme_options' ) ) { require_once( WPMEM_PATH . 'admin/admin.php' ); } - // if user has a role that can edit users, load the admin functions - if( current_user_can( 'edit_users' ) ) { + /** + * If user has a role that can edit users, load the admin functions, + * otherwise, load profile actions for non-admins. + */ + if ( current_user_can( 'edit_users' ) ) { require_once( 'admin/admin.php' ); require_once( 'admin/users.php' ); include_once( 'admin/user-profile.php' ); } else { - // user profile actions for non-admins require_once( WPMEM_PATH . 'users.php' ); add_action( 'show_user_profile', 'wpmem_user_profile' ); add_action( 'edit_user_profile', 'wpmem_user_profile' ); add_action( 'profile_update', 'wpmem_profile_update' ); } - // do any admin approved plugin updates need to be processed? - if( isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'wpmem_update' ) { - require_once( 'admin/update.php' ); - } - - // if user has a role that can edit posts, add the block/unblock meta boxes and custom post/page columns - if( current_user_can( 'edit_posts' ) ) { + /** + * If user has a role that can edit posts, add the block/unblock + * meta boxes and custom post/page columns. + */ + if ( current_user_can( 'edit_posts' ) ) { include_once( 'admin/post.php' ); add_action( 'add_meta_boxes', 'wpmem_block_meta_add' ); add_action( 'save_post', 'wpmem_block_meta_save' ); @@ -275,8 +285,8 @@ function wpmem_chk_admin() * @since 2.5.2 */ function wpmem_admin_options() { - if( ! is_multisite() || ( is_multisite() && current_user_can( 'edit_theme_options' ) ) ) { - $plugin_page = add_options_page ( 'WP-Members', 'WP-Members', 'manage_options', 'wpmem-settings', 'wpmem_admin' ); + if ( ! is_multisite() || ( is_multisite() && current_user_can( 'edit_theme_options' ) ) ) { + $plugin_page = add_options_page ( 'WP-Members', 'WP-Members', 'manage_options', 'wpmem-settings', 'wpmem_admin' ); add_action( 'load-'.$plugin_page, 'wpmem_load_admin_js' ); // enqueues javascript for admin } } @@ -289,17 +299,17 @@ function wpmem_admin_options() { */ function wpmem_install() { require_once( 'wp-members-install.php' ); - if( is_multisite() ) { + if ( is_multisite() ) { // if it is multisite, install options for each blog global $wpdb; - $blogs = $wpdb->get_results(" - SELECT blog_id + $blogs = $wpdb->get_results( + "SELECT blog_id FROM {$wpdb->blogs} WHERE site_id = '{$wpdb->siteid}' AND spam = '0' AND deleted = '0' - AND archived = '0' - "); + AND archived = '0'" + ); $original_blog_id = get_current_blog_id(); foreach ( $blogs as $blog_id ) { switch_to_blog( $blog_id->blog_id ); @@ -334,4 +344,4 @@ function wpmem_mu_new_site( $blog_id, $user_id, $domain, $path, $site_id, $meta } -/** End of File **/ +/** End of File **/ \ No newline at end of file From 4c4bd2efbb221f07f217f048d923a6cf27f35f04 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 6 Apr 2015 11:01:54 -0500 Subject: [PATCH 0034/1694] code standards, removed extract --- wp-members-core.php | 310 ++++++++++++++++++++--------------------- wp-members-dialogs.php | 100 ++++++------- 2 files changed, 202 insertions(+), 208 deletions(-) diff --git a/wp-members-core.php b/wp-members-core.php index e356823f..93f56025 100644 --- a/wp-members-core.php +++ b/wp-members-core.php @@ -25,47 +25,47 @@ if ( ! function_exists( 'wpmem' ) ): /** - * The Main Action Function + * The Main Action Function. * * Does actions required at initialization * prior to headers being sent. * * @since 0.1 * - * @global string $wpmem_a the action variable also used in wpmem_securify - * @global string $wpmem_regchk contains messages returned from $wpmem_a action functions, used in wpmem_securify + * @global string $wpmem_a The action variable also used in wpmem_securify. + * @global string $wpmem_regchk Contains messages returned from $wpmem_a action functions, used in wpmem_securify. */ -function wpmem() -{ +function wpmem() { + global $wpmem_a, $wpmem_regchk; $wpmem_a = ( isset( $_REQUEST['a'] ) ) ? trim( $_REQUEST['a'] ) : ''; - switch ($wpmem_a) { + switch ( $wpmem_a ) { - case ( 'login' ): + case 'login': $wpmem_regchk = wpmem_login(); break; - case ( 'logout' ): + case 'logout': wpmem_logout(); break; - case ( 'register' ): + case 'register': include_once( 'wp-members-register.php' ); $wpmem_regchk = wpmem_registration( 'register' ); break; - case ( 'update' ): + case 'update': include_once( 'wp-members-register.php' ); $wpmem_regchk = wpmem_registration( 'update' ); break; - case ( 'pwdchange' ): + case 'pwdchange': $wpmem_regchk = wpmem_change_password(); break; - case ( 'pwdreset' ): + case 'pwdreset': $wpmem_regchk = wpmem_reset_password(); break; @@ -90,36 +90,35 @@ function wpmem() if ( ! function_exists( 'wpmem_securify' ) ): /** - * The Securify Content Filter + * The Securify Content Filter. * * This is the primary function that picks up where wpmem() leaves off. - * Determines whether content is shown or hidden for both post and - * pages. + * Determines whether content is shown or hidden for both post and pages. * * @since 2.0 * - * @global var $wpmem_a the action variable received from wpmem() - * @global string $wpmem_regchk contains messages returned from wpmem() action functions - * @global string $wpmem_themsg contains messages to be output - * @global string $wpmem_captcha_err contains error message for reCAPTCHA - * @global array $post needed for protecting comments + * @global var $wpmem_a The action variable received from wpmem(). + * @global string $wpmem_regchk Contains messages returned from wpmem() action functions. + * @global string $wpmem_themsg Contains messages to be output. + * @global string $wpmem_captcha_err Contains error message for reCAPTCHA. + * @global array $post Needed for protecting comments. * @param string $content * @return string $content */ -function wpmem_securify( $content = null ) -{ +function wpmem_securify( $content = null ) { + $content = ( is_single() || is_page() ) ? $content : wpmem_do_excerpt( $content ); if ( ( ! wpmem_test_shortcode( $content, 'wp-members' ) ) ) { global $wpmem_regchk, $wpmem_themsg, $wpmem_a; - if( $wpmem_regchk == "captcha" ) { + if ( $wpmem_regchk == "captcha" ) { global $wpmem_captcha_err; $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

' . $wpmem_captcha_err; } // Block/unblock Posts - if( !is_user_logged_in() && wpmem_block() == true ) { + if ( !is_user_logged_in() && wpmem_block() == true ) { // protects comments if user is not logged in global $post; @@ -135,7 +134,7 @@ function wpmem_securify( $content = null ) include_once( WPMEM_PATH . 'wp-members-dialogs.php' ); // show the login and registration forms - if( $wpmem_regchk ) { + if ( $wpmem_regchk ) { // empty content in any of these scenarios $content = ''; @@ -161,14 +160,14 @@ function wpmem_securify( $content = null ) // toggle shows excerpt above login/reg on posts/pages global $wp_query; - if( $wp_query->query_vars['page'] > 1 ) { + if ( $wp_query->query_vars['page'] > 1 ) { // shuts down excerpts on multipage posts if not on first page $content = ''; - } elseif( WPMEM_SHOW_EXCERPT == 1 ) { + } elseif ( WPMEM_SHOW_EXCERPT == 1 ) { - if( ! stristr( $content, '
' . $wpmem_captcha_err; } - if( $wpmem_regchk == "loginfailed" ) { + if ( $wpmem_regchk == "loginfailed" ) { return wpmem_inc_loginfailed(); } - if( ! is_user_logged_in() ) { - if( $wpmem_a == 'register' ) { + if ( ! is_user_logged_in() ) { + if ( $wpmem_a == 'register' ) { switch( $wpmem_regchk ) { @@ -272,7 +272,7 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) break; } - } elseif( $wpmem_a == 'pwdreset' ) { + } elseif ( $wpmem_a == 'pwdreset' ) { $content = wpmem_page_pwd_reset( $wpmem_regchk, $content ); @@ -282,7 +282,7 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) $content = ( $page == 'register' || WPMEM_NO_REG != 1 ) ? $content . wpmem_inc_registration() : $content; } - } elseif( is_user_logged_in() && $page == 'members-area' ) { + } elseif ( is_user_logged_in() && $page == 'members-area' ) { /** * Filter the default heading in User Profile edit mode. @@ -303,7 +303,7 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) // determine if there are any errors/empty fields - if( $wpmem_regchk == "updaterr" || $wpmem_regchk == "email" ) { + if ( $wpmem_regchk == "updaterr" || $wpmem_regchk == "email" ) { $content = $content . wpmem_inc_regmessage( $wpmem_regchk, $wpmem_themsg ); $content = $content . wpmem_inc_registration( 'edit', $heading ); @@ -331,7 +331,7 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) break; } - } elseif( is_user_logged_in() && $page == 'register' ) { + } elseif ( is_user_logged_in() && $page == 'register' ) { //return wpmem_inc_memberlinks( 'register' ); @@ -341,16 +341,16 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) } - if( $page == 'login' ) { + if ( $page == 'login' ) { $content = ( $wpmem_regchk == "loginfailed" ) ? wpmem_inc_loginfailed() : $content; $content = ( ! is_user_logged_in() ) ? $content . wpmem_inc_login( 'login', $redirect_to ) : wpmem_inc_memberlinks( 'login' ); } - if( $page == 'password' ) { + if ( $page == 'password' ) { $content = wpmem_page_pwd_reset( $wpmem_regchk, $content ); } - if( $page == 'user-edit' ) { + if ( $page == 'user-edit' ) { $content = wpmem_page_user_edit( $wpmem_regchk, $content ); } @@ -361,21 +361,21 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) if ( ! function_exists( 'wpmem_block' ) ): /** - * Determines if content should be blocked + * Determines if content should be blocked. * * @since 2.6 * * @return bool $block */ -function wpmem_block() -{ +function wpmem_block() { + global $post; /** * Backward compatibility for old block/unblock meta */ $meta = get_post_meta( $post->ID, '_wpmem_block', true ); - if( ! $meta ) { + if ( ! $meta ) { // check for old meta $old_block = get_post_meta( $post->ID, 'block', true ); $old_unblock = get_post_meta( $post->ID, 'unblock', true ); @@ -388,7 +388,7 @@ function wpmem_block() 'post_type' => $post->post_type, 'block' => ( ( $post->post_type == 'post' && WPMEM_BLOCK_POSTS == 1 ) || ( $post->post_type == 'page' && WPMEM_BLOCK_PAGES == 1 ) ) ? true : false, 'block_meta' => $meta, // get_post_meta( $post->ID, '_wpmem_block', true ), - 'block_type' => ( $post->post_type == 'post' ) ? WPMEM_BLOCK_POSTS : ( ( $post->post_type == 'page' ) ? WPMEM_BLOCK_PAGES : 0 ) + 'block_type' => ( $post->post_type == 'post' ) ? WPMEM_BLOCK_POSTS : ( ( $post->post_type == 'page' ) ? WPMEM_BLOCK_PAGES : 0 ), ); /** @@ -401,21 +401,21 @@ function wpmem_block() */ $args = apply_filters( 'wpmem_block_args', '', $defaults ); - // merge $args with defaults and extract - extract( wp_parse_args( $args, $defaults ) ); + // merge $args with defaults + $args = ( wp_parse_args( $args, $defaults ) ); - if( is_single() || is_page() ) { - switch( $block_type ) { + if ( is_single() || is_page() ) { + switch( $args['block_type'] ) { case 1: // if content is blocked by default - $block = ( $block_meta == '0' ) ? false : $block; + $args['block'] = ( $args['block_meta'] == '0' ) ? false : $args['block']; break; case 0 : // if content is unblocked by default - $block = ( $block_meta == '1' ) ? true : $block; + $args['block'] = ( $args['block_meta'] == '1' ) ? true : $args['block']; break; } } else { - $block = false; + $args['block'] = false; } @@ -424,21 +424,21 @@ function wpmem_block() * * @since 2.7.5 * - * @param bool $block + * @param bool $args['block'] * @param array $args */ - return apply_filters( 'wpmem_block', $block, $args ); + return apply_filters( 'wpmem_block', $args['block'], $args ); } endif; if ( ! function_exists( 'wpmem_shortcode' ) ): /** - * Executes various shortcodes + * Executes various shortcodes. * - * This function executes shortcodes for pages (settings, register, login, user-list, + * This function executes shortcodes for pages (settings, register, login, user-list, * and tos pages), as well as login status and field attributes when the wp-members tag - * is used. Also executes shortcodes for login status with the wpmem_logged_in tags + * is used. Also executes shortcodes for login status with the wpmem_logged_in tags * and fields when the wpmem_field tags are used. * * @since 2.4 @@ -448,8 +448,8 @@ function wpmem_block() * @param string $tag * @return string returns the result of wpmem_do_sc_pages|wpmem_list_users|wpmem_sc_expmessage|$content */ -function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) -{ +function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { + // set all default attributes to false $defaults = array( 'page' => false, @@ -459,29 +459,27 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) 'msg' => false, 'field' => false, 'id' => false, - 'underscores' => 'off' + 'underscores' => 'off', ); - // merge defaults with $attr and extract - extract( shortcode_atts( $defaults, $attr, $tag ) ); + // merge defaults with $attr + $atts = shortcode_atts( $defaults, $attr, $tag ); // handles the 'page' attribute - if( $page ) { - if( $page == 'user-list' ) { - //return ( function_exists( 'wpmem_list_users' ) ) ? do_shortcode( wpmem_list_users( $attr, $content ) ) : ''; - if( function_exists( 'wpmem_list_users' ) ) { + if ( $atts['page'] ) { + if ( $atts['page'] == 'user-list' ) { + if ( function_exists( 'wpmem_list_users' ) ) { $content = do_shortcode( wpmem_list_users( $attr, $content ) ); } - } elseif( $page == 'tos' ) { - return $url; + } elseif ( $atts['page'] == 'tos' ) { + return $atts['url']; } else { - //return do_shortcode( wpmem_do_sc_pages( $page ) ); - $content = do_shortcode( wpmem_do_sc_pages( $page, $redirect_to ) ); + $content = do_shortcode( wpmem_do_sc_pages( $atts['page'], $atts['redirect_to'] ) ); } // resolve any texturize issues... - if( strstr( $content, '[wpmem_txt]' ) ) { - // fix the wptexturize + if ( strstr( $content, '[wpmem_txt]' ) ) { + // fixes the wptexturize remove_filter( 'the_content', 'wpautop' ); remove_filter( 'the_content', 'wptexturize' ); add_filter( 'the_content', 'wpmem_texturize', 99 ); @@ -490,28 +488,28 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) } // handles the 'status' attribute - if( ( $status ) || $tag == 'wpmem_logged_in' ) { + if ( ( $atts['status'] ) || $tag == 'wpmem_logged_in' ) { $do_return = false; // if using the wpmem_logged_in tag with no attributes & the user is logged in - if( $tag == 'wpmem_logged_in' && ( ! $attr ) && is_user_logged_in() ) + if ( $tag == 'wpmem_logged_in' && ( ! $attr ) && is_user_logged_in() ) $do_return = true; // if there is a status attribute of "in" and the user is logged in - if( $status == 'in' && is_user_logged_in() ) + if ( $atts['status'] == 'in' && is_user_logged_in() ) $do_return = true; // if there is a status attribute of "out" and the user is not logged in - if( $status == 'out' && ! is_user_logged_in() ) + if ( $atts['status'] == 'out' && ! is_user_logged_in() ) $do_return = true; // if there is a status attribute of "sub" and the user is logged in - if( $status == 'sub' && is_user_logged_in() ) { - if( WPMEM_USE_EXP == 1 ) { - if( ! wpmem_chk_exp() ) { + if ( $atts['status'] == 'sub' && is_user_logged_in() ) { + if ( WPMEM_USE_EXP == 1 ) { + if ( ! wpmem_chk_exp() ) { $do_return = true; - } elseif( $msg == true ) { + } elseif ( $atts['msg'] == true ) { $do_return = true; $content = wpmem_sc_expmessage(); } @@ -523,18 +521,18 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) } // handles the wpmem_logged_out tag with no attributes & the user is not logged in - if( $tag == 'wpmem_logged_out' && ( ! $attr ) && ! is_user_logged_in() ) { + if ( $tag == 'wpmem_logged_out' && ( ! $attr ) && ! is_user_logged_in() ) { return do_shortcode( $content ); } // handles the 'field' attribute - if( $field || $tag == 'wpmem_field' ) { - if( $id ) { + if ( $atts['field'] || $tag == 'wpmem_field' ) { + if ( $atts['id'] ) { // we are getting some other user - if( $id == 'get' ) { + if ( $atts['id'] == 'get' ) { $the_user_ID = ( isset( $_GET['uid'] ) ) ? $_GET['uid'] : ''; } else { - $the_user_ID = $id; + $the_user_ID = $atts['id']; } } else { // get the current user @@ -542,18 +540,16 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) } $user_info = get_userdata( $the_user_ID ); - if( $underscores == 'off' && $user_info ) { - $user_info->$field = str_replace( '_', ' ', $user_info->$field ); + if ( $atts['underscores'] == 'off' && $user_info ) { + $user_info->$atts['field'] = str_replace( '_', ' ', $user_info->$atts['field'] ); } - // @todo - check this change - return ( $user_info ) ? htmlspecialchars( $user_info->$field ) . do_shortcode( $content ) : do_shortcode( $content ); - // return ( $user_info ) ? htmlspecialchars( $user_info->$field ) . do_shortcode( $content ) : ''; + return ( $user_info ) ? htmlspecialchars( $user_info->$atts['field'] ) . do_shortcode( $content ) : do_shortcode( $content ); } // logout link shortcode - if( is_user_logged_in() && $tag == 'wpmem_logout' ) { - $link = ( $url ) ? wpmem_chk_qstr( $url ) . 'a=logout' : wpmem_chk_qstr( get_permalink() ) . 'a=logout'; + if ( is_user_logged_in() && $tag == 'wpmem_logout' ) { + $link = ( $atts['url'] ) ? wpmem_chk_qstr( $atts['url'] ) . 'a=logout' : wpmem_chk_qstr( get_permalink() ) . 'a=logout'; $text = ( $content ) ? $content : __( 'Click here to log out.', 'wp-members' ); return do_shortcode( "$text" ); } @@ -562,9 +558,9 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) endif; -if( ! function_exists( 'wpmem_check_activated' ) ): +if ( ! function_exists( 'wpmem_check_activated' ) ): /** - * Checks if a user is activated + * Checks if a user is activated. * * @since 2.7.1 * @@ -574,18 +570,18 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) * @uses wp_check_password * @return int $user */ -function wpmem_check_activated( $user, $username, $password ) -{ +function wpmem_check_activated( $user, $username, $password ) { + // password must be validated $pass = ( ( ! is_wp_error( $user ) ) && $password ) ? wp_check_password( $password, $user->user_pass, $user->ID ) : false; - if( ! $pass ) { - return $user; + if ( ! $pass ) { + return $user; } // activation flag must be validated $active = get_user_meta( $user->ID, 'active', true ); - if( $active != 1 ) { + if ( $active != 1 ) { return new WP_Error( 'authentication_failed', __( 'ERROR: User has not been activated.', 'wp-members' ) ); } @@ -595,9 +591,9 @@ function wpmem_check_activated( $user, $username, $password ) endif; -if( ! function_exists( 'wpmem_login' ) ): +if ( ! function_exists( 'wpmem_login' ) ): /** - * Logs in the user + * Logs in the user. * * Logs in the the user using wp_signon (since 2.5.2). If login is * successful, it will set a cookie using wp_set_auth_cookie (since 2.7.7), @@ -607,12 +603,12 @@ function wpmem_check_activated( $user, $username, $password ) * * @uses wp_signon * @uses wp_set_auth_cookie - * @uses wp_redirect Redirects to $redirect_to if login is successful - * @return string Returns "loginfailed" if the login fails + * @uses wp_redirect Redirects to $redirect_to if login is successful. + * @return string Returns "loginfailed" if the login fails. */ -function wpmem_login() -{ - if( $_POST['log'] && $_POST['pwd'] ) { +function wpmem_login() { + + if ( $_POST['log'] && $_POST['pwd'] ) { /** get username and sanitize */ $user_login = sanitize_user( $_POST['log'] ); @@ -630,7 +626,7 @@ function wpmem_login() $user = wp_signon( $creds, false ); /** if no error, user is a valid signon. continue */ - if( ! is_wp_error( $user ) ) { + if ( ! is_wp_error( $user ) ) { /** set the auth cookie */ wp_set_auth_cookie( $user->ID, $rememberme ); @@ -705,16 +701,16 @@ function wpmem_logout() { if ( ! function_exists( 'wpmem_login_status' ) ): /** - * Displays the user's login status + * Displays the user's login status. * * @since 2.0 * - * @uses wpmem_inc_memberlinks(). - * @param boolean $echo Determines whether function should print result or not (default: true). - * @return string $status The user status string produced by wpmem_inc_memberlinks(). + * @uses wpmem_inc_memberlinks() + * @param boolean $echo Determines whether function should print result or not (default: true). + * @return string $status The user status string produced by wpmem_inc_memberlinks(). */ -function wpmem_login_status( $echo = true ) -{ +function wpmem_login_status( $echo = true ) { + include_once( 'wp-members-dialogs.php' ); if ( is_user_logged_in() ) { $status = wpmem_inc_memberlinks( 'status' ); @@ -729,14 +725,13 @@ function wpmem_login_status( $echo = true ) if ( ! function_exists( 'wpmem_inc_sidebar' ) ): /** - * Displays the sidebar + * Displays the sidebar. * * @since 2.0 * * @uses wpmem_do_sidebar() */ -function wpmem_inc_sidebar() -{ +function wpmem_inc_sidebar() { include_once('wp-members-sidebar.php'); wpmem_do_sidebar(); } @@ -745,14 +740,13 @@ function wpmem_inc_sidebar() if ( ! function_exists( 'widget_wpmemwidget_init' ) ): /** - * Initializes the widget + * Initializes the widget. * * @since 2.0 * * @uses register_widget */ -function widget_wpmemwidget_init() -{ +function widget_wpmemwidget_init() { include_once( 'wp-members-sidebar.php' ); register_widget( 'widget_wpmemwidget' ); } @@ -761,17 +755,17 @@ function widget_wpmemwidget_init() if ( ! function_exists( 'wpmem_change_password' ) ): /** - * Handles user password change (not reset) + * Handles user password change (not reset). * * @since 2.1 * * @global $user_ID * @return string the value for $wpmem_regchk */ -function wpmem_change_password() -{ +function wpmem_change_password() { + global $user_ID; - if( isset( $_POST['formsubmit'] ) ) { + if ( isset( $_POST['formsubmit'] ) ) { $pass1 = $_POST['pass1']; $pass2 = $_POST['pass2']; @@ -806,9 +800,9 @@ function wpmem_change_password() endif; -if( ! function_exists( 'wpmem_reset_password' ) ): +if ( ! function_exists( 'wpmem_reset_password' ) ): /** - * Resets a forgotten password + * Resets a forgotten password. * * @since 2.1 * @@ -816,9 +810,9 @@ function wpmem_change_password() * @uses wp_update_user * @return string value for $wpmem_regchk */ -function wpmem_reset_password() -{ - if( isset( $_POST['formsubmit'] ) ) { +function wpmem_reset_password() { + + if ( isset( $_POST['formsubmit'] ) ) { /** * Filter the password reset arguments. @@ -829,21 +823,21 @@ function wpmem_reset_password() */ $arr = apply_filters( 'wpmem_pwdreset_args', array( 'user' => ( isset( $_POST['user'] ) ) ? $_POST['user'] : '', - 'email' => ( isset( $_POST['email'] ) ) ? $_POST['email'] : '' + 'email' => ( isset( $_POST['email'] ) ) ? $_POST['email'] : '', ) ); - if( ! $arr['user'] || ! $arr['email'] ) { + if ( ! $arr['user'] || ! $arr['email'] ) { // there was an empty field return "pwdreseterr"; } else { - if( username_exists( $arr['user'] ) ) { + if ( username_exists( $arr['user'] ) ) { $user = get_user_by( 'login', $arr['user'] ); - if( strtolower( $user->user_email ) !== strtolower( $arr['email'] ) || ( ( WPMEM_MOD_REG == 1 ) && ( get_user_meta( $user->ID,'active', true ) != 1 ) ) ) { + if ( strtolower( $user->user_email ) !== strtolower( $arr['email'] ) || ( ( WPMEM_MOD_REG == 1 ) && ( get_user_meta( $user->ID,'active', true ) != 1 ) ) ) { // the username was there, but the email did not match OR the user hasn't been activated return "pwdreseterr"; @@ -882,7 +876,7 @@ function wpmem_reset_password() endif; -if( ! function_exists( 'wpmem_no_reset' ) ): +if ( ! function_exists( 'wpmem_no_reset' ) ): /** * Keeps users not activated from resetting their password * via wp-login when using registration moderation. @@ -893,15 +887,15 @@ function wpmem_reset_password() */ function wpmem_no_reset() { - if( strpos( $_POST['user_login'], '@' ) ) { + if ( strpos( $_POST['user_login'], '@' ) ) { $user = get_user_by( 'email', trim( $_POST['user_login'] ) ); } else { $username = trim( $_POST['user_login'] ); $user = get_user_by( 'login', $username ); } - if( WPMEM_MOD_REG == 1 ) { - if( get_user_meta( $user->ID, 'active', true ) != 1 ) { + if ( WPMEM_MOD_REG == 1 ) { + if ( get_user_meta( $user->ID, 'active', true ) != 1 ) { return false; } } @@ -912,7 +906,7 @@ function wpmem_no_reset() { /** - * Anything that gets added to the the + * Anything that gets added to the the . * * @since 2.2 */ @@ -922,7 +916,7 @@ function wpmem_head() { /** - * Add registration fields to the native WP registration + * Add registration fields to the native WP registration. * * @since 2.8.3 */ @@ -933,7 +927,7 @@ function wpmem_wp_register_form() { /** - * Validates registration fields in the native WP registration + * Validates registration fields in the native WP registration. * * @since 2.8.3 * @@ -942,21 +936,21 @@ function wpmem_wp_register_form() { * @param $user_email * @return $errors */ -function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) -{ +function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) { + $wpmem_fields = get_option( 'wpmembers_fields' ); $exclude = wpmem_get_excluded_meta( 'register' ); - foreach( $wpmem_fields as $field ) { + foreach ( $wpmem_fields as $field ) { $is_error = false; - if( $field[5] == 'y' && $field[2] != 'user_email' && ! in_array( $field[2], $exclude ) ) { - if( ( $field[3] == 'checkbox' ) && ( ! isset( $_POST[$field[2]] ) ) ) { + if ( $field[5] == 'y' && $field[2] != 'user_email' && ! in_array( $field[2], $exclude ) ) { + if ( ( $field[3] == 'checkbox' ) && ( ! isset( $_POST[$field[2]] ) ) ) { $is_error = true; } - if( ( $field[3] != 'checkbox' ) && ( ! $_POST[$field[2]] ) ) { + if ( ( $field[3] != 'checkbox' ) && ( ! $_POST[$field[2]] ) ) { $is_error = true; } - if( $is_error ) { $errors->add( 'wpmem_error', sprintf( __('Sorry, %s is a required field.', 'wp-members'), $field[1] ) ); } + if ( $is_error ) { $errors->add( 'wpmem_error', sprintf( __('Sorry, %s is a required field.', 'wp-members'), $field[1] ) ); } } } @@ -965,22 +959,22 @@ function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) /** - * Inserts registration data from the native WP registration + * Inserts registration data from the native WP registration. * * @since 2.8.3 * * @param $user_id */ -function wpmem_wp_reg_finalize( $user_id ) -{ +function wpmem_wp_reg_finalize( $user_id ) { + $native_reg = ( isset( $_POST['wp-submit'] ) && $_POST['wp-submit'] == esc_attr( __( 'Register' ) ) ) ? true : false; $add_new = ( isset( $_POST['action'] ) && $_POST['action'] == 'createuser' ) ? true : false; - if( $native_reg || $add_new ) { + if ( $native_reg || $add_new ) { // get the fields $wpmem_fields = get_option( 'wpmembers_fields' ); // get any excluded meta fields $exclude = wpmem_get_excluded_meta( 'register' ); - foreach( $wpmem_fields as $meta ) { + foreach ( $wpmem_fields as $meta ) { if ( isset( $_POST[$meta[2]] ) && ! in_array( $meta[2], $exclude ) ) { update_user_meta( $user_id, $meta[2], sanitize_text_field( $_POST[$meta[2]] ) ); } @@ -991,7 +985,7 @@ function wpmem_wp_reg_finalize( $user_id ) /** - * Loads the stylesheet for backend registration + * Loads the stylesheet for backend registration. * * @since 2.8.7 */ diff --git a/wp-members-dialogs.php b/wp-members-dialogs.php index 5ff3bbc2..cd7352ae 100644 --- a/wp-members-dialogs.php +++ b/wp-members-dialogs.php @@ -17,23 +17,23 @@ /** - * include the form building functions + * Include the form building functions. */ include_once( 'forms.php' ); if ( ! function_exists( 'wpmem_inc_loginfailed' ) ): /** - * Login Failed Dialog + * Login Failed Dialog. * * Returns the login failed error message. * * @since 1.8 * - * @return string $str the generated html for the login failed message + * @return string $str the generated html for the login failed message. */ -function wpmem_inc_loginfailed() -{ +function wpmem_inc_loginfailed() { + // defaults $defaults = array( 'div_before' => '
', @@ -44,7 +44,7 @@ function wpmem_inc_loginfailed() 'p_before' => '

', 'message' => __( 'You entered an invalid username or password.', 'wp-members' ), 'p_after' => '

', - 'link' => '' . __( 'Click here to continue.', 'wp-members' ) . '' + 'link' => '' . __( 'Click here to continue.', 'wp-members' ) . '', ); /** @@ -56,14 +56,14 @@ function wpmem_inc_loginfailed() */ $args = apply_filters( 'wpmem_login_failed_args', '' ); - // merge $args with defaults and extract - extract( wp_parse_args( $args, $defaults ) ); + // merge $args with defaults + $args = wp_parse_args( $args, $defaults ); - $str = $div_before - . $heading_before . $heading . $heading_after - . $p_before . $message . $p_after - . $p_before . $link . $p_after - . $div_after; + $str = $args['div_before'] + . $args['heading_before'] . $args['heading'] . $args['heading_after'] + . $args['p_before'] . $args['message'] . $args['p_after'] + . $args['p_before'] . $args['link'] . $args['p_after'] + . $args['div_after']; /** * Filter the login failed dialog. @@ -81,34 +81,34 @@ function wpmem_inc_loginfailed() if ( ! function_exists( 'wpmem_inc_regmessage' ) ): /** - * Message Dialog + * Message Dialog. * * Returns various dialogs and error messages. * * @since 1.8 * - * @param string $toggle error message toggle to look for specific error messages - * @param string $msg a message that has no toggle that is passed directly to the function - * @return string $str The final HTML for the message + * @param string $toggle Error message toggle to look for specific error messages. + * @param string $msg A message that has no toggle that is passed directly to the function. + * @return string $str The final HTML for the message. */ -function wpmem_inc_regmessage( $toggle, $msg = '' ) -{ +function wpmem_inc_regmessage( $toggle, $msg = '' ) { + // defaults $defaults = array( 'div_before' => '
', 'div_after' => '
', 'p_before' => '

', 'p_after' => '

', - 'toggles' => array( - 'user', - 'email', - 'success', - 'editsuccess', - 'pwdchangerr', - 'pwdchangesuccess', - 'pwdreseterr', - 'pwdresetsuccess' - ) + 'toggles' => array( + 'user', + 'email', + 'success', + 'editsuccess', + 'pwdchangerr', + 'pwdchangesuccess', + 'pwdreseterr', + 'pwdresetsuccess', + ), ); /** @@ -123,8 +123,8 @@ function wpmem_inc_regmessage( $toggle, $msg = '' ) // get dialogs set in the db $dialogs = get_option( 'wpmembers_dialogs' ); - for( $r = 0; $r < count( $defaults['toggles'] ); $r++ ) { - if( $toggle == $defaults['toggles'][$r] ) { + for ( $r = 0; $r < count( $defaults['toggles'] ); $r++ ) { + if ( $toggle == $defaults['toggles'][$r] ) { $msg = __( stripslashes( $dialogs[$r+1] ), 'wp-members' ); break; } @@ -141,10 +141,10 @@ function wpmem_inc_regmessage( $toggle, $msg = '' ) */ $defaults = apply_filters( 'wpmem_msg_dialog_arr', $defaults, $toggle ); - // merge $args with defaults and extract - extract( wp_parse_args( $args, $defaults ) ); + // merge $args with defaults + $args = wp_parse_args( $args, $defaults ); - $str = $div_before . $p_before . stripslashes( $msg ) . $p_after . $div_after; + $str = $args['div_before'] . $args['p_before'] . stripslashes( $msg ) . $args['p_after'] . $args['div_after']; /** * Filter the message. @@ -159,9 +159,9 @@ function wpmem_inc_regmessage( $toggle, $msg = '' ) endif; -if( ! function_exists( 'wpmem_inc_memberlinks' ) ): +if ( ! function_exists( 'wpmem_inc_memberlinks' ) ): /** - * Member Links Dialog + * Member Links Dialog. * * Outputs the links used on the members area. * @@ -170,8 +170,8 @@ function wpmem_inc_regmessage( $toggle, $msg = '' ) * @param string $page * @return string $str */ -function wpmem_inc_memberlinks( $page = 'members' ) -{ +function wpmem_inc_memberlinks( $page = 'members' ) { + global $user_login; $link = wpmem_chk_qstr(); @@ -185,12 +185,12 @@ function wpmem_inc_memberlinks( $page = 'members' ) */ $logout = apply_filters( 'wpmem_logout_link', $link . 'a=logout' ); - switch( $page ) { + switch ( $page ) { case 'members': $str = ''; /** * Filter the links displayed on the User Profile page (logged in state). @@ -291,7 +291,7 @@ function wpmem_inc_memberlinks( $page = 'members' ) if ( ! function_exists( 'wpmem_page_pwd_reset' ) ): /** - * Password reset forms + * Password reset forms. * * This function creates both password reset and forgotten * password forms for page=password shortcode. @@ -302,11 +302,11 @@ function wpmem_inc_memberlinks( $page = 'members' ) * @param string $content * @return string $content */ -function wpmem_page_pwd_reset( $wpmem_regchk, $content ) -{ - if( is_user_logged_in() ) { +function wpmem_page_pwd_reset( $wpmem_regchk, $content ) { + + if ( is_user_logged_in() ) { - switch( $wpmem_regchk ) { + switch ( $wpmem_regchk ) { case "pwdchangempty": $content = wpmem_inc_regmessage( $wpmem_regchk, __( 'Password fields cannot be empty', 'wp-members' ) ); @@ -358,7 +358,7 @@ function wpmem_page_pwd_reset( $wpmem_regchk, $content ) if ( ! function_exists( 'wpmem_page_user_edit' ) ): /** - * Creates a user edit page + * Creates a user edit page. * * @since 2.7.6 * @@ -366,8 +366,8 @@ function wpmem_page_pwd_reset( $wpmem_regchk, $content ) * @param string $content * @return string $content */ -function wpmem_page_user_edit( $wpmem_regchk, $content ) -{ +function wpmem_page_user_edit( $wpmem_regchk, $content ) { + global $wpmem_a, $wpmem_themsg; /** * Filter the default User Edit heading for shortcode. @@ -378,11 +378,11 @@ function wpmem_page_user_edit( $wpmem_regchk, $content ) */ $heading = apply_filters( 'wpmem_user_edit_heading', __( 'Edit Your Information', 'wp-members' ) ); - if( $wpmem_a == "update") { $content.= wpmem_inc_regmessage( $wpmem_regchk, $wpmem_themsg ); } + if ( $wpmem_a == "update") { $content.= wpmem_inc_regmessage( $wpmem_regchk, $wpmem_themsg ); } $content = $content . wpmem_inc_registration( 'edit', $heading ); return $content; } endif; -/** End of File **/ +/** End of File **/ \ No newline at end of file From b8eba41e1d4aded22bbdae5215b7321c081b1d00 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 6 Apr 2015 17:48:18 -0500 Subject: [PATCH 0035/1694] code standards --- forms.php | 151 ++++++++++++++++++++--------------------- wp-members-sidebar.php | 45 ++++++------ 2 files changed, 94 insertions(+), 102 deletions(-) diff --git a/forms.php b/forms.php index 30ea95de..21ef5021 100644 --- a/forms.php +++ b/forms.php @@ -1,6 +1,6 @@ 'text', 'tag' => 'log', 'class' => 'username', - 'div' => 'div_text' + 'div' => 'div_text', ), array( 'name' => __( 'Password' ), 'type' => 'password', 'tag' => 'pwd', 'class' => 'password', - 'div' => 'div_text' - ) + 'div' => 'div_text', + ), ); /** @@ -97,7 +97,7 @@ function wpmem_inc_login( $page="page", $redirect_to = null ) 'action' => 'login', 'button_text' => __( 'Log In' ), 'inputs' => $default_inputs, - 'redirect_to' => $redirect_to + 'redirect_to' => $redirect_to, ); /** @@ -120,7 +120,7 @@ function wpmem_inc_login( $page="page", $redirect_to = null ) if ( ! function_exists( 'wpmem_inc_changepassword' ) ): /** - * Change Password Dialog + * Change Password Dialog. * * Loads the form for changing password. * @@ -128,10 +128,10 @@ function wpmem_inc_login( $page="page", $redirect_to = null ) * * @uses wpmem_login_form() * - * @return string $str the generated html for the change password form + * @return string $str the generated html for the change password form. */ -function wpmem_inc_changepassword() -{ +function wpmem_inc_changepassword() { + /** create the default inputs **/ $default_inputs = array( array( @@ -139,15 +139,15 @@ function wpmem_inc_changepassword() 'type' => 'password', 'tag' => 'pass1', 'class' => 'password', - 'div' => 'div_text' + 'div' => 'div_text', ), array( 'name' => __( 'Confirm new password' ), 'type' => 'password', 'tag' => 'pass2', 'class' => 'password', - 'div' => 'div_text' - ) + 'div' => 'div_text', + ), ); /** @@ -163,7 +163,7 @@ function wpmem_inc_changepassword() 'heading' => __('Change Password', 'wp-members'), 'action' => 'pwdchange', 'button_text' => __('Update Password', 'wp-members'), - 'inputs' => $default_inputs + 'inputs' => $default_inputs, ); /** @@ -186,7 +186,7 @@ function wpmem_inc_changepassword() if ( ! function_exists( 'wpmem_inc_resetpassword' ) ): /** - * Reset Password Dialog + * Reset Password Dialog. * * Loads the form for resetting password. * @@ -194,7 +194,7 @@ function wpmem_inc_changepassword() * * @uses wpmem_login_form() * - * @return string $str the generated html fo the reset password form + * @return string $str the generated html fo the reset password form. */ function wpmem_inc_resetpassword() { @@ -205,15 +205,15 @@ function wpmem_inc_resetpassword() 'type' => 'text', 'tag' => 'user', 'class' => 'username', - 'div' => 'div_text' + 'div' => 'div_text', ), array( 'name' => __( 'Email' ), 'type' => 'text', 'tag' => 'email', 'class' => 'password', - 'div' => 'div_text' - ) + 'div' => 'div_text', + ), ); /** @@ -229,7 +229,7 @@ function wpmem_inc_resetpassword() 'heading' => __( 'Reset Forgotten Password', 'wp-members' ), 'action' => 'pwdreset', 'button_text' => __( 'Reset Password' ), - 'inputs' => $default_inputs + 'inputs' => $default_inputs, ); /** @@ -252,18 +252,18 @@ function wpmem_inc_resetpassword() if ( ! function_exists( 'wpmem_login_form' ) ): /** - * Login Form Dialog + * Login Form Dialog. * * Builds the form used for login, change password, and reset password. * * @since 2.5.1 * * @param string $page - * @param array $arr The elements needed to generate the form (login|reset password|forgotten password) - * @return string $form The HTML for the form as a string + * @param array $arr The elements needed to generate the form (login|reset password|forgotten password). + * @return string $form The HTML for the form as a string. */ -function wpmem_login_form( $page, $arr ) -{ +function wpmem_login_form( $page, $arr ) { + // extract the arguments array extract( $arr ); @@ -298,7 +298,7 @@ function wpmem_login_form( $page, $arr ) 'remember_check' => true, 'n' => "\n", 't' => "\t", - 'redirect_to' => ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : ( ( isset( $redirect_to ) ) ? $redirect_to : get_permalink() ) + 'redirect_to' => ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : ( ( isset( $redirect_to ) ) ? $redirect_to : get_permalink() ), ); @@ -315,7 +315,7 @@ function wpmem_login_form( $page, $arr ) */ $args = apply_filters( 'wpmem_login_form_args', '', $action ); - // merge $args with defaults and extract + // merge $args with defaults extract( wp_parse_args( $args, $defaults ) ); // build the input rows @@ -330,7 +330,7 @@ function wpmem_login_form( $page, $arr ) 'field_before' => $field_before, 'field' => $field, 'field_after' => $field_after, - 'row_after' => $row_after + 'row_after' => $row_after, ); } @@ -350,7 +350,7 @@ function wpmem_login_form( $page, $arr ) // put the rows from the array into $form $form = ''; - foreach( $rows as $row_item ) { + foreach ( $rows as $row_item ) { $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $n . $row_item['label'] . $n : $row_item['label'] . $n; $row .= ( $row_item['field_before'] != '' ) ? $row_item['field_before'] . $n . $t . $row_item['field'] . $n . $row_item['field_after'] . $n : $row_item['field'] . $n; $row .= ( $row_item['row_before'] != '' ) ? $row_item['row_after'] . $n : ''; @@ -474,20 +474,20 @@ function wpmem_login_form( $page, $arr ) if ( ! function_exists( 'wpmem_inc_registration' ) ): /** - * Registration Form Dialog + * Registration Form Dialog. * * Outputs the form for new user registration and existing user edits. * * @since 2.5.1 * - * @param string $toggle (optional) Toggles between new registration ('new') and user profile edit ('edit') - * @param string $heading (optional) The heading text for the form, null (default) for new registration - * @global string $wpmem_regchk Used to determine if the form is in an error state - * @global array $userdata Used to get the user's registration data if they are logged in (user profile edit) - * @return string $form The HTML for the entire form as a string + * @param string $toggle (optional) Toggles between new registration ('new') and user profile edit ('edit'). + * @param string $heading (optional) The heading text for the form, null (default) for new registration. + * @global string $wpmem_regchk Used to determine if the form is in an error state. + * @global array $userdata Used to get the user's registration data if they are logged in (user profile edit). + * @return string $form The HTML for the entire form as a string. */ -function wpmem_inc_registration( $toggle = 'new', $heading = '' ) -{ +function wpmem_inc_registration( $toggle = 'new', $heading = '' ) { + global $wpmem_regchk, $userdata; // set up default wrappers @@ -547,11 +547,11 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) */ $args = apply_filters( 'wpmem_register_form_args', '', $toggle ); - // merge $args with defaults and extract + // merge $args with defaults extract( wp_parse_args( $args, $defaults ) ); // Username is editable if new reg, otherwise user profile is not - if( $toggle == 'edit' ) { + if ( $toggle == 'edit' ) { // this is the User Profile edit - username is not editable $val = $userdata->user_login; $label = ''; @@ -579,7 +579,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) 'field_before' => $field_before, 'field' => $input, 'field_after' => $field_after, - 'row_after' => $row_after + 'row_after' => $row_after, ); /** @@ -599,8 +599,8 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) //$wpmem_fields = get_option( 'wpmembers_fields' ); // loop through the remaining fields - foreach( $wpmem_fields as $field ) - { + foreach ( $wpmem_fields as $field ) { + // start with a clean row $val = ''; $label = ''; $input = ''; $field_before = ''; $field_after = ''; @@ -609,16 +609,16 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) $do_row = ( $toggle == 'edit' && in_array( $field[2], $pass_arr ) ) ? false : true; // skips tos, makes tos field hidden on user edit page, unless they haven't got a value for tos - if( $field[2] == 'tos' && $toggle == 'edit' && ( get_user_meta( $userdata->ID, 'tos', true ) ) ) { + if ( $field[2] == 'tos' && $toggle == 'edit' && ( get_user_meta( $userdata->ID, 'tos', true ) ) ) { $do_row = false; $hidden_tos = wpmem_create_formfield( $field[2], 'hidden', get_user_meta( $userdata->ID, 'tos', true ) ); } // if the field is set to display and we aren't skipping, construct the row - if( $field[4] == 'y' && $do_row == true ) { + if ( $field[4] == 'y' && $do_row == true ) { // label for all but TOS - if( $field[2] != 'tos' ) { + if ( $field[2] != 'tos' ) { $class = ( $field[3] == 'password' ) ? 'text' : $field[3]; @@ -629,9 +629,9 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) } // gets the field value for both edit profile and submitted reg w/ error - if( ( $toggle == 'edit' ) && ( $wpmem_regchk != 'updaterr' ) ) { + if ( ( $toggle == 'edit' ) && ( $wpmem_regchk != 'updaterr' ) ) { - switch( $field[2] ) { + switch ( $field[2] ) { case( 'description' ): $val = htmlspecialchars( get_user_meta( $userdata->ID, 'description', 'true' ) ); break; @@ -657,7 +657,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) } // does the tos field - if( $field[2] == 'tos' ) { + if ( $field[2] == 'tos' ) { $val = ( isset( $_POST[ $field[2] ] ) ) ? $_POST[ $field[2] ] : ''; @@ -692,20 +692,20 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) } else { // for checkboxes - if( $field[3] == 'checkbox' ) { + if ( $field[3] == 'checkbox' ) { $valtochk = $val; $val = $field[7]; // if it should it be checked by default (& only if form not submitted), then override above... - if( $field[8] == 'y' && ( ! $_POST && $toggle != 'edit' ) ) { $val = $valtochk = $field[7]; } + if ( $field[8] == 'y' && ( ! $_POST && $toggle != 'edit' ) ) { $val = $valtochk = $field[7]; } } // for dropdown select - if( $field[3] == 'select' ) { + if ( $field[3] == 'select' ) { $valtochk = $val; $val = $field[7]; } - if( ! isset( $valtochk ) ) { $valtochk = ''; } + if ( ! isset( $valtochk ) ) { $valtochk = ''; } // for all other input types $input = wpmem_create_formfield( $field[2], $field[3], $val, $valtochk ); @@ -718,7 +718,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) } // if the row is set to display, add the row to the form array - if( $field[4] == 'y' ) { + if ( $field[4] == 'y' ) { $rows[$field[2]] = array( 'order' => $field[0], 'meta' => $field[2], @@ -729,14 +729,13 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) 'field_before' => $field_before, 'field' => $input, 'field_after' => $field_after, - 'row_after' => $row_after + 'row_after' => $row_after, ); } } - // if captcha is Really Simple CAPTCHA - if( WPMEM_CAPTCHA == 2 && $toggle != 'edit' ) { + if ( WPMEM_CAPTCHA == 2 && $toggle != 'edit' ) { $row = wpmem_build_rs_captcha(); $rows['captcha'] = array( 'order' => '', @@ -748,12 +747,10 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) 'field_before' => ( $wrap_inputs ) ? '
' : '', 'field' => $row['field'], 'field_after' => ( $wrap_inputs ) ? '
' : '', - 'row_after' => $row_after + 'row_after' => $row_after, ); } - - /** * Filter the array of form rows. * @@ -770,7 +767,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) // put the rows from the array into $form $form = ''; $enctype = ''; - foreach( $rows as $row_item ) { + foreach ( $rows as $row_item ) { $enctype = ( $row_item['type'] == 'file' ) ? "multipart/form-data" : $enctype; $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $n . $row_item['label'] . $n : $row_item['label'] . $n; $row .= ( $row_item['field_before'] != '' ) ? $row_item['field_before'] . $n . $t . $row_item['field'] . $n . $row_item['field_after'] . $n : $row_item['field'] . $n; @@ -779,7 +776,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) } // do recaptcha if enabled - if( WPMEM_CAPTCHA == 1 && $toggle != 'edit' ) { // don't show on edit page! + if ( WPMEM_CAPTCHA == 1 && $toggle != 'edit' ) { // don't show on edit page! // get the captcha options $wpmem_captcha = get_option( 'wpmembers_captcha' ); @@ -914,15 +911,15 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) if ( ! function_exists( 'wpmem_inc_recaptcha' ) ): /** - * Create reCAPTCHA form + * Create reCAPTCHA form. * * @since 2.6.0 * * @param array $arr * @return string $str */ -function wpmem_inc_recaptcha( $arr ) -{ +function wpmem_inc_recaptcha( $arr ) { + // determine if reCAPTCHA should be another language $allowed_langs = array( 'nl', 'fr', 'de', 'pt', 'ru', 'es', 'tr' ); $compare_lang = strtolower( substr( WPLANG, -2 ) ); @@ -957,14 +954,14 @@ function wpmem_inc_recaptcha( $arr ) /** - * Create an attribution link in the form + * Create an attribution link in the form. * * @since 2.6.0 * * @return string $str */ -function wpmem_inc_attribution() -{ +function wpmem_inc_attribution() { + $http = ( is_ssl() ) ? 'https://' : 'http://'; $str = '
@@ -982,9 +979,9 @@ function wpmem_inc_attribution() * * @return array Form elements for Really Simple CAPTCHA. */ -function wpmem_build_rs_captcha() -{ - if( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { +function wpmem_build_rs_captcha() { + + if ( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { // setup defaults $defaults = array( 'characters' => 'ABCDEFGHJKLMNPQRSTUVWXYZ23456789', @@ -995,7 +992,7 @@ function wpmem_build_rs_captcha() 'bg_color' => '255,255,255', 'font_size' => '12', 'kerning' => '14', - 'img_type' => 'png' + 'img_type' => 'png', ); $wpmem_captcha = get_option( 'wpmembers_captcha' ); diff --git a/wp-members-sidebar.php b/wp-members-sidebar.php index 177e6fe9..82e0671d 100644 --- a/wp-members-sidebar.php +++ b/wp-members-sidebar.php @@ -1,6 +1,6 @@ '; - if( WPMEM_MSURL != null ) { + if ( WPMEM_MSURL != null ) { /** * Filter the sidebar forgot password link. * @@ -175,7 +175,7 @@ function wpmem_do_sidebar( $post_to = null ) $buttons.= ' ' . __( 'Forgot?', 'wp-members' ) . ' '; } - if( WPMEM_REGURL != null ) { + if ( WPMEM_REGURL != null ) { /** * Filter the sidebar register link. * @@ -209,7 +209,7 @@ function wpmem_do_sidebar( $post_to = null ) $form = apply_filters( 'wpmem_sidebar_form', $form ); $do_error_msg = ''; - if( isset( $_POST['slog'] ) && $wpmem_regchk == 'loginfailed' ) { + if ( isset( $_POST['slog'] ) && $wpmem_regchk == 'loginfailed' ) { $do_error_msg = true; $error_msg = $error_before . $error_msg . $error_after; /** @@ -257,18 +257,16 @@ function wpmem_do_sidebar( $post_to = null ) /** - * Class for the sidebar login widget + * Class for the sidebar login widget. * * @since 2.7 */ -class widget_wpmemwidget extends WP_Widget -{ +class widget_wpmemwidget extends WP_Widget { /** * Sets up the WP-Members login widget. */ - function widget_wpmemwidget() - { + function widget_wpmemwidget() { $widget_ops = array( 'classname' => 'wp-members', 'description' => __( 'Displays the WP-Members sidebar login.', 'wp-members' ) @@ -282,8 +280,7 @@ function widget_wpmemwidget() * * @param array $instance */ - function form( $instance ) - { + function form( $instance ) { /* Default widget settings. */ $defaults = array( @@ -311,8 +308,7 @@ function form( $instance ) * @param array $old_instance * @return array $instance */ - function update( $new_instance, $old_instance ) - { + function update( $new_instance, $old_instance ) { $instance = $old_instance; /* Strip tags for title to remove HTML. */ @@ -328,8 +324,7 @@ function update( $new_instance, $old_instance ) * @param array $args * @param array $instance */ - function widget( $args, $instance ) - { + function widget( $args, $instance ) { extract( $args ); // Get the Widget Title @@ -363,4 +358,4 @@ function widget( $args, $instance ) } } -/** End of File **/ +/** End of File **/ \ No newline at end of file From 9595fd97de23132d5333b3e7268095adbacf9c16 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 7 Apr 2015 17:51:02 +0000 Subject: [PATCH 0036/1694] corrected wpmem_settings_loaded action --- wp-members.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-members.php b/wp-members.php index b64edae0..519142ac 100644 --- a/wp-members.php +++ b/wp-members.php @@ -141,7 +141,7 @@ function wpmem_init() { * * @since 3.0 */ - add_action( 'wpmem_settings_loaded' ); + do_action( 'wpmem_settings_loaded' ); /** * Filter the location and name of the pluggable file. From c63b2acb280da51df8be0303a8dc49ef66378c96 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 7 Apr 2015 16:40:35 -0500 Subject: [PATCH 0037/1694] new 3.0 settings --- admin/admin.php | 112 ++++++++-------- admin/dialogs.php | 22 ++-- admin/tab-emails.php | 4 +- admin/tab-options.php | 288 +++++++++++++++++++++++------------------ uninstall.php | 14 +- wp-members-install.php | 255 ++++++++++++++++-------------------- wp-members.php | 42 +++--- 7 files changed, 372 insertions(+), 365 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index dd2c6641..d0be45a6 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -1,6 +1,6 @@ ' . __( 'Settings' ) . ''; $links = array_merge( array( $settings_link ), $links ); } @@ -65,23 +64,22 @@ function wpmem_admin_plugin_links( $links, $file ) /** - * Loads the admin javascript and css files + * Loads the admin javascript and css files. * * @since 2.5.1 * * @uses wp_enqueue_script * @uses wp_enqueue_style */ -function wpmem_load_admin_js() -{ - // queue up admin ajax and styles - wp_enqueue_script( 'wpmem-admin-js', WPMEM_DIR . '/js/admin.js', '', WPMEM_VERSION ); +function wpmem_load_admin_js() { + // queue up admin ajax and styles + wp_enqueue_script( 'wpmem-admin-js', WPMEM_DIR . '/js/admin.js', '', WPMEM_VERSION ); wp_enqueue_style ( 'wpmem-admin-css', WPMEM_DIR . '/css/admin.css', '', WPMEM_VERSION ); } /** - * Creates the captcha tab + * Creates the captcha tab. * * @since 2.8 * @@ -95,12 +93,12 @@ function wpmem_a_captcha_tab( $tab ) { /** - * Adds the captcha tab + * Adds the captcha tab. * * @since 2.8 * - * @param array $tabs The array of tabs for the admin panel - * @return array The updated array of tabs for the admin panel + * @param array $tabs The array of tabs for the admin panel. + * @return array The updated array of tabs for the admin panel. */ function wpmem_add_captcha_tab( $tabs ) { return array_merge( $tabs, array( 'captcha' => 'Captcha' ) ); @@ -108,16 +106,16 @@ function wpmem_add_captcha_tab( $tabs ) { /** - * Primary admin function + * Primary admin function. * * @since 2.1 */ -function wpmem_admin() -{ +function wpmem_admin() { + $did_update = ( isset( $_POST['wpmem_admin_a'] ) ) ? wpmem_admin_action( $_POST['wpmem_admin_a'] ) : false; $wpmem_settings = get_option( 'wpmembers_settings' ); - if( $wpmem_settings[6] ) { + if ( $wpmem_settings[6] ) { add_filter( 'wpmem_admin_tabs', 'wpmem_add_captcha_tab' ); add_action( 'wpmem_admin_do_tab', 'wpmem_a_captcha_tab', 1, 1 ); } ?> @@ -153,15 +151,15 @@ function wpmem_admin() /** - * Displays the content for default tabs + * Displays the content for default tabs. * * @since 2.8 * - * @param string $tab The tab that we are on and displaying - * @param array $wpmem_settings The array of plugin settings + * @param string $tab The tab that we are on and displaying. + * @param array $wpmem_settings The array of plugin settings. */ -function wpmem_admin_do_tab( $tab, $wpmem_settings ) -{ +function wpmem_admin_do_tab( $tab, $wpmem_settings ) { + switch ( $tab ) { case 'options' : @@ -185,19 +183,19 @@ function wpmem_admin_do_tab( $tab, $wpmem_settings ) /** - * Assemble the tabs for the admin panel + * Assemble the tabs for the admin panel. * * @since 2.8 * - * @param string $current The tab that we are on + * @param string $current The tab that we are on. */ -function wpmem_admin_tabs( $current = 'options' ) -{ - $tabs = array( - 'options' => 'WP-Members ' . __( 'Options', 'wp-members' ), - 'fields' => __( 'Fields', 'wp-members' ), - 'dialogs' => __( 'Dialogs', 'wp-members' ), - 'emails' => __( 'Emails', 'wp-members' ) +function wpmem_admin_tabs( $current = 'options' ) { + + $tabs = array( + 'options' => 'WP-Members ' . __( 'Options', 'wp-members' ), + 'fields' => __( 'Fields', 'wp-members' ), + 'dialogs' => __( 'Dialogs', 'wp-members' ), + 'emails' => __( 'Emails', 'wp-members' ), ); /** @@ -209,56 +207,55 @@ function wpmem_admin_tabs( $current = 'options' ) */ $tabs = apply_filters( 'wpmem_admin_tabs', $tabs ); - $links = array(); - foreach( $tabs as $tab => $name ) { - + $links = array(); + foreach ( $tabs as $tab => $name ) { $class = ( $tab == $current ) ? 'nav-tab nav-tab-active' : 'nav-tab'; $links[] = '' . $name . ''; - } - + echo ''; + foreach ( $links as $link ) { + echo $link; + } + echo ''; } /** - * Handles the various update actions for the default tabs + * Handles the various update actions for the default tabs. * * @since 2.8 * - * @param string $action The action that is being done + * @param string $action The action that is being done. */ -function wpmem_admin_action( $action ) -{ +function wpmem_admin_action( $action ) { + $did_update = ''; // makes sure $did_update is defined - switch( $action ) { + switch ( $action ) { - case( 'update_settings' ): + case 'update_settings': include_once( 'tab-options.php' ); - $did_update = wpmem_update_options(); + $did_update = wpmem_update_options(); break; - case( 'update_fields' ): - case( 'add_field' ): - case( 'edit_field' ): + case 'update_fields': + case 'add_field': + case 'edit_field': include_once( 'tab-fields.php' ); $did_update = wpmem_update_fields( $action ); break; - case( 'update_dialogs' ): + case 'update_dialogs': include_once( 'tab-dialogs.php' ); $did_update = wpmem_update_dialogs(); break; - case( 'update_emails' ): + case 'update_emails': include_once( 'tab-emails.php' ); $did_update = wpmem_update_emails(); break; - case( 'update_captcha' ): + case 'update_captcha': include_once( 'tab-captcha.php' ); $did_update = wpmem_update_captcha(); break; @@ -269,12 +266,11 @@ function wpmem_admin_action( $action ) /** - * Adds WP-Members custom fields to the WP Add New User form + * Adds WP-Members custom fields to the WP Add New User form. * * @since 2.9.1 */ -function wpmem_admin_add_new_user() -{ +function wpmem_admin_add_new_user() { include_once( WPMEM_PATH . '/native-registration.php' ); echo wpmem_do_wp_newuser_form(); return; diff --git a/admin/dialogs.php b/admin/dialogs.php index 8eb28510..14a37a9b 100644 --- a/admin/dialogs.php +++ b/admin/dialogs.php @@ -51,36 +51,32 @@ function wpmem_a_do_warnings( $did_update, $wpmem_settings ) /** * Warning messages */ + + // are warnings turned off? + $warnings_off = ( $wpmem_settings['warnings'] == 0 ) ? true : false; // settings allow anyone to register - if( get_option( 'users_can_register' ) != 0 && $wpmem_settings[11] == 0 ) { + if( get_option( 'users_can_register' ) != 0 && $warnings_off ) { wpmem_a_warning_msg(1); } // settings allow anyone to comment - if( get_option( 'comment_registration' ) !=1 && $wpmem_settings[11] == 0 ) { + if( get_option( 'comment_registration' ) !=1 && $warnings_off ) { wpmem_a_warning_msg(2); } // rss set to full text feeds - if( get_option( 'rss_use_excerpt' ) !=1 && $wpmem_settings[11] == 0 ) { + if( get_option( 'rss_use_excerpt' ) !=1 && $warnings_off ) { wpmem_a_warning_msg(3); } // holding registrations but haven't changed default successful registration message - if( $wpmem_settings[11] == 0 && $wpmem_settings[5] == 1 && $wpmem_dialogs[3] == 'Congratulations! Your registration was successful.

You may now login using the password that was emailed to you.' ) { + if( $warnings_off && $wpmem_settings['mod_reg'] == 1 && $wpmem_dialogs[3] == 'Congratulations! Your registration was successful.

You may now login using the password that was emailed to you.' ) { wpmem_a_warning_msg(4); - } - - // turned off registration but also have set to moderate and/or email new registrations - if( $wpmem_settings[11] == 0 && $wpmem_settings[7] == 1 ) { - if( $wpmem_settings[5] == 1 || $wpmem_settings[4] ==1 ) { - wpmem_a_warning_msg(5); - } - } + } // haven't entered recaptcha api keys - if( $wpmem_settings[11] == 0 && $wpmem_settings[6] == 1 ) { + if( $warnings_off && $wpmem_settings['captcha'] == 1 ) { $wpmem_captcha = get_option('wpmembers_captcha'); if( !$wpmem_captcha['recaptcha']['public'] || !$wpmem_captcha['recaptcha']['private'] ) { wpmem_a_warning_msg(6); diff --git a/admin/tab-emails.php b/admin/tab-emails.php index 88b96ac9..0b76b375 100644 --- a/admin/tab-emails.php +++ b/admin/tab-emails.php @@ -25,7 +25,7 @@ */ function wpmem_a_build_emails( $wpmem_settings ) { - if( $wpmem_settings[5] == 0 ) { + if( $wpmem_settings['mod_reg'] == 0 ) { $wpmem_email_title_arr = array( array( __( "New Registration", 'wp-members' ), 'wpmembers_email_newreg' ) ); @@ -39,7 +39,7 @@ function wpmem_a_build_emails( $wpmem_settings ) $wpmem_email_title_arr, array( __( "Password Reset", 'wp-members' ), 'wpmembers_email_repass' ) ); - if( $wpmem_settings[4] == 1 ) { + if( $wpmem_settings['notify'] == 1 ) { array_push( $wpmem_email_title_arr, array( __( "Admin Notification", 'wp-members' ), 'wpmembers_email_notify' ) diff --git a/admin/tab-options.php b/admin/tab-options.php index 9eaa6e84..f762e133 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -1,6 +1,6 @@ ', '', '', '' ), 'wp-members' ); $help_link = __( sprintf( 'See the %sUsers Guide on plugin options%s.', '', '' ), 'wp-members' ); @@ -49,56 +49,97 @@ function wpmem_a_build_options( $wpmem_settings )
+

Content

+
    +
  • + + /> Posts +
  • +
  • + + /> Pages +
  • +
  • + + /> Posts +
  • +
  • + + /> Pages +
  • +
  • + + /> Posts +
  • +
  • + + /> Pages +
  • +
  • + + /> Posts +
  • +
  • + + /> Pages +
  • +
+ +

Subscription Settings

+
    +
  • + + + />   + +
  • +
+

Other Settings

    9 ) || ( WPMEM_EXP_MODULE == true ) ) { ?> + array(__('Notify admin','wp-members'),'wpmem_settings_notify',sprintf(__('Notify %s for each new registration? %s','wp-members'),$admin_email,$chg_email),'notify'), + array(__('Moderate registration','wp-members'),'wpmem_settings_moderate',__('Holds new registrations for admin approval','wp-members'),'mod_reg'), + //array(__('Use reCAPTCHA','wp-members'),'wpmem_settings_captcha',__('Turns on CAPTCHA for registration','wp-members'),'captcha'), + array(__('Ignore warning messages','wp-members'),'wpmem_settings_ignore_warnings',__('Ignores WP-Members warning messages in the admin panel','wp-members'),'warnings'), + ); + for ( $row = 0; $row < count( $arr ); $row++ ) { ?>
  • - - />   - + + />   +
  • - - + +
  • - />   + />  
  • - +
  • - />      . + />      .
  • - +
- +
  • - +
  • -

  • - +
  • @@ -164,119 +204,117 @@ function wpmem_a_build_options( $wpmem_settings ) /** - * Updates the plugin options + * Updates the plugin options. * * @since 2.8.0 * - * @return string The options updated message + * @return string The options updated message. */ -function wpmem_update_options() -{ +function wpmem_update_options() { + //check nonce check_admin_referer( 'wpmem-update-settings' ); - //keep things clean - $post_arr = array( - 'WPMEM_VERSION', - 'wpmem_settings_block_posts', - 'wpmem_settings_block_pages', - 'wpmem_settings_show_excerpts', - 'wpmem_settings_notify', - 'wpmem_settings_moderate', - 'wpmem_settings_captcha', - 'wpmem_settings_turnoff', - 'wpmem_settings_legacy', - 'wpmem_settings_time_exp', - 'wpmem_settings_trial', - 'wpmem_settings_ignore_warnings' - ); - - $wpmem_newsettings = array(); - for( $row = 0; $row < count( $post_arr ); $row++ ) { - if( $post_arr[$row] == 'WPMEM_VERSION' ) { - $wpmem_newsettings[$row] = 'WPMEM_VERSION'; - } else { - if( isset( $_POST[$post_arr[$row]] ) != 1 ) { - $wpmem_newsettings[$row] = 0; - } else { - $wpmem_newsettings[$row] = $_POST[$post_arr[$row]]; - } - } - - if( WPMEM_DEBUG == true ) { - echo $post_arr[$row] . ' ' . $_POST[$post_arr[$row]] . '
    '; - } - - /* - if we are setting registration to be moderated, - check to see if the current admin has been - activated so they don't accidentally lock themselves - out later - */ - if( $row == 5 ) { - if( isset( $_POST[$post_arr[$row]] ) == 1) { - global $current_user; - get_currentuserinfo(); - $user_ID = $current_user->ID; - update_user_meta( $user_ID, 'active', 1 ); - } - } - } - - $wpmem_attribution = ( isset( $_POST['attribution'] ) ) ? 1 : 0; - update_option( 'wpmembers_attrib', $wpmem_attribution ); $wpmem_settings_msurl = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? $_POST['wpmem_settings_msurl'] : ''; $wpmem_settings_mspage = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_mspage']; - if( $wpmem_settings_mspage ) { update_option( 'wpmembers_msurl', $wpmem_settings_mspage ); } - if( $wpmem_settings_msurl != wpmem_use_ssl() && $wpmem_settings_msurl != 'use_custom' && ! $wpmem_settings_mspage ) { - update_option( 'wpmembers_msurl', trim( $wpmem_settings_msurl ) ); + if ( $wpmem_settings_msurl != wpmem_use_ssl() && $wpmem_settings_msurl != 'use_custom' && ! $wpmem_settings_mspage ) { + $msurl = trim( $wpmem_settings_msurl ); + } else { + $msurl = $wpmem_settings_mspage; } $wpmem_settings_regurl = ( $_POST['wpmem_settings_regpage'] == 'use_custom' ) ? $_POST['wpmem_settings_regurl'] : ''; $wpmem_settings_regpage = ( $_POST['wpmem_settings_regpage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_regpage']; - if( $wpmem_settings_regpage ) { update_option( 'wpmembers_regurl', $wpmem_settings_regpage ); } - if( $wpmem_settings_regurl != wpmem_use_ssl() && $wpmem_settings_regurl != 'use_custom' && ! $wpmem_settings_regpage ) { - update_option( 'wpmembers_regurl', trim( $wpmem_settings_regurl ) ); + if ( $wpmem_settings_regurl != wpmem_use_ssl() && $wpmem_settings_regurl != 'use_custom' && ! $wpmem_settings_regpage ) { + $regurl = trim( $wpmem_settings_regurl ); + } else { + $regurl = $wpmem_settings_regpage; } $wpmem_settings_logurl = ( $_POST['wpmem_settings_logpage'] == 'use_custom' ) ? $_POST['wpmem_settings_logurl'] : ''; $wpmem_settings_logpage = ( $_POST['wpmem_settings_logpage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_logpage']; - if( $wpmem_settings_logpage ) { update_option( 'wpmembers_logurl', $wpmem_settings_logpage ); } - if( $wpmem_settings_logurl != wpmem_use_ssl() && $wpmem_settings_logurl != 'use_custom' && ! $wpmem_settings_logpage ) { - update_option( 'wpmembers_logurl', trim( $wpmem_settings_logurl ) ); + if ( $wpmem_settings_logurl != wpmem_use_ssl() && $wpmem_settings_logurl != 'use_custom' && ! $wpmem_settings_logpage ) { + $logurl = trim( $wpmem_settings_logurl ); + } else { + $logurl = $wpmem_settings_logpage; } $wpmem_settings_cssurl = $_POST['wpmem_settings_cssurl']; - if( $wpmem_settings_cssurl != wpmem_use_ssl() ) { - update_option( 'wpmembers_cssurl', trim( $wpmem_settings_cssurl ) ); - } + $cssurl = ( $wpmem_settings_cssurl != wpmem_use_ssl() ) ? trim( $wpmem_settings_cssurl ) : ''; $wpmem_settings_style = ( isset( $_POST['wpmem_settings_style'] ) ) ? $_POST['wpmem_settings_style'] : false; - update_option( 'wpmembers_style', $wpmem_settings_style, false ); $wpmem_autoex = array ( 'auto_ex' => isset( $_POST['wpmem_autoex'] ) ? $_POST['wpmem_autoex'] : 0, - 'auto_ex_len' => isset( $_POST['wpmem_autoex_len'] ) ? $_POST['wpmem_autoex_len'] : '' + 'auto_ex_len' => isset( $_POST['wpmem_autoex_len'] ) ? $_POST['wpmem_autoex_len'] : '', + ); + + $wpmem_newsettings = array( + 'version' => WPMEM_VERSION, + 'block' => array( + 'post' => ( isset( $_POST['wpmem_block_post'] ) ) ? 1 : 0, + 'page' => ( isset( $_POST['wpmem_block_page'] ) ) ? 1 : 0, + ), + 'show_excerpt' => array( + 'post' => ( isset( $_POST['wpmem_show_excerpt_post'] ) ) ? 1 : 0, + 'page' => ( isset( $_POST['wpmem_show_excerpt_page'] ) ) ? 1 : 0, + ), + 'show_reg' => array( + 'post' => ( isset( $_POST['wpmem_show_reg_post'] ) ) ? 1 : 0, + 'page' => ( isset( $_POST['wpmem_show_reg_page'] ) ) ? 1 : 0, + ), + 'show_login' => array( + 'post' => ( isset( $_POST['wpmem_show_login_post'] ) ) ? 1 : 0, + 'page' => ( isset( $_POST['wpmem_show_login_page'] ) ) ? 1 : 0, + ), + 'notify' => ( isset( $_POST['wpmem_settings_notify'] ) ) ? 1 : 0, + 'mod_reg' => ( isset( $_POST['wpmem_settings_moderate'] ) ) ? 1 : 0, + 'captcha' => ( isset( $_POST['wpmem_settings_captcha'] ) ) ? $_POST['wpmem_settings_captcha'] : 0, + 'use_exp' => ( isset( $_POST['wpmem_settings_time_exp'] ) ) ? 1 : 0, + 'use_trial' => ( isset( $_POST['wpmem_settings_trial'] ) ) ? 1 : 0, + 'warnings' => ( isset( $_POST['wpmem_settings_ignore_warnings'] ) ) ? 1 : 0, + 'user_pages' => array( + 'profile' => ( $msurl ) ? $msurl : '', + 'register' => ( $regurl ) ? $regurl : '', + 'login' => ( $logurl ) ? $logurl : '', + ), + 'cssurl' => ( $cssurl ) ? $cssurl : '', + 'style' => $wpmem_settings_style, + 'autoex' => $wpmem_autoex, + 'attrib' => ( isset( $_POST['attribution'] ) ) ? 1 : 0, + ); - update_option( 'wpmembers_autoex', $wpmem_autoex, false ); + /* + if we are setting registration to be moderated, + check to see if the current admin has been + activated so they don't accidentally lock themselves + out later + */ + if ( isset( $_POST['wpmem_settings_moderate'] ) == 1) { + global $current_user; + get_currentuserinfo(); + $user_ID = $current_user->ID; + update_user_meta( $user_ID, 'active', 1 ); + } + update_option( 'wpmembers_settings', $wpmem_newsettings ); $wpmem_settings = $wpmem_newsettings; - - + return __( 'WP-Members settings were updated', 'wp-members' ); } /** - * Create the stylesheet dropdown selection + * Create the stylesheet dropdown selection. * * @since 2.8 + * + * @param $style string The stored stylesheet setting. */ -function wpmem_admin_style_list() -{ - $val = get_option( 'wpmembers_style', null ); +function wpmem_admin_style_list( $style ) { + $list = array( 'No Float' => WPMEM_DIR . 'css/generic-no-float.css', 'Rigid' => WPMEM_DIR . 'css/generic-rigid.css', @@ -301,9 +339,9 @@ function wpmem_admin_style_list() $list = apply_filters( 'wpmem_admin_style_list', $list ); $selected = false; - foreach( $list as $name => $location ) { - $selected = ( $location == $val ) ? true : $selected; - echo '\n"; + foreach ( $list as $name => $location ) { + $selected = ( $location == $style ) ? true : $selected; + echo '\n"; } $selected = ( ! $selected ) ? ' selected' : ''; echo ''; @@ -313,14 +351,14 @@ function wpmem_admin_style_list() /** - * Create a dropdown selection of pages + * Create a dropdown selection of pages. * * @since 2.8.1 * * @param string $val */ -function wpmem_admin_page_list( $val, $show_custom_url = true ) -{ +function wpmem_admin_page_list( $val, $show_custom_url = true ) { + $selected = ( $val == 'http://' ) ? 'select a page' : false; $pages = get_pages(); @@ -333,7 +371,7 @@ function wpmem_admin_page_list( $val, $show_custom_url = true ) $option .= ''; echo $option; } - if( $show_custom_url ) { + if ( $show_custom_url ) { $selected = ( ! $selected ) ? ' selected' : ''; echo ''; } diff --git a/uninstall.php b/uninstall.php index 16ae5683..6bbd9174 100644 --- a/uninstall.php +++ b/uninstall.php @@ -58,14 +58,14 @@ function wpmem_uninstall_options() delete_option( 'wpmembers_captcha' ); delete_option( 'wpmembers_tos' ); delete_option( 'wpmembers_export' ); - delete_option( 'wpmembers_msurl' ); - delete_option( 'wpmembers_regurl' ); - delete_option( 'wpmembers_logurl' ); - delete_option( 'wpmembers_cssurl' ); - delete_option( 'wpmembers_style' ); - delete_option( 'wpmembers_autoex' ); +// delete_option( 'wpmembers_msurl' ); +// delete_option( 'wpmembers_regurl' ); +// delete_option( 'wpmembers_logurl' ); +// delete_option( 'wpmembers_cssurl' ); +// delete_option( 'wpmembers_style' ); +// delete_option( 'wpmembers_autoex' ); delete_option( 'wpmembers_utfields' ); - delete_option( 'wpmembers_attrib' ); +// delete_option( 'wpmembers_attrib' ); delete_option( 'wpmembers_email_newreg' ); delete_option( 'wpmembers_email_newmod' ); diff --git a/wp-members-install.php b/wp-members-install.php index 808e2de5..1b553023 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -21,8 +21,8 @@ * * @since 2.2.2 */ -function wpmem_do_install() -{ +function wpmem_do_install() { + /* if you need to force an install, set $chk_force = true @@ -37,11 +37,46 @@ function wpmem_do_install() $chk_force = false; - if( !get_option( 'wpmembers_settings' ) || $chk_force == true ) { + if ( ! get_option( 'wpmembers_settings' ) || $chk_force == true ) { // this is a clean install (or an upgrade from 2.1 or earlier) - $wpmem_settings = array( WPMEM_VERSION, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ); + $wpmem_settings = array( + 'version' => WPMEM_VERSION, + 'block' => array( + 'post' => 1, + 'page' => 0, + ), + 'show_excerpt' => array( + 'post' => 0, + 'page' => 0, + ), + 'show_reg' => array( + 'post' => 1, + 'page' => 1, + ), + 'show_login' => array( + 'post' => 1, + 'page' => 1, + ), + 'notify' => 0, + 'mod_reg' => 0, + 'captcha' => 0, + 'use_exp' => 0, + 'use_trial' => 0, + 'warnings' => 0, + 'user_pages' => array( + 'profile' => '', + 'register' => '', + 'login' => '', + ), + 'cssurl' => '', + 'style' => '', + 'autoex' => '', + 'attrib' => 0, + + + ); update_option( 'wpmembers_settings', $wpmem_settings, '', 'yes' ); // using update_option to allow for forced update // order, label, optionname, type, display, required, native, checked value, checked by default @@ -61,7 +96,8 @@ function wpmem_do_install() array( 13, 'Biographical Info', 'description', 'textarea', 'n', 'n', 'y' ), array( 14, 'Password', 'password', 'password', 'n', 'n', 'n' ), array( 15, 'Confirm Password', 'confirm_password', 'password', 'n', 'n', 'n' ), - array( 16, 'TOS', 'tos', 'checkbox', 'n', 'n', 'n', 'agree', 'n' ) + array( 16, 'TOS', 'tos', 'checkbox', 'n', 'n', 'n', 'agree', 'n' ), + ); ); update_option( 'wpmembers_fields', $wpmem_fields_options_arr, '', 'yes' ); // using update_option to allow for forced update @@ -77,123 +113,74 @@ function wpmem_do_install() "Password successfully reset!

    An email containing a new password has been sent to the email address on file for your account." ); + // insert TOS dialog placeholder + $dummy_tos = "Put your TOS (Terms of Service) text here. You can use HTML markup."; + update_option( 'wpmembers_tos', $dummy_tos ); + update_option( 'wpmembers_dialogs', $wpmem_dialogs_arr, '', 'yes' ); // using update_option to allow for forced update - wpmem_append_tos( 'new' ); - - wpmem_append_email(); + append_email(); // if it's a new install, use the Twenty Twelve stylesheet update_option( 'wpmembers_style', plugin_dir_url ( __FILE__ ) . 'css/generic-no-float.css', '', 'yes' ); } else { - wpmem_update_captcha(); - - wpmem_update_dialogs(); + update_captcha(); + + update_dialogs(); - wpmem_append_email(); + append_email(); $wpmem_settings = get_option( 'wpmembers_settings' ); - switch( count ( $wpmem_settings ) ) { - - case 4: - - // upgrading from 2.2.x - // update version, insert new toggles, keep other settings - $wpmem_newsettings = array( - WPMEM_VERSION, // 0 version - $wpmem_settings[1], // 1 block posts - $wpmem_settings[2], // 2 block pages - '0', // 3 show excerpts on posts/pages - '0', // 4 notify admin - '0', // 5 moderate registration - '0', // 6 toggle captcha - '0', // 7 turn off registration - '1', // 8 add use legacy forms (tables) - '0', // 9 time based expiration - '0', // 10 offer trial period - $wpmem_settings[3] // 11 ignore warnings - ); - update_option( 'wpmembers_settings', $wpmem_newsettings ); - wpmem_append_tos( '2.2+' ); - wpmem_update_active( 0 ); - break; + // can only upgrade from 2.5.1 or higher + $show_reg = ( $wpmem_settings[7] == 0 ) ? 1 : 0; + $wpmem_newsettings = array( + 'version' => WPMEM_VERSION, + 'block' => array( + 'post' => $wpmem_settings[1], + 'page' => $wpmem_settings[2], + ), + 'show_excerpt' => array( + 'post' => $wpmem_settings[3], + 'page' => $wpmem_settings[3], + ), + 'show_reg' => array( + 'post' => $show_reg, + 'page' => $show_reg, + ), + 'show_login' => array( + 'post' => 1, + 'page' => 1, + ), + 'notify' => $wpmem_settings[4], + 'mod_reg' => $wpmem_settings[5], + 'captcha' => $wpmem_settings[6], + 'use_exp' => $wpmem_settings[9], + 'use_trial' => $wpmem_settings[10], + 'warnings' => $wpmem_settings[11], + 'user_pages' => array( + 'profile' => get_option( 'wpmembers_msurl' ), + 'register' => get_option( 'wpmembers_regurl' ), + 'login' => get_option( 'wpmembers_logurl' ), + ), + 'cssurl' => get_option( 'wpmembers_cssurl' ), + 'style' => get_option( 'wpmembers_style' ), + 'autoex' => get_option( 'wpmembers_autoex' ), + 'attrib' => get_option( 'wpmembers_attrib' ), + ); + update_option( 'wpmembers_settings', $wpmem_newsettings ); - case 10: // count($wpmem_settings) > 4 && count($wpmem_settings) < 12 + // remove old settings + delete_option( 'wpmembers_msurl' ); + delete_option( 'wpmembers_regurl' ); + delete_option( 'wpmembers_logurl' ); + delete_option( 'wpmembers_cssurl' ); + delete_option( 'wpmembers_style' ); + delete_option( 'wpmembers_autoex' ); + delete_option( 'wpmembers_attrib' ); - // upgrading from 2.3.0, 2.3.1, 2.3.2, 2.4.0, or 2.5.0 - // update version, insert captcha toggle, keep other settings - $wpmem_newsettings = array( - WPMEM_VERSION, // 0 version - $wpmem_settings[1], // 1 block posts - $wpmem_settings[2], // 2 block pages - $wpmem_settings[3], // 3 show excerpts on posts/pages - $wpmem_settings[4], // 4 notify admin - $wpmem_settings[5], // 5 moderate registration - '0', // 6 toggle captcha - $wpmem_settings[6], // 7 turn off registration - '1', // 8 add use legacy forms (tables) - $wpmem_settings[7], // 9 time based expiration - $wpmem_settings[8], // 10 offer trial period - $wpmem_settings[9] // 11 ignore warnings - ); - update_option( 'wpmembers_settings', $wpmem_newsettings ); - wpmem_append_tos( '2.2+'); - wpmem_update_active( $wpmem_settings[5] ); - break; - - case 12: - - // upgrading from 2.5.1 or higher - // 2.5.1 - 2.9.7 only updated the version - // 2.9.8 requires a db update, so this allows the admin panel to produce a nag message - $wpmem_newsettings = array( - WPMEM_VERSION, // 0 version - $wpmem_settings[1], // 1 block posts - $wpmem_settings[2], // 2 block pages - $wpmem_settings[3], // 3 show excerpts on posts/pages - $wpmem_settings[4], // 4 notify admin - $wpmem_settings[5], // 5 moderate registration - $wpmem_settings[6], // 6 toggle captcha - $wpmem_settings[7], // 7 turn off registration - $wpmem_settings[8], // 8 add use legacy forms (tables) - $wpmem_settings[9], // 9 time based expiration - $wpmem_settings[10], // 10 offer trial period - $wpmem_settings[11] // 11 ignore warnings - ); - update_option( 'wpmembers_settings', $wpmem_newsettings ); - wpmem_update_active( $wpmem_settings[5] ); - break; - } - } -} - - -/** - * Adds TOS field to upgrades if appropriate - * - * @since 2.4 - */ -function wpmem_append_tos( $upgrade ) -{ - // check if _tos has been put in before; if not, populate dummy data - if( !get_option('wpmembers_tos') ) { - $dummy_tos = "Put your TOS (Terms of Service) text here. You can use HTML markup."; - update_option( 'wpmembers_tos', $dummy_tos ); - - if( $upgrade == '2.2+' ) { - // append a TOS field to the end of the fields array - $fields = get_option( 'wpmembers_fields' ); - - $x = count( $fields ); - $x = $x + 1; - - $fields[] = array( $x, 'TOS', 'tos', 'checkbox', 'y', 'y', 'n', 'agree', 'n' ); - - update_option( 'wpmembers_fields', $fields ); - } } } @@ -203,8 +190,7 @@ function wpmem_append_tos( $upgrade ) * * @since 2.7 */ -function wpmem_append_email() -{ +function append_email() { //email for a new registration $subj = 'Your registration info for [blogname]'; @@ -228,7 +214,7 @@ function wpmem_append_email() "body" => $body ); - if( ! get_option( 'wpmembers_email_newreg' ) ) { + if ( ! get_option( 'wpmembers_email_newreg' ) ) { update_option( 'wpmembers_email_newreg', $arr, false ); } @@ -246,7 +232,7 @@ function wpmem_append_email() "body" => $body ); - if( ! get_option( 'wpmembers_email_newmod' ) ) { + if ( ! get_option( 'wpmembers_email_newmod' ) ) { update_option( 'wpmembers_email_newmod', $arr, false ); } @@ -274,7 +260,7 @@ function wpmem_append_email() "body" => $body ); - if( ! get_option( 'wpmembers_email_appmod' ) ) { + if ( ! get_option( 'wpmembers_email_appmod' ) ) { update_option( 'wpmembers_email_appmod', $arr, false ); } @@ -294,7 +280,7 @@ function wpmem_append_email() "body" => $body ); - if( ! get_option( 'wpmembers_email_repass' ) ) { + if ( ! get_option( 'wpmembers_email_repass' ) ) { update_option( 'wpmembers_email_repass', $arr, false ); } @@ -321,7 +307,7 @@ function wpmem_append_email() "body" => $body ); - if( ! get_option( 'wpmembers_email_notify' ) ) { + if ( ! get_option( 'wpmembers_email_notify' ) ) { update_option( 'wpmembers_email_notify', $arr, false ); } @@ -332,7 +318,7 @@ function wpmem_append_email() This is an automated message from [blogname] Please do not reply to this address'; - if( ! get_option( 'wpmembers_email_footer' ) ) { + if ( ! get_option( 'wpmembers_email_footer' ) ) { update_option( 'wpmembers_email_footer', $body, false ); } @@ -345,22 +331,22 @@ function wpmem_append_email() * * @since 2.9.3 */ -function wpmem_update_dialogs() -{ +function update_dialogs() { + $wpmem_dialogs_arr = get_option( 'wpmembers_dialogs' ); $do_update = false; - if( $wpmem_dialogs_arr[0] == "This content is restricted to site members. If you are an existing user, please login. New users may register below." ) { + if ( $wpmem_dialogs_arr[0] == "This content is restricted to site members. If you are an existing user, please login. New users may register below." ) { $wpmem_dialogs_arr[0] = "This content is restricted to site members. If you are an existing user, please log in. New users may register below."; $do_update = true; } - if( $wpmem_dialogs_arr[3] == "Congratulations! Your registration was successful.

    You may now login using the password that was emailed to you." ) { + if ( $wpmem_dialogs_arr[3] == "Congratulations! Your registration was successful.

    You may now login using the password that was emailed to you." ) { $wpmem_dialogs_arr[3] = "Congratulations! Your registration was successful.

    You may now log in using the password that was emailed to you."; $do_update = true; } - if( $do_update ) { + if ( $do_update ) { update_option( 'wpmembers_dialogs', $wpmem_dialogs_arr, '', 'yes' ); } @@ -373,20 +359,20 @@ function wpmem_update_dialogs() * * @since 2.9.5 */ -function wpmem_update_captcha() -{ +function update_captcha() { + $captcha_settings = get_option( 'wpmembers_captcha' ); // if there captcha settings, update them - if( $captcha_settings && ! array_key_exists( 'recaptcha', $captcha_settings ) ) { + if ( $captcha_settings && ! array_key_exists( 'recaptcha', $captcha_settings ) ) { // check to see if the array keys are numeric $is_numeric = false; - foreach( $captcha_settings as $key => $setting ) { + foreach ( $captcha_settings as $key => $setting ) { $is_numeric = ( is_int( $key ) ) ? true : $is_numeric; } - if( $is_numeric ) { + if ( $is_numeric ) { $new_captcha = array(); // these are old recaptcha settings $new_captcha['recaptcha']['public'] = $captcha_settings[0]; @@ -401,19 +387,4 @@ function wpmem_update_captcha() } -function wpmem_update_active( $mod ) { - if( $mod == 1 ) { - global $wpdb; - $users = get_users( array( 'fields'=>'ID' ) ); - foreach( $users as $user ){ - $is_active = get_user_meta( $user, 'active', true ); - if( ! $is_active || $is_active != 1 ) { - $wpdb->update( $wpdb->users, array( 'user_status' => '2' ), array( 'ID' => $user ) ); - } elseif( $is_active == 1 ) { - $wpdb->update( $wpdb->users, array( 'user_status' => '0' ), array( 'ID' => $user ) ); - } - } - } - return; -} -/** End of File **/ +/** End of File **/ \ No newline at end of file diff --git a/wp-members.php b/wp-members.php index b64edae0..d395a3a5 100644 --- a/wp-members.php +++ b/wp-members.php @@ -84,6 +84,11 @@ */ function wpmem_init() { + /** + * Setup globals + */ + global $wpmem_settings; + /** * Fires before initialization of plugin options. * @@ -112,28 +117,29 @@ function wpmem_init() { $wpmem_settings = apply_filters( 'wpmem_settings', $wpmem_settings ); /** - * define constants based on option settings. + * Define constants based on option settings. */ - ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem_settings[1] ) : ''; - ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $wpmem_settings[2] ) : ''; - ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $wpmem_settings[3] ) : ''; - ( ! defined( 'WPMEM_NOTIFY_ADMIN' ) ) ? define( 'WPMEM_NOTIFY_ADMIN', $wpmem_settings[4] ) : ''; - ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $wpmem_settings[5] ) : ''; - ( ! defined( 'WPMEM_CAPTCHA' ) ) ? define( 'WPMEM_CAPTCHA', $wpmem_settings[6] ) : ''; - ( ! defined( 'WPMEM_NO_REG' ) ) ? define( 'WPMEM_NO_REG', $wpmem_settings[7] ) : ''; - ( ! defined( 'WPMEM_USE_EXP' ) ) ? define( 'WPMEM_USE_EXP', $wpmem_settings[9] ) : ''; - ( ! defined( 'WPMEM_USE_TRL' ) ) ? define( 'WPMEM_USE_TRL', $wpmem_settings[10] ) : ''; - ( ! defined( 'WPMEM_IGNORE_WARN' ) ) ? define( 'WPMEM_IGNORE_WARN', $wpmem_settings[11] ) : ''; - - ( ! defined( 'WPMEM_MSURL' ) ) ? define( 'WPMEM_MSURL', get_option( 'wpmembers_msurl', null ) ) : ''; - ( ! defined( 'WPMEM_REGURL' ) ) ? define( 'WPMEM_REGURL', get_option( 'wpmembers_regurl',null ) ) : ''; - ( ! defined( 'WPMEM_LOGURL' ) ) ? define( 'WPMEM_LOGURL', get_option( 'wpmembers_logurl',null ) ) : ''; + ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem_settings['block']['post'] ) : ''; + ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $wpmem_settings['block']['page'] ) : ''; + ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $wpmem_settings['show_excerpt']['post'] ) : ''; + ( ! defined( 'WPMEM_NOTIFY_ADMIN' ) ) ? define( 'WPMEM_NOTIFY_ADMIN', $wpmem_settings['notify'] ) : ''; + ( ! defined( 'WPMEM_NO_REG' ) ) ? define( 'WPMEM_NO_REG', $wpmem_settings['mod_reg'] ) : ''; + ( ! defined( 'WPMEM_IGNORE_WARN' ) ) ? define( 'WPMEM_IGNORE_WARN', $wpmem_settings['warnings'] ) : ''; + + ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $wpmem_settings['mod_reg'] ) : ''; + ( ! defined( 'WPMEM_CAPTCHA' ) ) ? define( 'WPMEM_CAPTCHA', $wpmem_settings['captcha'] ) : ''; + ( ! defined( 'WPMEM_USE_EXP' ) ) ? define( 'WPMEM_USE_EXP', $wpmem_settings['use_exp'] ) : ''; + ( ! defined( 'WPMEM_USE_TRL' ) ) ? define( 'WPMEM_USE_TRL', $wpmem_settings['use_trial'] ) : ''; + + ( ! defined( 'WPMEM_MSURL' ) ) ? define( 'WPMEM_MSURL', $wpmem_settings['user_pages']['profile'] ) : ''; + ( ! defined( 'WPMEM_REGURL' ) ) ? define( 'WPMEM_REGURL', $wpmem_settings['user_pages']['register'] ) : ''; + ( ! defined( 'WPMEM_LOGURL' ) ) ? define( 'WPMEM_LOGURL', $wpmem_settings['user_pages']['login'] ) : ''; /** * Define the stylesheet. */ - $wpmem_style = get_option( 'wpmembers_style', null ); - $wpmem_style = ( $wpmem_style == 'use_custom' || ! $wpmem_style ) ? get_option( 'wpmembers_cssurl', null ) : $wpmem_style; + $wpmem_style = $wpmem_settings['style']; + $wpmem_style = ( $wpmem_style == 'use_custom' || ! $wpmem_style ) ? $wpmem_settings['cssurl'] : $wpmem_style; define( 'WPMEM_CSSURL', $wpmem_style ); /** @@ -141,7 +147,7 @@ function wpmem_init() { * * @since 3.0 */ - add_action( 'wpmem_settings_loaded' ); + do_action( 'wpmem_settings_loaded' ); /** * Filter the location and name of the pluggable file. From a72850780ecec47587e4803a2f60fed396952c36 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 8 Apr 2015 09:28:09 -0500 Subject: [PATCH 0038/1694] code clean up --- wp-members-core.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/wp-members-core.php b/wp-members-core.php index 93f56025..11d2f048 100644 --- a/wp-members-core.php +++ b/wp-members-core.php @@ -118,7 +118,7 @@ function wpmem_securify( $content = null ) { } // Block/unblock Posts - if ( !is_user_logged_in() && wpmem_block() == true ) { + if ( ! is_user_logged_in() && wpmem_block() == true ) { // protects comments if user is not logged in global $post; @@ -333,12 +333,10 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) { } elseif ( is_user_logged_in() && $page == 'register' ) { - //return wpmem_inc_memberlinks( 'register' ); - $content = $content . wpmem_inc_memberlinks( 'register' ); - + } - + } if ( $page == 'login' ) { @@ -365,7 +363,7 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) { * * @since 2.6 * - * @return bool $block + * @return bool $block true|false */ function wpmem_block() { From 045ae4eb9a0de67b60dcca03b5ac357f836b8c0f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 8 Apr 2015 09:29:02 -0500 Subject: [PATCH 0039/1694] wpmem_rs_captcha_folder filter --- forms.php | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/forms.php b/forms.php index 21ef5021..21314276 100644 --- a/forms.php +++ b/forms.php @@ -1014,9 +1014,16 @@ function wpmem_build_rs_captcha() { $wpmem_captcha_word = $wpmem_captcha->generate_random_word(); $wpmem_captcha_prefix = mt_rand(); - $wpmem_captcha_image_name = $wpmem_captcha->generate_image( $wpmem_captcha_prefix, $wpmem_captcha_word ); - $wpmem_captcha_image_url = get_bloginfo('wpurl') . '/wp-content/plugins/really-simple-captcha/tmp/'; + + /** + * Filters the default Really Simple Captcha folder location. + * + * @since 3.0 + * + * @param string The default location of RS Captcha. + */ + $wpmem_captcha_image_url = apply_filters( 'wpmem_rs_captcha_folder', get_bloginfo('wpurl') . '/wp-content/plugins/really-simple-captcha/tmp/' ); $img_w = $wpmem_captcha->img_size[0]; $img_h = $wpmem_captcha->img_size[1]; From 3ba862bf7d6528189ef50929e58bc399fe679a75 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 8 Apr 2015 17:30:31 -0500 Subject: [PATCH 0040/1694] toggle new|edit added to wpmem_register_data filter hook --- wp-members-register.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/wp-members-register.php b/wp-members-register.php index bde97ce3..908e930a 100644 --- a/wp-members-register.php +++ b/wp-members-register.php @@ -199,9 +199,10 @@ function wpmem_registration( $toggle ) * * @since 2.8.2 * - * @param array $fields An array of the registration field data. + * @param array $fields An array of the registration field data. + * @param string $toggle A switch to indicate the action (new|edit). */ - $fields = apply_filters( 'wpmem_register_data', $fields ); + $fields = apply_filters( 'wpmem_register_data', $fields, 'new' ); /** * Fires before any insertion/emails. @@ -319,9 +320,10 @@ function wpmem_registration( $toggle ) * * @since 2.8.2 * - * @param array $fields An array of the registration field data. + * @param array $fields An array of the registration field data. + * @param string $toggle A switch to indicate the action (new|edit). */ - $fields = apply_filters( 'wpmem_register_data', $fields ); + $fields = apply_filters( 'wpmem_register_data', $fields, 'edit' ); /** * Fires before data insertion. From 2814c46a15bb419eb4cb61278fd238bc21ff0ea8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 10 Apr 2015 15:17:55 -0500 Subject: [PATCH 0041/1694] new WP_Members class --- class-wp-members.php | 29 +++++++++++++++++++++++++++ wp-members.php | 47 ++++++++++++++++++-------------------------- 2 files changed, 48 insertions(+), 28 deletions(-) create mode 100644 class-wp-members.php diff --git a/class-wp-members.php b/class-wp-members.php new file mode 100644 index 00000000..81be89bf --- /dev/null +++ b/class-wp-members.php @@ -0,0 +1,29 @@ +settings An array of the WP-Members settings. + */ + $settings = apply_filters( 'wpmem_settings', get_option( 'wpmembers_settings' ) ); + + /** + * Assemble settings. + */ + foreach ( $settings as $key => $val ) { + $this->$key = $val; + } + + } + +} \ No newline at end of file diff --git a/wp-members.php b/wp-members.php index d395a3a5..bd8b966c 100644 --- a/wp-members.php +++ b/wp-members.php @@ -87,7 +87,7 @@ function wpmem_init() { /** * Setup globals */ - global $wpmem_settings; + global $wpmem; /** * Fires before initialization of plugin options. @@ -101,45 +101,36 @@ function wpmem_init() { */ load_plugin_textdomain( 'wp-members', false, dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); - - /** - * Load options. - */ - $wpmem_settings = get_option( 'wpmembers_settings' ); - /** - * Filter the options before they are loaded into constants. - * - * @since 2.9.0 - * - * @param array $wpmem_settings An array of the WP-Members settings. + * Load WP_Members class. */ - $wpmem_settings = apply_filters( 'wpmem_settings', $wpmem_settings ); + include_once( 'class-wp-members.php' ); + $wpmem = new WP_Members(); /** * Define constants based on option settings. */ - ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem_settings['block']['post'] ) : ''; - ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $wpmem_settings['block']['page'] ) : ''; - ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $wpmem_settings['show_excerpt']['post'] ) : ''; - ( ! defined( 'WPMEM_NOTIFY_ADMIN' ) ) ? define( 'WPMEM_NOTIFY_ADMIN', $wpmem_settings['notify'] ) : ''; - ( ! defined( 'WPMEM_NO_REG' ) ) ? define( 'WPMEM_NO_REG', $wpmem_settings['mod_reg'] ) : ''; - ( ! defined( 'WPMEM_IGNORE_WARN' ) ) ? define( 'WPMEM_IGNORE_WARN', $wpmem_settings['warnings'] ) : ''; + ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem->block['post'] ) : ''; + ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $wpmem->block['page'] ) : ''; + ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $wpmem->show_excerpt['post'] ) : ''; + ( ! defined( 'WPMEM_NOTIFY_ADMIN' ) ) ? define( 'WPMEM_NOTIFY_ADMIN', $wpmem->notify ) : ''; + ( ! defined( 'WPMEM_NO_REG' ) ) ? define( 'WPMEM_NO_REG', $wpmem->mod_reg ) : ''; + ( ! defined( 'WPMEM_IGNORE_WARN' ) ) ? define( 'WPMEM_IGNORE_WARN', $wpmem->warnings ) : ''; - ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $wpmem_settings['mod_reg'] ) : ''; - ( ! defined( 'WPMEM_CAPTCHA' ) ) ? define( 'WPMEM_CAPTCHA', $wpmem_settings['captcha'] ) : ''; - ( ! defined( 'WPMEM_USE_EXP' ) ) ? define( 'WPMEM_USE_EXP', $wpmem_settings['use_exp'] ) : ''; - ( ! defined( 'WPMEM_USE_TRL' ) ) ? define( 'WPMEM_USE_TRL', $wpmem_settings['use_trial'] ) : ''; + ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $wpmem->mod_reg ) : ''; + ( ! defined( 'WPMEM_CAPTCHA' ) ) ? define( 'WPMEM_CAPTCHA', $wpmem->captcha ) : ''; + ( ! defined( 'WPMEM_USE_EXP' ) ) ? define( 'WPMEM_USE_EXP', $wpmem->use_exp ) : ''; + ( ! defined( 'WPMEM_USE_TRL' ) ) ? define( 'WPMEM_USE_TRL', $wpmem->use_trial ) : ''; - ( ! defined( 'WPMEM_MSURL' ) ) ? define( 'WPMEM_MSURL', $wpmem_settings['user_pages']['profile'] ) : ''; - ( ! defined( 'WPMEM_REGURL' ) ) ? define( 'WPMEM_REGURL', $wpmem_settings['user_pages']['register'] ) : ''; - ( ! defined( 'WPMEM_LOGURL' ) ) ? define( 'WPMEM_LOGURL', $wpmem_settings['user_pages']['login'] ) : ''; + ( ! defined( 'WPMEM_MSURL' ) ) ? define( 'WPMEM_MSURL', $wpmem->user_pages['profile'] ) : ''; + ( ! defined( 'WPMEM_REGURL' ) ) ? define( 'WPMEM_REGURL', $wpmem->user_pages['register'] ) : ''; + ( ! defined( 'WPMEM_LOGURL' ) ) ? define( 'WPMEM_LOGURL', $wpmem->user_pages['login'] ) : ''; /** * Define the stylesheet. */ - $wpmem_style = $wpmem_settings['style']; - $wpmem_style = ( $wpmem_style == 'use_custom' || ! $wpmem_style ) ? $wpmem_settings['cssurl'] : $wpmem_style; + $wpmem_style = $wpmem->style; + $wpmem_style = ( $wpmem_style == 'use_custom' || ! $wpmem_style ) ? $wpmem->cssurl : $wpmem_style; define( 'WPMEM_CSSURL', $wpmem_style ); /** From b493e4bb4570873e8e97b41669aafe5201558a77 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 13 Apr 2015 16:58:57 -0500 Subject: [PATCH 0042/1694] manage new settings format in admin, code standards --- admin/admin.php | 53 ++++++++------ admin/dialogs.php | 160 ++++++++++++++++++++---------------------- admin/tab-captcha.php | 101 +++++++++++++------------- admin/tab-dialogs.php | 66 +++++++++-------- admin/tab-emails.php | 96 +++++++++++++------------ admin/tab-options.php | 137 ++++++++++++++++++++---------------- 6 files changed, 321 insertions(+), 292 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index d0be45a6..4848c412 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -13,6 +13,18 @@ * @subpackage WP-Members * @author Chad Butler * @copyright 2006-2015 + * + * Functions included: + * * wpmem_a_do_field_reorder + * * wpmem_admin_plugin_links + * * wpmem_load_admin_js + * * wpmem_a_captcha_tab + * * wpmem_add_captcha_tab + * * wpmem_admin + * * wpmem_admin_do_tab + * * wpmem_admin_tabs + * * wpmem_admin_action + * * wpmem_admin_add_new_user */ @@ -23,7 +35,7 @@ /** Actions and Filters */ -add_action( 'wpmem_admin_do_tab', 'wpmem_admin_do_tab', 10, 2 ); +add_action( 'wpmem_admin_do_tab', 'wpmem_admin_do_tab' ); add_action( 'wp_ajax_wpmem_a_field_reorder', 'wpmem_a_do_field_reorder' ); add_action( 'user_new_form', 'wpmem_admin_add_new_user' ); add_filter( 'plugin_action_links', 'wpmem_admin_plugin_links', 10, 2 ); @@ -114,12 +126,13 @@ function wpmem_admin() { $did_update = ( isset( $_POST['wpmem_admin_a'] ) ) ? wpmem_admin_action( $_POST['wpmem_admin_a'] ) : false; - $wpmem_settings = get_option( 'wpmembers_settings' ); - if ( $wpmem_settings[6] ) { + global $wpmem; + + if ( $wpmem->captcha ) { add_filter( 'wpmem_admin_tabs', 'wpmem_add_captcha_tab' ); add_action( 'wpmem_admin_do_tab', 'wpmem_a_captcha_tab', 1, 1 ); } ?> - +
    @@ -128,7 +141,7 @@ function wpmem_admin() { wpmem_admin_tabs( $tab ); - wpmem_a_do_warnings( $did_update, $wpmem_settings ); + wpmem_a_do_warnings( $did_update ); /** * Fires at the end of creating an admin panel tab. @@ -139,13 +152,12 @@ function wpmem_admin() { * * @since 2.8 * - * @param string $tab The tab being generated. - * @param array $wpmem_settings The plugin settings. + * @param string $tab The tab being generated. */ - do_action( 'wpmem_admin_do_tab', $tab, $wpmem_settings ); + do_action( 'wpmem_admin_do_tab', $tab ); ?>
    __( 'Dialogs', 'wp-members' ), 'emails' => __( 'Emails', 'wp-members' ), ); - + /** * Filter the admin tabs for the plugin settings page. * @@ -206,7 +217,7 @@ function wpmem_admin_tabs( $current = 'options' ) { * @param array $tabs An array of the tabs to be displayed on the plugin settings page. */ $tabs = apply_filters( 'wpmem_admin_tabs', $tabs ); - + $links = array(); foreach ( $tabs as $tab => $name ) { $class = ( $tab == $current ) ? 'nav-tab nav-tab-active' : 'nav-tab'; @@ -244,23 +255,23 @@ function wpmem_admin_action( $action ) { include_once( 'tab-fields.php' ); $did_update = wpmem_update_fields( $action ); break; - + case 'update_dialogs': include_once( 'tab-dialogs.php' ); $did_update = wpmem_update_dialogs(); break; - + case 'update_emails': include_once( 'tab-emails.php' ); $did_update = wpmem_update_emails(); break; - + case 'update_captcha': include_once( 'tab-captcha.php' ); $did_update = wpmem_update_captcha(); break; } - + return $did_update; } diff --git a/admin/dialogs.php b/admin/dialogs.php index 14a37a9b..c8e075d5 100644 --- a/admin/dialogs.php +++ b/admin/dialogs.php @@ -1,6 +1,6 @@ -



    -

    - -

    - */ ?> -

    - +

    warnings == 0 ) ? true : false; // settings allow anyone to register - if( get_option( 'users_can_register' ) != 0 && $warnings_off ) { + if ( get_option( 'users_can_register' ) != 0 && $warnings_off ) { wpmem_a_warning_msg(1); } // settings allow anyone to comment - if( get_option( 'comment_registration' ) !=1 && $warnings_off ) { + if ( get_option( 'comment_registration' ) !=1 && $warnings_off ) { wpmem_a_warning_msg(2); - } - + } + // rss set to full text feeds - if( get_option( 'rss_use_excerpt' ) !=1 && $warnings_off ) { + if ( get_option( 'rss_use_excerpt' ) !=1 && $warnings_off ) { wpmem_a_warning_msg(3); - } + } // holding registrations but haven't changed default successful registration message - if( $warnings_off && $wpmem_settings['mod_reg'] == 1 && $wpmem_dialogs[3] == 'Congratulations! Your registration was successful.

    You may now login using the password that was emailed to you.' ) { + if ( $warnings_off && $wpmem->mod_reg == 1 && $wpmem_dialogs[3] == 'Congratulations! Your registration was successful.

    You may now login using the password that was emailed to you.' ) { wpmem_a_warning_msg(4); - } - + } + // haven't entered recaptcha api keys - if( $warnings_off && $wpmem_settings['captcha'] == 1 ) { + if ( $warnings_off && $wpmem->captcha == 1 ) { $wpmem_captcha = get_option('wpmembers_captcha'); - if( !$wpmem_captcha['recaptcha']['public'] || !$wpmem_captcha['recaptcha']['private'] ) { + if ( !$wpmem_captcha['recaptcha']['public'] || !$wpmem_captcha['recaptcha']['private'] ) { wpmem_a_warning_msg(6); } } - + } /** - * Assembles the various admin warning messages + * Assembles the various admin warning messages. * * @since 2.4.0 * - * @param int $msg The number for which message should be displayed + * @param int $msg The number for which message should be displayed. */ -function wpmem_a_warning_msg( $msg ) -{ +function wpmem_a_warning_msg( $msg ) { + $strong_msg = $remain_msg = $span_msg = ''; - switch( $msg ) { - - case 1: + switch ( $msg ) { + case 1: $strong_msg = __( 'Your WP settings allow anyone to register - this is not the recommended setting.', 'wp-members' ); $remain_msg = sprintf( __( 'You can %s change this here %s making sure the box next to "Anyone can register" is unchecked.', 'wp-members'), '', '' ); $span_msg = __( 'This setting allows a link on the /wp-login.php page to register using the WP native registration process thus circumventing any registration you are using with WP-Members. In some cases, this may suit the users wants/needs, but most users should uncheck this option. If you do not change this setting, you can choose to ignore these warning messages under WP-Members Settings.', 'wp-members' ); - break; - - case 2: + case 2: $strong_msg = __( 'Your WP settings allow anyone to comment - this is not the recommended setting.', 'wp-members' ); $remain_msg = sprintf( __( 'You can %s change this here %s by checking the box next to "Users must be registered and logged in to comment."', 'wp-members' ), '', '' ); $span_msg = __( 'This setting allows any users to comment, whether or not they are registered. Depending on how you are using WP-Members will determine whether you should change this setting or not. If you do not change this setting, you can choose to ignore these warning messages under WP-Members Settings.', 'wp-members' ); + break; - break; - - case 3: - + case 3: $strong_msg = __( 'Your WP settings allow full text rss feeds - this is not the recommended setting.', 'wp-members' ); $remain_msg = sprintf( __( 'You can %s change this here %s by changing "For each article in a feed, show" to "Summary."', 'wp-members' ), '' , '' ); $span_msg = __( 'Leaving this set to full text allows anyone to read your protected content in an RSS reader. Changing this to Summary prevents this as your feeds will only show summary text.', 'wp-members' ); - break; - - case 4: - + + case 4: $strong_msg = __( 'You have set WP-Members to hold registrations for approval', 'wp-members' ); $remain_msg = __( 'but you have not changed the default message for "Registration Completed" under "WP-Members Dialogs and Error Messages." You should change this message to let users know they are pending approval.', 'wp-members' ); - break; - case 5: - + case 5: $strong_msg = __( 'You have set WP-Members to turn off the registration process', 'wp-members' ); - $remain_msg = __( 'but you also set to moderate and/or email admin new registrations. You will need to set up a registration page for users to register.', 'wp-members' ); - + $remain_msg = __( 'but you also set to moderate and/or email admin new registrations. You will need to set up a registration page for users to register.', 'wp-members' ); break; - + case 6: - $strong_msg = __( 'You have turned on reCAPTCHA', 'wp-members'); $remain_msg = __( 'but you have not entered API keys. You will need both a public and private key. The CAPTCHA will not display unless a valid API key is included.', 'wp-members' ); - break; } - - if ( $span_msg ) { $span_msg = ' [why is this?]'; } + + if ( $span_msg ) { + $span_msg = ' [why is this?]'; + } echo '

    ' . $strong_msg . ' ' . $remain_msg . $span_msg . '

    '; } /** - * Assemble the side meta box + * Assemble the side meta box. * * @since 2.8 */ -function wpmem_a_meta_box() -{ +function wpmem_a_meta_box() { + ?>

    WP-Members Information

    @@ -171,7 +161,7 @@ function wpmem_a_meta_box()

    Find out how to get access to WP-Members private members forum, premium code snippets, tutorials, and add-on modules!

    - +

    ™!

     Chad Butler
    @@ -185,53 +175,53 @@ function wpmem_a_meta_box() /** - * Assemble the rocketgeek.com rss feed box + * Assemble the rocketgeek.com rss feed box. * * @since 2.8.0 */ -function wpmem_a_rss_box() -{ +function wpmem_a_rss_box() { + ?>

    'http://rocketgeek.com/feed/', //put your feed URL here - 'title' => __( 'Latest from RocketGeek', 'wp-members' ), - 'items' => 4, //how many posts to show + wp_widget_rss_output( array( + 'url' => 'http://rocketgeek.com/feed/', //put your feed URL here + 'title' => __( 'Latest from RocketGeek', 'wp-members' ), + 'items' => 4, //how many posts to show 'show_summary' => 0, - 'show_author' => 0, - 'show_date' => 0 - ));?> + 'show_author' => 0, + 'show_date' => 0, + ) );?>
    '; - wp_widget_rss_output(array( - 'url' => 'http://feeds.feedburner.com/butlerblog', - 'title' => __( 'Latest from ButlerBlog', 'wp-members' ), - 'items' => 5, + wp_widget_rss_output( array( + 'url' => 'http://feeds.feedburner.com/butlerblog', + 'title' => __( 'Latest from ButlerBlog', 'wp-members' ), + 'items' => 5, 'show_summary' => 0, - 'show_author' => 0, - 'show_date' => 1 - )); + 'show_author' => 0, + 'show_date' => 1, + ) ); echo "
    "; } diff --git a/admin/tab-captcha.php b/admin/tab-captcha.php index 5db0e977..a80b9279 100644 --- a/admin/tab-captcha.php +++ b/admin/tab-captcha.php @@ -1,6 +1,6 @@ ', '' ), 'wp-members' ); ?>
    - +
    @@ -36,24 +43,20 @@ function wpmem_a_build_captcha_options()
    -
    -
    +
    +
    - +

    - + - captcha == 1 ) { $show_update_button = true; ?> - - - + + + + @@ -82,9 +85,9 @@ function wpmem_a_build_captcha_options() captcha == 2 ) { + // setup defaults $defaults = array( 'characters' => 'ABCDEFGHJKLMNPQRSTUVWXYZ23456789', @@ -95,17 +98,17 @@ function wpmem_a_build_captcha_options() 'bg_color' => '255,255,255', 'font_size' => '12', 'kerning' => '14', - 'img_type' => 'png' + 'img_type' => 'png', ); - + $args = ( is_array( $wpmem_captcha['really_simple'] ) ) ? $wpmem_captcha['really_simple'] : array(); - + extract( wp_parse_args( $args, $defaults ) ); - + // explode colors $font_color = explode( ',', $font_color ); $bg_color = explode( ',', $bg_color ); - + $show_update_button = true; if ( is_plugin_active( 'really-simple-captcha/really-simple-captcha.php' ) ) { ?> @@ -154,60 +157,60 @@ function wpmem_a_build_captcha_options()

    ', '' ), 'wp-members' ); ?>

    - - - + if ( $show_update_button ) { ?> + + - - -
    @@ -61,14 +64,14 @@ function wpmem_a_build_captcha_options()

    ', '' ); ?>.

    ", '' ); ?>.
    :  
    -
     
      - + -
    + + + +
  • - $_POST['wpmem_captcha_publickey'], 'private' => $_POST['wpmem_captcha_privatekey'], - 'theme' => $_POST['wpmem_captcha_theme'] + 'theme' => $_POST['wpmem_captcha_theme'], ); } - if( $update_type == 'really_simple' ) { - if( array_key_exists( 'recaptcha', $settings ) ) { + if ( $update_type == 'really_simple' ) { + if ( array_key_exists( 'recaptcha', $settings ) ) { // updating really_simple but need to maintain recaptcha $new_settings['recaptcha'] = $settings['recaptcha']; } @@ -225,7 +228,7 @@ function wpmem_update_captcha() 'img_type' => $_POST['img_type'], ); } - + update_option( 'wpmembers_captcha', $new_settings ); return __( 'CAPTCHA was updated for WP-Members', 'wp-members' ); } diff --git a/admin/tab-dialogs.php b/admin/tab-dialogs.php index 1c697a5a..46cb594f 100644 --- a/admin/tab-dialogs.php +++ b/admin/tab-dialogs.php @@ -1,6 +1,6 @@ + __( "Restricted post (or page), displays above the login/registration form", 'wp-members' ), + __( "Username is taken", 'wp-members' ), + __( "Email is registered", 'wp-members' ), + __( "Registration completed", 'wp-members' ), + __( "User update", 'wp-members' ), + __( "Passwords did not match", 'wp-members' ), + __( "Password changes", 'wp-members' ), + __( "Username or email do not exist when trying to reset forgotten password", 'wp-members' ), + __( "Password reset", 'wp-members' ), + ); ?>
    - +
    @@ -56,27 +60,27 @@ function wpmem_a_build_dialogs()

    - +
    - + - - - + + + - -
     
     
    + +
    @@ -88,17 +92,17 @@ function wpmem_a_build_dialogs() /** - * Updates the dialog settings + * Updates the dialog settings. * * @since 2.8 * - * @return string The dialogs updated message + * @return string The dialogs updated message. */ -function wpmem_update_dialogs() -{ +function wpmem_update_dialogs() { + //check nonce check_admin_referer( 'wpmem-update-dialogs' ); - + $wpmem_dialogs = get_option( 'wpmembers_dialogs' ); for( $row = 0; $row < count( $wpmem_dialogs); $row++ ) { @@ -108,11 +112,11 @@ function wpmem_update_dialogs() update_option( 'wpmembers_dialogs', $wpmem_newdialogs ); $wpmem_dialogs = $wpmem_newdialogs; - + // Terms of Service - update_option( 'wpmembers_tos', $_POST['dialogs_tos'] ); - - return __( 'WP-Members dialogs were updated', 'wp-members' ); + update_option( 'wpmembers_tos', $_POST['dialogs_tos'] ); + + return __( 'WP-Members dialogs were updated', 'wp-members' ); } /** End of File **/ \ No newline at end of file diff --git a/admin/tab-emails.php b/admin/tab-emails.php index 0b76b375..8962dc63 100644 --- a/admin/tab-emails.php +++ b/admin/tab-emails.php @@ -1,6 +1,6 @@ mod_reg == 0 ) { $wpmem_email_title_arr = array( - array( __( "New Registration", 'wp-members' ), 'wpmembers_email_newreg' ) + array( __( "New Registration", 'wp-members' ), 'wpmembers_email_newreg' ), ); } else { - $wpmem_email_title_arr = array( + $wpmem_email_title_arr = array( array( __( "Registration is Moderated", 'wp-members' ), 'wpmembers_email_newmod' ), - array( __( "Registration is Moderated, User is Approved", 'wp-members' ), 'wpmembers_email_appmod' ) + array( __( "Registration is Moderated, User is Approved", 'wp-members' ), 'wpmembers_email_appmod' ), ); } array_push( $wpmem_email_title_arr, - array( __( "Password Reset", 'wp-members' ), 'wpmembers_email_repass' ) + array( __( "Password Reset", 'wp-members' ), 'wpmembers_email_repass' ), ); - if( $wpmem_settings['notify'] == 1 ) { + if ( $wpmem->notify == 1 ) { array_push( $wpmem_email_title_arr, - array( __( "Admin Notification", 'wp-members' ), 'wpmembers_email_notify' ) + array( __( "Admin Notification", 'wp-members' ), 'wpmembers_email_notify' ), ); } array_push( $wpmem_email_title_arr, - array( __( "Email Signature", 'wp-members' ), 'wpmembers_email_footer' ) - ); ?> + array( __( "Email Signature", 'wp-members' ), 'wpmembers_email_footer' ), + ); ?>
    -
    +

    WP-Members

    @@ -74,14 +78,14 @@ function wpmem_a_build_emails( $wpmem_settings )   John Smith


    - - - - + + @@ -89,23 +93,23 @@ function wpmem_a_build_emails( $wpmem_settings )
    - - + -
    - -   +
    + +   - - - + + +
    @@ -123,42 +127,42 @@ function wpmem_a_build_emails( $wpmem_settings ) /** - * Updates the email message settings + * Updates the email message settings. * * @since 2.8 * - * @return string The emails updated message + * @return string The emails updated message. */ -function wpmem_update_emails() -{ +function wpmem_update_emails() { + + global $wpmem; + //check nonce check_admin_referer( 'wpmem-update-emails' ); - - $wpmem_settings = get_option( 'wpmembers_settings' ); - + // update the email address (if applicable) ( $_POST['wp_mail_from'] ) ? update_option( 'wpmembers_email_wpfrom', $_POST['wp_mail_from'] ) : delete_option( 'wpmembers_email_wpfrom' ); ( $_POST['wp_mail_from_name'] ) ? update_option( 'wpmembers_email_wpname', $_POST['wp_mail_from_name'] ) : delete_option( 'wpmembers_email_wpname' ); - + // update the various emails being used - ( $wpmem_settings[5] == 0 ) ? $arr = array( 'wpmembers_email_newreg' ) : $arr = array( 'wpmembers_email_newmod', 'wpmembers_email_appmod' ); + ( $wpmem->mod_reg == 0 ) ? $arr = array( 'wpmembers_email_newreg' ) : $arr = array( 'wpmembers_email_newmod', 'wpmembers_email_appmod' ); array_push( $arr, 'wpmembers_email_repass' ); - ( $wpmem_settings[4] == 1 ) ? array_push( $arr, 'wpmembers_email_notify' ) : false; + ( $wpmem->notify == 1 ) ? array_push( $arr, 'wpmembers_email_notify' ) : false; array_push( $arr, 'wpmembers_email_footer' ); - - for( $row = 0; $row < ( count( $arr ) - 1 ); $row++ ) { + + for ( $row = 0; $row < ( count( $arr ) - 1 ); $row++ ) { $arr2 = array( "subj" => $_POST[$arr[$row] . '_subj'], - "body" => $_POST[$arr[$row] . '_body'] + "body" => $_POST[$arr[$row] . '_body'], ); update_option( $arr[$row], $arr2, false ); $arr2 = ''; } - + // updated the email footer update_option( $arr[$row], $_POST[$arr[$row] . '_body'], false ); - - return __('WP-Members emails were updated', 'wp-members'); + + return __( 'WP-Members emails were updated', 'wp-members' ); } diff --git a/admin/tab-options.php b/admin/tab-options.php index f762e133..4971c936 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -13,6 +13,12 @@ * @subpackage WP-Members * @author Chad Butler * @copyright 2006-2015 + * + * Functions included: + * * wpmem_a_build_options + * * wpmem_update_options + * * wpmem_admin_style_list + * * wpmem_admin_page_list */ @@ -20,17 +26,17 @@ * Builds the settings panel. * * @since 2.2.2 - * - * @param array $wpmem_settings */ -function wpmem_a_build_options( $wpmem_settings ) { - +function wpmem_a_build_options() { + + global $wpmem; + $admin_email = apply_filters( 'wpmem_notify_addr', get_option( 'admin_email' ) ); $chg_email = __( sprintf( '%sChange%s or %sFilter%s this address', '', '', '', '' ), 'wp-members' ); $help_link = __( sprintf( 'See the %sUsers Guide on plugin options%s.', '', '' ), 'wp-members' ); ?>
    - +
    @@ -53,39 +59,49 @@ function wpmem_a_build_options( $wpmem_settings ) {
    • - /> Posts + + Posts
    • - /> Pages + + Pages
    • - /> Posts + show_excerpt['post'] == 1 ) { echo "checked"; }?> /> Posts
    • - /> Pages + show_excerpt['page'] == 1 ) { echo "checked"; }?> /> Pages
    • - /> Posts + show_login['post'] == 1 ) { echo "checked"; }?> /> Posts
    • - /> Pages + show_login['page'] == 1 ) { echo "checked"; }?> /> Pages
    • - /> Posts + show_reg['post'] == 1 ) { echo "checked"; }?> /> Posts
    • - /> Pages + show_reg['page'] == 1 ) { echo "checked"; }?> /> Pages
    use_exp == true ) { $arr = array( array(__('Time-based expiration','wp-members'),'wpmem_settings_time_exp',__('Allows for access to expire','wp-members'),'use_exp'), array(__('Trial period','wp-members'),'wpmem_settings_trial',__('Allows for a trial period','wp-members'),'use_trial'), @@ -95,8 +111,8 @@ function wpmem_a_build_options( $wpmem_settings ) { for ( $row = 0; $row < count( $arr ); $row++ ) { ?>
  • - - />   + $arr[$row][3]; } ?> + $arr[$row][3] == 1 ) { echo "checked"; }?> />  
  • - - />   + $arr[$row][3]; } ?> + $arr[$row][3] == 1 ) { echo "checked"; }?> />  
  • - + attrib; ?>
  • />  
  • - + autoex; ?>
  • - + />      .
  • - user_pages['login']; if ( ! $wpmem_logurl ) { $wpmem_logurl = wpmem_use_ssl(); } ?>
  • @@ -150,7 +166,7 @@ function wpmem_a_build_options( $wpmem_settings ) {
  • - user_pages['register']; if ( ! $wpmem_regurl ) { $wpmem_regurl = wpmem_use_ssl(); } ?>
  • @@ -158,11 +174,11 @@ function wpmem_a_build_options( $wpmem_settings ) {  
    - +
  • - user_pages['profile']; if ( ! $wpmem_msurl ) { $wpmem_msurl = wpmem_use_ssl(); } ?>
  • @@ -176,12 +192,12 @@ function wpmem_a_build_options( $wpmem_settings ) {
  • - + -
  • - + cssurl; if ( ! $wpmem_cssurl ) { $wpmem_cssurl = wpmem_use_ssl(); } ?>
  • @@ -215,7 +231,6 @@ function wpmem_update_options() { //check nonce check_admin_referer( 'wpmem-update-settings' ); - $wpmem_settings_msurl = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? $_POST['wpmem_settings_msurl'] : ''; $wpmem_settings_mspage = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_mspage']; if ( $wpmem_settings_msurl != wpmem_use_ssl() && $wpmem_settings_msurl != 'use_custom' && ! $wpmem_settings_mspage ) { @@ -231,7 +246,7 @@ function wpmem_update_options() { } else { $regurl = $wpmem_settings_regpage; } - + $wpmem_settings_logurl = ( $_POST['wpmem_settings_logpage'] == 'use_custom' ) ? $_POST['wpmem_settings_logurl'] : ''; $wpmem_settings_logpage = ( $_POST['wpmem_settings_logpage'] == 'use_custom' ) ? '' : $_POST['wpmem_settings_logpage']; if ( $wpmem_settings_logurl != wpmem_use_ssl() && $wpmem_settings_logurl != 'use_custom' && ! $wpmem_settings_logpage ) { @@ -239,12 +254,12 @@ function wpmem_update_options() { } else { $logurl = $wpmem_settings_logpage; } - + $wpmem_settings_cssurl = $_POST['wpmem_settings_cssurl']; $cssurl = ( $wpmem_settings_cssurl != wpmem_use_ssl() ) ? trim( $wpmem_settings_cssurl ) : ''; - + $wpmem_settings_style = ( isset( $_POST['wpmem_settings_style'] ) ) ? $_POST['wpmem_settings_style'] : false; - + $wpmem_autoex = array ( 'auto_ex' => isset( $_POST['wpmem_autoex'] ) ? $_POST['wpmem_autoex'] : 0, 'auto_ex_len' => isset( $_POST['wpmem_autoex_len'] ) ? $_POST['wpmem_autoex_len'] : '', @@ -253,27 +268,27 @@ function wpmem_update_options() { $wpmem_newsettings = array( 'version' => WPMEM_VERSION, 'block' => array( - 'post' => ( isset( $_POST['wpmem_block_post'] ) ) ? 1 : 0, - 'page' => ( isset( $_POST['wpmem_block_page'] ) ) ? 1 : 0, + 'post' => ( isset( $_POST['wpmem_block_post'] ) ) ? $_POST['wpmem_block_post'] : 0, + 'page' => ( isset( $_POST['wpmem_block_page'] ) ) ? $_POST['wpmem_block_page'] : 0, ), 'show_excerpt' => array( - 'post' => ( isset( $_POST['wpmem_show_excerpt_post'] ) ) ? 1 : 0, - 'page' => ( isset( $_POST['wpmem_show_excerpt_page'] ) ) ? 1 : 0, + 'post' => ( isset( $_POST['wpmem_show_excerpt_post'] ) ) ? $_POST['wpmem_show_excerpt_post'] : 0, + 'page' => ( isset( $_POST['wpmem_show_excerpt_page'] ) ) ? $_POST['wpmem_show_excerpt_page'] : 0, ), 'show_reg' => array( - 'post' => ( isset( $_POST['wpmem_show_reg_post'] ) ) ? 1 : 0, - 'page' => ( isset( $_POST['wpmem_show_reg_page'] ) ) ? 1 : 0, + 'post' => ( isset( $_POST['wpmem_show_reg_post'] ) ) ? $_POST['wpmem_show_reg_post'] : 0, + 'page' => ( isset( $_POST['wpmem_show_reg_page'] ) ) ? $_POST['wpmem_show_reg_page'] : 0, ), 'show_login' => array( - 'post' => ( isset( $_POST['wpmem_show_login_post'] ) ) ? 1 : 0, - 'page' => ( isset( $_POST['wpmem_show_login_page'] ) ) ? 1 : 0, + 'post' => ( isset( $_POST['wpmem_show_login_post'] ) ) ? $_POST['wpmem_show_login_post'] : 0, + 'page' => ( isset( $_POST['wpmem_show_login_page'] ) ) ? $_POST['wpmem_show_login_page'] : 0, ), - 'notify' => ( isset( $_POST['wpmem_settings_notify'] ) ) ? 1 : 0, - 'mod_reg' => ( isset( $_POST['wpmem_settings_moderate'] ) ) ? 1 : 0, - 'captcha' => ( isset( $_POST['wpmem_settings_captcha'] ) ) ? $_POST['wpmem_settings_captcha'] : 0, - 'use_exp' => ( isset( $_POST['wpmem_settings_time_exp'] ) ) ? 1 : 0, - 'use_trial' => ( isset( $_POST['wpmem_settings_trial'] ) ) ? 1 : 0, - 'warnings' => ( isset( $_POST['wpmem_settings_ignore_warnings'] ) ) ? 1 : 0, + 'notify' => ( isset( $_POST['wpmem_settings_notify'] ) ) ? $_POST['wpmem_settings_notify'] : 0, + 'mod_reg' => ( isset( $_POST['wpmem_settings_moderate'] ) ) ? $_POST['wpmem_settings_moderate'] : 0, + 'captcha' => ( isset( $_POST['wpmem_settings_captcha'] ) ) ? $_POST['wpmem_settings_captcha'] : 0, + 'use_exp' => ( isset( $_POST['wpmem_settings_time_exp'] ) ) ? $_POST['wpmem_settings_time_exp'] : 0, + 'use_trial' => ( isset( $_POST['wpmem_settings_trial'] ) ) ? $_POST['wpmem_settings_trial'] : 0, + 'warnings' => ( isset( $_POST['wpmem_settings_ignore_warnings'] ) ) ? $_POST['wpmem_settings_ignore_warnings'] : 0, 'user_pages' => array( 'profile' => ( $msurl ) ? $msurl : '', 'register' => ( $regurl ) ? $regurl : '', @@ -282,17 +297,17 @@ function wpmem_update_options() { 'cssurl' => ( $cssurl ) ? $cssurl : '', 'style' => $wpmem_settings_style, 'autoex' => $wpmem_autoex, - 'attrib' => ( isset( $_POST['attribution'] ) ) ? 1 : 0, + 'attrib' => ( isset( $_POST['attribution'] ) ) ? $_POST['attribution'] : 0, ); - + /* if we are setting registration to be moderated, check to see if the current admin has been activated so they don't accidentally lock themselves out later */ - if ( isset( $_POST['wpmem_settings_moderate'] ) == 1) { + if ( isset( $_POST['wpmem_settings_moderate'] ) == 1 ) { global $current_user; get_currentuserinfo(); $user_ID = $current_user->ID; @@ -300,7 +315,9 @@ function wpmem_update_options() { } update_option( 'wpmembers_settings', $wpmem_newsettings ); - $wpmem_settings = $wpmem_newsettings; + + global $wpmem; + $wpmem = new WP_Members(); return __( 'WP-Members settings were updated', 'wp-members' ); } @@ -328,7 +345,7 @@ function wpmem_admin_style_list( $style ) { 'Twenty Ten' => WPMEM_DIR . 'css/wp-members.css', 'Kubrick' => WPMEM_DIR . 'css/wp-members-kubrick.css', ); - + /** * Filters the list of stylesheets in the plugin options dropdown. * @@ -337,7 +354,7 @@ function wpmem_admin_style_list( $style ) { * @param array $list An array of stylesheets that can be applied to the plugin's forms. */ $list = apply_filters( 'wpmem_admin_style_list', $list ); - + $selected = false; foreach ( $list as $name => $location ) { $selected = ( $location == $style ) ? true : $selected; @@ -345,7 +362,7 @@ function wpmem_admin_style_list( $style ) { } $selected = ( ! $selected ) ? ' selected' : ''; echo ''; - + return; } @@ -358,9 +375,9 @@ function wpmem_admin_style_list( $style ) { * @param string $val */ function wpmem_admin_page_list( $val, $show_custom_url = true ) { - + $selected = ( $val == 'http://' ) ? 'select a page' : false; - $pages = get_pages(); + $pages = get_pages(); echo ''; From 4ec723f83ca2a95ba92de8f5171aa05631beea8f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 13 Apr 2015 17:38:26 -0500 Subject: [PATCH 0043/1694] manage new settings format in admin, code standards --- admin/post.php | 191 +++++++++++++++++++++++++++---------------------- 1 file changed, 105 insertions(+), 86 deletions(-) diff --git a/admin/post.php b/admin/post.php index 4431c320..4c6d5b7d 100644 --- a/admin/post.php +++ b/admin/post.php @@ -1,6 +1,6 @@ - - current_action(); $sendback = ''; - switch( $action ) { - + switch ( $action ) { + case ( 'block' ): case ( 'unblock' ): /** validate nonce **/ @@ -66,25 +78,23 @@ function wpmem_posts_page_load() $posts = ( isset( $_REQUEST['post'] ) ) ? $_REQUEST['post'] : ''; /** update posts **/ $x = ''; - if( $posts ) { - foreach( $posts as $post_id ) { + if ( $posts ) { + foreach ( $posts as $post_id ) { $x++; $post = get_post( $post_id ); $type = $post->post_type; // update accordingly - if( ( $type == 'post' && WPMEM_BLOCK_POSTS == 0 ) || - ( $type == 'page' && WPMEM_BLOCK_PAGES == 0 ) ) { - if( $action == 'block' ) { + if ( ( $type == 'post' && $wpmem->block['post'] == 0 ) || ( $type == 'page' && $wpmem->block['page'] == 0 ) ) { + if ( $action == 'block' ) { update_post_meta( $post_id, '_wpmem_block', 1 ); } else { delete_post_meta( $post_id, '_wpmem_block' ); } } - - if( ( $type == 'post' && WPMEM_BLOCK_POSTS == 1 ) || - ( $type == 'page' && WPMEM_BLOCK_PAGES == 1 ) ) { - if( $action == 'unblock' ) { - update_post_meta( $post_id, '_wpmem_block', 0 ); + + if ( ( $type == 'post' && $wpmem->block['post'] == 1 ) || ( $type == 'page' && $wpmem->block['page'] == 1 ) ) { + if ( $action == 'unblock' ) { + update_post_meta( $post_id, '_wpmem_block', 0 ); } else { delete_post_meta( $post_id, '_wpmem_block' ); } @@ -92,10 +102,10 @@ function wpmem_posts_page_load() } /** set the return message */ $arr = array( - 'a' => $action, - 'n' => $x + 'a' => $action, + 'n' => $x, ); - if( $type == 'page' ) { + if ( $type == 'page' ) { $arr['post_type'] = 'page'; } $sendback = add_query_arg( array( $arr ), '', $sendback ); @@ -104,7 +114,7 @@ function wpmem_posts_page_load() $sendback = add_query_arg( array( 'a' => 'none' ), '', $sendback ); } break; - + default: return; @@ -117,14 +127,14 @@ function wpmem_posts_page_load() /** - * Function to echo admin update message + * Function to echo admin update message. * * @since 2.8.2 */ -function wpmem_posts_admin_notices() -{ +function wpmem_posts_admin_notices() { + global $pagenow, $post_type; - if( $pagenow == 'edit.php' && isset( $_REQUEST['a'] ) ) { + if ( $pagenow == 'edit.php' && isset( $_REQUEST['a'] ) ) { $action = ( $_REQUEST['a'] == 'block' ) ? 'blocked' : 'unblocked'; echo '

    ' . $_REQUEST['n'] . ' ' . $post_type . ' ' . $action . '

    '; } @@ -136,24 +146,28 @@ function wpmem_posts_admin_notices() * * @since 2.8 */ -function wpmem_block_meta_add() -{ +function wpmem_block_meta_add() { + /** - * Filter the post meta box title + * Filter the post meta box title. * * @since 2.9.0 + * + * @param Post restriction title. */ $post_title = apply_filters( 'wpmem_admin_post_meta_title', __( 'Post Restriction', 'wp-members' ) ); /** - * Filter the page meta box title + * Filter the page meta box title. * * @since 2.9.0 + * + * @param Page restriction title. */ $page_title = apply_filters( 'wpmem_admin_page_meta_title', __( 'Page Restriction', 'wp-members' ) ); add_meta_box( 'wpmem-block-meta-id', $post_title, 'wpmem_block_meta', 'post', 'side', 'high' ); - add_meta_box( 'wpmem-block-meta-id', $page_title, 'wpmem_block_meta', 'page', 'side', 'high' ); + add_meta_box( 'wpmem-block-meta-id', $page_title, 'wpmem_block_meta', 'page', 'side', 'high' ); } @@ -165,18 +179,18 @@ function wpmem_block_meta_add() * @global $post The WordPress post object. */ function wpmem_block_meta() { - - global $post; - wp_nonce_field( 'wpmem_block_meta_nonce', 'wpmem_block_meta_nonce' ); + global $post, $wpmem; + + wp_nonce_field( 'wpmem_block_meta_nonce', 'wpmem_block_meta_nonce' ); $post_type = get_post_type_object( $post->post_type ); - if( ( $post->post_type == 'post' && WPMEM_BLOCK_POSTS == 1 ) || ( $post->post_type == 'page' && WPMEM_BLOCK_PAGES == 1 ) ) { + if ( $wpmem->block[ $post->post_type ] == 1 ) { $block = 0; $notice_text = 'blocked'; $text = 'Unblock'; - } elseif( ( $post->post_type == 'post' && WPMEM_BLOCK_POSTS == 0 ) || ( $post->post_type == 'page' && WPMEM_BLOCK_PAGES == 0 ) ) { + } elseif ( $wpmem->block[ $post->post_type ] == 0 ) { $block = 1; $notice_text = 'not blocked'; $text = 'Block'; @@ -191,15 +205,15 @@ function wpmem_block_meta() { printf( 'Edit', $admin_url ); ?>

    -

    +

    ID, $meta, true ), '1' ); ?> /> ID, $meta, true ), '0' ); ?> /> -

    - + Date: Mon, 13 Apr 2015 21:15:40 -0500 Subject: [PATCH 0044/1694] new settings, code standards --- admin/user-profile.php | 88 +++++++------- admin/users.php | 253 +++++++++++++++++++++++------------------ 2 files changed, 189 insertions(+), 152 deletions(-) diff --git a/admin/user-profile.php b/admin/user-profile.php index 32b6856d..cf111a9e 100644 --- a/admin/user-profile.php +++ b/admin/user-profile.php @@ -13,6 +13,10 @@ * @subpackage WP-Members * @author Chad Butler * @copyright 2006-2015 + * + * Functions included: + * * wpmem_admin_fields + * * wpmem_admin_update */ @@ -30,12 +34,12 @@ * @global array $current_screen The WordPress screen object * @global int $user_ID The user ID */ -function wpmem_admin_fields() -{ - global $current_screen, $user_ID; +function wpmem_admin_fields() { + + global $current_screen, $user_ID, $wpmem; $user_id = ( $current_screen->id == 'profile' ) ? $user_ID : $_REQUEST['user_id']; ?> -

    ' . __( '(required)' ) . '' : ''; - + $show_field = ' '; $val = htmlspecialchars( get_user_meta( $user_id, $meta[2], true ) ); - if( $meta[3] == 'checkbox' || $meta[3] == 'select' ) { - $valtochk = $val; + if ( $meta[3] == 'checkbox' || $meta[3] == 'select' ) { + $valtochk = $val; $val = $meta[7]; } $show_field.= wpmem_create_formfield( $meta[2], $meta[3], $val, $valtochk ) . ' '; - + /** * Filter the profile field. * @@ -98,7 +102,7 @@ function wpmem_admin_fields() } // see if reg is moderated, and if the user has been activated - if( WPMEM_MOD_REG == 1 ) { + if ( $wpmem->mod_reg == 1 ) { $user_active_flag = get_user_meta( $user_id, 'active', true ); switch( $user_active_flag ) { @@ -106,8 +110,8 @@ function wpmem_admin_fields() $label = __( 'Activate this user?', 'wp-members' ); $action = 1; break; - - case 0: + + case 0: $label = __( 'Reactivate this user?', 'wp-members' ); $action = 1; break; @@ -124,14 +128,14 @@ function wpmem_admin_fields() - use_exp == 1 ) { + if ( ( $wpmem->mod_reg == 1 && get_user_meta( $user_id, 'active', true ) == 1 ) || ( $wpmwm->mod_reg != 1 ) ) { wpmem_a_extenduser( $user_id ); - } + } } ?> @@ -147,18 +151,20 @@ function wpmem_admin_fields() * @param array $wpmem_fields The WP-Members fields. */ do_action( 'wpmem_admin_after_profile', $user_id, $wpmem_fields ); ?> - + $val ) { - if( ! in_array( $key, $exclude ) ) { + foreach ( $fields as $key => $val ) { + if ( ! in_array( $key, $exclude ) ) { update_user_meta( $user_id, $key, $val ); } } - if( WPMEM_MOD_REG == 1 ) { + if ( $wpmem->mod_reg == 1 ) { $wpmem_activate_user = ( isset( $_POST['activate_user'] ) == '' ) ? -1 : $_POST['activate_user']; - if( $wpmem_activate_user == 1 ) { + if ( $wpmem_activate_user == 1 ) { wpmem_a_activate_user( $user_id, $chk_pass ); - } elseif( $wpmem_activate_user == 0 ) { + } elseif ( $wpmem_activate_user == 0 ) { wpmem_a_deactivate_user( $user_id ); } } - ( WPMEM_USE_EXP == 1 ) ? wpmem_a_extend_user( $user_id ) : ''; - + ( $wpmem->use_exp == 1 ) ? wpmem_a_extend_user( $user_id ) : ''; + /** * Fires after the user profile is updated. * @@ -223,7 +229,7 @@ function wpmem_admin_update() { * @param int $user_id The user ID. */ do_action( 'wpmem_admin_after_user_update', $user_id ); - + return; } diff --git a/admin/users.php b/admin/users.php index a6a84331..2545505d 100644 --- a/admin/users.php +++ b/admin/users.php @@ -1,6 +1,6 @@ All Users page. * @@ -13,6 +13,22 @@ * @subpackage WP-Members * @author Chad Butler * @copyright 2006-2015 + * + * Functions included: + * * wpmem_bulk_user_action + * * wpmem_insert_activate_link + * * wpmem_users_page_load + * * wpmem_users_admin_notices + * * wpmem_users_views + * * wpmem_add_user_column + * * wpmem_add_user_column_content + * * wpmem_a_activate_user + * * wpmem_a_deactivate_user + * * wpmem_a_pre_user_query + * * wpmem_set_new_user_non_active + * * wpmem_set_activated_user + * * wpmem_set_deactivated_user + * * wpmem_set_user_status */ @@ -28,37 +44,36 @@ add_action( 'wpmem_post_register_data', 'wpmem_set_new_user_non_active' ); add_action( 'wpmem_user_activated', 'wpmem_set_activated_user' ); add_action( 'wpmem_user_deactivated', 'wpmem_set_deactivated_user' ); -if( WPMEM_MOD_REG == 1 ) { +global $wpmem; // @todo Is there a better way to do this? +if ( $wpmem->mod_reg == 1 ) { add_filter( 'user_row_actions', 'wpmem_insert_activate_link', 10, 2 ); } /** - * Function to add activate/export to the bulk dropdown list + * Function to add activate/export to the bulk dropdown list. * * @since 2.8.2 */ -function wpmem_bulk_user_action() -{ ?> - - ID ) ) { - + if ( current_user_can( 'edit_users', $user_object->ID ) ) { + $var = get_user_meta( $user_object->ID, 'active', true ); - - if( $var != 1 ) { + + if ( $var != 1 ) { $url = "users.php?action=activate-single&user=$user_object->ID"; $url = wp_nonce_url( $url, 'activate-user' ); $actions['activate'] = 'Activate'; } } - return $actions; + return $actions; } /** - * Function to handle bulk actions at page load + * Function to handle bulk actions at page load. * * @since 2.8.2 * * @uses WP_Users_List_Table */ -function wpmem_users_page_load() -{ +function wpmem_users_page_load() { + // if exporting all users, do it, then exit - if( isset( $_REQUEST['export_all'] ) && $_REQUEST['export_all'] == __( 'Export All Users', 'wp-members' ) ) { + if ( isset( $_REQUEST['export_all'] ) && $_REQUEST['export_all'] == __( 'Export All Users', 'wp-members' ) ) { include_once( WPMEM_PATH . 'admin/user-export.php' ); $today = date( "m-d-y" ); wpmem_export_users( array( 'export'=>'all', 'filename'=>'user-export-' . $today . '.csv' ), '' ); exit(); } - + $wp_list_table = _get_list_table( 'WP_Users_List_Table' ); $action = $wp_list_table->current_action(); $sendback = ''; - - if( $action == 'activate' || 'activate-single' ) { + + if ( $action == 'activate' || 'activate-single' ) { // find out if we need to set passwords $chk_pass = false; $wpmem_fields = get_option( 'wpmembers_fields' ); - foreach( $wpmem_fields as $field ) { - if( $field[2] == 'password' && $field[4] == 'y' ) { - $chk_pass = true; + foreach ( $wpmem_fields as $field ) { + if ( $field[2] == 'password' && $field[4] == 'y' ) { + $chk_pass = true; break; } } } - - switch( $action ) { - + + switch ( $action ) { + case 'activate': - + /** validate nonce */ check_admin_referer( 'bulk-users' ); - + /** get the users */ $users = $_REQUEST['users']; /** update the users */ $x = 0; - foreach( $users as $user ) { + foreach ( $users as $user ) { // check to see if the user is already activated, if not, activate - if( ! get_user_meta( $user, 'active', true ) ) { + if ( ! get_user_meta( $user, 'active', true ) ) { wpmem_a_activate_user( $user, $chk_pass ); $x++; } } - + /** set the return message */ $sendback = add_query_arg( array('activated' => $x . ' users activated' ), $sendback ); - break; - + case 'activate-single': - + /** validate nonce */ check_admin_referer( 'activate-user' ); - + /** get the users */ $users = $_REQUEST['user']; /** check to see if the user is already activated, if not, activate */ - if( ! get_user_meta( $users, 'active', true ) ) { - + if ( ! get_user_meta( $users, 'active', true ) ) { + wpmem_a_activate_user( $users, $chk_pass ); - + /** get the user data */ $user_info = get_userdata( $users ); /** set the return message */ $sendback = add_query_arg( array('activated' => "$user_info->user_login activated" ), $sendback ); - + } else { /** get the return message */ $sendback = add_query_arg( array('activated' => "That user is already active" ), $sendback ); - + } - break; - + case 'show': add_action( 'pre_user_query', 'wpmem_a_pre_user_query' ); return; break; - + case 'export': $users = ( isset( $_REQUEST['users'] ) ) ? $_REQUEST['users'] : false; @@ -180,7 +193,7 @@ function wpmem_users_page_load() wpmem_export_users( array( 'export'=>'selected' ), $users ); return; break; - + default: return; break; @@ -195,53 +208,67 @@ function wpmem_users_page_load() /** - * Function to echo admin update message + * Function to echo admin update message. * * @since 2.8.2 */ -function wpmem_users_admin_notices() -{ +function wpmem_users_admin_notices() { + global $pagenow, $user_action_msg; - if( $pagenow == 'users.php' && isset( $_REQUEST['activated'] ) ) { + if( $pagenow == 'users.php' && isset( $_REQUEST['activated'] ) ) { $message = $_REQUEST['activated']; echo "

    {$message}

    "; } - if( $user_action_msg ) { + if ( $user_action_msg ) { echo "

    {$user_action_msg}

    "; } } /** - * Function to add user views to the top list + * Function to add user views to the top list. * * @since 2.8.2 * * @param array $views * @return array $views */ -function wpmem_users_views( $views ) -{ - $arr = array(); - if( defined( 'WPMEM_USE_EXP' ) && WPMEM_USE_EXP == 1 ) { $arr[] = 'Pending'; } - if( defined( 'WPMEM_USE_TRL' ) && WPMEM_USE_TRL == 1 ) { $arr[] = 'Trial'; } - if( defined( 'WPMEM_USE_EXP' ) && WPMEM_USE_EXP == 1 ) { $arr[] = 'Subscription'; $arr[] = 'Expired'; } - if( defined( 'WPMEM_MOD_REG' ) && WPMEM_MOD_REG == 1 ) { $arr[] = 'Not Active'; } +function wpmem_users_views( $views ) { + + global $wpmem; + + $arr = array(); + if ( $wpmem->use_exp == 1 ) { + $arr[] = 'Pending'; + } + if ( $wpmem->use_trial == 1 ) { + $arr[] = 'Trial'; + } + if ( $wpmem->use_exp == 1 ) { + $arr[] = 'Subscription'; + $arr[] = 'Expired'; + } + if ( $wpmem->mod_reg == 1 ) { + $arr[] = 'Not Active'; + } $arr[] = 'Not Exported'; $show = ( isset( $_GET['show'] ) ) ? $_GET['show'] : false; - - for( $row = 0; $row < count( $arr ); $row++ ) - { + + for ( $row = 0; $row < count( $arr ); $row++ ) { $link = "users.php?action=show&show="; $lcas = str_replace( " ", "", strtolower( $arr[$row] ) ); $link.= $lcas; $curr = ( $show == $lcas ) ? ' class="current"' : ''; - + $echolink = true; - if( $lcas == "notactive" && WPMEM_MOD_REG != 1 ) { $echolink = false; } + if ( $lcas == "notactive" && $wpmem->mod_reg != 1 ) { + $echolink = false; + } - if( $echolink ) { $views[$lcas] = "$arr[$row] "; } + if ( $echolink ) { + $views[$lcas] = "$arr[$row] "; + } } /** @todo if $show, then run function search query for the users */ @@ -251,59 +278,59 @@ function wpmem_users_views( $views ) /** - * Function to add custom user columns to the user table + * Function to add custom user columns to the user table. * * @since 2.8.2 * * @param array $columns * @return array $columns */ -function wpmem_add_user_column( $columns ) -{ - global $wpmem_user_columns; +function wpmem_add_user_column( $columns ) { + + global $wpmem_user_columns, $wpmem; $wpmem_user_columns = get_option( 'wpmembers_utfields' ); - if( $wpmem_user_columns ) { - foreach( $wpmem_user_columns as $key => $val ) { + if ( $wpmem_user_columns ) { + foreach ( $wpmem_user_columns as $key => $val ) { - if( $key == 'active' ) { + if ( $key == 'active' ) { - if( WPMEM_MOD_REG == 1 ) { + if ( $wpmem->mod_reg == 1 ) { $columns[$key] = $val; } - + } else { $columns[$key] = $val; } } } - + return $columns; } /** - * Function to add the user content to the custom column + * Function to add the user content to the custom column. * * @since 2.8.2 * - * @param $value - * @param $column_name - * @param $user_id - * @return The user value for the custom column + * @param $value + * @param $column_name + * @param $user_id + * @return The user value for the custom column. */ function wpmem_add_user_column_content( $value, $column_name, $user_id ) { // is the column a WP-Members column? - global $wpmem_user_columns; + global $wpmem_user_columns, $wpmem; $is_wpmem = ( is_array( $wpmem_user_columns ) && array_key_exists( $column_name, $wpmem_user_columns ) ) ? true : false; + + if ( $is_wpmem ) { - if( $is_wpmem ) { - - switch( $column_name ) { + switch ( $column_name ) { case 'active': - if( WPMEM_MOD_REG == 1 ) { + if ( $wpmem->mod_reg == 1 ) { /** * If the column is "active", then return the value or empty. * Returning in here keeps us from displaying another value. @@ -322,20 +349,20 @@ function wpmem_add_user_column_content( $value, $column_name, $user_id ) { $user_info = get_userdata( $user_id ); return $user_info->$column_name; break; - + default: return get_user_meta( $user_id, $column_name, true ); break; } - + } - + return $value; } /** - * Activates a user + * Activates a user. * * If registration is moderated, sets the activated flag * in the usermeta. Flag prevents login when WPMEM_MOD_REG @@ -344,36 +371,40 @@ function wpmem_add_user_column_content( $value, $column_name, $user_id ) { * * @since 2.4 * - * @param int $user_id - * @param bool $chk_pass - * @uses $wpdb WordPress Database object + * @param int $user_id + * @param bool $chk_pass + * @uses $wpdb WordPress Database object. */ -function wpmem_a_activate_user( $user_id, $chk_pass = false ) -{ +function wpmem_a_activate_user( $user_id, $chk_pass = false ) { + + global $wpmem; + // define new_pass $new_pass = ''; - + // If passwords are user defined skip this - if( ! $chk_pass ) { + if ( ! $chk_pass ) { // generates a password to send the user $new_pass = wp_generate_password(); $new_hash = wp_hash_password( $new_pass ); - + // update the user with the new password global $wpdb; $wpdb->update( $wpdb->users, array( 'user_pass' => $new_hash ), array( 'ID' => $user_id ), array( '%s' ), array( '%d' ) ); } - + // if subscriptions can expire, set the user's expiration date - if( WPMEM_USE_EXP == 1 ) { wpmem_set_exp( $user_id ); } + if( $wpmem->use_exp == 1 ) { + wpmem_set_exp( $user_id ); + } // generate and send user approved email to user require_once( WPMEM_PATH . 'wp-members-email.php' ); wpmem_inc_regemail( $user_id, $new_pass, 2 ); - + // set the active flag in usermeta update_user_meta( $user_id, 'active', 1 ); - + /** * Fires after the user activation process is complete. * @@ -382,13 +413,13 @@ function wpmem_a_activate_user( $user_id, $chk_pass = false ) * @param int $user_id The user's ID. */ do_action( 'wpmem_user_activated', $user_id ); - + return; } /** - * Deactivates a user + * Deactivates a user. * * Reverses the active flag from the activation process * preventing login when registration is moderated. @@ -399,7 +430,7 @@ function wpmem_a_activate_user( $user_id, $chk_pass = false ) */ function wpmem_a_deactivate_user( $user_id ) { update_user_meta( $user_id, 'active', 0 ); - + /** * Fires after the user deactivation process is complete. * @@ -418,8 +449,8 @@ function wpmem_a_deactivate_user( $user_id ) { * * @param $user_search */ -function wpmem_a_pre_user_query( $user_search ) -{ +function wpmem_a_pre_user_query( $user_search ) { + global $wpdb; $show = $_GET['show']; switch ( $show ) { @@ -500,7 +531,7 @@ function wpmem_set_deactivated_user( $user_id ) { /** - * Updates the user_status value in the wp_users table + * Updates the user_status value in the wp_users table. * * @param $user_id * @param $status @@ -511,4 +542,4 @@ function wpmem_set_user_status( $user_id, $status ) { return; } -/** End of File **/ +/** End of File **/ \ No newline at end of file From 9eacd922e84a739cc1df703c39d3885035ff7c5a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 13 Apr 2015 22:06:40 -0500 Subject: [PATCH 0045/1694] new settings, whitespace cleanup --- wp-members-core.php | 217 +++++++++++++++++++++++--------------------- 1 file changed, 112 insertions(+), 105 deletions(-) diff --git a/wp-members-core.php b/wp-members-core.php index 11d2f048..f14c02a4 100644 --- a/wp-members-core.php +++ b/wp-members-core.php @@ -82,7 +82,7 @@ function wpmem() { * @param string $wpmem_regchk The value of wpmem_regchk. * @param string $wpmem_a The $wpmem_a action. * @return string $wpmem_regchk Filtered or unfiltered $wpmem_regchk value. - */ + */ $wpmem_regchk = apply_filters( 'wpmem_regchk', $wpmem_regchk, $wpmem_a ); } endif; @@ -97,21 +97,25 @@ function wpmem() { * * @since 2.0 * + * @global object $wpmem The WP_Members object. * @global var $wpmem_a The action variable received from wpmem(). * @global string $wpmem_regchk Contains messages returned from wpmem() action functions. * @global string $wpmem_themsg Contains messages to be output. * @global string $wpmem_captcha_err Contains error message for reCAPTCHA. - * @global array $post Needed for protecting comments. + * @global object $post The post object. * @param string $content * @return string $content */ function wpmem_securify( $content = null ) { - + + global $wpmem, $wpmem_regchk, $wpmem_themsg, $wpmem_a, $post; + + $post_type = get_post_type( $post ); + $content = ( is_single() || is_page() ) ? $content : wpmem_do_excerpt( $content ); - if ( ( ! wpmem_test_shortcode( $content, 'wp-members' ) ) ) { - global $wpmem_regchk, $wpmem_themsg, $wpmem_a; - + if ( ( ! wpmem_test_shortcode( $content, 'wp-members' ) ) ) { + if ( $wpmem_regchk == "captcha" ) { global $wpmem_captcha_err; $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; @@ -119,9 +123,9 @@ function wpmem_securify( $content = null ) { // Block/unblock Posts if ( ! is_user_logged_in() && wpmem_block() == true ) { - + // protects comments if user is not logged in - global $post; + //global $post; /** * Filter the post password. * @@ -129,8 +133,8 @@ function wpmem_securify( $content = null ) { * * @param string The autogenerated post password. */ - $post->post_password = apply_filters( 'wpmem_post_password' , wp_generate_password() ); - + //$post->post_password = apply_filters( 'wpmem_post_password' , wp_generate_password() ); + include_once( WPMEM_PATH . 'wp-members-dialogs.php' ); // show the login and registration forms @@ -138,34 +142,34 @@ function wpmem_securify( $content = null ) { // empty content in any of these scenarios $content = ''; - - switch( $wpmem_regchk ) { - + + switch ( $wpmem_regchk ) { + case "loginfailed": $content = wpmem_inc_loginfailed(); break; - + case "success": $content = wpmem_inc_regmessage( $wpmem_regchk, $wpmem_themsg ); $content = $content . wpmem_inc_login(); break; - + default: $content = wpmem_inc_regmessage( $wpmem_regchk, $wpmem_themsg ); $content = $content . wpmem_inc_registration(); break; } - + } else { - + // toggle shows excerpt above login/reg on posts/pages global $wp_query; if ( $wp_query->query_vars['page'] > 1 ) { - + // shuts down excerpts on multipage posts if not on first page $content = ''; - - } elseif ( WPMEM_SHOW_EXCERPT == 1 ) { + + } elseif ( $wpmem->show_excerpt[ $post->post_type ] == 1 ) { if ( ! stristr( $content, 'show_reg[ $post_type ] == 1 ) ? $content . wpmem_inc_registration() : $content; } - // Protects comments if expiration module is used and user is expired } elseif ( is_user_logged_in() && wpmem_block() == true ){ - $content = ( WPMEM_USE_EXP == 1 && function_exists( 'wpmem_do_expmessage' ) ) ? wpmem_do_expmessage( $content ) : $content; - + $content = ( $wpmem->use_exp == 1 && function_exists( 'wpmem_do_expmessage' ) ) ? wpmem_do_expmessage( $content ) : $content; + } - } - + /** * Filter the value of $content after wpmem_securify has run. * @@ -204,16 +206,16 @@ function wpmem_securify( $content = null ) { * @param string $content The content after securify has run. */ $content = apply_filters( 'wpmem_securify', $content ); - + if ( strstr( $content, '[wpmem_txt]' ) ) { // fix the wptexturize remove_filter( 'the_content', 'wpautop' ); remove_filter( 'the_content', 'wptexturize' ); - add_filter( 'the_content', 'wpmem_texturize', 99 ); + add_filter( 'the_content', 'wpmem_texturize', 99 ); } return $content; - + } // end wpmem_securify endif; @@ -230,32 +232,36 @@ function wpmem_securify( $content = null ) { * * @param string $page * @param string $redirect_to + * @global object $wpmem * @global string $wpmem_regchk * @global string $wpmem_themsg * @global string $wpmem_a - * @return string $content + * @global object $post + * @return string $content */ function wpmem_do_sc_pages( $page, $redirect_to = null ) { - global $wpmem_regchk, $wpmem_themsg, $wpmem_a; + global $wpmem, $wpmem_regchk, $wpmem_themsg, $wpmem_a, $post; include_once( WPMEM_PATH . 'wp-members-dialogs.php' ); - + + $post_type = get_post_type( $post ); + $content = ''; - + // deprecating members-area parameter to be replaced by user-profile $page = ( $page == 'user-profile' ) ? 'members-area' : $page; - if ( $page == 'members-area' || $page == 'register' ) { - + if ( $page == 'members-area' || $page == 'register' ) { + if ( $wpmem_regchk == "captcha" ) { global $wpmem_captcha_err; $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; } - + if ( $wpmem_regchk == "loginfailed" ) { return wpmem_inc_loginfailed(); } - + if ( ! is_user_logged_in() ) { if ( $wpmem_a == 'register' ) { @@ -279,11 +285,11 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) { } else { $content = ( $page == 'members-area' ) ? $content . wpmem_inc_login( 'members' ) : $content; - $content = ( $page == 'register' || WPMEM_NO_REG != 1 ) ? $content . wpmem_inc_registration() : $content; + $content = ( $page == 'register' || $wpmem->show_reg[ $post_type ] != 1 ) ? $content . wpmem_inc_registration() : $content; } } elseif ( is_user_logged_in() && $page == 'members-area' ) { - + /** * Filter the default heading in User Profile edit mode. * @@ -292,7 +298,7 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) { * @param string The default edit mode heading. */ $heading = apply_filters( 'wpmem_user_edit_heading', __( 'Edit Your Information', 'wp-members' ) ); - + switch( $wpmem_a ) { case "edit": @@ -367,8 +373,8 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) { */ function wpmem_block() { - global $post; - + global $post, $wpmem; + /** * Backward compatibility for old block/unblock meta */ @@ -379,16 +385,16 @@ function wpmem_block() { $old_unblock = get_post_meta( $post->ID, 'unblock', true ); $meta = ( $old_block ) ? 1 : ( ( $old_unblock ) ? 0 : $meta ); } - + // setup defaults - $defaults = array( + $defaults = array( 'post_id' => $post->ID, 'post_type' => $post->post_type, - 'block' => ( ( $post->post_type == 'post' && WPMEM_BLOCK_POSTS == 1 ) || ( $post->post_type == 'page' && WPMEM_BLOCK_PAGES == 1 ) ) ? true : false, - 'block_meta' => $meta, // get_post_meta( $post->ID, '_wpmem_block', true ), - 'block_type' => ( $post->post_type == 'post' ) ? WPMEM_BLOCK_POSTS : ( ( $post->post_type == 'page' ) ? WPMEM_BLOCK_PAGES : 0 ), + 'block' => ( $wpmem->block[ $post->post_type ] == 1 ) ? true : false, + 'block_meta' => $meta, // @todo get_post_meta( $post->ID, '_wpmem_block', true ), + 'block_type' => ( $post->post_type == 'post' ) ? $wpmem->block['post'] : ( ( $post->post_type == 'page' ) ? $wpmem->block['page'] : 0 ), ); - + /** * Filter the block arguments. * @@ -398,7 +404,7 @@ function wpmem_block() { * @param array $defaults Although you are not filtering the defaults, knowing what they are can assist developing more powerful functions. */ $args = apply_filters( 'wpmem_block_args', '', $defaults ); - + // merge $args with defaults $args = ( wp_parse_args( $args, $defaults ) ); @@ -412,11 +418,11 @@ function wpmem_block() { break; } } else { - + $args['block'] = false; - + } - + /** * Filter the block boolean. * @@ -448,6 +454,8 @@ function wpmem_block() { */ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { + global $wpmem; + // set all default attributes to false $defaults = array( 'page' => false, @@ -474,38 +482,38 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { } else { $content = do_shortcode( wpmem_do_sc_pages( $atts['page'], $atts['redirect_to'] ) ); } - + // resolve any texturize issues... if ( strstr( $content, '[wpmem_txt]' ) ) { // fixes the wptexturize remove_filter( 'the_content', 'wpautop' ); remove_filter( 'the_content', 'wptexturize' ); - add_filter( 'the_content', 'wpmem_texturize', 99 ); + add_filter( 'the_content', 'wpmem_texturize', 99 ); } return $content; } - + // handles the 'status' attribute if ( ( $atts['status'] ) || $tag == 'wpmem_logged_in' ) { - + $do_return = false; - + // if using the wpmem_logged_in tag with no attributes & the user is logged in if ( $tag == 'wpmem_logged_in' && ( ! $attr ) && is_user_logged_in() ) $do_return = true; - + // if there is a status attribute of "in" and the user is logged in if ( $atts['status'] == 'in' && is_user_logged_in() ) $do_return = true; - + // if there is a status attribute of "out" and the user is not logged in if ( $atts['status'] == 'out' && ! is_user_logged_in() ) $do_return = true; - + // if there is a status attribute of "sub" and the user is logged in if ( $atts['status'] == 'sub' && is_user_logged_in() ) { - if ( WPMEM_USE_EXP == 1 ) { - if ( ! wpmem_chk_exp() ) { + if ( $wpmem->use_exp == 1 ) { + if ( ! wpmem_chk_exp() ) { $do_return = true; } elseif ( $atts['msg'] == true ) { $do_return = true; @@ -513,11 +521,11 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { } } } - + // return content (or empty content) depending on the result of the above logic return ( $do_return ) ? do_shortcode( $content ) : ''; } - + // handles the wpmem_logged_out tag with no attributes & the user is not logged in if ( $tag == 'wpmem_logged_out' && ( ! $attr ) && ! is_user_logged_in() ) { return do_shortcode( $content ); @@ -537,21 +545,21 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { $the_user_ID = get_current_user_id(); } $user_info = get_userdata( $the_user_ID ); - + if ( $atts['underscores'] == 'off' && $user_info ) { $user_info->$atts['field'] = str_replace( '_', ' ', $user_info->$atts['field'] ); } return ( $user_info ) ? htmlspecialchars( $user_info->$atts['field'] ) . do_shortcode( $content ) : do_shortcode( $content ); } - + // logout link shortcode if ( is_user_logged_in() && $tag == 'wpmem_logout' ) { $link = ( $atts['url'] ) ? wpmem_chk_qstr( $atts['url'] ) . 'a=logout' : wpmem_chk_qstr( get_permalink() ) . 'a=logout'; $text = ( $content ) ? $content : __( 'Click here to log out.', 'wp-members' ); return do_shortcode( "$text" ); } - + } endif; @@ -572,7 +580,7 @@ function wpmem_check_activated( $user, $username, $password ) { // password must be validated $pass = ( ( ! is_wp_error( $user ) ) && $password ) ? wp_check_password( $password, $user->user_pass, $user->ID ) : false; - + if ( ! $pass ) { return $user; } @@ -607,32 +615,32 @@ function wpmem_check_activated( $user, $username, $password ) { function wpmem_login() { if ( $_POST['log'] && $_POST['pwd'] ) { - + /** get username and sanitize */ $user_login = sanitize_user( $_POST['log'] ); - + /** are we setting a forever cookie? */ $rememberme = ( isset( $_POST['rememberme'] ) == 'forever' ) ? true : false; - + /** assemble login credentials */ $creds = array(); $creds['user_login'] = $user_login; $creds['user_password'] = $_POST['pwd']; $creds['remember'] = $rememberme; - + /** wp_signon the user and get the $user object */ $user = wp_signon( $creds, false ); /** if no error, user is a valid signon. continue */ if ( ! is_wp_error( $user ) ) { - + /** set the auth cookie */ wp_set_auth_cookie( $user->ID, $rememberme ); - + /** determine where to put the user after login */ $redirect_to = ( isset( $_POST['redirect_to'] ) ) ? $_POST['redirect_to'] : $_SERVER['REQUEST_URI']; - - /** + + /** * Filter the redirect url. * * @since 2.7.7 @@ -641,23 +649,22 @@ function wpmem_login() { * @param int $user->ID The user's primary key ID. */ $redirect_to = apply_filters( 'wpmem_login_redirect', $redirect_to, $user->ID ); - + /** and do the redirect */ wp_redirect( $redirect_to ); - + /** wp_redirect requires us to exit() */ exit(); - + } else { - + return "loginfailed"; } - + } else { //login failed return "loginfailed"; - } - + } } // end of login function endif; @@ -685,10 +692,10 @@ function wpmem_logout() { $redirect_to = apply_filters( 'wpmem_logout_redirect', get_bloginfo( 'url' ) ); wp_clear_auth_cookie(); - + /** This action is defined in /wp-includes/pluggable.php **/ do_action( 'wp_logout' ); - + nocache_headers(); wp_redirect( $redirect_to ); @@ -767,9 +774,9 @@ function wpmem_change_password() { $pass1 = $_POST['pass1']; $pass2 = $_POST['pass2']; - + if ( ! $pass1 && ! $pass2 ) { // check for both fields being empty - + return "pwdchangempty"; } elseif ( $pass1 != $pass2 ) { // make sure the fields match @@ -779,7 +786,7 @@ function wpmem_change_password() { } else { // update password in db (wp_update_user hashes the password) wp_update_user( array ( 'ID' => $user_ID, 'user_pass' => $pass1 ) ); - + /** * Fires after password change. * @@ -788,7 +795,7 @@ function wpmem_change_password() { * @param int $user_ID The user's numeric ID. */ do_action( 'wpmem_pwd_change', $user_ID ); - + return "pwdchangesuccess"; } @@ -834,23 +841,23 @@ function wpmem_reset_password() { if ( username_exists( $arr['user'] ) ) { $user = get_user_by( 'login', $arr['user'] ); - + if ( strtolower( $user->user_email ) !== strtolower( $arr['email'] ) || ( ( WPMEM_MOD_REG == 1 ) && ( get_user_meta( $user->ID,'active', true ) != 1 ) ) ) { // the username was there, but the email did not match OR the user hasn't been activated return "pwdreseterr"; - + } else { - + // generate a new password $new_pass = wp_generate_password(); - + // update the users password wp_update_user( array ( 'ID' => $user->ID, 'user_pass' => $new_pass ) ); // send it in an email require_once( 'wp-members-email.php' ); wpmem_inc_regemail( $user->ID, $new_pass, 3 ); - + /** * Fires after password reset. * @@ -859,7 +866,7 @@ function wpmem_reset_password() { * @param int $user_ID The user's numeric ID. */ do_action( 'wpmem_pwd_reset', $user->ID ); - + return "pwdresetsuccess"; } } else { @@ -893,11 +900,11 @@ function wpmem_no_reset() { } if ( WPMEM_MOD_REG == 1 ) { - if ( get_user_meta( $user->ID, 'active', true ) != 1 ) { + if ( get_user_meta( $user->ID, 'active', true ) != 1 ) { return false; } } - + return true; } endif; @@ -945,7 +952,7 @@ function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) { if ( ( $field[3] == 'checkbox' ) && ( ! isset( $_POST[$field[2]] ) ) ) { $is_error = true; } - if ( ( $field[3] != 'checkbox' ) && ( ! $_POST[$field[2]] ) ) { + if ( ( $field[3] != 'checkbox' ) && ( ! $_POST[$field[2]] ) ) { $is_error = true; } if ( $is_error ) { $errors->add( 'wpmem_error', sprintf( __('Sorry, %s is a required field.', 'wp-members'), $field[1] ) ); } @@ -988,7 +995,7 @@ function wpmem_wp_reg_finalize( $user_id ) { * @since 2.8.7 */ function wpmem_wplogin_stylesheet() { - echo ''; + echo ''; } @@ -996,7 +1003,7 @@ function wpmem_wplogin_stylesheet() { * Securifies the comments. * * If the user is not logged in and the content is blocked - * (i.e. wpmem_block() returns true), function loads a + * (i.e. wpmem_block() returns true), function loads a * dummy/empty comments template. * * @since 2.9.9 From cd8d674d865b76f6f2fdc53e4ecdfb747b4436c2 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 14 Apr 2015 11:18:26 -0500 Subject: [PATCH 0046/1694] new settings, code standards, merged post column and page column functions --- admin/post.php | 83 +++++++++++++------------------------------------- 1 file changed, 21 insertions(+), 62 deletions(-) diff --git a/admin/post.php b/admin/post.php index 4c6d5b7d..e672f675 100644 --- a/admin/post.php +++ b/admin/post.php @@ -23,17 +23,15 @@ * * wpmem_block_meta_save * * wpmem_post_columns * * wpmem_post_columns_content - * * wpmem_page_columns - * * wpmem_page_columns_content */ /** * Actions */ -add_action( 'admin_footer-edit.php', 'wpmem_bulk_posts_action' ); -add_action( 'load-edit.php', 'wpmem_posts_page_load' ); -add_action( 'admin_notices', 'wpmem_posts_admin_notices'); +add_action( 'admin_footer-edit.php', 'wpmem_bulk_posts_action' ); +add_action( 'load-edit.php', 'wpmem_posts_page_load' ); +add_action( 'admin_notices', 'wpmem_posts_admin_notices' ); /** @@ -44,10 +42,10 @@ function wpmem_bulk_posts_action() { ?> post_type; // update accordingly - if ( ( $type == 'post' && $wpmem->block['post'] == 0 ) || ( $type == 'page' && $wpmem->block['page'] == 0 ) ) { + if ( $wpmem->block[ $type ] == 0 ) { if ( $action == 'block' ) { update_post_meta( $post_id, '_wpmem_block', 1 ); } else { @@ -92,7 +90,7 @@ function wpmem_posts_page_load() { } } - if ( ( $type == 'post' && $wpmem->block['post'] == 1 ) || ( $type == 'page' && $wpmem->block['page'] == 1 ) ) { + if ( $wpmem->block[ $type ] == 1 ) { if ( $action == 'unblock' ) { update_post_meta( $post_id, '_wpmem_block', 0 ); } else { @@ -104,11 +102,11 @@ function wpmem_posts_page_load() { $arr = array( 'a' => $action, 'n' => $x, + 'post_type' => $type, ); - if ( $type == 'page' ) { - $arr['post_type'] = 'page'; - } + $sendback = add_query_arg( array( $arr ), '', $sendback ); + } else { /** set the return message */ $sendback = add_query_arg( array( 'a' => 'none' ), '', $sendback ); @@ -289,8 +287,10 @@ function wpmem_block_meta_save( $post_id ) { * @param arr $columns The array of table columns. */ function wpmem_post_columns( $columns ) { + global $wpmem; + $post_type = ( isset( $_REQUEST['post_type'] ) ) ? $_REQUEST['post_type'] : 'post'; wp_enqueue_style ( 'wpmem-admin-css', WPMEM_DIR . '/css/admin.css', '', WPMEM_VERSION ); - $columns['wpmem_block'] = ( WPMEM_BLOCK_POSTS == 1 ) ? __( 'Unblocked?', 'wp-members' ) : __( 'Blocked?', 'wp-members' ); + $columns['wpmem_block'] = ( $wpmem->block[ $post_type ] == 1 ) ? __( 'Unblocked?', 'wp-members' ) : __( 'Blocked?', 'wp-members' ); return $columns; } @@ -304,67 +304,26 @@ function wpmem_post_columns( $columns ) { * @param $post_ID */ function wpmem_post_columns_content( $column_name, $post_ID ) { - if ( $column_name == 'wpmem_block' ) { - - $block_meta = get_post_meta( $post_ID, '_wpmem_block', true ); - - /** - * Backward compatibility for old block/unblock meta - */ - if ( ! $block_meta ) { - // check for old meta - $old_block = get_post_meta( $post_ID, 'block', true ); - $old_unblock = get_post_meta( $post_ID, 'unblock', true ); - $block_meta = ( $old_block ) ? 1 : ( ( $old_unblock ) ? 0 : $block_meta ); - } - - echo ( WPMEM_BLOCK_POSTS == 1 && $block_meta == '0' ) ? __( 'Yes' ) : ''; - echo ( WPMEM_BLOCK_POSTS == 0 && $block_meta == '1' ) ? __( 'Yes' ) : ''; - } -} - - -/** - * Adds WP-Members blocking status to Page Table columns. - * - * @since 2.8.3 - * - * @uses wp_enqueue_style Loads the WP-Members admin stylesheet. - * - * @param arr $columns The array of table columns. - */ -function wpmem_page_columns( $columns ) { - wp_enqueue_style ( 'wpmem-admin-css', WPMEM_DIR . '/css/admin.css', '', WPMEM_VERSION ); - $columns['wpmem_block'] = ( WPMEM_BLOCK_PAGES == 1 ) ? __( 'Unblocked?', 'wp-members' ) : __( 'Blocked?', 'wp-members' ); - return $columns; -} + global $wpmem; + $post_type = ( isset( $_REQUEST['post_type'] ) ) ? $_REQUEST['post_type'] : 'post'; -/** - * Adds blocking status to the Page Table column. - * - * @since 2.8.3 - * - * @param $column_name - * @param $post_ID - */ -function wpmem_page_columns_content( $column_name, $post_ID ) { - if ( $column_name == 'wpmem_block' ) { + if ( $column_name == 'wpmem_block' ) { $block_meta = get_post_meta( $post_ID, '_wpmem_block', true ); /** * Backward compatibility for old block/unblock meta */ - if( ! $block_meta ) { + if ( ! $block_meta ) { // check for old meta $old_block = get_post_meta( $post_ID, 'block', true ); $old_unblock = get_post_meta( $post_ID, 'unblock', true ); $block_meta = ( $old_block ) ? 1 : ( ( $old_unblock ) ? 0 : $block_meta ); } - echo ( WPMEM_BLOCK_PAGES == 1 && $block_meta == '0' ) ? __( 'Yes' ) : ''; - echo ( WPMEM_BLOCK_PAGES == 0 && $block_meta == '1' ) ? __( 'Yes' ) : ''; + echo ( $wpmem->block[ $post_type ] == 1 && $block_meta == '0' ) ? __( 'Yes' ) : ''; + echo ( $wpmem->block[ $post_type ] == 0 && $block_meta == '1' ) ? __( 'Yes' ) : ''; } } From 267d463c836fa8361225f243301a28e0b932bb33 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 14 Apr 2015 11:18:59 -0500 Subject: [PATCH 0047/1694] replaced constants with new settings object --- admin/admin.php | 6 ++-- admin/tab-fields.php | 5 ++-- admin/user-export.php | 13 +++++---- admin/users.php | 9 +++--- forms.php | 16 ++++++----- utilities.php | 2 +- wp-members-core.php | 8 ++++-- wp-members-dialogs.php | 30 ++++++++++---------- wp-members-email.php | 20 +++++++------ wp-members-register.php | 12 ++++---- wp-members-sidebar.php | 10 +++---- wp-members.php | 63 +++++++++++++++++++++-------------------- 12 files changed, 105 insertions(+), 89 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index 4848c412..9155985e 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -35,10 +35,10 @@ /** Actions and Filters */ -add_action( 'wpmem_admin_do_tab', 'wpmem_admin_do_tab' ); +add_action( 'wpmem_admin_do_tab', 'wpmem_admin_do_tab' ); add_action( 'wp_ajax_wpmem_a_field_reorder', 'wpmem_a_do_field_reorder' ); -add_action( 'user_new_form', 'wpmem_admin_add_new_user' ); -add_filter( 'plugin_action_links', 'wpmem_admin_plugin_links', 10, 2 ); +add_action( 'user_new_form', 'wpmem_admin_add_new_user' ); +add_filter( 'plugin_action_links', 'wpmem_admin_plugin_links', 10, 2 ); /** diff --git a/admin/tab-fields.php b/admin/tab-fields.php index d7e1612e..4ffe4526 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -412,6 +412,7 @@ function wpmem_a_field_edit( $mode, $wpmem_fields = null, $field = null ) */ function wpmem_a_field_table( $wpmem_fields ) { + global $wpmem; ?>

    @@ -484,7 +485,7 @@ function wpmem_a_field_table( $wpmem_fields ) /> - + mod_reg == 1 ) { ?>   @@ -508,7 +509,7 @@ function wpmem_a_field_table( $wpmem_fields ) /> - + use_exp == 1 ) { ?>   Subscription Type diff --git a/admin/user-export.php b/admin/user-export.php index 26046ce4..159375c0 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -25,6 +25,9 @@ * @param array $users */ function wpmem_export_users( $args, $users = null ) { + + global $wpmem; + $today = date( "m-d-y" ); /** Setup defaults **/ @@ -70,8 +73,8 @@ function wpmem_export_users( $args, $users = null ) { } } - $hrow .= ( WPMEM_MOD_REG == 1 ) ? __( 'Activated?', 'wp-members' ) . "," : ''; - $hrow .= ( WPMEM_USE_EXP == 1 ) ? __( 'Subscription', 'wp-members' ) . "," . __( 'Expires', 'wp-members' ) . "," : ''; + $hrow .= ( $wpmem->mod_reg == 1 ) ? __( 'Activated?', 'wp-members' ) . "," : ''; + $hrow .= ( $wpmem->use_exp == 1 ) ? __( 'Subscription', 'wp-members' ) . "," . __( 'Expires', 'wp-members' ) . "," : ''; $hrow .= __( 'Registered', 'wp-members' ) . ","; $hrow .= __( 'IP', 'wp-members' ); @@ -105,9 +108,9 @@ function wpmem_export_users( $args, $users = null ) { } } - $data .= ( WPMEM_MOD_REG == 1 ) ? '"' . ( get_user_meta( $user, 'active', 1 ) ) ? __( 'Yes' ) : __( 'No' ) . '",' : ''; - $data .= ( WPMEM_USE_EXP == 1 ) ? '"' . get_user_meta( $user, "exp_type", true ) . '",' : ''; - $data .= ( WPMEM_USE_EXP == 1 ) ? '"' . get_user_meta( $user, "expires", true ) . '",' : ''; + $data .= ( $wpmem->mod_reg == 1 ) ? '"' . ( get_user_meta( $user, 'active', 1 ) ) ? __( 'Yes' ) : __( 'No' ) . '",' : ''; + $data .= ( $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "exp_type", true ) . '",' : ''; + $data .= ( $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "expires", true ) . '",' : ''; $data .= '"' . $user_info->user_registered . '",'; $data .= '"' . get_user_meta( $user, "wpmem_reg_ip", true ). '"'; diff --git a/admin/users.php b/admin/users.php index 2545505d..612a11bd 100644 --- a/admin/users.php +++ b/admin/users.php @@ -55,14 +55,15 @@ * * @since 2.8.2 */ -function wpmem_bulk_user_action() { ?> +function wpmem_bulk_user_action() { + global $wpmem; ?> - - '; - - /** - * Filter the reCAPTCHA HTML. - * - * @since 2.7.4 - * - * @param string $str A string of HTML for the reCAPTCHA. - */ - $str = apply_filters( 'wpmem_recaptcha', $str ); - - return $str; -} -endif; - - -/** - * Create an attribution link in the form. - * - * @since 2.6.0 - * - * @return string $str - */ -function wpmem_inc_attribution() { - - $http = ( is_ssl() ) ? 'https://' : 'http://'; - $str = ' -
    - Powered by WP-Members -
    '; - - return ( get_option( 'wpmembers_attrib' ) ) ? $str : ''; -} - - -/** - * Create Really Simple CAPTCHA. - * - * @since 2.9.5 - * - * @return array Form elements for Really Simple CAPTCHA. - */ -function wpmem_build_rs_captcha() { - - if ( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { - // setup defaults - $defaults = array( - 'characters' => 'ABCDEFGHJKLMNPQRSTUVWXYZ23456789', - 'num_char' => '4', - 'dim_w' => '72', - 'dim_h' => '30', - 'font_color' => '0,0,0', - 'bg_color' => '255,255,255', - 'font_size' => '12', - 'kerning' => '14', - 'img_type' => 'png', - ); - $wpmem_captcha = get_option( 'wpmembers_captcha' ); - - extract( wp_parse_args( $wpmem_captcha['really_simple'], $defaults ) ); - - $img_size = array( $dim_w, $dim_h ); - $fg = explode( ",", $font_color ); - $bg = explode( ",", $bg_color ); - - $wpmem_captcha = new ReallySimpleCaptcha(); - $wpmem_captcha->chars = $characters; - $wpmem_captcha->char_length = $num_char; - $wpmem_captcha->img_size = $img_size; - $wpmem_captcha->fg = $fg; - $wpmem_captcha->bg = $bg; - $wpmem_captcha->font_size = $font_size; - $wpmem_captcha->font_char_width = $kerning; - $wpmem_captcha->img_type = $img_type; - - $wpmem_captcha_word = $wpmem_captcha->generate_random_word(); - $wpmem_captcha_prefix = mt_rand(); - $wpmem_captcha_image_name = $wpmem_captcha->generate_image( $wpmem_captcha_prefix, $wpmem_captcha_word ); - - /** - * Filters the default Really Simple Captcha folder location. - * - * @since 3.0 - * - * @param string The default location of RS Captcha. - */ - $wpmem_captcha_image_url = apply_filters( 'wpmem_rs_captcha_folder', get_bloginfo('wpurl') . '/wp-content/plugins/really-simple-captcha/tmp/' ); - - $img_w = $wpmem_captcha->img_size[0]; - $img_h = $wpmem_captcha->img_size[1]; - $src = $wpmem_captcha_image_url . $wpmem_captcha_image_name; - $size = $wpmem_captcha->char_length; - $pre = $wpmem_captcha_prefix; - - return array( - 'label' => '', - 'field' => ' - - captcha' - ); - } else { - return; - } -} - +' . __( stripslashes( $arr[0] ), 'wp-members' ) . '

    '; + + /** + * Filter the post restricted message. + * + * @since 2.7.3 + * + * @param string $str The post restricted message. + */ + $str = apply_filters( 'wpmem_restricted_msg', $str ); + + } + } + + // create the default inputs + $default_inputs = array( + array( + 'name' => __( 'Username' ), + 'type' => 'text', + 'tag' => 'log', + 'class' => 'username', + 'div' => 'div_text', + ), + array( + 'name' => __( 'Password' ), + 'type' => 'password', + 'tag' => 'pwd', + 'class' => 'password', + 'div' => 'div_text', + ), + ); + + /** + * Filter the array of login form fields. + * + * @since 2.9.0 + * + * @param array $default_inputs An array matching the elements used by default. + */ + $default_inputs = apply_filters( 'wpmem_inc_login_inputs', $default_inputs ); + + $defaults = array( + 'heading' => __( 'Existing Users Log In', 'wp-members' ), + 'action' => 'login', + 'button_text' => __( 'Log In' ), + 'inputs' => $default_inputs, + 'redirect_to' => $redirect_to, + ); + + /** + * Filter the arguments to override login form defaults. + * + * @since 2.9.0 + * + * @param array $args An array of arguments to use. Default null. + */ + $args = apply_filters( 'wpmem_inc_login_args', '' ); + + $arr = wp_parse_args( $args, $defaults ); + + $str = $str . wpmem_login_form( $page, $arr ); + + return $str; +} +endif; + + +if ( ! function_exists( 'wpmem_inc_changepassword' ) ): +/** + * Change Password Dialog. + * + * Loads the form for changing password. + * + * @since 2.0 + * + * @uses wpmem_login_form() + * + * @return string $str the generated html for the change password form. + */ +function wpmem_inc_changepassword() { + + // create the default inputs + $default_inputs = array( + array( + 'name' => __( 'New password' ), + 'type' => 'password', + 'tag' => 'pass1', + 'class' => 'password', + 'div' => 'div_text', + ), + array( + 'name' => __( 'Confirm new password' ), + 'type' => 'password', + 'tag' => 'pass2', + 'class' => 'password', + 'div' => 'div_text', + ), + ); + + /** + * Filter the array of change password form fields. + * + * @since 2.9.0 + * + * @param array $default_inputs An array matching the elements used by default. + */ + $default_inputs = apply_filters( 'wpmem_inc_changepassword_inputs', $default_inputs ); + + $defaults = array( + 'heading' => __('Change Password', 'wp-members'), + 'action' => 'pwdchange', + 'button_text' => __('Update Password', 'wp-members'), + 'inputs' => $default_inputs, + ); + + /** + * Filter the arguments to override change password form defaults. + * + * @since 2.9.0 + * + * @param array $args An array of arguments to use. Default null. + */ + $args = apply_filters( 'wpmem_inc_changepassword_args', '' ); + + $arr = wp_parse_args( $args, $defaults ); + + $str = wpmem_login_form( 'page', $arr ); + + return $str; +} +endif; + + +if ( ! function_exists( 'wpmem_inc_resetpassword' ) ): +/** + * Reset Password Dialog. + * + * Loads the form for resetting password. + * + * @since 2.1 + * + * @uses wpmem_login_form() + * + * @return string $str the generated html fo the reset password form. + */ +function wpmem_inc_resetpassword() +{ + /** create the default inputs **/ + $default_inputs = array( + array( + 'name' => __( 'Username' ), + 'type' => 'text', + 'tag' => 'user', + 'class' => 'username', + 'div' => 'div_text', + ), + array( + 'name' => __( 'Email' ), + 'type' => 'text', + 'tag' => 'email', + 'class' => 'password', + 'div' => 'div_text', + ), + ); + + /** + * Filter the array of reset password form fields. + * + * @since 2.9.0 + * + * @param array $default_inputs An array matching the elements used by default. + */ + $default_inputs = apply_filters( 'wpmem_inc_resetpassword_inputs', $default_inputs ); + + $defaults = array( + 'heading' => __( 'Reset Forgotten Password', 'wp-members' ), + 'action' => 'pwdreset', + 'button_text' => __( 'Reset Password' ), + 'inputs' => $default_inputs, + ); + + /** + * Filter the arguments to override reset password form defaults. + * + * @since 2.9.0 + * + * @param array $args An array of arguments to use. Default null. + */ + $args = apply_filters( 'wpmem_inc_resetpassword_args', '' ); + + $arr = wp_parse_args( $args, $defaults ); + + $str = wpmem_login_form( 'page', $arr ); + + return $str; +} +endif; + + +if ( ! function_exists( 'wpmem_login_form' ) ): +/** + * Login Form Dialog. + * + * Builds the form used for login, change password, and reset password. + * + * @since 2.5.1 + * + * @param string $page + * @param array $arr The elements needed to generate the form (login|reset password|forgotten password). + * @return string $form The HTML for the form as a string. + */ +function wpmem_login_form( $page, $arr ) { + + global $wpmem; + + // extract the arguments array + extract( $arr ); + + // set up default wrappers + $defaults = array( + + // wrappers + 'heading_before' => '', + 'heading_after' => '', + 'fieldset_before' => '
    ', + 'fieldset_after' => '
    ', + 'main_div_before' => '
    ', + 'main_div_after' => '
    ', + 'txt_before' => '[wpmem_txt]', + 'txt_after' => '[/wpmem_txt]', + 'row_before' => '', + 'row_after' => '', + 'buttons_before' => '
    ', + 'buttons_after' => '
    ', + 'link_before' => '', + + // classes & ids + 'form_id' => '', + 'form_class' => 'form', + 'button_id' => '', + 'button_class' => 'buttons', + + // other + 'strip_breaks' => true, + 'wrap_inputs' => true, + 'remember_check' => true, + 'n' => "\n", + 't' => "\t", + 'redirect_to' => ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : ( ( isset( $redirect_to ) ) ? $redirect_to : get_permalink() ), + + ); + + /** + * Filter the default form arguments. + * + * This filter accepts an array of various elements to replace the form defaults. This + * includes default tags, labels, text, and small items including various booleans. + * + * @since 2.9.0 + * + * @param array An array of arguments to merge with defaults. Default null. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + */ + $args = apply_filters( 'wpmem_login_form_args', '', $action ); + + // merge $args with defaults + extract( wp_parse_args( $args, $defaults ) ); + + // build the input rows + foreach ( $inputs as $input ) { + $label = ''; + $field = wpmem_create_formfield( $input['tag'], $input['type'], '', '', $input['class'] ); + $field_before = ( $wrap_inputs ) ? '
    ' : ''; + $field_after = ( $wrap_inputs ) ? '
    ' : ''; + $rows[] = array( + 'row_before' => $row_before, + 'label' => $label, + 'field_before' => $field_before, + 'field' => $field, + 'field_after' => $field_after, + 'row_after' => $row_after, + ); + } + + /** + * Filter the array of form rows. + * + * This filter receives an array of the main rows in the form, each array element being + * an array of that particular row's pieces. This allows making changes to individual + * parts of a row without needing to parse through a string of HTML. + * + * @since 2.9.0 + * + * @param array $rows An array containing the form rows. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + */ + $rows = apply_filters( 'wpmem_login_form_rows', $rows, $action ); + + // put the rows from the array into $form + $form = ''; + foreach ( $rows as $row_item ) { + $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $n . $row_item['label'] . $n : $row_item['label'] . $n; + $row .= ( $row_item['field_before'] != '' ) ? $row_item['field_before'] . $n . $t . $row_item['field'] . $n . $row_item['field_after'] . $n : $row_item['field'] . $n; + $row .= ( $row_item['row_before'] != '' ) ? $row_item['row_after'] . $n : ''; + $form.= $row; + } + + // build hidden fields, filter, and add to the form + $hidden = wpmem_create_formfield( 'redirect_to', 'hidden', $redirect_to ) . $n; + $hidden = $hidden . wpmem_create_formfield( 'a', 'hidden', $action ) . $n; + $hidden = ( $action != 'login' ) ? $hidden . wpmem_create_formfield( 'formsubmit', 'hidden', '1' ) : $hidden; + + /** + * Filter the hidden field HTML. + * + * @since 2.9.0 + * + * @param string $hidden The generated HTML of hidden fields. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + */ + $form = $form . apply_filters( 'wpmem_login_hidden_fields', $hidden, $action ); + + // build the buttons, filter, and add to the form + if ( $action == 'login' ) { + $remember_check = ( $remember_check ) ? $t . wpmem_create_formfield( 'rememberme', 'checkbox', 'forever' ) . ' ' . __( 'Remember Me' ) . '  ' . $n : ''; + $buttons = $remember_check . $t . '' . $n; + } else { + $buttons = '' . $n; + } + + /** + * Filter the HTML for form buttons. + * + * The string includes the buttons, as well as the before/after wrapper elements. + * + * @since 2.9.0 + * + * @param string $buttons The generated HTML of the form buttons. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + */ + $form = $form . apply_filters( 'wpmem_login_form_buttons', $buttons_before . $n . $buttons . $buttons_after . $n, $action ); + + if ( ( $wpmem->user_pages['profile'] != null || $page == 'members' ) && $action == 'login' ) { + + /** + * Filter the forgot password link. + * + * @since 2.8.0 + * + * @param string The forgot password link. + */ + $link = apply_filters( 'wpmem_forgot_link', wpmem_chk_qstr( $wpmem->user_pages['profile'] ) . 'a=pwdreset' ); + $str = __( 'Forgot password?', 'wp-members' ) . ' ' . __( 'Click here to reset', 'wp-members' ) . ''; + $form = $form . $link_before . apply_filters( 'wpmem_forgot_link_str', $str ) . $link_after . $n; + + } + + if ( ( $wpmem->user_pages['register'] != null ) && $action == 'login' ) { + + /** + * Filter the link to the registration page. + * + * @since 2.8.0 + * + * @param string The registration page link. + */ + $link = apply_filters( 'wpmem_reg_link', $wpmem->user_pages['register'] ); + $str = __( 'New User?', 'wp-members' ) . ' ' . __( 'Click here to register', 'wp-members' ) . ''; + $form = $form . $link_before . apply_filters( 'wpmem_reg_link_str', $str ) . $link_after . $n; + + } + + // apply the heading + $form = $heading_before . $heading . $heading_after . $n . $form; + + // apply fieldset wrapper + $form = $fieldset_before . $n . $form . $fieldset_after . $n; + + // apply form wrapper + $form = '
    ' . $n . $form . '
    '; + + // apply anchor + $form = '' . $n . $form; + + // apply main wrapper + $form = $main_div_before . $n . $form . $n . $main_div_after; + + // apply wpmem_txt wrapper + $form = $txt_before . $form . $txt_after; + + // remove line breaks + $form = ( $strip_breaks ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; + + /** + * Filter the generated HTML of the entire form. + * + * @since 2.7.4 + * + * @param string $form The HTML of the final generated form. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + */ + $form = apply_filters( 'wpmem_login_form', $form, $action ); + + /** + * Filter before the form. + * + * This rarely used filter allows you to stick any string onto the front of + * the generated form. + * + * @since 2.7.4 + * + * @param string $str The HTML to add before the form. Default null. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + */ + $form = apply_filters( 'wpmem_login_form_before', '', $action ) . $form; + + return $form; +} // end wpmem_login_form +endif; + + +if ( ! function_exists( 'wpmem_inc_registration' ) ): +/** + * Registration Form Dialog. + * + * Outputs the form for new user registration and existing user edits. + * + * @since 2.5.1 + * + * @param string $toggle (optional) Toggles between new registration ('new') and user profile edit ('edit'). + * @param string $heading (optional) The heading text for the form, null (default) for new registration. + * @global string $wpmem_regchk Used to determine if the form is in an error state. + * @global array $userdata Used to get the user's registration data if they are logged in (user profile edit). + * @return string $form The HTML for the entire form as a string. + */ +function wpmem_inc_registration( $toggle = 'new', $heading = '' ) { + + global $wpmem, $wpmem_regchk, $userdata; + + // set up default wrappers + $defaults = array( + + // wrappers + 'heading_before' => '', + 'heading_after' => '', + 'fieldset_before' => '
    ', + 'fieldset_after' => '
    ', + 'main_div_before' => '
    ', + 'main_div_after' => '
    ', + 'txt_before' => '[wpmem_txt]', + 'txt_after' => '[/wpmem_txt]', + 'row_before' => '', + 'row_after' => '', + 'buttons_before' => '
    ', + 'buttons_after' => '
    ', + + // classes & ids + 'form_id' => '', + 'form_class' => 'form', + 'button_id' => '', + 'button_class' => 'buttons', + + // required field tags and text + 'req_mark' => '*', + 'req_label' => __( 'Required field', 'wp-members' ), + 'req_label_before' => '
    ', + 'req_label_after' => '
    ', + + // buttons + 'show_clear_form' => false, + 'clear_form' => __( 'Reset Form', 'wp-members' ), + 'submit_register' => __( 'Register' ), + 'submit_update' => __( 'Update Profile', 'wp-members' ), + + // other + 'strip_breaks' => true, + 'use_nonce' => false, + 'wrap_inputs' => true, + 'n' => "\n", + 't' => "\t", + + ); + + /** + * Filter the default form arguments. + * + * This filter accepts an array of various elements to replace the form defaults. This + * includes default tags, labels, text, and small items including various booleans. + * + * @since 2.9.0 + * + * @param array An array of arguments to merge with defaults. Default null. + * @param string $toggle Toggle new registration or profile update. new|edit. + */ + $args = apply_filters( 'wpmem_register_form_args', '', $toggle ); + + // merge $args with defaults + extract( wp_parse_args( $args, $defaults ) ); + + // Username is editable if new reg, otherwise user profile is not + if ( $toggle == 'edit' ) { + // this is the User Profile edit - username is not editable + $val = $userdata->user_login; + $label = ''; + $input = '

    ' . $val . '

    '; + $field_before = ( $wrap_inputs ) ? '
    ' : ''; + $field_after = ( $wrap_inputs ) ? '
    ' : ''; + } else { + // this is a new registration + $val = ( isset( $_POST['log'] ) ) ? stripslashes( $_POST['log'] ) : ''; + $label = ''; + $input = wpmem_create_formfield( 'log', 'text', $val, '', 'username' ); + + } + $field_before = ( $wrap_inputs ) ? '
    ' : ''; + $field_after = ( $wrap_inputs ) ? '
    ': ''; + + // add the username row to the array + $rows['username'] = array( + 'order' => 0, + 'meta' => 'username', + 'type' => 'text', + 'value' => $val, + 'row_before' => $row_before, + 'label' => $label, + 'field_before' => $field_before, + 'field' => $input, + 'field_after' => $field_after, + 'row_after' => $row_after, + ); + + /** + * Filter the array of form fields. + * + * The form fields are stored in the WP options table as wpmembers_fields. This + * filter can filter that array after the option is retreived before the fields + * are parsed. This allows you to change the fields that may be used in the form + * on the fly. + * + * @since 2.9.0 + * + * @param array The array of form fields. + * @param string $toggle Toggle new registration or profile update. new|edit. + */ + $wpmem_fields = apply_filters( 'wpmem_register_fields_arr', get_option( 'wpmembers_fields' ), $toggle ); + + // loop through the remaining fields + foreach ( $wpmem_fields as $field ) { + + // start with a clean row + $val = ''; $label = ''; $input = ''; $field_before = ''; $field_after = ''; + + // skips user selected passwords for profile update + $pass_arr = array( 'password', 'confirm_password', 'password_confirm' ); + $do_row = ( $toggle == 'edit' && in_array( $field[2], $pass_arr ) ) ? false : true; + + // skips tos, makes tos field hidden on user edit page, unless they haven't got a value for tos + if ( $field[2] == 'tos' && $toggle == 'edit' && ( get_user_meta( $userdata->ID, 'tos', true ) ) ) { + $do_row = false; + $hidden_tos = wpmem_create_formfield( $field[2], 'hidden', get_user_meta( $userdata->ID, 'tos', true ) ); + } + + // if the field is set to display and we aren't skipping, construct the row + if ( $field[4] == 'y' && $do_row == true ) { + + // label for all but TOS + if ( $field[2] != 'tos' ) { + + $class = ( $field[3] == 'password' ) ? 'text' : $field[3]; + + $label = ''; + + } + + // gets the field value for both edit profile and submitted reg w/ error + if ( ( $toggle == 'edit' ) && ( $wpmem_regchk != 'updaterr' ) ) { + + switch ( $field[2] ) { + case( 'description' ): + $val = htmlspecialchars( get_user_meta( $userdata->ID, 'description', 'true' ) ); + break; + + case( 'user_email' ): + case( 'confirm_email' ): + $val = $userdata->user_email; + break; + + case( 'user_url' ): + $val = esc_url( $userdata->user_url ); + break; + + default: + $val = htmlspecialchars( get_user_meta( $userdata->ID, $field[2], 'true' ) ); + break; + } + + } else { + + $val = ( isset( $_POST[ $field[2] ] ) ) ? $_POST[ $field[2] ] : ''; + + } + + // does the tos field + if ( $field[2] == 'tos' ) { + + $val = ( isset( $_POST[ $field[2] ] ) ) ? $_POST[ $field[2] ] : ''; + + // should be checked by default? and only if form hasn't been submitted + $val = ( ! $_POST && $field[8] == 'y' ) ? $field[7] : $val; + $input = wpmem_create_formfield( $field[2], $field[3], $field[7], $val ); + $input = ( $field[5] == 'y' ) ? $input . $req_mark : $input; + + // determine if TOS is a WP page or not... + $tos_content = stripslashes( get_option( 'wpmembers_tos' ) ); + if ( ( wpmem_test_shortcode( $tos_content, 'wp-members' ) ) ) { + $link = do_shortcode( $tos_content ); + $tos_pop = ''; + } else { + $tos_pop = ""; + } + + /** + * Filter the TOS link text. + * + * @since 2.7.5 + * + * @param string The link text. + * @param string $toggle Toggle new registration or profile update. new|edit. + */ + $input.= apply_filters( 'wpmem_tos_link_txt', sprintf( __( 'Please indicate that you agree to the %s TOS %s', 'wp-members' ), $tos_pop, '' ), $toggle ); + + // in previous versions, the div class would end up being the same as the row before. + $field_before = ( $wrap_inputs ) ? '
    ' : ''; + $field_after = ( $wrap_inputs ) ? '
    ' : ''; + + } else { + + // for checkboxes + if ( $field[3] == 'checkbox' ) { + $valtochk = $val; + $val = $field[7]; + // if it should it be checked by default (& only if form not submitted), then override above... + if ( $field[8] == 'y' && ( ! $_POST && $toggle != 'edit' ) ) { $val = $valtochk = $field[7]; } + } + + // for dropdown select + if ( $field[3] == 'select' ) { + $valtochk = $val; + $val = $field[7]; + } + + if ( ! isset( $valtochk ) ) { $valtochk = ''; } + + // for all other input types + $input = wpmem_create_formfield( $field[2], $field[3], $val, $valtochk ); + + // determine input wrappers + $field_before = ( $wrap_inputs ) ? '
    ' : ''; + $field_after = ( $wrap_inputs ) ? '
    ' : ''; + } + + } + + // if the row is set to display, add the row to the form array + if ( $field[4] == 'y' ) { + $rows[$field[2]] = array( + 'order' => $field[0], + 'meta' => $field[2], + 'type' => $field[3], + 'value' => $val, + 'row_before' => $row_before, + 'label' => $label, + 'field_before' => $field_before, + 'field' => $input, + 'field_after' => $field_after, + 'row_after' => $row_after, + ); + } + } + + // if captcha is Really Simple CAPTCHA + if ( $wpmem->captcha == 2 && $toggle != 'edit' ) { + $row = wpmem_build_rs_captcha(); + $rows['captcha'] = array( + 'order' => '', + 'meta' => '', + 'type' => 'text', + 'value' => '', + 'row_before' => $row_before, + 'label' => $row['label'], + 'field_before' => ( $wrap_inputs ) ? '
    ' : '', + 'field' => $row['field'], + 'field_after' => ( $wrap_inputs ) ? '
    ' : '', + 'row_after' => $row_after, + ); + } + + /** + * Filter the array of form rows. + * + * This filter receives an array of the main rows in the form, each array element being + * an array of that particular row's pieces. This allows making changes to individual + * parts of a row without needing to parse through a string of HTML. + * + * @since 2.9.0 + * + * @param array $rows An array containing the form rows. + * @param string $toggle Toggle new registration or profile update. new|edit. + */ + $rows = apply_filters( 'wpmem_register_form_rows', $rows, $toggle ); + + // put the rows from the array into $form + $form = ''; $enctype = ''; + foreach ( $rows as $row_item ) { + $enctype = ( $row_item['type'] == 'file' ) ? "multipart/form-data" : $enctype; + $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $n . $row_item['label'] . $n : $row_item['label'] . $n; + $row .= ( $row_item['field_before'] != '' ) ? $row_item['field_before'] . $n . $t . $row_item['field'] . $n . $row_item['field_after'] . $n : $row_item['field'] . $n; + $row .= ( $row_item['row_after'] != '' ) ? $row_item['row_after'] . $n : ''; + $form.= $row; + } + + // do recaptcha if enabled + if ( $wpmem->captcha == 1 && $toggle != 'edit' ) { // don't show on edit page! + + // get the captcha options + $wpmem_captcha = get_option( 'wpmembers_captcha' ); + + // start with a clean row + $row = ''; + $row = '
    '; + $row.= '
    ' . wpmem_inc_recaptcha( $wpmem_captcha['recaptcha'] ) . '
    '; + + // add the captcha row to the form + /** + * Filter the HTML for the CAPTCHA row. + * + * @since 2.9.0 + * + * @param string The HTML for the entire row (includes HTML tags plus reCAPTCHA). + * @param string $toggle Toggle new registration or profile update. new|edit. + */ + $form.= apply_filters( 'wpmem_register_captcha_row', $row_before . $row . $row_after, $toggle ); + } + + // create hidden fields + $var = ( $toggle == 'edit' ) ? 'update' : 'register'; + $redirect_to = ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : get_permalink(); + $hidden = '' . $n; + $hidden .= '' . $n; + $hidden = ( isset( $hidden_tos ) ) ? $hidden . $hidden_tos . $n : $hidden; + + /** + * Filter the hidden field HTML. + * + * @since 2.9.0 + * + * @param string $hidden The generated HTML of hidden fields. + * @param string $toggle Toggle new registration or profile update. new|edit. + */ + $hidden = apply_filters( 'wpmem_register_hidden_fields', $hidden, $toggle ); + + // add the hidden fields to the form + $form.= $hidden; + + // create buttons and wrapper + $button_text = ( $toggle == 'edit' ) ? $submit_update : $submit_register; + $buttons = ( $show_clear_form ) ? ' ' . $n : ''; + $buttons.= '' . $n; + + /** + * Filter the HTML for form buttons. + * + * The string passed through the filter includes the buttons, as well as the HTML wrapper elements. + * + * @since 2.9.0 + * + * @param string $buttons The generated HTML of the form buttons. + * @param string $toggle Toggle new registration or profile update. new|edit. + */ + $buttons = apply_filters( 'wpmem_register_form_buttons', $buttons, $toggle ); + + // add the buttons to the form + $form.= $buttons_before . $n . $buttons . $buttons_after . $n; + + // add the required field notation to the bottom of the form + $form.= $req_label_before . $req_mark . $req_label . $req_label_after; + + // apply the heading + /** + * Filter the registration form heading. + * + * @since 2.8.2 + * + * @param string $str + * @param string $toggle Toggle new registration or profile update. new|edit. + */ + $heading = ( !$heading ) ? apply_filters( 'wpmem_register_heading', __( 'New User Registration', 'wp-members' ), $toggle ) : $heading; + $form = $heading_before . $heading . $heading_after . $n . $form; + + // apply fieldset wrapper + $form = $fieldset_before . $n . $form . $n . $fieldset_after; + + // apply attribution if enabled + $form = $form . wpmem_inc_attribution(); + + // apply nonce + $form = ( defined( 'WPMEM_USE_NONCE' ) || $use_nonce ) ? wp_nonce_field( 'wpmem-validate-submit', 'wpmem-form-submit' ) . $n . $form : $form; + + // apply form wrapper + $enctype = ( $enctype == 'multipart/form-data' ) ? ' enctype="multipart/form-data"' : ''; + $form = '
    ' . $n . $form. $n . '
    '; + + // apply anchor + $form = '' . $n . $form; + + // apply main div wrapper + $form = $main_div_before . $n . $form . $n . $main_div_after . $n; + + // apply wpmem_txt wrapper + $form = $txt_before . $form . $txt_after; + + // remove line breaks if enabled for easier filtering later + $form = ( $strip_breaks ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; + + /** + * Filter the generated HTML of the entire form. + * + * @since 2.7.4 + * + * @param string $form The HTML of the final generated form. + * @param string $toggle Toggle new registration or profile update. new|edit. + * @param array $rows The rows array + * @param string $hidden The HTML string of hidden fields + */ + $form = apply_filters( 'wpmem_register_form', $form, $toggle, $rows, $hidden ); + + /** + * Filter before the form. + * + * This rarely used filter allows you to stick any string onto the front of + * the generated form. + * + * @since 2.7.4 + * + * @param string $str The HTML to add before the form. Default null. + * @param string $toggle Toggle new registration or profile update. new|edit. + */ + $form = apply_filters( 'wpmem_register_form_before', '', $toggle ) . $form; + + // return the generated form + return $form; +} // end wpmem_inc_registration +endif; + + +if ( ! function_exists( 'wpmem_inc_recaptcha' ) ): +/** + * Create reCAPTCHA form. + * + * @since 2.6.0 + * + * @param array $arr + * @return string $str + */ +function wpmem_inc_recaptcha( $arr ) { + + // determine if reCAPTCHA should be another language + $allowed_langs = array( 'nl', 'fr', 'de', 'pt', 'ru', 'es', 'tr' ); + $compare_lang = strtolower( substr( WPLANG, -2 ) ); + $use_the_lang = ( in_array( $compare_lang, $allowed_langs ) ) ? $compare_lang : false; + $lang = ( $use_the_lang ) ? ' lang : \'' . $use_the_lang . '\'' : ''; + + // determine if we need ssl + $http = wpmem_use_ssl(); + + $str = ' + + '; + + /** + * Filter the reCAPTCHA HTML. + * + * @since 2.7.4 + * + * @param string $str A string of HTML for the reCAPTCHA. + */ + $str = apply_filters( 'wpmem_recaptcha', $str ); + + return $str; +} +endif; + + +/** + * Create an attribution link in the form. + * + * @since 2.6.0 + * + * @return string $str + */ +function wpmem_inc_attribution() { + + $http = ( is_ssl() ) ? 'https://' : 'http://'; + $str = ' +
    + Powered by WP-Members +
    '; + + return ( get_option( 'wpmembers_attrib' ) ) ? $str : ''; +} + + +/** + * Create Really Simple CAPTCHA. + * + * @since 2.9.5 + * + * @return array Form elements for Really Simple CAPTCHA. + */ +function wpmem_build_rs_captcha() { + + if ( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { + // setup defaults + $defaults = array( + 'characters' => 'ABCDEFGHJKLMNPQRSTUVWXYZ23456789', + 'num_char' => '4', + 'dim_w' => '72', + 'dim_h' => '30', + 'font_color' => '0,0,0', + 'bg_color' => '255,255,255', + 'font_size' => '12', + 'kerning' => '14', + 'img_type' => 'png', + ); + $wpmem_captcha = get_option( 'wpmembers_captcha' ); + + extract( wp_parse_args( $wpmem_captcha['really_simple'], $defaults ) ); + + $img_size = array( $dim_w, $dim_h ); + $fg = explode( ",", $font_color ); + $bg = explode( ",", $bg_color ); + + $wpmem_captcha = new ReallySimpleCaptcha(); + $wpmem_captcha->chars = $characters; + $wpmem_captcha->char_length = $num_char; + $wpmem_captcha->img_size = $img_size; + $wpmem_captcha->fg = $fg; + $wpmem_captcha->bg = $bg; + $wpmem_captcha->font_size = $font_size; + $wpmem_captcha->font_char_width = $kerning; + $wpmem_captcha->img_type = $img_type; + + $wpmem_captcha_word = $wpmem_captcha->generate_random_word(); + $wpmem_captcha_prefix = mt_rand(); + $wpmem_captcha_image_name = $wpmem_captcha->generate_image( $wpmem_captcha_prefix, $wpmem_captcha_word ); + + /** + * Filters the default Really Simple Captcha folder location. + * + * @since 3.0 + * + * @param string The default location of RS Captcha. + */ + $wpmem_captcha_image_url = apply_filters( 'wpmem_rs_captcha_folder', get_bloginfo('wpurl') . '/wp-content/plugins/really-simple-captcha/tmp/' ); + + $img_w = $wpmem_captcha->img_size[0]; + $img_h = $wpmem_captcha->img_size[1]; + $src = $wpmem_captcha_image_url . $wpmem_captcha_image_name; + $size = $wpmem_captcha->char_length; + $pre = $wpmem_captcha_prefix; + + return array( + 'label' => '', + 'field' => ' + + captcha' + ); + } else { + return; + } +} + /** End of File **/ \ No newline at end of file diff --git a/wp-members-register.php b/inc/register.php similarity index 96% rename from wp-members-register.php rename to inc/register.php index 2d6e5021..71edcce0 100644 --- a/wp-members-register.php +++ b/inc/register.php @@ -1,464 +1,464 @@ -errors ) { - $wpmem_themsg = $errors->get_error_message(); return $wpmem_themsg; exit; - } - - } else { - if( ! $fields['username'] ) { $wpmem_themsg = __( 'Sorry, username is a required field', 'wp-members' ); return $wpmem_themsg; exit(); } - if( ! validate_username( $fields['username'] ) ) { $wpmem_themsg = __( 'The username cannot include non-alphanumeric characters.', 'wp-members' ); return $wpmem_themsg; exit(); } - if( ! is_email( $fields['user_email']) ) { $wpmem_themsg = __( 'You must enter a valid email address.', 'wp-members' ); return $wpmem_themsg; exit(); } - if( username_exists( $fields['username'] ) ) { return "user"; exit(); } - if( email_exists( $fields['user_email'] ) ) { return "email"; exit(); } - } - if( $wpmem_themsg ) { return "empty"; exit(); } - - // If form contains password and email confirmation, validate that they match. - if( array_key_exists( 'confirm_password', $fields ) && $fields['confirm_password'] != $fields ['password'] ) { $wpmem_themsg = __( 'Passwords did not match.', 'wp-members' ); } - if( array_key_exists( 'confirm_email', $fields ) && $fields['confirm_email'] != $fields ['user_email'] ) { $wpmem_themsg = __( 'Emails did not match.', 'wp-members' ); } - - $wpmem_captcha = get_option( 'wpmembers_captcha' ); // Get the captcha settings (api keys). - if( $wpmem->captcha == 1 && $wpmem_captcha['recaptcha'] ) { // If captcha is on, check the captcha. - - if( $wpmem_captcha['recaptcha']['public'] && $wpmem_captcha['recaptcha']['private'] ) { // If there is no api key, the captcha never displayed to the end user. - if( !$_POST["recaptcha_response_field"] ) { // validate for empty captcha field - $wpmem_themsg = __( 'You must complete the CAPTCHA form.', 'wp-members' ); - return "empty"; exit(); - } - } - - // Check to see if the recaptcha library has already been loaded by another plugin. - if( ! function_exists( '_recaptcha_qsencode' ) ) { require_once('lib/recaptchalib.php'); } - - $publickey = $wpmem_captcha['recaptcha']['public']; - $privatekey = $wpmem_captcha['recaptcha']['private']; - - // The response from reCAPTCHA. - $resp = null; - // The error code from reCAPTCHA, if any. - $error = null; - - if( $_POST["recaptcha_response_field"] ) { - - $resp = recaptcha_check_answer ( - $privatekey, - $_SERVER["REMOTE_ADDR"], - $_POST["recaptcha_challenge_field"], - $_POST["recaptcha_response_field"] - ); - - if( ! $resp->is_valid ) { - - // Set the error code so that we can display it. - global $wpmem_captcha_err; - $wpmem_captcha_err = $resp->error; - $wpmem_captcha_err = wpmem_get_captcha_err( $wpmem_captcha_err ); - - return "captcha"; - exit(); - - } - } // End check recaptcha. - } elseif( $wpmem->captcha == 2 ) { - if( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { - // Validate Really Simple Captcha. - $wpmem_captcha = new ReallySimpleCaptcha(); - // This variable holds the CAPTCHA image prefix, which corresponds to the correct answer. - $wpmem_captcha_prefix = ( isset( $_POST['captcha_prefix'] ) ) ? $_POST['captcha_prefix'] : ''; - // This variable holds the CAPTCHA response, entered by the user. - $wpmem_captcha_code = ( isset( $_POST['captcha_code'] ) ) ? $_POST['captcha_code'] : ''; - // Check CAPTCHA validity. - $wpmem_captcha_correct = ( $wpmem_captcha->check( $wpmem_captcha_prefix, $wpmem_captcha_code ) ) ? true : false; - // Clean up the tmp directory. - $wpmem_captcha->remove( $wpmem_captcha_prefix ); - $wpmem_captcha->cleanup(); - // If CAPTCHA validation fails (incorrect value entered in CAPTCHA field), return an error. - if ( ! $wpmem_captcha_correct ) { - $wpmem_themsg = wpmem_get_captcha_err( 'really-simple' ); - return "empty"; exit(); - } - } - } - - // Check for user defined password. - $fields['password'] = ( ! isset( $_POST['password'] ) ) ? wp_generate_password() : $_POST['password']; - - // Add for _data hooks - $fields['user_registered'] = gmdate( 'Y-m-d H:i:s' ); - $fields['user_role'] = get_option( 'default_role' ); - $fields['wpmem_reg_ip'] = $_SERVER['REMOTE_ADDR']; - $fields['wpmem_reg_url'] = $_REQUEST['redirect_to']; - - /* - * These native fields are not installed by default, but if they - * are added, use the $_POST value - otherwise, default to username. - * value can be filtered with wpmem_register_data - */ - $fields['user_nicename'] = ( isset( $_POST['user_nicename'] ) ) ? sanitize_title( $_POST['user_nicename'] ) : $fields['username']; - $fields['display_name'] = ( isset( $_POST['display_name'] ) ) ? sanitize_user ( $_POST['display_name'] ) : $fields['username']; - $fields['nickname'] = ( isset( $_POST['nickname'] ) ) ? sanitize_user ( $_POST['nickname'] ) : $fields['username']; - - /** - * Filter registration data after validation before data insertion. - * - * @since 2.8.2 - * - * @param array $fields An array of the registration field data. - * @param string $toggle A switch to indicate the action (new|edit). - */ - $fields = apply_filters( 'wpmem_register_data', $fields, 'new' ); - - /** - * Fires before any insertion/emails. - * - * This action is the final step in pre registering a user. This - * can be used for attaching custom validation to the registration - * process. It cannot be used for changing any user registration - * data. Use the wpmem_register_data filter for that. - * - * @since 2.7.2 - * - * @param array $fields The user's submitted registration data. - */ - do_action( 'wpmem_pre_register_data', $fields ); - - // If the _pre_register_data hook sends back an error message. - if( $wpmem_themsg ){ return $wpmem_themsg; } - - // Main new user fields are ready. - $new_user_fields = array ( - 'user_pass' => $fields['password'], - 'user_login' => $fields['username'], - 'user_nicename' => $fields['user_nicename'], - 'user_email' => $fields['user_email'], - 'display_name' => $fields['display_name'], - 'nickname' => $fields['nickname'], - 'user_registered' => $fields['user_registered'], - 'role' => $fields['user_role'] - ); - - // Get any excluded meta fields. - $excluded_meta = wpmem_get_excluded_meta( 'register' ); - - // User_url, first_name, last_name, description, jabber, aim, yim. - $new_user_fields_meta = array( 'user_url', 'first_name', 'last_name', 'description', 'jabber', 'aim', 'yim' ); - foreach( $wpmem_fields as $meta ) { - if( in_array( $meta[2], $new_user_fields_meta ) ) { - if( $meta[4] == 'y' && ! in_array( $meta[2], $excluded_meta ) ) { - $new_user_fields[$meta[2]] = $fields[$meta[2]]; - } - } - } - - // Inserts to wp_users table. - $fields['ID'] = wp_insert_user( $new_user_fields ); - - // Set remaining fields to wp_usermeta table. - foreach( $wpmem_fields as $meta ) { - // If the field is not excluded, update accordingly. - if( ! in_array( $meta[2], $excluded_meta ) && ! in_array( $meta[2], $new_user_fields_meta ) ) { - if( $meta[4] == 'y' && $meta[2] != 'user_email' ) { - update_user_meta( $fields['ID'], $meta[2], $fields[$meta[2]] ); - } - } - } - - // Capture IP address of user at registration. - update_user_meta( $fields['ID'], 'wpmem_reg_ip', $fields['wpmem_reg_ip'] ); - - // Store the registration url. - update_user_meta( $fields['ID'], 'wpmem_reg_url', $fields['wpmem_reg_url'] ); - - // Set user expiration, if used. - if( $wpmem->use_exp == 1 && $wpmem->mod_reg != 1 ) { wpmem_set_exp( $fields['ID'] ); } - - /** - * Fires after user insertion but before email. - * - * @since 2.7.2 - * - * @param array $fields The user's submitted registration data. - */ - do_action( 'wpmem_post_register_data', $fields ); - - require_once( 'wp-members-email.php' ); - - /* - * If this was successful, and you have email properly - * configured, send a notification email to the user. - */ - wpmem_inc_regemail( $fields['ID'], $fields['password'], $wpmem->mod_reg, $wpmem_fields, $fields ); - - // Notify admin of new reg, if needed. - if( $wpmem->notify == 1 ) { wpmem_notify_admin( $fields['ID'], $wpmem_fields ); } - - /** - * Fires after registration is complete. - * - * @since 2.7.1 - */ - do_action( 'wpmem_register_redirect' ); - - // successful registration message - return "success"; exit(); - break; - - case "update": - - if( $wpmem_themsg ) { return "updaterr"; exit(); } - - /* - * Doing a check for existing email is not the same as a new reg. check first to - * see if it's different, then check if it is a valid address and it exists. - */ - global $current_user; get_currentuserinfo(); - if( $fields['user_email'] != $current_user->user_email ) { - if( email_exists( $fields['user_email'] ) ) { return "email"; exit(); } - if( !is_email( $fields['user_email']) ) { $wpmem_themsg = __( 'You must enter a valid email address.', 'wp-members' ); return "updaterr"; exit(); } - } - - // If form includes email confirmation, validate that they match. - if( array_key_exists( 'confirm_email', $fields ) && $fields['confirm_email'] != $fields ['user_email'] ) { $wpmem_themsg = __( 'Emails did not match.', 'wp-members' ); } - - // Add the user_ID to the fields array. - $fields['ID'] = $user_ID; - - /** - * Filter registration data after validation before data insertion. - * - * @since 2.8.2 - * - * @param array $fields An array of the registration field data. - * @param string $toggle A switch to indicate the action (new|edit). - */ - $fields = apply_filters( 'wpmem_register_data', $fields, 'edit' ); - - /** - * Fires before data insertion. - * - * This action is the final step in pre updating a user. This - * can be used for attaching custom validation to the update - * process. It cannot be used for changing any user update - * data. Use the wpmem_register_data filter for that. - * - * @since 2.7.2 - * - * @param array $fields The user's submitted update data. - */ - do_action( 'wpmem_pre_update_data', $fields ); - - /* - * If the _pre_update_data hook sends back an error message. - * @todo - double check this. it should probably return "updaterr" and the hook should globalize wpmem_themsg - */ - if( $wpmem_themsg ){ return $wpmem_themsg; } - - // A list of fields that can be updated by wp_update_user. - $native_fields = array( - 'user_nicename', - 'user_url', - 'user_email', - 'display_name', - 'nickname', - 'first_name', - 'last_name', - 'description', - 'role', - 'jabber', - 'aim', - 'yim' - ); - $native_update = array( 'ID' => $user_ID ); - - foreach( $wpmem_fields as $meta ) { - // If the field is not excluded, update accordingly. - if( ! in_array( $meta[2], wpmem_get_excluded_meta( 'update' ) ) ) { - switch( $meta[2] ) { - - // If the field can be updated by wp_update_user. - case( in_array( $meta[2], $native_fields ) ): - $fields[$meta[2]] = ( isset( $fields[$meta[2]] ) ) ? $fields[$meta[2]] : ''; - $native_update[$meta[2]] = $fields[$meta[2]]; - break; - - // If the field is password. - case( 'password' ): - // Do nothing. - break; - - // Everything else goes into wp_usermeta. - default: - if( $meta[4] == 'y' ) { - update_user_meta( $user_ID, $meta[2], $fields[$meta[2]] ); - } - break; - } - } - } - - // Update wp_update_user fields. - wp_update_user( $native_update ); - - /** - * Fires at the end of user update data insertion. - * - * @since 2.7.2 - * - * @param array $fields The user's submitted registration data. - */ - do_action( 'wpmem_post_update_data', $fields ); - - return "editsuccess"; exit(); - break; - } -} // End registration function. -endif; - - -if( ! function_exists( 'wpmem_get_captcha_err' ) ): -/** - * Generate reCAPTCHA error messages. - * - * @since 2.4 - * - * @param string $wpmem_captcha_err The response from the reCAPTCHA API. - * @return string $wpmem_captcha_err The appropriate error message. - */ -function wpmem_get_captcha_err( $wpmem_captcha_err ) { - - switch( $wpmem_captcha_err ) { - - case "invalid-site-public-key": - $wpmem_captcha_err = __( 'We were unable to validate the public key.', 'wp-members' ); - break; - - case "invalid-site-public-key": - $wpmem_captcha_err = __( 'We were unable to validate the private key.', 'wp-members' ); - break; - - case "invalid-request-cookie": - $wpmem_captcha_err = __( 'The challenge parameter of the verify script was incorrect.', 'wp-members' ); - break; - - case "incorrect-captcha-sol": - $wpmem_captcha_err = __( 'The CAPTCHA solution was incorrect.', 'wp-members' ); - break; - - case "verify-params-incorrect": - $wpmem_captcha_err = __( 'The parameters to verify were incorrect', 'wp-members' ); - break; - - case "invalid-referrer": - $wpmem_captcha_err = __( 'reCAPTCHA API keys are tied to a specific domain name for security reasons.', 'wp-members' ); - break; - - case "recaptcha-not-reachable": - $wpmem_captcha_err = __( 'The reCAPTCHA server was not reached. Please try to resubmit.', 'wp-members' ); - break; - - case 'really-simple': - $wpmem_captcha_err = __( 'You have entered an incorrect code value. Please try again.', 'wp-members' ); - break; - } - - return $wpmem_captcha_err; -} -endif; - +errors ) { + $wpmem_themsg = $errors->get_error_message(); return $wpmem_themsg; exit; + } + + } else { + if( ! $fields['username'] ) { $wpmem_themsg = __( 'Sorry, username is a required field', 'wp-members' ); return $wpmem_themsg; exit(); } + if( ! validate_username( $fields['username'] ) ) { $wpmem_themsg = __( 'The username cannot include non-alphanumeric characters.', 'wp-members' ); return $wpmem_themsg; exit(); } + if( ! is_email( $fields['user_email']) ) { $wpmem_themsg = __( 'You must enter a valid email address.', 'wp-members' ); return $wpmem_themsg; exit(); } + if( username_exists( $fields['username'] ) ) { return "user"; exit(); } + if( email_exists( $fields['user_email'] ) ) { return "email"; exit(); } + } + if( $wpmem_themsg ) { return "empty"; exit(); } + + // If form contains password and email confirmation, validate that they match. + if( array_key_exists( 'confirm_password', $fields ) && $fields['confirm_password'] != $fields ['password'] ) { $wpmem_themsg = __( 'Passwords did not match.', 'wp-members' ); } + if( array_key_exists( 'confirm_email', $fields ) && $fields['confirm_email'] != $fields ['user_email'] ) { $wpmem_themsg = __( 'Emails did not match.', 'wp-members' ); } + + $wpmem_captcha = get_option( 'wpmembers_captcha' ); // Get the captcha settings (api keys). + if( $wpmem->captcha == 1 && $wpmem_captcha['recaptcha'] ) { // If captcha is on, check the captcha. + + if( $wpmem_captcha['recaptcha']['public'] && $wpmem_captcha['recaptcha']['private'] ) { // If there is no api key, the captcha never displayed to the end user. + if( !$_POST["recaptcha_response_field"] ) { // validate for empty captcha field + $wpmem_themsg = __( 'You must complete the CAPTCHA form.', 'wp-members' ); + return "empty"; exit(); + } + } + + // Check to see if the recaptcha library has already been loaded by another plugin. + if( ! function_exists( '_recaptcha_qsencode' ) ) { require_once('lib/recaptchalib.php'); } + + $publickey = $wpmem_captcha['recaptcha']['public']; + $privatekey = $wpmem_captcha['recaptcha']['private']; + + // The response from reCAPTCHA. + $resp = null; + // The error code from reCAPTCHA, if any. + $error = null; + + if( $_POST["recaptcha_response_field"] ) { + + $resp = recaptcha_check_answer ( + $privatekey, + $_SERVER["REMOTE_ADDR"], + $_POST["recaptcha_challenge_field"], + $_POST["recaptcha_response_field"] + ); + + if( ! $resp->is_valid ) { + + // Set the error code so that we can display it. + global $wpmem_captcha_err; + $wpmem_captcha_err = $resp->error; + $wpmem_captcha_err = wpmem_get_captcha_err( $wpmem_captcha_err ); + + return "captcha"; + exit(); + + } + } // End check recaptcha. + } elseif( $wpmem->captcha == 2 ) { + if( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { + // Validate Really Simple Captcha. + $wpmem_captcha = new ReallySimpleCaptcha(); + // This variable holds the CAPTCHA image prefix, which corresponds to the correct answer. + $wpmem_captcha_prefix = ( isset( $_POST['captcha_prefix'] ) ) ? $_POST['captcha_prefix'] : ''; + // This variable holds the CAPTCHA response, entered by the user. + $wpmem_captcha_code = ( isset( $_POST['captcha_code'] ) ) ? $_POST['captcha_code'] : ''; + // Check CAPTCHA validity. + $wpmem_captcha_correct = ( $wpmem_captcha->check( $wpmem_captcha_prefix, $wpmem_captcha_code ) ) ? true : false; + // Clean up the tmp directory. + $wpmem_captcha->remove( $wpmem_captcha_prefix ); + $wpmem_captcha->cleanup(); + // If CAPTCHA validation fails (incorrect value entered in CAPTCHA field), return an error. + if ( ! $wpmem_captcha_correct ) { + $wpmem_themsg = wpmem_get_captcha_err( 'really-simple' ); + return "empty"; exit(); + } + } + } + + // Check for user defined password. + $fields['password'] = ( ! isset( $_POST['password'] ) ) ? wp_generate_password() : $_POST['password']; + + // Add for _data hooks + $fields['user_registered'] = gmdate( 'Y-m-d H:i:s' ); + $fields['user_role'] = get_option( 'default_role' ); + $fields['wpmem_reg_ip'] = $_SERVER['REMOTE_ADDR']; + $fields['wpmem_reg_url'] = $_REQUEST['redirect_to']; + + /* + * These native fields are not installed by default, but if they + * are added, use the $_POST value - otherwise, default to username. + * value can be filtered with wpmem_register_data + */ + $fields['user_nicename'] = ( isset( $_POST['user_nicename'] ) ) ? sanitize_title( $_POST['user_nicename'] ) : $fields['username']; + $fields['display_name'] = ( isset( $_POST['display_name'] ) ) ? sanitize_user ( $_POST['display_name'] ) : $fields['username']; + $fields['nickname'] = ( isset( $_POST['nickname'] ) ) ? sanitize_user ( $_POST['nickname'] ) : $fields['username']; + + /** + * Filter registration data after validation before data insertion. + * + * @since 2.8.2 + * + * @param array $fields An array of the registration field data. + * @param string $toggle A switch to indicate the action (new|edit). + */ + $fields = apply_filters( 'wpmem_register_data', $fields, 'new' ); + + /** + * Fires before any insertion/emails. + * + * This action is the final step in pre registering a user. This + * can be used for attaching custom validation to the registration + * process. It cannot be used for changing any user registration + * data. Use the wpmem_register_data filter for that. + * + * @since 2.7.2 + * + * @param array $fields The user's submitted registration data. + */ + do_action( 'wpmem_pre_register_data', $fields ); + + // If the _pre_register_data hook sends back an error message. + if( $wpmem_themsg ){ return $wpmem_themsg; } + + // Main new user fields are ready. + $new_user_fields = array ( + 'user_pass' => $fields['password'], + 'user_login' => $fields['username'], + 'user_nicename' => $fields['user_nicename'], + 'user_email' => $fields['user_email'], + 'display_name' => $fields['display_name'], + 'nickname' => $fields['nickname'], + 'user_registered' => $fields['user_registered'], + 'role' => $fields['user_role'] + ); + + // Get any excluded meta fields. + $excluded_meta = wpmem_get_excluded_meta( 'register' ); + + // User_url, first_name, last_name, description, jabber, aim, yim. + $new_user_fields_meta = array( 'user_url', 'first_name', 'last_name', 'description', 'jabber', 'aim', 'yim' ); + foreach( $wpmem_fields as $meta ) { + if( in_array( $meta[2], $new_user_fields_meta ) ) { + if( $meta[4] == 'y' && ! in_array( $meta[2], $excluded_meta ) ) { + $new_user_fields[$meta[2]] = $fields[$meta[2]]; + } + } + } + + // Inserts to wp_users table. + $fields['ID'] = wp_insert_user( $new_user_fields ); + + // Set remaining fields to wp_usermeta table. + foreach( $wpmem_fields as $meta ) { + // If the field is not excluded, update accordingly. + if( ! in_array( $meta[2], $excluded_meta ) && ! in_array( $meta[2], $new_user_fields_meta ) ) { + if( $meta[4] == 'y' && $meta[2] != 'user_email' ) { + update_user_meta( $fields['ID'], $meta[2], $fields[$meta[2]] ); + } + } + } + + // Capture IP address of user at registration. + update_user_meta( $fields['ID'], 'wpmem_reg_ip', $fields['wpmem_reg_ip'] ); + + // Store the registration url. + update_user_meta( $fields['ID'], 'wpmem_reg_url', $fields['wpmem_reg_url'] ); + + // Set user expiration, if used. + if( $wpmem->use_exp == 1 && $wpmem->mod_reg != 1 ) { wpmem_set_exp( $fields['ID'] ); } + + /** + * Fires after user insertion but before email. + * + * @since 2.7.2 + * + * @param array $fields The user's submitted registration data. + */ + do_action( 'wpmem_post_register_data', $fields ); + + require_once( WPMEM_PATH . 'inc/email.php' ); + + /* + * If this was successful, and you have email properly + * configured, send a notification email to the user. + */ + wpmem_inc_regemail( $fields['ID'], $fields['password'], $wpmem->mod_reg, $wpmem_fields, $fields ); + + // Notify admin of new reg, if needed. + if( $wpmem->notify == 1 ) { wpmem_notify_admin( $fields['ID'], $wpmem_fields ); } + + /** + * Fires after registration is complete. + * + * @since 2.7.1 + */ + do_action( 'wpmem_register_redirect' ); + + // successful registration message + return "success"; exit(); + break; + + case "update": + + if( $wpmem_themsg ) { return "updaterr"; exit(); } + + /* + * Doing a check for existing email is not the same as a new reg. check first to + * see if it's different, then check if it is a valid address and it exists. + */ + global $current_user; get_currentuserinfo(); + if( $fields['user_email'] != $current_user->user_email ) { + if( email_exists( $fields['user_email'] ) ) { return "email"; exit(); } + if( !is_email( $fields['user_email']) ) { $wpmem_themsg = __( 'You must enter a valid email address.', 'wp-members' ); return "updaterr"; exit(); } + } + + // If form includes email confirmation, validate that they match. + if( array_key_exists( 'confirm_email', $fields ) && $fields['confirm_email'] != $fields ['user_email'] ) { $wpmem_themsg = __( 'Emails did not match.', 'wp-members' ); } + + // Add the user_ID to the fields array. + $fields['ID'] = $user_ID; + + /** + * Filter registration data after validation before data insertion. + * + * @since 2.8.2 + * + * @param array $fields An array of the registration field data. + * @param string $toggle A switch to indicate the action (new|edit). + */ + $fields = apply_filters( 'wpmem_register_data', $fields, 'edit' ); + + /** + * Fires before data insertion. + * + * This action is the final step in pre updating a user. This + * can be used for attaching custom validation to the update + * process. It cannot be used for changing any user update + * data. Use the wpmem_register_data filter for that. + * + * @since 2.7.2 + * + * @param array $fields The user's submitted update data. + */ + do_action( 'wpmem_pre_update_data', $fields ); + + /* + * If the _pre_update_data hook sends back an error message. + * @todo - double check this. it should probably return "updaterr" and the hook should globalize wpmem_themsg + */ + if( $wpmem_themsg ){ return $wpmem_themsg; } + + // A list of fields that can be updated by wp_update_user. + $native_fields = array( + 'user_nicename', + 'user_url', + 'user_email', + 'display_name', + 'nickname', + 'first_name', + 'last_name', + 'description', + 'role', + 'jabber', + 'aim', + 'yim' + ); + $native_update = array( 'ID' => $user_ID ); + + foreach( $wpmem_fields as $meta ) { + // If the field is not excluded, update accordingly. + if( ! in_array( $meta[2], wpmem_get_excluded_meta( 'update' ) ) ) { + switch( $meta[2] ) { + + // If the field can be updated by wp_update_user. + case( in_array( $meta[2], $native_fields ) ): + $fields[$meta[2]] = ( isset( $fields[$meta[2]] ) ) ? $fields[$meta[2]] : ''; + $native_update[$meta[2]] = $fields[$meta[2]]; + break; + + // If the field is password. + case( 'password' ): + // Do nothing. + break; + + // Everything else goes into wp_usermeta. + default: + if( $meta[4] == 'y' ) { + update_user_meta( $user_ID, $meta[2], $fields[$meta[2]] ); + } + break; + } + } + } + + // Update wp_update_user fields. + wp_update_user( $native_update ); + + /** + * Fires at the end of user update data insertion. + * + * @since 2.7.2 + * + * @param array $fields The user's submitted registration data. + */ + do_action( 'wpmem_post_update_data', $fields ); + + return "editsuccess"; exit(); + break; + } +} // End registration function. +endif; + + +if( ! function_exists( 'wpmem_get_captcha_err' ) ): +/** + * Generate reCAPTCHA error messages. + * + * @since 2.4 + * + * @param string $wpmem_captcha_err The response from the reCAPTCHA API. + * @return string $wpmem_captcha_err The appropriate error message. + */ +function wpmem_get_captcha_err( $wpmem_captcha_err ) { + + switch( $wpmem_captcha_err ) { + + case "invalid-site-public-key": + $wpmem_captcha_err = __( 'We were unable to validate the public key.', 'wp-members' ); + break; + + case "invalid-site-public-key": + $wpmem_captcha_err = __( 'We were unable to validate the private key.', 'wp-members' ); + break; + + case "invalid-request-cookie": + $wpmem_captcha_err = __( 'The challenge parameter of the verify script was incorrect.', 'wp-members' ); + break; + + case "incorrect-captcha-sol": + $wpmem_captcha_err = __( 'The CAPTCHA solution was incorrect.', 'wp-members' ); + break; + + case "verify-params-incorrect": + $wpmem_captcha_err = __( 'The parameters to verify were incorrect', 'wp-members' ); + break; + + case "invalid-referrer": + $wpmem_captcha_err = __( 'reCAPTCHA API keys are tied to a specific domain name for security reasons.', 'wp-members' ); + break; + + case "recaptcha-not-reachable": + $wpmem_captcha_err = __( 'The reCAPTCHA server was not reached. Please try to resubmit.', 'wp-members' ); + break; + + case 'really-simple': + $wpmem_captcha_err = __( 'You have entered an incorrect code value. Please try again.', 'wp-members' ); + break; + } + + return $wpmem_captcha_err; +} +endif; + /** End of File **/ \ No newline at end of file diff --git a/sidebar.php b/inc/sidebar.php similarity index 100% rename from sidebar.php rename to inc/sidebar.php diff --git a/users.php b/inc/users.php similarity index 96% rename from users.php rename to inc/users.php index b975d2a0..e97bf6d8 100644 --- a/users.php +++ b/inc/users.php @@ -1,132 +1,132 @@ - -

    - - ' . __( '(required)' ) . '' : ''; - $show_field = ' - - - - '; - - /** - * Filter the field for user profile additional fields. - * - * @since 2.9.1 - * - * @parma string $show_field The HTML string of the additional field. - */ - echo apply_filters( 'wpmem_user_profile_field', $show_field ); - } - } ?> -
    '; - - $val = get_user_meta( $user_id, $meta[2], true ); - if ( $meta[3] == 'checkbox' || $meta[3] == 'select' ) { - $valtochk = $val; - $val = $meta[7]; - } - $show_field.= wpmem_create_formfield( $meta[2], $meta[3], $val, $valtochk ) . ' -
    +

    + + ' . __( '(required)' ) . '' : ''; + $show_field = ' + + + + '; + + /** + * Filter the field for user profile additional fields. + * + * @since 2.9.1 + * + * @parma string $show_field The HTML string of the additional field. + */ + echo apply_filters( 'wpmem_user_profile_field', $show_field ); + } + } ?> +
    '; + + $val = get_user_meta( $user_id, $meta[2], true ); + if ( $meta[3] == 'checkbox' || $meta[3] == 'select' ) { + $valtochk = $val; + $val = $meta[7]; + } + $show_field.= wpmem_create_formfield( $meta[2], $meta[3], $val, $valtochk ) . ' +
    "; - break; - - case "checkbox": - $class = ( $class == 'textbox' ) ? "checkbox" : $class; - $str = ""; - break; - - case "text": - $value = stripslashes( esc_attr( $value ) ); - $str = ""; - break; - - case "textarea": - $value = stripslashes( esc_textarea( $value ) ); - $class = ( $class == 'textbox' ) ? "textarea" : $class; - $str = ""; - break; - - case "password": - $str = ""; - break; - - case "hidden": - $str = ""; - break; - - case "option": - $str = ""; - break; - - case "select": - $class = ( $class == 'textbox' ) ? "dropdown" : $class; - $str = ""; - break; - - } - - return $str; -} -endif; - - -if ( ! function_exists( 'wpmem_selected' ) ): -/** - * Determines if a form field is selected (i.e. lists & checkboxes). - * - * @since 0.1 - * - * @param string $value - * @param string $valtochk - * @param string $type - * @return string $issame - */ -function wpmem_selected( $value, $valtochk, $type=null ) { - $issame = ( $type == 'select' ) ? ' selected' : ' checked'; - return ( $value == $valtochk ) ? $issame : ''; -} -endif; - - -if ( ! function_exists( 'wpmem_chk_qstr' ) ): -/** - * Checks querystrings. - * - * @since 2.0 - * - * @uses get_permalink - * @param string $url - * @return string $return_url - */ -function wpmem_chk_qstr( $url = null ) { - - $permalink = get_option( 'permalink_structure' ); - if ( ! $permalink ) { - $url = ( ! $url ) ? get_option( 'home' ) . "/?" . $_SERVER['QUERY_STRING'] : ''; - $return_url = $url . "&"; - } else { - $url = ( ! $url ) ? get_permalink() : ''; - $return_url = $url . "?"; - } - return $return_url; -} -endif; - - -if ( ! function_exists( 'wpmem_generatePassword' ) ): -/** - * Generates a random password. - * - * @since 2.0 - * - * @return string The random password. - */ -function wpmem_generatePassword() { - return substr( md5( uniqid( microtime() ) ), 0, 7 ); -} -endif; - - -if ( ! function_exists( 'wpmem_texturize' ) ): -/** - * Overrides the wptexturize filter. - * - * Currently only used for the login form to remove the
    tag that WP puts in after the "Remember Me". - * - * @since 2.6.4 - * - * @param string $content - * @return string $new_content - */ -function wpmem_texturize( $content ) { - - $new_content = ''; - $pattern_full = '{(\[wpmem_txt\].*?\[/wpmem_txt\])}is'; - $pattern_contents = '{\[wpmem_txt\](.*?)\[/wpmem_txt\]}is'; - $pieces = preg_split( $pattern_full, $content, -1, PREG_SPLIT_DELIM_CAPTURE ); - - foreach ( $pieces as $piece ) { - if ( preg_match( $pattern_contents, $piece, $matches ) ) { - $new_content .= $matches[1]; - } else { - $new_content .= wptexturize( wpautop( $piece ) ); - } - } - - return $new_content; -} -endif; - - -if ( ! function_exists( 'wpmem_enqueue_style' ) ): -/** - * Loads the stylesheet for tableless forms. - * - * @since 2.6 - * - * @global $wpmem - * @uses wp_register_style - * @uses wp_enqueue_style - */ -function wpmem_enqueue_style() { - global $wpmem; - wp_register_style( 'wp-members', $wpmem->cssurl, '', WPMEM_VERSION ); - wp_enqueue_style ( 'wp-members' ); -} -endif; - - -if ( ! function_exists( 'wpmem_do_excerpt' ) ): -/** - * Creates an excerpt on the fly if there is no 'more' tag. - * - * @since 2.6 - * - * @param string $content - * @return string $content - */ -function wpmem_do_excerpt( $content ) { - - $arr = get_option( 'wpmembers_autoex' ); - - // Is there already a 'more' link in the content? - $has_more_link = ( stristr( $content, 'class="more-link"' ) ) ? true : false; - - // If auto_ex is on. - if ( $arr['auto_ex'] == true ) { - - // Build an excerpt if one does not exist. - if ( ! $has_more_link ) { - - $words = explode( ' ', $content, ( $arr['auto_ex_len'] + 1 ) ); - if ( count( $words ) > $arr['auto_ex_len'] ) { - array_pop( $words ); - } - $content = implode( ' ', $words ); - - // Check for common html tags. - $common_tags = array( 'i', 'b', 'strong', 'em', 'h1', 'h2', 'h3', 'h4', 'h5' ); - foreach ( $common_tags as $tag ) { - if ( stristr( $content, '<' . $tag . '>' ) ) { - $after = stristr( $content, '' ); - $content = ( ! stristr( $after, '' ) ) ? $content . '' : $content; - } - } - } - } - - global $post, $more; - // If there is no 'more' link and auto_ex is on. - if ( ! $has_more_link && ( $arr['auto_ex'] == true ) ) { - // The default $more_link_text. - $more_link_text = __( '(more…)' ); - // The default $more_link. - $more_link = ' ' . $more_link_text . ''; - // Apply the_content_more_link filter if one exists (will match up all 'more' link text). - $more_link = apply_filters( 'the_content_more_link' , $more_link, $more_link_text ); - // Add the more link to the excerpt. - $content = $content . $more_link; - } - - /** - * Filter the auto excerpt. - * - * @since 2.8.1 - * - * @param string $content The excerpt. - */ - $content = apply_filters( 'wpmem_auto_excerpt', $content ); - - // Return the excerpt. - return $content; -} -endif; - - -if ( ! function_exists( 'wpmem_test_shortcode' ) ): -/** - * Tests $content for the presence of the [wp-members] shortcode. - * - * @since 2.6 - * - * @global string $post - * @uses get_shortcode_regex - * @return bool - * - * @example http://codex.wordpress.org/Function_Reference/get_shortcode_regex - */ -function wpmem_test_shortcode( $content, $tag ) { - - global $shortcode_tags; - if ( array_key_exists( $tag, $shortcode_tags ) ) { - preg_match_all( '/' . get_shortcode_regex() . '/s', $content, $matches, PREG_SET_ORDER ); - if ( empty( $matches ) ) { - return false; - } - - foreach ( $matches as $shortcode ) { - if ( $tag === $shortcode[2] ) { - return true; - } - } - } - return false; -} -endif; - - -/** - * Sets an array of user meta fields to be excluded from update/insert. - * - * @since 2.9.3 - * - * @param string $tag A tag so we know where the function is being used. - */ -function wpmem_get_excluded_meta( $tag ) { - - /** - * Filter the fields to be excluded when user is created/updated. - * - * @since 2.9.3 - * - * @param array An array of the field meta names to exclude. - * @param string $tag A tag so we know where the function is being used. - */ - return apply_filters( 'wpmem_exclude_fields', array( 'password', 'confirm_password', 'confirm_email', 'password_confirm', 'email_confirm' ), $tag ); -} - - -/** - * Returns http:// or https:// depending on ssl. - * - * @ since 2.9.8 - */ -function wpmem_use_ssl() { - return ( is_ssl() ) ? 'https://' : 'http://'; -} - +"; + break; + + case "checkbox": + $class = ( $class == 'textbox' ) ? "checkbox" : $class; + $str = ""; + break; + + case "text": + $value = stripslashes( esc_attr( $value ) ); + $str = ""; + break; + + case "textarea": + $value = stripslashes( esc_textarea( $value ) ); + $class = ( $class == 'textbox' ) ? "textarea" : $class; + $str = ""; + break; + + case "password": + $str = ""; + break; + + case "hidden": + $str = ""; + break; + + case "option": + $str = ""; + break; + + case "select": + $class = ( $class == 'textbox' ) ? "dropdown" : $class; + $str = ""; + break; + + } + + return $str; +} +endif; + + +if ( ! function_exists( 'wpmem_selected' ) ): +/** + * Determines if a form field is selected (i.e. lists & checkboxes). + * + * @since 0.1 + * + * @param string $value + * @param string $valtochk + * @param string $type + * @return string $issame + */ +function wpmem_selected( $value, $valtochk, $type=null ) { + $issame = ( $type == 'select' ) ? ' selected' : ' checked'; + return ( $value == $valtochk ) ? $issame : ''; +} +endif; + + +if ( ! function_exists( 'wpmem_chk_qstr' ) ): +/** + * Checks querystrings. + * + * @since 2.0 + * + * @uses get_permalink + * @param string $url + * @return string $return_url + */ +function wpmem_chk_qstr( $url = null ) { + + $permalink = get_option( 'permalink_structure' ); + if ( ! $permalink ) { + $url = ( ! $url ) ? get_option( 'home' ) . "/?" . $_SERVER['QUERY_STRING'] : ''; + $return_url = $url . "&"; + } else { + $url = ( ! $url ) ? get_permalink() : ''; + $return_url = $url . "?"; + } + return $return_url; +} +endif; + + +if ( ! function_exists( 'wpmem_generatePassword' ) ): +/** + * Generates a random password. + * + * @since 2.0 + * + * @return string The random password. + */ +function wpmem_generatePassword() { + return substr( md5( uniqid( microtime() ) ), 0, 7 ); +} +endif; + + +if ( ! function_exists( 'wpmem_texturize' ) ): +/** + * Overrides the wptexturize filter. + * + * Currently only used for the login form to remove the
    tag that WP puts in after the "Remember Me". + * + * @since 2.6.4 + * + * @param string $content + * @return string $new_content + */ +function wpmem_texturize( $content ) { + + $new_content = ''; + $pattern_full = '{(\[wpmem_txt\].*?\[/wpmem_txt\])}is'; + $pattern_contents = '{\[wpmem_txt\](.*?)\[/wpmem_txt\]}is'; + $pieces = preg_split( $pattern_full, $content, -1, PREG_SPLIT_DELIM_CAPTURE ); + + foreach ( $pieces as $piece ) { + if ( preg_match( $pattern_contents, $piece, $matches ) ) { + $new_content .= $matches[1]; + } else { + $new_content .= wptexturize( wpautop( $piece ) ); + } + } + + return $new_content; +} +endif; + + +if ( ! function_exists( 'wpmem_enqueue_style' ) ): +/** + * Loads the stylesheet for tableless forms. + * + * @since 2.6 + * + * @global $wpmem + * @uses wp_register_style + * @uses wp_enqueue_style + */ +function wpmem_enqueue_style() { + global $wpmem; + wp_register_style( 'wp-members', $wpmem->cssurl, '', WPMEM_VERSION ); + wp_enqueue_style ( 'wp-members' ); +} +endif; + + +if ( ! function_exists( 'wpmem_do_excerpt' ) ): +/** + * Creates an excerpt on the fly if there is no 'more' tag. + * + * @since 2.6 + * + * @param string $content + * @return string $content + */ +function wpmem_do_excerpt( $content ) { + + $arr = get_option( 'wpmembers_autoex' ); + + // Is there already a 'more' link in the content? + $has_more_link = ( stristr( $content, 'class="more-link"' ) ) ? true : false; + + // If auto_ex is on. + if ( $arr['auto_ex'] == true ) { + + // Build an excerpt if one does not exist. + if ( ! $has_more_link ) { + + $words = explode( ' ', $content, ( $arr['auto_ex_len'] + 1 ) ); + if ( count( $words ) > $arr['auto_ex_len'] ) { + array_pop( $words ); + } + $content = implode( ' ', $words ); + + // Check for common html tags. + $common_tags = array( 'i', 'b', 'strong', 'em', 'h1', 'h2', 'h3', 'h4', 'h5' ); + foreach ( $common_tags as $tag ) { + if ( stristr( $content, '<' . $tag . '>' ) ) { + $after = stristr( $content, '' ); + $content = ( ! stristr( $after, '' ) ) ? $content . '' : $content; + } + } + } + } + + global $post, $more; + // If there is no 'more' link and auto_ex is on. + if ( ! $has_more_link && ( $arr['auto_ex'] == true ) ) { + // The default $more_link_text. + $more_link_text = __( '(more…)' ); + // The default $more_link. + $more_link = ' ' . $more_link_text . ''; + // Apply the_content_more_link filter if one exists (will match up all 'more' link text). + $more_link = apply_filters( 'the_content_more_link' , $more_link, $more_link_text ); + // Add the more link to the excerpt. + $content = $content . $more_link; + } + + /** + * Filter the auto excerpt. + * + * @since 2.8.1 + * + * @param string $content The excerpt. + */ + $content = apply_filters( 'wpmem_auto_excerpt', $content ); + + // Return the excerpt. + return $content; +} +endif; + + +if ( ! function_exists( 'wpmem_test_shortcode' ) ): +/** + * Tests $content for the presence of the [wp-members] shortcode. + * + * @since 2.6 + * + * @global string $post + * @uses get_shortcode_regex + * @return bool + * + * @example http://codex.wordpress.org/Function_Reference/get_shortcode_regex + */ +function wpmem_test_shortcode( $content, $tag ) { + + global $shortcode_tags; + if ( array_key_exists( $tag, $shortcode_tags ) ) { + preg_match_all( '/' . get_shortcode_regex() . '/s', $content, $matches, PREG_SET_ORDER ); + if ( empty( $matches ) ) { + return false; + } + + foreach ( $matches as $shortcode ) { + if ( $tag === $shortcode[2] ) { + return true; + } + } + } + return false; +} +endif; + + +/** + * Sets an array of user meta fields to be excluded from update/insert. + * + * @since 2.9.3 + * + * @param string $tag A tag so we know where the function is being used. + */ +function wpmem_get_excluded_meta( $tag ) { + + /** + * Filter the fields to be excluded when user is created/updated. + * + * @since 2.9.3 + * + * @param array An array of the field meta names to exclude. + * @param string $tag A tag so we know where the function is being used. + */ + return apply_filters( 'wpmem_exclude_fields', array( 'password', 'confirm_password', 'confirm_email', 'password_confirm', 'email_confirm' ), $tag ); +} + + +/** + * Returns http:// or https:// depending on ssl. + * + * @ since 2.9.8 + */ +function wpmem_use_ssl() { + return ( is_ssl() ) ? 'https://' : 'http://'; +} + /** End of File **/ \ No newline at end of file diff --git a/wp-registration.php b/inc/wp-registration.php similarity index 100% rename from wp-registration.php rename to inc/wp-registration.php diff --git a/wp-members.php b/wp-members.php index 2de8400b..5892a6fb 100644 --- a/wp-members.php +++ b/wp-members.php @@ -98,7 +98,7 @@ function wpmem_init() { load_plugin_textdomain( 'wp-members', false, dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); // Load WP_Members class. - include_once( 'class-wp-members.php' ); + include_once( 'inc/class-wp-members.php' ); $wpmem = new WP_Members(); /** @@ -127,7 +127,7 @@ function wpmem_init() { define( 'WPMEM_EXP_MODULE', $exp_module ); // Load core file. - include_once( 'wp-members-core.php' ); + include_once( 'inc/core.php' ); // Add actions. add_action( 'init', array( $wpmem, 'get_action' ) ); @@ -198,7 +198,7 @@ function wpmem_chk_admin() { require_once( 'admin/users.php' ); include_once( 'admin/user-profile.php' ); } else { - require_once( WPMEM_PATH . 'users.php' ); + require_once( WPMEM_PATH . 'inc/users.php' ); add_action( 'show_user_profile', 'wpmem_user_profile' ); add_action( 'edit_user_profile', 'wpmem_user_profile' ); add_action( 'profile_update', 'wpmem_profile_update' ); @@ -209,7 +209,7 @@ function wpmem_chk_admin() { * meta boxes and custom post/page columns. */ if ( current_user_can( 'edit_posts' ) ) { - include_once( 'admin/post.php' ); + include_once( WPMEM_PATH . 'admin/post.php' ); add_action( 'add_meta_boxes', 'wpmem_block_meta_add' ); add_action( 'save_post', 'wpmem_block_meta_save' ); add_filter( 'manage_posts_columns', 'wpmem_post_columns' ); @@ -246,7 +246,7 @@ function wpmem_admin_options() { * @since 2.5.2 */ function wpmem_install() { - require_once( 'wp-members-install.php' ); + require_once( WPMEM_PATH . 'wp-members-install.php' ); if ( is_multisite() ) { // if it is multisite, install options for each blog global $wpdb; @@ -285,7 +285,7 @@ function wpmem_install() { * @param $meta */ function wpmem_mu_new_site( $blog_id, $user_id, $domain, $path, $site_id, $meta ) { - require_once( 'wp-members-install.php' ); + require_once( WPMEM_PATH . 'wp-members-install.php' ); switch_to_blog( $blog_id ); wpmem_do_install(); restore_current_blog(); From 58ef0b7d8268759e6579cbc8e69e8a8f319ad983 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 6 May 2015 13:19:49 -0500 Subject: [PATCH 0067/1694] new shortcodes include file, new form shortcode --- inc/class-wp-members.php | 22 +++ inc/core.php | 267 ------------------------- inc/shortcodes.php | 409 +++++++++++++++++++++++++++++++++++++++ wp-members.php | 8 +- 4 files changed, 433 insertions(+), 273 deletions(-) create mode 100644 inc/shortcodes.php diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index d9e4a01b..f56af8a8 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -276,4 +276,26 @@ function do_securify( $content = null ) { } + /** + * Plugin initialization function to load shortcodes. + * + * @since 3.0.0 + */ + function load_shortcodes() { + + require_once( WPMEM_PATH . 'inc/shortcodes.php' ); + add_shortcode( 'wp-members', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_field', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logged_in', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logged_out', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logout', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_form', 'wpmem_form_sc' ); + + /** + * Fires after shortcodes load (for adding additional custom shortcodes). + * + * @since 3.0.0 + */ + do_action( 'wpmem_load_shortcodes' ); + } } \ No newline at end of file diff --git a/inc/core.php b/inc/core.php index 17f3dfc1..c076dc47 100644 --- a/inc/core.php +++ b/inc/core.php @@ -58,145 +58,6 @@ function wpmem_securify( $content = null ) { endif; -if ( ! function_exists( 'wpmem_do_sc_pages' ) ): -/** - * Builds the shortcode pages (login, register, user-profile, user-edit, password). - * - * Some of the logic here is similar to the wpmem_securify() function. - * But where that function handles general content, this function - * handles building specific pages generated by shortcodes. - * - * @since 2.6 - * - * @param string $page - * @param string $redirect_to - * @global object $wpmem - * @global string $wpmem_themsg - * @global object $post - * @return string $content - */ -function wpmem_do_sc_pages( $page, $redirect_to = null ) { - - global $wpmem, $wpmem_themsg, $post; - include_once( WPMEM_PATH . 'inc/dialogs.php' ); - - $content = ''; - - // Deprecating members-area parameter to be replaced by user-profile. - $page = ( $page == 'user-profile' ) ? 'members-area' : $page; - - if ( $page == 'members-area' || $page == 'register' ) { - - if ( $wpmem->regchk == "captcha" ) { - global $wpmem_captcha_err; - $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; - } - - if ( $wpmem->regchk == "loginfailed" ) { - return wpmem_inc_loginfailed(); - } - - if ( ! is_user_logged_in() ) { - if ( $wpmem->action == 'register' ) { - - switch( $wpmem->regchk ) { - - case "success": - $content = wpmem_inc_regmessage( $wpmem->regchk,$wpmem_themsg ); - $content = $content . wpmem_inc_login(); - break; - - default: - $content = wpmem_inc_regmessage( $wpmem->regchk,$wpmem_themsg ); - $content = $content . wpmem_inc_registration(); - break; - } - - } elseif ( $wpmem->action == 'pwdreset' ) { - - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); - - } else { - - $content = ( $page == 'members-area' ) ? $content . wpmem_inc_login( 'members' ) : $content; - $content = ( $page == 'register' || $wpmem->show_reg[ $post->post_type ] != 1 ) ? $content . wpmem_inc_registration() : $content; - } - - } elseif ( is_user_logged_in() && $page == 'members-area' ) { - - /** - * Filter the default heading in User Profile edit mode. - * - * @since 2.7.5 - * - * @param string The default edit mode heading. - */ - $heading = apply_filters( 'wpmem_user_edit_heading', __( 'Edit Your Information', 'wp-members' ) ); - - switch( $wpmem->action ) { - - case "edit": - $content = $content . wpmem_inc_registration( 'edit', $heading ); - break; - - case "update": - - // Determine if there are any errors/empty fields. - - if ( $wpmem->regchk == "updaterr" || $wpmem->regchk == "email" ) { - - $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); - $content = $content . wpmem_inc_registration( 'edit', $heading ); - - } else { - - //Case "editsuccess". - $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); - $content = $content . wpmem_inc_memberlinks(); - - } - break; - - case "pwdchange": - - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); - break; - - case "renew": - $content = wpmem_renew(); - break; - - default: - $content = wpmem_inc_memberlinks(); - break; - } - - } elseif ( is_user_logged_in() && $page == 'register' ) { - - $content = $content . wpmem_inc_memberlinks( 'register' ); - - } - - } - - if ( $page == 'login' ) { - $content = ( $wpmem->regchk == "loginfailed" ) ? wpmem_inc_loginfailed() : $content; - $content = ( ! is_user_logged_in() ) ? $content . wpmem_inc_login( 'login', $redirect_to ) : wpmem_inc_memberlinks( 'login' ); - } - - if ( $page == 'password' ) { - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); - } - - if ( $page == 'user-edit' ) { - $content = wpmem_page_user_edit( $wpmem->regchk, $content ); - } - - return $content; -} // End wpmem_do_sc_pages. -endif; - - if ( ! function_exists( 'wpmem_block' ) ): /** * Determines if content should be blocked. @@ -214,134 +75,6 @@ function wpmem_block() { endif; -if ( ! function_exists( 'wpmem_shortcode' ) ): -/** - * Executes various shortcodes. - * - * This function executes shortcodes for pages (settings, register, login, user-list, - * and tos pages), as well as login status and field attributes when the wp-members tag - * is used. Also executes shortcodes for login status with the wpmem_logged_in tags - * and fields when the wpmem_field tags are used. - * - * @since 2.4 - * - * @param array $attr page|url|status|msg|field|id - * @param string $content - * @param string $tag - * @return string Returns the result of wpmem_do_sc_pages|wpmem_list_users|wpmem_sc_expmessage|$content. - */ -function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { - - global $wpmem; - - // Set all default attributes to false. - $defaults = array( - 'page' => false, - 'redirect_to' => null, - 'url' => false, - 'status' => false, - 'msg' => false, - 'field' => false, - 'id' => false, - 'underscores' => 'off', - ); - - // Merge defaults with $attr. - $atts = shortcode_atts( $defaults, $attr, $tag ); - - // Handles the 'page' attribute. - if ( $atts['page'] ) { - if ( $atts['page'] == 'user-list' ) { - if ( function_exists( 'wpmem_list_users' ) ) { - $content = do_shortcode( wpmem_list_users( $attr, $content ) ); - } - } elseif ( $atts['page'] == 'tos' ) { - return $atts['url']; - } else { - $content = do_shortcode( wpmem_do_sc_pages( $atts['page'], $atts['redirect_to'] ) ); - } - - // Resolve any texturize issues. - if ( strstr( $content, '[wpmem_txt]' ) ) { - // Fixes the wptexturize. - remove_filter( 'the_content', 'wpautop' ); - remove_filter( 'the_content', 'wptexturize' ); - add_filter( 'the_content', 'wpmem_texturize', 99 ); - } - return $content; - } - - // Handles the 'status' attribute. - if ( ( $atts['status'] ) || $tag == 'wpmem_logged_in' ) { - - $do_return = false; - - // If using the wpmem_logged_in tag with no attributes & the user is logged in. - if ( $tag == 'wpmem_logged_in' && ( ! $attr ) && is_user_logged_in() ) - $do_return = true; - - // If there is a status attribute of "in" and the user is logged in. - if ( $atts['status'] == 'in' && is_user_logged_in() ) - $do_return = true; - - // If there is a status attribute of "out" and the user is not logged in. - if ( $atts['status'] == 'out' && ! is_user_logged_in() ) - $do_return = true; - - // If there is a status attribute of "sub" and the user is logged in. - if ( $atts['status'] == 'sub' && is_user_logged_in() ) { - if ( $wpmem->use_exp == 1 ) { - if ( ! wpmem_chk_exp() ) { - $do_return = true; - } elseif ( $atts['msg'] == true ) { - $do_return = true; - $content = wpmem_sc_expmessage(); - } - } - } - - // Return content (or empty content) depending on the result of the above logic. - return ( $do_return ) ? do_shortcode( $content ) : ''; - } - - // Handles the wpmem_logged_out tag with no attributes & the user is not logged in. - if ( $tag == 'wpmem_logged_out' && ( ! $attr ) && ! is_user_logged_in() ) { - return do_shortcode( $content ); - } - - // Handles the 'field' attribute. - if ( $atts['field'] || $tag == 'wpmem_field' ) { - if ( $atts['id'] ) { - // We are getting some other user. - if ( $atts['id'] == 'get' ) { - $the_user_ID = ( isset( $_GET['uid'] ) ) ? $_GET['uid'] : ''; - } else { - $the_user_ID = $atts['id']; - } - } else { - // Get the current user. - $the_user_ID = get_current_user_id(); - } - $user_info = get_userdata( $the_user_ID ); - - if ( $atts['underscores'] == 'off' && $user_info ) { - $user_info->$atts['field'] = str_replace( '_', ' ', $user_info->$atts['field'] ); - } - - return ( $user_info ) ? htmlspecialchars( $user_info->$atts['field'] ) . do_shortcode( $content ) : do_shortcode( $content ); - } - - // Logout link shortcode. - if ( is_user_logged_in() && $tag == 'wpmem_logout' ) { - $link = ( $atts['url'] ) ? wpmem_chk_qstr( $atts['url'] ) . 'a=logout' : wpmem_chk_qstr( get_permalink() ) . 'a=logout'; - $text = ( $content ) ? $content : __( 'Click here to log out.', 'wp-members' ); - return do_shortcode( "$text" ); - } - -} -endif; - - if ( ! function_exists( 'wpmem_check_activated' ) ): /** * Checks if a user is activated. diff --git a/inc/shortcodes.php b/inc/shortcodes.php new file mode 100644 index 00000000..cbf8d1b6 --- /dev/null +++ b/inc/shortcodes.php @@ -0,0 +1,409 @@ +regchk == 'loginfailed' ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to ); + } + break; + + case in_array( 'register', $atts ): + if ( is_user_logged_in() ) { + /* + * If the user is logged in, return any nested content (if any) + * or the default bullet links if no nested content. + */ + $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'register' ); + } else { + // @todo Can this be moved into another function? Should $wpmem get an error message handler? + if ( $wpmem->regchk == 'captcha' ) { + global $wpmem_captcha_err; + $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; + } + $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ) : ''; + $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login() : wpmem_inc_registration(); + } + break; + } + + /* + * @todo - This is temporary for texturizing. Need to work it into an argument in the function call as + * to whether the [wpmem_txt] shortcode is even included. For now, this will allow this function to be + * tested as an include during the 3.0 alpha/beta testing period and a permanent solution can be worked + * out for 3.x.x. + */ + if ( array_key_exists( 'texturize', $atts ) && $atts['texturize'] == 'false' ) { + $content = str_replace( array( '[wpmem_txt]', '[/wpmem_txt]' ), array( '', '' ), $content ); + } + if ( strstr( $content, '[wpmem_txt]' ) ) { + // Fixes the wptexturize. + remove_filter( 'the_content', 'wpautop' ); + remove_filter( 'the_content', 'wptexturize' ); + add_filter( 'the_content', 'wpmem_texturize', 99 ); + } + /** End temporary texturize functions */ + + return do_shortcode( $content ); +} + + +/** + * Displays login form when called by shortcode. + * + * @since 3.0 + * + * @param $atts + * @param $content + * @param $tag + * @return $content + +function wpmem_sc_login_form( $atts, $content, $tag ) { + + // Dependencies. + global $wpmem; + include_once( WPMEM_PATH . 'inc/core.php' ); + include_once( WPMEM_PATH . 'inc/dialogs.php' ); + // Defaults. + $redirect_to = ( isset( $atts['redirect_to'] ) ) ? $atts['redirect_to'] : null; + $texturize = ( isset( $atts['texturize'] ) ) ? $atts['texturize'] : false; + + if ( is_user_logged_in() ) { + return ( $content ) ? $content : wpmem_inc_memberlinks( 'login' ); + } else { + return ( $wpmem->regchk == 'loginfailed' ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to, $texturize ); + } +} */ + + +if ( ! function_exists( 'wpmem_shortcode' ) ): +/** + * Executes various shortcodes. + * + * This function executes shortcodes for pages (settings, register, login, user-list, + * and tos pages), as well as login status and field attributes when the wp-members tag + * is used. Also executes shortcodes for login status with the wpmem_logged_in tags + * and fields when the wpmem_field tags are used. + * + * @since 2.4 + * + * @param array $attr page|url|status|msg|field|id + * @param string $content + * @param string $tag + * @return string Returns the result of wpmem_do_sc_pages|wpmem_list_users|wpmem_sc_expmessage|$content. + */ +function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { + + global $wpmem; + + // Set all default attributes to false. + $defaults = array( + 'page' => false, + 'redirect_to' => null, + 'url' => false, + 'status' => false, + 'msg' => false, + 'field' => false, + 'id' => false, + 'underscores' => 'off', + ); + + // Merge defaults with $attr. + $atts = shortcode_atts( $defaults, $attr, $tag ); + + // Handles the 'page' attribute. + if ( $atts['page'] ) { + if ( $atts['page'] == 'user-list' ) { + if ( function_exists( 'wpmem_list_users' ) ) { + $content = do_shortcode( wpmem_list_users( $attr, $content ) ); + } + } elseif ( $atts['page'] == 'tos' ) { + return $atts['url']; + } else { + $content = do_shortcode( wpmem_do_sc_pages( $atts['page'], $atts['redirect_to'] ) ); + } + + // Resolve any texturize issues. + if ( strstr( $content, '[wpmem_txt]' ) ) { + // Fixes the wptexturize. + remove_filter( 'the_content', 'wpautop' ); + remove_filter( 'the_content', 'wptexturize' ); + add_filter( 'the_content', 'wpmem_texturize', 99 ); + } + return $content; + } + + // Handles the 'status' attribute. + if ( ( $atts['status'] ) || $tag == 'wpmem_logged_in' ) { + + $do_return = false; + + // If using the wpmem_logged_in tag with no attributes & the user is logged in. + if ( $tag == 'wpmem_logged_in' && ( ! $attr ) && is_user_logged_in() ) + $do_return = true; + + // If there is a status attribute of "in" and the user is logged in. + if ( $atts['status'] == 'in' && is_user_logged_in() ) + $do_return = true; + + // If there is a status attribute of "out" and the user is not logged in. + if ( $atts['status'] == 'out' && ! is_user_logged_in() ) + $do_return = true; + + // If there is a status attribute of "sub" and the user is logged in. + if ( $atts['status'] == 'sub' && is_user_logged_in() ) { + if ( $wpmem->use_exp == 1 ) { + if ( ! wpmem_chk_exp() ) { + $do_return = true; + } elseif ( $atts['msg'] == true ) { + $do_return = true; + $content = wpmem_sc_expmessage(); + } + } + } + + // Return content (or empty content) depending on the result of the above logic. + return ( $do_return ) ? do_shortcode( $content ) : ''; + } + + // Handles the wpmem_logged_out tag with no attributes & the user is not logged in. + if ( $tag == 'wpmem_logged_out' && ( ! $attr ) && ! is_user_logged_in() ) { + return do_shortcode( $content ); + } + + // Handles the 'field' attribute. + if ( $atts['field'] || $tag == 'wpmem_field' ) { + if ( $atts['id'] ) { + // We are getting some other user. + if ( $atts['id'] == 'get' ) { + $the_user_ID = ( isset( $_GET['uid'] ) ) ? $_GET['uid'] : ''; + } else { + $the_user_ID = $atts['id']; + } + } else { + // Get the current user. + $the_user_ID = get_current_user_id(); + } + $user_info = get_userdata( $the_user_ID ); + + if ( $atts['underscores'] == 'off' && $user_info ) { + $user_info->$atts['field'] = str_replace( '_', ' ', $user_info->$atts['field'] ); + } + + return ( $user_info ) ? htmlspecialchars( $user_info->$atts['field'] ) . do_shortcode( $content ) : do_shortcode( $content ); + } + + // Logout link shortcode. + if ( is_user_logged_in() && $tag == 'wpmem_logout' ) { + $link = ( $atts['url'] ) ? wpmem_chk_qstr( $atts['url'] ) . 'a=logout' : wpmem_chk_qstr( get_permalink() ) . 'a=logout'; + $text = ( $content ) ? $content : __( 'Click here to log out.', 'wp-members' ); + return do_shortcode( "$text" ); + } + +} +endif; + + +if ( ! function_exists( 'wpmem_do_sc_pages' ) ): +/** + * Builds the shortcode pages (login, register, user-profile, user-edit, password). + * + * Some of the logic here is similar to the wpmem_securify() function. + * But where that function handles general content, this function + * handles building specific pages generated by shortcodes. + * + * @since 2.6 + * + * @param string $page + * @param string $redirect_to + * @global object $wpmem + * @global string $wpmem_themsg + * @global object $post + * @return string $content + */ +function wpmem_do_sc_pages( $page, $redirect_to = null ) { + + global $wpmem, $wpmem_themsg, $post; + include_once( WPMEM_PATH . 'inc/dialogs.php' ); + + $content = ''; + + // Deprecating members-area parameter to be replaced by user-profile. + $page = ( $page == 'user-profile' ) ? 'members-area' : $page; + + if ( $page == 'members-area' || $page == 'register' ) { + + if ( $wpmem->regchk == "captcha" ) { + global $wpmem_captcha_err; + $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; + } + + if ( $wpmem->regchk == "loginfailed" ) { + return wpmem_inc_loginfailed(); + } + + if ( ! is_user_logged_in() ) { + if ( $wpmem->action == 'register' ) { + + switch( $wpmem->regchk ) { + + case "success": + $content = wpmem_inc_regmessage( $wpmem->regchk,$wpmem_themsg ); + $content = $content . wpmem_inc_login(); + break; + + default: + $content = wpmem_inc_regmessage( $wpmem->regchk,$wpmem_themsg ); + $content = $content . wpmem_inc_registration(); + break; + } + + } elseif ( $wpmem->action == 'pwdreset' ) { + + $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + + } else { + + $content = ( $page == 'members-area' ) ? $content . wpmem_inc_login( 'members' ) : $content; + $content = ( $page == 'register' || $wpmem->show_reg[ $post->post_type ] != 1 ) ? $content . wpmem_inc_registration() : $content; + } + + } elseif ( is_user_logged_in() && $page == 'members-area' ) { + + /** + * Filter the default heading in User Profile edit mode. + * + * @since 2.7.5 + * + * @param string The default edit mode heading. + */ + $heading = apply_filters( 'wpmem_user_edit_heading', __( 'Edit Your Information', 'wp-members' ) ); + + switch( $wpmem->action ) { + + case "edit": + $content = $content . wpmem_inc_registration( 'edit', $heading ); + break; + + case "update": + + // Determine if there are any errors/empty fields. + + if ( $wpmem->regchk == "updaterr" || $wpmem->regchk == "email" ) { + + $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_inc_registration( 'edit', $heading ); + + } else { + + //Case "editsuccess". + $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_inc_memberlinks(); + + } + break; + + case "pwdchange": + + $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + break; + + case "renew": + $content = wpmem_renew(); + break; + + default: + $content = wpmem_inc_memberlinks(); + break; + } + + } elseif ( is_user_logged_in() && $page == 'register' ) { + + $content = $content . wpmem_inc_memberlinks( 'register' ); + + } + + } + + if ( $page == 'login' ) { + $content = ( $wpmem->regchk == "loginfailed" ) ? wpmem_inc_loginfailed() : $content; + $content = ( ! is_user_logged_in() ) ? $content . wpmem_inc_login( 'login', $redirect_to ) : wpmem_inc_memberlinks( 'login' ); + } + + if ( $page == 'password' ) { + $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + } + + if ( $page == 'user-edit' ) { + $content = wpmem_page_user_edit( $wpmem->regchk, $content ); + } + + return $content; +} // End wpmem_do_sc_pages. +endif; + + /** End of File **/ \ No newline at end of file diff --git a/wp-members.php b/wp-members.php index 5892a6fb..5b7c272e 100644 --- a/wp-members.php +++ b/wp-members.php @@ -144,12 +144,8 @@ function wpmem_init() { add_filter( 'registration_errors', 'wpmem_wp_reg_validate', 10, 3 ); // native registration validation add_filter( 'comments_open', 'wpmem_securify_comments', 20, 1 ); // securifies the comments - // Add shortcodes. - add_shortcode( 'wp-members', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_field', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logged_in', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logged_out', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logout', 'wpmem_shortcode' ); + // Load shortcodes. + $wpmem->load_shortcodes(); // Load the stylesheet if using the new forms. add_action( 'wp_print_styles', 'wpmem_enqueue_style' ); From d5cc6275d5402d802a0ec1c621977cb0ad4354e5 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 8 May 2015 13:39:27 -0500 Subject: [PATCH 0068/1694] code standards --- inc/register.php | 169 ++++++++++++++++++++++++++++++----------------- 1 file changed, 109 insertions(+), 60 deletions(-) diff --git a/inc/register.php b/inc/register.php index 71edcce0..eff26868 100644 --- a/inc/register.php +++ b/inc/register.php @@ -20,7 +20,7 @@ */ -if( ! function_exists( 'wpmem_registration' ) ): +if ( ! function_exists( 'wpmem_registration' ) ): /** * Register function. * @@ -40,15 +40,15 @@ function wpmem_registration( $toggle ) { global $user_ID, $wpmem, $wpmem_themsg, $userdata; // Check the nonce. - if( defined( 'WPMEM_USE_NONCE' ) ) { - if( empty( $_POST ) || !wp_verify_nonce( $_POST['wpmem-form-submit'], 'wpmem-validate-submit' ) ) { + if ( defined( 'WPMEM_USE_NONCE' ) ) { + if ( empty( $_POST ) || ! wp_verify_nonce( $_POST['wpmem-form-submit'], 'wpmem-validate-submit' ) ) { $wpmem_themsg = __( 'There was an error processing the form.', 'wp-members' ); return; } } // Is this a registration or a user profile update? - if( $toggle == 'register' ) { + if ( $toggle == 'register' ) { $fields['username'] = ( isset( $_POST['log'] ) ) ? sanitize_user( $_POST['log'] ) : ''; } @@ -57,10 +57,10 @@ function wpmem_registration( $toggle ) { // Build the $fields array from $_POST data. $wpmem_fields = get_option( 'wpmembers_fields' ); - foreach( $wpmem_fields as $meta ) { - if( $meta[4] == 'y' ) { - if( $meta[2] != 'password' ) { - $fields[$meta[2]] = ( isset( $_POST[$meta[2]] ) ) ? sanitize_text_field( $_POST[$meta[2]] ) : ''; + foreach ( $wpmem_fields as $meta ) { + if ( $meta[4] == 'y' ) { + if ( $meta[2] != 'password' ) { + $fields[ $meta[2] ] = ( isset( $_POST[ $meta[2] ] ) ) ? sanitize_text_field( $_POST[ $meta[2] ] ) : ''; } else { // We do have password as part of the registration form. $fields['password'] = ( isset( $_POST['password'] ) ) ? $_POST['password'] : ''; @@ -80,51 +80,84 @@ function wpmem_registration( $toggle ) { // Check for required fields $wpmem_fields_rev = array_reverse( $wpmem_fields ); - foreach( $wpmem_fields_rev as $meta ) { + foreach ( $wpmem_fields_rev as $meta ) { $pass_arr = array( 'password', 'confirm_password', 'password_confirm' ); $pass_chk = ( $toggle == 'update' && in_array( $meta[2], $pass_arr ) ) ? true : false; - if( $meta[5] == 'y' && $pass_chk == false ) { - if( ! $fields[$meta[2]] ) { $wpmem_themsg = sprintf( __('Sorry, %s is a required field.', 'wp-members'), $meta[1] ); } + if ( $meta[5] == 'y' && $pass_chk == false ) { + if ( ! $fields[ $meta[2] ] ) { + $wpmem_themsg = sprintf( __('Sorry, %s is a required field.', 'wp-members'), $meta[1] ); + } } } - switch( $toggle ) { + switch ( $toggle ) { case "register": - if( is_multisite() ) { + if ( is_multisite() ) { // Multisite has different requirements. $result = wpmu_validate_user_signup($fields['username'], $fields['user_email']); $errors = $result['errors']; - if( $errors->errors ) { + if ( $errors->errors ) { $wpmem_themsg = $errors->get_error_message(); return $wpmem_themsg; exit; } } else { - if( ! $fields['username'] ) { $wpmem_themsg = __( 'Sorry, username is a required field', 'wp-members' ); return $wpmem_themsg; exit(); } - if( ! validate_username( $fields['username'] ) ) { $wpmem_themsg = __( 'The username cannot include non-alphanumeric characters.', 'wp-members' ); return $wpmem_themsg; exit(); } - if( ! is_email( $fields['user_email']) ) { $wpmem_themsg = __( 'You must enter a valid email address.', 'wp-members' ); return $wpmem_themsg; exit(); } - if( username_exists( $fields['username'] ) ) { return "user"; exit(); } - if( email_exists( $fields['user_email'] ) ) { return "email"; exit(); } + if ( ! $fields['username'] ) { + $wpmem_themsg = __( 'Sorry, username is a required field', 'wp-members' ); + return $wpmem_themsg; + exit(); + } + if ( ! validate_username( $fields['username'] ) ) { + $wpmem_themsg = __( 'The username cannot include non-alphanumeric characters.', 'wp-members' ); + return $wpmem_themsg; + exit(); + } + if ( ! is_email( $fields['user_email']) ) { + $wpmem_themsg = __( 'You must enter a valid email address.', 'wp-members' ); + return $wpmem_themsg; + exit(); + } + if ( username_exists( $fields['username'] ) ) { + return "user"; + exit(); + } + if ( email_exists( $fields['user_email'] ) ) { + return "email"; + exit(); + } + } + if ( $wpmem_themsg ) { + return "empty"; + exit(); } - if( $wpmem_themsg ) { return "empty"; exit(); } // If form contains password and email confirmation, validate that they match. - if( array_key_exists( 'confirm_password', $fields ) && $fields['confirm_password'] != $fields ['password'] ) { $wpmem_themsg = __( 'Passwords did not match.', 'wp-members' ); } - if( array_key_exists( 'confirm_email', $fields ) && $fields['confirm_email'] != $fields ['user_email'] ) { $wpmem_themsg = __( 'Emails did not match.', 'wp-members' ); } - - $wpmem_captcha = get_option( 'wpmembers_captcha' ); // Get the captcha settings (api keys). - if( $wpmem->captcha == 1 && $wpmem_captcha['recaptcha'] ) { // If captcha is on, check the captcha. - - if( $wpmem_captcha['recaptcha']['public'] && $wpmem_captcha['recaptcha']['private'] ) { // If there is no api key, the captcha never displayed to the end user. - if( !$_POST["recaptcha_response_field"] ) { // validate for empty captcha field + if ( array_key_exists( 'confirm_password', $fields ) && $fields['confirm_password'] != $fields ['password'] ) { + $wpmem_themsg = __( 'Passwords did not match.', 'wp-members' ); + } + if ( array_key_exists( 'confirm_email', $fields ) && $fields['confirm_email'] != $fields ['user_email'] ) { + $wpmem_themsg = __( 'Emails did not match.', 'wp-members' ); + } + + // Get the captcha settings (api keys). + $wpmem_captcha = get_option( 'wpmembers_captcha' ); + + // If captcha is on, check the captcha. + if ( $wpmem->captcha == 1 && $wpmem_captcha['recaptcha'] ) { + + // If there is no api key, the captcha never displayed to the end user. + if ( $wpmem_captcha['recaptcha']['public'] && $wpmem_captcha['recaptcha']['private'] ) { + if ( ! $_POST["recaptcha_response_field"] ) { // validate for empty captcha field $wpmem_themsg = __( 'You must complete the CAPTCHA form.', 'wp-members' ); return "empty"; exit(); } } // Check to see if the recaptcha library has already been loaded by another plugin. - if( ! function_exists( '_recaptcha_qsencode' ) ) { require_once('lib/recaptchalib.php'); } + if ( ! function_exists( '_recaptcha_qsencode' ) ) { + require_once('lib/recaptchalib.php'); + } $publickey = $wpmem_captcha['recaptcha']['public']; $privatekey = $wpmem_captcha['recaptcha']['private']; @@ -134,7 +167,7 @@ function wpmem_registration( $toggle ) { // The error code from reCAPTCHA, if any. $error = null; - if( $_POST["recaptcha_response_field"] ) { + if ( $_POST["recaptcha_response_field"] ) { $resp = recaptcha_check_answer ( $privatekey, @@ -143,7 +176,7 @@ function wpmem_registration( $toggle ) { $_POST["recaptcha_response_field"] ); - if( ! $resp->is_valid ) { + if ( ! $resp->is_valid ) { // Set the error code so that we can display it. global $wpmem_captcha_err; @@ -155,8 +188,8 @@ function wpmem_registration( $toggle ) { } } // End check recaptcha. - } elseif( $wpmem->captcha == 2 ) { - if( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { + } elseif ( $wpmem->captcha == 2 ) { + if ( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { // Validate Really Simple Captcha. $wpmem_captcha = new ReallySimpleCaptcha(); // This variable holds the CAPTCHA image prefix, which corresponds to the correct answer. @@ -188,7 +221,7 @@ function wpmem_registration( $toggle ) { /* * These native fields are not installed by default, but if they * are added, use the $_POST value - otherwise, default to username. - * value can be filtered with wpmem_register_data + * Value can be filtered with wpmem_register_data. */ $fields['user_nicename'] = ( isset( $_POST['user_nicename'] ) ) ? sanitize_title( $_POST['user_nicename'] ) : $fields['username']; $fields['display_name'] = ( isset( $_POST['display_name'] ) ) ? sanitize_user ( $_POST['display_name'] ) : $fields['username']; @@ -219,7 +252,9 @@ function wpmem_registration( $toggle ) { do_action( 'wpmem_pre_register_data', $fields ); // If the _pre_register_data hook sends back an error message. - if( $wpmem_themsg ){ return $wpmem_themsg; } + if ( $wpmem_themsg ) { + return $wpmem_themsg; + } // Main new user fields are ready. $new_user_fields = array ( @@ -238,10 +273,10 @@ function wpmem_registration( $toggle ) { // User_url, first_name, last_name, description, jabber, aim, yim. $new_user_fields_meta = array( 'user_url', 'first_name', 'last_name', 'description', 'jabber', 'aim', 'yim' ); - foreach( $wpmem_fields as $meta ) { - if( in_array( $meta[2], $new_user_fields_meta ) ) { - if( $meta[4] == 'y' && ! in_array( $meta[2], $excluded_meta ) ) { - $new_user_fields[$meta[2]] = $fields[$meta[2]]; + foreach ( $wpmem_fields as $meta ) { + if ( in_array( $meta[2], $new_user_fields_meta ) ) { + if ( $meta[4] == 'y' && ! in_array( $meta[2], $excluded_meta ) ) { + $new_user_fields[ $meta[2] ] = $fields[ $meta[2] ]; } } } @@ -250,11 +285,11 @@ function wpmem_registration( $toggle ) { $fields['ID'] = wp_insert_user( $new_user_fields ); // Set remaining fields to wp_usermeta table. - foreach( $wpmem_fields as $meta ) { + foreach ( $wpmem_fields as $meta ) { // If the field is not excluded, update accordingly. - if( ! in_array( $meta[2], $excluded_meta ) && ! in_array( $meta[2], $new_user_fields_meta ) ) { - if( $meta[4] == 'y' && $meta[2] != 'user_email' ) { - update_user_meta( $fields['ID'], $meta[2], $fields[$meta[2]] ); + if ( ! in_array( $meta[2], $excluded_meta ) && ! in_array( $meta[2], $new_user_fields_meta ) ) { + if ( $meta[4] == 'y' && $meta[2] != 'user_email' ) { + update_user_meta( $fields['ID'], $meta[2], $fields[ $meta[2] ] ); } } } @@ -266,7 +301,7 @@ function wpmem_registration( $toggle ) { update_user_meta( $fields['ID'], 'wpmem_reg_url', $fields['wpmem_reg_url'] ); // Set user expiration, if used. - if( $wpmem->use_exp == 1 && $wpmem->mod_reg != 1 ) { wpmem_set_exp( $fields['ID'] ); } + if ( $wpmem->use_exp == 1 && $wpmem->mod_reg != 1 ) { wpmem_set_exp( $fields['ID'] ); } /** * Fires after user insertion but before email. @@ -286,7 +321,9 @@ function wpmem_registration( $toggle ) { wpmem_inc_regemail( $fields['ID'], $fields['password'], $wpmem->mod_reg, $wpmem_fields, $fields ); // Notify admin of new reg, if needed. - if( $wpmem->notify == 1 ) { wpmem_notify_admin( $fields['ID'], $wpmem_fields ); } + if ( $wpmem->notify == 1 ) { + wpmem_notify_admin( $fields['ID'], $wpmem_fields ); + } /** * Fires after registration is complete. @@ -301,20 +338,32 @@ function wpmem_registration( $toggle ) { case "update": - if( $wpmem_themsg ) { return "updaterr"; exit(); } + if ( $wpmem_themsg ) { + return "updaterr"; + exit(); + } /* * Doing a check for existing email is not the same as a new reg. check first to * see if it's different, then check if it is a valid address and it exists. */ global $current_user; get_currentuserinfo(); - if( $fields['user_email'] != $current_user->user_email ) { - if( email_exists( $fields['user_email'] ) ) { return "email"; exit(); } - if( !is_email( $fields['user_email']) ) { $wpmem_themsg = __( 'You must enter a valid email address.', 'wp-members' ); return "updaterr"; exit(); } + if ( $fields['user_email'] != $current_user->user_email ) { + if ( email_exists( $fields['user_email'] ) ) { + return "email"; + exit(); + } + if ( !is_email( $fields['user_email']) ) { + $wpmem_themsg = __( 'You must enter a valid email address.', 'wp-members' ); + return "updaterr"; + exit(); + } } // If form includes email confirmation, validate that they match. - if( array_key_exists( 'confirm_email', $fields ) && $fields['confirm_email'] != $fields ['user_email'] ) { $wpmem_themsg = __( 'Emails did not match.', 'wp-members' ); } + if ( array_key_exists( 'confirm_email', $fields ) && $fields['confirm_email'] != $fields ['user_email'] ) { + $wpmem_themsg = __( 'Emails did not match.', 'wp-members' ); + } // Add the user_ID to the fields array. $fields['ID'] = $user_ID; @@ -347,7 +396,7 @@ function wpmem_registration( $toggle ) { * If the _pre_update_data hook sends back an error message. * @todo - double check this. it should probably return "updaterr" and the hook should globalize wpmem_themsg */ - if( $wpmem_themsg ){ return $wpmem_themsg; } + if ( $wpmem_themsg ){ return $wpmem_themsg; } // A list of fields that can be updated by wp_update_user. $native_fields = array( @@ -366,15 +415,15 @@ function wpmem_registration( $toggle ) { ); $native_update = array( 'ID' => $user_ID ); - foreach( $wpmem_fields as $meta ) { + foreach ( $wpmem_fields as $meta ) { // If the field is not excluded, update accordingly. - if( ! in_array( $meta[2], wpmem_get_excluded_meta( 'update' ) ) ) { - switch( $meta[2] ) { + if ( ! in_array( $meta[2], wpmem_get_excluded_meta( 'update' ) ) ) { + switch ( $meta[2] ) { // If the field can be updated by wp_update_user. case( in_array( $meta[2], $native_fields ) ): - $fields[$meta[2]] = ( isset( $fields[$meta[2]] ) ) ? $fields[$meta[2]] : ''; - $native_update[$meta[2]] = $fields[$meta[2]]; + $fields[ $meta[2] ] = ( isset( $fields[ $meta[2] ] ) ) ? $fields[ $meta[2] ] : ''; + $native_update[ $meta[2] ] = $fields[ $meta[2] ]; break; // If the field is password. @@ -384,8 +433,8 @@ function wpmem_registration( $toggle ) { // Everything else goes into wp_usermeta. default: - if( $meta[4] == 'y' ) { - update_user_meta( $user_ID, $meta[2], $fields[$meta[2]] ); + if ( $meta[4] == 'y' ) { + update_user_meta( $user_ID, $meta[2], $fields[ $meta[2] ] ); } break; } @@ -411,7 +460,7 @@ function wpmem_registration( $toggle ) { endif; -if( ! function_exists( 'wpmem_get_captcha_err' ) ): +if ( ! function_exists( 'wpmem_get_captcha_err' ) ): /** * Generate reCAPTCHA error messages. * @@ -422,7 +471,7 @@ function wpmem_registration( $toggle ) { */ function wpmem_get_captcha_err( $wpmem_captcha_err ) { - switch( $wpmem_captcha_err ) { + switch ( $wpmem_captcha_err ) { case "invalid-site-public-key": $wpmem_captcha_err = __( 'We were unable to validate the public key.', 'wp-members' ); From cd65c3497fcd84f9e8e8bca197c773f015d9a9c9 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 8 May 2015 13:40:08 -0500 Subject: [PATCH 0069/1694] added form shortcodes for password and user edit --- inc/shortcodes.php | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/inc/shortcodes.php b/inc/shortcodes.php index cbf8d1b6..0ce548eb 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -71,7 +71,7 @@ function wpmem_form_sc( $atts, $content = null, $tag = 'wpmem_form' ) { $content = ( $wpmem->regchk == 'loginfailed' ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to ); } break; - + case in_array( 'register', $atts ): if ( is_user_logged_in() ) { /* @@ -89,6 +89,15 @@ function wpmem_form_sc( $atts, $content = null, $tag = 'wpmem_form' ) { $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login() : wpmem_inc_registration(); } break; + + case in_array( 'password', $atts ): + $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + break; + + case in_array( 'user-edit', $atts ): + $content = wpmem_page_user_edit( $wpmem->regchk, $content ); + break; + } /* @@ -106,6 +115,7 @@ function wpmem_form_sc( $atts, $content = null, $tag = 'wpmem_form' ) { remove_filter( 'the_content', 'wptexturize' ); add_filter( 'the_content', 'wpmem_texturize', 99 ); } + // @todo - Look into shortcode_unautop(). /** End temporary texturize functions */ return do_shortcode( $content ); From af660f1330b03ff770a251e56667cadbdf8310f0 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 8 May 2015 13:40:31 -0500 Subject: [PATCH 0070/1694] plugin init updates --- inc/class-wp-members.php | 109 +++++++++++++++++++++++++++++++-------- wp-members.php | 66 ++++++++++++------------ 2 files changed, 121 insertions(+), 54 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index f56af8a8..0e38ca24 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -8,6 +8,17 @@ class WP_Members { function __construct() { + $this->load_settings(); + + } + + /** + * Plugin initialization function. + * + * @since 3.0.0 + */ + function load_settings() { + /** * Filter the options before they are loaded into constants. * @@ -25,6 +36,82 @@ function __construct() { // Set the stylesheet. $this->cssurl = ( $this->style == 'use_custom' ) ? $this->cssurl : $this->style; } + + /** + * Plugin initialization function to load shortcodes. + * + * @since 3.0.0 + */ + function load_shortcodes() { + + require_once( WPMEM_PATH . 'inc/shortcodes.php' ); + add_shortcode( 'wp-members', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_field', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logged_in', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logged_out', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logout', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_form', 'wpmem_form_sc' ); + + /** + * Fires after shortcodes load (for adding additional custom shortcodes). + * + * @since 3.0.0 + */ + do_action( 'wpmem_load_shortcodes' ); + } + + /** + * Plugin initialization function to load hooks. + * + * @since 3.0.0 + */ + function load_hooks() { + + // Add actions. + add_action( 'init', array( $this, 'get_action' ) ); + add_action( 'widgets_init', 'widget_wpmemwidget_init' ); // initializes the widget + add_action( 'admin_init', 'wpmem_chk_admin' ); // check user role to load correct dashboard + add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu + add_action( 'user_register', 'wpmem_wp_reg_finalize' ); // handles wp native registration + add_action( 'login_enqueue_scripts', 'wpmem_wplogin_stylesheet' ); // styles the native registration + add_action( 'wp_print_styles', 'wpmem_enqueue_style' ); // load the stylesheet if using the new forms + + // Add filters. + add_filter( 'the_content', array( $this, 'do_securify' ), 1, 1 ); + add_filter( 'allow_password_reset', 'wpmem_no_reset' ); // no password reset for non-activated users + add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration + add_filter( 'registration_errors', 'wpmem_wp_reg_validate', 10, 3 ); // native registration validation + add_filter( 'comments_open', 'wpmem_securify_comments', 20, 1 ); // securifies the comments + + // If registration is moderated, check for activation (blocks backend login by non-activated users). + if ( $this->mod_reg == 1 ) { + add_filter( 'authenticate', 'wpmem_check_activated', 99, 3 ); + } + } + + /** + * Load drop-ins. + * + * @since 3.0.0 + * + * @todo This is experimental. The function and its operation is subject to change. + */ + function load_dropins() { + + /** + * Filters the dropin file folder. + * + * @since 3.0.0 + * + * @param string $folder The dropin file folder. + */ + $folder = apply_filters( 'wpmem_dropin_folder', WP_PLUGIN_DIR . '/wp-members-dropins/' ); + + // Load any drop-ins. + foreach ( glob( $folder . '*.php' ) as $filename ) { + include_once( $filename ); + } + } /** * Gets the requested action. @@ -276,26 +363,4 @@ function do_securify( $content = null ) { } - /** - * Plugin initialization function to load shortcodes. - * - * @since 3.0.0 - */ - function load_shortcodes() { - - require_once( WPMEM_PATH . 'inc/shortcodes.php' ); - add_shortcode( 'wp-members', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_field', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logged_in', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logged_out', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logout', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_form', 'wpmem_form_sc' ); - - /** - * Fires after shortcodes load (for adding additional custom shortcodes). - * - * @since 3.0.0 - */ - do_action( 'wpmem_load_shortcodes' ); - } } \ No newline at end of file diff --git a/wp-members.php b/wp-members.php index 5b7c272e..08d1ae43 100644 --- a/wp-members.php +++ b/wp-members.php @@ -59,16 +59,19 @@ */ -/** initial constants **/ +// Initialize constants. define( 'WPMEM_VERSION', '3.0 build 2.9.9.1 base' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); -/** initialize the plugin **/ +// Localization. +add_action( 'plugins_loaded', 'wpmem_load_textdomain' ); + +// Initialize the plugin. add_action( 'after_setup_theme', 'wpmem_init', 10 ); -/** install the pluign **/ +// Install the plugin. register_activation_hook( __FILE__, 'wpmem_install' ); @@ -94,11 +97,8 @@ function wpmem_init() { */ do_action( 'wpmem_pre_init' ); - // Start with any potential translation. - load_plugin_textdomain( 'wp-members', false, dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); - // Load WP_Members class. - include_once( 'inc/class-wp-members.php' ); + include_once( WPMEM_PATH . 'inc/class-wp-members.php' ); $wpmem = new WP_Members(); /** @@ -127,34 +127,14 @@ function wpmem_init() { define( 'WPMEM_EXP_MODULE', $exp_module ); // Load core file. - include_once( 'inc/core.php' ); - - // Add actions. - add_action( 'init', array( $wpmem, 'get_action' ) ); - add_action( 'widgets_init', 'widget_wpmemwidget_init' ); // initializes the widget - add_action( 'admin_init', 'wpmem_chk_admin' ); // check user role to load correct dashboard - add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu - add_action( 'user_register', 'wpmem_wp_reg_finalize' ); // handles wp native registration - add_action( 'login_enqueue_scripts', 'wpmem_wplogin_stylesheet' ); // styles the native registration - - // Add filters. - add_filter( 'the_content', array( $wpmem, 'do_securify' ), 1, 1 ); - add_filter( 'allow_password_reset', 'wpmem_no_reset' ); // no password reset for non-activated users - add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration - add_filter( 'registration_errors', 'wpmem_wp_reg_validate', 10, 3 ); // native registration validation - add_filter( 'comments_open', 'wpmem_securify_comments', 20, 1 ); // securifies the comments + include_once( WPMEM_PATH . 'inc/core.php' ); + + // Load actions and filters. + $wpmem->load_hooks(); // Load shortcodes. $wpmem->load_shortcodes(); - // Load the stylesheet if using the new forms. - add_action( 'wp_print_styles', 'wpmem_enqueue_style' ); - - // If registration is moderated, check for activation (blocks backend login by non-activated users). - if ( $wpmem->mod_reg == 1 ) { - add_filter( 'authenticate', 'wpmem_check_activated', 99, 3 ); - } - /** * Fires after initialization of plugin options. * @@ -288,4 +268,26 @@ function wpmem_mu_new_site( $blog_id, $user_id, $domain, $path, $site_id, $meta } -/** End of File **/ \ No newline at end of file +/** + * Loads translation files. + * + * @since 3.0.0 + */ +function wpmem_load_textdomain() { + + /** + * Filter translation file. + * + * @since 3.0.0 + * + * @param string $file The translation file to load. + */ + $file = apply_filters( 'wpmem_localization_file', dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); + + // Load the localization file. + load_plugin_textdomain( 'wp-members', false, $file ); + + return; +} + +// End of File. \ No newline at end of file From 9a8eb962f1d23aa6685d7d6fd4e2330d293930f3 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 8 May 2015 16:06:54 -0500 Subject: [PATCH 0071/1694] register function revisions --- inc/register.php | 45 +++++++++++++++------------------------------ 1 file changed, 15 insertions(+), 30 deletions(-) diff --git a/inc/register.php b/inc/register.php index eff26868..c60d2709 100644 --- a/inc/register.php +++ b/inc/register.php @@ -77,7 +77,7 @@ function wpmem_registration( $toggle ) { */ $fields = apply_filters( 'wpmem_pre_validate_form', $fields ); - // Check for required fields + // Check for required fields, reverse the array for logical error message order. $wpmem_fields_rev = array_reverse( $wpmem_fields ); foreach ( $wpmem_fields_rev as $meta ) { @@ -85,7 +85,7 @@ function wpmem_registration( $toggle ) { $pass_chk = ( $toggle == 'update' && in_array( $meta[2], $pass_arr ) ) ? true : false; if ( $meta[5] == 'y' && $pass_chk == false ) { if ( ! $fields[ $meta[2] ] ) { - $wpmem_themsg = sprintf( __('Sorry, %s is a required field.', 'wp-members'), $meta[1] ); + $wpmem_themsg = sprintf( __( 'Sorry, %s is a required field.', 'wp-members' ), $meta[1] ); } } } @@ -93,44 +93,29 @@ function wpmem_registration( $toggle ) { switch ( $toggle ) { case "register": - + if ( is_multisite() ) { // Multisite has different requirements. - $result = wpmu_validate_user_signup($fields['username'], $fields['user_email']); + $result = wpmu_validate_user_signup( $fields['username'], $fields['user_email'] ); $errors = $result['errors']; if ( $errors->errors ) { $wpmem_themsg = $errors->get_error_message(); return $wpmem_themsg; exit; } } else { - if ( ! $fields['username'] ) { - $wpmem_themsg = __( 'Sorry, username is a required field', 'wp-members' ); + // Validate username and email fields. + $wpmem_themsg = ( email_exists( $fields['user_email'] ) ) ? "email" : $wpmem_themsg; + $wpmem_themsg = ( username_exists( $fields['username'] ) ) ? "user" : $wpmem_themsg; + $wpmem_themsg = ( ! is_email( $fields['user_email']) ) ? __( 'You must enter a valid email address.', 'wp-members' ) : $wpmem_themsg; + $wpmem_themsg = ( ! validate_username( $fields['username'] ) ) ? __( 'The username cannot include non-alphanumeric characters.', 'wp-members' ) : $wpmem_themsg; + $wpmem_themsg = ( ! $fields['username'] ) ? __( 'Sorry, username is a required field', 'wp-members' ) : $wpmem_themsg; + + // If there is an error from username, email, or required field validation, stop registration and return the error. + if ( $wpmem_themsg ) { return $wpmem_themsg; - exit(); - } - if ( ! validate_username( $fields['username'] ) ) { - $wpmem_themsg = __( 'The username cannot include non-alphanumeric characters.', 'wp-members' ); - return $wpmem_themsg; - exit(); - } - if ( ! is_email( $fields['user_email']) ) { - $wpmem_themsg = __( 'You must enter a valid email address.', 'wp-members' ); - return $wpmem_themsg; - exit(); - } - if ( username_exists( $fields['username'] ) ) { - return "user"; - exit(); - } - if ( email_exists( $fields['user_email'] ) ) { - return "email"; - exit(); + exit(); } } - if ( $wpmem_themsg ) { - return "empty"; - exit(); - } // If form contains password and email confirmation, validate that they match. if ( array_key_exists( 'confirm_password', $fields ) && $fields['confirm_password'] != $fields ['password'] ) { @@ -271,7 +256,7 @@ function wpmem_registration( $toggle ) { // Get any excluded meta fields. $excluded_meta = wpmem_get_excluded_meta( 'register' ); - // User_url, first_name, last_name, description, jabber, aim, yim. + // Fields for wp_insert_user: user_url, first_name, last_name, description, jabber, aim, yim. $new_user_fields_meta = array( 'user_url', 'first_name', 'last_name', 'description', 'jabber', 'aim', 'yim' ); foreach ( $wpmem_fields as $meta ) { if ( in_array( $meta[2], $new_user_fields_meta ) ) { From 2f0b4c9d56e532681814f380c0f1222c44c6fe58 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 11 May 2015 09:34:13 -0500 Subject: [PATCH 0072/1694] regchk changes, added load_fields function to class --- inc/class-wp-members.php | 68 +++++++++++++++++++++++++++++----------- 1 file changed, 49 insertions(+), 19 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 0e38ca24..c3dee817 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -87,6 +87,13 @@ function load_hooks() { if ( $this->mod_reg == 1 ) { add_filter( 'authenticate', 'wpmem_check_activated', 99, 3 ); } + + /** + * Fires after action and filter hooks load (for adding/removing hooks). + * + * @since 3.0.0 + */ + do_action( 'wpmem_load_hooks' ); } /** @@ -111,6 +118,13 @@ function load_dropins() { foreach ( glob( $folder . '*.php' ) as $filename ) { include_once( $filename ); } + + /** + * Fires after dropins load (for adding additional dropings). + * + * @since 3.0.0 + */ + do_action( 'wpmem_load_dropins' ); } /** @@ -125,19 +139,6 @@ function get_action() { // Get the regchk value (if any). $this->regchk = $this->get_regchk( $this->action ); - - /** - * Filter wpmem_regchk. - * - * The value of regchk is determined by functions that may be run in the get_regchk function. - * This value determines what happens in the wpmem_securify() function. - * - * @since 2.9.0 - * - * @param string $this->regchk The value of wpmem_regchk. - * @param string $this->action The $wpmem_a action. - */ - $this->regchk = apply_filters( 'wpmem_regchk', $this->regchk, $this->action ); } /** @@ -155,28 +156,46 @@ function get_regchk( $action ) { switch ( $action ) { case 'login': - return wpmem_login(); + $regchk = wpmem_login(); break; case 'logout': - wpmem_logout(); + $regchk = wpmem_logout(); break; case 'pwdchange': - return wpmem_change_password(); + $regchk = wpmem_change_password(); break; case 'pwdreset': - return wpmem_reset_password(); + $regchk = wpmem_reset_password(); break; case 'register': case 'update': require_once( WPMEM_PATH . 'inc/register.php' ); - return wpmem_registration( $action ); + $regchk = wpmem_registration( $action ); + break; + + default: + $regchk = ( isset( $regchk ) ) ? $regchk : ''; break; } - return; + + /** + * Filter wpmem_regchk. + * + * The value of regchk is determined by functions that may be run in the get_regchk function. + * This value determines what happens in the wpmem_securify() function. + * + * @since 2.9.0 + * + * @param string $this->regchk The value of wpmem_regchk. + * @param string $this->action The $wpmem_a action. + */ + $regchk = apply_filters( 'wpmem_regchk', $regchk, $action ); + + return $regchk; } /** @@ -363,4 +382,15 @@ function do_securify( $content = null ) { } + /** + * Returns the registration fields. + * + * @since 3.0.0 + * + * @return array The registration fields. + */ + function load_fields() { + $this->fields = get_option( 'wpmembers_fields' ); + } + } \ No newline at end of file From 1abecdc7c2f192c91d2a815811c0b329a45bbf0e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 11 May 2015 09:34:55 -0500 Subject: [PATCH 0073/1694] updated to use load_fields so fields load once --- inc/core.php | 10 +++++----- inc/email.php | 4 ++-- inc/forms.php | 3 ++- inc/register.php | 2 +- inc/users.php | 8 ++++---- inc/wp-registration.php | 6 ++++-- wp-members.php | 3 +++ 7 files changed, 21 insertions(+), 15 deletions(-) diff --git a/inc/core.php b/inc/core.php index c076dc47..5aaaddbe 100644 --- a/inc/core.php +++ b/inc/core.php @@ -45,9 +45,7 @@ function wpmem() { * * @since 2.0 * - * @global string $wpmem_themsg Contains messages to be output. - * @global string $wpmem_captcha_err Contains error message for reCAPTCHA. - * @global object $post The post object. + * @global object $wpmem * @param string $content * @return string $content */ @@ -451,7 +449,8 @@ function wpmem_wp_register_form() { */ function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) { - $wpmem_fields = get_option( 'wpmembers_fields' ); + global $wpmem; + $wpmem_fields = $wpmem->fields; //get_option( 'wpmembers_fields' ); $exclude = wpmem_get_excluded_meta( 'register' ); foreach ( $wpmem_fields as $field ) { @@ -480,11 +479,12 @@ function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) { */ function wpmem_wp_reg_finalize( $user_id ) { + global $wpmem; $native_reg = ( isset( $_POST['wp-submit'] ) && $_POST['wp-submit'] == esc_attr( __( 'Register' ) ) ) ? true : false; $add_new = ( isset( $_POST['action'] ) && $_POST['action'] == 'createuser' ) ? true : false; if ( $native_reg || $add_new ) { // Get the fields. - $wpmem_fields = get_option( 'wpmembers_fields' ); + $wpmem_fields = $wpmem->fields; //get_option( 'wpmembers_fields' ); // Get any excluded meta fields. $exclude = wpmem_get_excluded_meta( 'register' ); foreach ( $wpmem_fields as $meta ) { diff --git a/inc/email.php b/inc/email.php index 0b783c00..177e05cc 100644 --- a/inc/email.php +++ b/inc/email.php @@ -107,7 +107,7 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, // Handle backward compatibility for customizations that may call the email function directly. if ( ! $wpmem_fields ) { - $wpmem_fields = get_option( 'wpmembers_fields' ); + $wpmem_fields = $wpmem->fields; //get_option( 'wpmembers_fields' ); } /** @@ -325,7 +325,7 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { // Handle backward compatibility for customizations that may call the email function directly. if ( ! $wpmem_fields ) { - $wpmem_fields = get_option( 'wpmembers_fields' ); + $wpmem_fields = $wpmem->fields; //get_option( 'wpmembers_fields' ); } /** diff --git a/inc/forms.php b/inc/forms.php index 50a663b2..4c305fce 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -596,7 +596,8 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) { * @param array The array of form fields. * @param string $toggle Toggle new registration or profile update. new|edit. */ - $wpmem_fields = apply_filters( 'wpmem_register_fields_arr', get_option( 'wpmembers_fields' ), $toggle ); + // $wpmem_fields = apply_filters( 'wpmem_register_fields_arr', get_option( 'wpmembers_fields' ), $toggle ); + $wpmem_fields = apply_filters( 'wpmem_register_fields_arr', $wpmem->fields, $toggle ); // loop through the remaining fields foreach ( $wpmem_fields as $field ) { diff --git a/inc/register.php b/inc/register.php index c60d2709..739f85d4 100644 --- a/inc/register.php +++ b/inc/register.php @@ -56,7 +56,7 @@ function wpmem_registration( $toggle ) { $fields['user_email'] = ( isset( $_POST['user_email'] ) ) ? $_POST['user_email'] : ''; // Build the $fields array from $_POST data. - $wpmem_fields = get_option( 'wpmembers_fields' ); + $wpmem_fields = $wpmem->fields; // get_option( 'wpmembers_fields' ); foreach ( $wpmem_fields as $meta ) { if ( $meta[4] == 'y' ) { if ( $meta[2] != 'password' ) { diff --git a/inc/users.php b/inc/users.php index e97bf6d8..d35255f2 100644 --- a/inc/users.php +++ b/inc/users.php @@ -27,7 +27,7 @@ */ function wpmem_user_profile() { - global $user_id; + global $wpmem, $user_id; /** * Filter the heading for the user profile additional fields. * @@ -39,7 +39,7 @@ function wpmem_user_profile() { fields; //get_option( 'wpmembers_fields' ); // Get excluded meta. $exclude = wpmem_get_excluded_meta( 'user-profile' ); @@ -98,9 +98,9 @@ function wpmem_user_profile() { */ function wpmem_profile_update() { - global $user_id; + global $wpmem, $user_id; // Get the fields. - $wpmem_fields = get_option( 'wpmembers_fields' ); + $wpmem_fields = $wpmem->fields; //get_option( 'wpmembers_fields' ); // Get any excluded meta fields. $exclude = wpmem_get_excluded_meta( 'user-profile' ); foreach ( $wpmem_fields as $meta ) { diff --git a/inc/wp-registration.php b/inc/wp-registration.php index 8070a8e3..d825a070 100644 --- a/inc/wp-registration.php +++ b/inc/wp-registration.php @@ -29,7 +29,8 @@ */ function wpmem_do_wp_register_form() { - $wpmem_fields = get_option( 'wpmembers_fields' ); + global $wpmem; + $wpmem_fields = $wpmem->fields; //$wpmem_fields = get_option( 'wpmembers_fields' ); foreach ( $wpmem_fields as $field ) { //for ( $row = 0; $row < count( $wpmem_fields ); $row++ ) { @@ -145,9 +146,10 @@ function wpmem_do_wp_register_form() { */ function wpmem_do_wp_newuser_form() { + global $wpmem; echo '
    '; - $wpmem_fields = get_option( 'wpmembers_fields' ); + $wpmem_fields = $wpmem->fields; //get_option( 'wpmembers_fields' ); $exclude = wpmem_get_excluded_meta( 'register' ); foreach ( $wpmem_fields as $field ) { diff --git a/wp-members.php b/wp-members.php index 08d1ae43..371ff2a0 100644 --- a/wp-members.php +++ b/wp-members.php @@ -135,6 +135,9 @@ function wpmem_init() { // Load shortcodes. $wpmem->load_shortcodes(); + // Load fields. + $wpmem->load_fields(); + /** * Fires after initialization of plugin options. * From 7fe8c45a159bd66a60a773418d581c51424b78b1 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 11 May 2015 11:58:10 -0500 Subject: [PATCH 0074/1694] legacy status shortcodes to new functions, added support for user ID and role attributes --- inc/class-wp-members.php | 12 ++-- inc/shortcodes.php | 131 ++++++++++++++++++++++++++++++--------- 2 files changed, 107 insertions(+), 36 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index c3dee817..29c4a66a 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -45,12 +45,12 @@ function load_settings() { function load_shortcodes() { require_once( WPMEM_PATH . 'inc/shortcodes.php' ); - add_shortcode( 'wp-members', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_field', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logged_in', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logged_out', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_logout', 'wpmem_shortcode' ); - add_shortcode( 'wpmem_form', 'wpmem_form_sc' ); + add_shortcode( 'wp-members', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_field', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_logged_in', 'wpmem_sc_logged_in' ); + add_shortcode( 'wpmem_logged_out', 'wpmem_sc_logged_out' ); + add_shortcode( 'wpmem_logout', 'wpmem_shortcode' ); + add_shortcode( 'wpmem_form', 'wpmem_sc_forms' ); /** * Fires after shortcodes load (for adding additional custom shortcodes). diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 0ce548eb..5f2a5150 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -44,7 +44,7 @@ * @param $tag * @return $content */ -function wpmem_form_sc( $atts, $content = null, $tag = 'wpmem_form' ) { +function wpmem_sc_forms( $atts, $content = null, $tag = 'wpmem_form' ) { // Dependencies. global $wpmem, $wpmem_themsg; @@ -122,6 +122,102 @@ function wpmem_form_sc( $atts, $content = null, $tag = 'wpmem_form' ) { } +/** + * Handles the logged in status shortcodes. + * + * There are two shortcodes to display content based on a user being logged + * in - [wp-members status=in] and [wpmem_logged_in] (status=in is a legacy + * shortcode, but will still function). There are several attributes that + * can be used with the shortcode: in|out, sub for subscription only info, + * id, and role. IDs and roles can be comma separated values for multiple + * users and roles. Additionally, status=out can be used to display content + * only to logged out users or visitors. + * + * @since 3.0.0 + * + * @param array $atts + * @param string $content + * @param string $tag + * @return string $content + */ +function wpmem_sc_logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) { + + global $wpmem; + + // Handles the 'status' attribute. + if ( ( isset( $atts['status'] ) ) || $tag == 'wpmem_logged_in' ) { + + $do_return = false; + + // If there is a status attribute of "out" and the user is not logged in. + $do_return = ( isset( $atts['status'] ) && $atts['status'] == 'out' && ! is_user_logged_in() ) ? true : $do_return; + + if ( is_user_logged_in() ) { + + // In case $current_user is not already global + $current_user = wp_get_current_user(); + + // If there is a status attribute of "in" and the user is logged in. + $do_return = ( isset( $atts['status'] ) && $atts['status'] == 'in' ) ? true : $do_return; + + // If using the wpmem_logged_in tag with no attributes & the user is logged in. + $do_return = ( $tag == 'wpmem_logged_in' && ( ! $atts ) ) ? true : $do_return; + + // If there is an "id" attribute and the user ID is in it. + if ( isset( $atts['id'] ) ) { + $ids = explode( ',', $atts['id'] ); + foreach ( $ids as $id ) { + if ( trim( $id ) == $current_user->ID ) { + $do_return = true; + } + } + } + + // If there is a "role" attribute and the user has a matching role. + if ( isset( $atts['role'] ) ) { + $roles = explode( ',', $atts['role'] ); + foreach ( $roles as $role ) { + if ( in_array( trim( $role ), $current_user->roles ) ) { + $do_return = true; + } + } + } + + // If there is a status attribute of "sub" and the user is logged in. + if ( ( isset( $atts['status'] ) ) && $atts['status'] == 'sub' && is_user_logged_in() ) { + if ( $wpmem->use_exp == 1 ) { + if ( ! wpmem_chk_exp() ) { + $do_return = true; + } elseif ( $atts['msg'] == true ) { + $do_return = true; + $content = wpmem_sc_expmessage(); + } + } + } + + } + + // Return content (or empty content) depending on the result of the above logic. + return ( $do_return ) ? do_shortcode( $content ) : ''; + } +} + + +/** + * Handles the [wpmem_logged_out] shortcode. + * + * @since 3.0.0 + * + * @param array $atts + * @param string $content + * @param string $tag + * @return string $content + */ +function wpmem_sc_logged_out( $atts, $content = null, $tag ) { + return ( ! is_user_logged_in() ) ? do_shortcode( $content ) : ''; +} + + /** * Displays login form when called by shortcode. * @@ -209,41 +305,16 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { // Handles the 'status' attribute. if ( ( $atts['status'] ) || $tag == 'wpmem_logged_in' ) { - - $do_return = false; - - // If using the wpmem_logged_in tag with no attributes & the user is logged in. - if ( $tag == 'wpmem_logged_in' && ( ! $attr ) && is_user_logged_in() ) - $do_return = true; - - // If there is a status attribute of "in" and the user is logged in. - if ( $atts['status'] == 'in' && is_user_logged_in() ) - $do_return = true; - - // If there is a status attribute of "out" and the user is not logged in. - if ( $atts['status'] == 'out' && ! is_user_logged_in() ) - $do_return = true; - - // If there is a status attribute of "sub" and the user is logged in. - if ( $atts['status'] == 'sub' && is_user_logged_in() ) { - if ( $wpmem->use_exp == 1 ) { - if ( ! wpmem_chk_exp() ) { - $do_return = true; - } elseif ( $atts['msg'] == true ) { - $do_return = true; - $content = wpmem_sc_expmessage(); - } - } - } - - // Return content (or empty content) depending on the result of the above logic. - return ( $do_return ) ? do_shortcode( $content ) : ''; + return do_shortcode( wpmem_sc_logged_in( $atts, $content, $tag ) ); } + // @deprecated 3.0.0 // Handles the wpmem_logged_out tag with no attributes & the user is not logged in. + /* if ( $tag == 'wpmem_logged_out' && ( ! $attr ) && ! is_user_logged_in() ) { return do_shortcode( $content ); } + */ // Handles the 'field' attribute. if ( $atts['field'] || $tag == 'wpmem_field' ) { From 1522347ae39b6430df84c626a48fcb06d1881629 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 11 May 2015 12:15:12 -0500 Subject: [PATCH 0075/1694] install package for 3.0 alpha testing --- wp-members-install.php | 32 ++++++++++++++++++++++++++------ 1 file changed, 26 insertions(+), 6 deletions(-) diff --git a/wp-members-install.php b/wp-members-install.php index 97d8a197..cc96bc12 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -30,9 +30,9 @@ function wpmem_do_install() { /* - * If you need to force an install, set $chk_force = true + * If you need to force an install, set $chk_force = true. * - *IMPORTANT NOTES: + * Important notes: * * 1. This will override any settings you already have for any of the plugin settings. * 2. This will not effect any WP settings or registered users. @@ -43,6 +43,7 @@ function wpmem_do_install() { if ( ! get_option( 'wpmembers_settings' ) || $chk_force == true ) { // This is a clean install (or an upgrade from 2.1 or earlier). + $wpmem_settings = array( 'version' => WPMEM_VERSION, 'block' => array( @@ -78,9 +79,23 @@ function wpmem_do_install() { 'attrib' => 0, ); - update_option( 'wpmembers_settings', $wpmem_settings, '', 'yes' ); // Using update_option to allow for forced update. - - // order, label, optionname, type, display, required, native, checked value, checked by default + update_option( 'wpmembers_settings', $wpmem_settings, '', 'yes' ); + + /* + * Field array elements: + * + * array( + * order, + * label, + * optionname, + * type, + * display, + * required, + * native, + * checked value, + * checked by default, + * ); + */ $wpmem_fields_options_arr = array( array( 1, 'First Name', 'first_name', 'text', 'y', 'y', 'y' ), array( 2, 'Last Name', 'last_name', 'text', 'y', 'y', 'y' ), @@ -185,9 +200,13 @@ function wpmem_update_settings() { 'autoex' => get_option( 'wpmembers_autoex' ), 'attrib' => get_option( 'wpmembers_attrib' ), ); + + $wpmem_newsettings = array_merge( $wpmem_settings, $wpmem_newsettings ); + update_option( 'wpmembers_settings', $wpmem_newsettings ); - // Remove old settings. + // Final 3.0 will remove the following settings when updating. + /* delete_option( 'wpmembers_msurl' ); delete_option( 'wpmembers_regurl' ); delete_option( 'wpmembers_logurl' ); @@ -195,6 +214,7 @@ function wpmem_update_settings() { delete_option( 'wpmembers_style' ); delete_option( 'wpmembers_autoex' ); delete_option( 'wpmembers_attrib' ); + */ } } From d86d4385f19f5b1251c35ebd756af60eceadaaa7 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 12 May 2015 11:29:04 -0500 Subject: [PATCH 0076/1694] fixed autoexcerpt default setting array at install --- wp-members-install.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/wp-members-install.php b/wp-members-install.php index cc96bc12..d398d919 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -75,7 +75,10 @@ function wpmem_do_install() { ), 'cssurl' => '', 'style' => '', - 'autoex' => '', + 'autoex' => array( + 'auto_ex' => '', + 'auto_ex_len' => '', + ), 'attrib' => 0, ); From 79b324ab2c043f3799745770e3ce7f7099ee203f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 20 May 2015 15:06:45 -0500 Subject: [PATCH 0077/1694] new sortable custom columns class --- admin/users.php | 30 ++++----- ...class-wp-members-sortable-user-columns.php | 66 +++++++++++++++++++ 2 files changed, 79 insertions(+), 17 deletions(-) create mode 100644 inc/class-wp-members-sortable-user-columns.php diff --git a/admin/users.php b/admin/users.php index be992a1a..d8668b41 100644 --- a/admin/users.php +++ b/admin/users.php @@ -44,10 +44,7 @@ add_action( 'wpmem_post_register_data', 'wpmem_set_new_user_non_active' ); add_action( 'wpmem_user_activated', 'wpmem_set_activated_user' ); add_action( 'wpmem_user_deactivated', 'wpmem_set_deactivated_user' ); -global $wpmem; // @todo Is there a better way to do this? -if ( $wpmem->mod_reg == 1 ) { - add_filter( 'user_row_actions', 'wpmem_insert_activate_link', 10, 2 ); -} +add_filter( 'user_row_actions', 'wpmem_insert_activate_link', 10, 2 ); /** @@ -83,7 +80,8 @@ function wpmem_bulk_user_action() { * @return array $actions */ function wpmem_insert_activate_link( $actions, $user_object ) { - if ( current_user_can( 'edit_users', $user_object->ID ) ) { + global $wpmem; + if ( current_user_can( 'edit_users', $user_object->ID ) && $wpmem->mod_reg == 1 ) { $var = get_user_meta( $user_object->ID, 'active', true ); @@ -289,23 +287,21 @@ function wpmem_users_views( $views ) { function wpmem_add_user_column( $columns ) { global $wpmem_user_columns, $wpmem; - $wpmem_user_columns = get_option( 'wpmembers_utfields' ); - - if ( $wpmem_user_columns ) { - foreach ( $wpmem_user_columns as $key => $val ) { - if ( $key == 'active' ) { - - if ( $wpmem->mod_reg == 1 ) { - $columns[$key] = $val; - } + // Get any columns to be added to the Users > All Users screen. + $wpmem_user_columns = get_option( 'wpmembers_utfields' ); - } else { - $columns[$key] = $val; - } + if ( $wpmem_user_columns ) { + if ( $wpmem->mod_reg != 1 ) { + unset( $wpmem_user_columns['active'] ); } + + $columns = array_merge( $columns, $wpmem_user_columns ); } + require_once( WPMEM_PATH . 'inc/class-wp-members-sortable-user-columns.php' ); + new WP_Members_Sortable_User_Columns( $wpmem_user_columns ); + return $columns; } diff --git a/inc/class-wp-members-sortable-user-columns.php b/inc/class-wp-members-sortable-user-columns.php new file mode 100644 index 00000000..7fbae71f --- /dev/null +++ b/inc/class-wp-members-sortable-user-columns.php @@ -0,0 +1,66 @@ +args = $args; + add_action( 'pre_user_query', array( &$this, 'query' ) ); + add_action( 'manage_users_custom_column', array( &$this, 'content' ), 10, 3 ); + add_filter( 'manage_users_columns', array( &$this, 'columns' ) ); + add_filter( 'manage_users_sortable_columns', array( &$this, 'sortable') ); + } + + function query( $query ) { + $vars = $query->query_vars; + if ( in_array( $vars['orderby'], $this->defaults ) ) { + return; + } + $title = $this->args[ $vars['orderby'] ]; + if ( ! empty( $title ) ) { + $query->query_from .= " LEFT JOIN wp_usermeta m ON (wp_users.ID = m.user_id AND m.meta_key = '" . $vars['orderby'] . "')"; + $query->query_orderby = "ORDER BY m.meta_value ".$vars['order']; + } + } + + function columns( $columns ) { + foreach ( $this->args as $key => $value ) { + $columns[ $key ] = $value; + } + return $columns; + } + + function sortable( $columns ) { + foreach ( $this->args as $key => $value ) { + $columns[ $key ] = $key; + } + return $columns; + } + + function content( $value, $column_name, $user_id ) { + $user = get_userdata( $user_id ); + return $user->$column_name; + } + +} \ No newline at end of file From 0f4525708a46f222bad08157a0b477de9a6e9766 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 20 May 2015 15:07:27 -0500 Subject: [PATCH 0078/1694] login function does not need to call wp_set_auth_cookie; this is already done by wp_signon --- inc/core.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/inc/core.php b/inc/core.php index 5aaaddbe..faf910b1 100644 --- a/inc/core.php +++ b/inc/core.php @@ -143,8 +143,9 @@ function wpmem_login() { // If no error, user is a valid signon. continue. if ( ! is_wp_error( $user ) ) { + // @todo - I don't think we need this. It is done in wp_signon. // Set the auth cookie. - wp_set_auth_cookie( $user->ID, $rememberme ); + // wp_set_auth_cookie( $user->ID, $rememberme ); // Determine where to put the user after login. $redirect_to = ( isset( $_POST['redirect_to'] ) ) ? $_POST['redirect_to'] : $_SERVER['REQUEST_URI']; From ca84002ec9ea7bcedf4c9b31a912a4dee419a77e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 20 May 2015 15:09:40 -0500 Subject: [PATCH 0079/1694] added defaults for autoex in install --- wp-members-install.php | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) diff --git a/wp-members-install.php b/wp-members-install.php index 97d8a197..ba31c307 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -74,13 +74,31 @@ function wpmem_do_install() { ), 'cssurl' => '', 'style' => '', - 'autoex' => '', + 'autoex' => array( + 'auto_ex' => '', + 'auto_ex_len' => '', + ), 'attrib' => 0, ); - - update_option( 'wpmembers_settings', $wpmem_settings, '', 'yes' ); // Using update_option to allow for forced update. - - // order, label, optionname, type, display, required, native, checked value, checked by default + + // Using update_option to allow for forced update. + update_option( 'wpmembers_settings', $wpmem_settings, '', 'yes' ); + + /* + * Field array elements: + * + * array( + * order, + * label, + * optionname, + * type, + * display, + * required, + * native, + * checked value, + * checked by default, + * ); + */ $wpmem_fields_options_arr = array( array( 1, 'First Name', 'first_name', 'text', 'y', 'y', 'y' ), array( 2, 'Last Name', 'last_name', 'text', 'y', 'y', 'y' ), From 1e9911ce2f6432b3d81f1e72bea682e862c1f255 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 22 May 2015 15:32:58 -0500 Subject: [PATCH 0080/1694] added user count shortcode --- inc/shortcodes.php | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 5f2a5150..96b16a9f 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -94,7 +94,7 @@ function wpmem_sc_forms( $atts, $content = null, $tag = 'wpmem_form' ) { $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); break; - case in_array( 'user-edit', $atts ): + case in_array( 'user_edit', $atts ): $content = wpmem_page_user_edit( $wpmem->regchk, $content ); break; @@ -487,4 +487,29 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) { } // End wpmem_do_sc_pages. endif; + +/** + * User count shortcode. + * + * @since 3.0 + * + * @todo Evaluate this shortcode for full inclusion. + */ +add_shortcode( 'wpmem_show_count', 'wpmem_sc_user_count' ); +function wpmem_sc_user_count( $atts, $content = null ) { + global $wpdb; + $do_query = ( $atts['key'] && $atts['value'] ) ? true : false; + if ( $do_query ) { + $user_meta_query = $wpdb->get_var( $wpdb->prepare( + "SELECT COUNT(*) + FROM $wpdb->usermeta + WHERE meta_key = %s + AND meta_value = %s", + $atts['key'], + $atts['value'] + ) ); + } + return ( $do_query ) ? $atts['label'] . $user_meta_query : ''; +} + /** End of File **/ \ No newline at end of file From 733d544cb5ef13c39a0d7cc4d399d100720f4603 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 22 May 2015 15:34:01 -0500 Subject: [PATCH 0081/1694] added shortcodes to tinymce --- inc/class-wp-members-tinymce-buttons.php | 42 +++ js/shortcodes_tinymce.js | 407 +++++++++++++++++++++++ js/shortcodes_tinymce_4.js | 162 +++++++++ 3 files changed, 611 insertions(+) create mode 100644 inc/class-wp-members-tinymce-buttons.php create mode 100644 js/shortcodes_tinymce.js create mode 100644 js/shortcodes_tinymce_4.js diff --git a/inc/class-wp-members-tinymce-buttons.php b/inc/class-wp-members-tinymce-buttons.php new file mode 100644 index 00000000..210bc62c --- /dev/null +++ b/inc/class-wp-members-tinymce-buttons.php @@ -0,0 +1,42 @@ +=' ) ) { + $plugin_array['wpmem_shortcodes'] = WPMEM_DIR .'js/shortcodes_tinymce_4.js?ver=' . $ver; + } else { + $plugin_array['wpmem_shortcodes'] = WPMEM_DIR .'js/shortcodes_tinymce.js?ver=' . $ver; + } + return $plugin_array; + } + + function register_button( $buttons ) { + array_push( $buttons, "wpmem_shortcodes_button" ); + return $buttons; + } +} + +// End of File. \ No newline at end of file diff --git a/js/shortcodes_tinymce.js b/js/shortcodes_tinymce.js new file mode 100644 index 00000000..f097c87d --- /dev/null +++ b/js/shortcodes_tinymce.js @@ -0,0 +1,407 @@ +(function () { + "use strict"; + + tinymce.create('tinymce.plugins.wcShortcodeMce', { + init : function(ed, url){ + tinymce.plugins.wcShortcodeMce.theurl = url; + }, + createControl : function(btn, e) { + if ( btn === "wpmem_shortcodes_button" ) { + var a = this; + + // out puts an js error when clicking on button + // btn = e.createSplitButton('wpmem_shortcodes_button', { + + btn = e.createMenuButton('wpmem_shortcodes_button', { + title: "Insert Shortcode", + image: tinymce.plugins.wcShortcodeMce.theurl +"/images/shortcodes.png", + icons: false, + }); + btn.onRenderMenu.add(function (c, b) { + + b.add({title : 'WC Shortcodes', 'class' : 'mceMenuItemTitle'}).setDisabled(1); + + + // Columns + c = b.addMenu({title:"Columns"}); + + a.render( c, "1/2 + 1/2", "half-half" ); + a.render( c, "1/3 + 1/3 + 1/3", "third-third-third" ); + a.render( c, "1/3 + 2/3", "third-twothird" ); + a.render( c, "2/3 + 1/3", "twothird-third" ); + a.render( c, "1/4 + 1/4 + 1/4 + 1/4", "fourth-fourth-fourth-fourth" ); + a.render( c, "1/4 + 1/2 + 1/4", "fourth-half-fourth" ); + a.render( c, "1/2 + 1/4 + 1/4", "half-fourth-fourth" ); + a.render( c, "1/4 + 1/4 + 1/2", "fourth-fourth-half" ); + a.render( c, "1/4 + 3/4", "fourth-three-fourth" ); + a.render( c, "3/4 + 1/4", "three-fourth-fourth" ); + + b.addSeparator(); + + + // Elements + c = b.addMenu({title:"Elements"}); + + a.render( c, "Posts", "posts" ); + a.render( c, "Button", "button" ); + a.render( c, "Google Map", "googlemap" ); + a.render( c, "Heading", "heading" ); + a.render( c, "Pricing Table", "pricing" ); + a.render( c, "Skillbar", "skillbar" ); + a.render( c, "Social Icon", "social" ); + a.render( c, "Testimonial", "testimonial" ); + a.render( c, "Image", "image" ); + a.render( c, "Countdown", "countdown" ); + a.render( c, "RSVP", "rsvp" ); + a.render( c, "HTML", "html" ); + + b.addSeparator(); + + // Boxes + c = b.addMenu({title:"Boxes"}); + + a.render( c, "Primary", "primaryBox" ); + a.render( c, "Secondary", "secondaryBox" ); + a.render( c, "Inverse", "inverseBox" ); + a.render( c, "Success", "successBox" ); + a.render( c, "Warning", "warningBox" ); + a.render( c, "Danger", "dangerBox" ); + a.render( c, "Info", "infoBox" ); + + b.addSeparator(); + + // Highlights + c = b.addMenu({title:"Highlights"}); + + a.render( c, "Blue", "blueHighlight" ); + a.render( c, "Gray", "grayHighlight" ); + a.render( c, "Green", "greenHighlight" ); + a.render( c, "Red", "redHighlight" ); + a.render( c, "Yellow", "yellowHighlight" ); + + b.addSeparator(); + + + // Dividers + c = b.addMenu({title:"Dividers"}); + + a.render( c, "Solid", "solidDivider" ); + a.render( c, "Dashed", "dashedDivider" ); + a.render( c, "Dotted", "dottedDivider" ); + a.render( c, "Double", "doubleDivider" ); + a.render( c, "Image1", "imageDivider" ); + a.render( c, "Image2", "imageDivider2" ); + a.render( c, "Image3", "imageDivider3" ); + + b.addSeparator(); + + + // jQuery + c = b.addMenu({title:"jQuery"}); + + a.render( c, "Accordion", "accordion" ); + a.render( c, "Tabs", "tabs" ); + a.render( c, "Toggle", "toggle" ); + + b.addSeparator(); + + + // Helpers + c = b.addMenu({title:"Other"}); + + a.render( c, "Spacing", "spacing" ); + a.render( c, "Clear Floats", "clear" ); + a.render( c, "Center Content", "center" ); + a.render( c, "Full Width", "fullwidth" ); + a.render( c, "Code", "code" ); + a.render( c, "Pre", "pre" ); + + + + }); + + return btn; + } + return null; + }, + render : function(ed, title, id) { + ed.add({ + title: title, + onclick: function () { + + // Selected content + var mceSelected = tinyMCE.activeEditor.selection.getContent(); + + // Add highlighted content inside the shortcode when possible - yay! + var wcDummyContent; + if ( mceSelected ) { + wcDummyContent = mceSelected; + } else { + wcDummyContent = 'Sample Content'; + } + var wcParagraphContent = '

    Sample Content

    '; + + // Accordion + if(id === "accordion") { + tinyMCE.activeEditor.selection.setContent('

    [wc_accordion collapse="0"]

    [wc_accordion_section title="Section 1"]

    ' + wcParagraphContent + '

    [/wc_accordion_section]

    [wc_accordion_section title="Section 2"]

    ' + wcParagraphContent + '

    [/wc_accordion_section]

    [/wc_accordion]

    '); + } + + + + + // Boxes + if(id === "primaryBox") { + tinyMCE.activeEditor.selection.setContent('[wc_box color="primary" text_align="left"]' + wcDummyContent + '[/wc_box]'); + } + if(id === "secondaryBox") { + tinyMCE.activeEditor.selection.setContent('[wc_box color="secondary" text_align="left"]' + wcDummyContent + '[/wc_box]'); + } + if(id === "inverseBox") { + tinyMCE.activeEditor.selection.setContent('[wc_box color="inverse" text_align="left"]' + wcDummyContent + '[/wc_box]'); + } + if(id === "successBox") { + tinyMCE.activeEditor.selection.setContent('[wc_box color="success" text_align="left"]' + wcDummyContent + '[/wc_box]'); + } + if(id === "warningBox") { + tinyMCE.activeEditor.selection.setContent('[wc_box color="warning" text_align="left"]' + wcDummyContent + '[/wc_box]'); + } + if(id === "dangerBox") { + tinyMCE.activeEditor.selection.setContent('[wc_box color="danger" text_align="left"]' + wcDummyContent + '[/wc_box]'); + } + if(id === "infoBox") { + tinyMCE.activeEditor.selection.setContent('[wc_box color="info" text_align="left"]' + wcDummyContent + '[/wc_box]'); + } + + + + + // Image + if(id === "image") { + tinyMCE.activeEditor.selection.setContent('[wc_image attachment_id="" size="" title="" alt="" caption="" link_to="post" url="" align="none" flag="For Sale" left="" top="" right="0" bottom="20" text_color="" background_color="" font_size=""][/wc_image]'); + } + + + + + + // Posts + if(id === "posts") { + tinyMCE.activeEditor.selection.setContent('[wc_posts author="" author_name="" p="" post__in="" order="DESC" orderby="date" post_status="publish" post_type="post" posts_per_page="10" taxonomy="" field="slug" terms="" title="yes" meta_all="yes" meta_author="yes" meta_date="yes" meta_comments="yes" thumbnail="yes" content="yes" paging="yes" size="large" filtering="yes" columns="3" gutter_space="20" heading_type="h2" layout="isotope"][/wc_posts]'); + } + + + + + // Button + if(id === "button") { + tinyMCE.activeEditor.selection.setContent('[wc_button type="primary" url="http://webplantmedia.com" title="Visit Site" target="self" position="float"]' + wcDummyContent + '[/wc_button]'); + } + + + + + // Clear Floats + if(id === "clear") { + tinyMCE.activeEditor.selection.setContent('[wc_clear_floats]'); + } + + + + + // Columns + if(id === "half-half") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-half" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-half" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + if(id === "third-third-third") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-third" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-third"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-third" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + if(id === "third-twothird") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-third" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="two-third" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + if(id === "twothird-third") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="two-third" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-third" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + if(id === "fourth-fourth-fourth-fourth") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + if(id === "fourth-half-fourth") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-half"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + if(id === "half-fourth-fourth") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-half" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + if(id === "fourth-fourth-half") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-half" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + if(id === "fourth-three-fourth") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="three-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + if(id === "three-fourth-fourth") { + tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="three-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); + } + + + + // Divider + if(id === "solidDivider") { + tinyMCE.activeEditor.selection.setContent('[wc_divider style="solid" line="single" margin_top="" margin_bottom=""]'); + } + if(id === "dashedDivider") { + tinyMCE.activeEditor.selection.setContent('[wc_divider style="dashed" line="single" margin_top="" margin_bottom=""]'); + } + if(id === "dottedDivider") { + tinyMCE.activeEditor.selection.setContent('[wc_divider style="dotted" line="single" margin_top="" margin_bottom=""]'); + } + if(id === "doubleDivider") { + tinyMCE.activeEditor.selection.setContent('[wc_divider style="solid" line="double" margin_top="" margin_bottom=""]'); + } + if(id === "tripleDivider") { + tinyMCE.activeEditor.selection.setContent('[wc_divider style="solid" line="triple" margin_top="" margin_bottom=""]'); + } + if(id === "imageDivider") { + tinyMCE.activeEditor.selection.setContent('[wc_divider style="image" margin_top="" margin_bottom=""]'); + } + if(id === "imageDivider2") { + tinyMCE.activeEditor.selection.setContent('[wc_divider style="image2" margin_top="" margin_bottom=""]'); + } + if(id === "imageDivider3") { + tinyMCE.activeEditor.selection.setContent('[wc_divider style="image3" margin_top="" margin_bottom=""]'); + } + + + + + // Google Map + if(id === "googlemap") { + tinyMCE.activeEditor.selection.setContent('[wc_googlemap title="St. Paul\'s Chapel" location="209 Broadway, New York, NY 10007" zoom="10" height="250" title_on_load="no" class=""]'); + } + + + + + // Heading + if(id === "heading") { + tinyMCE.activeEditor.selection.setContent('[wc_heading type="h1" title="' + wcDummyContent + '" text_align="left"]'); + } + + + + + // Highlight + if(id === "blueHighlight") { + tinyMCE.activeEditor.selection.setContent('[wc_highlight color="blue"]' + wcDummyContent + '[/wc_highlight]'); + } + if(id === "grayHighlight") { + tinyMCE.activeEditor.selection.setContent('[wc_highlight color="gray"]' + wcDummyContent + '[/wc_highlight]'); + } + if(id === "greenHighlight") { + tinyMCE.activeEditor.selection.setContent('[wc_highlight color="green"]' + wcDummyContent + '[/wc_highlight]'); + } + if(id === "redHighlight") { + tinyMCE.activeEditor.selection.setContent('[wc_highlight color="red"]' + wcDummyContent + '[/wc_highlight]'); + } + if(id === "yellowHighlight") { + tinyMCE.activeEditor.selection.setContent('[wc_highlight color="yellow"]' + wcDummyContent + '[/wc_highlight]'); + } + + + + // Pricing + if(id === "pricing") { + tinyMCE.activeEditor.selection.setContent('[wc_pricing type="primary" featured="yes" plan="Basic" cost="$19.99" per="per month" button_url="#" button_text="Sign Up" button_target="self" button_rel="nofollow"]
    • 30GB Storage
    • 512MB Ram
    • 10 databases
    • 1,000 Emails
    • 25GB Bandwidth
    [/wc_pricing]'); + } + + + + + //Spacing + if(id === "spacing") { + tinyMCE.activeEditor.selection.setContent('[wc_spacing size="40px"]'); + } + + + + + //Social + if(id === "social") { + tinyMCE.activeEditor.selection.setContent('[wc_social_icons align="left" size="large" display="facebook,google,twitter,pinterest,instagram,bloglovin,flickr,rss,email,custom1,custom2,custom3,custom4,custom5"]'); + } + + + + + //Skillbar + if(id === "skillbar") { + tinyMCE.activeEditor.selection.setContent('[wc_skillbar title="' + wcDummyContent + '" percentage="100" color="#6adcfa"]'); + } + + + + + //Tabs + if(id === "tabs") { + tinyMCE.activeEditor.selection.setContent('

    [wc_tabgroup][wc_tab title="First Tab"]

    '+wcParagraphContent+'

    [/wc_tab][wc_tab title="Second Tab"]

    '+wcParagraphContent+'

    [/wc_tab][/wc_tabgroup]

    '); + } + + + + //Testimonial + if(id === "testimonial") { + tinyMCE.activeEditor.selection.setContent('[wc_testimonial by="Author" url="" position="left"]' + wcDummyContent + '[/wc_testimonial]'); + } + + + + //RSVP + if(id === "rsvp") { + tinyMCE.activeEditor.selection.setContent('[wc_rsvp columns="3" align="left" button_align="center"]'); + } + + + + //Countdown + if(id === "countdown") { + var d = new Date(); + var year = d.getFullYear() + 1; + tinyMCE.activeEditor.selection.setContent('[wc_countdown date="July 23, '+year+', 6:00:00 PM" format="wdHMs" message="Your Message Here!" labels="Years,Months,Weeks,Days,Hours,Minutes,Seconds" labels1="Year,Month,Week,Day,Hour,Minute,Second"]'); + } + + + //Toggle + if(id === "toggle") { + tinyMCE.activeEditor.selection.setContent('

    [wc_toggle title="This Is Your Toggle Title" padding="" border_width=""]

    ' + wcParagraphContent + '

    [/wc_toggle]

    '); + } + + if(id === "center") { + tinyMCE.activeEditor.selection.setContent('

    [wc_center max_width="500px" text_align="left"]

    ' + wcParagraphContent + '

    [/wc_center]

    '); + } + + + if(id === "fullwidth") { + tinyMCE.activeEditor.selection.setContent('[wc_fullwidth selector="#main"]' + wcDummyContent + '[/wc_fullwidth]'); + } + + + if(id === "html") { + tinyMCE.activeEditor.selection.setContent('[wc_html name="Custom Field Name"]'); + } + + + if(id === "code") { + tinyMCE.activeEditor.selection.setContent('[wc_code]' + wcDummyContent + '[/wc_code]'); + } + + + if(id === "pre") { + tinyMCE.activeEditor.selection.setContent('[wc_pre color="1" wrap="0" scrollable="1" linenums="0" name="Custom Field Name"]'); + } + + + return false; + } + }); + } + + }); + tinymce.PluginManager.add("wpmem_shortcodes", tinymce.plugins.wcShortcodeMce); +})(); diff --git a/js/shortcodes_tinymce_4.js b/js/shortcodes_tinymce_4.js new file mode 100644 index 00000000..27713685 --- /dev/null +++ b/js/shortcodes_tinymce_4.js @@ -0,0 +1,162 @@ +(function () { + "use strict"; + + var wcShortcodeManager = function(editor, url) { + var wcDummyContent = 'Sample Content'; + var wcParagraphContent = '

    Sample Content

    '; + + + editor.addButton('wpmem_shortcodes_button', function() { + return { + title: "", + text: "[WP-Members Shortcodes]", + image: url + "/images/shortcodes.png", + type: 'menubutton', + icons: false, + menu: [ + { + text: 'Login Forms', + menu: [ + { + text: "basic login", + onclick: function(){ + editor.insertContent('[wpmem_form login]'); + } + }, + { + text: "login + redirect", + onclick: function(){ + editor.insertContent('[wpmem_form login redirect_to="http://mysite.com/my-page/"]'); + } + }, + { + text: "login + logged in content", + onclick: function(){ + editor.insertContent('[wpmem_form login]
    This displays when logged in
    [/wpmem_form]'); + } + }, + { + text: "login + redirect + content", + onclick: function(){ + editor.insertContent('[wpmem_form login redirect_to="http://mysite.com/my-page/"]
    This displays when logged in
    [/wpmem_form]'); + } + }, + ] + }, + { + text: 'Registration Forms', + menu: [ + { + text: "basic registration", + onclick: function(){ + editor.insertContent('[wpmem_form register]'); + } + }, + { + text: "registration + redirect", + onclick: function(){ + editor.insertContent('[wpmem_form register redirect_to="http://mysite.com/my-page/"]'); + } + }, + { + text: "registration + logged in content", + onclick: function(){ + editor.insertContent('[wpmem_form register]
    This displays when logged in
    [/wpmem_form]'); + } + }, + { + text: "registration + redirect + content", + onclick: function(){ + editor.insertContent('[wpmem_form register redirect_to="http://mysite.com/my-page/"]
    This displays when logged in
    [/wpmem_form]'); + } + }, + ] + }, + { + text: 'Other Forms', + menu: [ + { + text: "User Profile Page", + onclick: function(){ + editor.insertContent('[wp-members page="user-profile"]'); + } + }, + { + text: "Password Reset/Change", + onclick: function(){ + editor.insertContent('[wpmem_form password]'); + } + }, + { + text: "Password Reset Only", + onclick: function(){ + editor.insertContent('[wpmem_logged_out][wpmem_form password][/wpmem_logged_out]'); + } + }, + { + text: "Password Change Only", + onclick: function(){ + editor.insertContent('[wpmem_logged_in][wpmem_form password][/wpmem_logged_in]'); + } + }, + { + text: "User Data Edit", + onclick: function(){ + editor.insertContent('[wpmem_logged_in][wpmem_form user_edit][/wpmem_logged_in]'); + } + }, + ] + }, + { + text: 'Content Restriction', + menu: [ + { + text: "logged in content", + onclick: function(){ + editor.insertContent('[wpmem_logged_in]
    This displays when logged in
    [/wpmem_logged_in]'); + } + }, + { + text: "logged out content", + onclick: function(){ + editor.insertContent('[wpmem_logged_out]
    This displays when logged out
    [/wpmem_logged_out]'); + } + }, + ] + }, + { + text: 'Logout Link', + menu: [ + { + text: "basic logout link", + onclick: function(){ + editor.insertContent('[wpmem_logout]'); + } + }, + { + text: "logout link + custom link text", + onclick: function(){ + editor.insertContent('[wpmem_logout]This the link text[/wpmem_logout]'); + } + }, + ] + }, + { + text: 'User Fields', + onclick: function(){ + editor.insertContent('[wpmem_field field=user_login]'); + } + }, + { + text: 'User Count', + onclick: function(){ + editor.insertContent('[wpmem_show_count label="Active Users: " meta=active value=1]'); + } + }, + ] + } + }); + }; + + tinymce.PluginManager.add( "wpmem_shortcodes", wcShortcodeManager ); +})(); From 07ad830dca7f57fb208911491b296bf6f50827af Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 26 May 2015 13:25:11 -0500 Subject: [PATCH 0082/1694] added custom post types to main plugin options --- admin/tab-options.php | 130 +++++++++++++++++++++++------------------- 1 file changed, 71 insertions(+), 59 deletions(-) diff --git a/admin/tab-options.php b/admin/tab-options.php index e5aa10af..c52deb73 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -34,7 +34,20 @@ function wpmem_a_build_options() { $admin_email = apply_filters( 'wpmem_notify_addr', get_option( 'admin_email' ) ); $chg_email = __( sprintf( '%sChange%s or %sFilter%s this address', '', '', '', '' ), 'wp-members' ); $help_link = __( sprintf( 'See the %sUsers Guide on plugin options%s.', '', '' ), 'wp-members' ); - ?> + + // Build an array of post types + $post_types = get_post_types( array( 'public' => true, '_builtin' => false ), 'names', 'and' ); + $post_arr = array( + 'post' => 'Posts', + 'page' => 'Pages', + ); + if ( $post_types ) { + foreach ( $post_types as $post_type ) { + $cpt_obj = get_post_type_object( $post_type ); + $post_arr[ $cpt_obj->name ] = $cpt_obj->labels->name; + } + } ?> +
    @@ -57,48 +70,43 @@ function wpmem_a_build_options() {

    Content

      -
    • - - - Posts -
    • -
    • - - + + + - Pages -
    • -
    • - - show_excerpt['post'] == 1 ) { echo "checked"; }?> /> Posts -
    • -
    • - - show_excerpt['page'] == 1 ) { echo "checked"; }?> /> Pages -
    • -
    • - - show_login['post'] == 1 ) { echo "checked"; }?> /> Posts -
    • -
    • - - show_login['page'] == 1 ) { echo "checked"; }?> /> Pages -
    • -
    • - - show_reg['post'] == 1 ) { echo "checked"; }?> /> Posts -
    • -
    • - - show_reg['page'] == 1 ) { echo "checked"; }?> /> Pages +
    • + 'Show Excerpts', + 'login' => 'Show Login Form', + 'reg' => 'Show Registration Form', + ); + + foreach ( $option_group_array as $item_key => $item_val ) { + $i = 0; + $len = count( $post_arr ); + foreach ( $post_arr as $key => $val ) { ?> + > + + block[ $key ] ) && $wpmem->block[ $key ] == 1 ) ? "checked" : ''; ?> /> + +
    use_exp == true ) { @@ -264,23 +272,7 @@ function wpmem_update_options() { ); $wpmem_newsettings = array( - 'version' => WPMEM_VERSION, - 'block' => array( - 'post' => ( isset( $_POST['wpmem_block_post'] ) ) ? $_POST['wpmem_block_post'] : 0, - 'page' => ( isset( $_POST['wpmem_block_page'] ) ) ? $_POST['wpmem_block_page'] : 0, - ), - 'show_excerpt' => array( - 'post' => ( isset( $_POST['wpmem_show_excerpt_post'] ) ) ? $_POST['wpmem_show_excerpt_post'] : 0, - 'page' => ( isset( $_POST['wpmem_show_excerpt_page'] ) ) ? $_POST['wpmem_show_excerpt_page'] : 0, - ), - 'show_reg' => array( - 'post' => ( isset( $_POST['wpmem_show_reg_post'] ) ) ? $_POST['wpmem_show_reg_post'] : 0, - 'page' => ( isset( $_POST['wpmem_show_reg_page'] ) ) ? $_POST['wpmem_show_reg_page'] : 0, - ), - 'show_login' => array( - 'post' => ( isset( $_POST['wpmem_show_login_post'] ) ) ? $_POST['wpmem_show_login_post'] : 0, - 'page' => ( isset( $_POST['wpmem_show_login_page'] ) ) ? $_POST['wpmem_show_login_page'] : 0, - ), + 'version' => WPMEM_VERSION, 'notify' => ( isset( $_POST['wpmem_settings_notify'] ) ) ? $_POST['wpmem_settings_notify'] : 0, 'mod_reg' => ( isset( $_POST['wpmem_settings_moderate'] ) ) ? $_POST['wpmem_settings_moderate'] : 0, 'captcha' => ( isset( $_POST['wpmem_settings_captcha'] ) ) ? $_POST['wpmem_settings_captcha'] : 0, @@ -296,9 +288,29 @@ function wpmem_update_options() { 'style' => $wpmem_settings_style, 'autoex' => $wpmem_autoex, 'attrib' => ( isset( $_POST['attribution'] ) ) ? $_POST['attribution'] : 0, - ); + // Build an array of post types + $post_types = get_post_types( array( 'public' => true, '_builtin' => false ), 'names', 'and' ); + $post_arr = array( 'post', 'page' ); + if ( $post_types ) { + foreach ( $post_types as $post_type ) { + $cpt_obj = get_post_type_object( $post_type ); + $post_arr[] = $cpt_obj->name; + } + } + + // Get settings for blocking, excerpts, show login, and show registration for posts, pages, and custom post types. + $option_group_array = array( 'block', 'show_excerpt', 'show_login', 'show_reg' ); + foreach ( $option_group_array as $option_group_item ) { + $arr = array(); + foreach ( $post_arr as $post_type ) { + $post_var = 'wpmem_' . $option_group_item . '_' . $post_type; + $arr[ $post_type ] = ( isset( $_POST[ $post_var ] ) ) ? $_POST[ $post_var ] : 0; + } + $wpmem_newsettings[ $option_group_item ] = $arr; + } + /* * If we are setting registration to be moderated, * check to see if the current admin has been From 34ff02fcce7ffc1ff2f866f3698b77c41d5fc268 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 26 May 2015 13:25:37 -0500 Subject: [PATCH 0083/1694] removed wp_set_auth_cookie from login function (already done by wp_signon) --- inc/core.php | 4 ---- readme.txt | 1 + 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/inc/core.php b/inc/core.php index faf910b1..40edc8b9 100644 --- a/inc/core.php +++ b/inc/core.php @@ -143,10 +143,6 @@ function wpmem_login() { // If no error, user is a valid signon. continue. if ( ! is_wp_error( $user ) ) { - // @todo - I don't think we need this. It is done in wp_signon. - // Set the auth cookie. - // wp_set_auth_cookie( $user->ID, $rememberme ); - // Determine where to put the user after login. $redirect_to = ( isset( $_POST['redirect_to'] ) ) ? $_POST['redirect_to'] : $_SERVER['REQUEST_URI']; diff --git a/readme.txt b/readme.txt index 3a9f8abd..3dd49392 100644 --- a/readme.txt +++ b/readme.txt @@ -141,6 +141,7 @@ WP-Members 2.9.9 is mostly minor updates preparing codebase for the 3.0 project. * wpmem_settings_loaded action added. * securify comments changed to use comments_open instead of comments_template (with a blank template). * registration clear form button defaults to false +* removed wp_set_auth_cookie from login function; it is already done as part of wp_signon = 2.9.9 = * Code standards in wp-members-email.php From 177e462946fa3208ecdd5568138156b523fe6885 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 27 May 2015 10:38:20 -0500 Subject: [PATCH 0084/1694] fix to captcha tab that slipped in during code standards cleanup --- admin/tab-captcha.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/admin/tab-captcha.php b/admin/tab-captcha.php index 3c901707..8d58dc74 100644 --- a/admin/tab-captcha.php +++ b/admin/tab-captcha.php @@ -55,7 +55,8 @@ function wpmem_a_build_captcha_options() {
    - captcha == 1 ) { $show_update_button = true; ?>
    From d737aa0fab7071d88e4c1a0a0d854c6aec78acf4 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 27 May 2015 15:25:59 -0500 Subject: [PATCH 0085/1694] corrections to options update --- admin/tab-options.php | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/admin/tab-options.php b/admin/tab-options.php index c52deb73..b9b4e915 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -91,9 +91,9 @@ function wpmem_a_build_options() { // Show Excerpts, Login Form, and Registration Form option groups. $option_group_array = array( - 'excerpt' => 'Show Excerpts', - 'login' => 'Show Login Form', - 'reg' => 'Show Registration Form', + 'show_excerpt' => 'Show Excerpts', + 'show_login' => 'Show Login Form', + 'show_reg' => 'Show Registration Form', ); foreach ( $option_group_array as $item_key => $item_val ) { @@ -102,7 +102,7 @@ function wpmem_a_build_options() { foreach ( $post_arr as $key => $val ) { ?> > - block[ $key ] ) && $wpmem->block[ $key ] == 1 ) ? "checked" : ''; ?> /> + {$item_key}[ $key ] ); ?> /> $val ) { + $wpmem->$key = $val; + } return __( 'WP-Members settings were updated', 'wp-members' ); } From e7b5b4d092cb6ac941ed5968b048c0b80b338f4e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 27 May 2015 15:26:27 -0500 Subject: [PATCH 0086/1694] updated login form function for turn off forms option --- inc/forms.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/inc/forms.php b/inc/forms.php index 4c305fce..976cb6df 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -41,12 +41,12 @@ */ function wpmem_inc_login( $page="page", $redirect_to = null ) { - global $wpmem_regchk; + global $wpmem, $wpmem_regchk, $post; $str = ''; if ( $page == "page" ){ - if ( $wpmem_regchk!="success" ){ + if ( $wpmem_regchk != "success" ){ $arr = get_option( 'wpmembers_dialogs' ); @@ -111,7 +111,7 @@ function wpmem_inc_login( $page="page", $redirect_to = null ) { $arr = wp_parse_args( $args, $defaults ); - $str = $str . wpmem_login_form( $page, $arr ); + $str = ( $wpmem->show_login[ $post->post_type ] == 1 ) ? $str . wpmem_login_form( $page, $arr ) : $str; return $str; } From e2ca119a03d89ce2e32661546370ffd79cbdaa6a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 28 May 2015 11:02:22 -0500 Subject: [PATCH 0087/1694] code standards --- admin/admin.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index 3ee16f57..f9c96cdf 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -64,7 +64,9 @@ function wpmem_a_do_field_reorder(){ */ function wpmem_admin_plugin_links( $links, $file ) { static $wpmem_plugin; - if ( !$wpmem_plugin ) $wpmem_plugin = plugin_basename( 'wp-members/wp-members.php' ); + if ( ! $wpmem_plugin ) { + $wpmem_plugin = plugin_basename( 'wp-members/wp-members.php' ); + } if ( $file == $wpmem_plugin ) { $settings_link = '' . __( 'Settings' ) . ''; $links = array_merge( array( $settings_link ), $links ); @@ -285,4 +287,4 @@ function wpmem_admin_add_new_user() { return; } -/** End of File **/ \ No newline at end of file +// End of File. \ No newline at end of file From 6509f77c3a16e8ed897e339c956e667e961722a8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 28 May 2015 11:03:01 -0500 Subject: [PATCH 0088/1694] support for custom post types, adding meta box for individual blocking/unblocking --- admin/post.php | 44 +++++++++++++++++++++++++------------------- 1 file changed, 25 insertions(+), 19 deletions(-) diff --git a/admin/post.php b/admin/post.php index 498025e9..8adc43bb 100644 --- a/admin/post.php +++ b/admin/post.php @@ -146,26 +146,32 @@ function wpmem_posts_admin_notices() { */ function wpmem_block_meta_add() { - /** - * Filter the post meta box title. - * - * @since 2.9.0 - * - * @param Post restriction title. - */ - $post_title = apply_filters( 'wpmem_admin_post_meta_title', __( 'Post Restriction', 'wp-members' ) ); - - /** - * Filter the page meta box title. - * - * @since 2.9.0 - * - * @param Page restriction title. - */ - $page_title = apply_filters( 'wpmem_admin_page_meta_title', __( 'Page Restriction', 'wp-members' ) ); + // Build an array of post types + $post_types = get_post_types( array( 'public' => true, '_builtin' => false ), 'names', 'and' ); + $post_arr = array( + 'post' => 'Posts', + 'page' => 'Pages', + ); + if ( $post_types ) { + foreach ( $post_types as $post_type ) { + $cpt_obj = get_post_type_object( $post_type ); + $post_arr[ $cpt_obj->name ] = $cpt_obj->labels->name; + } + } - add_meta_box( 'wpmem-block-meta-id', $post_title, 'wpmem_block_meta', 'post', 'side', 'high' ); - add_meta_box( 'wpmem-block-meta-id', $page_title, 'wpmem_block_meta', 'page', 'side', 'high' ); + foreach ( $post_arr as $key => $val ) { + + /** + * Filter the post meta box title. + * + * @since 2.9.0 + * + * @param Post restriction title. + */ + $post_title = apply_filters( 'wpmem_admin_' . $key . '_meta_title', __( $val . ' Restriction', 'wp-members' ) ); + + add_meta_box( 'wpmem-block-meta-id', $post_title, 'wpmem_block_meta', $key, 'side', 'high' ); + } } From f92e9449bacef38147d488ec33c8556d02a91481 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 28 May 2015 11:03:26 -0500 Subject: [PATCH 0089/1694] updated readme, set alpha version number 1 --- readme.txt | 6 ++++-- wp-members.php | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/readme.txt b/readme.txt index 3dd49392..b993ab7a 100644 --- a/readme.txt +++ b/readme.txt @@ -140,8 +140,10 @@ WP-Members 2.9.9 is mostly minor updates preparing codebase for the 3.0 project. * added new|edit toggle to wpmem-register_data filter hook. * wpmem_settings_loaded action added. * securify comments changed to use comments_open instead of comments_template (with a blank template). -* registration clear form button defaults to false -* removed wp_set_auth_cookie from login function; it is already done as part of wp_signon +* registration clear form button defaults to false. +* removed wp_set_auth_cookie from login function; it is already done as part of wp_signon. +* added support for custom post types, both setting defaults and individual post blocking. +* post meta box title filter is now for all post types wpmem_admin_{post type}_meta_title. = 2.9.9 = * Code standards in wp-members-email.php diff --git a/wp-members.php b/wp-members.php index 371ff2a0..29ddc971 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0 build 2.9.9.1 base +Version: 3.0 alpha 1 Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0 build 2.9.9.1 base' ); +define( 'WPMEM_VERSION', '3.0 alpha 1' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 5ff2c4a1de3412d51d79b50e56c13ebe3c2f1128 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 28 May 2015 11:53:59 -0500 Subject: [PATCH 0090/1694] install for alpha testing --- wp-members-install.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wp-members-install.php b/wp-members-install.php index d398d919..c118fcc4 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -82,8 +82,9 @@ function wpmem_do_install() { 'attrib' => 0, ); + // Using update_option to allow for forced update. update_option( 'wpmembers_settings', $wpmem_settings, '', 'yes' ); - + /* * Field array elements: * From fb9e503854ec1da44691ebb9b4f5a8b49b623448 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 28 May 2015 13:59:33 -0500 Subject: [PATCH 0091/1694] fixes to shortcode js for old tinymce --- js/shortcodes_tinymce.js | 365 ++++----------------------------------- 1 file changed, 30 insertions(+), 335 deletions(-) diff --git a/js/shortcodes_tinymce.js b/js/shortcodes_tinymce.js index f097c87d..71e2cbd4 100644 --- a/js/shortcodes_tinymce.js +++ b/js/shortcodes_tinymce.js @@ -1,9 +1,9 @@ (function () { "use strict"; - tinymce.create('tinymce.plugins.wcShortcodeMce', { + tinymce.create('tinymce.plugins.wpmemShortcodeMce', { init : function(ed, url){ - tinymce.plugins.wcShortcodeMce.theurl = url; + tinymce.plugins.wpmemShortcodeMce.theurl = url; }, createControl : function(btn, e) { if ( btn === "wpmem_shortcodes_button" ) { @@ -14,108 +14,56 @@ btn = e.createMenuButton('wpmem_shortcodes_button', { title: "Insert Shortcode", - image: tinymce.plugins.wcShortcodeMce.theurl +"/images/shortcodes.png", + image: tinymce.plugins.wpmemShortcodeMce.theurl +"/images/shortcodes.png", icons: false, }); btn.onRenderMenu.add(function (c, b) { - b.add({title : 'WC Shortcodes', 'class' : 'mceMenuItemTitle'}).setDisabled(1); + b.add({title : 'WP-Members Shortcodes', 'class' : 'mceMenuItemTitle'}).setDisabled(1); - // Columns - c = b.addMenu({title:"Columns"}); + // Login Forms + c = b.addMenu({title:"Login Forms"}); - a.render( c, "1/2 + 1/2", "half-half" ); - a.render( c, "1/3 + 1/3 + 1/3", "third-third-third" ); - a.render( c, "1/3 + 2/3", "third-twothird" ); - a.render( c, "2/3 + 1/3", "twothird-third" ); - a.render( c, "1/4 + 1/4 + 1/4 + 1/4", "fourth-fourth-fourth-fourth" ); - a.render( c, "1/4 + 1/2 + 1/4", "fourth-half-fourth" ); - a.render( c, "1/2 + 1/4 + 1/4", "half-fourth-fourth" ); - a.render( c, "1/4 + 1/4 + 1/2", "fourth-fourth-half" ); - a.render( c, "1/4 + 3/4", "fourth-three-fourth" ); - a.render( c, "3/4 + 1/4", "three-fourth-fourth" ); + a.render( c, "login", "login" ); b.addSeparator(); - // Elements - c = b.addMenu({title:"Elements"}); + // Registration Forms + c = b.addMenu({title:"Registration Forms"}); - a.render( c, "Posts", "posts" ); - a.render( c, "Button", "button" ); - a.render( c, "Google Map", "googlemap" ); - a.render( c, "Heading", "heading" ); - a.render( c, "Pricing Table", "pricing" ); - a.render( c, "Skillbar", "skillbar" ); - a.render( c, "Social Icon", "social" ); - a.render( c, "Testimonial", "testimonial" ); - a.render( c, "Image", "image" ); - a.render( c, "Countdown", "countdown" ); - a.render( c, "RSVP", "rsvp" ); - a.render( c, "HTML", "html" ); + a.render( c, "register", "register" ); b.addSeparator(); - // Boxes - c = b.addMenu({title:"Boxes"}); - - a.render( c, "Primary", "primaryBox" ); - a.render( c, "Secondary", "secondaryBox" ); - a.render( c, "Inverse", "inverseBox" ); - a.render( c, "Success", "successBox" ); - a.render( c, "Warning", "warningBox" ); - a.render( c, "Danger", "dangerBox" ); - a.render( c, "Info", "infoBox" ); + // Other Forms + c = b.addMenu({title:"Other Forms"}); b.addSeparator(); - // Highlights - c = b.addMenu({title:"Highlights"}); - - a.render( c, "Blue", "blueHighlight" ); - a.render( c, "Gray", "grayHighlight" ); - a.render( c, "Green", "greenHighlight" ); - a.render( c, "Red", "redHighlight" ); - a.render( c, "Yellow", "yellowHighlight" ); + // Content Restriction + c = b.addMenu({title:"Content Restriction"}); b.addSeparator(); - // Dividers - c = b.addMenu({title:"Dividers"}); + // Logout Link + c = b.addMenu({title:"Logout Link"}); - a.render( c, "Solid", "solidDivider" ); - a.render( c, "Dashed", "dashedDivider" ); - a.render( c, "Dotted", "dottedDivider" ); - a.render( c, "Double", "doubleDivider" ); - a.render( c, "Image1", "imageDivider" ); - a.render( c, "Image2", "imageDivider2" ); - a.render( c, "Image3", "imageDivider3" ); b.addSeparator(); - // jQuery - c = b.addMenu({title:"jQuery"}); - - a.render( c, "Accordion", "accordion" ); - a.render( c, "Tabs", "tabs" ); - a.render( c, "Toggle", "toggle" ); + // User Fields + c = b.addMenu({title:"User Fields"}); + b.addSeparator(); - // Helpers - c = b.addMenu({title:"Other"}); - - a.render( c, "Spacing", "spacing" ); - a.render( c, "Clear Floats", "clear" ); - a.render( c, "Center Content", "center" ); - a.render( c, "Full Width", "fullwidth" ); - a.render( c, "Code", "code" ); - a.render( c, "Pre", "pre" ); - + // User Count + c = b.addMenu({title:"User Count"}); }); @@ -129,273 +77,20 @@ title: title, onclick: function () { - // Selected content var mceSelected = tinyMCE.activeEditor.selection.getContent(); - - // Add highlighted content inside the shortcode when possible - yay! - var wcDummyContent; + + var wpmemDummyContent; if ( mceSelected ) { - wcDummyContent = mceSelected; - } else { - wcDummyContent = 'Sample Content'; - } - var wcParagraphContent = '

    Sample Content

    '; - - // Accordion - if(id === "accordion") { - tinyMCE.activeEditor.selection.setContent('

    [wc_accordion collapse="0"]

    [wc_accordion_section title="Section 1"]

    ' + wcParagraphContent + '

    [/wc_accordion_section]

    [wc_accordion_section title="Section 2"]

    ' + wcParagraphContent + '

    [/wc_accordion_section]

    [/wc_accordion]

    '); - } - - - - - // Boxes - if(id === "primaryBox") { - tinyMCE.activeEditor.selection.setContent('[wc_box color="primary" text_align="left"]' + wcDummyContent + '[/wc_box]'); - } - if(id === "secondaryBox") { - tinyMCE.activeEditor.selection.setContent('[wc_box color="secondary" text_align="left"]' + wcDummyContent + '[/wc_box]'); - } - if(id === "inverseBox") { - tinyMCE.activeEditor.selection.setContent('[wc_box color="inverse" text_align="left"]' + wcDummyContent + '[/wc_box]'); - } - if(id === "successBox") { - tinyMCE.activeEditor.selection.setContent('[wc_box color="success" text_align="left"]' + wcDummyContent + '[/wc_box]'); - } - if(id === "warningBox") { - tinyMCE.activeEditor.selection.setContent('[wc_box color="warning" text_align="left"]' + wcDummyContent + '[/wc_box]'); + wpmemDummyContent = mceSelected; } - if(id === "dangerBox") { - tinyMCE.activeEditor.selection.setContent('[wc_box color="danger" text_align="left"]' + wcDummyContent + '[/wc_box]'); - } - if(id === "infoBox") { - tinyMCE.activeEditor.selection.setContent('[wc_box color="info" text_align="left"]' + wcDummyContent + '[/wc_box]'); - } - - - - - // Image - if(id === "image") { - tinyMCE.activeEditor.selection.setContent('[wc_image attachment_id="" size="" title="" alt="" caption="" link_to="post" url="" align="none" flag="For Sale" left="" top="" right="0" bottom="20" text_color="" background_color="" font_size=""][/wc_image]'); - } - - - - - - // Posts - if(id === "posts") { - tinyMCE.activeEditor.selection.setContent('[wc_posts author="" author_name="" p="" post__in="" order="DESC" orderby="date" post_status="publish" post_type="post" posts_per_page="10" taxonomy="" field="slug" terms="" title="yes" meta_all="yes" meta_author="yes" meta_date="yes" meta_comments="yes" thumbnail="yes" content="yes" paging="yes" size="large" filtering="yes" columns="3" gutter_space="20" heading_type="h2" layout="isotope"][/wc_posts]'); - } - - - - - // Button - if(id === "button") { - tinyMCE.activeEditor.selection.setContent('[wc_button type="primary" url="http://webplantmedia.com" title="Visit Site" target="self" position="float"]' + wcDummyContent + '[/wc_button]'); - } - - - - - // Clear Floats - if(id === "clear") { - tinyMCE.activeEditor.selection.setContent('[wc_clear_floats]'); - } - - - - - // Columns - if(id === "half-half") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-half" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-half" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - if(id === "third-third-third") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-third" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-third"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-third" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - if(id === "third-twothird") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-third" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="two-third" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - if(id === "twothird-third") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="two-third" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-third" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - if(id === "fourth-fourth-fourth-fourth") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - if(id === "fourth-half-fourth") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-half"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - if(id === "half-fourth-fourth") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-half" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - if(id === "fourth-fourth-half") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-half" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - if(id === "fourth-three-fourth") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="one-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="three-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - if(id === "three-fourth-fourth") { - tinyMCE.activeEditor.selection.setContent('

    [wc_row][wc_column size="three-fourth" position="first"]

    ' + wcParagraphContent + '

    [/wc_column][wc_column size="one-fourth" position="last"]

    ' + wcParagraphContent + '

    [/wc_column][/wc_row]

    '); - } - - - // Divider - if(id === "solidDivider") { - tinyMCE.activeEditor.selection.setContent('[wc_divider style="solid" line="single" margin_top="" margin_bottom=""]'); - } - if(id === "dashedDivider") { - tinyMCE.activeEditor.selection.setContent('[wc_divider style="dashed" line="single" margin_top="" margin_bottom=""]'); - } - if(id === "dottedDivider") { - tinyMCE.activeEditor.selection.setContent('[wc_divider style="dotted" line="single" margin_top="" margin_bottom=""]'); - } - if(id === "doubleDivider") { - tinyMCE.activeEditor.selection.setContent('[wc_divider style="solid" line="double" margin_top="" margin_bottom=""]'); - } - if(id === "tripleDivider") { - tinyMCE.activeEditor.selection.setContent('[wc_divider style="solid" line="triple" margin_top="" margin_bottom=""]'); + if(id === "login") { + tinyMCE.activeEditor.selection.setContent('[wpmem_form login]'); } - if(id === "imageDivider") { - tinyMCE.activeEditor.selection.setContent('[wc_divider style="image" margin_top="" margin_bottom=""]'); + if(id === "register") { + tinyMCE.activeEditor.selection.setContent('[wpmem_form register]'); } - if(id === "imageDivider2") { - tinyMCE.activeEditor.selection.setContent('[wc_divider style="image2" margin_top="" margin_bottom=""]'); - } - if(id === "imageDivider3") { - tinyMCE.activeEditor.selection.setContent('[wc_divider style="image3" margin_top="" margin_bottom=""]'); - } - - - - - // Google Map - if(id === "googlemap") { - tinyMCE.activeEditor.selection.setContent('[wc_googlemap title="St. Paul\'s Chapel" location="209 Broadway, New York, NY 10007" zoom="10" height="250" title_on_load="no" class=""]'); - } - - - - - // Heading - if(id === "heading") { - tinyMCE.activeEditor.selection.setContent('[wc_heading type="h1" title="' + wcDummyContent + '" text_align="left"]'); - } - - - - - // Highlight - if(id === "blueHighlight") { - tinyMCE.activeEditor.selection.setContent('[wc_highlight color="blue"]' + wcDummyContent + '[/wc_highlight]'); - } - if(id === "grayHighlight") { - tinyMCE.activeEditor.selection.setContent('[wc_highlight color="gray"]' + wcDummyContent + '[/wc_highlight]'); - } - if(id === "greenHighlight") { - tinyMCE.activeEditor.selection.setContent('[wc_highlight color="green"]' + wcDummyContent + '[/wc_highlight]'); - } - if(id === "redHighlight") { - tinyMCE.activeEditor.selection.setContent('[wc_highlight color="red"]' + wcDummyContent + '[/wc_highlight]'); - } - if(id === "yellowHighlight") { - tinyMCE.activeEditor.selection.setContent('[wc_highlight color="yellow"]' + wcDummyContent + '[/wc_highlight]'); - } - - - - // Pricing - if(id === "pricing") { - tinyMCE.activeEditor.selection.setContent('[wc_pricing type="primary" featured="yes" plan="Basic" cost="$19.99" per="per month" button_url="#" button_text="Sign Up" button_target="self" button_rel="nofollow"]
    • 30GB Storage
    • 512MB Ram
    • 10 databases
    • 1,000 Emails
    • 25GB Bandwidth
    [/wc_pricing]'); - } - - - - - //Spacing - if(id === "spacing") { - tinyMCE.activeEditor.selection.setContent('[wc_spacing size="40px"]'); - } - - - - - //Social - if(id === "social") { - tinyMCE.activeEditor.selection.setContent('[wc_social_icons align="left" size="large" display="facebook,google,twitter,pinterest,instagram,bloglovin,flickr,rss,email,custom1,custom2,custom3,custom4,custom5"]'); - } - - - - - //Skillbar - if(id === "skillbar") { - tinyMCE.activeEditor.selection.setContent('[wc_skillbar title="' + wcDummyContent + '" percentage="100" color="#6adcfa"]'); - } - - - - - //Tabs - if(id === "tabs") { - tinyMCE.activeEditor.selection.setContent('

    [wc_tabgroup][wc_tab title="First Tab"]

    '+wcParagraphContent+'

    [/wc_tab][wc_tab title="Second Tab"]

    '+wcParagraphContent+'

    [/wc_tab][/wc_tabgroup]

    '); - } - - - - //Testimonial - if(id === "testimonial") { - tinyMCE.activeEditor.selection.setContent('[wc_testimonial by="Author" url="" position="left"]' + wcDummyContent + '[/wc_testimonial]'); - } - - - - //RSVP - if(id === "rsvp") { - tinyMCE.activeEditor.selection.setContent('[wc_rsvp columns="3" align="left" button_align="center"]'); - } - - - - //Countdown - if(id === "countdown") { - var d = new Date(); - var year = d.getFullYear() + 1; - tinyMCE.activeEditor.selection.setContent('[wc_countdown date="July 23, '+year+', 6:00:00 PM" format="wdHMs" message="Your Message Here!" labels="Years,Months,Weeks,Days,Hours,Minutes,Seconds" labels1="Year,Month,Week,Day,Hour,Minute,Second"]'); - } - - - //Toggle - if(id === "toggle") { - tinyMCE.activeEditor.selection.setContent('

    [wc_toggle title="This Is Your Toggle Title" padding="" border_width=""]

    ' + wcParagraphContent + '

    [/wc_toggle]

    '); - } - - if(id === "center") { - tinyMCE.activeEditor.selection.setContent('

    [wc_center max_width="500px" text_align="left"]

    ' + wcParagraphContent + '

    [/wc_center]

    '); - } - - - if(id === "fullwidth") { - tinyMCE.activeEditor.selection.setContent('[wc_fullwidth selector="#main"]' + wcDummyContent + '[/wc_fullwidth]'); - } - - - if(id === "html") { - tinyMCE.activeEditor.selection.setContent('[wc_html name="Custom Field Name"]'); - } - - - if(id === "code") { - tinyMCE.activeEditor.selection.setContent('[wc_code]' + wcDummyContent + '[/wc_code]'); - } - - - if(id === "pre") { - tinyMCE.activeEditor.selection.setContent('[wc_pre color="1" wrap="0" scrollable="1" linenums="0" name="Custom Field Name"]'); - } - + return false; } @@ -403,5 +98,5 @@ } }); - tinymce.PluginManager.add("wpmem_shortcodes", tinymce.plugins.wcShortcodeMce); + tinymce.PluginManager.add("wpmem_shortcodes", tinymce.plugins.wpmemShortcodeMce); })(); From cf9ca7b48d3239afc0a8f9eda6edadffd9c6f88f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 29 May 2015 09:21:22 -0500 Subject: [PATCH 0092/1694] added tinymce loader function --- admin/post.php | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/admin/post.php b/admin/post.php index 8adc43bb..3f3ab1cb 100644 --- a/admin/post.php +++ b/admin/post.php @@ -23,6 +23,7 @@ * - wpmem_block_meta_save * - wpmem_post_columns * - wpmem_post_columns_content + * - wpmem_load_tinymce */ @@ -32,6 +33,7 @@ add_action( 'admin_footer-edit.php', 'wpmem_bulk_posts_action' ); add_action( 'load-edit.php', 'wpmem_posts_page_load' ); add_action( 'admin_notices', 'wpmem_posts_admin_notices' ); +add_action( 'load-post.php', 'wpmem_load_tinymce' ); /** @@ -331,4 +333,16 @@ function wpmem_post_columns_content( $column_name, $post_ID ) { } } -/** End of File **/ \ No newline at end of file + +/** + * Adds shortcode dropdown to post editor tinymce. + * + * @since 3.0 + */ +function wpmem_load_tinymce() { + global $wpmem_shortcode; + include( WPMEM_PATH . 'inc/class-wp-members-tinymce-buttons.php' ); + $wpmem_shortcode = new WP_Members_TinyMCE_Buttons; +} + +// End of File. \ No newline at end of file From 0fc1b54d30f5b966673fbad8fa924c2813249beb Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 8 Jun 2015 10:17:14 -0500 Subject: [PATCH 0093/1694] query vars patch for default permalinks --- inc/class-wp-members.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 29c4a66a..debefd57 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -328,7 +328,7 @@ function do_securify( $content = null ) { // Toggle shows excerpt above login/reg on posts/pages. global $wp_query; - if ( $wp_query->query_vars['page'] > 1 ) { + if ( isset( $wp_query->query_vars['page'] ) && $wp_query->query_vars['page'] > 1 ) { // Shuts down excerpts on multipage posts if not on first page. $content = ''; From 793383aef643ae81e909f607ee1582a54d0e1fe9 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 8 Jun 2015 10:17:39 -0500 Subject: [PATCH 0094/1694] added .link-text class to 2013 stylesheet --- css/wp-members-2013.css | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/css/wp-members-2013.css b/css/wp-members-2013.css index 5c8af2d7..cfd14ee0 100644 --- a/css/wp-members-2013.css +++ b/css/wp-members-2013.css @@ -174,6 +174,11 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ #wpmem_reg .captcha table{ line-height: 0px; } +#wpmem_login .link-text { + float:right; + width:100%; +} + /** for smaller screens */ From ee5e7feb6371da8ede56927db4921b0815aa6301 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 8 Jun 2015 14:01:58 -0500 Subject: [PATCH 0095/1694] added redirect_to as a function argument --- inc/core.php | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/inc/core.php b/inc/core.php index 40edc8b9..1fac3b92 100644 --- a/inc/core.php +++ b/inc/core.php @@ -181,21 +181,25 @@ function wpmem_login() { * * @since 2.0 * - * @uses wp_clearcookie - * @uses wp_logout - * @uses nocache_headers - * @uses wp_redirect + * @uses wp_clearcookie + * @uses wp_logout + * @uses nocache_headers + * @uses wp_redirect + * @param string $redirect_to The URL to redirect to at logout. */ -function wpmem_logout() { +function wpmem_logout( $redirect_to = null ) { + + // Default redirect URL. + $redirect_to = ( $redirect_to ) ? $redirect_to : get_bloginfo( 'url' ); /** - * Filter the where the user goes when logged out. + * Filter where the user goes when logged out. * * @since 2.7.1 * * @param string The blog home page. */ - $redirect_to = apply_filters( 'wpmem_logout_redirect', get_bloginfo( 'url' ) ); + $redirect_to = apply_filters( 'wpmem_logout_redirect', $redirect_to ); wp_clear_auth_cookie(); From 609d467bd8c7c675f99c04d367b38a2ef50db0f9 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 8 Jun 2015 14:02:30 -0500 Subject: [PATCH 0096/1694] fix if there is no setting for custom post types --- admin/tab-options.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/admin/tab-options.php b/admin/tab-options.php index b9b4e915..879a65bc 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -81,7 +81,7 @@ function wpmem_a_build_options() { @@ -99,10 +99,12 @@ function wpmem_a_build_options() { foreach ( $option_group_array as $item_key => $item_val ) { $i = 0; $len = count( $post_arr ); - foreach ( $post_arr as $key => $val ) { ?> + foreach ( $post_arr as $key => $val ) { + $setting = ( isset( $wpmem->{$item_key}[ $key ] ) ) ? $wpmem->{$item_key}[ $key ] : 0; + ?> > - {$item_key}[ $key ] ); ?> /> + /> Date: Mon, 8 Jun 2015 14:03:09 -0500 Subject: [PATCH 0097/1694] fix for default logout link --- inc/utilities.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/utilities.php b/inc/utilities.php index 0f4cfd52..f977d9ae 100644 --- a/inc/utilities.php +++ b/inc/utilities.php @@ -133,7 +133,7 @@ function wpmem_chk_qstr( $url = null ) { $url = ( ! $url ) ? get_option( 'home' ) . "/?" . $_SERVER['QUERY_STRING'] : ''; $return_url = $url . "&"; } else { - $url = ( ! $url ) ? get_permalink() : ''; + $url = ( ! $url ) ? get_permalink() : $url; $return_url = $url . "?"; } return $return_url; From a39a4643c12416f185321a78de55bfd8e353d158 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 8 Jun 2015 14:03:43 -0500 Subject: [PATCH 0098/1694] fix if there are no wp-members columns set for users > all users screen --- inc/class-wp-members-sortable-user-columns.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/class-wp-members-sortable-user-columns.php b/inc/class-wp-members-sortable-user-columns.php index 7fbae71f..8f2fe5ef 100644 --- a/inc/class-wp-members-sortable-user-columns.php +++ b/inc/class-wp-members-sortable-user-columns.php @@ -25,7 +25,7 @@ class WP_Members_Sortable_User_Columns { ); function __construct( $args ) { - $this->args = $args; + $this->args = ( is_array( $args ) ) ? $args : array(); add_action( 'pre_user_query', array( &$this, 'query' ) ); add_action( 'manage_users_custom_column', array( &$this, 'content' ), 10, 3 ); add_filter( 'manage_users_columns', array( &$this, 'columns' ) ); From 8a4703b5238d2ee93f07acdff49d58bb42a94df3 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 8 Jun 2015 15:21:19 -0500 Subject: [PATCH 0099/1694] moving from alpha to beta release status --- wp-members.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-members.php b/wp-members.php index 29ddc971..501e40cd 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0 alpha 1 +Version: 3.0 beta 1 Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0 alpha 1' ); +define( 'WPMEM_VERSION', '3.0 beta 1' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 51eb9428f64a4c6d998c2579cba1221082749d73 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 13 Jun 2015 13:04:28 -0500 Subject: [PATCH 0100/1694] added 3.0 beta information --- README.md | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 11099900..6edc9789 100644 --- a/README.md +++ b/README.md @@ -4,17 +4,13 @@ WP-Members™ is a free membership management framework for WordPress® t ## Description ## -This is the "bleeding edge" repository for the WP-Members plugin for WordPress. - -There are currently two branches here. One is the 3.0 branch build. The master branch is the 3.0 (very) alpha version built on the 2.9.9.1 base code. +This is the beta release repository for the WP-Members plugin for WordPress.. ## Usage Information ## If you are looking for a production ready version of the plugin, use the 2.9.9.1 version hosted here: http://wordpress.org/extend/plugins/wp-members/ -If you are testing 3.0, you can try one of the two branches hosted here, as follows: - -1. If you are trying it on a site that you might revert to 2.9.9.1, then use the master branch. I have made adjustments to the install in this branch to keep the previous settings intact. The final 3.0 will use new settings which will update and overwrite current settings of earlier versions. So if you might roll-back, you need the 3.0 build on 2.9.9.1 code base. +This branch is the 3.0 release candidate, currently tagged as a beta version. Keep in mind that this is beta, so it should be tested prior to loading to a production site -2. If you are testing on a test site that will not need to roll back, you can use the 3.0 branch or the master branch. 3.0 is the development branch, so at any given time, it may or may not be completely stable and debugged. \ No newline at end of file +If you are trying it on a site that you might revert to 2.9.9.1, I have made adjustments to the install in this branch to keep the previous (2.x compliant) settings intact. The final 3.0 will use new settings which will update and overwrite current settings of earlier versions. From a911e7ab8c1a6f6a4cae13c429f339105e522542 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 15 Jun 2015 15:16:22 -0500 Subject: [PATCH 0101/1694] todo for user export --- admin/user-export.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/admin/user-export.php b/admin/user-export.php index 62da910e..83fa301c 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -96,10 +96,11 @@ function wpmem_export_users( $args, $users = null ) { $user_info = get_userdata( $user ); $data .= '"' . $user_info->ID . '","' . $user_info->user_login . '",'; - + $wp_user_fields = array( 'user_email', 'user_nicename', 'user_url', 'display_name' ); foreach ( $wpmem_fields as $meta ) { if ( ! in_array( $meta[2], $exclude_fields ) ) { + // @todo Research using fputcsv to escape fields for export. if ( in_array( $meta[2], $wp_user_fields ) ){ $data .= '"' . $user_info->$meta[2] . '",'; } else { From dc25ea1c36db0ba09aeb13843fda0169dac02a70 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 15 Jun 2015 15:16:57 -0500 Subject: [PATCH 0102/1694] tinymce button cleanup --- admin/post.php | 9 ++++++--- js/shortcodes_tinymce_4.js | 8 +++++--- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/admin/post.php b/admin/post.php index 3f3ab1cb..35d3598f 100644 --- a/admin/post.php +++ b/admin/post.php @@ -340,9 +340,12 @@ function wpmem_post_columns_content( $column_name, $post_ID ) { * @since 3.0 */ function wpmem_load_tinymce() { - global $wpmem_shortcode; - include( WPMEM_PATH . 'inc/class-wp-members-tinymce-buttons.php' ); - $wpmem_shortcode = new WP_Members_TinyMCE_Buttons; + // @todo For now, only load if WP version is high enough. + if ( version_compare( get_bloginfo( 'version' ), '3.9', '>=' ) ) { + global $wpmem_shortcode; + include( WPMEM_PATH . 'inc/class-wp-members-tinymce-buttons.php' ); + $wpmem_shortcode = new WP_Members_TinyMCE_Buttons; + } } // End of File. \ No newline at end of file diff --git a/js/shortcodes_tinymce_4.js b/js/shortcodes_tinymce_4.js index 27713685..4bdc547e 100644 --- a/js/shortcodes_tinymce_4.js +++ b/js/shortcodes_tinymce_4.js @@ -8,12 +8,14 @@ editor.addButton('wpmem_shortcodes_button', function() { return { - title: "", - text: "[WP-Members Shortcodes]", - image: url + "/images/shortcodes.png", + title: "WP-Members Shortcodes", + text: "[ ]", type: 'menubutton', icons: false, menu: [ + { + text: 'WP-Members Shortcodes', + }, { text: 'Login Forms', menu: [ From 710056bbaf0da9286487fdf3e8cff797f680358e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 16 Jun 2015 12:27:23 -0500 Subject: [PATCH 0103/1694] added legacy constants, will be deprecated later --- inc/class-wp-members.php | 24 ++++++++++++++++++++++++ wp-members.php | 3 +++ 2 files changed, 27 insertions(+) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index debefd57..504bdef2 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -127,6 +127,30 @@ function load_dropins() { do_action( 'wpmem_load_dropins' ); } + /** + * Loads pre-3.0 constants (included primarily for add-on compatibility). + * + * @since 3.0 + */ + function load_contants() { + ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $this->block['post'] ) : ''; + ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $this->block['page'] ) : ''; + ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $this->show_excerpt['post'] ) : ''; + ( ! defined( 'WPMEM_NOTIFY_ADMIN' ) ) ? define( 'WPMEM_NOTIFY_ADMIN', $this->notify ) : ''; + ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $this->mod_reg ) : ''; + ( ! defined( 'WPMEM_CAPTCHA' ) ) ? define( 'WPMEM_CAPTCHA', $this->captcha ) : ''; + ( ! defined( 'WPMEM_NO_REG' ) ) ? define( 'WPMEM_NO_REG', ( -1 * $this->show_reg['post'] ) ) : ''; + ( ! defined( 'WPMEM_USE_EXP' ) ) ? define( 'WPMEM_USE_EXP', $this->use_exp ) : ''; + ( ! defined( 'WPMEM_USE_TRL' ) ) ? define( 'WPMEM_USE_TRL', $this->use_trial ) : ''; + ( ! defined( 'WPMEM_IGNORE_WARN' ) ) ? define( 'WPMEM_IGNORE_WARN', $this->warnings ) : ''; + + ( ! defined( 'WPMEM_MSURL' ) ) ? define( 'WPMEM_MSURL', $this->user_pages['profile'] ) : ''; + ( ! defined( 'WPMEM_REGURL' ) ) ? define( 'WPMEM_REGURL', $this->user_pages['register'] ) : ''; + ( ! defined( 'WPMEM_LOGURL' ) ) ? define( 'WPMEM_LOGURL', $this->user_pages['login'] ) : ''; + + define( 'WPMEM_CSSURL', $this->cssurl ); + } + /** * Gets the requested action. * diff --git a/wp-members.php b/wp-members.php index 501e40cd..ef423e71 100644 --- a/wp-members.php +++ b/wp-members.php @@ -137,6 +137,9 @@ function wpmem_init() { // Load fields. $wpmem->load_fields(); + + // Load contants. + $wpmem->load_contants(); /** * Fires after initialization of plugin options. From 947ed021466039adc49ced2aa9bd825a0b83189d Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 19 Jun 2015 15:58:39 -0500 Subject: [PATCH 0104/1694] added back wpmem_regchk global variable for legacy purposes --- admin/tab-options.php | 8 ++++---- inc/class-wp-members.php | 4 ++++ 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/admin/tab-options.php b/admin/tab-options.php index 879a65bc..9e6dec58 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -91,9 +91,9 @@ function wpmem_a_build_options() { // Show Excerpts, Login Form, and Registration Form option groups. $option_group_array = array( - 'show_excerpt' => 'Show Excerpts', - 'show_login' => 'Show Login Form', - 'show_reg' => 'Show Registration Form', + 'show_excerpt' => __( 'Show Excerpts', 'wp-members' ), + 'show_login' => __( 'Show Login Form', 'wp-members' ), + 'show_reg' => __( 'Show Registration Form', 'wp-members' ), ); foreach ( $option_group_array as $item_key => $item_val ) { @@ -111,7 +111,7 @@ function wpmem_a_build_options() { } ?> use_exp == true ) { + if ( WPMEM_EXP_MODULE == true ) { $arr = array( array(__('Time-based expiration','wp-members'),'wpmem_settings_time_exp',__('Allows for access to expire','wp-members'),'use_exp'), array(__('Trial period','wp-members'),'wpmem_settings_trial',__('Allows for a trial period','wp-members'),'use_trial'), diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 504bdef2..cc89f36d 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -219,6 +219,10 @@ function get_regchk( $action ) { */ $regchk = apply_filters( 'wpmem_regchk', $regchk, $action ); + // @todo Remove legacy global variable. + global $wpmem_regchk; + $wpmem_regchk = $regchk; + return $regchk; } From be31dccd718a028d79a5436c20ac25a2124a976d Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 19 Jun 2015 15:59:27 -0500 Subject: [PATCH 0105/1694] new translation template --- admin/admin.php | 2 +- lang/wp-members.pot | 887 +++++++++++++++++++++++++------------------- 2 files changed, 507 insertions(+), 382 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index f9c96cdf..2c0f134b 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -68,7 +68,7 @@ function wpmem_admin_plugin_links( $links, $file ) { $wpmem_plugin = plugin_basename( 'wp-members/wp-members.php' ); } if ( $file == $wpmem_plugin ) { - $settings_link = '' . __( 'Settings' ) . ''; + $settings_link = '' . __( 'Settings', 'wp-members' ) . ''; $links = array_merge( array( $settings_link ), $links ); } return $links; diff --git a/lang/wp-members.pot b/lang/wp-members.pot index b6bfeae8..82fc5a00 100644 --- a/lang/wp-members.pot +++ b/lang/wp-members.pot @@ -1,16 +1,13 @@ -# Copyright (C) 2014 WP-Members -# This file is distributed under the same license as the WP-Members package. msgid "" msgstr "" -"Project-Id-Version: WP-Members 2.9.5\n" -"Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2014-07-08 10:47-0600\n" +"Project-Id-Version: WP-Members\n" +"POT-Creation-Date: 2015-06-16 12:01-0600\n" +"PO-Revision-Date: 2015-06-16 12:01-0600\n" +"Last-Translator: \n" +"Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"PO-Revision-Date: 2014-07-08 10:50-0600\n" -"Last-Translator: \n" -"Language-Team: \n" "X-Generator: Poedit 1.6.4\n" "X-Poedit-Basepath: ..\n" "X-Poedit-SourceCharset: UTF-8\n" @@ -19,40 +16,40 @@ msgstr "" "_nx_noop:3c,1,2;__ngettext_noop:1,2\n" "X-Poedit-SearchPath-0: .\n" -#: admin/admin.php:60 admin/admin.php:129 +#: admin/admin.php:71 admin/admin.php:138 msgid "Settings" msgstr "" -#: admin/admin.php:187 +#: admin/admin.php:206 msgid "Options" msgstr "" -#: admin/admin.php:188 +#: admin/admin.php:207 msgid "Fields" msgstr "" -#: admin/admin.php:189 +#: admin/admin.php:208 msgid "Dialogs" msgstr "" -#: admin/admin.php:190 +#: admin/admin.php:209 msgid "Emails" msgstr "" -#: admin/dialogs.php:109 +#: admin/dialogs.php:103 msgid "" "Your WP settings allow anyone to register - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:110 +#: admin/dialogs.php:104 #, php-format msgid "" "You can %s change this here %s making sure the box next to \"Anyone can " "register\" is unchecked." msgstr "" -#: admin/dialogs.php:111 +#: admin/dialogs.php:105 msgid "" "This setting allows a link on the /wp-login.php page to register using the " "WP native registration process thus circumventing any registration you are " @@ -62,20 +59,20 @@ msgid "" "Settings." msgstr "" -#: admin/dialogs.php:117 +#: admin/dialogs.php:109 msgid "" "Your WP settings allow anyone to comment - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:118 +#: admin/dialogs.php:110 #, php-format msgid "" "You can %s change this here %s by checking the box next to \"Users must be " "registered and logged in to comment.\"" msgstr "" -#: admin/dialogs.php:119 +#: admin/dialogs.php:111 msgid "" "This setting allows any users to comment, whether or not they are " "registered. Depending on how you are using WP-Members will determine whether " @@ -83,138 +80,133 @@ msgid "" "you can choose to ignore these warning messages under WP-Members Settings." msgstr "" -#: admin/dialogs.php:125 +#: admin/dialogs.php:115 msgid "" "Your WP settings allow full text rss feeds - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:126 +#: admin/dialogs.php:116 #, php-format msgid "" "You can %s change this here %s by changing \"For each article in a feed, show" "\" to \"Summary.\"" msgstr "" -#: admin/dialogs.php:127 +#: admin/dialogs.php:117 msgid "" "Leaving this set to full text allows anyone to read your protected content " "in an RSS reader. Changing this to Summary prevents this as your feeds will " "only show summary text." msgstr "" -#: admin/dialogs.php:133 +#: admin/dialogs.php:121 msgid "You have set WP-Members to hold registrations for approval" msgstr "" -#: admin/dialogs.php:134 +#: admin/dialogs.php:122 msgid "" "but you have not changed the default message for \"Registration Completed\" " "under \"WP-Members Dialogs and Error Messages.\" You should change this " "message to let users know they are pending approval." msgstr "" -#: admin/dialogs.php:140 +#: admin/dialogs.php:126 msgid "You have set WP-Members to turn off the registration process" msgstr "" -#: admin/dialogs.php:141 +#: admin/dialogs.php:127 msgid "" "but you also set to moderate and/or email admin new registrations. You will " "need to set up a registration page for users to register." msgstr "" -#: admin/dialogs.php:147 +#: admin/dialogs.php:131 msgid "You have turned on reCAPTCHA" msgstr "" -#: admin/dialogs.php:148 +#: admin/dialogs.php:132 msgid "" "but you have not entered API keys. You will need both a public and private " "key. The CAPTCHA will not display unless a valid API key is included." msgstr "" -#: admin/dialogs.php:171 +#: admin/dialogs.php:156 msgid "Version:" msgstr "" -#: admin/dialogs.php:172 +#: admin/dialogs.php:157 msgid "Quick Start Guide" msgstr "" -#: admin/dialogs.php:173 +#: admin/dialogs.php:158 msgid "Online User Guide" msgstr "" -#: admin/dialogs.php:174 +#: admin/dialogs.php:159 msgid "FAQs" msgstr "" -#: admin/dialogs.php:181 +#: admin/dialogs.php:166 msgid "Thank you for using WP-Members" msgstr "" -#: admin/dialogs.php:182 +#: admin/dialogs.php:167 msgid "A plugin developed by" msgstr "" -#: admin/dialogs.php:183 +#: admin/dialogs.php:168 msgid "Follow" msgstr "" -#: admin/dialogs.php:200 admin/dialogs.php:204 +#: admin/dialogs.php:185 admin/dialogs.php:189 msgid "Latest from RocketGeek" msgstr "" -#: admin/dialogs.php:221 admin/dialogs.php:234 +#: admin/dialogs.php:206 admin/dialogs.php:219 msgid "Latest from ButlerBlog" msgstr "" -#: admin/post.php:36 admin/post.php:38 +#: admin/post.php:47 admin/post.php:49 admin/tab-options.php:83 msgid "Block" msgstr "" -#: admin/post.php:37 admin/post.php:39 +#: admin/post.php:48 admin/post.php:50 msgid "Unblock" msgstr "" -#: admin/post.php:120 -#, php-format -msgid "%s posts %sed." +#: admin/post.php:173 +msgid " Restriction" msgstr "" -#: admin/post.php:138 -msgid "Post Restriction" -msgstr "" - -#: admin/post.php:145 -msgid "Page Restriction" -msgstr "" - -#: admin/post.php:263 admin/post.php:295 +#: admin/post.php:301 msgid "Unblocked?" msgstr "" -#: admin/post.php:263 admin/post.php:295 +#: admin/post.php:301 msgid "Blocked?" msgstr "" -#: admin/tab-captcha.php:35 admin/tab-dialogs.php:44 admin/tab-emails.php:113 -#: admin/tab-fields.php:45 admin/tab-options.php:37 +#: admin/post.php:331 admin/post.php:332 admin/user-export.php:112 +msgid "Yes" +msgstr "" + +#: admin/tab-captcha.php:42 admin/tab-dialogs.php:48 admin/tab-emails.php:117 +#: admin/tab-fields.php:45 admin/tab-options.php:56 msgid "Need help?" msgstr "" -#: admin/tab-captcha.php:46 +#: admin/tab-captcha.php:53 msgid "Manage reCAPTCHA Options" msgstr "" -#: admin/tab-captcha.php:60 +#: admin/tab-captcha.php:63 msgid "" "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " "while blocking spam on your blog." msgstr "" -#: admin/tab-captcha.php:61 +#: admin/tab-captcha.php:64 #, php-format msgid "" "reCAPTCHA asks commenters to retype two words scanned from a book to prove " @@ -224,815 +216,892 @@ msgid "" "the %s reCAPTCHA website%s" msgstr "" -#: admin/tab-captcha.php:66 +#: admin/tab-captcha.php:69 msgid "reCAPTCHA Keys" msgstr "" -#: admin/tab-captcha.php:68 +#: admin/tab-captcha.php:71 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:69 +#: admin/tab-captcha.php:72 msgid "Public Key" msgstr "" -#: admin/tab-captcha.php:70 +#: admin/tab-captcha.php:73 msgid "Private Key" msgstr "" -#: admin/tab-captcha.php:74 +#: admin/tab-captcha.php:77 msgid "Choose Theme" msgstr "" -#: admin/tab-captcha.php:77 +#: admin/tab-captcha.php:80 msgid "Red" msgstr "" -#: admin/tab-captcha.php:78 +#: admin/tab-captcha.php:81 msgid "White" msgstr "" -#: admin/tab-captcha.php:79 +#: admin/tab-captcha.php:82 msgid "Black Glass" msgstr "" -#: admin/tab-captcha.php:80 +#: admin/tab-captcha.php:83 msgid "Clean" msgstr "" -#: admin/tab-captcha.php:112 +#: admin/tab-captcha.php:115 msgid "Characters for image" msgstr "" -#: admin/tab-captcha.php:116 +#: admin/tab-captcha.php:119 msgid "Number of characters" msgstr "" -#: admin/tab-captcha.php:120 +#: admin/tab-captcha.php:123 msgid "Image dimensions" msgstr "" #: admin/tab-captcha.php:124 +msgid "Width" +msgstr "" + +#: admin/tab-captcha.php:124 +msgid "Height" +msgstr "" + +#: admin/tab-captcha.php:127 msgid "Font color of characters" msgstr "" -#: admin/tab-captcha.php:128 +#: admin/tab-captcha.php:131 msgid "Background color of image" msgstr "" -#: admin/tab-captcha.php:132 +#: admin/tab-captcha.php:135 msgid "Font size" msgstr "" -#: admin/tab-captcha.php:136 +#: admin/tab-captcha.php:139 msgid "Width between characters" msgstr "" -#: admin/tab-captcha.php:140 +#: admin/tab-captcha.php:143 msgid "Image type" msgstr "" -#: admin/tab-captcha.php:154 +#: admin/tab-captcha.php:157 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: admin/tab-captcha.php:166 +#: admin/tab-captcha.php:169 msgid "Update CAPTCHA Settings" msgstr "" -#: admin/tab-captcha.php:230 +#: admin/tab-captcha.php:233 msgid "CAPTCHA was updated for WP-Members" msgstr "" -#: admin/tab-dialogs.php:29 +#: admin/tab-dialogs.php:33 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" -#: admin/tab-dialogs.php:30 +#: admin/tab-dialogs.php:34 msgid "Username is taken" msgstr "" -#: admin/tab-dialogs.php:31 +#: admin/tab-dialogs.php:35 msgid "Email is registered" msgstr "" -#: admin/tab-dialogs.php:32 +#: admin/tab-dialogs.php:36 msgid "Registration completed" msgstr "" -#: admin/tab-dialogs.php:33 +#: admin/tab-dialogs.php:37 msgid "User update" msgstr "" -#: admin/tab-dialogs.php:34 +#: admin/tab-dialogs.php:38 msgid "Passwords did not match" msgstr "" -#: admin/tab-dialogs.php:35 +#: admin/tab-dialogs.php:39 msgid "Password changes" msgstr "" -#: admin/tab-dialogs.php:36 +#: admin/tab-dialogs.php:40 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" -#: admin/tab-dialogs.php:37 +#: admin/tab-dialogs.php:41 msgid "Password reset" msgstr "" -#: admin/tab-dialogs.php:54 +#: admin/tab-dialogs.php:58 msgid "Dialogs and Error Messages" msgstr "" -#: admin/tab-dialogs.php:56 +#: admin/tab-dialogs.php:60 #, php-format msgid "" "You can customize the text for dialogs and error messages. Simple HTML is " "allowed %s etc." msgstr "" -#: admin/tab-dialogs.php:69 +#: admin/tab-dialogs.php:73 msgid "Terms of Service (TOS)" msgstr "" -#: admin/tab-dialogs.php:76 +#: admin/tab-dialogs.php:80 msgid "Update Dialogs" msgstr "" -#: admin/tab-dialogs.php:115 +#: admin/tab-dialogs.php:119 msgid "WP-Members dialogs were updated" msgstr "" -#: admin/tab-emails.php:30 +#: admin/tab-emails.php:34 msgid "New Registration" msgstr "" -#: admin/tab-emails.php:34 +#: admin/tab-emails.php:38 msgid "Registration is Moderated" msgstr "" -#: admin/tab-emails.php:35 +#: admin/tab-emails.php:39 msgid "Registration is Moderated, User is Approved" msgstr "" -#: admin/tab-emails.php:40 +#: admin/tab-emails.php:44 msgid "Password Reset" msgstr "" -#: admin/tab-emails.php:45 +#: admin/tab-emails.php:49 msgid "Admin Notification" msgstr "" -#: admin/tab-emails.php:50 +#: admin/tab-emails.php:54 msgid "Email Signature" msgstr "" -#: admin/tab-emails.php:57 +#: admin/tab-emails.php:61 msgid "Email Messages" msgstr "" -#: admin/tab-emails.php:60 +#: admin/tab-emails.php:64 msgid "You can customize the content of the emails sent by the plugin." msgstr "" -#: admin/tab-emails.php:62 +#: admin/tab-emails.php:66 msgid "A list of shortcodes is available here." msgstr "" -#: admin/tab-emails.php:69 +#: admin/tab-emails.php:73 msgid "Set a custom email address" msgstr "" -#: admin/tab-emails.php:70 admin/tab-emails.php:74 admin/tab-emails.php:97 +#: admin/tab-emails.php:74 admin/tab-emails.php:78 admin/tab-emails.php:101 msgid "(optional)" msgstr "" -#: admin/tab-emails.php:73 +#: admin/tab-emails.php:77 msgid "Set a custom email name" msgstr "" -#: admin/tab-emails.php:84 +#: admin/tab-emails.php:88 msgid "Subject" msgstr "" -#: admin/tab-emails.php:88 +#: admin/tab-emails.php:92 msgid "Body" msgstr "" -#: admin/tab-emails.php:105 +#: admin/tab-emails.php:109 msgid "Update Emails" msgstr "" -#: admin/tab-emails.php:161 +#: admin/tab-emails.php:165 msgid "WP-Members emails were updated" msgstr "" -#: admin/tab-fields.php:166 +#: admin/tab-fields.php:170 msgid "WP-Members fields were updated" msgstr "" -#: admin/tab-fields.php:176 +#: admin/tab-fields.php:182 msgid "Field Label is required for adding a new field. Nothing was updated." msgstr "" -#: admin/tab-fields.php:177 +#: admin/tab-fields.php:183 msgid "Option Name is required for adding a new field. Nothing was updated." msgstr "" -#: admin/tab-fields.php:184 +#: admin/tab-fields.php:185 +msgid "Option Name must contain only letters, numbers, and underscores" +msgstr "" + +#: admin/tab-fields.php:192 msgid "A field with that option name already exists" msgstr "" -#: admin/tab-fields.php:201 +#: admin/tab-fields.php:209 msgid "Checked value is required for checkboxes. Nothing was updated." msgstr "" -#: admin/tab-fields.php:223 +#: admin/tab-fields.php:235 msgid "field was added" msgstr "" -#: admin/tab-fields.php:241 +#: admin/tab-fields.php:253 msgid "field was updated" msgstr "" -#: admin/tab-fields.php:289 admin/tab-fields.php:385 +#: admin/tab-fields.php:272 admin/tab-fields.php:451 +msgid "Edit" +msgstr "" + +#: admin/tab-fields.php:299 admin/tab-fields.php:416 msgid "Edit Field" msgstr "" -#: admin/tab-fields.php:289 +#: admin/tab-fields.php:299 msgid "Add a Field" msgstr "" -#: admin/tab-fields.php:295 admin/tab-fields.php:416 +#: admin/tab-fields.php:305 admin/tab-fields.php:445 msgid "Field Label" msgstr "" -#: admin/tab-fields.php:297 +#: admin/tab-fields.php:307 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: admin/tab-fields.php:300 admin/tab-fields.php:417 +#: admin/tab-fields.php:310 admin/tab-fields.php:446 msgid "Option Name" msgstr "" -#: admin/tab-fields.php:306 +#: admin/tab-fields.php:316 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: admin/tab-fields.php:310 admin/tab-fields.php:418 +#: admin/tab-fields.php:320 admin/tab-fields.php:447 msgid "Field Type" msgstr "" -#: admin/tab-fields.php:316 +#: admin/tab-fields.php:326 msgid "text" msgstr "" -#: admin/tab-fields.php:317 +#: admin/tab-fields.php:327 msgid "textarea" msgstr "" -#: admin/tab-fields.php:318 +#: admin/tab-fields.php:328 msgid "checkbox" msgstr "" -#: admin/tab-fields.php:319 +#: admin/tab-fields.php:329 msgid "dropdown" msgstr "" -#: admin/tab-fields.php:320 +#: admin/tab-fields.php:330 msgid "password" msgstr "" -#: admin/tab-fields.php:325 admin/tab-fields.php:419 +#: admin/tab-fields.php:331 +msgid "file" +msgstr "" + +#: admin/tab-fields.php:336 admin/tab-fields.php:448 msgid "Display?" msgstr "" -#: admin/tab-fields.php:329 admin/tab-fields.php:420 +#: admin/tab-fields.php:340 admin/tab-fields.php:449 msgid "Required?" msgstr "" -#: admin/tab-fields.php:334 +#: admin/tab-fields.php:346 +msgid "Additional information for field upload fields" +msgstr "" + +#: admin/tab-fields.php:349 +msgid "Accepted file types:" +msgstr "" + +#: admin/tab-fields.php:354 +msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" +msgstr "" + +#: admin/tab-fields.php:361 msgid "Additional information for checkbox fields" msgstr "" -#: admin/tab-fields.php:337 +#: admin/tab-fields.php:364 msgid "Checked by default?" msgstr "" -#: admin/tab-fields.php:341 +#: admin/tab-fields.php:368 msgid "Stored value if checked:" msgstr "" -#: admin/tab-fields.php:347 +#: admin/tab-fields.php:376 msgid "Additional information for dropdown fields" msgstr "" -#: admin/tab-fields.php:350 +#: admin/tab-fields.php:379 msgid "For dropdown, array of values:" msgstr "" -#: admin/tab-fields.php:375 +#: admin/tab-fields.php:404 msgid "Options should be Option Name|option_value," msgstr "" -#: admin/tab-fields.php:379 +#: admin/tab-fields.php:408 msgid "Visit plugin site for more information" msgstr "" -#: admin/tab-fields.php:385 +#: admin/tab-fields.php:416 msgid "Add Field" msgstr "" -#: admin/tab-fields.php:407 +#: admin/tab-fields.php:436 msgid "Manage Fields" msgstr "" -#: admin/tab-fields.php:409 +#: admin/tab-fields.php:438 msgid "" "Determine which fields will display and which are required. This includes " "all fields, both native WP fields and WP-Members custom fields." msgstr "" -#: admin/tab-fields.php:410 +#: admin/tab-fields.php:439 msgid "(Note: Email is always mandatory and cannot be changed.)" msgstr "" -#: admin/tab-fields.php:415 +#: admin/tab-fields.php:444 msgid "Add/Delete" msgstr "" -#: admin/tab-fields.php:421 +#: admin/tab-fields.php:450 msgid "Checked?" msgstr "" -#: admin/tab-fields.php:423 +#: admin/tab-fields.php:452 msgid "Users Screen" msgstr "" -#: admin/tab-fields.php:435 +#: admin/tab-fields.php:464 msgid "Delete" msgstr "" -#: admin/tab-fields.php:447 +#: admin/tab-fields.php:476 msgid "(Email cannot be removed)" msgstr "" -#: admin/tab-fields.php:467 +#: admin/tab-fields.php:496 msgid "Registration Date" msgstr "" -#: admin/tab-fields.php:470 +#: admin/tab-fields.php:499 msgid "native" msgstr "" -#: admin/tab-fields.php:480 +#: admin/tab-fields.php:509 msgid "Active" msgstr "" -#: admin/tab-fields.php:492 +#: admin/tab-fields.php:521 msgid "Registration IP" msgstr "" -#: admin/tab-fields.php:527 +#: admin/tab-fields.php:556 msgid "Update Fields" msgstr "" -#: admin/tab-options.php:48 +#: admin/tab-options.php:67 msgid "Manage Options" msgstr "" -#: admin/tab-options.php:54 -msgid "Block Posts by default" +#: admin/tab-options.php:82 +msgid "Do not block" msgstr "" -#: admin/tab-options.php:54 -msgid "" -"Note: Posts can still be individually blocked or unblocked at the article " -"level" +#: admin/tab-options.php:84 +msgid "Hide" msgstr "" -#: admin/tab-options.php:55 -msgid "Block Pages by default" +#: admin/tab-options.php:94 +msgid "Show Excerpts" msgstr "" -#: admin/tab-options.php:55 -msgid "" -"Note: Pages can still be individually blocked or unblocked at the article " -"level" +#: admin/tab-options.php:95 +msgid "Show Login Form" msgstr "" -#: admin/tab-options.php:56 -msgid "Show excerpts" +#: admin/tab-options.php:96 +msgid "Show Registration Form" msgstr "" -#: admin/tab-options.php:56 -msgid "" -"Shows excerpted content above the login/registration on both Posts and Pages" -msgstr "" - -#: admin/tab-options.php:57 -msgid "Notify admin" -msgstr "" - -#: admin/tab-options.php:57 -#, php-format -msgid "Notify %s for each new registration? %s" -msgstr "" - -#: admin/tab-options.php:58 -msgid "Moderate registration" -msgstr "" - -#: admin/tab-options.php:58 -msgid "Holds new registrations for admin approval" -msgstr "" - -#: admin/tab-options.php:91 -msgid "Enable CAPTCHA" +#: admin/tab-options.php:116 +msgid "Time-based expiration" msgstr "" -#: admin/tab-options.php:59 -msgid "Turns on CAPTCHA for registration" +#: admin/tab-options.php:116 +msgid "Allows for access to expire" msgstr "" -#: admin/tab-options.php:60 -msgid "Hide registration" +#: admin/tab-options.php:117 +msgid "Trial period" msgstr "" -#: admin/tab-options.php:60 -msgid "Removes the registration form from blocked content" +#: admin/tab-options.php:117 +msgid "Allows for a trial period" msgstr "" -#: admin/tab-options.php:62 -msgid "Time-based expiration" +#: admin/tab-options.php:133 +msgid "Notify admin" msgstr "" -#: admin/tab-options.php:62 -msgid "Allows for access to expire" +#: admin/tab-options.php:133 +#, php-format +msgid "Notify %s for each new registration? %s" msgstr "" -#: admin/tab-options.php:63 -msgid "Trial period" +#: admin/tab-options.php:134 +msgid "Moderate registration" msgstr "" -#: admin/tab-options.php:63 -msgid "Allows for a trial period" +#: admin/tab-options.php:134 +msgid "Holds new registrations for admin approval" msgstr "" -#: admin/tab-options.php:64 +#: admin/tab-options.php:135 msgid "Ignore warning messages" msgstr "" -#: admin/tab-options.php:64 +#: admin/tab-options.php:135 msgid "Ignores WP-Members warning messages in the admin panel" msgstr "" -#: admin/tab-options.php:81 +#: admin/tab-options.php:147 msgid "Attribution" msgstr "" -#: admin/tab-options.php:83 +#: admin/tab-options.php:149 msgid "" "Attribution is appreciated! Display \"powered by\" link on register form?" msgstr "" -#: admin/tab-options.php:87 +#: admin/tab-options.php:153 msgid "Auto Excerpt:" msgstr "" -#: admin/tab-options.php:88 +#: admin/tab-options.php:154 msgid "Number of words in excerpt:" msgstr "" -#: admin/tab-options.php:88 admin/tab-options.php:108 -#: admin/tab-options.php:118 admin/tab-options.php:132 +#: admin/tab-options.php:154 msgid "Optional" msgstr "" -#: admin/tab-options.php:88 +#: admin/tab-options.php:154 msgid "Automatically creates an excerpt" msgstr "" -#: admin/tab-options.php:103 -msgid "User Profile Page:" +#: admin/tab-options.php:157 +msgid "Enable CAPTCHA" msgstr "" -#: admin/tab-options.php:106 -msgid "For creating a forgot password link in the login form" +#: admin/tab-options.php:159 +msgid "None" +msgstr "" + +#: admin/tab-options.php:164 +msgid "Pages" +msgstr "" + +#: admin/tab-options.php:168 +msgid "Login Page:" msgstr "" -#: admin/tab-options.php:113 +#: admin/tab-options.php:171 +msgid "Specify a login page (optional)" +msgstr "" + +#: admin/tab-options.php:180 msgid "Register Page:" msgstr "" -#: admin/tab-options.php:116 +#: admin/tab-options.php:183 msgid "For creating a register link in the login form" msgstr "" -#: admin/tab-options.php:126 -msgid "Select a stylesheet or specify a custom stylesheet below" +#: admin/tab-options.php:192 +msgid "User Profile Page:" msgstr "" -#: admin/tab-options.php:131 +#: admin/tab-options.php:195 +msgid "For creating a forgot password link in the login form" +msgstr "" + +#: admin/tab-options.php:201 admin/tab-options.php:203 +msgid "Stylesheet" +msgstr "" + +#: admin/tab-options.php:212 msgid "Custom Stylesheet:" msgstr "" -#: admin/tab-options.php:136 +#: admin/tab-options.php:218 msgid "Update Settings" msgstr "" -#: admin/tab-options.php:246 +#: admin/tab-options.php:336 msgid "WP-Members settings were updated" msgstr "" -#: admin/tab-options.php:296 -msgid "Select a page" +#: admin/tab-options.php:378 admin/tab-options.php:407 +msgid "USE CUSTOM URL BELOW" msgstr "" -#: admin/tab-options.php:304 -msgid "USE CUSTOM URL BELOW" +#: admin/tab-options.php:396 +msgid "Select a page" msgstr "" -#: admin/user-export.php:57 admin/user-export.php:172 +#: admin/user-export.php:76 msgid "Activated?" msgstr "" -#: admin/user-export.php:61 admin/user-export.php:175 +#: admin/user-export.php:77 msgid "Subscription" msgstr "" -#: admin/user-export.php:61 admin/user-export.php:175 +#: admin/user-export.php:77 msgid "Expires" msgstr "" -#: admin/user-export.php:64 admin/user-export.php:178 +#: admin/user-export.php:79 msgid "Registered" msgstr "" -#: admin/user-export.php:65 admin/user-export.php:179 +#: admin/user-export.php:80 msgid "IP" msgstr "" -#: admin/user-profile.php:46 +#: admin/user-export.php:112 admin/users.php:335 +msgid "No" +msgstr "" + +#: admin/user-profile.php:50 msgid "WP-Members Additional Fields" msgstr "" -#: admin/user-profile.php:66 native-registration.php:36 -#: native-registration.php:159 users.php:62 +#: admin/user-profile.php:78 inc/users.php:62 inc/wp-registration.php:37 +#: inc/wp-registration.php:159 msgid "(required)" msgstr "" -#: admin/user-profile.php:98 +#: admin/user-profile.php:110 msgid "Activate this user?" msgstr "" -#: admin/user-profile.php:103 +#: admin/user-profile.php:115 msgid "Reactivate this user?" msgstr "" -#: admin/user-profile.php:108 +#: admin/user-profile.php:120 msgid "Deactivate this user?" msgstr "" -#: admin/user-profile.php:129 +#: admin/user-profile.php:144 msgid "IP @ registration" msgstr "" -#: admin/users.php:45 admin/users.php:49 +#: admin/users.php:60 admin/users.php:64 +msgid "Activate" +msgstr "" + +#: admin/users.php:62 admin/users.php:66 msgid "Export" msgstr "" -#: admin/users.php:50 admin/users.php:91 +#: admin/users.php:67 admin/users.php:108 msgid "Export All Users" msgstr "" -#: forms.php:95 -msgid "Existing Users Log In" +#: inc/class-wp-members-widget.php:15 +msgid "Displays the WP-Members sidebar login." msgstr "" -#: forms.php:161 wp-members-dialogs.php:192 -msgid "Change Password" +#: inc/class-wp-members-widget.php:30 inc/class-wp-members-widget.php:73 +msgid "Login Status" msgstr "" -#: forms.php:163 -msgid "Update Password" +#: inc/class-wp-members-widget.php:37 +msgid "Title:" msgstr "" -#: forms.php:227 -msgid "Reset Forgotten Password" +#: inc/class-wp-members-widget.php:41 +msgid "Redirect to (optional):" msgstr "" -#: forms.php:403 -msgid "Forgot password?" +#: inc/class-wp-members.php:320 inc/shortcodes.php:86 inc/shortcodes.php:383 +msgid "There was an error with the CAPTCHA form." msgstr "" -#: forms.php:403 -msgid "Click here to reset" +#: inc/core.php:100 +msgid "ERROR: User has not been activated." msgstr "" -#: forms.php:418 -msgid "New User?" +#: inc/core.php:466 inc/register.php:88 +#, php-format +msgid "Sorry, %s is a required field." msgstr "" -#: forms.php:418 -msgid "Click here to register" +#: inc/core.php:484 inc/forms.php:526 inc/sidebar.php:188 +msgid "Register" msgstr "" -#: forms.php:515 -msgid "Required field" +#: inc/dialogs.php:40 +msgid "Login Failed!" msgstr "" -#: forms.php:521 -msgid "Reset Form" +#: inc/dialogs.php:43 +msgid "You entered an invalid username or password." msgstr "" -#: forms.php:523 -msgid "Update Profile" +#: inc/dialogs.php:45 +msgid "Click here to continue." msgstr "" -#: forms.php:561 -msgid "Choose a Username" +#: inc/dialogs.php:189 +msgid "Edit My Information" msgstr "" -#: forms.php:683 native-registration.php:65 +#: inc/dialogs.php:190 inc/forms.php:163 +msgid "Change Password" +msgstr "" + +#: inc/dialogs.php:204 inc/dialogs.php:225 inc/dialogs.php:261 +#: inc/sidebar.php:46 inc/sidebar.php:242 #, php-format -msgid "Please indicate that you agree to the %s TOS %s" +msgid "You are logged in as %s" msgstr "" -#: forms.php:852 -msgid "New User Registration" +#: inc/dialogs.php:206 +msgid "Click to log out." msgstr "" -#: forms.php:1018 -msgid "Input the code:" +#: inc/dialogs.php:207 +msgid "Begin using the site." msgstr "" -#: users.php:38 -msgid "Additional Information" +#: inc/dialogs.php:226 +msgid "Click to log out" msgstr "" -#: wp-members-core.php:118 wp-members-core.php:245 -msgid "There was an error with the CAPTCHA form." +#: inc/dialogs.php:262 inc/sidebar.php:47 +msgid "click to log out" msgstr "" -#: wp-members-core.php:287 wp-members-dialogs.php:338 +#: inc/dialogs.php:310 +msgid "Password fields cannot be empty" +msgstr "" + +#: inc/dialogs.php:377 inc/shortcodes.php:425 msgid "Edit Your Information" msgstr "" -#: wp-members-core.php:512 -msgid "Click here to log out." +#: inc/forms.php:71 inc/forms.php:204 inc/forms.php:558 inc/sidebar.php:137 +msgid "Username" msgstr "" -#: wp-members-core.php:544 -msgid "ERROR: User has not been activated." +#: inc/forms.php:78 inc/sidebar.php:143 +msgid "Password" msgstr "" -#: wp-members-core.php:903 wp-members-register.php:93 -#, php-format -msgid "Sorry, %s is a required field." +#: inc/forms.php:96 +msgid "Existing Users Log In" msgstr "" -#: wp-members-dialogs.php:42 -msgid "Login Failed!" +#: inc/forms.php:98 +msgid "Log In" msgstr "" -#: wp-members-dialogs.php:45 -msgid "You entered an invalid username or password." +#: inc/forms.php:138 +msgid "New password" msgstr "" -#: wp-members-dialogs.php:47 -msgid "Click here to continue." +#: inc/forms.php:145 +msgid "Confirm new password" msgstr "" -#: wp-members-dialogs.php:191 -msgid "Edit My Information" +#: inc/forms.php:165 +msgid "Update Password" msgstr "" -#: wp-members-dialogs.php:206 wp-members-dialogs.php:224 -#: wp-members-dialogs.php:239 wp-members-sidebar.php:46 -#: wp-members-sidebar.php:246 -#, php-format -msgid "You are logged in as %s" +#: inc/forms.php:211 +msgid "Email" msgstr "" -#: wp-members-dialogs.php:208 -msgid "Click to log out." +#: inc/forms.php:229 +msgid "Reset Forgotten Password" msgstr "" -#: wp-members-dialogs.php:209 -msgid "Begin using the site." +#: inc/forms.php:231 +msgid "Reset Password" msgstr "" -#: wp-members-dialogs.php:225 -msgid "Click to log out" +#: inc/forms.php:379 +msgid "Remember Me" msgstr "" -#: wp-members-dialogs.php:240 wp-members-sidebar.php:47 -msgid "click to log out" +#: inc/forms.php:407 +msgid "Forgot password?" msgstr "" -#: wp-members-dialogs.php:271 -msgid "Password fields cannot be empty" +#: inc/forms.php:407 +msgid "Click here to reset" +msgstr "" + +#: inc/forms.php:422 +msgid "New User?" +msgstr "" + +#: inc/forms.php:422 +msgid "Click here to register" +msgstr "" + +#: inc/forms.php:519 +msgid "Required field" +msgstr "" + +#: inc/forms.php:525 +msgid "Reset Form" +msgstr "" + +#: inc/forms.php:527 +msgid "Update Profile" +msgstr "" + +#: inc/forms.php:565 +msgid "Choose a Username" +msgstr "" + +#: inc/forms.php:687 inc/wp-registration.php:66 +#, php-format +msgid "Please indicate that you agree to the %s TOS %s" +msgstr "" + +#: inc/forms.php:854 +msgid "New User Registration" +msgstr "" + +#: inc/forms.php:1036 +msgid "Input the code:" msgstr "" -#: wp-members-register.php:51 +#: inc/register.php:45 msgid "There was an error processing the form." msgstr "" -#: wp-members-register.php:110 -msgid "Sorry, username is a required field" +#: inc/register.php:109 inc/register.php:342 +msgid "You must enter a valid email address." msgstr "" -#: wp-members-register.php:111 +#: inc/register.php:110 msgid "The username cannot include non-alphanumeric characters." msgstr "" -#: wp-members-register.php:112 wp-members-register.php:282 -msgid "You must enter a valid email address." +#: inc/register.php:111 +msgid "Sorry, username is a required field" msgstr "" -#: wp-members-register.php:119 +#: inc/register.php:122 msgid "Passwords did not match." msgstr "" -#: wp-members-register.php:120 wp-members-register.php:286 +#: inc/register.php:125 inc/register.php:350 msgid "Emails did not match." msgstr "" -#: wp-members-register.php:127 +#: inc/register.php:137 msgid "You must complete the CAPTCHA form." msgstr "" -#: wp-members-register.php:377 +#: inc/register.php:462 msgid "We were unable to validate the public key." msgstr "" -#: wp-members-register.php:381 +#: inc/register.php:466 msgid "We were unable to validate the private key." msgstr "" -#: wp-members-register.php:385 +#: inc/register.php:470 msgid "The challenge parameter of the verify script was incorrect." msgstr "" -#: wp-members-register.php:389 +#: inc/register.php:474 msgid "The CAPTCHA solution was incorrect." msgstr "" -#: wp-members-register.php:393 +#: inc/register.php:478 msgid "The parameters to verify were incorrect" msgstr "" -#: wp-members-register.php:397 +#: inc/register.php:482 msgid "" "reCAPTCHA API keys are tied to a specific domain name for security reasons." msgstr "" -#: wp-members-register.php:401 +#: inc/register.php:486 msgid "The reCAPTCHA server was not reached. Please try to resubmit." msgstr "" -#: wp-members-register.php:405 +#: inc/register.php:490 msgid "You have entered an incorrect code value. Please try again." msgstr "" -#: wp-members-sidebar.php:117 +#: inc/shortcodes.php:344 +msgid "Click here to log out." +msgstr "" + +#: inc/sidebar.php:113 msgid "Login Failed!
    You entered an invalid username or password." msgstr "" -#: wp-members-sidebar.php:118 +#: inc/sidebar.php:114 msgid "You are not logged in." msgstr "" -#: wp-members-sidebar.php:169 +#: inc/sidebar.php:165 msgid "log in" msgstr "" -#: wp-members-sidebar.php:180 +#: inc/sidebar.php:176 msgid "Forgot?" msgstr "" -#: wp-members-sidebar.php:247 +#: inc/sidebar.php:243 msgid "click here to log out" msgstr "" -#: wp-members-sidebar.php:279 -msgid "Displays the WP-Members sidebar login." -msgstr "" - -#: wp-members-sidebar.php:294 wp-members-sidebar.php:333 -msgid "Login Status" +#: inc/users.php:38 +msgid "Additional Information" msgstr "" -#: wp-members-sidebar.php:299 -msgid "Title:" +#: inc/utilities.php:250 +msgid "(more…)" msgstr "" #: wp-members-tos.php:24 @@ -1049,111 +1118,167 @@ msgstr "" msgid "%sprint%s" msgstr "" - -#: STRINGS THAT ARE NOT SPECIFICALLY CONTAINED IN THE PLUGIN - -#: Custom Field Strings - -#: wp-members-install.php:49 +#: string stored in database msgid "First Name" msgstr "" -#: wp-members-install.php:50 +#: string stored in database msgid "Last Name" msgstr "" -#: wp-members-install.php:51 +#: string stored in database msgid "Address 1" msgstr "" -#: wp-members-install.php:52 +#: string stored in database msgid "Address 2" msgstr "" -#: wp-members-install.php:53 +#: string stored in database msgid "City" msgstr "" -#: wp-members-install.php:54 +#: string stored in database msgid "State" msgstr "" -#: wp-members-install.php:55 +#: string stored in database msgid "Zip" msgstr "" -#: wp-members-install.php:56 +#: string stored in database msgid "Country" msgstr "" -#: wp-members-install.php:57 +#: string stored in database msgid "Day Phone" msgstr "" -#: wp-members-install.php:59 -msgid "Website" +#: string stored in database +msgid "Email" msgstr "" -#: wp-members-install.php:60 -msgid "AIM" +#: string stored in database +msgid "Confirm Email" msgstr "" -#: wp-members-install.php:61 -msgid "Yahoo IM" -msgstr "" - -#: wp-members-install.php:62 -msgid "Jabber/Google Talk" +#: string stored in database +msgid "Website" msgstr "" -#: wp-members-install.php:63 +#: string stored in database msgid "Biographical Info" msgstr "" -#: wp-members-install.php:64 wp-members-install.php:211 -msgid "TOS" +#: string stored in database +msgid "Password" msgstr "" +#: string stored in database +msgid "Confirm Password" +msgstr "" -#: Error message dialog strings - -#: wp-members-install.php:96 -msgid "This content is restricted to site members. If you are an existing user, " -"please log in. New users may register below." +#: string stored in database +msgid "TOS" msgstr "" -#: wp-members-install.php:97 +#: string stored in database +msgid "This content is restricted to site members. If you are an existing user, please log in. New users may register below." +msgstr "" + +#: string stored in database msgid "Sorry, that username is taken, please try another." msgstr "" -#: wp-members-install.php:98 +#: string stored in database msgid "Sorry, that email address already has an account.
    Please try another." msgstr "" -#: wp-members-install.php:99 -msgid "Congratulations! Your registration was successful.

    You may now " -"log in using the password that was emailed to you." +#: string stored in database +msgid "Congratulations! Your registration was successful.

    You may now log in using the password that was emailed to you." msgstr "" -#: wp-members-install.php:100 +#: string stored in database msgid "Your information was updated!" msgstr "" -#: wp-members-install.php:101 +#: string stored in database msgid "Passwords did not match.

    Please try again." msgstr "" -#: wp-members-install.php:102 -msgid "Password successfully changed!

    You will need to re-login with " -"your new password." +#: string stored in database +msgid "Password successfully changed!" msgstr "" -#: wp-members-install.php:103 +#: string stored in database msgid "Either the username or email address do not exist in our records." msgstr "" -#: wp-members-install.php:104 -msgid "Password successfully reset!

    An email containing a new password " -"has been sent to the email address on file for your account. You may change " -"this random password then re-login with your new password." +#: string stored in database +msgid "Password successfully reset!

    An email containing a new password has been sent to the email address on file for your account." +msgstr "" + +#: admin/post.php: may be deprecated +#, php-format +msgid "%s posts %sed." +msgstr "" + +#: wp-members-install.php: may be deprecated +msgid "AIM" +msgstr "AIM" + +#: admin/tab-options.php: may be deprecated +msgid "Block Posts by default" +msgstr "" + +#: admin/tab-options.php: may be deprecated +msgid "Block Pages by default" +msgstr "" + +#: admin/tab-options.php: may be deprecated +msgid "Hide registration" +msgstr "" + +#: wp-members-install.php: may be deprecated +msgid "Jabber/Google Talk" +msgstr "" + +#: admin/tab-options.php: may be deprecated +msgid "Note: Posts can still be individually blocked or unblocked at the article level" +msgstr "" + +#: admin/tab-options.php: may be deprecated +msgid "Note: Pages can still be individually blocked or unblocked at the article level" +msgstr "" + +#: admin/post.php: may be deprecated +msgid "Page Restriction" +msgstr "" + +#: admin/post.php: may be deprecated +msgid "Post Restriction" +msgstr "" + +#: admin/tab-options.php: may be deprecated +msgid "Removes the registration form from blocked content" +msgstr "" + +#: admin/tab-options.php: may be deprecated +msgid "Select a stylesheet or specify a custom stylesheet below" +msgstr "" + +#: admin/tab-options.php: may be deprecated +msgid "Show excerpts" +msgstr "" + +#: admin/tab-options.php: may be deprecated +msgid "Shows excerpted content above the login/registration on both Posts and Pages" +msgstr "" + +#: admin/tab-options.php: may be deprecated +msgid "Turns on CAPTCHA for registration" +msgstr "" + +#: wp-members-install.php: may be deprecated +msgid "Yahoo IM" msgstr "" \ No newline at end of file From 25bb0dec7df60f045e7458232fc6787fe320ed13 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 23 Jun 2015 10:49:17 -0500 Subject: [PATCH 0106/1694] corrected function name for load_constants() --- inc/class-wp-members.php | 2 +- wp-members.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index cc89f36d..d5d4fe72 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -132,7 +132,7 @@ function load_dropins() { * * @since 3.0 */ - function load_contants() { + function load_constants() { ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $this->block['post'] ) : ''; ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $this->block['page'] ) : ''; ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $this->show_excerpt['post'] ) : ''; diff --git a/wp-members.php b/wp-members.php index ef423e71..9c46bbe8 100644 --- a/wp-members.php +++ b/wp-members.php @@ -139,7 +139,7 @@ function wpmem_init() { $wpmem->load_fields(); // Load contants. - $wpmem->load_contants(); + $wpmem->load_constants(); /** * Fires after initialization of plugin options. From 5ab5b588adb407fd1cf5a8905f31af8d45022fc5 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 23 Jun 2015 10:49:53 -0500 Subject: [PATCH 0107/1694] added wpmem_securify_comments filter hook to wpmem_securify_comments() function --- inc/core.php | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/inc/core.php b/inc/core.php index 1fac3b92..4e62d59b 100644 --- a/inc/core.php +++ b/inc/core.php @@ -520,7 +520,19 @@ function wpmem_wplogin_stylesheet() { * @return bool $open Whether the current post is open for comments. */ function wpmem_securify_comments( $open ) { - return ( ! is_user_logged_in() && wpmem_block() ) ? false : $open; + + $open = ( ! is_user_logged_in() && wpmem_block() ) ? false : $open; + + /** + * Filters whether comments are open or not. + * + * @since 3.0.0 + * + * @param bool $open Whether the current post is open for comments. + */ + $open = apply_filters( 'wpmem_securify_comments', $open ); + + return $open; } /** End of File **/ \ No newline at end of file From 2c9195e05cf9e8d685ad6300ca8b63d3040c99c8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 23 Jun 2015 17:01:28 -0500 Subject: [PATCH 0108/1694] changed anchor link for login form to apply name as the action and not always login (adds pwdchange and pwdreset) --- inc/forms.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/forms.php b/inc/forms.php index 976cb6df..9648557b 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -434,7 +434,7 @@ function wpmem_login_form( $page, $arr ) { $form = '' . $n . $form . ''; // apply anchor - $form = '' . $n . $form; + $form = '' . $n . $form; // apply main wrapper $form = $main_div_before . $n . $form . $n . $main_div_after; From c41b679662d380f0b37152057b22417d6d532973 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 23 Jun 2015 17:02:05 -0500 Subject: [PATCH 0109/1694] fixed querystring logic if default permalinks are being used --- inc/utilities.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/utilities.php b/inc/utilities.php index f977d9ae..4c85302b 100644 --- a/inc/utilities.php +++ b/inc/utilities.php @@ -130,7 +130,7 @@ function wpmem_chk_qstr( $url = null ) { $permalink = get_option( 'permalink_structure' ); if ( ! $permalink ) { - $url = ( ! $url ) ? get_option( 'home' ) . "/?" . $_SERVER['QUERY_STRING'] : ''; + $url = ( ! $url ) ? get_option( 'home' ) . "/?" . $_SERVER['QUERY_STRING'] : $url; $return_url = $url . "&"; } else { $url = ( ! $url ) ? get_permalink() : $url; From 72e88aec5de7497f1b8fb17e0b01cc1ec27ac6d6 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 23 Jun 2015 17:19:46 -0500 Subject: [PATCH 0110/1694] updated readme and main plugin file for final 3.0 release --- readme.txt | 32 ++++++++++++++++++++------------ wp-members.php | 4 ++-- 2 files changed, 22 insertions(+), 14 deletions(-) diff --git a/readme.txt b/readme.txt index b993ab7a..851a2cb4 100644 --- a/readme.txt +++ b/readme.txt @@ -2,8 +2,8 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 -Tested up to: 4.1 -Stable tag: 2.9.9.1 +Tested up to: 4.2.2 +Stable tag: 3.0.0 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,8 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 2.9.9.1 patches an issue with the admin notification email update in 2.9.9. -WP-Members 2.9.9 is mostly minor updates preparing codebase for the 3.0 project. +WP-Members 3.0.0 is a major version release. Please be sure you have reviewed the changelog before upgrading. == Screenshots == @@ -134,16 +133,25 @@ WP-Members 2.9.9 is mostly minor updates preparing codebase for the 3.0 project. == Changelog == = 3.0.0 = -* New settings and new plugin class. + +This release makes significant changes to the plugin's main options in the way they are stored. While care has been taken to make sure that you can roll back to a previous version, you may need to resave settings in the plugin's main options tab when attempting to roll back. It is advised that you test this update prior upgrading an existing install on a production site. + +If you have any custom functions hooked to filters and actions that call any file includes directly from the plugin, please note that several file names have changed. + +* New settings and new plugin class WP_Members. +* New settings now natively support Custom Post Types, both setting defaults and individual post blocking. * Settings constants removed in favor of using the $wpmem object class. -* wpmem_rs_captcha_folder filter hook. -* added new|edit toggle to wpmem-register_data filter hook. +* Added new|edit toggle to wpmem-register_data filter hook. * wpmem_settings_loaded action added. -* securify comments changed to use comments_open instead of comments_template (with a blank template). -* registration clear form button defaults to false. -* removed wp_set_auth_cookie from login function; it is already done as part of wp_signon. -* added support for custom post types, both setting defaults and individual post blocking. -* post meta box title filter is now for all post types wpmem_admin_{post type}_meta_title. +* Securify comments changed to use comments_open instead of comments_template (with a blank template). +* New wpmem_securify_comments filter hook to customize whether comments load or not. +* Registration clear form button defaults to false. +* Removed wp_set_auth_cookie from login function; it is already done as part of wp_signon. +* Post meta box title filter is now for all post types wpmem_admin_{post type}_meta_title. +* New filter for Really Simple Captcha folder location: wpmem_rs_captcha_folder. +* New shortcodes [wpmem_form] added. +* Shortcode dropdown selector added to tinymce toolbar in Post/Page editor. +* Added redirect_to as a function argument if calling wpmem_logout() directly. = 2.9.9 = * Code standards in wp-members-email.php diff --git a/wp-members.php b/wp-members.php index 9c46bbe8..fc9bf4a0 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0 beta 1 +Version: 3.0.0 Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0 beta 1' ); +define( 'WPMEM_VERSION', '3.0.0' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 805bc9f176ee7bf50a73c2d7dced63afa33005e5 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 25 Jun 2015 12:51:38 -0500 Subject: [PATCH 0111/1694] removed support for sortable user columns until it can be re-evaluated. --- admin/users.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/admin/users.php b/admin/users.php index d8668b41..d64d605c 100644 --- a/admin/users.php +++ b/admin/users.php @@ -299,8 +299,9 @@ function wpmem_add_user_column( $columns ) { $columns = array_merge( $columns, $wpmem_user_columns ); } - require_once( WPMEM_PATH . 'inc/class-wp-members-sortable-user-columns.php' ); - new WP_Members_Sortable_User_Columns( $wpmem_user_columns ); + // @todo - needs to be debugged for use with external process custom columns. + // require_once( WPMEM_PATH . 'inc/class-wp-members-sortable-user-columns.php' ); + // new WP_Members_Sortable_User_Columns( $wpmem_user_columns ); return $columns; } From 316f45a200c41e5b16f249165f5ccca146447b20 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 25 Jun 2015 12:52:00 -0500 Subject: [PATCH 0112/1694] removed CPT support until it can be re-evaluated. --- admin/post.php | 23 +++++++++++++++-------- admin/tab-options.php | 8 ++++++-- inc/class-wp-members.php | 2 +- 3 files changed, 22 insertions(+), 11 deletions(-) diff --git a/admin/post.php b/admin/post.php index 35d3598f..4ad6de00 100644 --- a/admin/post.php +++ b/admin/post.php @@ -41,7 +41,9 @@ * * @since 2.9.2 */ -function wpmem_bulk_posts_action() { ?> +function wpmem_bulk_posts_action() { + // @todo - holding off on CPT support for now. + if ( ( isset( $_GET['post_type'] ) && $_GET['post_type'] == 'page' ) || ! isset( $_GET['post_type'] ) ) { ?> true, '_builtin' => false ), 'names', 'and' ); + // @todo - holding off on CPT support. + // $post_types = get_post_types( array( 'public' => true, '_builtin' => false ), 'names', 'and' ); $post_arr = array( 'post' => 'Posts', 'page' => 'Pages', ); - if ( $post_types ) { + /* if ( $post_types ) { foreach ( $post_types as $post_type ) { $cpt_obj = get_post_type_object( $post_type ); $post_arr[ $cpt_obj->name ] = $cpt_obj->labels->name; } - } + } */ foreach ( $post_arr as $key => $val ) { @@ -192,11 +196,11 @@ function wpmem_block_meta() { $post_type = get_post_type_object( $post->post_type ); - if ( $wpmem->block[ $post->post_type ] == 1 ) { + if ( isset( $wpmem->block[ $post->post_type ] ) && $wpmem->block[ $post->post_type ] == 1 ) { $block = 0; $notice_text = 'blocked'; $text = 'Unblock'; - } elseif ( $wpmem->block[ $post->post_type ] == 0 ) { + } else { //} elseif ( $wpmem->block[ $post->post_type ] == 0 ) { $block = 1; $notice_text = 'not blocked'; $text = 'Block'; @@ -297,8 +301,11 @@ function wpmem_block_meta_save( $post_id ) { function wpmem_post_columns( $columns ) { global $wpmem; $post_type = ( isset( $_REQUEST['post_type'] ) ) ? $_REQUEST['post_type'] : 'post'; - wp_enqueue_style ( 'wpmem-admin-css', WPMEM_DIR . '/css/admin.css', '', WPMEM_VERSION ); - $columns['wpmem_block'] = ( $wpmem->block[ $post_type ] == 1 ) ? __( 'Unblocked?', 'wp-members' ) : __( 'Blocked?', 'wp-members' ); + + if ( $post_type == 'page' || $post_type == 'post' ) { // @todo - holding off on CPT support. + wp_enqueue_style ( 'wpmem-admin-css', WPMEM_DIR . '/css/admin.css', '', WPMEM_VERSION ); + $columns['wpmem_block'] = ( $wpmem->block[ $post_type ] == 1 ) ? __( 'Unblocked?', 'wp-members' ) : __( 'Blocked?', 'wp-members' ); + } return $columns; } diff --git a/admin/tab-options.php b/admin/tab-options.php index 9e6dec58..652e2465 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -75,7 +75,8 @@ function wpmem_a_build_options() { // Content Blocking option group. $i = 0; $len = count( $post_arr ); - foreach ( $post_arr as $key => $val ) { ?> + foreach ( $post_arr as $key => $val ) { + if ( $key == 'post' || $key == 'page' ) { // @todo - holding off on CPT support. ?> > /> diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index cacb8409..9a3bff43 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -253,7 +253,7 @@ function is_blocked() { $defaults = array( 'post_id' => $post->ID, 'post_type' => $post->post_type, - 'block' => ( $this->block[ $post->post_type ] == 1 ) ? true : false, + 'block' => ( isset( $this->block[ $post->post_type ] ) && $this->block[ $post->post_type ] == 1 ) ? true : false, 'block_meta' => $meta, // @todo get_post_meta( $post->ID, '_wpmem_block', true ), 'block_type' => ( $post->post_type == 'post' ) ? $this->block['post'] : ( ( $post->post_type == 'page' ) ? $this->block['page'] : 0 ), ); From 2f893c1ad7034a8926cffb5f9c5b58b7b91d0f63 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 25 Jun 2015 15:20:14 -0500 Subject: [PATCH 0113/1694] changed the order of functions for updating from previous versions so the settings update fires first --- wp-members-install.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/wp-members-install.php b/wp-members-install.php index 3289a1e1..19eb50e6 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -143,11 +143,12 @@ function wpmem_do_install() { update_option( 'wpmembers_style', plugin_dir_url ( __FILE__ ) . 'css/generic-no-float.css', '', 'yes' ); } else { - + + wpmem_update_settings(); wpmem_update_captcha(); wpmem_update_dialogs(); wpmem_append_email(); - wpmem_update_settings(); + } } From ce0819d1b5bc9c7204a9512c92918f1b22a342fb Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 25 Jun 2015 15:20:34 -0500 Subject: [PATCH 0114/1694] version 3.0.0.3 --- readme.txt | 10 ++++++++-- wp-members.php | 4 ++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/readme.txt b/readme.txt index 57f04742..1c97cd00 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 Tested up to: 4.2.2 -Stable tag: 3.0.0.2 +Stable tag: 3.0.0.3 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,7 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.0.2 is patch release. See the change log for detail. +WP-Members 3.0.0.3 is bug fix release. See the change log for detail. WP-Members 3.0.0 is a major version release. Please be sure you have reviewed the changelog before upgrading. http://rkt.bz/v30 == Screenshots == @@ -133,6 +133,12 @@ WP-Members 3.0.0 is a major version release. Please be sure you have reviewed th == Changelog == += 3.0.0.3 = + +* Removed sortable user columns. This class needs to be rebuilt to accommodate custom user columns outside of WP-Members. +* Removed native support for Custom Post Types (CPTs). Native CPT support was to be included in 3.0. However, it became appearant during the initial rollout that there are some additional considerations that need to be made regarding CPT support. It is being rolled back until the issues that have come up can be addressed. +* Changed the order of update functions for users upgrading from previous versions so that the rebuild of the plugin's settings happens first. The most critical function in 3.x updating is to rebuild the plugin's main options array to the new 3.0 format. + = 3.0.0.2 = * Patch correcting logic flaw in the login form shortcode that caused the form to not display at all if "show login" was turned off (should not effect the shortcode forms). diff --git a/wp-members.php b/wp-members.php index 8ee473eb..c1e95b80 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.0.2 +Version: 3.0.0.3 Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.0.2' ); +define( 'WPMEM_VERSION', '3.0.0.3' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From ccd67037d0bffeec2733ebc2182a030e3ddf086f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 25 Jun 2015 16:23:43 -0500 Subject: [PATCH 0115/1694] temporary check to see if version 3 settings were loaded and if not, runs settings update. --- inc/class-wp-members.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 9a3bff43..fefb146c 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -10,6 +10,13 @@ function __construct() { $this->load_settings(); + // Temporary check to validate that version 3 settings were built. + if ( ! isset( $this->version ) ) { + // Settings were not properly built during plugin upgrade. + require_once( WPMEM_PATH . 'wp-members-install.php' ); + wpmem_update_settings(); + $this->load_settings(); + } } /** From 7e9fc585a6d277759d46e27564397d3d94c9bcbf Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 25 Jun 2015 16:24:06 -0500 Subject: [PATCH 0116/1694] update to uninstall to remove pre 3.x settings --- uninstall.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/uninstall.php b/uninstall.php index 9012dc8e..537f81b3 100644 --- a/uninstall.php +++ b/uninstall.php @@ -66,6 +66,15 @@ function wpmem_uninstall_options() { delete_option( 'wpmembers_email_wpname' ); delete_option( 'widget_wpmemwidget' ); + + // For pre-3.x settings that may remain. + delete_option( 'wpmembers_msurl' ); + delete_option( 'wpmembers_regurl' ); + delete_option( 'wpmembers_logurl' ); + delete_option( 'wpmembers_cssurl' ); + delete_option( 'wpmembers_style' ); + delete_option( 'wpmembers_autoex' ); + delete_option( 'wpmembers_attrib' ); } /** End of File **/ \ No newline at end of file From 005b64f6f6e823852405d4924a8c06ae627e8d0b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 26 Jun 2015 09:14:50 -0500 Subject: [PATCH 0117/1694] updated readme.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 72bbf1d5..98fb73f5 100644 --- a/README.md +++ b/README.md @@ -10,5 +10,5 @@ This is the development repository for the WP-Members plugin for WordPress. Keep in mind that the branch here is a development branch, so it should be tested prior to loading to a production site -If you are looking for a production ready version of the plugin, use the 3.0.0.2 version hosted here: +If you are looking for a production ready version of the plugin, use the 3.0.0.3 version hosted here: http://wordpress.org/extend/plugins/wp-members/ From 083260ef373fe0ce46e1a20cc7e1f0be121ef139 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 2 Jul 2015 09:56:09 -0500 Subject: [PATCH 0118/1694] 3.0.0.3 fixes (minor install revision) --- inc/class-wp-members.php | 26 ++++++++++---------------- wp-members-install.php | 4 ++++ 2 files changed, 14 insertions(+), 16 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index fefb146c..490207df 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -6,26 +6,13 @@ */ class WP_Members { - function __construct() { - - $this->load_settings(); - - // Temporary check to validate that version 3 settings were built. - if ( ! isset( $this->version ) ) { - // Settings were not properly built during plugin upgrade. - require_once( WPMEM_PATH . 'wp-members-install.php' ); - wpmem_update_settings(); - $this->load_settings(); - } - } - /** * Plugin initialization function. * * @since 3.0.0 */ - function load_settings() { - + function __construct() { + /** * Filter the options before they are loaded into constants. * @@ -35,13 +22,20 @@ function load_settings() { */ $settings = apply_filters( 'wpmem_settings', get_option( 'wpmembers_settings' ) ); + // Validate that v3 settings are loaded. + if ( ! isset( $settings['version'] ) ) { + // If settings were not properly built during plugin upgrade. + require_once( WPMEM_PATH . 'wp-members-install.php' ); + $settings = apply_filters( 'wpmem_settings', wpmem_update_settings() ); + } + // Assemble settings. foreach ( $settings as $key => $val ) { $this->$key = $val; } // Set the stylesheet. - $this->cssurl = ( $this->style == 'use_custom' ) ? $this->cssurl : $this->style; + $this->cssurl = ( isset( $this->style ) && $this->style == 'use_custom' ) ? $this->cssurl : $this->style; } /** diff --git a/wp-members-install.php b/wp-members-install.php index 19eb50e6..e50e4841 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -157,6 +157,8 @@ function wpmem_do_install() { * Updates the existing settings if doing an update. * * @since 3.0 + * + * @return array $wpmem_newsettings */ function wpmem_update_settings() { @@ -220,6 +222,8 @@ function wpmem_update_settings() { delete_option( 'wpmembers_autoex' ); delete_option( 'wpmembers_attrib' ); */ + + return $wpmem_newsettings; } } From 6c87c5bb23f3f6576af2f1d79df8641a0f4dd4d8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 14 Jul 2015 15:49:13 -0500 Subject: [PATCH 0119/1694] bug fix to use autoex setting in object, not wpmem_autoex --- inc/utilities.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/inc/utilities.php b/inc/utilities.php index 4c85302b..1723a15f 100644 --- a/inc/utilities.php +++ b/inc/utilities.php @@ -215,7 +215,9 @@ function wpmem_enqueue_style() { */ function wpmem_do_excerpt( $content ) { - $arr = get_option( 'wpmembers_autoex' ); + global $wpmem; + + $arr = $wpmem->autoex; // get_option( 'wpmembers_autoex' ); // Is there already a 'more' link in the content? $has_more_link = ( stristr( $content, 'class="more-link"' ) ) ? true : false; From 6d482d32db38b397102a87a98c81f9857cabde40 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 14 Jul 2015 15:50:27 -0500 Subject: [PATCH 0120/1694] changed widget_wpmemwidget() function to __construct() --- inc/class-wp-members-widget.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/class-wp-members-widget.php b/inc/class-wp-members-widget.php index 792e5cd6..5eae9e6e 100644 --- a/inc/class-wp-members-widget.php +++ b/inc/class-wp-members-widget.php @@ -9,7 +9,7 @@ class widget_wpmemwidget extends WP_Widget { /** * Sets up the WP-Members login widget. */ - function widget_wpmemwidget() { + function __construct() { $widget_ops = array( 'classname' => 'wp-members', 'description' => __( 'Displays the WP-Members sidebar login.', 'wp-members' ) From 10696f27b9d4140a723903daba5776743b3b9f51 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 14 Jul 2015 15:51:35 -0500 Subject: [PATCH 0121/1694] added error check in add form field if user tries to add "name" (which causes registration to 404) --- admin/tab-fields.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index e7366fa7..f373f9d7 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -190,6 +190,9 @@ function wpmem_update_fields( $action ) { $chk_fields[] = $field[2]; } $add_field_err_msg = ( in_array( $_POST['add_option'], $chk_fields ) ) ? __( 'A field with that option name already exists', 'wp-members' ) : $add_field_err_msg; + + // Error check for disallowed field names. + $add_field_err_msg = ( strtolower( $_POST['add_option'] ) == 'name' ) ? __( 'Sorry, "name" is not an allowed field name. Field was not added.', 'wp-members' ) : $add_field_err_msg; // Error check option name for spaces and replace with underscores. $us_option = $_POST['add_option']; From 40c22fea3faac8dc96b314e3b42adc3bbc1e220c Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 14 Jul 2015 15:52:36 -0500 Subject: [PATCH 0122/1694] admin user profile to use $wpmem->fields instead of wpmembers_fields option --- admin/user-profile.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/user-profile.php b/admin/user-profile.php index 149ad8ed..52bc6da8 100644 --- a/admin/user-profile.php +++ b/admin/user-profile.php @@ -51,7 +51,7 @@ function wpmem_admin_fields() { fields; // get_option( 'wpmembers_fields' ); // Get excluded meta. $exclude = wpmem_get_excluded_meta( 'admin-profile' ); @@ -169,7 +169,7 @@ function wpmem_admin_update() { global $wpmem; $user_id = $_REQUEST['user_id']; - $wpmem_fields = get_option( 'wpmembers_fields' ); + $wpmem_fields = $wpmem->fields; // get_option( 'wpmembers_fields' ); /** * Fires before the user profile is updated. From 73cc0f3ba80546e2608648f0882310bc000b3762 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 14 Jul 2015 15:53:55 -0500 Subject: [PATCH 0123/1694] added reCAPTCHA version 2 as a separate option (will deprecate v1 later) --- admin/dialogs.php | 8 +++--- admin/tab-captcha.php | 62 +++++++++++++++++++++++++++++++++++-------- admin/tab-options.php | 1 + inc/forms.php | 13 +++++++-- inc/register.php | 23 ++++++++++++++++ 5 files changed, 91 insertions(+), 16 deletions(-) diff --git a/admin/dialogs.php b/admin/dialogs.php index 5965162b..ee50d793 100644 --- a/admin/dialogs.php +++ b/admin/dialogs.php @@ -77,9 +77,11 @@ function wpmem_a_do_warnings( $did_update ) { // Haven't entered recaptcha api keys. if ( $warnings_off && $wpmem->captcha == 1 ) { - $wpmem_captcha = get_option('wpmembers_captcha'); - if ( !$wpmem_captcha['recaptcha']['public'] || !$wpmem_captcha['recaptcha']['private'] ) { - wpmem_a_warning_msg(6); + $wpmem_captcha = get_option( 'wpmembers_captcha' ); + if ( isset( $wpmem_captcha['recaptcha'] ) ) { + if ( ! $wpmem_captcha['recaptcha']['public'] || ! $wpmem_captcha['recaptcha']['private'] ) { + wpmem_a_warning_msg(6); + } } } diff --git a/admin/tab-captcha.php b/admin/tab-captcha.php index 8d58dc74..c85b643a 100644 --- a/admin/tab-captcha.php +++ b/admin/tab-captcha.php @@ -57,7 +57,11 @@ function wpmem_a_build_captcha_options() {
    captcha == 1 ) { - $show_update_button = true; ?> + $show_update_button = true; + $private_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['private'] : ''; + $public_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['public'] : ''; + $captcha_theme = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['theme'] : ''; + ?> captcha == 3 ) { + $show_update_button = true; + $private_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['private'] : ''; + $public_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['public'] : ''; + ?> + + + + + + + + captcha == 2 ) { @@ -160,11 +186,23 @@ function wpmem_a_build_captcha_options() { + if ( $show_update_button ) { + + switch ( $wpmem->captcha ) { + case 1: + $captcha_type = 'recaptcha'; + break; + case 2: + $captcha_type = 'really_simple'; + break; + case 3: + $captcha_type = 'recaptcha2'; + break; + } ?> @@ -197,7 +235,7 @@ function wpmem_update_captcha() { $update_type = $_POST['wpmem_recaptcha_type']; $new_settings = array(); - if ( $update_type == 'recaptcha' ) { + if ( $update_type == 'recaptcha' || $update_type == 'recaptcha2' ) { if ( array_key_exists( 'really_simple', $settings ) ) { // Updating recaptcha but need to maintain really_simple. $new_settings['really_simple'] = $settings['really_simple']; @@ -205,8 +243,10 @@ function wpmem_update_captcha() { $new_settings['recaptcha'] = array( 'public' => $_POST['wpmem_captcha_publickey'], 'private' => $_POST['wpmem_captcha_privatekey'], - 'theme' => $_POST['wpmem_captcha_theme'], ); + if ( $update_type == 'recaptcha' && isset( $_POST['wpmem_captcha_theme'] ) ) { + $new_settings['recaptcha']['theme'] = $_POST['wpmem_captcha_theme']; + } } if ( $update_type == 'really_simple' ) { diff --git a/admin/tab-options.php b/admin/tab-options.php index 652e2465..b84caeb3 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -162,6 +162,7 @@ function wpmem_a_build_options() { diff --git a/inc/forms.php b/inc/forms.php index 29156ded..e24d940d 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -777,7 +777,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) { } // do recaptcha if enabled - if ( $wpmem->captcha == 1 && $toggle != 'edit' ) { // don't show on edit page! + if ( ( $wpmem->captcha == 1 || $wpmem->captcha == 3 ) && $toggle != 'edit' ) { // don't show on edit page! // get the captcha options $wpmem_captcha = get_option( 'wpmembers_captcha' ); @@ -930,7 +930,10 @@ function wpmem_inc_recaptcha( $arr ) { // determine if we need ssl $http = wpmem_use_ssl(); - $str = ' @@ -940,6 +943,12 @@ function wpmem_inc_recaptcha( $arr ) { '; + } elseif ( $wpmem->captcha == 3 ) { + + $str = ' +
    '; + } + /** * Filter the reCAPTCHA HTML. * diff --git a/inc/register.php b/inc/register.php index 4e80f717..c817c54a 100644 --- a/inc/register.php +++ b/inc/register.php @@ -192,6 +192,29 @@ function wpmem_registration( $toggle ) { return "empty"; exit(); } } + } elseif ( $wpmem->captcha == 3 && $wpmem_captcha['recaptcha'] ) { + // Get the captcha response. + if ( isset( $_POST['g-recaptcha-response'] ) ) { + $captcha = $_POST['g-recaptcha-response']; + } + + // If there is no captcha value, return error. + if ( ! $captcha ) { + $wpmem_themsg = __( 'You must complete the CAPTCHA form.', 'wp-members' ); + return "empty"; exit(); + } + + // We need the private key for validation. + $privatekey = $wpmem_captcha['recaptcha']['private']; + + // Validate the captcha. + $response = file_get_contents( "https://www.google.com/recaptcha/api/siteverify?secret=" . $privatekey . "&response=" . $captcha . "&remoteip=" . $_SERVER['REMOTE_ADDR'] ); + + // If captcha validation was unsuccessful. + if ( $response['success'] == false ) { + $wpmem_themsg = __( 'CAPTCHA was not valid.', 'wp-members' ); + return "empty"; exit(); + } } // Check for user defined password. From fd72b7076e52ff0a793512614029add376c10f6f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 15 Jul 2015 11:50:44 -0500 Subject: [PATCH 0124/1694] merged in comments fix from 3.0.1.1 --- inc/core.php | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/inc/core.php b/inc/core.php index c1b824f7..6ca1eef9 100644 --- a/inc/core.php +++ b/inc/core.php @@ -531,8 +531,24 @@ function wpmem_securify_comments( $open ) { * @param bool $open Whether the current post is open for comments. */ $open = apply_filters( 'wpmem_securify_comments', $open ); + + if ( ! $open ) { + add_filter( 'comments_array' , 'wpmem_securify_comments_array' , 10, 2 ); + } return $open; } +/** + * Empties the comments array if content is blocked. + * + * @since 3.0.1 + * + * @return array $comments The comments array. + */ +function wpmem_securify_comments_array( $comments , $post_id ) { + $comments = ( ! is_user_logged_in() && wpmem_block() ) ? array() : $comments; + return $comments; +} + /** End of File **/ \ No newline at end of file From be9ccde6efe6617cc716c95805cefb4aa7acfbf6 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 15 Jul 2015 11:51:26 -0500 Subject: [PATCH 0125/1694] tested and debugged widget __construct for WP 4.3 --- inc/class-wp-members-widget.php | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/inc/class-wp-members-widget.php b/inc/class-wp-members-widget.php index 5eae9e6e..fe83fee7 100644 --- a/inc/class-wp-members-widget.php +++ b/inc/class-wp-members-widget.php @@ -10,11 +10,14 @@ class widget_wpmemwidget extends WP_Widget { * Sets up the WP-Members login widget. */ function __construct() { - $widget_ops = array( - 'classname' => 'wp-members', - 'description' => __( 'Displays the WP-Members sidebar login.', 'wp-members' ) - ); - $this->WP_Widget( 'widget_wpmemwidget', 'WP-Members Login', $widget_ops ); + parent::__construct( + 'widget_wpmemwidget', + 'WP-Members Login', + array( + 'classname' => 'wp-members', + 'description' => __( 'Displays the WP-Members sidebar login.', 'wp-members' ), + ) + ); } /** From 42ec1899a1b92ae1b74f03ced6bb1ba8624d2d99 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 15 Jul 2015 13:25:47 -0500 Subject: [PATCH 0126/1694] expanded field name error checking to check against a list of all WP reserved terms --- admin/tab-fields.php | 8 ++++++-- inc/utilities.php | 12 ++++++++++++ 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index f373f9d7..4a59e0da 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -191,8 +191,12 @@ function wpmem_update_fields( $action ) { } $add_field_err_msg = ( in_array( $_POST['add_option'], $chk_fields ) ) ? __( 'A field with that option name already exists', 'wp-members' ) : $add_field_err_msg; - // Error check for disallowed field names. - $add_field_err_msg = ( strtolower( $_POST['add_option'] ) == 'name' ) ? __( 'Sorry, "name" is not an allowed field name. Field was not added.', 'wp-members' ) : $add_field_err_msg; + // Error check for reserved terms. + $reserved_terms = wpmem_wp_reserved_terms(); + $submitted_term = $_POST['add_option']; + if ( in_array( strtolower( $submitted_term ), $reserved_terms ) ) { + $add_field_err_msg = sprintf( __( 'Sorry, "%s" is a reserved term. Field was not added.', 'wp-members' ), $submitted_term ); + } // Error check option name for spaces and replace with underscores. $us_option = $_POST['add_option']; diff --git a/inc/utilities.php b/inc/utilities.php index 1723a15f..66faf0ab 100644 --- a/inc/utilities.php +++ b/inc/utilities.php @@ -335,4 +335,16 @@ function wpmem_use_ssl() { return ( is_ssl() ) ? 'https://' : 'http://'; } + +/** + * Returns an array of WordPress reserved terms. + * + * @since 3.0.2 + * + * @return array An array of WordPress reserved terms. + */ +function wpmem_wp_reserved_terms() { + return array( 'attachment', 'attachment_id', 'author', 'author_name', 'calendar', 'cat', 'category', 'category__and', 'category__in', 'category__not_in', 'category_name', 'comments_per_page', 'comments_popup', 'customize_messenger_channel', 'customized', 'cpage', 'day', 'debug', 'error', 'exact', 'feed', 'fields', 'hour', 'link_category', 'm', 'minute', 'monthnum', 'more', 'name', 'nav_menu', 'nonce', 'nopaging', 'offset', 'order', 'orderby', 'p', 'page', 'page_id', 'paged', 'pagename', 'pb', 'perm', 'post', 'post__in', 'post__not_in', 'post_format', 'post_mime_type', 'post_status', 'post_tag', 'post_type', 'posts', 'posts_per_archive_page', 'posts_per_page', 'preview', 'robots', 's', 'search', 'second', 'sentence', 'showposts', 'static', 'subpost', 'subpost_id', 'tag', 'tag__and', 'tag__in', 'tag__not_in', 'tag_id', 'tag_slug__and', 'tag_slug__in', 'taxonomy', 'tb', 'term', 'theme', 'type', 'w', 'withcomments', 'withoutcomments', 'year' ); +} + /** End of File **/ \ No newline at end of file From fcfcf5456c5a140370e4b171cd490f5880037a4d Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 15 Jul 2015 14:15:51 -0500 Subject: [PATCH 0127/1694] setting version 3.0.2 --- readme.txt | 12 ++++++++++-- wp-members.php | 4 ++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/readme.txt b/readme.txt index 7d72de39..8f96c1dc 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 Tested up to: 4.2.2 -Stable tag: 3.0.1 +Stable tag: 3.0.2 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,7 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.1 is bug fix release. See the change log for detail. +WP-Members 3.0.2 is feature and fix release. See the change log for detail. WP-Members 3.0.0 is a major version release. Please be sure you have reviewed the changelog before upgrading. http://rkt.bz/v30 == Screenshots == @@ -133,11 +133,19 @@ WP-Members 3.0.0 is a major version release. Please be sure you have reviewed th == Changelog == += 3.0.2 = + +* Added reCAPTCHA version 2 as an option. v1 will remain available for now, to be fully deprecated later. +* Fixed widget to use __construct for WP 4.3 compatibility. +* Added error checking for WP reserved names when adding new custom fields. + = 3.0.1 = * Fixed use of wp_signon() for ssl. * Fixed [wpmem_msurl] email shortcode. * Fixed admin js and css load (removed unnecessary slash). +* Fixed autoexcerpt to use setting from object and not wpmemembers_autoex option. +* Added filter to remove comments array if content is blocked. = 3.0.0 = diff --git a/wp-members.php b/wp-members.php index d14bc9e7..1a17adc0 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.1 +Version: 3.0.2 Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.1' ); +define( 'WPMEM_VERSION', '3.0.2' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 7e21a45f362ec12465e8b468ac3abd39ad952254 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 24 Jul 2015 11:15:06 -0500 Subject: [PATCH 0128/1694] added wpmem_wp_reserved_terms filter for overriding reserved terms list --- inc/utilities.php | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/inc/utilities.php b/inc/utilities.php index 66faf0ab..50350e52 100644 --- a/inc/utilities.php +++ b/inc/utilities.php @@ -344,7 +344,18 @@ function wpmem_use_ssl() { * @return array An array of WordPress reserved terms. */ function wpmem_wp_reserved_terms() { - return array( 'attachment', 'attachment_id', 'author', 'author_name', 'calendar', 'cat', 'category', 'category__and', 'category__in', 'category__not_in', 'category_name', 'comments_per_page', 'comments_popup', 'customize_messenger_channel', 'customized', 'cpage', 'day', 'debug', 'error', 'exact', 'feed', 'fields', 'hour', 'link_category', 'm', 'minute', 'monthnum', 'more', 'name', 'nav_menu', 'nonce', 'nopaging', 'offset', 'order', 'orderby', 'p', 'page', 'page_id', 'paged', 'pagename', 'pb', 'perm', 'post', 'post__in', 'post__not_in', 'post_format', 'post_mime_type', 'post_status', 'post_tag', 'post_type', 'posts', 'posts_per_archive_page', 'posts_per_page', 'preview', 'robots', 's', 'search', 'second', 'sentence', 'showposts', 'static', 'subpost', 'subpost_id', 'tag', 'tag__and', 'tag__in', 'tag__not_in', 'tag_id', 'tag_slug__and', 'tag_slug__in', 'taxonomy', 'tb', 'term', 'theme', 'type', 'w', 'withcomments', 'withoutcomments', 'year' ); + $reserved_terms = array( 'attachment', 'attachment_id', 'author', 'author_name', 'calendar', 'cat', 'category', 'category__and', 'category__in', 'category__not_in', 'category_name', 'comments_per_page', 'comments_popup', 'customize_messenger_channel', 'customized', 'cpage', 'day', 'debug', 'error', 'exact', 'feed', 'fields', 'hour', 'link_category', 'm', 'minute', 'monthnum', 'more', 'name', 'nav_menu', 'nonce', 'nopaging', 'offset', 'order', 'orderby', 'p', 'page', 'page_id', 'paged', 'pagename', 'pb', 'perm', 'post', 'post__in', 'post__not_in', 'post_format', 'post_mime_type', 'post_status', 'post_tag', 'post_type', 'posts', 'posts_per_archive_page', 'posts_per_page', 'preview', 'robots', 's', 'search', 'second', 'sentence', 'showposts', 'static', 'subpost', 'subpost_id', 'tag', 'tag__and', 'tag__in', 'tag__not_in', 'tag_id', 'tag_slug__and', 'tag_slug__in', 'taxonomy', 'tb', 'term', 'theme', 'type', 'w', 'withcomments', 'withoutcomments', 'year' ); + + /** + * Filter the array of reserved terms. + * + * @since 3.0.2 + * + * @param array $reserved_terms + */ + $reserved_terms = apply_filters( 'wpmem_wp_reserved_terms', $reserved_terms ); + + return $reserved_terms; } /** End of File **/ \ No newline at end of file From 52ba0a71b420daf4478c8d6551d700a9977b3228 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 24 Jul 2015 17:16:06 -0500 Subject: [PATCH 0129/1694] added back responsive forms screenshot in readme --- readme.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/readme.txt b/readme.txt index 8f96c1dc..5da6477b 100644 --- a/readme.txt +++ b/readme.txt @@ -130,6 +130,8 @@ WP-Members 3.0.0 is a major version release. Please be sure you have reviewed th 7. Posts > Edit Post - The plugin adds a meta box to the post/page editor allowing you to set an individual post to be blocked or unblocked (the opposite of whatver your default setting is). +8. Responsive forms. + == Changelog == From 12a6a17423521de16ba26f4c66188daa4dfdc98f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 24 Jul 2015 17:27:56 -0500 Subject: [PATCH 0130/1694] updated git readme --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 98fb73f5..77021d59 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ This is the development repository for the WP-Members plugin for WordPress. ## Usage Information ## -Keep in mind that the branch here is a development branch, so it should be tested prior to loading to a production site +Keep in mind that the branch here is a development branch, so it should be tested prior to loading to a production site. -If you are looking for a production ready version of the plugin, use the 3.0.0.3 version hosted here: +If you are looking for a production ready version of the plugin, use the version hosted here: http://wordpress.org/extend/plugins/wp-members/ From 2fa82525f8b5161beb3c52aa8b1ef072f5779bde Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 27 Jul 2015 11:50:55 -0500 Subject: [PATCH 0131/1694] trim whitespace for password reset and change, added redirect to login function --- inc/core.php | 41 +++++++++++++++++++++++++++++++++++------ inc/utilities.php | 2 +- 2 files changed, 36 insertions(+), 7 deletions(-) diff --git a/inc/core.php b/inc/core.php index 6ca1eef9..80f7f99b 100644 --- a/inc/core.php +++ b/inc/core.php @@ -144,7 +144,11 @@ function wpmem_login() { if ( ! is_wp_error( $user ) ) { // Determine where to put the user after login. - $redirect_to = ( isset( $_POST['redirect_to'] ) ) ? $_POST['redirect_to'] : $_SERVER['REQUEST_URI']; + if ( isset( $_POST['redirect_to'] ) ) { + $redirect_to = trim( $_POST['redirect_to'] ); + } else { + $redirect_to = $_SERVER['REQUEST_URI'] . ( ( isset( $_SERVER['QUERY_STRING'] ) ) ? $_SERVER['QUERY_STRING'] : '' ); + } /** * Filter the redirect url. @@ -285,8 +289,8 @@ function wpmem_change_password() { global $user_ID; if ( isset( $_POST['formsubmit'] ) ) { - $pass1 = $_POST['pass1']; - $pass2 = $_POST['pass2']; + $pass1 = trim( $_POST['pass1'] ); + $pass2 = trim( $_POST['pass2'] ); if ( ! $pass1 && ! $pass2 ) { // Check for both fields being empty. @@ -342,8 +346,8 @@ function wpmem_reset_password() { * @param array The username and email. */ $arr = apply_filters( 'wpmem_pwdreset_args', array( - 'user' => ( isset( $_POST['user'] ) ) ? $_POST['user'] : '', - 'email' => ( isset( $_POST['email'] ) ) ? $_POST['email'] : '', + 'user' => ( isset( $_POST['user'] ) ) ? trim( $_POST['user'] ) : '', + 'email' => ( isset( $_POST['email'] ) ) ? trim( $_POST['email'] ) : '', ) ); if ( ! $arr['user'] || ! $arr['email'] ) { @@ -539,6 +543,7 @@ function wpmem_securify_comments( $open ) { return $open; } + /** * Empties the comments array if content is blocked. * @@ -551,4 +556,28 @@ function wpmem_securify_comments_array( $comments , $post_id ) { return $comments; } -/** End of File **/ \ No newline at end of file + +/** + * Redirects a user to defined login page with return redirect. + * + * @since 3.0.2 + */ +function wpmem_redirect_to_login() { + + global $wpmem; + + if( ! is_user_logged_in() && $wpmem->is_blocked() ) { + global $post; + // Get the page location. + $page = urlencode( "http://" . $_SERVER["HTTP_HOST"] . $_SERVER["REQUEST_URI"] ); + + $url = wpmem_chk_qstr( $wpmem->user_pages['login'] ) . 'redirect_to=' . $page; + + wp_redirect( $url ); + exit(); + } + return; +} + + +// End of File. \ No newline at end of file diff --git a/inc/utilities.php b/inc/utilities.php index 50350e52..6ad6a463 100644 --- a/inc/utilities.php +++ b/inc/utilities.php @@ -131,7 +131,7 @@ function wpmem_chk_qstr( $url = null ) { $permalink = get_option( 'permalink_structure' ); if ( ! $permalink ) { $url = ( ! $url ) ? get_option( 'home' ) . "/?" . $_SERVER['QUERY_STRING'] : $url; - $return_url = $url . "&"; + $return_url = $url . "&"; } else { $url = ( ! $url ) ? get_permalink() : $url; $return_url = $url . "?"; From 52b4b2df4e30cdd5291c8548073178cf83688d12 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 27 Jul 2015 13:34:42 -0500 Subject: [PATCH 0132/1694] updated wpmem_securify_comments_array to use is_blocked() in $wpmem object instead of wpmem_blocked(). --- inc/core.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/inc/core.php b/inc/core.php index 80f7f99b..449ae8fa 100644 --- a/inc/core.php +++ b/inc/core.php @@ -551,8 +551,9 @@ function wpmem_securify_comments( $open ) { * * @return array $comments The comments array. */ -function wpmem_securify_comments_array( $comments , $post_id ) { - $comments = ( ! is_user_logged_in() && wpmem_block() ) ? array() : $comments; +function wpmem_securify_comments_array( $comments , $post_id ) { + global $wpmem; + $comments = ( ! is_user_logged_in() && $wpmem->is_blocked() ) ? array() : $comments; return $comments; } From dc4112c65ee84996faadf0e379321fbd2f4a84f7 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 27 Jul 2015 14:59:28 -0500 Subject: [PATCH 0133/1694] updated readme.txt for 3.0.2 final --- readme.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/readme.txt b/readme.txt index 5da6477b..184b09ff 100644 --- a/readme.txt +++ b/readme.txt @@ -140,6 +140,8 @@ WP-Members 3.0.0 is a major version release. Please be sure you have reviewed th * Added reCAPTCHA version 2 as an option. v1 will remain available for now, to be fully deprecated later. * Fixed widget to use __construct for WP 4.3 compatibility. * Added error checking for WP reserved names when adding new custom fields. +* Added wpmem_wp_reserved_terms filter for overriding reserved terms list. +* Added trim whitespace to password reset and password change form validation. = 3.0.1 = From f7205064409e74b9d6185fe2b695cea8969e0bc4 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 3 Aug 2015 11:16:41 -0500 Subject: [PATCH 0134/1694] recaptcha v2 bug fix - decode json response on validation --- inc/register.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/inc/register.php b/inc/register.php index c817c54a..49966eda 100644 --- a/inc/register.php +++ b/inc/register.php @@ -210,6 +210,9 @@ function wpmem_registration( $toggle ) { // Validate the captcha. $response = file_get_contents( "https://www.google.com/recaptcha/api/siteverify?secret=" . $privatekey . "&response=" . $captcha . "&remoteip=" . $_SERVER['REMOTE_ADDR'] ); + // Decode the json response. + $response = json_decode( $response, true ); + // If captcha validation was unsuccessful. if ( $response['success'] == false ) { $wpmem_themsg = __( 'CAPTCHA was not valid.', 'wp-members' ); From da918fcb39824e4f285845017e7f444dbcfa42d9 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 4 Aug 2015 09:59:03 -0500 Subject: [PATCH 0135/1694] admin forms now use submit_button() --- admin/tab-captcha.php | 2 +- admin/tab-dialogs.php | 2 +- admin/tab-emails.php | 2 +- admin/tab-fields.php | 5 +++-- admin/tab-options.php | 2 +- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/admin/tab-captcha.php b/admin/tab-captcha.php index c85b643a..c71a59df 100644 --- a/admin/tab-captcha.php +++ b/admin/tab-captcha.php @@ -204,7 +204,7 @@ function wpmem_a_build_captcha_options() { diff --git a/admin/tab-dialogs.php b/admin/tab-dialogs.php index b7fc8150..b23b2e09 100644 --- a/admin/tab-dialogs.php +++ b/admin/tab-dialogs.php @@ -77,7 +77,7 @@ function wpmem_a_build_dialogs() {

    @@ -69,22 +73,44 @@ function wpmem_a_build_captcha_options() {
    ", '' ); ?>.
    - :  
    - + :  
    +
    +

    +

    ', '' ); ?>.

    +

    +

    + ", '' ); ?>.
    + :  
    + +
      - + - +
      - +
    diff --git a/admin/tab-emails.php b/admin/tab-emails.php index 113040ba..4a3d024b 100644 --- a/admin/tab-emails.php +++ b/admin/tab-emails.php @@ -106,7 +106,7 @@ function wpmem_a_build_emails() {
      - +
    diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 4a59e0da..75833dc3 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -420,7 +420,8 @@ function wpmem_a_field_edit( $mode, $wpmem_fields = null, $field = null ) {
    - + +

  • @@ -560,7 +561,7 @@ function wpmem_a_field_table( $wpmem_fields ) {
    - +
    diff --git a/admin/tab-options.php b/admin/tab-options.php index b84caeb3..5d831adc 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -220,7 +220,7 @@ function wpmem_a_build_options() {


    - +
    From be5e50c584899e44aba77e022551f964b4626672 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 4 Aug 2015 13:35:41 -0500 Subject: [PATCH 0136/1694] fixed typo error in $wpmem object name --- admin/user-profile.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/user-profile.php b/admin/user-profile.php index 52bc6da8..34b5354c 100644 --- a/admin/user-profile.php +++ b/admin/user-profile.php @@ -136,7 +136,7 @@ function wpmem_admin_fields() { * if user is not active yet. */ if ( $wpmem->use_exp == 1 ) { - if ( ( $wpmem->mod_reg == 1 && get_user_meta( $user_id, 'active', true ) == 1 ) || ( $wpmwm->mod_reg != 1 ) ) { + if ( ( $wpmem->mod_reg == 1 && get_user_meta( $user_id, 'active', true ) == 1 ) || ( $wpmem->mod_reg != 1 ) ) { wpmem_a_extenduser( $user_id ); } } ?> From f7ccb4c93baf4d6d2595218c42468311125040f7 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 4 Aug 2015 14:23:39 -0500 Subject: [PATCH 0137/1694] corrected register shortcode redirect --- inc/forms.php | 4 ++-- inc/shortcodes.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/inc/forms.php b/inc/forms.php index e24d940d..ad8081f6 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -487,7 +487,7 @@ function wpmem_login_form( $page, $arr ) { * @global array $userdata Used to get the user's registration data if they are logged in (user profile edit). * @return string $form The HTML for the entire form as a string. */ -function wpmem_inc_registration( $toggle = 'new', $heading = '' ) { +function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = null ) { global $wpmem, $wpmem_regchk, $userdata; @@ -801,7 +801,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '' ) { // create hidden fields $var = ( $toggle == 'edit' ) ? 'update' : 'register'; - $redirect_to = ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : get_permalink(); + $redirect_to = ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : ( ( $redirect_to ) ? $redirect_to : get_permalink() ); $hidden = '' . $n; $hidden .= '' . $n; $hidden = ( isset( $hidden_tos ) ) ? $hidden . $hidden_tos . $n : $hidden; diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 0aff9708..221ea688 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -86,7 +86,7 @@ function wpmem_sc_forms( $atts, $content = null, $tag = 'wpmem_form' ) { $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; } $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ) : ''; - $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login() : wpmem_inc_registration(); + $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login() : wpmem_inc_registration( 'new', '', $redirect_to ); } break; From 17cb192c8fdb00e9991995d8cdce0b96c0cd593d Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 6 Aug 2015 10:20:55 -0500 Subject: [PATCH 0138/1694] bug fix for wpmem_msg_dialog_arr filter --- inc/dialogs.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/dialogs.php b/inc/dialogs.php index abd42f10..81bd33e6 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -142,7 +142,7 @@ function wpmem_inc_regmessage( $toggle, $msg = '' ) { // Merge $args with defaults. $args = wp_parse_args( $args, $defaults ); - $str = $args['div_before'] . $args['p_before'] . stripslashes( $msg ) . $args['p_after'] . $args['div_after']; + $str = $args['div_before'] . $args['p_before'] . stripslashes( $args['msg'] ) . $args['p_after'] . $args['div_after']; /** * Filter the message. From 8a495e3db265c1e0ff0a4064902e61fc5878ec5f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 9 Aug 2015 10:26:10 -0500 Subject: [PATCH 0139/1694] changed localization action hook to init, added wpmem_localization_file filter, load from /wp-content/ first --- wp-members.php | 30 +++++++++++++++++++++++------- 1 file changed, 23 insertions(+), 7 deletions(-) diff --git a/wp-members.php b/wp-members.php index 1a17adc0..30987ad4 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.2 +Version: 3.0.3 Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,13 +60,13 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.2' ); +define( 'WPMEM_VERSION', '3.0.3' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); // Localization. -add_action( 'plugins_loaded', 'wpmem_load_textdomain' ); +add_action( 'init', 'wpmem_load_textdomain' ); //add_action( 'plugins_loaded', 'wpmem_load_textdomain' ); // Initialize the plugin. add_action( 'after_setup_theme', 'wpmem_init', 10 ); @@ -281,6 +281,11 @@ function wpmem_mu_new_site( $blog_id, $user_id, $domain, $path, $site_id, $meta */ function wpmem_load_textdomain() { + // @todo See: https://ulrich.pogson.ch/load-theme-plugin-translations for notes on changes. + + $domain = 'wp-members'; + $locale = apply_filters( 'plugin_locale', get_locale(), $domain ); + /** * Filter translation file. * @@ -288,11 +293,22 @@ function wpmem_load_textdomain() { * * @param string $file The translation file to load. */ - $file = apply_filters( 'wpmem_localization_file', dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); - - // Load the localization file. - load_plugin_textdomain( 'wp-members', false, $file ); + $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . $domain . '/' . $domain . '-' . $locale . '.mo' ); + if ( $loaded = load_textdomain( $domain, $file ) ) { + return $loaded; + } else { + + /** + * Filter translation directory. + * + * @since 3.0.3 + * + * @param string $dir The translation directory. + */ + $dir = apply_filters( 'wpmem_localization_dir', dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); + load_plugin_textdomain( $domain, FALSE, $dir ); + } return; } From 80299316c63d9c4b5271f52f7e3b98ed59aedde2 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 9 Aug 2015 10:29:40 -0500 Subject: [PATCH 0140/1694] updated readme for 3.0.3 release --- readme.txt | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/readme.txt b/readme.txt index 184b09ff..97d64c28 100644 --- a/readme.txt +++ b/readme.txt @@ -1,9 +1,9 @@ -=== WP-Members === +=== WP-Members: Membership Framework === Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 -Tested up to: 4.2.2 -Stable tag: 3.0.2 +Tested up to: 4.3 +Stable tag: 3.0.3 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,7 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.2 is feature and fix release. See the change log for detail. +WP-Members 3.0.3 is feature and fix release. See the change log for detail. WP-Members 3.0.0 is a major version release. Please be sure you have reviewed the changelog before upgrading. http://rkt.bz/v30 == Screenshots == @@ -135,6 +135,16 @@ WP-Members 3.0.0 is a major version release. Please be sure you have reviewed th == Changelog == += 3.0.3 = + +* Bug fix recaptcha v2 decode json response on validation. +* Bug fix typo in $wpmem object name in admin/user-profile.php. +* Fix register form shortcode redirect_to parameter. +* Admin forms now use submit_button() function to generate submit button. +* Changed localization to load on init action which will allow for more flexibility with filtering custom language files. +* Added wpmem_localization_file and wpmem_localization_dir filters. +* Localizaiton checks for file in /wp-content/ language directory first, then loads plugin default. + = 3.0.2 = * Added reCAPTCHA version 2 as an option. v1 will remain available for now, to be fully deprecated later. From a5be6d233274ef9a0ff65347e77239d725b43f1f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 18 Aug 2015 13:14:05 -0500 Subject: [PATCH 0141/1694] updated text for recaptcha, keys are now "site" and "secret" --- admin/tab-captcha.php | 13 +++---------- lang/wp-members.pot | 22 +++------------------- 2 files changed, 6 insertions(+), 29 deletions(-) diff --git a/admin/tab-captcha.php b/admin/tab-captcha.php index c71a59df..c5e75b17 100644 --- a/admin/tab-captcha.php +++ b/admin/tab-captcha.php @@ -95,19 +95,12 @@ function wpmem_a_build_captcha_options() { $private_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['private'] : ''; $public_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['public'] : ''; ?> - - -

    -

    ', '' ); ?>.

    -

    - - - ", '' ); ?>.
    - :  
    - + ", '' ); ?>.
    + :  
    + Date: Tue, 18 Aug 2015 13:14:38 -0500 Subject: [PATCH 0142/1694] added function list to file header --- inc/dialogs.php | 9 ++++++++- inc/shortcodes.php | 11 ++++++++++- 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/inc/dialogs.php b/inc/dialogs.php index 81bd33e6..490f73db 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -13,6 +13,13 @@ * @subpackage WP-Members * @author Chad Butler * @copyright 2006-2015 + * + * Functions Included: + * - wpmem_inc_loginfailed + * - wpmem_inc_regmessage + * - wpmem_inc_memberlinks + * - wpmem_page_pwd_reset + * - wpmem_page_user_edit */ @@ -383,4 +390,4 @@ function wpmem_page_user_edit( $wpmem_regchk, $content ) { } endif; -/** End of File **/ \ No newline at end of file +// End of file. \ No newline at end of file diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 221ea688..d24593e5 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -13,6 +13,15 @@ * @subpackage WP-Members * @author Chad Butler * @copyright 2006-2015 + * + * Functions Included: + * - wpmem_sc_forms + * - wpmem_sc_logged_in + * - wpmem_sc_logged_out + * - wpmem_shortcode + * - wpmem_do_sc_pages + * - wpmem_do_sc_pages + * - wpmem_sc_user_count */ @@ -512,4 +521,4 @@ function wpmem_sc_user_count( $atts, $content = null ) { return ( $do_query ) ? $atts['label'] . $user_meta_query : ''; } - /** End of File **/ \ No newline at end of file +// End of file. \ No newline at end of file From 3cea6c16b4dcab66093f476e68834d221179d6dd Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 18 Aug 2015 13:20:38 -0500 Subject: [PATCH 0143/1694] corrected redirect_to parameter functionality for register form shortcode --- inc/forms.php | 6 +++++- inc/register.php | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/inc/forms.php b/inc/forms.php index ad8081f6..b5a9302b 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -804,6 +804,9 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = $redirect_to = ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : ( ( $redirect_to ) ? $redirect_to : get_permalink() ); $hidden = '' . $n; $hidden .= '' . $n; + if ( $redirect_to != get_permalink() ) { + $hidden.= '' . $n; + } $hidden = ( isset( $hidden_tos ) ) ? $hidden . $hidden_tos . $n : $hidden; /** @@ -865,7 +868,8 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = // apply form wrapper $enctype = ( $enctype == 'multipart/form-data' ) ? ' enctype="multipart/form-data"' : ''; - $form = '

    ' . $n . $form. $n . '
    '; + $post_to = ( $redirect_to ) ? $redirect_to : get_permalink(); + $form = '
    ' . $n . $form. $n . '
    '; // apply anchor $form = '' . $n . $form; diff --git a/inc/register.php b/inc/register.php index 49966eda..6ee11cc0 100644 --- a/inc/register.php +++ b/inc/register.php @@ -227,7 +227,7 @@ function wpmem_registration( $toggle ) { $fields['user_registered'] = gmdate( 'Y-m-d H:i:s' ); $fields['user_role'] = get_option( 'default_role' ); $fields['wpmem_reg_ip'] = $_SERVER['REMOTE_ADDR']; - $fields['wpmem_reg_url'] = $_REQUEST['redirect_to']; + $fields['wpmem_reg_url'] = ( isset( $_REQUEST['wpmem_reg_page'] ) ) ? $_REQUEST['wpmem_reg_page'] : $_REQUEST['redirect_to']; /* * These native fields are not installed by default, but if they From f2c3aa94679f5dd9eb1f72d0fbd69284d04f2141 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 18 Aug 2015 13:30:43 -0500 Subject: [PATCH 0144/1694] readme updates for 3.0.3 --- readme.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/readme.txt b/readme.txt index 97d64c28..c57e0ff4 100644 --- a/readme.txt +++ b/readme.txt @@ -139,11 +139,12 @@ WP-Members 3.0.0 is a major version release. Please be sure you have reviewed th * Bug fix recaptcha v2 decode json response on validation. * Bug fix typo in $wpmem object name in admin/user-profile.php. +* Bug fix message string variable in wpmem_msg_dialog_arr filter. * Fix register form shortcode redirect_to parameter. * Admin forms now use submit_button() function to generate submit button. * Changed localization to load on init action which will allow for more flexibility with filtering custom language files. * Added wpmem_localization_file and wpmem_localization_dir filters. -* Localizaiton checks for file in /wp-content/ language directory first, then loads plugin default. +* Localization checks for file in /wp-content/ language directory first, then loads plugin default. = 3.0.2 = From 58fc7650d351559ab58bb8196095b37a180c56ed Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 25 Aug 2015 08:04:56 -0500 Subject: [PATCH 0145/1694] lowered priority for the_content, added back global $wpmem_a, updated readme for 3.0.4 --- inc/class-wp-members.php | 10 +++++++--- inc/shortcodes.php | 4 ++-- readme.txt | 9 +++++++-- wp-members.php | 4 ++-- 4 files changed, 18 insertions(+), 9 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 490207df..211f20a6 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -78,11 +78,11 @@ function load_hooks() { add_action( 'wp_print_styles', 'wpmem_enqueue_style' ); // load the stylesheet if using the new forms // Add filters. - add_filter( 'the_content', array( $this, 'do_securify' ), 1, 1 ); + add_filter( 'the_content', array( $this, 'do_securify' ), 99 ); add_filter( 'allow_password_reset', 'wpmem_no_reset' ); // no password reset for non-activated users add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration add_filter( 'registration_errors', 'wpmem_wp_reg_validate', 10, 3 ); // native registration validation - add_filter( 'comments_open', 'wpmem_securify_comments', 20, 1 ); // securifies the comments + add_filter( 'comments_open', 'wpmem_securify_comments', 99 ); // securifies the comments // If registration is moderated, check for activation (blocks backend login by non-activated users). if ( $this->mod_reg == 1 ) { @@ -162,6 +162,10 @@ function get_action() { // Get the action being done (if any). $this->action = ( isset( $_REQUEST['a'] ) ) ? trim( $_REQUEST['a'] ) : ''; + // For backward compatibility with processes that check $wpmem_a. + global $wpmem_a; + $wpmem_a = $this->action; + // Get the regchk value (if any). $this->regchk = $this->get_regchk( $this->action ); } @@ -404,7 +408,7 @@ function do_securify( $content = null ) { // Fix the wptexturize. remove_filter( 'the_content', 'wpautop' ); remove_filter( 'the_content', 'wptexturize' ); - add_filter( 'the_content', 'wpmem_texturize', 99 ); + add_filter( 'the_content', 'wpmem_texturize', 999 ); } return $content; diff --git a/inc/shortcodes.php b/inc/shortcodes.php index d24593e5..bd536bf9 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -122,7 +122,7 @@ function wpmem_sc_forms( $atts, $content = null, $tag = 'wpmem_form' ) { // Fixes the wptexturize. remove_filter( 'the_content', 'wpautop' ); remove_filter( 'the_content', 'wptexturize' ); - add_filter( 'the_content', 'wpmem_texturize', 99 ); + add_filter( 'the_content', 'wpmem_texturize', 999 ); } // @todo - Look into shortcode_unautop(). /** End temporary texturize functions */ @@ -307,7 +307,7 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { // Fixes the wptexturize. remove_filter( 'the_content', 'wpautop' ); remove_filter( 'the_content', 'wptexturize' ); - add_filter( 'the_content', 'wpmem_texturize', 99 ); + add_filter( 'the_content', 'wpmem_texturize', 999 ); } return $content; } diff --git a/readme.txt b/readme.txt index c57e0ff4..a65af97a 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 Tested up to: 4.3 -Stable tag: 3.0.3 +Stable tag: 3.0.4 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,7 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.3 is feature and fix release. See the change log for detail. +WP-Members 3.0.4 is a functional improvement release. See the change log for details. WP-Members 3.0.0 is a major version release. Please be sure you have reviewed the changelog before upgrading. http://rkt.bz/v30 == Screenshots == @@ -135,6 +135,11 @@ WP-Members 3.0.0 is a major version release. Please be sure you have reviewed th == Changelog == += 3.0.4 = + +* Reintroduced the global action variable $wpmem_a for backward compatibility with certain add-ons, most notably the WP-Members MailChimp extension ( see http://rkt.bz/3b ). Users of this extension should upgrade. This variable had been replaced with the new WP-Members object class introduced in 3.0. However, users of older extensions and those that may have customziations with logic may be using this variable, so rather than force updating and upgrading, it is being added back in. +* Change to the priority of functions hooked to the the_content filter. Lowering the priority should better integrate the plugin with various builder plugins and other processes that currently filter the_content after WP-Members since the content will now be filtered later in the process. This also should improve situations where in the past the on-the-fly texturization shortcode for the WP-Members forms might remain unparsed. + = 3.0.3 = * Bug fix recaptcha v2 decode json response on validation. diff --git a/wp-members.php b/wp-members.php index 30987ad4..498113c9 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.3 +Version: 3.0.4 Author: Chad Butler Author URI: http://butlerblog.com/ License: GPLv2 @@ -60,7 +60,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.3' ); +define( 'WPMEM_VERSION', '3.0.4' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 11f9e1f8f555137686f54ee8bf6041e342a38e54 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 09:03:29 -0500 Subject: [PATCH 0146/1694] fixes preparing for wordpress.org translation import: added missing text domain, fixed error on loading language pack from new location. --- wp-members.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/wp-members.php b/wp-members.php index 498113c9..b57eefd3 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,9 +3,10 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.4 +Version: 3.0.5 Author: Chad Butler Author URI: http://butlerblog.com/ +Text Domain: wp-members License: GPLv2 */ @@ -60,7 +61,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.4' ); +define( 'WPMEM_VERSION', '3.0.5' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); @@ -295,7 +296,7 @@ function wpmem_load_textdomain() { */ $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . $domain . '/' . $domain . '-' . $locale . '.mo' ); - if ( $loaded = load_textdomain( $domain, $file ) ) { + if ( $loaded == load_textdomain( $domain, $file ) ) { return $loaded; } else { From 02fb76765b1047ea97280cf18c8a3f38d7db1953 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 09:04:56 -0500 Subject: [PATCH 0147/1694] cleanup of some stylesheets: added some needed properties, adjustments to responsive elements. --- css/generic-no-float.css | 1 + css/generic-rigid.css | 1 + css/wp-members-2014-no-float.css | 25 +++++++++++++ css/wp-members-2014.css | 25 +++++++++++++ css/wp-members-2015-no-float.css | 43 +++++---------------- css/wp-members-2015.css | 64 ++++++++++++++------------------ 6 files changed, 90 insertions(+), 69 deletions(-) diff --git a/css/generic-no-float.css b/css/generic-no-float.css index 6c745c24..f60e8623 100644 --- a/css/generic-no-float.css +++ b/css/generic-no-float.css @@ -195,6 +195,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ } #wpmem_login .link-text { width: 74%; + text-align:right; } #tos { diff --git a/css/generic-rigid.css b/css/generic-rigid.css index b00043d8..7e5d882c 100644 --- a/css/generic-rigid.css +++ b/css/generic-rigid.css @@ -246,6 +246,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ #wpmem_login .link-text { width: 100%; float:right; + text-align:right; } diff --git a/css/wp-members-2014-no-float.css b/css/wp-members-2014-no-float.css index 01ec68b9..9e5f00d7 100644 --- a/css/wp-members-2014-no-float.css +++ b/css/wp-members-2014-no-float.css @@ -59,6 +59,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ #wp-members input[type="text"], #wp-members input[type="password"]{ margin: 0 0 4px 0; + width: 92%; } #wp-members input[type="submit"] { padding: 5px 6px 4px; @@ -162,6 +163,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ } #wpmem_login .link-text { width: 74%; + text-align:right; } #tos { @@ -181,6 +183,29 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ /** for smaller screens */ +@media screen and (max-width: 1079px) { + #wp-members .button_div { + text-align:center; + } + #wp-members input[type="submit"] { + width: 92%; + margin: 0 10px 6px 0; + } +} + +@media screen and (max-width: 1007px) { + #wp-members { + width: 179px; + } + #wp-members .button_div { + text-align: inherit; + } + #wp-members input[type="submit"] { + width: inherit; + margin: 0 4px 0 0; + } +} + @media screen and (max-width: 720px) { #wpmem_reg label.text, #wpmem_reg label.checkbox, #wpmem_reg label.textarea , #wpmem_reg label.select, diff --git a/css/wp-members-2014.css b/css/wp-members-2014.css index da7e4b2d..f84a02fe 100644 --- a/css/wp-members-2014.css +++ b/css/wp-members-2014.css @@ -54,6 +54,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ #wp-members input[type="text"], #wp-members input[type="password"]{ margin: 0 0 4px 0; + width: 92%; } #wp-members input[type="submit"] { padding: 5px 6px 4px; @@ -192,6 +193,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ #wpmem_login .link-text { float:right; width:100%; + text-align:right; } @@ -208,6 +210,29 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ /** for smaller screens */ +@media screen and (max-width: 1079px) { + #wp-members .button_div { + text-align:center; + } + #wp-members input[type="submit"] { + width: 92%; + margin: 0 10px 6px 0; + } +} + +@media screen and (max-width: 1007px) { + #wp-members { + width: 179px; + } + #wp-members .button_div { + text-align: inherit; + } + #wp-members input[type="submit"] { + width: inherit; + margin: 0 4px 0 0; + } +} + @media screen and (max-width: 720px) { #wpmem_reg label.text, #wpmem_reg label.checkbox, #wpmem_reg label.textarea , #wpmem_reg label.select, diff --git a/css/wp-members-2015-no-float.css b/css/wp-members-2015-no-float.css index 9f27e045..5bc34b0d 100644 --- a/css/wp-members-2015-no-float.css +++ b/css/wp-members-2015-no-float.css @@ -44,9 +44,8 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ width: 100%; } .wpmem_msg { - width: 74%; margin: 0; - padding: 28px 26px 4px; + padding: 32px 26px 4px; } @@ -56,22 +55,22 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ width: 100%; } #wp-members fieldset { - border:none; - padding:0px + border: none; + padding: 10px 0 0 0; } #wp-members input { font-family: inherit; } #wp-members input[type="text"], #wp-members input[type="password"]{ - margin: 0 0 4px 0; + margin: 0 0 8px 0; } #wp-members input[type="submit"] { - padding: 5px 6px 4px; - margin: 0 4px 0 0; + padding: 5px 10px; + margin: 0 6px 0 0; } #wp-members .button_div { - margin-top:4px; + margin-top: 8px; } #wp-members .err { width:100%; @@ -83,9 +82,6 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ /* Login Form and Registration Form */ -#wpmem_reg, #wpmem_login { - -} #wpmem_reg label, #wpmem_login label { @@ -101,28 +97,6 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ margin-bottom: 6px; } -#wpmem_reg input[type="text"], -#wpmem_reg textarea, -#wpmem_login input[type="text"], -#wpmem_login input[type="password"] { - -} - -#wpmem_reg input, -#wpmem_reg button, -#wpmem_reg select, -#wpmem_reg textarea, -#wpmem_login input, -#wpmem_login button { - -} - -#wpmem_reg input:focus, -#wpmem_reg textarea:focus, -#wpmem_login input:focus { - -} - #wpmem_reg select { width:100%; padding: 8px 10px 7px; @@ -200,6 +174,8 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ } #wpmem_login .link-text { width: 74%; + margin: 4px 0; + text-align: right; } #tos { @@ -241,6 +217,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ #wpmem_reg .div_select, #wpmem_login .div_text, #wpmem_reg .div_checkbox { width: 98%; + font-size: 80%; } #wpmem_msg, .wpmem_msg { width: 100%; diff --git a/css/wp-members-2015.css b/css/wp-members-2015.css index 0d034641..df6a8310 100644 --- a/css/wp-members-2015.css +++ b/css/wp-members-2015.css @@ -45,7 +45,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ } .wpmem_msg { margin: 0; - padding: 28px 26px 4px; + padding: 32px 26px 4px; } @@ -55,8 +55,8 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ width: 100%; } #wp-members fieldset { - border:none; - padding:0px + border: none; + padding: 0px } #wp-members input { font-family: inherit; @@ -69,12 +69,12 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ padding: 5px 6px 4px; margin: 0 4px 0 0; } -#wp-members .button_div { - margin-top:4px; +#wp-members .button_div { + margin-top: 4px; } #wp-members .err { width:100%; - padding: 5px; + padding: 5px; font-family: inherit; background: #F7F7F7; border: 1px solid rgba(51, 51, 51, 0.3); @@ -82,32 +82,6 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ /* Login Form and Registration Form */ -#wpmem_reg, #wpmem_login { - -} - -#wpmem_reg input[type="text"], -#wpmem_reg textarea, -#wpmem_login input[type="text"], -#wpmem_login input[type="password"] { - -} - -#wpmem_reg input, -#wpmem_reg button, -#wpmem_reg select, -#wpmem_reg textarea, -#wpmem_login input, -#wpmem_login button { - -} - -#wpmem_reg input:focus, -#wpmem_reg textarea:focus, -#wpmem_login input:focus { - -} - #wpmem_reg select { width:100%; padding: 6px 10px 7px; @@ -124,15 +98,16 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ font-size: 24px; line-height: 1; font-weight: 700; - margin-bottom: 10px; + margin-bottom: 30px; } #wpmem_reg label.text, #wpmem_reg label.checkbox, -#wpmem_reg label.textarea , #wpmem_reg label.select, +#wpmem_reg label.textarea, #wpmem_reg label.select, #wpmem_login label { height: 30px; width:32%; float:left; padding: 12px 0px 0px; + -webkit-padding: 15px 0px 0px; margin: 0px 0px 14px; height: 49px; } @@ -147,7 +122,10 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ letter-spacing: 0.04em; line-height: 1.5; text-transform: uppercase; - margin-bottom: 6px; + margin-bottom: 13px; +} +#wpmem_reg label.textarea { + height: 185px; } #wpmem_reg .form, #wpmem_login .form { margin:0; @@ -166,7 +144,13 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ float:right; margin:0 0 14px 0; } -#wpmem_reg .div_checkbox { height: 49px; } +#wpmem_reg .div_text, #wpmem_reg .div_select, +#wpmem_login .div_text, #wpmem_reg .div_checkbox { + height: 49px; +} +#wpmem_reg .div_checkbox { + padding: 9px 0; +} #wpmem_login input[type="checkbox"] { margin: 18px 2px; } @@ -189,6 +173,8 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ #wpmem_reg .req-text { margin: 20px 0px 0px 5px; + display: inline-block; + width: 100%; } #wpmem_reg .noinput { @@ -209,7 +195,9 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ } #wpmem_login .link-text { width: 100%; + margin: 4px 0; float: right; + text-align: right; } #tos { @@ -242,6 +230,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ #wpmem_reg label.text, #wpmem_reg label.checkbox, #wpmem_reg label.textarea , #wpmem_reg label.select, #wpmem_login label { + height: 20px; width: 90%; padding: 5px 0 0 0; } @@ -253,6 +242,9 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ #wpmem_reg .div_checkbox { width: 98%; } + #wpmem_reg .div_text { + font-size: 80%; + } #wpmem_msg, .wpmem_msg { width: 100%; } From a4115c0832b269f4241a4caf558bc0f86684ecc8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 09:06:17 -0500 Subject: [PATCH 0148/1694] fix to load tinymce shortcode button on new post/page (previously was only loading on edit). --- admin/post.php | 1 + inc/class-wp-members-tinymce-buttons.php | 35 ++++++++++++++++++------ 2 files changed, 28 insertions(+), 8 deletions(-) diff --git a/admin/post.php b/admin/post.php index 4ad6de00..09530340 100644 --- a/admin/post.php +++ b/admin/post.php @@ -34,6 +34,7 @@ add_action( 'load-edit.php', 'wpmem_posts_page_load' ); add_action( 'admin_notices', 'wpmem_posts_admin_notices' ); add_action( 'load-post.php', 'wpmem_load_tinymce' ); +add_action( 'load-post-new.php', 'wpmem_load_tinymce' ); /** diff --git a/inc/class-wp-members-tinymce-buttons.php b/inc/class-wp-members-tinymce-buttons.php index 210bc62c..08667a61 100644 --- a/inc/class-wp-members-tinymce-buttons.php +++ b/inc/class-wp-members-tinymce-buttons.php @@ -6,20 +6,31 @@ */ class WP_Members_TinyMCE_Buttons { + /** + * Initialize WP-Members TinyMCE Button. + * + * @since 3.0 + */ function __construct() { - add_action( 'admin_head', array( &$this, 'init' ) ); - } - - function init() { - if ( ! current_user_can( 'edit_posts' ) && ! current_user_can( 'edit_pages' ) ) - return; + + if ( ! current_user_can( 'edit_posts' ) && ! current_user_can( 'edit_pages' ) ) { + return; + } - if ( get_user_option('rich_editing') == 'true' ) { + if ( get_user_option( 'rich_editing' ) == 'true' ) { add_filter( 'mce_external_plugins', array( &$this, 'add_plugin' ) ); add_filter( 'mce_buttons', array( &$this, 'register_button' ) ); } } + /** + * Load the correct plugin file. + * + * @since 3.0 + * + * @param array $plugin_array + * @return array $plugin_array + */ function add_plugin( $plugin_array ) { $ver = WPMEM_VERSION; @@ -32,7 +43,15 @@ function add_plugin( $plugin_array ) { } return $plugin_array; } - + + /** + * Register the button. + * + * @since 3.0 + * + * @param array $buttons + * @return array $buttons + */ function register_button( $buttons ) { array_push( $buttons, "wpmem_shortcodes_button" ); return $buttons; From 0884053f7f5c77fa8221a8e4ac28aa3544b3dc7b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 09:06:51 -0500 Subject: [PATCH 0149/1694] added password parameter to wpmem_pwd_change and wpmem_pwd_reset actions --- inc/core.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/inc/core.php b/inc/core.php index 449ae8fa..8f6de588 100644 --- a/inc/core.php +++ b/inc/core.php @@ -309,9 +309,10 @@ function wpmem_change_password() { * * @since 2.9.0 * - * @param int $user_ID The user's numeric ID. + * @param int $user_ID The user's numeric ID. + * @param string $pass1 The user's new plain text password. */ - do_action( 'wpmem_pwd_change', $user_ID ); + do_action( 'wpmem_pwd_change', $user_ID, $pass1 ); return "pwdchangesuccess"; @@ -382,9 +383,10 @@ function wpmem_reset_password() { * * @since 2.9.0 * - * @param int $user_ID The user's numeric ID. + * @param int $user_ID The user's numeric ID. + * @param string $new_pass The new plain text password. */ - do_action( 'wpmem_pwd_reset', $user->ID ); + do_action( 'wpmem_pwd_reset', $user->ID, $new_pass ); return "pwdresetsuccess"; } From 4b06dba24439983d36a865edc2a067e7d81d59d8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 09:07:16 -0500 Subject: [PATCH 0150/1694] added 'wp-members' to tinymce button for clarity --- js/shortcodes_tinymce_4.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/shortcodes_tinymce_4.js b/js/shortcodes_tinymce_4.js index 4bdc547e..155f3e0f 100644 --- a/js/shortcodes_tinymce_4.js +++ b/js/shortcodes_tinymce_4.js @@ -9,7 +9,7 @@ editor.addButton('wpmem_shortcodes_button', function() { return { title: "WP-Members Shortcodes", - text: "[ ]", + text: "[WP-Members]", type: 'menubutton', icons: false, menu: [ From 8f3be231ac7335cd3b38afe1b6842eb3eb4ac6b6 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 10:49:34 -0500 Subject: [PATCH 0151/1694] moved admin js and css to /admin/js/ and /admin/css/ folders --- admin/admin.php | 4 +- {css => admin/css}/admin.css | 90 ++++++++++++++++++------------------ {js => admin/js}/admin.js | 0 3 files changed, 47 insertions(+), 47 deletions(-) rename {css => admin/css}/admin.css (94%) rename {js => admin/js}/admin.js (100%) diff --git a/admin/admin.php b/admin/admin.php index 1aa48ec4..bc0f0b7d 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -85,8 +85,8 @@ function wpmem_admin_plugin_links( $links, $file ) { */ function wpmem_load_admin_js() { // Queue up admin ajax and styles. - wp_enqueue_script( 'wpmem-admin-js', WPMEM_DIR . 'js/admin.js', '', WPMEM_VERSION ); - wp_enqueue_style ( 'wpmem-admin-css', WPMEM_DIR . 'css/admin.css', '', WPMEM_VERSION ); + wp_enqueue_script( 'wpmem-admin-js', WPMEM_DIR . 'admin/js/admin.js', '', WPMEM_VERSION ); + wp_enqueue_style ( 'wpmem-admin-css', WPMEM_DIR . 'admin/css/admin.css', '', WPMEM_VERSION ); } diff --git a/css/admin.css b/admin/css/admin.css similarity index 94% rename from css/admin.css rename to admin/css/admin.css index 3c33bde4..31dcaef1 100644 --- a/css/admin.css +++ b/admin/css/admin.css @@ -1,46 +1,46 @@ -/** - * WP-Members Admin Styles CSS - * - * CSS for the WP-Members admin panels - * - * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2015 Chad Butler - * WP-Members(tm) is a trademark of butlerblog.com - * - * @package WordPress - * @subpackage WP-Members - * @author Chad Butler - * @copyright 2006-2015 - */ - - -.wpmem_tbl_drag { - background:#fffbcc; - font-weight: bold; - border: 1px solid #990000; -} - -.column-wpmem_block { - width: 80px; -} - -#addfieldform li, -#updatesettings li { - padding: 5px 0; -} - -#addfieldform label, -#updatesettings label { - float:left; - width: 166px; -} - -#addfieldform .add-field-indent { - margin-left: 165px; -} - -#fields_postbox, -#add_field_postbox{ - min-width:950px; +/** + * WP-Members Admin Styles CSS + * + * CSS for the WP-Members admin panels + * + * This file is part of the WP-Members plugin by Chad Butler + * You can find out more about this plugin at http://rocketgeek.com + * Copyright (c) 2006-2015 Chad Butler + * WP-Members(tm) is a trademark of butlerblog.com + * + * @package WordPress + * @subpackage WP-Members + * @author Chad Butler + * @copyright 2006-2015 + */ + + +.wpmem_tbl_drag { + background:#fffbcc; + font-weight: bold; + border: 1px solid #990000; +} + +.column-wpmem_block { + width: 80px; +} + +#addfieldform li, +#updatesettings li { + padding: 5px 0; +} + +#addfieldform label, +#updatesettings label { + float:left; + width: 166px; +} + +#addfieldform .add-field-indent { + margin-left: 165px; +} + +#fields_postbox, +#add_field_postbox{ + min-width:950px; } \ No newline at end of file diff --git a/js/admin.js b/admin/js/admin.js similarity index 100% rename from js/admin.js rename to admin/js/admin.js From cd807cebc3d573e7e5688d3a8cbb242c6cd0ef01 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 10:51:06 -0500 Subject: [PATCH 0152/1694] moved tinymce button include to /admin/includes/ and scripts to /admin/js/ --- {inc => admin/includes}/class-wp-members-tinymce-buttons.php | 4 ++-- {js => admin/js}/shortcodes_tinymce.js | 0 {js => admin/js}/shortcodes_tinymce_4.js | 0 admin/post.php | 2 +- 4 files changed, 3 insertions(+), 3 deletions(-) rename {inc => admin/includes}/class-wp-members-tinymce-buttons.php (85%) rename {js => admin/js}/shortcodes_tinymce.js (100%) rename {js => admin/js}/shortcodes_tinymce_4.js (100%) diff --git a/inc/class-wp-members-tinymce-buttons.php b/admin/includes/class-wp-members-tinymce-buttons.php similarity index 85% rename from inc/class-wp-members-tinymce-buttons.php rename to admin/includes/class-wp-members-tinymce-buttons.php index 08667a61..5fcd9704 100644 --- a/inc/class-wp-members-tinymce-buttons.php +++ b/admin/includes/class-wp-members-tinymce-buttons.php @@ -37,9 +37,9 @@ function add_plugin( $plugin_array ) { // WP version 3.9 updated to tinymce 4.0 if ( version_compare( get_bloginfo( 'version' ), '3.9', '>=' ) ) { - $plugin_array['wpmem_shortcodes'] = WPMEM_DIR .'js/shortcodes_tinymce_4.js?ver=' . $ver; + $plugin_array['wpmem_shortcodes'] = WPMEM_DIR .'admin/js/shortcodes_tinymce_4.js?ver=' . $ver; } else { - $plugin_array['wpmem_shortcodes'] = WPMEM_DIR .'js/shortcodes_tinymce.js?ver=' . $ver; + $plugin_array['wpmem_shortcodes'] = WPMEM_DIR .'admin/js/shortcodes_tinymce.js?ver=' . $ver; } return $plugin_array; } diff --git a/js/shortcodes_tinymce.js b/admin/js/shortcodes_tinymce.js similarity index 100% rename from js/shortcodes_tinymce.js rename to admin/js/shortcodes_tinymce.js diff --git a/js/shortcodes_tinymce_4.js b/admin/js/shortcodes_tinymce_4.js similarity index 100% rename from js/shortcodes_tinymce_4.js rename to admin/js/shortcodes_tinymce_4.js diff --git a/admin/post.php b/admin/post.php index 09530340..5d3854de 100644 --- a/admin/post.php +++ b/admin/post.php @@ -351,7 +351,7 @@ function wpmem_load_tinymce() { // @todo For now, only load if WP version is high enough. if ( version_compare( get_bloginfo( 'version' ), '3.9', '>=' ) ) { global $wpmem_shortcode; - include( WPMEM_PATH . 'inc/class-wp-members-tinymce-buttons.php' ); + include( WPMEM_PATH . 'admin/includes/class-wp-members-tinymce-buttons.php' ); $wpmem_shortcode = new WP_Members_TinyMCE_Buttons; } } From 768f43b1135350e0e84b3e0c0e158185558d3dce Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 10:51:54 -0500 Subject: [PATCH 0153/1694] moved sortable user columns to /admin/includes/ --- ...class-wp-members-sortable-user-columns.php | 116 ++++++++++++++++++ admin/users.php | 6 +- ...class-wp-members-sortable-user-columns.php | 66 ---------- 3 files changed, 119 insertions(+), 69 deletions(-) create mode 100644 admin/includes/class-wp-members-sortable-user-columns.php delete mode 100644 inc/class-wp-members-sortable-user-columns.php diff --git a/admin/includes/class-wp-members-sortable-user-columns.php b/admin/includes/class-wp-members-sortable-user-columns.php new file mode 100644 index 00000000..78b5ce6e --- /dev/null +++ b/admin/includes/class-wp-members-sortable-user-columns.php @@ -0,0 +1,116 @@ + +args = $args; + add_action( 'pre_user_query', array(&$this, 'query' ) ); + add_action( 'manage_users_custom_column', array( &$this, 'content' ), 10, 3 ); + add_filter( 'manage_users_columns', array( &$this, 'columns' ) ); + add_filter( 'manage_users_sortable_columns', array( &$this, 'sortable') ); + } + + /** + * Prequery function. + * + * @since 3.1 + * + * @param string $query + */ + function query( $query ) { + global $wpdb; + $vars = $query->query_vars; + if ( in_array( $vars['orderby'], $this->defaults ) ) { + return; + } + $title = $this->args[ $vars['orderby'] ]; + if ( ! empty( $title ) ) { + $query->query_from .= " LEFT JOIN " . $wpdb->prefix . "usermeta m ON (" . $wpdb->prefix . "users.ID = m.user_id AND m.meta_key = '" . $vars['orderby'] . "')"; + $query->query_orderby = "ORDER BY m.meta_value " . $vars['order']; + } + } + + /** + * Columns function. + * + * @since 3.1 + * + * @param array $columns + */ + function columns( $columns ) { echo 'you are here'; + foreach ( $this->args as $key => $value ) { + $columns[ $key ] = $value; + } + return $columns; + } + + /** + * Column sorting function. + * + * @since 3.1 + * + * @param array $columns + */ + function sortable( $columns ) { + $custom = array(); + foreach ( $this->args as $key => $value ) { + $custom[ $key ] = $key; + } + return wp_parse_args( $custom, $columns ); + } + + /** + * Column content function. + * + * @since 3.1 + * + * @param string $value + * @param string $column_name + * @param int $user_id + */ + function content( $value, $column_name, $user_id ) { + foreach ( $this->args as $key => $val ) { + if ( $column_name == $key ) { + $user = get_userdata( $user_id ); + return $user->$column_name; + } + } + return $value; + } +} +endif; \ No newline at end of file diff --git a/admin/users.php b/admin/users.php index d64d605c..a15081e4 100644 --- a/admin/users.php +++ b/admin/users.php @@ -299,9 +299,9 @@ function wpmem_add_user_column( $columns ) { $columns = array_merge( $columns, $wpmem_user_columns ); } - // @todo - needs to be debugged for use with external process custom columns. - // require_once( WPMEM_PATH . 'inc/class-wp-members-sortable-user-columns.php' ); - // new WP_Members_Sortable_User_Columns( $wpmem_user_columns ); + // Makes WP-Members columns sortable. + require_once( WPMEM_PATH . 'admin/includes/class-wp-members-sortable-user-columns.php' ); + new WP_Members_Sortable_User_Columns( $wpmem_user_columns ); return $columns; } diff --git a/inc/class-wp-members-sortable-user-columns.php b/inc/class-wp-members-sortable-user-columns.php deleted file mode 100644 index 8f2fe5ef..00000000 --- a/inc/class-wp-members-sortable-user-columns.php +++ /dev/null @@ -1,66 +0,0 @@ -args = ( is_array( $args ) ) ? $args : array(); - add_action( 'pre_user_query', array( &$this, 'query' ) ); - add_action( 'manage_users_custom_column', array( &$this, 'content' ), 10, 3 ); - add_filter( 'manage_users_columns', array( &$this, 'columns' ) ); - add_filter( 'manage_users_sortable_columns', array( &$this, 'sortable') ); - } - - function query( $query ) { - $vars = $query->query_vars; - if ( in_array( $vars['orderby'], $this->defaults ) ) { - return; - } - $title = $this->args[ $vars['orderby'] ]; - if ( ! empty( $title ) ) { - $query->query_from .= " LEFT JOIN wp_usermeta m ON (wp_users.ID = m.user_id AND m.meta_key = '" . $vars['orderby'] . "')"; - $query->query_orderby = "ORDER BY m.meta_value ".$vars['order']; - } - } - - function columns( $columns ) { - foreach ( $this->args as $key => $value ) { - $columns[ $key ] = $value; - } - return $columns; - } - - function sortable( $columns ) { - foreach ( $this->args as $key => $value ) { - $columns[ $key ] = $key; - } - return $columns; - } - - function content( $value, $column_name, $user_id ) { - $user = get_userdata( $user_id ); - return $user->$column_name; - } - -} \ No newline at end of file From 9343bddae273e2ed07b8f987af0132c423732a95 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 10:52:48 -0500 Subject: [PATCH 0154/1694] updated and verified that all folders contain an index.php file to prevent directory browsing --- admin/css/index.php | 1 + admin/includes/index.php | 1 + admin/index.php | 2 +- admin/js/index.php | 1 + css/index.php | 2 +- inc/index.php | 1 + index.php | 2 +- js/index.php | 1 - lang/index.php | 1 + lib/index.php | 2 +- 10 files changed, 9 insertions(+), 5 deletions(-) create mode 100644 admin/css/index.php create mode 100644 admin/includes/index.php create mode 100644 admin/js/index.php create mode 100644 inc/index.php delete mode 100644 js/index.php create mode 100644 lang/index.php diff --git a/admin/css/index.php b/admin/css/index.php new file mode 100644 index 00000000..dc051a13 --- /dev/null +++ b/admin/css/index.php @@ -0,0 +1 @@ + \ No newline at end of file + \ No newline at end of file + \ No newline at end of file + \ No newline at end of file diff --git a/lang/index.php b/lang/index.php new file mode 100644 index 00000000..dc051a13 --- /dev/null +++ b/lang/index.php @@ -0,0 +1 @@ + \ No newline at end of file + Date: Mon, 28 Sep 2015 10:53:11 -0500 Subject: [PATCH 0155/1694] fix to load_textdomain --- wp-members.php | 1 + 1 file changed, 1 insertion(+) diff --git a/wp-members.php b/wp-members.php index b57eefd3..eceddd72 100644 --- a/wp-members.php +++ b/wp-members.php @@ -296,6 +296,7 @@ function wpmem_load_textdomain() { */ $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . $domain . '/' . $domain . '-' . $locale . '.mo' ); + $loaded = false; if ( $loaded == load_textdomain( $domain, $file ) ) { return $loaded; } else { From 063fda120757dbcc61beffa45fabd280c350dc36 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 10:53:31 -0500 Subject: [PATCH 0156/1694] updates to native registration --- inc/wp-registration.php | 178 ++++++++++++++++++++-------------------- 1 file changed, 91 insertions(+), 87 deletions(-) diff --git a/inc/wp-registration.php b/inc/wp-registration.php index d825a070..73fe3857 100644 --- a/inc/wp-registration.php +++ b/inc/wp-registration.php @@ -31,111 +31,115 @@ function wpmem_do_wp_register_form() { global $wpmem; $wpmem_fields = $wpmem->fields; //$wpmem_fields = get_option( 'wpmembers_fields' ); - foreach ( $wpmem_fields as $field ) { - //for ( $row = 0; $row < count( $wpmem_fields ); $row++ ) { + if ( isset( $wpmem_fields ) && is_array( $wpmem_fields ) ) { + foreach ( $wpmem_fields as $field ) { + //for ( $row = 0; $row < count( $wpmem_fields ); $row++ ) { + + $req = ( $field[5] == 'y' ) ? ' ' . __( '(required)' ) . '' : ''; + + if ( $field[4] == 'y' && $field[2] != 'user_email' ) { + + if ( $field[3] == 'checkbox' ) { + + if ( $field[2] == 'tos' ) { + $tos_content = stripslashes( get_option( 'wpmembers_tos' ) ); + if ( stristr( $tos_content, '[wp-members page="tos"' ) ) { + + $tos_content = " " . $tos_content; + $ini = strpos( $tos_content, 'url="' ); + $ini += strlen( 'url="' ); + $len = strpos( $tos_content, '"]', $ini ) - $ini; + $link = substr( $tos_content, $ini, $len ); + $tos_pop = ''; + + } else { + $tos_pop = ""; + } + /** + * Filter the TOS link text. + * + * When this filter is used for the WP native registration, the $toggle parameter is not passed. + * + * @since 2.7.5 + * + * @param string The text and link for the TOS. + */ + $tos = apply_filters( 'wpmem_tos_link_txt', sprintf( __( 'Please indicate that you agree to the %s TOS %s', 'wp-members' ), $tos_pop, '' ) ); + + } - $req = ( $field[5] == 'y' ) ? ' ' . __( '(required)' ) . '' : ''; + $label = ( $field[2] == 'tos' ) ? $tos : __( $field[1], 'wp-members' ); - if ( $field[4] == 'y' && $field[2] != 'user_email' ) { - - if ( $field[3] == 'checkbox' ) { + $val = ( isset( $_POST[ $field[2] ] ) ) ? $_POST[ $field[2] ] : ''; + $val = ( ! $_POST && $field[8] == 'y' ) ? $field[7] : $val; - if ( $field[2] == 'tos' ) { - $tos_content = stripslashes( get_option( 'wpmembers_tos' ) ); - if ( stristr( $tos_content, '[wp-members page="tos"' ) ) { + $row_before = '

    '; + $label = '

    '; - $tos_content = " " . $tos_content; - $ini = strpos( $tos_content, 'url="' ); - $ini += strlen( 'url="' ); - $len = strpos( $tos_content, '"]', $ini ) - $ini; - $link = substr( $tos_content, $ini, $len ); - $tos_pop = ''; + } else { - } else { - $tos_pop = ""; - } - /** - * Filter the TOS link text. - * - * When this filter is used for the WP native registration, the $toggle parameter is not passed. - * - * @since 2.7.5 - * - * @param string The text and link for the TOS. - */ - $tos = apply_filters( 'wpmem_tos_link_txt', sprintf( __( 'Please indicate that you agree to the %s TOS %s', 'wp-members' ), $tos_pop, '' ) ); - - } + $row_before = '

    '; + $label = '

    '; - $label = '

    '; + case( 'select' ): + $val = ( isset( $_POST[ $field[2] ] ) ) ? $_POST[ $field[2] ] : ''; + $input = wpmem_create_formfield( $field[2], $field[3], $field[7], $val ); + break; - } else { + case( 'textarea' ): + $input = ''; + break; - $row_before = '

    '; - $label = '

    '; - case( 'select' ): - $val = ( isset( $_POST[ $field[2] ] ) ) ? $_POST[ $field[2] ] : ''; - $input = wpmem_create_formfield( $field[2], $field[3], $field[7], $val ); - break; - - case( 'textarea' ): - $input = ''; - break; - - default: - $input = ''; - break; } - $row_after = '

    '; - + // if the row is set to display, add the row to the form array + $rows[$field[2]] = array( + 'type' => $field[3], + 'row_before' => $row_before, + 'label' => $label, + 'field' => $input, + 'row_after' => $row_after, + ); } - - // if the row is set to display, add the row to the form array - $rows[$field[2]] = array( - 'type' => $field[3], - 'row_before' => $row_before, - 'label' => $label, - 'field' => $input, - 'row_after' => $row_after, - ); } - } - - /** - * Filter the native registration form rows. - * - * @since 2.9.3. - * - * @param array $rows The custom rows added to the form. - */ - $rows = apply_filters( 'wpmem_native_form_rows', $rows ); - - foreach ( $rows as $row_item ) { - if ( $row_item['type'] == 'checkbox' ) { - echo $row_item['row_before'] . $row_item['field'] . $row_item['label'] . $row_item['row_after']; - } else { - echo $row_item['row_before'] . $row_item['label'] . $row_item['field'] . $row_item['row_after']; + + if ( isset( $rows ) && is_array( $rows ) ) { + + /** + * Filter the native registration form rows. + * + * @since 2.9.3. + * + * @param array $rows The custom rows added to the form. + */ + $rows = apply_filters( 'wpmem_native_form_rows', $rows ); + + foreach ( $rows as $row_item ) { + if ( $row_item['type'] == 'checkbox' ) { + echo $row_item['row_before'] . $row_item['field'] . $row_item['label'] . $row_item['row_after']; + } else { + echo $row_item['row_before'] . $row_item['label'] . $row_item['field'] . $row_item['row_after']; + } + } } } - } From 87dc1d0961e01ec0d0bf8fc23fd477c4f1529f7f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 13:11:44 -0500 Subject: [PATCH 0157/1694] rolling back sortable custom user columns for 3.0.5 --- ...class-wp-members-sortable-user-columns.php | 51 +++++++++++++------ admin/users.php | 7 +-- 2 files changed, 39 insertions(+), 19 deletions(-) diff --git a/admin/includes/class-wp-members-sortable-user-columns.php b/admin/includes/class-wp-members-sortable-user-columns.php index 78b5ce6e..57cb433a 100644 --- a/admin/includes/class-wp-members-sortable-user-columns.php +++ b/admin/includes/class-wp-members-sortable-user-columns.php @@ -3,7 +3,7 @@ /** * WP-Members Sortable Columns Class. * - * @since 3.1 + * @since 3.0 */ if( ! class_exists( 'WP_Members_Sortable_User_Columns' ) ): @@ -33,22 +33,24 @@ class WP_Members_Sortable_User_Columns /** * Initial contruct function. * - * @since 3.1 + * @since 3.0 * * @param array $args */ function __construct( $args ) { $this->args = $args; - add_action( 'pre_user_query', array(&$this, 'query' ) ); - add_action( 'manage_users_custom_column', array( &$this, 'content' ), 10, 3 ); - add_filter( 'manage_users_columns', array( &$this, 'columns' ) ); - add_filter( 'manage_users_sortable_columns', array( &$this, 'sortable') ); + //add_action( 'pre_user_query', array(&$this, 'query' ) ); + add_action( 'manage_users_custom_column', array( &$this, 'column_content' ), 10, 3 ); + add_filter( 'manage_users_columns', array( &$this, 'add_to_columns' ) ); + add_filter( 'manage_users_sortable_columns', array( &$this, 'make_column_sortable') ); + + add_filter( 'request', array( &$this, 'custom_column_orderby' ) ); } /** * Prequery function. * - * @since 3.1 + * @since 3.0 * * @param string $query */ @@ -66,13 +68,13 @@ function query( $query ) { } /** - * Columns function. + * Adds selected WP-Members columns to the Users > All Users columns. * - * @since 3.1 + * @since 3.0 * * @param array $columns */ - function columns( $columns ) { echo 'you are here'; + function add_to_columns( $columns ) { foreach ( $this->args as $key => $value ) { $columns[ $key ] = $value; } @@ -80,13 +82,13 @@ function columns( $columns ) { echo 'you are here'; } /** - * Column sorting function. + * Sets selected WP-Members columns as sortable. * - * @since 3.1 + * @since 3.0 * * @param array $columns */ - function sortable( $columns ) { + function make_column_sortable( $columns ) { $custom = array(); foreach ( $this->args as $key => $value ) { $custom[ $key ] = $key; @@ -95,15 +97,15 @@ function sortable( $columns ) { } /** - * Column content function. + * Returns the column content value for WP-Members selected columns. * - * @since 3.1 + * @since 3.0 * * @param string $value * @param string $column_name * @param int $user_id */ - function content( $value, $column_name, $user_id ) { + function column_content( $value, $column_name, $user_id ) { foreach ( $this->args as $key => $val ) { if ( $column_name == $key ) { $user = get_userdata( $user_id ); @@ -112,5 +114,22 @@ function content( $value, $column_name, $user_id ) { } return $value; } + + /** + * Sort custom column. + * + * @since 3.0.5 + */ + function custom_column_orderby( $vars ) { + foreach ( $this->args as $key => $val ) { + if ( isset( $vars[ $key ] ) && $val == $vars[ $key ] ) { + $vars = array_merge( $vars, array( + 'meta_key' => $key, + 'orderby' => $key, + ) ); + } + } + return $vars; + } } endif; \ No newline at end of file diff --git a/admin/users.php b/admin/users.php index a15081e4..75818647 100644 --- a/admin/users.php +++ b/admin/users.php @@ -298,10 +298,11 @@ function wpmem_add_user_column( $columns ) { $columns = array_merge( $columns, $wpmem_user_columns ); } - + // Makes WP-Members columns sortable. - require_once( WPMEM_PATH . 'admin/includes/class-wp-members-sortable-user-columns.php' ); - new WP_Members_Sortable_User_Columns( $wpmem_user_columns ); + // @todo - finish debugging class or add sortable functions to users.php. + // require_once( WPMEM_PATH . 'admin/includes/class-wp-members-sortable-user-columns.php' ); + // new WP_Members_Sortable_User_Columns( $wpmem_user_columns ); return $columns; } From 8d7e0b16d6ba8c94ff5a708e2dc7171c44eaac34 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 14:55:01 -0500 Subject: [PATCH 0158/1694] updated readme for 3.0.5 release --- readme.txt | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/readme.txt b/readme.txt index a65af97a..9876bcdb 100644 --- a/readme.txt +++ b/readme.txt @@ -2,8 +2,8 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 -Tested up to: 4.3 -Stable tag: 3.0.4 +Tested up to: 4.3.1 +Stable tag: 3.0.5 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,7 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.4 is a functional improvement release. See the change log for details. +WP-Members 3.0.5 is primarily a functional improvement release with minimal core changes. See the change log for details. WP-Members 3.0.0 is a major version release. Please be sure you have reviewed the changelog before upgrading. http://rkt.bz/v30 == Screenshots == @@ -135,6 +135,16 @@ WP-Members 3.0.0 is a major version release. Please be sure you have reviewed th == Changelog == += 3.0.5 = + +* Updated wpmem_pwd_change and wpmem_pwd_reset action hooks to include password as a parameter. +* Stylesheet updates for 2015, 2014, and generic (both float and no float). +* Fix to TinyMCE shortcode button, should now load button on new post/page editor. +* Added [WP-Members] to the TinyMCE shortcode button for clarity as to what it is. +* Moved admin js and css files to /admin/js/ and /admin/css/ +* Moved admin class files to /admin/includes/ +* Updated and verified all directories contain an index.php file to prevent directory browsing. + = 3.0.4 = * Reintroduced the global action variable $wpmem_a for backward compatibility with certain add-ons, most notably the WP-Members MailChimp extension ( see http://rkt.bz/3b ). Users of this extension should upgrade. This variable had been replaced with the new WP-Members object class introduced in 3.0. However, users of older extensions and those that may have customziations with logic may be using this variable, so rather than force updating and upgrading, it is being added back in. From fee4615509eeeb84bc4c764dda816db6d87a2a4a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 28 Sep 2015 17:07:29 -0500 Subject: [PATCH 0159/1694] updated localization template (pot) --- lang/wp-members.pot | 419 ++++++++++++++++++++++++-------------------- 1 file changed, 233 insertions(+), 186 deletions(-) diff --git a/lang/wp-members.pot b/lang/wp-members.pot index ba324800..13306594 100644 --- a/lang/wp-members.pot +++ b/lang/wp-members.pot @@ -1,20 +1,23 @@ msgid "" msgstr "" -"Project-Id-Version: WP-Members\n" -"POT-Creation-Date: 2015-06-16 12:01-0600\n" -"PO-Revision-Date: 2015-06-16 12:01-0600\n" +"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" +"Project-Id-Version: WP-Members 3.0.5\n" +"POT-Creation-Date: 2015-09-28 16:50-0500\n" +"PO-Revision-Date: 2015-09-28 16:47-0500\n" "Last-Translator: \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 1.6.4\n" +"X-Generator: Poedit 1.8.5\n" "X-Poedit-Basepath: ..\n" +"X-Poedit-WPHeader: wp-members.php\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;" "esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c;_n_noop:1,2;" "_nx_noop:3c,1,2;__ngettext_noop:1,2\n" "X-Poedit-SearchPath-0: .\n" +"X-Poedit-SearchPathExcluded-0: *.js\n" #: admin/admin.php:71 admin/admin.php:138 msgid "Settings" @@ -36,20 +39,20 @@ msgstr "" msgid "Emails" msgstr "" -#: admin/dialogs.php:103 +#: admin/dialogs.php:105 msgid "" "Your WP settings allow anyone to register - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:104 +#: admin/dialogs.php:106 #, php-format msgid "" "You can %s change this here %s making sure the box next to \"Anyone can " "register\" is unchecked." msgstr "" -#: admin/dialogs.php:105 +#: admin/dialogs.php:107 msgid "" "This setting allows a link on the /wp-login.php page to register using the " "WP native registration process thus circumventing any registration you are " @@ -59,20 +62,20 @@ msgid "" "Settings." msgstr "" -#: admin/dialogs.php:109 +#: admin/dialogs.php:111 msgid "" "Your WP settings allow anyone to comment - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:110 +#: admin/dialogs.php:112 #, php-format msgid "" "You can %s change this here %s by checking the box next to \"Users must be " "registered and logged in to comment.\"" msgstr "" -#: admin/dialogs.php:111 +#: admin/dialogs.php:113 msgid "" "This setting allows any users to comment, whether or not they are " "registered. Depending on how you are using WP-Members will determine whether " @@ -80,114 +83,114 @@ msgid "" "you can choose to ignore these warning messages under WP-Members Settings." msgstr "" -#: admin/dialogs.php:115 +#: admin/dialogs.php:117 msgid "" "Your WP settings allow full text rss feeds - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:116 +#: admin/dialogs.php:118 #, php-format msgid "" "You can %s change this here %s by changing \"For each article in a feed, show" "\" to \"Summary.\"" msgstr "" -#: admin/dialogs.php:117 +#: admin/dialogs.php:119 msgid "" "Leaving this set to full text allows anyone to read your protected content " "in an RSS reader. Changing this to Summary prevents this as your feeds will " "only show summary text." msgstr "" -#: admin/dialogs.php:121 +#: admin/dialogs.php:123 msgid "You have set WP-Members to hold registrations for approval" msgstr "" -#: admin/dialogs.php:122 +#: admin/dialogs.php:124 msgid "" "but you have not changed the default message for \"Registration Completed\" " "under \"WP-Members Dialogs and Error Messages.\" You should change this " "message to let users know they are pending approval." msgstr "" -#: admin/dialogs.php:126 +#: admin/dialogs.php:128 msgid "You have set WP-Members to turn off the registration process" msgstr "" -#: admin/dialogs.php:127 +#: admin/dialogs.php:129 msgid "" "but you also set to moderate and/or email admin new registrations. You will " "need to set up a registration page for users to register." msgstr "" -#: admin/dialogs.php:131 +#: admin/dialogs.php:133 msgid "You have turned on reCAPTCHA" msgstr "" -#: admin/dialogs.php:132 +#: admin/dialogs.php:134 msgid "" "but you have not entered API keys. You will need both a public and private " "key. The CAPTCHA will not display unless a valid API key is included." msgstr "" -#: admin/dialogs.php:156 +#: admin/dialogs.php:158 msgid "Version:" msgstr "" -#: admin/dialogs.php:157 +#: admin/dialogs.php:159 msgid "Quick Start Guide" msgstr "" -#: admin/dialogs.php:158 +#: admin/dialogs.php:160 msgid "Online User Guide" msgstr "" -#: admin/dialogs.php:159 +#: admin/dialogs.php:161 msgid "FAQs" msgstr "" -#: admin/dialogs.php:166 +#: admin/dialogs.php:168 msgid "Thank you for using WP-Members" msgstr "" -#: admin/dialogs.php:167 +#: admin/dialogs.php:169 msgid "A plugin developed by" msgstr "" -#: admin/dialogs.php:168 +#: admin/dialogs.php:170 msgid "Follow" msgstr "" -#: admin/dialogs.php:185 admin/dialogs.php:189 +#: admin/dialogs.php:187 admin/dialogs.php:191 msgid "Latest from RocketGeek" msgstr "" -#: admin/dialogs.php:206 admin/dialogs.php:219 +#: admin/dialogs.php:208 admin/dialogs.php:221 msgid "Latest from ButlerBlog" msgstr "" -#: admin/post.php:47 admin/post.php:49 admin/tab-options.php:83 +#: admin/post.php:50 admin/post.php:52 admin/tab-options.php:84 msgid "Block" msgstr "" -#: admin/post.php:48 admin/post.php:50 +#: admin/post.php:51 admin/post.php:53 msgid "Unblock" msgstr "" -#: admin/post.php:173 +#: admin/post.php:178 msgid " Restriction" msgstr "" -#: admin/post.php:301 +#: admin/post.php:308 msgid "Unblocked?" msgstr "" -#: admin/post.php:301 +#: admin/post.php:308 msgid "Blocked?" msgstr "" -#: admin/post.php:331 admin/post.php:332 admin/user-export.php:112 +#: admin/post.php:339 admin/post.php:340 admin/user-export.php:112 msgid "Yes" msgstr "" @@ -200,96 +203,127 @@ msgstr "" msgid "Manage reCAPTCHA Options" msgstr "" -#: admin/tab-captcha.php:69 +#: admin/tab-captcha.php:67 +msgid "" +"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " +"while blocking spam on your blog." +msgstr "" + +#: admin/tab-captcha.php:68 +#, php-format +msgid "" +"reCAPTCHA asks commenters to retype two words scanned from a book to prove " +"that they are a human. This verifies that they are not a spambot while also " +"correcting the automatic scans of old books. So you get less spam, and the " +"world gets accurately digitized books. Everybody wins! For details, visit " +"the %s reCAPTCHA website%s" +msgstr "" + +#: admin/tab-captcha.php:73 admin/tab-captcha.php:99 msgid "reCAPTCHA Keys" msgstr "" -#: admin/tab-captcha.php:71 +#: admin/tab-captcha.php:75 #, php-format msgid "" -"reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " +"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:72 -msgid "Site Key" +#: admin/tab-captcha.php:76 +msgid "Public Key" msgstr "" -#: admin/tab-captcha.php:73 -msgid "Secret Key" +#: admin/tab-captcha.php:77 +msgid "Private Key" msgstr "" -#: admin/tab-captcha.php:77 +#: admin/tab-captcha.php:81 msgid "Choose Theme" msgstr "" -#: admin/tab-captcha.php:80 +#: admin/tab-captcha.php:84 msgid "Red" msgstr "" -#: admin/tab-captcha.php:81 +#: admin/tab-captcha.php:85 msgid "White" msgstr "" -#: admin/tab-captcha.php:82 +#: admin/tab-captcha.php:86 msgid "Black Glass" msgstr "" -#: admin/tab-captcha.php:83 +#: admin/tab-captcha.php:87 msgid "Clean" msgstr "" -#: admin/tab-captcha.php:115 +#: admin/tab-captcha.php:101 +#, php-format +msgid "" +"reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " +"key. You can sign up for a %s free reCAPTCHA key%s" +msgstr "" + +#: admin/tab-captcha.php:102 +msgid "Site Key" +msgstr "" + +#: admin/tab-captcha.php:103 +msgid "Secret Key" +msgstr "" + +#: admin/tab-captcha.php:134 msgid "Characters for image" msgstr "" -#: admin/tab-captcha.php:119 +#: admin/tab-captcha.php:138 msgid "Number of characters" msgstr "" -#: admin/tab-captcha.php:123 +#: admin/tab-captcha.php:142 msgid "Image dimensions" msgstr "" -#: admin/tab-captcha.php:124 +#: admin/tab-captcha.php:143 msgid "Width" msgstr "" -#: admin/tab-captcha.php:124 +#: admin/tab-captcha.php:143 msgid "Height" msgstr "" -#: admin/tab-captcha.php:127 +#: admin/tab-captcha.php:146 msgid "Font color of characters" msgstr "" -#: admin/tab-captcha.php:131 +#: admin/tab-captcha.php:150 msgid "Background color of image" msgstr "" -#: admin/tab-captcha.php:135 +#: admin/tab-captcha.php:154 msgid "Font size" msgstr "" -#: admin/tab-captcha.php:139 +#: admin/tab-captcha.php:158 msgid "Width between characters" msgstr "" -#: admin/tab-captcha.php:143 +#: admin/tab-captcha.php:162 msgid "Image type" msgstr "" -#: admin/tab-captcha.php:157 +#: admin/tab-captcha.php:176 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: admin/tab-captcha.php:169 +#: admin/tab-captcha.php:200 msgid "Update CAPTCHA Settings" msgstr "" -#: admin/tab-captcha.php:233 +#: admin/tab-captcha.php:266 msgid "CAPTCHA was updated for WP-Members" msgstr "" @@ -436,179 +470,187 @@ msgstr "" msgid "A field with that option name already exists" msgstr "" -#: admin/tab-fields.php:209 +#: admin/tab-fields.php:198 +#, php-format +msgid "" +"Sorry, \"%s\" is a reserved term. " +"Field was not added." +msgstr "" + +#: admin/tab-fields.php:216 msgid "Checked value is required for checkboxes. Nothing was updated." msgstr "" -#: admin/tab-fields.php:235 +#: admin/tab-fields.php:242 msgid "field was added" msgstr "" -#: admin/tab-fields.php:253 +#: admin/tab-fields.php:260 msgid "field was updated" msgstr "" -#: admin/tab-fields.php:272 admin/tab-fields.php:451 +#: admin/tab-fields.php:279 admin/tab-fields.php:459 msgid "Edit" msgstr "" -#: admin/tab-fields.php:299 admin/tab-fields.php:416 +#: admin/tab-fields.php:306 admin/tab-fields.php:423 msgid "Edit Field" msgstr "" -#: admin/tab-fields.php:299 +#: admin/tab-fields.php:306 msgid "Add a Field" msgstr "" -#: admin/tab-fields.php:305 admin/tab-fields.php:445 +#: admin/tab-fields.php:312 admin/tab-fields.php:453 msgid "Field Label" msgstr "" -#: admin/tab-fields.php:307 +#: admin/tab-fields.php:314 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: admin/tab-fields.php:310 admin/tab-fields.php:446 +#: admin/tab-fields.php:317 admin/tab-fields.php:454 msgid "Option Name" msgstr "" -#: admin/tab-fields.php:316 +#: admin/tab-fields.php:323 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: admin/tab-fields.php:320 admin/tab-fields.php:447 +#: admin/tab-fields.php:327 admin/tab-fields.php:455 msgid "Field Type" msgstr "" -#: admin/tab-fields.php:326 +#: admin/tab-fields.php:333 msgid "text" msgstr "" -#: admin/tab-fields.php:327 +#: admin/tab-fields.php:334 msgid "textarea" msgstr "" -#: admin/tab-fields.php:328 +#: admin/tab-fields.php:335 msgid "checkbox" msgstr "" -#: admin/tab-fields.php:329 +#: admin/tab-fields.php:336 msgid "dropdown" msgstr "" -#: admin/tab-fields.php:330 +#: admin/tab-fields.php:337 msgid "password" msgstr "" -#: admin/tab-fields.php:331 +#: admin/tab-fields.php:338 msgid "file" msgstr "" -#: admin/tab-fields.php:336 admin/tab-fields.php:448 +#: admin/tab-fields.php:343 admin/tab-fields.php:456 msgid "Display?" msgstr "" -#: admin/tab-fields.php:340 admin/tab-fields.php:449 +#: admin/tab-fields.php:347 admin/tab-fields.php:457 msgid "Required?" msgstr "" -#: admin/tab-fields.php:346 +#: admin/tab-fields.php:353 msgid "Additional information for field upload fields" msgstr "" -#: admin/tab-fields.php:349 +#: admin/tab-fields.php:356 msgid "Accepted file types:" msgstr "" -#: admin/tab-fields.php:354 +#: admin/tab-fields.php:361 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: admin/tab-fields.php:361 +#: admin/tab-fields.php:368 msgid "Additional information for checkbox fields" msgstr "" -#: admin/tab-fields.php:364 +#: admin/tab-fields.php:371 msgid "Checked by default?" msgstr "" -#: admin/tab-fields.php:368 +#: admin/tab-fields.php:375 msgid "Stored value if checked:" msgstr "" -#: admin/tab-fields.php:376 +#: admin/tab-fields.php:383 msgid "Additional information for dropdown fields" msgstr "" -#: admin/tab-fields.php:379 +#: admin/tab-fields.php:386 msgid "For dropdown, array of values:" msgstr "" -#: admin/tab-fields.php:404 +#: admin/tab-fields.php:411 msgid "Options should be Option Name|option_value," msgstr "" -#: admin/tab-fields.php:408 +#: admin/tab-fields.php:415 msgid "Visit plugin site for more information" msgstr "" -#: admin/tab-fields.php:416 +#: admin/tab-fields.php:423 msgid "Add Field" msgstr "" -#: admin/tab-fields.php:436 +#: admin/tab-fields.php:444 msgid "Manage Fields" msgstr "" -#: admin/tab-fields.php:438 +#: admin/tab-fields.php:446 msgid "" "Determine which fields will display and which are required. This includes " "all fields, both native WP fields and WP-Members custom fields." msgstr "" -#: admin/tab-fields.php:439 +#: admin/tab-fields.php:447 msgid "(Note: Email is always mandatory and cannot be changed.)" msgstr "" -#: admin/tab-fields.php:444 +#: admin/tab-fields.php:452 msgid "Add/Delete" msgstr "" -#: admin/tab-fields.php:450 +#: admin/tab-fields.php:458 msgid "Checked?" msgstr "" -#: admin/tab-fields.php:452 +#: admin/tab-fields.php:460 msgid "Users Screen" msgstr "" -#: admin/tab-fields.php:464 +#: admin/tab-fields.php:472 msgid "Delete" msgstr "" -#: admin/tab-fields.php:476 +#: admin/tab-fields.php:484 msgid "(Email cannot be removed)" msgstr "" -#: admin/tab-fields.php:496 +#: admin/tab-fields.php:504 msgid "Registration Date" msgstr "" -#: admin/tab-fields.php:499 +#: admin/tab-fields.php:507 msgid "native" msgstr "" -#: admin/tab-fields.php:509 +#: admin/tab-fields.php:517 msgid "Active" msgstr "" -#: admin/tab-fields.php:521 +#: admin/tab-fields.php:529 msgid "Registration IP" msgstr "" -#: admin/tab-fields.php:556 +#: admin/tab-fields.php:564 msgid "Update Fields" msgstr "" @@ -616,149 +658,149 @@ msgstr "" msgid "Manage Options" msgstr "" -#: admin/tab-options.php:82 +#: admin/tab-options.php:83 msgid "Do not block" msgstr "" -#: admin/tab-options.php:84 +#: admin/tab-options.php:85 msgid "Hide" msgstr "" -#: admin/tab-options.php:94 +#: admin/tab-options.php:96 msgid "Show Excerpts" msgstr "" -#: admin/tab-options.php:95 +#: admin/tab-options.php:97 msgid "Show Login Form" msgstr "" -#: admin/tab-options.php:96 +#: admin/tab-options.php:98 msgid "Show Registration Form" msgstr "" -#: admin/tab-options.php:116 +#: admin/tab-options.php:120 msgid "Time-based expiration" msgstr "" -#: admin/tab-options.php:116 +#: admin/tab-options.php:120 msgid "Allows for access to expire" msgstr "" -#: admin/tab-options.php:117 +#: admin/tab-options.php:121 msgid "Trial period" msgstr "" -#: admin/tab-options.php:117 +#: admin/tab-options.php:121 msgid "Allows for a trial period" msgstr "" -#: admin/tab-options.php:133 +#: admin/tab-options.php:137 msgid "Notify admin" msgstr "" -#: admin/tab-options.php:133 +#: admin/tab-options.php:137 #, php-format msgid "Notify %s for each new registration? %s" msgstr "" -#: admin/tab-options.php:134 +#: admin/tab-options.php:138 msgid "Moderate registration" msgstr "" -#: admin/tab-options.php:134 +#: admin/tab-options.php:138 msgid "Holds new registrations for admin approval" msgstr "" -#: admin/tab-options.php:135 +#: admin/tab-options.php:139 msgid "Ignore warning messages" msgstr "" -#: admin/tab-options.php:135 +#: admin/tab-options.php:139 msgid "Ignores WP-Members warning messages in the admin panel" msgstr "" -#: admin/tab-options.php:147 +#: admin/tab-options.php:151 msgid "Attribution" msgstr "" -#: admin/tab-options.php:149 +#: admin/tab-options.php:153 msgid "" "Attribution is appreciated! Display \"powered by\" link on register form?" msgstr "" -#: admin/tab-options.php:153 +#: admin/tab-options.php:157 msgid "Auto Excerpt:" msgstr "" -#: admin/tab-options.php:154 +#: admin/tab-options.php:158 msgid "Number of words in excerpt:" msgstr "" -#: admin/tab-options.php:154 +#: admin/tab-options.php:158 msgid "Optional" msgstr "" -#: admin/tab-options.php:154 +#: admin/tab-options.php:158 msgid "Automatically creates an excerpt" msgstr "" -#: admin/tab-options.php:157 +#: admin/tab-options.php:161 msgid "Enable CAPTCHA" msgstr "" -#: admin/tab-options.php:159 +#: admin/tab-options.php:163 msgid "None" msgstr "" -#: admin/tab-options.php:164 +#: admin/tab-options.php:169 msgid "Pages" msgstr "" -#: admin/tab-options.php:168 +#: admin/tab-options.php:173 msgid "Login Page:" msgstr "" -#: admin/tab-options.php:171 +#: admin/tab-options.php:176 msgid "Specify a login page (optional)" msgstr "" -#: admin/tab-options.php:180 +#: admin/tab-options.php:185 msgid "Register Page:" msgstr "" -#: admin/tab-options.php:183 +#: admin/tab-options.php:188 msgid "For creating a register link in the login form" msgstr "" -#: admin/tab-options.php:192 +#: admin/tab-options.php:197 msgid "User Profile Page:" msgstr "" -#: admin/tab-options.php:195 +#: admin/tab-options.php:200 msgid "For creating a forgot password link in the login form" msgstr "" -#: admin/tab-options.php:201 admin/tab-options.php:203 +#: admin/tab-options.php:206 admin/tab-options.php:208 msgid "Stylesheet" msgstr "" -#: admin/tab-options.php:212 +#: admin/tab-options.php:217 msgid "Custom Stylesheet:" msgstr "" -#: admin/tab-options.php:218 +#: admin/tab-options.php:223 msgid "Update Settings" msgstr "" -#: admin/tab-options.php:336 +#: admin/tab-options.php:341 msgid "WP-Members settings were updated" msgstr "" -#: admin/tab-options.php:378 admin/tab-options.php:407 +#: admin/tab-options.php:383 admin/tab-options.php:412 msgid "USE CUSTOM URL BELOW" msgstr "" -#: admin/tab-options.php:396 +#: admin/tab-options.php:401 msgid "Select a page" msgstr "" @@ -782,7 +824,7 @@ msgstr "" msgid "IP" msgstr "" -#: admin/user-export.php:112 admin/users.php:335 +#: admin/user-export.php:112 admin/users.php:337 msgid "No" msgstr "" @@ -790,8 +832,8 @@ msgstr "" msgid "WP-Members Additional Fields" msgstr "" -#: admin/user-profile.php:78 inc/users.php:62 inc/wp-registration.php:37 -#: inc/wp-registration.php:159 +#: admin/user-profile.php:78 inc/users.php:62 inc/wp-registration.php:38 +#: inc/wp-registration.php:163 msgid "(required)" msgstr "" @@ -823,23 +865,23 @@ msgstr "" msgid "Export All Users" msgstr "" -#: inc/class-wp-members-widget.php:15 +#: inc/class-wp-members-widget.php:18 msgid "Displays the WP-Members sidebar login." msgstr "" -#: inc/class-wp-members-widget.php:30 inc/class-wp-members-widget.php:73 +#: inc/class-wp-members-widget.php:33 inc/class-wp-members-widget.php:76 msgid "Login Status" msgstr "" -#: inc/class-wp-members-widget.php:37 +#: inc/class-wp-members-widget.php:40 msgid "Title:" msgstr "" -#: inc/class-wp-members-widget.php:41 +#: inc/class-wp-members-widget.php:44 msgid "Redirect to (optional):" msgstr "" -#: inc/class-wp-members.php:320 inc/shortcodes.php:86 inc/shortcodes.php:383 +#: inc/class-wp-members.php:329 inc/shortcodes.php:95 inc/shortcodes.php:392 msgid "There was an error with the CAPTCHA form." msgstr "" @@ -847,62 +889,62 @@ msgstr "" msgid "ERROR: User has not been activated." msgstr "" -#: inc/core.php:466 inc/register.php:88 +#: inc/core.php:472 inc/register.php:88 #, php-format msgid "Sorry, %s is a required field." msgstr "" -#: inc/core.php:484 inc/forms.php:526 inc/sidebar.php:188 +#: inc/core.php:490 inc/forms.php:526 inc/sidebar.php:188 msgid "Register" msgstr "" -#: inc/dialogs.php:40 +#: inc/dialogs.php:47 msgid "Login Failed!" msgstr "" -#: inc/dialogs.php:43 +#: inc/dialogs.php:50 msgid "You entered an invalid username or password." msgstr "" -#: inc/dialogs.php:45 +#: inc/dialogs.php:52 msgid "Click here to continue." msgstr "" -#: inc/dialogs.php:189 +#: inc/dialogs.php:196 msgid "Edit My Information" msgstr "" -#: inc/dialogs.php:190 inc/forms.php:163 +#: inc/dialogs.php:197 inc/forms.php:163 msgid "Change Password" msgstr "" -#: inc/dialogs.php:204 inc/dialogs.php:225 inc/dialogs.php:261 +#: inc/dialogs.php:211 inc/dialogs.php:232 inc/dialogs.php:268 #: inc/sidebar.php:46 inc/sidebar.php:242 #, php-format msgid "You are logged in as %s" msgstr "" -#: inc/dialogs.php:206 +#: inc/dialogs.php:213 msgid "Click to log out." msgstr "" -#: inc/dialogs.php:207 +#: inc/dialogs.php:214 msgid "Begin using the site." msgstr "" -#: inc/dialogs.php:226 +#: inc/dialogs.php:233 msgid "Click to log out" msgstr "" -#: inc/dialogs.php:262 inc/sidebar.php:47 +#: inc/dialogs.php:269 inc/sidebar.php:47 msgid "click to log out" msgstr "" -#: inc/dialogs.php:310 +#: inc/dialogs.php:317 msgid "Password fields cannot be empty" msgstr "" -#: inc/dialogs.php:377 inc/shortcodes.php:425 +#: inc/dialogs.php:384 inc/shortcodes.php:434 msgid "Edit Your Information" msgstr "" @@ -910,7 +952,7 @@ msgstr "" msgid "Username" msgstr "" -#: inc/forms.php:78 inc/sidebar.php:143 +#: inc/forms.php:78 inc/sidebar.php:143 string stored in database msgid "Password" msgstr "" @@ -934,7 +976,7 @@ msgstr "" msgid "Update Password" msgstr "" -#: inc/forms.php:211 +#: inc/forms.php:211 string stored in database msgid "Email" msgstr "" @@ -982,16 +1024,16 @@ msgstr "" msgid "Choose a Username" msgstr "" -#: inc/forms.php:687 inc/wp-registration.php:66 +#: inc/forms.php:687 inc/wp-registration.php:67 #, php-format msgid "Please indicate that you agree to the %s TOS %s" msgstr "" -#: inc/forms.php:854 +#: inc/forms.php:857 msgid "New User Registration" msgstr "" -#: inc/forms.php:1036 +#: inc/forms.php:1049 msgid "Input the code:" msgstr "" @@ -999,7 +1041,7 @@ msgstr "" msgid "There was an error processing the form." msgstr "" -#: inc/register.php:109 inc/register.php:342 +#: inc/register.php:109 inc/register.php:368 msgid "You must enter a valid email address." msgstr "" @@ -1015,48 +1057,52 @@ msgstr "" msgid "Passwords did not match." msgstr "" -#: inc/register.php:125 inc/register.php:350 +#: inc/register.php:125 inc/register.php:376 msgid "Emails did not match." msgstr "" -#: inc/register.php:137 +#: inc/register.php:137 inc/register.php:203 msgid "You must complete the CAPTCHA form." msgstr "" -#: inc/register.php:462 +#: inc/register.php:218 +msgid "CAPTCHA was not valid." +msgstr "" + +#: inc/register.php:488 msgid "We were unable to validate the public key." msgstr "" -#: inc/register.php:466 +#: inc/register.php:492 msgid "We were unable to validate the private key." msgstr "" -#: inc/register.php:470 +#: inc/register.php:496 msgid "The challenge parameter of the verify script was incorrect." msgstr "" -#: inc/register.php:474 +#: inc/register.php:500 msgid "The CAPTCHA solution was incorrect." msgstr "" -#: inc/register.php:478 +#: inc/register.php:504 msgid "The parameters to verify were incorrect" msgstr "" -#: inc/register.php:482 +#: inc/register.php:508 msgid "" "reCAPTCHA API keys are tied to a specific domain name for security reasons." msgstr "" -#: inc/register.php:486 +#: inc/register.php:512 msgid "The reCAPTCHA server was not reached. Please try to resubmit." msgstr "" -#: inc/register.php:490 +#: inc/register.php:516 msgid "You have entered an incorrect code value. Please try again." msgstr "" -#: inc/shortcodes.php:344 +#: inc/shortcodes.php:353 msgid "Click here to log out." msgstr "" @@ -1084,7 +1130,7 @@ msgstr "" msgid "Additional Information" msgstr "" -#: inc/utilities.php:250 +#: inc/utilities.php:252 msgid "(more…)" msgstr "" @@ -1138,10 +1184,6 @@ msgstr "" msgid "Day Phone" msgstr "" -#: string stored in database -msgid "Email" -msgstr "" - #: string stored in database msgid "Confirm Email" msgstr "" @@ -1154,10 +1196,6 @@ msgstr "" msgid "Biographical Info" msgstr "" -#: string stored in database -msgid "Password" -msgstr "" - #: string stored in database msgid "Confirm Password" msgstr "" @@ -1265,4 +1303,13 @@ msgstr "" #: wp-members-install.php: may be deprecated msgid "Yahoo IM" +msgstr "" + +#. Description of the plugin/theme +msgid "" +"WP access restriction and user registration. For more information on plugin " +"features, refer to the online Users Guide. A Quick Start Guide is also " +"available. WP-Members(tm) is a trademark of butlerblog.com." msgstr "" \ No newline at end of file From 04a46206e08ca9f77671f7c1dfd78fc14a6d4d9c Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 29 Sep 2015 09:47:55 -0500 Subject: [PATCH 0160/1694] fixes localization logic bug from 3.0.5 --- readme.txt | 7 ++++--- wp-members.php | 8 ++++---- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/readme.txt b/readme.txt index 9876bcdb..ec397a36 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 Tested up to: 4.3.1 -Stable tag: 3.0.5 +Stable tag: 3.0.5.1 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,8 +111,9 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.5 is primarily a functional improvement release with minimal core changes. See the change log for details. -WP-Members 3.0.0 is a major version release. Please be sure you have reviewed the changelog before upgrading. http://rkt.bz/v30 +WP-Members 3.0.5.1 fixes a bug in the localization logic. If you run WP-Members in another language, please update. +WP-Members 3.0.5 is a functional improvement release with minimal core changes. +WP-Members 3.0.0 is a major version release. Please review the changelog: http://rkt.bz/v30 == Screenshots == diff --git a/wp-members.php b/wp-members.php index eceddd72..b0fcb967 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.5 +Version: 3.0.5.1 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -61,7 +61,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.5' ); +define( 'WPMEM_VERSION', '3.0.5.1' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); @@ -294,9 +294,9 @@ function wpmem_load_textdomain() { * * @param string $file The translation file to load. */ - $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . $domain . '/' . $domain . '-' . $locale . '.mo' ); + $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . 'plugins/' . $domain . '-' . $locale . '.mo' ); - $loaded = false; + $loaded = true; if ( $loaded == load_textdomain( $domain, $file ) ) { return $loaded; } else { From 3c26a3dcf6b1103ac02eb512227648ba44710cf2 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 30 Sep 2015 20:10:34 -0500 Subject: [PATCH 0161/1694] additional improvements to the load_textdomain() process --- wp-members.php | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/wp-members.php b/wp-members.php index b0fcb967..883507bb 100644 --- a/wp-members.php +++ b/wp-members.php @@ -284,20 +284,29 @@ function wpmem_load_textdomain() { // @todo See: https://ulrich.pogson.ch/load-theme-plugin-translations for notes on changes. + // Plugin textdomain. $domain = 'wp-members'; - $locale = apply_filters( 'plugin_locale', get_locale(), $domain ); + // Wordpress locale. + /** This filter is documented in wp-includes/l10n.php */ + $locale = apply_filters( 'plugin_locale', get_locale(), $domain ); + /** * Filter translation file. * + * If the translate.wordpress.org language pack is available, it will + * be /wp-content/languages/plugins/wp-members-{locale}.mo by default. + * You can filter this if you want to load a language pack from a + * different location (or different file name). + * * @since 3.0.0 * * @param string $file The translation file to load. */ $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . 'plugins/' . $domain . '-' . $locale . '.mo' ); - - $loaded = true; - if ( $loaded == load_textdomain( $domain, $file ) ) { + + $loaded = load_textdomain( $domain, $file ); + if ( $loaded ) { return $loaded; } else { From b60a3d7a8c44697007cd7714660c732de139721e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 30 Sep 2015 20:10:59 -0500 Subject: [PATCH 0162/1694] fixed bug in user export when moderated registration is turned on. --- admin/user-export.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/user-export.php b/admin/user-export.php index 83fa301c..c3a0b20e 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -109,7 +109,7 @@ function wpmem_export_users( $args, $users = null ) { } } - $data .= ( $wpmem->mod_reg == 1 ) ? '"' . ( get_user_meta( $user, 'active', 1 ) ) ? __( 'Yes' ) : __( 'No' ) . '",' : ''; + $data .= ( $wpmem->mod_reg == 1 ) ? '"' . ( get_user_meta( $user, 'active', 1 ) ? __( 'Yes' ) : __( 'No' ) ) . '",' : ''; $data .= ( $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "exp_type", true ) . '",' : ''; $data .= ( $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "expires", true ) . '",' : ''; From 57b7133366e34d5ded8bff2c59266c7a622cb7fa Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 9 Oct 2015 10:32:43 -0500 Subject: [PATCH 0163/1694] added https to codex link --- admin/tab-fields.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 75833dc3..1727cd45 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -195,7 +195,7 @@ function wpmem_update_fields( $action ) { $reserved_terms = wpmem_wp_reserved_terms(); $submitted_term = $_POST['add_option']; if ( in_array( strtolower( $submitted_term ), $reserved_terms ) ) { - $add_field_err_msg = sprintf( __( 'Sorry, "%s" is a reserved term. Field was not added.', 'wp-members' ), $submitted_term ); + $add_field_err_msg = sprintf( __( 'Sorry, "%s" is a reserved term. Field was not added.', 'wp-members' ), $submitted_term ); } // Error check option name for spaces and replace with underscores. From 066fd468705b668752639d5d823d9886d56478bc Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 9 Oct 2015 10:33:08 -0500 Subject: [PATCH 0164/1694] added /lang domain path --- wp-members.php | 1 + 1 file changed, 1 insertion(+) diff --git a/wp-members.php b/wp-members.php index 883507bb..8ccce786 100644 --- a/wp-members.php +++ b/wp-members.php @@ -7,6 +7,7 @@ Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members +Domain Path: /lang License: GPLv2 */ From 475ff0c6dc6fe824522d156f5407a002474dbac2 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 9 Oct 2015 10:33:40 -0500 Subject: [PATCH 0165/1694] improved current page retrieval in wpmem_redirect_to_login() --- inc/core.php | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/inc/core.php b/inc/core.php index 8f6de588..668287de 100644 --- a/inc/core.php +++ b/inc/core.php @@ -567,14 +567,15 @@ function wpmem_securify_comments_array( $comments , $post_id ) { */ function wpmem_redirect_to_login() { - global $wpmem; + global $wp, $post, $wpmem; if( ! is_user_logged_in() && $wpmem->is_blocked() ) { - global $post; - // Get the page location. - $page = urlencode( "http://" . $_SERVER["HTTP_HOST"] . $_SERVER["REQUEST_URI"] ); - $url = wpmem_chk_qstr( $wpmem->user_pages['login'] ) . 'redirect_to=' . $page; + // Get current page location. + $current_page = home_url( add_query_arg( array(), $wp->request ) ); + $redirect_to = urlencode( $current_page ); + + $url = wpmem_chk_qstr( $wpmem->user_pages['login'] ) . 'redirect_to=' . $redirect_to; wp_redirect( $url ); exit(); From 3c4a8a716635e3432a224c07ecb42a4e442dab8d Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 10 Oct 2015 22:33:26 -0500 Subject: [PATCH 0166/1694] fixes to admin enqueued scripts --- admin/admin.php | 23 +++++++++++++++++++++++ admin/post.php | 1 - wp-members.php | 1 - 3 files changed, 23 insertions(+), 2 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index bc0f0b7d..d8f028ae 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -25,6 +25,7 @@ * - wpmem_admin_tabs * - wpmem_admin_action * - wpmem_admin_add_new_user + * - wpmem_admin_enqueue_scripts */ @@ -33,6 +34,7 @@ /** Actions and Filters */ +add_action( 'admin_enqueue_scripts', 'wpmem_admin_enqueue_scripts' ); add_action( 'wpmem_admin_do_tab', 'wpmem_admin_do_tab' ); add_action( 'wp_ajax_wpmem_a_field_reorder', 'wpmem_a_do_field_reorder' ); add_action( 'user_new_form', 'wpmem_admin_add_new_user' ); @@ -79,6 +81,7 @@ function wpmem_admin_plugin_links( $links, $file ) { * Loads the admin javascript and css files. * * @since 2.5.1 + * @deprecated 3.0.6 * * @uses wp_enqueue_script * @uses wp_enqueue_style @@ -287,4 +290,24 @@ function wpmem_admin_add_new_user() { return; } + +/** + * Enqueues the admin javascript and css files. + * + * @since 3.0.6 + * + * @uses wp_enqueue_script + * @uses wp_enqueue_style + * + * @param str $hook The admin screen hook being loaded. + */ +function wpmem_admin_enqueue_scripts( $hook ) { + if ( $hook == 'edit.php' || $hook == 'settings_page_wpmem-settings' ) { + wp_enqueue_style( 'wpmem-admin', WPMEM_DIR . 'admin/css/admin.css', '', WPMEM_VERSION ); + } + if ( $hook == 'settings_page_wpmem-settings' ) { + wp_enqueue_script( 'wpmem-admin', WPMEM_DIR . 'admin/js/admin.js', '', WPMEM_VERSION ); + } +} + // End of File. \ No newline at end of file diff --git a/admin/post.php b/admin/post.php index 5d3854de..29ea25fa 100644 --- a/admin/post.php +++ b/admin/post.php @@ -304,7 +304,6 @@ function wpmem_post_columns( $columns ) { $post_type = ( isset( $_REQUEST['post_type'] ) ) ? $_REQUEST['post_type'] : 'post'; if ( $post_type == 'page' || $post_type == 'post' ) { // @todo - holding off on CPT support. - wp_enqueue_style ( 'wpmem-admin-css', WPMEM_DIR . '/css/admin.css', '', WPMEM_VERSION ); $columns['wpmem_block'] = ( $wpmem->block[ $post_type ] == 1 ) ? __( 'Unblocked?', 'wp-members' ) : __( 'Blocked?', 'wp-members' ); } return $columns; diff --git a/wp-members.php b/wp-members.php index 8ccce786..fb659c02 100644 --- a/wp-members.php +++ b/wp-members.php @@ -219,7 +219,6 @@ function wpmem_chk_admin() { function wpmem_admin_options() { if ( ! is_multisite() || ( is_multisite() && current_user_can( 'edit_theme_options' ) ) ) { $plugin_page = add_options_page ( 'WP-Members', 'WP-Members', 'manage_options', 'wpmem-settings', 'wpmem_admin' ); - add_action( 'load-'.$plugin_page, 'wpmem_load_admin_js' ); // enqueues javascript for admin } } From 97f2608d781fb4a14eb9e7a9083ae0005b29e877 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 12 Oct 2015 15:30:38 -0500 Subject: [PATCH 0167/1694] fixes to admin enqueued scripts --- admin/admin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/admin.php b/admin/admin.php index d8f028ae..f4dc3512 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -306,7 +306,7 @@ function wpmem_admin_enqueue_scripts( $hook ) { wp_enqueue_style( 'wpmem-admin', WPMEM_DIR . 'admin/css/admin.css', '', WPMEM_VERSION ); } if ( $hook == 'settings_page_wpmem-settings' ) { - wp_enqueue_script( 'wpmem-admin', WPMEM_DIR . 'admin/js/admin.js', '', WPMEM_VERSION ); + wp_enqueue_script( 'wpmem-admin', WPMEM_DIR . 'admin/js/admin.js', '', WPMEM_VERSION ); } } From 3e36059fd393d9ffcc6521c354eea05f4fa9628f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 12 Oct 2015 15:31:34 -0500 Subject: [PATCH 0168/1694] 3.0.6 release --- readme.txt | 13 ++++++++++--- wp-members.php | 4 ++-- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/readme.txt b/readme.txt index ec397a36..a531aac5 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 Tested up to: 4.3.1 -Stable tag: 3.0.5.1 +Stable tag: 3.0.6 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,8 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.5.1 fixes a bug in the localization logic. If you run WP-Members in another language, please update. -WP-Members 3.0.5 is a functional improvement release with minimal core changes. +WP-Members 3.0.6 is a functional improvement release with minimal core changes. WP-Members 3.0.0 is a major version release. Please review the changelog: http://rkt.bz/v30 == Screenshots == @@ -136,6 +135,14 @@ WP-Members 3.0.0 is a major version release. Please review the changelog: http:/ == Changelog == += 3.0.6 = + +* Updates to localization function - documented plugin_locale filter, wpmem_localization_file filter, and improved load_textdomain logic. +* Added /lang domain path to plugin header. +* Fixed a bug in the user export function that broke CSV columns when moderated registration was turned on. +* Improved current page retrieval in wpmem_redirect_to_login() function. +* Fixed admin enqueued scripts (post/page screen hook did not load from new location). + = 3.0.5 = * Updated wpmem_pwd_change and wpmem_pwd_reset action hooks to include password as a parameter. diff --git a/wp-members.php b/wp-members.php index fb659c02..516aae9d 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.5.1 +Version: 3.0.6 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.5.1' ); +define( 'WPMEM_VERSION', '3.0.6' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 5355b7b7d82fab1a3be672927aa2ce035ef07958 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 19 Oct 2015 14:02:38 -0500 Subject: [PATCH 0169/1694] code standards, improved inline documentation --- admin/admin.php | 96 ++++++++++++++++++++++++++++++++++--------------- 1 file changed, 68 insertions(+), 28 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index f4dc3512..7db8ae27 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -9,8 +9,7 @@ * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * - * @package WordPress - * @subpackage WP-Members + * @package WP-Members * @author Chad Butler * @copyright 2006-2015 * @@ -29,11 +28,15 @@ */ -/** File Includes */ +/** + * Load dialog functions. + */ include_once( WPMEM_PATH . 'admin/dialogs.php' ); -/** Actions and Filters */ +/** + * Actions and Filters + */ add_action( 'admin_enqueue_scripts', 'wpmem_admin_enqueue_scripts' ); add_action( 'wpmem_admin_do_tab', 'wpmem_admin_do_tab' ); add_action( 'wp_ajax_wpmem_a_field_reorder', 'wpmem_a_do_field_reorder' ); @@ -45,11 +48,14 @@ * Calls the function to reorder fields. * * @since 2.8.0 - * - * @uses wpmem_a_field_reorder */ -function wpmem_a_do_field_reorder(){ +function wpmem_a_do_field_reorder() { + /** + * Load the fields tab functions. + */ include_once( WPMEM_PATH . 'admin/tab-fields.php' ); + + // Reorder registration fields. wpmem_a_field_reorder(); } @@ -57,11 +63,10 @@ function wpmem_a_do_field_reorder(){ /** * Filter to add link to settings from plugin panel. * - * @since 2.4 + * @since 2.4.0 * * @param array $links * @param string $file - * @static string $wpmem_plugin * @return array $links */ function wpmem_admin_plugin_links( $links, $file ) { @@ -82,9 +87,6 @@ function wpmem_admin_plugin_links( $links, $file ) { * * @since 2.5.1 * @deprecated 3.0.6 - * - * @uses wp_enqueue_script - * @uses wp_enqueue_style */ function wpmem_load_admin_js() { // Queue up admin ajax and styles. @@ -96,21 +98,29 @@ function wpmem_load_admin_js() { /** * Creates the captcha tab. * - * @since 2.8 + * @since 2.8.0 * - * @param string $tab - * @return + * @param string $tab The admin tab being displayed. + * @return string|bool The captcha options tab, otherwise false. */ function wpmem_a_captcha_tab( $tab ) { - include_once( WPMEM_PATH . 'admin/tab-captcha.php' ); - return ( $tab == 'captcha' ) ? wpmem_a_build_captcha_options() : false ; + if ( $tab == 'captcha' ) { + /** + * Load the captcha tab functions. + */ + include_once( WPMEM_PATH . 'admin/tab-captcha.php' ); + // Render the captcha tab. + return wpmem_a_build_captcha_options(); + } else { + return false; + } } /** * Adds the captcha tab. * - * @since 2.8 + * @since 2.8.0 * * @param array $tabs The array of tabs for the admin panel. * @return array The updated array of tabs for the admin panel. @@ -123,7 +133,9 @@ function wpmem_add_captcha_tab( $tabs ) { /** * Primary admin function. * - * @since 2.1 + * @since 2.1.0 + * + * @global object $wpmem The WP_Members object. */ function wpmem_admin() { @@ -142,8 +154,10 @@ function wpmem_admin() { Date: Mon, 19 Oct 2015 14:03:45 -0500 Subject: [PATCH 0170/1694] code standards, inline documentation, added excluded_fields to object class, changed utility function to wrapper for new class method. --- inc/class-wp-members.php | 68 ++++++++++++++++++++++++++++++++++------ inc/utilities.php | 47 +++++++++++++-------------- 2 files changed, 80 insertions(+), 35 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 211f20a6..8a56dd39 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -1,9 +1,16 @@ block['post'] ) : ''; @@ -156,6 +172,8 @@ function load_constants() { * Gets the requested action. * * @since 3.0.0 + * + * @global string $wpmem_a The WP-Members action variable. */ function get_action() { @@ -175,6 +193,8 @@ function get_action() { * * @since 3.0.0 * + * @global string $wpmem_a The WP-Members action variable. + * * @param string $action The action being done. * @return string The regchk value. * @@ -237,7 +257,9 @@ function get_regchk( $action ) { * This function was originally stand alone in the core file and * was moved to the WP_Members class in 3.0. * - * @since 3.0 + * @since 3.0.0 + * + * @global object $post The WordPress Post object. * * @return bool $block true|false */ @@ -308,11 +330,11 @@ function is_blocked() { * This is the primary function that picks up where get_action() leaves off. * Determines whether content is shown or hidden for both post and pages. * - * @since 3.0 + * @since 3.0.0 * * @global string $wpmem_themsg Contains messages to be output. - * @global string $wpmem_captcha_err Contains error message for reCAPTCHA. - * @global object $post The post object. + * @global object $post The WordPress Post object. + * * @param string $content * @return string $content */ @@ -416,14 +438,40 @@ function do_securify( $content = null ) { } /** - * Returns the registration fields. + * Sets the registration fields. * * @since 3.0.0 - * - * @return array The registration fields. */ function load_fields() { $this->fields = get_option( 'wpmembers_fields' ); } + + /** + * Get excluded meta fields. + * + * @since Unknown + * + * @param string $tag A tag so we know where the function is being used. + * @return array The excluded fields. + */ + function excluded_fields( $tag ) { + + // Default excluded fields. + $excluded_fields = array( 'password', 'confirm_password', 'confirm_email', 'password_confirm', 'email_confirm' ); + + /** + * Filter the fields to be excluded when user is created/updated. + * + * @since 2.9.3 + * @since Unknown Moved to new method in WP_Members Class. + * + * @param array An array of the field meta names to exclude. + * @param string $tag A tag so we know where the function is being used. + */ + $excluded_fields = apply_filters( 'wpmem_exclude_fields', $excluded_fields, $tag ); + + // Return excluded fields. + return $excluded_fields; + } } \ No newline at end of file diff --git a/inc/utilities.php b/inc/utilities.php index 6ad6a463..a777a5c6 100644 --- a/inc/utilities.php +++ b/inc/utilities.php @@ -10,8 +10,8 @@ * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * - * @package WordPress - * @subpackage WP-Members + * @package WP-Members + * @subpackage WP-Members Utility Functions * @author Chad Butler * @copyright 2006-2015 * @@ -19,7 +19,7 @@ * - wpmem_create_formfield * - wpmem_selected * - wpmem_chk_qstr - * - wpmem_generatePassword + * - wpmem_generatePassword (deprecated) * - wpmem_texturize * - wpmem_enqueue_style * - wpmem_do_excerpt @@ -35,7 +35,7 @@ * * Creates various form fields and returns them as a string. * - * @since 1.8 + * @since 1.8.0 * * @param string $name The name of the field. * @param string $type The field type. @@ -102,7 +102,7 @@ function wpmem_create_formfield( $name, $type, $value, $valtochk=null, $class='t /** * Determines if a form field is selected (i.e. lists & checkboxes). * - * @since 0.1 + * @since 0.1.0 * * @param string $value * @param string $valtochk @@ -120,9 +120,8 @@ function wpmem_selected( $value, $valtochk, $type=null ) { /** * Checks querystrings. * - * @since 2.0 + * @since 2.0.0 * - * @uses get_permalink * @param string $url * @return string $return_url */ @@ -145,7 +144,8 @@ function wpmem_chk_qstr( $url = null ) { /** * Generates a random password. * - * @since 2.0 + * @since 2.0.0 + * @deprecated Unknown * * @return string The random password. */ @@ -192,9 +192,7 @@ function wpmem_texturize( $content ) { * * @since 2.6 * - * @global $wpmem - * @uses wp_register_style - * @uses wp_enqueue_style + * @global object $wpmem The WP_Members object. */ function wpmem_enqueue_style() { global $wpmem; @@ -210,6 +208,8 @@ function wpmem_enqueue_style() { * * @since 2.6 * + * @global object $wpmem The WP_Members object. + * * @param string $content * @return string $content */ @@ -277,10 +277,10 @@ function wpmem_do_excerpt( $content ) { /** * Tests $content for the presence of the [wp-members] shortcode. * - * @since 2.6 + * @since 2.6.0 + * + * @global $shortcode_tags * - * @global string $post - * @uses get_shortcode_regex * @return bool * * @example http://codex.wordpress.org/Function_Reference/get_shortcode_regex @@ -309,27 +309,24 @@ function wpmem_test_shortcode( $content, $tag ) { * Sets an array of user meta fields to be excluded from update/insert. * * @since 2.9.3 + * @since Unknown Now a wrapper for get_excluded_fields(). * - * @param string $tag A tag so we know where the function is being used. + * @param string $tag A tag so we know where the function is being used. + * @return array Array of fields to be excluded from the registration form. */ function wpmem_get_excluded_meta( $tag ) { - /** - * Filter the fields to be excluded when user is created/updated. - * - * @since 2.9.3 - * - * @param array An array of the field meta names to exclude. - * @param string $tag A tag so we know where the function is being used. - */ - return apply_filters( 'wpmem_exclude_fields', array( 'password', 'confirm_password', 'confirm_email', 'password_confirm', 'email_confirm' ), $tag ); + global $wpmem; + return $wpmem->excluded_fields( $tag ); } /** * Returns http:// or https:// depending on ssl. * - * @ since 2.9.8 + * @since 2.9.8 + * + * @return string https://|http:// depending on whether ssl is being used. */ function wpmem_use_ssl() { return ( is_ssl() ) ? 'https://' : 'http://'; From 20a99ad74f7018bee8dfe6890cc2fce85626d8db Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 19 Oct 2015 14:04:43 -0500 Subject: [PATCH 0171/1694] code standards, improved inline documentation, changes to use fields from object class. --- inc/core.php | 195 ++++++++++++++++++++++++++++++--------------------- 1 file changed, 117 insertions(+), 78 deletions(-) diff --git a/inc/core.php b/inc/core.php index 668287de..859123a6 100644 --- a/inc/core.php +++ b/inc/core.php @@ -10,14 +10,15 @@ * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * - * @package WordPress - * @subpackage WP-Members - * @author Chad Butler + * @package WP-Members + * @author Chad Butler * @copyright 2006-2015 */ -// Include utility functions. +/** + * Load utility functions. + */ require_once( WPMEM_PATH . 'inc/utilities.php' ); @@ -25,9 +26,12 @@ * The Main Action Function. * * Does actions required at initialization prior to headers being sent. - * Since 3.0, this function is a wrapper for get_action(). + * Since 3.0, this function is a wrapper for $wpmem->get_action(). + * + * @since 0.1.0 + * @since 3.0.0 Now a wrapper for $wpmem->get_action(). * - * @since 0.1 + * @global object $wpmem The WP-Members object class. */ function wpmem() { global $wpmem; @@ -41,13 +45,15 @@ function wpmem() { * * This is the primary function that picks up where wpmem() leaves off. * Determines whether content is shown or hidden for both post and pages. - * Since 3.0, this function is a wrapper for do_securify(). + * Since 3.0, this function is a wrapper for $wpmem->do_securify(). * - * @since 2.0 + * @since 2.0.0 + * @since 3.0.0 Now a wrapper for $wpmem->do_securify(). * - * @global object $wpmem - * @param string $content - * @return string $content + * @global object $wpmem The WP-Members object class. + * + * @param string $content Content of the current post. + * @return string $content Content of the current post or replaced content if post is blocked and user is not logged in. */ function wpmem_securify( $content = null ) { global $wpmem; @@ -58,13 +64,14 @@ function wpmem_securify( $content = null ) { if ( ! function_exists( 'wpmem_block' ) ): /** - * Determines if content should be blocked. + * Determines if content is blocked. * - * Since 3.0, this function is a wrapper for is_blocked(). + * @since 2.6.0 + * @since 3.0.0 Now a wrapper for $wpmem->is_blocked(). * - * @since 2.6 + * @global object $wpmem The WP-Members object class. * - * @return bool $block true|false + * @return bool $block true if content is blocked, false otherwise. */ function wpmem_block() { global $wpmem; @@ -79,11 +86,10 @@ function wpmem_block() { * * @since 2.7.1 * - * @uses wp_check_password - * @param int $user - * @param string $username - * @param string $password - * @return int $user + * @param object $user The WordPress User object. + * @param string $username The user's username (user_login). + * @param string $password The user's password. + * @return object $user The WordPress User object. */ function wpmem_check_activated( $user, $username, $password ) { @@ -114,12 +120,12 @@ function wpmem_check_activated( $user, $username, $password ) { * successful, it will set a cookie using wp_set_auth_cookie (since 2.7.7), * then it redirects and exits; otherwise "loginfailed" is returned. * - * @since 0.1 + * @since 0.1.0 + * @since 2.5.2 Now uses wp_signon(). + * @since 2.7.7 Sets cookie using wp_set_auth_cookie(). + * @since 3.0.0 Removed wp_set_auth_cookie(), this already happens in wp_signon(). * - * @uses wp_signon - * @uses wp_set_auth_cookie - * @uses wp_redirect Redirects to $redirect_to if login is successful. - * @return string Returns "loginfailed" if the login fails. + * @return string Returns "loginfailed" if the login fails. */ function wpmem_login() { @@ -183,12 +189,8 @@ function wpmem_login() { /** * Logs the user out then redirects. * - * @since 2.0 + * @since 2.0.0 * - * @uses wp_clearcookie - * @uses wp_logout - * @uses nocache_headers - * @uses wp_redirect * @param string $redirect_to The URL to redirect to at logout. */ function wpmem_logout( $redirect_to = null ) { @@ -207,7 +209,7 @@ function wpmem_logout( $redirect_to = null ) { wp_clear_auth_cookie(); - // This action is defined in /wp-includes/pluggable.php. + /** This action is defined in /wp-includes/pluggable.php. */ do_action( 'wp_logout' ); nocache_headers(); @@ -220,17 +222,20 @@ function wpmem_logout( $redirect_to = null ) { if ( ! function_exists( 'wpmem_login_status' ) ): /** - * Displays the user's login status. + * Returns or displays the user's login status. * - * @since 2.0 + * @since 2.0.0 * - * @uses wpmem_inc_memberlinks() - * @param boolean $echo Determines whether function should print result or not (default: true). - * @return string $status The user status string produced by wpmem_inc_memberlinks(). + * @param boolean $echo Determines whether function should print result or not (default: true). + * @return string $status The user status string produced by wpmem_inc_memberlinks(). */ function wpmem_login_status( $echo = true ) { - include_once( WPMEM_PATH . 'inc/dialogs.php' ); + /** + * Load the dialogs functions. + */ + require_once( WPMEM_PATH . 'inc/dialogs.php' ); + if ( is_user_logged_in() ) { $status = wpmem_inc_memberlinks( 'status' ); if ( $echo ) { @@ -248,12 +253,16 @@ function wpmem_login_status( $echo = true ) { * * This function is a wrapper for wpmem_do_sidebar(). * - * @since 2.0 + * @since 2.0.0 * - * @uses wpmem_do_sidebar() + * @todo This function may be deprecated. */ function wpmem_inc_sidebar() { + /** + * Load the sidebar functions. + */ include_once( WPMEM_PATH . 'inc/sidebar.php' ); + // Render the sidebar. wpmem_do_sidebar(); } endif; @@ -261,15 +270,23 @@ function wpmem_inc_sidebar() { if ( ! function_exists( 'widget_wpmemwidget_init' ) ): /** - * Initializes the widget. + * Initializes the WP-Members widget. * - * @since 2.0 - * - * @uses register_widget + * @since 2.0.0 */ function widget_wpmemwidget_init() { - include_once( WPMEM_PATH . 'inc/class-wp-members-widget.php' ); - include_once( WPMEM_PATH . 'inc/sidebar.php' ); + + /** + * Load the WP-Members widget class. + */ + require_once( WPMEM_PATH . 'inc/class-wp-members-widget.php' ); + + /** + * Load the sidebar functions. + */ + require_once( WPMEM_PATH . 'inc/sidebar.php' ); + + // Register the WP-Members widget. register_widget( 'widget_wpmemwidget' ); } endif; @@ -279,10 +296,11 @@ function widget_wpmemwidget_init() { /** * Handles user password change (not reset). * - * @since 2.1 + * @since 2.1.0 * - * @global $user_ID - * @return string the value for $wpmem->regchk + * @global int $user_ID The WordPress user ID. + * + * @return string The value for $wpmem->regchk */ function wpmem_change_password() { @@ -308,6 +326,7 @@ function wpmem_change_password() { * Fires after password change. * * @since 2.9.0 + * @since 3.0.5 Added $pass1 to arguments passed. * * @param int $user_ID The user's numeric ID. * @param string $pass1 The user's new plain text password. @@ -327,11 +346,11 @@ function wpmem_change_password() { /** * Resets a forgotten password. * - * @since 2.1 + * @since 2.1.0 + * + * @global object $wpmem The WP-Members object class. * - * @uses wp_generate_password - * @uses wp_update_user - * @return string value for $wpmem->regchk + * @return string The value for $wpmem->regchk */ function wpmem_reset_password() { @@ -374,14 +393,19 @@ function wpmem_reset_password() { // Update the users password. wp_update_user( array ( 'ID' => $user->ID, 'user_pass' => $new_pass ) ); - // Send it in an email. + /** + * Load the email functions. + */ require_once( WPMEM_PATH . 'inc/email.php' ); + + // Send it in an email. wpmem_inc_regemail( $user->ID, $new_pass, 3 ); /** * Fires after password reset. * * @since 2.9.0 + * @since 3.0.5 Added $pass1 to arguments passed. * * @param int $user_ID The user's numeric ID. * @param string $new_pass The new plain text password. @@ -404,12 +428,11 @@ function wpmem_reset_password() { if ( ! function_exists( 'wpmem_no_reset' ) ): /** - * Keeps users not activated from resetting their password - * via wp-login when using registration moderation. + * Prevents users not activated from resetting their password. * * @since 2.5.1 * - * @return bool + * @return bool Returns false if the user is not activated, otherwise true. */ function wpmem_no_reset() { @@ -439,7 +462,10 @@ function wpmem_no_reset() { * @since 2.8.3 */ function wpmem_wp_register_form() { - include_once( WPMEM_PATH . 'inc/wp-registration.php' ); + /** + * Load native WP registration functions. + */ + require_once( WPMEM_PATH . 'inc/wp-registration.php' ); wpmem_do_wp_register_form(); } @@ -449,24 +475,28 @@ function wpmem_wp_register_form() { * * @since 2.8.3 * - * @param $errors - * @param $sanatized_user_login - * @param $user_email - * @return $errors + * @global object $wpmem The WP-Members object class. + * + * @param array $errors A WP_Error object containing any errors encountered during registration. + * @param string $sanitized_user_login User's username after it has been sanitized. + * @param string $user_email User's email. + * @return array $errors A WP_Error object containing any errors encountered during registration. */ function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) { global $wpmem; - $wpmem_fields = $wpmem->fields; //get_option( 'wpmembers_fields' ); + + // Get any meta fields that should be excluded. + // @todo This needs to change to $wpmem->excluded_fields($tag). $exclude = wpmem_get_excluded_meta( 'register' ); - foreach ( $wpmem_fields as $field ) { + foreach ( $wpmem->fields as $field ) { $is_error = false; if ( $field[5] == 'y' && $field[2] != 'user_email' && ! in_array( $field[2], $exclude ) ) { - if ( ( $field[3] == 'checkbox' ) && ( ! isset( $_POST[$field[2]] ) ) ) { + if ( ( $field[3] == 'checkbox' ) && ( ! isset( $_POST[ $field[2] ] ) ) ) { $is_error = true; } - if ( ( $field[3] != 'checkbox' ) && ( ! $_POST[$field[2]] ) ) { + if ( ( $field[3] != 'checkbox' ) && ( ! $_POST[ $field[2] ] ) ) { $is_error = true; } if ( $is_error ) { $errors->add( 'wpmem_error', sprintf( __('Sorry, %s is a required field.', 'wp-members'), $field[1] ) ); } @@ -482,7 +512,9 @@ function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) { * * @since 2.8.3 * - * @param $user_id + * @global object $wpmem The WP-Members object class. + * + * @param int $user_id The WP user ID. */ function wpmem_wp_reg_finalize( $user_id ) { @@ -490,13 +522,12 @@ function wpmem_wp_reg_finalize( $user_id ) { $native_reg = ( isset( $_POST['wp-submit'] ) && $_POST['wp-submit'] == esc_attr( __( 'Register' ) ) ) ? true : false; $add_new = ( isset( $_POST['action'] ) && $_POST['action'] == 'createuser' ) ? true : false; if ( $native_reg || $add_new ) { - // Get the fields. - $wpmem_fields = $wpmem->fields; //get_option( 'wpmembers_fields' ); // Get any excluded meta fields. + // @todo This needs to change to $wpmem->excluded_fields($tag). $exclude = wpmem_get_excluded_meta( 'register' ); - foreach ( $wpmem_fields as $meta ) { - if ( isset( $_POST[$meta[2]] ) && ! in_array( $meta[2], $exclude ) ) { - update_user_meta( $user_id, $meta[2], sanitize_text_field( $_POST[$meta[2]] ) ); + foreach ( $wpmem->fields as $meta ) { + if ( isset( $_POST[ $meta[2] ] ) && ! in_array( $meta[2], $exclude ) ) { + update_user_meta( $user_id, $meta[2], sanitize_text_field( $_POST[ $meta[2] ] ) ); } } } @@ -510,6 +541,7 @@ function wpmem_wp_reg_finalize( $user_id ) { * @since 2.8.7 */ function wpmem_wplogin_stylesheet() { + // @todo Should this enqueue styles? echo ''; } @@ -518,27 +550,28 @@ function wpmem_wplogin_stylesheet() { * Securifies the comments. * * If the user is not logged in and the content is blocked - * (i.e. wpmem_block() returns true), function loads a + * (i.e. wpmem->is_blocked() returns true), function loads a * dummy/empty comments template. * * @since 2.9.9 * - * @return bool $open Whether the current post is open for comments. + * @return bool $open true if current post is open for comments, otherwise false. */ function wpmem_securify_comments( $open ) { $open = ( ! is_user_logged_in() && wpmem_block() ) ? false : $open; - + /** * Filters whether comments are open or not. * * @since 3.0.0 * - * @param bool $open Whether the current post is open for comments. + * @param bool $open true if current post is open for comments, otherwise false. */ $open = apply_filters( 'wpmem_securify_comments', $open ); - + if ( ! $open ) { + /** This filter is documented in wp-includes/comment-template.php */ add_filter( 'comments_array' , 'wpmem_securify_comments_array' , 10, 2 ); } @@ -551,6 +584,8 @@ function wpmem_securify_comments( $open ) { * * @since 3.0.1 * + * @global object $wpmem The WP-Members object class. + * * @return array $comments The comments array. */ function wpmem_securify_comments_array( $comments , $post_id ) { @@ -564,12 +599,16 @@ function wpmem_securify_comments_array( $comments , $post_id ) { * Redirects a user to defined login page with return redirect. * * @since 3.0.2 + * + * @global object $wp The WordPress object. + * @global object $post The WordPress post object. + * @global object $wpmem The WP-Members object. */ function wpmem_redirect_to_login() { global $wp, $post, $wpmem; - if( ! is_user_logged_in() && $wpmem->is_blocked() ) { + if ( ! is_user_logged_in() && $wpmem->is_blocked() ) { // Get current page location. $current_page = home_url( add_query_arg( array(), $wp->request ) ); @@ -584,4 +623,4 @@ function wpmem_redirect_to_login() { } -// End of File. \ No newline at end of file +// End of file. \ No newline at end of file From 175ba85f26fa8f605e25dea5c0aedd07dcfa36b3 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 19 Oct 2015 14:05:43 -0500 Subject: [PATCH 0172/1694] code standards, improved inline documentation, new check for wpmem_form shortcode to skip if no additional tag exists. --- inc/shortcodes.php | 184 ++++++++++++++++++++++++++------------------- 1 file changed, 105 insertions(+), 79 deletions(-) diff --git a/inc/shortcodes.php b/inc/shortcodes.php index bd536bf9..31c9d9e1 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -9,8 +9,8 @@ * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * - * @package WordPress - * @subpackage WP-Members + * @package WP-Members + * @subpackage WP-Members Shortcodes * @author Chad Butler * @copyright 2006-2015 * @@ -20,7 +20,6 @@ * - wpmem_sc_logged_out * - wpmem_shortcode * - wpmem_do_sc_pages - * - wpmem_do_sc_pages * - wpmem_sc_user_count */ @@ -46,87 +45,104 @@ /** * Function for forms called by shortcode. * - * @since 3.0 + * @since 3.0.0 * - * @param $attr - * @param $content - * @param $tag - * @return $content + * @global object $wpmem The WP_Members object. + * @global string $wpmem_themsg The WP-Members message container. + * + * @param array $attr + * @param string $content + * @param string $tag + * @return string $content */ function wpmem_sc_forms( $atts, $content = null, $tag = 'wpmem_form' ) { - // Dependencies. global $wpmem, $wpmem_themsg; + + /** + * Load core functions if they are not already loaded. + */ include_once( WPMEM_PATH . 'inc/core.php' ); + + /** + * Load dialog functions if they are not already loaded. + */ include_once( WPMEM_PATH . 'inc/dialogs.php' ); + // Defaults. $redirect_to = ( isset( $atts['redirect_to'] ) ) ? $atts['redirect_to'] : null; $texturize = ( isset( $atts['texturize'] ) ) ? $atts['texturize'] : false; - switch ( $atts ) { - - case in_array( 'login', $atts ): - if ( is_user_logged_in() ) { - /* - * If the user is logged in, return any nested content (if any) - * or the default bullet links if no nested content. - */ - $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'login' ); - } else { - /* - * If the user is not logged in, return an error message if a login - * error state exists, or return the login form. - */ - $content = ( $wpmem->regchk == 'loginfailed' ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to ); - } - break; - - case in_array( 'register', $atts ): - if ( is_user_logged_in() ) { - /* - * If the user is logged in, return any nested content (if any) - * or the default bullet links if no nested content. - */ - $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'register' ); - } else { - // @todo Can this be moved into another function? Should $wpmem get an error message handler? - if ( $wpmem->regchk == 'captcha' ) { - global $wpmem_captcha_err; - $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; - } - $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ) : ''; - $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login() : wpmem_inc_registration( 'new', '', $redirect_to ); - } - break; - - case in_array( 'password', $atts ): - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); - break; - - case in_array( 'user_edit', $atts ): - $content = wpmem_page_user_edit( $wpmem->regchk, $content ); - break; - - } - /* - * @todo - This is temporary for texturizing. Need to work it into an argument in the function call as - * to whether the [wpmem_txt] shortcode is even included. For now, this will allow this function to be - * tested as an include during the 3.0 alpha/beta testing period and a permanent solution can be worked - * out for 3.x.x. + * The [wpmem_form] shortcode requires additional tags (login, register, etc) that + * will be in the $atts array. If $atts is not an array, no additional tags were + * given, so there is nothing to render. */ - if ( array_key_exists( 'texturize', $atts ) && $atts['texturize'] == 'false' ) { - $content = str_replace( array( '[wpmem_txt]', '[/wpmem_txt]' ), array( '', '' ), $content ); - } - if ( strstr( $content, '[wpmem_txt]' ) ) { - // Fixes the wptexturize. - remove_filter( 'the_content', 'wpautop' ); - remove_filter( 'the_content', 'wptexturize' ); - add_filter( 'the_content', 'wpmem_texturize', 999 ); - } - // @todo - Look into shortcode_unautop(). - /** End temporary texturize functions */ + if ( is_array( $atts ) ) { + + // If $atts is an array, get the tag from the array so we know what form to render. + switch ( $atts ) { + + case in_array( 'login', $atts ): + if ( is_user_logged_in() ) { + /* + * If the user is logged in, return any nested content (if any) + * or the default bullet links if no nested content. + */ + $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'login' ); + } else { + /* + * If the user is not logged in, return an error message if a login + * error state exists, or return the login form. + */ + $content = ( $wpmem->regchk == 'loginfailed' ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to ); + } + break; + + case in_array( 'register', $atts ): + if ( is_user_logged_in() ) { + /* + * If the user is logged in, return any nested content (if any) + * or the default bullet links if no nested content. + */ + $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'register' ); + } else { + // @todo Can this be moved into another function? Should $wpmem get an error message handler? + if ( $wpmem->regchk == 'captcha' ) { + global $wpmem_captcha_err; + $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; + } + $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ) : ''; + $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login() : wpmem_inc_registration( 'new', '', $redirect_to ); + } + break; + case in_array( 'password', $atts ): + $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + break; + + case in_array( 'user_edit', $atts ): + $content = wpmem_page_user_edit( $wpmem->regchk, $content ); + break; + + } + + /* + * This is for texturizing. Need to work it into an argument in the function call as to whether the + * [wpmem_txt] shortcode is even included. @todo - Is this a temporary solution or is there something + * cleaner that can be worked out? + */ + if ( array_key_exists( 'texturize', $atts ) && $atts['texturize'] == 'false' ) { + $content = str_replace( array( '[wpmem_txt]', '[/wpmem_txt]' ), array( '', '' ), $content ); + } + if ( strstr( $content, '[wpmem_txt]' ) ) { + // Fixes the wptexturize. + remove_filter( 'the_content', 'wpautop' ); + remove_filter( 'the_content', 'wptexturize' ); + add_filter( 'the_content', 'wpmem_texturize', 999 ); + } + // End texturize functions */ + } return do_shortcode( $content ); } @@ -144,6 +160,8 @@ function wpmem_sc_forms( $atts, $content = null, $tag = 'wpmem_form' ) { * * @since 3.0.0 * + * @global object $wpmem The WP_Members object. + * * @param array $atts * @param string $content * @param string $tag @@ -230,7 +248,9 @@ function wpmem_sc_logged_out( $atts, $content = null, $tag ) { /** * Displays login form when called by shortcode. * - * @since 3.0 + * @since 3.0.0 + * + * @global object $wpmem The WP_Members object. * * @param $atts * @param $content @@ -264,7 +284,9 @@ function wpmem_sc_login_form( $atts, $content, $tag ) { * is used. Also executes shortcodes for login status with the wpmem_logged_in tags * and fields when the wpmem_field tags are used. * - * @since 2.4 + * @since 2.4.0 + * + * @global object $wpmem The WP_Members object. * * @param array $attr page|url|status|msg|field|id * @param string $content @@ -366,13 +388,14 @@ function wpmem_shortcode( $attr, $content = null, $tag = 'wp-members' ) { * But where that function handles general content, this function * handles building specific pages generated by shortcodes. * - * @since 2.6 + * @since 2.6.0 + * + * @global object $wpmem The WP_Members object. + * @global string $wpmem_themsg The WP-Members message container. + * @global object $post The WordPress post object. * * @param string $page * @param string $redirect_to - * @global object $wpmem - * @global string $wpmem_themsg - * @global object $post * @return string $content */ function wpmem_do_sc_pages( $page, $redirect_to = null ) { @@ -500,11 +523,14 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) { /** * User count shortcode. * - * @since 3.0 + * @since 3.0.0 + * + * @global object $wpdb The WordPress database object. * - * @todo Evaluate this shortcode for full inclusion. + * @param array $atts Shortcode attributes. + * @param string $content The shortcode content. + * @return string $content */ -add_shortcode( 'wpmem_show_count', 'wpmem_sc_user_count' ); function wpmem_sc_user_count( $atts, $content = null ) { global $wpdb; $do_query = ( $atts['key'] && $atts['value'] ) ? true : false; From c34de6e472036485a05b552facc6aa68ee8a57dc Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 20 Oct 2015 13:45:22 -0500 Subject: [PATCH 0173/1694] better path for plugin_basename --- admin/admin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/admin.php b/admin/admin.php index 7db8ae27..bfbf5754 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -72,7 +72,7 @@ function wpmem_a_do_field_reorder() { function wpmem_admin_plugin_links( $links, $file ) { static $wpmem_plugin; if ( ! $wpmem_plugin ) { - $wpmem_plugin = plugin_basename( 'wp-members/wp-members.php' ); + $wpmem_plugin = plugin_basename( WPMEM_PATH . '/wp-members.php' ); } if ( $file == $wpmem_plugin ) { $settings_link = '' . __( 'Settings', 'wp-members' ) . ''; From ab5d791035c47fca5bc66e778227bc6dd7b4af67 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 2 Nov 2015 11:24:54 -0600 Subject: [PATCH 0174/1694] added comment on filter moved to WP_Members class --- inc/class-wp-members.php | 1 + 1 file changed, 1 insertion(+) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 8a56dd39..776c2a56 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -24,6 +24,7 @@ function __construct() { * Filter the options before they are loaded into constants. * * @since 2.9.0 + * @since 3.0.0 Moved to the WP_Members class. * * @param array $this->settings An array of the WP-Members settings. */ From cfe0d4d0bd2858df9d403fe0c9a228368bba6f43 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 2 Nov 2015 11:26:25 -0600 Subject: [PATCH 0175/1694] fix for post WP 4.0 installs (no WPLANG constant definition) when reCAPTCHA is used and notices are enabled; fix for display_name update on user profile update; code standards --- inc/forms.php | 42 +++++++++++++++++++++++------------------- 1 file changed, 23 insertions(+), 19 deletions(-) diff --git a/inc/forms.php b/inc/forms.php index b5a9302b..70d91915 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -33,24 +33,27 @@ * * @since 1.8 * - * @uses wpmem_login_form() + * @global object $wpmem The WP_Members object. + * @global string $wpmem_regchk The WP-Members message container. + * @global object $post The WordPress Post object. * * @param string $page * @param string $redirect_to * @return string $str The generated html for the login form. */ -function wpmem_inc_login( $page="page", $redirect_to = null, $show = 'show' ) { +function wpmem_inc_login( $page = "page", $redirect_to = null, $show = 'show' ) { global $wpmem, $wpmem_regchk, $post; $str = ''; - if ( $page == "page" ){ - if ( $wpmem_regchk != "success" ){ + if ( $page == "page" ) { + + if ( $wpmem_regchk != "success" ) { $arr = get_option( 'wpmembers_dialogs' ); - // this shown above blocked content + // This shown above blocked content. $str = '

    ' . __( stripslashes( $arr[0] ), 'wp-members' ) . '

    '; /** @@ -65,7 +68,7 @@ function wpmem_inc_login( $page="page", $redirect_to = null, $show = 'show' ) { } } - // create the default inputs + // Create the default inputs. $default_inputs = array( array( 'name' => __( 'Username' ), @@ -124,9 +127,7 @@ function wpmem_inc_login( $page="page", $redirect_to = null, $show = 'show' ) { * * Loads the form for changing password. * - * @since 2.0 - * - * @uses wpmem_login_form() + * @since 2.0.0 * * @return string $str the generated html for the change password form. */ @@ -190,15 +191,13 @@ function wpmem_inc_changepassword() { * * Loads the form for resetting password. * - * @since 2.1 - * - * @uses wpmem_login_form() + * @since 2.1.0 * * @return string $str the generated html fo the reset password form. */ -function wpmem_inc_resetpassword() -{ - /** create the default inputs **/ +function wpmem_inc_resetpassword() { + + // Create the default inputs. $default_inputs = array( array( 'name' => __( 'Username' ), @@ -637,14 +636,18 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = $val = htmlspecialchars( get_user_meta( $userdata->ID, 'description', 'true' ) ); break; - case( 'user_email' ): - case( 'confirm_email' ): + case 'user_email': + case 'confirm_email': $val = $userdata->user_email; break; - case( 'user_url' ): + case 'user_url': $val = esc_url( $userdata->user_url ); break; + + case 'display_name': + $val = htmlspecialchars( $userdata->display_name ); + break; default: $val = htmlspecialchars( get_user_meta( $userdata->ID, $field[2], 'true' ) ); @@ -927,7 +930,8 @@ function wpmem_inc_recaptcha( $arr ) { // determine if reCAPTCHA should be another language $allowed_langs = array( 'nl', 'fr', 'de', 'pt', 'ru', 'es', 'tr' ); - $compare_lang = strtolower( substr( WPLANG, -2 ) ); + $locale = apply_filters( 'plugin_locale', get_locale(), 'wp-members' ); + $compare_lang = strtolower( substr( $locale, -2 ) ); $use_the_lang = ( in_array( $compare_lang, $allowed_langs ) ) ? $compare_lang : false; $lang = ( $use_the_lang ) ? ' lang : \'' . $use_the_lang . '\'' : ''; From 125b9473f66134965f6065075c87bb846c0dc8e0 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 2 Nov 2015 11:28:58 -0600 Subject: [PATCH 0176/1694] code standards, set 3.0.7 version --- wp-members.php | 79 ++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 67 insertions(+), 12 deletions(-) diff --git a/wp-members.php b/wp-members.php index 516aae9d..94643f69 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.6 +Version: 3.0.7 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.6' ); +define( 'WPMEM_VERSION', '3.0.7' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); @@ -86,6 +86,8 @@ * its features and options. * * @since 2.9.0 + * + * @global object $wpmem The WP-Members object class. */ function wpmem_init() { @@ -99,8 +101,12 @@ function wpmem_init() { */ do_action( 'wpmem_pre_init' ); - // Load WP_Members class. - include_once( WPMEM_PATH . 'inc/class-wp-members.php' ); + /** + * Load the WP_Members class. + */ + require_once( WPMEM_PATH . 'inc/class-wp-members.php' ); + + // Invoke the WP_Members class. $wpmem = new WP_Members(); /** @@ -115,7 +121,7 @@ function wpmem_init() { * * @since 2.9.0 * - * @param string The path to wp-members-pluggable.php. + * @param string The path to WP-Members plugin functions file. */ $wpmem_pluggable = apply_filters( 'wpmem_plugins_file', WP_PLUGIN_DIR . '/wp-members-pluggable.php' ); @@ -128,8 +134,10 @@ function wpmem_init() { $exp_module = ( in_array( 'wp-members-expiration/module.php', get_option( 'active_plugins' ) ) ) ? true : false; define( 'WPMEM_EXP_MODULE', $exp_module ); - // Load core file. - include_once( WPMEM_PATH . 'inc/core.php' ); + /** + * Load the WP-Members core functions file. + */ + require_once( WPMEM_PATH . 'inc/core.php' ); // Load actions and filters. $wpmem->load_hooks(); @@ -170,6 +178,9 @@ function wpmem_chk_admin() { do_action( 'wpmem_pre_admin_init' ); if ( is_multisite() && current_user_can( 'edit_theme_options' ) ) { + /** + * Load the main admin file. + */ require_once( WPMEM_PATH . 'admin/admin.php' ); } @@ -178,11 +189,30 @@ function wpmem_chk_admin() { * otherwise, load profile actions for non-admins. */ if ( current_user_can( 'edit_users' ) ) { + + /** + * Load the main admin file if not already loaded. + */ require_once( WPMEM_PATH . 'admin/admin.php' ); + + /** + * Load the admin user functions. + */ require_once( WPMEM_PATH . 'admin/users.php' ); - include_once( WPMEM_PATH . 'admin/user-profile.php' ); + + /** + * Load the admin user profile functions. + */ + require_once( WPMEM_PATH . 'admin/user-profile.php' ); + } else { + + /** + * Load the admin user functions. + */ require_once( WPMEM_PATH . 'inc/users.php' ); + + // User actions and filters. add_action( 'show_user_profile', 'wpmem_user_profile' ); add_action( 'edit_user_profile', 'wpmem_user_profile' ); add_action( 'profile_update', 'wpmem_profile_update' ); @@ -193,7 +223,13 @@ function wpmem_chk_admin() { * meta boxes and custom post/page columns. */ if ( current_user_can( 'edit_posts' ) ) { - include_once( WPMEM_PATH . 'admin/post.php' ); + + /** + * Load the admin post functions. + */ + require_once( WPMEM_PATH . 'admin/post.php' ); + + // Post actions and filters. add_action( 'add_meta_boxes', 'wpmem_block_meta_add' ); add_action( 'save_post', 'wpmem_block_meta_save' ); add_filter( 'manage_posts_columns', 'wpmem_post_columns' ); @@ -229,9 +265,16 @@ function wpmem_admin_options() { * @since 2.5.2 */ function wpmem_install() { + + /** + * Load the install file. + */ require_once( WPMEM_PATH . 'wp-members-install.php' ); + + // Multisite requires different install process. if ( is_multisite() ) { - // if it is multisite, install options for each blog + + // If it is multisite, install options for each blog. global $wpdb; $blogs = $wpdb->get_results( "SELECT blog_id @@ -247,8 +290,10 @@ function wpmem_install() { wpmem_do_install(); } switch_to_blog( $original_blog_id ); + } else { - // normal single install + + // Single site install. wpmem_do_install(); } } @@ -268,9 +313,19 @@ function wpmem_install() { * @param $meta */ function wpmem_mu_new_site( $blog_id, $user_id, $domain, $path, $site_id, $meta ) { + + /** + * Load the install file. + */ require_once( WPMEM_PATH . 'wp-members-install.php' ); + + // Switch to the new blog. switch_to_blog( $blog_id ); + + // Run the WP-Members install. wpmem_do_install(); + + // Switch back to the current blog. restore_current_blog(); } @@ -323,4 +378,4 @@ function wpmem_load_textdomain() { return; } -// End of File. \ No newline at end of file +// End of file. \ No newline at end of file From 4b9ec590435c38250520cdd97552e57687742b8f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 2 Nov 2015 11:35:14 -0600 Subject: [PATCH 0177/1694] readme updates for 3.0.7 --- readme.txt | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/readme.txt b/readme.txt index a531aac5..b0d87138 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 Tested up to: 4.3.1 -Stable tag: 3.0.6 +Stable tag: 3.0.7 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,7 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.6 is a functional improvement release with minimal core changes. +WP-Members 3.0.7 is a functional improvement release with minimal core changes. WP-Members 3.0.0 is a major version release. Please review the changelog: http://rkt.bz/v30 == Screenshots == @@ -135,6 +135,15 @@ WP-Members 3.0.0 is a major version release. Please review the changelog: http:/ == Changelog == += 3.0.7 = + +* Fix for use of display_name on profile update. +* Fix for newer installs (post WP 4.0) where WPLANG is not defined and reCAPTCHA is used. +* Fix in wpmem_form shortcode to skp if no additional tag exists. +* Fix to plugin_basename. +* Changes in core to use fields from WP_Members class (preparing for new form field process). +* Reviews and updates to code standards and inline documentation. + = 3.0.6 = * Updates to localization function - documented plugin_locale filter, wpmem_localization_file filter, and improved load_textdomain logic. From 0c9344f5b76cddb6dbe4987d8d88d79a0e322d5b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 6 Nov 2015 22:14:13 -0600 Subject: [PATCH 0178/1694] added check for expiration module constant to avoid undefined errors if expiration settings are inadvertently left on when the plugin is deactivated. --- admin/tab-fields.php | 2 +- admin/user-export.php | 6 +++--- admin/user-profile.php | 4 ++-- admin/users.php | 4 ++-- inc/dialogs.php | 2 +- inc/email.php | 8 ++++---- inc/shortcodes.php | 2 +- 7 files changed, 14 insertions(+), 14 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 1727cd45..0effbf84 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -535,7 +535,7 @@ function wpmem_a_field_table( $wpmem_fields ) { /> - use_exp == 1 ) { ?> + use_exp == 1 ) { ?>   Subscription Type diff --git a/admin/user-export.php b/admin/user-export.php index c3a0b20e..2f36653c 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -74,7 +74,7 @@ function wpmem_export_users( $args, $users = null ) { } $hrow .= ( $wpmem->mod_reg == 1 ) ? __( 'Activated?', 'wp-members' ) . "," : ''; - $hrow .= ( $wpmem->use_exp == 1 ) ? __( 'Subscription', 'wp-members' ) . "," . __( 'Expires', 'wp-members' ) . "," : ''; + $hrow .= ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? __( 'Subscription', 'wp-members' ) . "," . __( 'Expires', 'wp-members' ) . "," : ''; $hrow .= __( 'Registered', 'wp-members' ) . ","; $hrow .= __( 'IP', 'wp-members' ); @@ -110,8 +110,8 @@ function wpmem_export_users( $args, $users = null ) { } $data .= ( $wpmem->mod_reg == 1 ) ? '"' . ( get_user_meta( $user, 'active', 1 ) ? __( 'Yes' ) : __( 'No' ) ) . '",' : ''; - $data .= ( $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "exp_type", true ) . '",' : ''; - $data .= ( $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "expires", true ) . '",' : ''; + $data .= ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "exp_type", true ) . '",' : ''; + $data .= ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "expires", true ) . '",' : ''; $data .= '"' . $user_info->user_registered . '",'; $data .= '"' . get_user_meta( $user, "wpmem_reg_ip", true ). '"'; diff --git a/admin/user-profile.php b/admin/user-profile.php index 34b5354c..d7007305 100644 --- a/admin/user-profile.php +++ b/admin/user-profile.php @@ -135,7 +135,7 @@ function wpmem_admin_fields() { * If registration is moderated, this doesn't show * if user is not active yet. */ - if ( $wpmem->use_exp == 1 ) { + if ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) { if ( ( $wpmem->mod_reg == 1 && get_user_meta( $user_id, 'active', true ) == 1 ) || ( $wpmem->mod_reg != 1 ) ) { wpmem_a_extenduser( $user_id ); } @@ -222,7 +222,7 @@ function wpmem_admin_update() { } } - ( $wpmem->use_exp == 1 ) ? wpmem_a_extend_user( $user_id ) : ''; + ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? wpmem_a_extend_user( $user_id ) : ''; /** * Fires after the user profile is updated. diff --git a/admin/users.php b/admin/users.php index 75818647..3c132918 100644 --- a/admin/users.php +++ b/admin/users.php @@ -238,13 +238,13 @@ function wpmem_users_views( $views ) { global $wpmem; $arr = array(); - if ( $wpmem->use_exp == 1 ) { + if ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) { $arr[] = 'Pending'; } if ( $wpmem->use_trial == 1 ) { $arr[] = 'Trial'; } - if ( $wpmem->use_exp == 1 ) { + if ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) { $arr[] = 'Subscription'; $arr[] = 'Expired'; } diff --git a/inc/dialogs.php b/inc/dialogs.php index 490f73db..607e1d0c 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -195,7 +195,7 @@ function wpmem_inc_memberlinks( $page = 'members' ) { case 'members': $str = ''; /** * Filter the links displayed on the User Profile page (logged in state). diff --git a/inc/email.php b/inc/email.php index 07c3455a..929cb020 100644 --- a/inc/email.php +++ b/inc/email.php @@ -81,8 +81,8 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, $arr['user_login'] = stripslashes( $user->user_login ); $arr['user_email'] = stripslashes( $user->user_email ); $arr['blogname'] = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); - $arr['exp_type'] = ( $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; - $arr['exp_date'] = ( $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; + $arr['exp_type'] = ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; + $arr['exp_date'] = ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; $arr['wpmem_msurl'] = $wpmem->user_pages['profile']; $arr['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); $arr['do_shortcodes'] = true; @@ -280,8 +280,8 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { $arr['user_ip'] = get_user_meta( $user_id, 'wpmem_reg_ip', true ); $arr['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); $arr['act_link'] = get_bloginfo ( 'wpurl' ) . "/wp-admin/user-edit.php?user_id=".$user_id; - $arr['exp_type'] = ( $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; - $arr['exp_date'] = ( $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; + $arr['exp_type'] = ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; + $arr['exp_date'] = ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; $arr['do_shortcodes'] = true; $arr['add_footer'] = true; $arr['disable'] = false; diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 31c9d9e1..463d2b42 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -212,7 +212,7 @@ function wpmem_sc_logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) // If there is a status attribute of "sub" and the user is logged in. if ( ( isset( $atts['status'] ) ) && $atts['status'] == 'sub' && is_user_logged_in() ) { - if ( $wpmem->use_exp == 1 ) { + if ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) { if ( ! wpmem_chk_exp() ) { $do_return = true; } elseif ( $atts['msg'] == true ) { From 450fea700843f727aa4e65b7be87364a783f93bc Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 12 Nov 2015 08:17:07 -0600 Subject: [PATCH 0179/1694] fixed typo in object name for password reset function --- inc/core.php | 2 +- readme.txt | 9 ++++++++- wp-members.php | 4 ++-- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/inc/core.php b/inc/core.php index 859123a6..ba181253 100644 --- a/inc/core.php +++ b/inc/core.php @@ -445,7 +445,7 @@ function wpmem_no_reset() { $user = get_user_by( 'login', $username ); } - if ( $wmem->mod_reg == 1 ) { + if ( $wpmem->mod_reg == 1 ) { if ( get_user_meta( $user->ID, 'active', true ) != 1 ) { return false; } diff --git a/readme.txt b/readme.txt index b0d87138..2f62794b 100644 --- a/readme.txt +++ b/readme.txt @@ -111,7 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.7 is a functional improvement release with minimal core changes. +WP-Members 3.0.7.1 is a minor bug fix release for 3.0.7, also a fix release. WP-Members 3.0.0 is a major version release. Please review the changelog: http://rkt.bz/v30 == Screenshots == @@ -135,6 +135,13 @@ WP-Members 3.0.0 is a major version release. Please review the changelog: http:/ == Changelog == += 3.0.7.1 = + + + +* Fix for password reset (typo in object name checking for moderated registration) + + = 3.0.7 = * Fix for use of display_name on profile update. diff --git a/wp-members.php b/wp-members.php index 94643f69..e3998977 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.7 +Version: 3.0.7.1 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.7' ); +define( 'WPMEM_VERSION', '3.0.7.1' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 3812a179ecd5b5c9e42d3c99e735e8748beb42cd Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 12 Nov 2015 08:44:32 -0600 Subject: [PATCH 0180/1694] fix for bug in 3.0.7 when used with PayPal extension - logic test for WPMEM_EXP_MODULE --- admin/tab-fields.php | 2 +- admin/user-export.php | 6 +++--- admin/user-profile.php | 4 ++-- admin/users.php | 4 ++-- inc/dialogs.php | 2 +- inc/email.php | 8 ++++---- inc/shortcodes.php | 2 +- readme.txt | 8 ++++++-- wp-members.php | 4 ++-- 9 files changed, 22 insertions(+), 18 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 0effbf84..198ccf99 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -535,7 +535,7 @@ function wpmem_a_field_table( $wpmem_fields ) { /> - use_exp == 1 ) { ?> + use_exp == 1 ) { ?>   Subscription Type diff --git a/admin/user-export.php b/admin/user-export.php index 2f36653c..bc3d8006 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -74,7 +74,7 @@ function wpmem_export_users( $args, $users = null ) { } $hrow .= ( $wpmem->mod_reg == 1 ) ? __( 'Activated?', 'wp-members' ) . "," : ''; - $hrow .= ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? __( 'Subscription', 'wp-members' ) . "," . __( 'Expires', 'wp-members' ) . "," : ''; + $hrow .= ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? __( 'Subscription', 'wp-members' ) . "," . __( 'Expires', 'wp-members' ) . "," : ''; $hrow .= __( 'Registered', 'wp-members' ) . ","; $hrow .= __( 'IP', 'wp-members' ); @@ -110,8 +110,8 @@ function wpmem_export_users( $args, $users = null ) { } $data .= ( $wpmem->mod_reg == 1 ) ? '"' . ( get_user_meta( $user, 'active', 1 ) ? __( 'Yes' ) : __( 'No' ) ) . '",' : ''; - $data .= ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "exp_type", true ) . '",' : ''; - $data .= ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "expires", true ) . '",' : ''; + $data .= ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "exp_type", true ) . '",' : ''; + $data .= ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? '"' . get_user_meta( $user, "expires", true ) . '",' : ''; $data .= '"' . $user_info->user_registered . '",'; $data .= '"' . get_user_meta( $user, "wpmem_reg_ip", true ). '"'; diff --git a/admin/user-profile.php b/admin/user-profile.php index d7007305..49da2b1b 100644 --- a/admin/user-profile.php +++ b/admin/user-profile.php @@ -135,7 +135,7 @@ function wpmem_admin_fields() { * If registration is moderated, this doesn't show * if user is not active yet. */ - if ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) { + if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { if ( ( $wpmem->mod_reg == 1 && get_user_meta( $user_id, 'active', true ) == 1 ) || ( $wpmem->mod_reg != 1 ) ) { wpmem_a_extenduser( $user_id ); } @@ -222,7 +222,7 @@ function wpmem_admin_update() { } } - ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? wpmem_a_extend_user( $user_id ) : ''; + ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? wpmem_a_extend_user( $user_id ) : ''; /** * Fires after the user profile is updated. diff --git a/admin/users.php b/admin/users.php index 3c132918..99cbdc88 100644 --- a/admin/users.php +++ b/admin/users.php @@ -238,13 +238,13 @@ function wpmem_users_views( $views ) { global $wpmem; $arr = array(); - if ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) { + if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { $arr[] = 'Pending'; } if ( $wpmem->use_trial == 1 ) { $arr[] = 'Trial'; } - if ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) { + if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { $arr[] = 'Subscription'; $arr[] = 'Expired'; } diff --git a/inc/dialogs.php b/inc/dialogs.php index 607e1d0c..85c07f00 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -195,7 +195,7 @@ function wpmem_inc_memberlinks( $page = 'members' ) { case 'members': $str = ''; /** * Filter the links displayed on the User Profile page (logged in state). diff --git a/inc/email.php b/inc/email.php index 929cb020..1f58c798 100644 --- a/inc/email.php +++ b/inc/email.php @@ -81,8 +81,8 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, $arr['user_login'] = stripslashes( $user->user_login ); $arr['user_email'] = stripslashes( $user->user_email ); $arr['blogname'] = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); - $arr['exp_type'] = ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; - $arr['exp_date'] = ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; + $arr['exp_type'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; + $arr['exp_date'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; $arr['wpmem_msurl'] = $wpmem->user_pages['profile']; $arr['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); $arr['do_shortcodes'] = true; @@ -280,8 +280,8 @@ function wpmem_notify_admin( $user_id, $wpmem_fields, $field_data = null ) { $arr['user_ip'] = get_user_meta( $user_id, 'wpmem_reg_ip', true ); $arr['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); $arr['act_link'] = get_bloginfo ( 'wpurl' ) . "/wp-admin/user-edit.php?user_id=".$user_id; - $arr['exp_type'] = ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; - $arr['exp_date'] = ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; + $arr['exp_type'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; + $arr['exp_date'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; $arr['do_shortcodes'] = true; $arr['add_footer'] = true; $arr['disable'] = false; diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 463d2b42..9940bdd5 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -212,7 +212,7 @@ function wpmem_sc_logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) // If there is a status attribute of "sub" and the user is logged in. if ( ( isset( $atts['status'] ) ) && $atts['status'] == 'sub' && is_user_logged_in() ) { - if ( defined( WPMEM_EXP_MODULE ) && $wpmem->use_exp == 1 ) { + if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { if ( ! wpmem_chk_exp() ) { $do_return = true; } elseif ( $atts['msg'] == true ) { diff --git a/readme.txt b/readme.txt index 2f62794b..2d1005f3 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 Tested up to: 4.3.1 -Stable tag: 3.0.7 +Stable tag: 3.0.7.2 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,7 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.7.1 is a minor bug fix release for 3.0.7, also a fix release. +WP-Members 3.0.7.2 is a minor bug fix release for 3.0.7. WP-Members 3.0.0 is a major version release. Please review the changelog: http://rkt.bz/v30 == Screenshots == @@ -135,6 +135,10 @@ WP-Members 3.0.0 is a major version release. Please review the changelog: http:/ == Changelog == += 3.0.7.2 = + +* Fix for PayPal extension (http://rkt.bz/r3). 3.0.7 added some logic to avoid errors if the PayPal extension is disabled but the main option setting remained turned on. This release fixes a flaw in that logic that causes the extension to not display certain links or fields. + = 3.0.7.1 = diff --git a/wp-members.php b/wp-members.php index e3998977..ecfb465f 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.7.1 +Version: 3.0.7.2 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.7.1' ); +define( 'WPMEM_VERSION', '3.0.7.2' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 8b1068ae43218c0a9c2df6b2575966ebad26edb9 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 1 Dec 2015 16:26:44 -0600 Subject: [PATCH 0181/1694] removed extract from register form function, code standards for comments --- inc/forms.php | 217 +++++++++++++++++++++++++------------------------- 1 file changed, 108 insertions(+), 109 deletions(-) diff --git a/inc/forms.php b/inc/forms.php index 70d91915..f0f727a5 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -316,10 +316,10 @@ function wpmem_login_form( $page, $arr ) { */ $args = apply_filters( 'wpmem_login_form_args', '', $action ); - // merge $args with defaults + // Merge $args with defaults. extract( wp_parse_args( $args, $defaults ) ); - // build the input rows + // Build the input rows. foreach ( $inputs as $input ) { $label = ''; $field = wpmem_create_formfield( $input['tag'], $input['type'], '', '', $input['class'] ); @@ -349,7 +349,7 @@ function wpmem_login_form( $page, $arr ) { */ $rows = apply_filters( 'wpmem_login_form_rows', $rows, $action ); - // put the rows from the array into $form + // Put the rows from the array into $form. $form = ''; foreach ( $rows as $row_item ) { $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $n . $row_item['label'] . $n : $row_item['label'] . $n; @@ -358,7 +358,7 @@ function wpmem_login_form( $page, $arr ) { $form.= $row; } - // build hidden fields, filter, and add to the form + // Build hidden fields, filter, and add to the form. $hidden = wpmem_create_formfield( 'redirect_to', 'hidden', $redirect_to ) . $n; $hidden = $hidden . wpmem_create_formfield( 'a', 'hidden', $action ) . $n; $hidden = ( $action != 'login' ) ? $hidden . wpmem_create_formfield( 'formsubmit', 'hidden', '1' ) : $hidden; @@ -373,7 +373,7 @@ function wpmem_login_form( $page, $arr ) { */ $form = $form . apply_filters( 'wpmem_login_hidden_fields', $hidden, $action ); - // build the buttons, filter, and add to the form + // Build the buttons, filter, and add to the form. if ( $action == 'login' ) { $remember_check = ( $remember_check ) ? $t . wpmem_create_formfield( 'rememberme', 'checkbox', 'forever' ) . ' ' . __( 'Remember Me' ) . '  ' . $n : ''; $buttons = $remember_check . $t . '' . $n; @@ -423,25 +423,25 @@ function wpmem_login_form( $page, $arr ) { } - // apply the heading + // Apply the heading. $form = $heading_before . $heading . $heading_after . $n . $form; - // apply fieldset wrapper + // Apply fieldset wrapper. $form = $fieldset_before . $n . $form . $fieldset_after . $n; - // apply form wrapper + // Apply form wrapper. $form = '
    ' . $n . $form . '
    '; - // apply anchor + // Apply anchor. $form = '' . $n . $form; - // apply main wrapper + // Apply main wrapper. $form = $main_div_before . $n . $form . $n . $main_div_after; - // apply wpmem_txt wrapper + // Apply wpmem_txt wrapper. $form = $txt_before . $form . $txt_after; - // remove line breaks + // Remove line breaks. $form = ( $strip_breaks ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; /** @@ -468,7 +468,7 @@ function wpmem_login_form( $page, $arr ) { $form = apply_filters( 'wpmem_login_form_before', '', $action ) . $form; return $form; -} // end wpmem_login_form +} // End wpmem_login_form. endif; @@ -490,10 +490,10 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = global $wpmem, $wpmem_regchk, $userdata; - // set up default wrappers + // Set up default wrappers. $defaults = array( - // wrappers + // Wrappers. 'heading_before' => '', 'heading_after' => '', 'fieldset_before' => '
    ', @@ -507,25 +507,25 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = 'buttons_before' => '
    ', 'buttons_after' => '
    ', - // classes & ids + // Classes & ids. 'form_id' => '', 'form_class' => 'form', 'button_id' => '', 'button_class' => 'buttons', - // required field tags and text - 'req_mark' => '*', - 'req_label' => __( 'Required field', 'wp-members' ), + // Required field tags and text. + 'req_mark' => '*', + 'req_label' => '*' . __( 'Required field', 'wp-members' ), 'req_label_before' => '
    ', 'req_label_after' => '
    ', - // buttons + // Buttons. 'show_clear_form' => false, 'clear_form' => __( 'Reset Form', 'wp-members' ), 'submit_register' => __( 'Register' ), 'submit_update' => __( 'Update Profile', 'wp-members' ), - // other + // Other. 'strip_breaks' => true, 'use_nonce' => false, 'wrap_inputs' => true, @@ -547,39 +547,39 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = */ $args = apply_filters( 'wpmem_register_form_args', '', $toggle ); - // merge $args with defaults - extract( wp_parse_args( $args, $defaults ) ); + // Merge $args with defaults. + $args = wp_parse_args( $args, $defaults ); - // Username is editable if new reg, otherwise user profile is not + // Username is editable if new reg, otherwise user profile is not. if ( $toggle == 'edit' ) { - // this is the User Profile edit - username is not editable + // This is the User Profile edit - username is not editable. $val = $userdata->user_login; $label = ''; $input = '

    ' . $val . '

    '; - $field_before = ( $wrap_inputs ) ? '
    ' : ''; - $field_after = ( $wrap_inputs ) ? '
    ' : ''; + $field_before = ( $args['wrap_inputs'] ) ? '
    ' : ''; + $field_after = ( $args['wrap_inputs'] ) ? '
    ' : ''; } else { - // this is a new registration + // This is a new registration. $val = ( isset( $_POST['log'] ) ) ? stripslashes( $_POST['log'] ) : ''; - $label = ''; + $label = ''; $input = wpmem_create_formfield( 'log', 'text', $val, '', 'username' ); } - $field_before = ( $wrap_inputs ) ? '
    ' : ''; - $field_after = ( $wrap_inputs ) ? '
    ': ''; + $field_before = ( $args['wrap_inputs'] ) ? '
    ' : ''; + $field_after = ( $args['wrap_inputs'] ) ? '
    ': ''; - // add the username row to the array + // Add the username row to the array. $rows['username'] = array( 'order' => 0, 'meta' => 'username', 'type' => 'text', 'value' => $val, - 'row_before' => $row_before, + 'row_before' => $args['row_before'], 'label' => $label, 'field_before' => $field_before, 'field' => $input, 'field_after' => $field_after, - 'row_after' => $row_after, + 'row_after' => $args['row_after'], ); /** @@ -595,40 +595,39 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = * @param array The array of form fields. * @param string $toggle Toggle new registration or profile update. new|edit. */ - // $wpmem_fields = apply_filters( 'wpmem_register_fields_arr', get_option( 'wpmembers_fields' ), $toggle ); $wpmem_fields = apply_filters( 'wpmem_register_fields_arr', $wpmem->fields, $toggle ); - // loop through the remaining fields + // Loop through the remaining fields. foreach ( $wpmem_fields as $field ) { - // start with a clean row + // Start with a clean row. $val = ''; $label = ''; $input = ''; $field_before = ''; $field_after = ''; - // skips user selected passwords for profile update + // Skips user selected passwords for profile update. $pass_arr = array( 'password', 'confirm_password', 'password_confirm' ); $do_row = ( $toggle == 'edit' && in_array( $field[2], $pass_arr ) ) ? false : true; - // skips tos, makes tos field hidden on user edit page, unless they haven't got a value for tos + // Skips tos, makes tos field hidden on user edit page, unless they haven't got a value for tos. if ( $field[2] == 'tos' && $toggle == 'edit' && ( get_user_meta( $userdata->ID, 'tos', true ) ) ) { $do_row = false; $hidden_tos = wpmem_create_formfield( $field[2], 'hidden', get_user_meta( $userdata->ID, 'tos', true ) ); } - // if the field is set to display and we aren't skipping, construct the row + // If the field is set to display and we aren't skipping, construct the row. if ( $field[4] == 'y' && $do_row == true ) { - // label for all but TOS + // Label for all but TOS. if ( $field[2] != 'tos' ) { $class = ( $field[3] == 'password' ) ? 'text' : $field[3]; $label = ''; } - // gets the field value for both edit profile and submitted reg w/ error + // Gets the field value for both edit profile and submitted reg w/ error. if ( ( $toggle == 'edit' ) && ( $wpmem_regchk != 'updaterr' ) ) { switch ( $field[2] ) { @@ -660,17 +659,17 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = } - // does the tos field + // Does the tos field. if ( $field[2] == 'tos' ) { $val = ( isset( $_POST[ $field[2] ] ) ) ? $_POST[ $field[2] ] : ''; - // should be checked by default? and only if form hasn't been submitted + // Should be checked by default? and only if form hasn't been submitted. $val = ( ! $_POST && $field[8] == 'y' ) ? $field[7] : $val; $input = wpmem_create_formfield( $field[2], $field[3], $field[7], $val ); - $input = ( $field[5] == 'y' ) ? $input . $req_mark : $input; + $input = ( $field[5] == 'y' ) ? $input . $args['req_mark'] : $input; - // determine if TOS is a WP page or not... + // Determine if TOS is a WP page or not. $tos_content = stripslashes( get_option( 'wpmembers_tos' ) ); if ( ( wpmem_test_shortcode( $tos_content, 'wp-members' ) ) ) { $link = do_shortcode( $tos_content ); @@ -689,13 +688,13 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = */ $input.= apply_filters( 'wpmem_tos_link_txt', sprintf( __( 'Please indicate that you agree to the %s TOS %s', 'wp-members' ), $tos_pop, '' ), $toggle ); - // in previous versions, the div class would end up being the same as the row before. - $field_before = ( $wrap_inputs ) ? '
    ' : ''; - $field_after = ( $wrap_inputs ) ? '
    ' : ''; + // In previous versions, the div class would end up being the same as the row before. + $field_before = ( $args['wrap_inputs'] ) ? '
    ' : ''; + $field_after = ( $args['wrap_inputs'] ) ? '
    ' : ''; } else { - // for checkboxes + // For checkboxes. if ( $field[3] == 'checkbox' ) { $valtochk = $val; $val = $field[7]; @@ -703,7 +702,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = if ( $field[8] == 'y' && ( ! $_POST && $toggle != 'edit' ) ) { $val = $valtochk = $field[7]; } } - // for dropdown select + // For dropdown select. if ( $field[3] == 'select' ) { $valtochk = $val; $val = $field[7]; @@ -711,34 +710,34 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = if ( ! isset( $valtochk ) ) { $valtochk = ''; } - // for all other input types + // For all other input types. $input = wpmem_create_formfield( $field[2], $field[3], $val, $valtochk ); - // determine input wrappers - $field_before = ( $wrap_inputs ) ? '
    ' : ''; - $field_after = ( $wrap_inputs ) ? '
    ' : ''; + // Determine input wrappers. + $field_before = ( $args['wrap_inputs'] ) ? '
    ' : ''; + $field_after = ( $args['wrap_inputs'] ) ? '
    ' : ''; } } - // if the row is set to display, add the row to the form array + // If the row is set to display, add the row to the form array. if ( $field[4] == 'y' ) { $rows[$field[2]] = array( 'order' => $field[0], 'meta' => $field[2], 'type' => $field[3], 'value' => $val, - 'row_before' => $row_before, + 'row_before' => $args['row_before'], 'label' => $label, 'field_before' => $field_before, 'field' => $input, 'field_after' => $field_after, - 'row_after' => $row_after, + 'row_after' => $args['row_after'], ); } } - // if captcha is Really Simple CAPTCHA + // If captcha is Really Simple CAPTCHA. if ( $wpmem->captcha == 2 && $toggle != 'edit' ) { $row = wpmem_build_rs_captcha(); $rows['captcha'] = array( @@ -746,12 +745,12 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = 'meta' => '', 'type' => 'text', 'value' => '', - 'row_before' => $row_before, + 'row_before' => $args['row_before'], 'label' => $row['label'], - 'field_before' => ( $wrap_inputs ) ? '
    ' : '', + 'field_before' => ( $args['wrap_inputs'] ) ? '
    ' : '', 'field' => $row['field'], - 'field_after' => ( $wrap_inputs ) ? '
    ' : '', - 'row_after' => $row_after, + 'field_after' => ( $args['wrap_inputs'] ) ? '
    ' : '', + 'row_after' => $args['row_after'], ); } @@ -769,28 +768,28 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = */ $rows = apply_filters( 'wpmem_register_form_rows', $rows, $toggle ); - // put the rows from the array into $form + // Put the rows from the array into $form. $form = ''; $enctype = ''; foreach ( $rows as $row_item ) { $enctype = ( $row_item['type'] == 'file' ) ? "multipart/form-data" : $enctype; - $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $n . $row_item['label'] . $n : $row_item['label'] . $n; - $row .= ( $row_item['field_before'] != '' ) ? $row_item['field_before'] . $n . $t . $row_item['field'] . $n . $row_item['field_after'] . $n : $row_item['field'] . $n; - $row .= ( $row_item['row_after'] != '' ) ? $row_item['row_after'] . $n : ''; + $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $args['n'] . $row_item['label'] . $args['n'] : $row_item['label'] . $args['n']; + $row .= ( $row_item['field_before'] != '' ) ? $row_item['field_before'] . $args['n'] . $args['t'] . $row_item['field'] . $args['n'] . $row_item['field_after'] . $args['n'] : $row_item['field'] . $args['n']; + $row .= ( $row_item['row_after'] != '' ) ? $row_item['row_after'] . $args['n'] : ''; $form.= $row; } - // do recaptcha if enabled + // Do recaptcha if enabled. if ( ( $wpmem->captcha == 1 || $wpmem->captcha == 3 ) && $toggle != 'edit' ) { // don't show on edit page! - // get the captcha options + // Get the captcha options. $wpmem_captcha = get_option( 'wpmembers_captcha' ); - // start with a clean row + // Start with a clean row. $row = ''; $row = '
    '; $row.= '
    ' . wpmem_inc_recaptcha( $wpmem_captcha['recaptcha'] ) . '
    '; - // add the captcha row to the form + // Add the captcha row to the form. /** * Filter the HTML for the CAPTCHA row. * @@ -799,18 +798,18 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = * @param string The HTML for the entire row (includes HTML tags plus reCAPTCHA). * @param string $toggle Toggle new registration or profile update. new|edit. */ - $form.= apply_filters( 'wpmem_register_captcha_row', $row_before . $row . $row_after, $toggle ); + $form.= apply_filters( 'wpmem_register_captcha_row', $args['row_before'] . $row . $args['row_after'], $toggle ); } - // create hidden fields + // Create hidden fields. $var = ( $toggle == 'edit' ) ? 'update' : 'register'; $redirect_to = ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : ( ( $redirect_to ) ? $redirect_to : get_permalink() ); - $hidden = '' . $n; - $hidden .= '' . $n; + $hidden = '' . $args['n']; + $hidden .= '' . $args['n']; if ( $redirect_to != get_permalink() ) { - $hidden.= '' . $n; + $hidden.= '' . $args['n']; } - $hidden = ( isset( $hidden_tos ) ) ? $hidden . $hidden_tos . $n : $hidden; + $hidden = ( isset( $hidden_tos ) ) ? $hidden . $hidden_tos . $args['n'] : $hidden; /** * Filter the hidden field HTML. @@ -822,13 +821,13 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = */ $hidden = apply_filters( 'wpmem_register_hidden_fields', $hidden, $toggle ); - // add the hidden fields to the form + // Add the hidden fields to the form. $form.= $hidden; - // create buttons and wrapper - $button_text = ( $toggle == 'edit' ) ? $submit_update : $submit_register; - $buttons = ( $show_clear_form ) ? ' ' . $n : ''; - $buttons.= '' . $n; + // Create buttons and wrapper. + $button_text = ( $toggle == 'edit' ) ? $args['submit_update'] : $args['submit_register']; + $buttons = ( $args['show_clear_form'] ) ? ' ' . $args['n'] : ''; + $buttons.= '' . $args['n']; /** * Filter the HTML for form buttons. @@ -842,13 +841,13 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = */ $buttons = apply_filters( 'wpmem_register_form_buttons', $buttons, $toggle ); - // add the buttons to the form - $form.= $buttons_before . $n . $buttons . $buttons_after . $n; + // Add the buttons to the form. + $form.= $args['buttons_before'] . $args['n'] . $buttons . $args['buttons_after'] . $args['n']; - // add the required field notation to the bottom of the form - $form.= $req_label_before . $req_mark . $req_label . $req_label_after; + // Add the required field notation to the bottom of the form. + $form.= $args['req_label_before'] . $args['req_label'] . $args['req_label_after']; - // apply the heading + // Apply the heading. /** * Filter the registration form heading. * @@ -858,33 +857,33 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = * @param string $toggle Toggle new registration or profile update. new|edit. */ $heading = ( !$heading ) ? apply_filters( 'wpmem_register_heading', __( 'New User Registration', 'wp-members' ), $toggle ) : $heading; - $form = $heading_before . $heading . $heading_after . $n . $form; + $form = $args['heading_before'] . $heading . $args['heading_after'] . $args['n'] . $form; - // apply fieldset wrapper - $form = $fieldset_before . $n . $form . $n . $fieldset_after; + // Apply fieldset wrapper. + $form = $args['fieldset_before'] . $args['n'] . $form . $args['n'] . $args['fieldset_after']; - // apply attribution if enabled + // Apply attribution if enabled. $form = $form . wpmem_inc_attribution(); - // apply nonce - $form = ( defined( 'WPMEM_USE_NONCE' ) || $use_nonce ) ? wp_nonce_field( 'wpmem-validate-submit', 'wpmem-form-submit' ) . $n . $form : $form; + // Apply nonce. + $form = ( defined( 'WPMEM_USE_NONCE' ) || $args['use_nonce'] ) ? wp_nonce_field( 'wpmem-validate-submit', 'wpmem-form-submit' ) . $args['n'] . $form : $form; - // apply form wrapper + // Apply form wrapper. $enctype = ( $enctype == 'multipart/form-data' ) ? ' enctype="multipart/form-data"' : ''; $post_to = ( $redirect_to ) ? $redirect_to : get_permalink(); - $form = '
    ' . $n . $form. $n . '
    '; + $form = '
    ' . $args['n'] . $form . $args['n'] . '
    '; - // apply anchor - $form = '' . $n . $form; + // Apply anchor. + $form = '' . $args['n'] . $form; - // apply main div wrapper - $form = $main_div_before . $n . $form . $n . $main_div_after . $n; + // Apply main div wrapper. + $form = $args['main_div_before'] . $args['n'] . $form . $args['n'] . $args['main_div_after'] . $args['n']; - // apply wpmem_txt wrapper - $form = $txt_before . $form . $txt_after; + // Apply wpmem_txt wrapper. + $form = $args['txt_before'] . $form . $args['txt_after']; - // remove line breaks if enabled for easier filtering later - $form = ( $strip_breaks ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; + // Remove line breaks if enabled for easier filtering later. + $form = ( $args['strip_breaks'] ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; /** * Filter the generated HTML of the entire form. @@ -911,9 +910,9 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = */ $form = apply_filters( 'wpmem_register_form_before', '', $toggle ) . $form; - // return the generated form + // Return the generated form. return $form; -} // end wpmem_inc_registration +} // End wpmem_inc_registration. endif; @@ -928,14 +927,14 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = */ function wpmem_inc_recaptcha( $arr ) { - // determine if reCAPTCHA should be another language + // Determine if reCAPTCHA should be another language. $allowed_langs = array( 'nl', 'fr', 'de', 'pt', 'ru', 'es', 'tr' ); $locale = apply_filters( 'plugin_locale', get_locale(), 'wp-members' ); $compare_lang = strtolower( substr( $locale, -2 ) ); $use_the_lang = ( in_array( $compare_lang, $allowed_langs ) ) ? $compare_lang : false; $lang = ( $use_the_lang ) ? ' lang : \'' . $use_the_lang . '\'' : ''; - // determine if we need ssl + // Determine if we need ssl. $http = wpmem_use_ssl(); global $wpmem; @@ -1060,4 +1059,4 @@ function wpmem_build_rs_captcha() { } } -/** End of File **/ \ No newline at end of file +// End of file. \ No newline at end of file From 22fc6ff29747b7ae2735022279c3b0dc38b6f518 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 1 Dec 2015 16:35:27 -0600 Subject: [PATCH 0182/1694] added forgotten username retrieval --- admin/tab-emails.php | 5 ++ inc/class-wp-members.php | 4 ++ inc/core.php | 41 ++++++++++++++++ inc/dialogs.php | 100 +++++++++++++++++++++++++++++++++++++++ inc/email.php | 6 +++ inc/shortcodes.php | 4 ++ 6 files changed, 160 insertions(+) diff --git a/admin/tab-emails.php b/admin/tab-emails.php index 4a3d024b..b8417797 100644 --- a/admin/tab-emails.php +++ b/admin/tab-emails.php @@ -43,6 +43,10 @@ function wpmem_a_build_emails() { $wpmem_email_title_arr, array( __( "Password Reset", 'wp-members' ), 'wpmembers_email_repass' ) ); + array_push( + $wpmem_email_title_arr, + array( __( "Retrieve Username", 'wp-members' ), 'wpmembers_email_getuser' ) + ); if ( $wpmem->notify == 1 ) { array_push( $wpmem_email_title_arr, @@ -147,6 +151,7 @@ function wpmem_update_emails() { // Update the various emails being used. ( $wpmem->mod_reg == 0 ) ? $arr = array( 'wpmembers_email_newreg' ) : $arr = array( 'wpmembers_email_newmod', 'wpmembers_email_appmod' ); array_push( $arr, 'wpmembers_email_repass' ); + array_push( $arr, 'wpmembers_email_getuser' ); ( $wpmem->notify == 1 ) ? array_push( $arr, 'wpmembers_email_notify' ) : false; array_push( $arr, 'wpmembers_email_footer' ); diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 776c2a56..295becdd 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -221,6 +221,10 @@ function get_regchk( $action ) { $regchk = wpmem_reset_password(); break; + case 'getusername': + $regchk = wpmem_retrieve_username(); + break; + case 'register': case 'update': require_once( WPMEM_PATH . 'inc/register.php' ); diff --git a/inc/core.php b/inc/core.php index ba181253..845febf6 100644 --- a/inc/core.php +++ b/inc/core.php @@ -623,4 +623,45 @@ function wpmem_redirect_to_login() { } +/** + * Handles retrieving a forgotten username. + * + * @since 3.0.8 + * + * @return string $regchk The regchk value. + */ +function wpmem_retrieve_username() { + + if ( isset( $_POST['formsubmit'] ) ) { + + $user = ( isset( $_POST['user_email'] ) ) ? get_user_by( 'email', $_POST['user_email'] ) : false; + + if ( $user ) { + + /** + * Load the email functions. + */ + require_once( WPMEM_PATH . 'inc/email.php' ); + + // Send it in an email. + wpmem_inc_regemail( $user->ID, '', 4 ); + + /** + * Fires after retrieving username. + * + * @since 3.0.8 + * + * @param int $user_ID The user's numeric ID. + */ + do_action( 'wpmem_get_username', $user->ID ); + + return 'usernamesuccess'; + + } else { + return 'usernamefailed'; + } + } + return; +} + // End of file. \ No newline at end of file diff --git a/inc/dialogs.php b/inc/dialogs.php index 85c07f00..66689825 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -390,4 +390,104 @@ function wpmem_page_user_edit( $wpmem_regchk, $content ) { } endif; + +/** + * Forgot username form. + * + * This function creates a form for retrieving a forgotten username. + * + * @since 3.0.8 + * + * @param string $wpmem_regchk + * @param string $content + * @return string $content + */ +function wpmem_page_forgot_username( $wpmem_regchk, $content ) { + + if ( ! is_user_logged_in() ) { + + global $wpmem; + switch( $wpmem->regchk ) { + + case "usernamefailed": + $msg = __( 'Sorry, that email address was not found.', 'wp-members' ); + $content = $content + . wpmem_inc_regmessage( 'usernamefailed', $msg ) + . wpmem_inc_forgotusername(); + $wpmem->regchk = ''; // Clear regchk. + break; + + case "usernamesuccess": + $email = ( isset( $_POST['user_email'] ) ) ? $_POST['user_email'] : ''; + $msg = sprintf( __( 'An email was sent to %s with your username.', 'wp-members' ), $email ); + $content = $content . wpmem_inc_regmessage( 'usernamesuccess', $msg ); + $wpmem->regchk = ''; // Clear regchk. + break; + + default: + $content = $content . wpmem_inc_forgotusername(); + break; + } + + } + + return $content; + +} + + +/** + * Forgot Username Form. + * + * Loads the form for retrieving a username. + * + * @since 3.0.8 + * + * @return string $str The generated html for the forgot username form. + */ +function wpmem_inc_forgotusername() { + + // create the default inputs + $default_inputs = array( + array( + 'name' => __( 'Email Address', 'wp-members' ), + 'type' => 'text', + 'tag' => 'user_email', + 'class' => 'username', + 'div' => 'div_text', + ), + ); + + /** + * Filter the array of forgot username form fields. + * + * @since 2.9.0 + * + * @param array $default_inputs An array matching the elements used by default. + */ + $default_inputs = apply_filters( 'wpmem_inc_forgotusername_inputs', $default_inputs ); + + $defaults = array( + 'heading' => __( 'Retrieve username', 'wp-members' ), + 'action' => 'getusername', + 'button_text' => __( 'Retrieve username', 'wp-members' ), + 'inputs' => $default_inputs, + ); + + /** + * Filter the arguments to override change password form defaults. + * + * @since + * + * @param array $args An array of arguments to use. Default null. + */ + $args = apply_filters( 'wpmem_inc_forgotusername_args', '' ); + + $arr = wp_parse_args( $args, $defaults ); + + $str = wpmem_login_form( 'page', $arr ); + + return $str; +} + // End of file. \ No newline at end of file diff --git a/inc/email.php b/inc/email.php index 1f58c798..f38c02cc 100644 --- a/inc/email.php +++ b/inc/email.php @@ -70,6 +70,12 @@ function wpmem_inc_regemail( $user_id, $password, $toggle, $wpmem_fields = null, $arr = get_option( 'wpmembers_email_repass' ); $arr['toggle'] = 'repass'; break; + + case 4: + // This is a password reset. + $arr = get_option( 'wpmembers_email_getuser' ); + $arr['toggle'] = 'getuser'; + break; } diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 9940bdd5..7a1b1969 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -439,6 +439,10 @@ function wpmem_do_sc_pages( $page, $redirect_to = null ) { $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + } elseif( $wpmem->action == 'getusername' ) { + + $content = wpmem_page_forgot_username( $wpmem->regchk, $content ); + } else { $content = ( $page == 'members-area' ) ? $content . wpmem_inc_login( 'members' ) : $content; From 99840ba3b83c086eddcad340dc7701b41d9717ea Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 1 Dec 2015 16:53:43 -0600 Subject: [PATCH 0183/1694] changed htmlspecialchars on text fields to sanitize_text_field --- inc/forms.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/inc/forms.php b/inc/forms.php index f0f727a5..1946237d 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -637,7 +637,7 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = case 'user_email': case 'confirm_email': - $val = $userdata->user_email; + $val = sanitize_email( $userdata->user_email ); break; case 'user_url': @@ -645,11 +645,11 @@ function wpmem_inc_registration( $toggle = 'new', $heading = '', $redirect_to = break; case 'display_name': - $val = htmlspecialchars( $userdata->display_name ); + $val = sanitize_text_field( $userdata->display_name ); break; default: - $val = htmlspecialchars( get_user_meta( $userdata->ID, $field[2], 'true' ) ); + $val = sanitize_text_field( get_user_meta( $userdata->ID, $field[2], 'true' ) ); break; } From e0f73392c442876d49e8462d4858ffdf8933546e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 1 Dec 2015 17:01:24 -0600 Subject: [PATCH 0184/1694] added retrieve username email to install and uninstall --- uninstall.php | 17 +++++++++-------- wp-members-install.php | 20 +++++++++++++++++++- 2 files changed, 28 insertions(+), 9 deletions(-) diff --git a/uninstall.php b/uninstall.php index 537f81b3..e5fbd22c 100644 --- a/uninstall.php +++ b/uninstall.php @@ -56,14 +56,15 @@ function wpmem_uninstall_options() { delete_option( 'wpmembers_export' ); delete_option( 'wpmembers_utfields' ); - delete_option( 'wpmembers_email_newreg' ); - delete_option( 'wpmembers_email_newmod' ); - delete_option( 'wpmembers_email_appmod' ); - delete_option( 'wpmembers_email_repass' ); - delete_option( 'wpmembers_email_footer' ); - delete_option( 'wpmembers_email_notify' ); - delete_option( 'wpmembers_email_wpfrom' ); - delete_option( 'wpmembers_email_wpname' ); + delete_option( 'wpmembers_email_newreg' ); + delete_option( 'wpmembers_email_newmod' ); + delete_option( 'wpmembers_email_appmod' ); + delete_option( 'wpmembers_email_repass' ); + delete_option( 'wpmembers_email_footer' ); + delete_option( 'wpmembers_email_notify' ); + delete_option( 'wpmembers_email_wpfrom' ); + delete_option( 'wpmembers_email_wpname' ); + delete_option( 'wpmembers_email_getuser' ); delete_option( 'widget_wpmemwidget' ); diff --git a/wp-members-install.php b/wp-members-install.php index e50e4841..1c14901c 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -84,7 +84,7 @@ function wpmem_do_install() { // Using update_option to allow for forced update. update_option( 'wpmembers_settings', $wpmem_settings, '', 'yes' ); - + /* * Field array elements: * @@ -366,6 +366,24 @@ function wpmem_append_email() { if ( ! get_option( 'wpmembers_email_footer' ) ) { update_option( 'wpmembers_email_footer', $body, false ); } + + $arr = $subj = $body = ''; + + // Email for retrieve username. + $subj = 'Username for [blogname]'; + $body = 'Your username for [blogname] is below. + +username: [username] +'; + + $arr = array( + "subj" => $subj, + "body" => $body, + ); + + if ( ! get_option( 'wpmembers_email_getuser' ) ) { + update_option( 'wpmembers_email_getuser', $arr, false ); + } return true; } From acde46a7f4742ed3a68696100b947cfc91e0feca Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 4 Dec 2015 11:12:12 -0600 Subject: [PATCH 0185/1694] removed use of extract --- inc/sidebar.php | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/inc/sidebar.php b/inc/sidebar.php index fa426207..104002c9 100644 --- a/inc/sidebar.php +++ b/inc/sidebar.php @@ -130,27 +130,27 @@ function wpmem_do_sidebar( $post_to = null ) { $args = apply_filters( 'wpmem_sb_login_args', '' ); // Merge $args with defaults. - extract( wp_parse_args( $args, $defaults ) ); + $args = wp_parse_args( $args, $defaults ); $form = ''; $label = ''; $input = ''; - $input = ( $wrap_inputs ) ? $inputs_before . $input . $inputs_after : $input; - $row1 = $label . $n . $input . $n; + $input = ( $args['wrap_inputs'] ) ? $args['inputs_before'] . $input . $args['inputs_after'] : $input; + $row1 = $label . $args['n'] . $input . $args['n']; $label = ''; $input = ''; - $input = ( $wrap_inputs ) ? $inputs_before . $input . $inputs_after : $input; - $row2 = $label . $n . $input . $n; + $input = ( $args['wrap_inputs'] ) ? $args['inputs_before'] . $input . $args['inputs_after'] : $input; + $row2 = $label . $args['n'] . $input . $args['n']; $form = $row1 . $row2; - $hidden = '' . $n . - '' . $n . - '' . $n . + $hidden = '' . $args['n'] . + '' . $args['n'] . + '' . $args['n'] . ''; /** * Filter sidebar login form hidden fields. @@ -188,17 +188,17 @@ function wpmem_do_sidebar( $post_to = null ) { $buttons.= ' ' . __( 'Register' ) . ''; } - $form = $form . $n . $buttons_before . $buttons . $n . $buttons_after; + $form = $form . $args['n'] . $args['buttons_before'] . $buttons . $args['n'] . $args['buttons_after']; - $form = $fieldset_before . $n . $form . $n . $fieldset_after; + $form = $args['fieldset_before'] . $args['n'] . $form . $args['n'] . $args['fieldset_after']; - $form = '
    ' . $n . $form . $n . '
    '; + $form = '
    ' . $args['n'] . $form . $args['n'] . '
    '; // Add status message. - $form = $status_msg . $n . $form; + $form = $args['status_msg'] . $args['n'] . $form; // Strip breaks. - $form = ( $strip_breaks ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; + $form = ( $args['strip_breaks'] ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; /** * Filter the sidebar form. @@ -212,7 +212,7 @@ function wpmem_do_sidebar( $post_to = null ) { $do_error_msg = ''; if ( isset( $_POST['slog'] ) && $wpmem_regchk == 'loginfailed' ) { $do_error_msg = true; - $error_msg = $error_before . $error_msg . $error_after; + $error_msg = $args['error_before'] . $args['error_msg'] . $args['error_after']; /** * Filter the sidebar login failed message. * From a4376bb3c3a8cdf4b08d1959ddc52ff7848752fb Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 4 Dec 2015 11:12:48 -0600 Subject: [PATCH 0186/1694] removed use of extract --- admin/user-export.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/admin/user-export.php b/admin/user-export.php index bc3d8006..7de2f8f3 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -38,7 +38,7 @@ function wpmem_export_users( $args, $users = null ) { 'exclude_fields' => array( 'password', 'confirm_password', 'confirm_email' ), ); - // Merge $args with defaults and extract. + // Merge $args with defaults. /** * Filter the default export arguments. * @@ -46,18 +46,18 @@ function wpmem_export_users( $args, $users = null ) { * * @param array $args An array of arguments to merge with defaults. Default null. */ - extract( wp_parse_args( apply_filters( 'wpmem_export_args', $args ), $defaults ) ); + $args = wp_parse_args( apply_filters( 'wpmem_export_args', $args ), $defaults ); // Output needs to be buffered, start the buffer. ob_start(); // If exporting all, get all of the users. - $users = ( $export == 'all' ) ? get_users( array( 'fields' => 'ID' ) ) : $users; + $users = ( 'all' == $args'[export'] ) ? get_users( array( 'fields' => 'ID' ) ) : $users; // Generate headers and a filename based on date of export. header( "Content-Description: File Transfer" ); header( "Content-type: application/octet-stream" ); - header( "Content-Disposition: attachment; filename=" . $filename ); + header( "Content-Disposition: attachment; filename=" . $args['filename'] ); header( "Content-Type: text/csv; charset=" . get_option( 'blog_charset' ), true ); echo "\xEF\xBB\xBF"; // UTF-8 BOM @@ -68,7 +68,7 @@ function wpmem_export_users( $args, $users = null ) { $hrow = "User ID,Username,"; foreach ( $wpmem_fields as $meta ) { - if ( ! in_array( $meta[2], $exclude_fields ) ) { + if ( ! in_array( $meta[2], $args['exclude_fields'] ) ) { $hrow.= $meta[1] . ","; } } @@ -99,7 +99,7 @@ function wpmem_export_users( $args, $users = null ) { $wp_user_fields = array( 'user_email', 'user_nicename', 'user_url', 'display_name' ); foreach ( $wpmem_fields as $meta ) { - if ( ! in_array( $meta[2], $exclude_fields ) ) { + if ( ! in_array( $meta[2], $args['exclude_fields'] ) ) { // @todo Research using fputcsv to escape fields for export. if ( in_array( $meta[2], $wp_user_fields ) ){ $data .= '"' . $user_info->$meta[2] . '",'; @@ -118,7 +118,7 @@ function wpmem_export_users( $args, $users = null ) { $data .= "\r\n"; // Update the user record as being exported. - if ( $export != 'all' ){ + if ( 'all' != $args['export'] ){ update_user_meta( $user, 'exported', 1 ); } } From 10e61c6dab82531ca4f8963c99095bf329a0d26f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 4 Dec 2015 11:15:17 -0600 Subject: [PATCH 0187/1694] removed use of extract, added logical test for no saved settings --- admin/tab-captcha.php | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/admin/tab-captcha.php b/admin/tab-captcha.php index c5e75b17..86de40cd 100644 --- a/admin/tab-captcha.php +++ b/admin/tab-captcha.php @@ -120,27 +120,27 @@ function wpmem_a_build_captcha_options() { 'img_type' => 'png', ); - $args = ( is_array( $wpmem_captcha['really_simple'] ) ) ? $wpmem_captcha['really_simple'] : array(); + $args = ( isset( $wpmem_captcha['really_simple'] ) && is_array( $wpmem_captcha['really_simple'] ) ) ? $wpmem_captcha['really_simple'] : array(); - extract( wp_parse_args( $args, $defaults ) ); + $args = wp_parse_args( $args, $defaults ); // Explode colors. - $font_color = explode( ',', $font_color ); - $bg_color = explode( ',', $bg_color ); + $font_color = explode( ',', $args['font_color'] ); + $bg_color = explode( ',', $args['bg_color'] ); $show_update_button = true; if ( is_plugin_active( 'really-simple-captcha/really-simple-captcha.php' ) ) { ?> - + - + - + @@ -152,18 +152,18 @@ function wpmem_a_build_captcha_options() { - + - + Date: Fri, 4 Dec 2015 11:17:45 -0600 Subject: [PATCH 0188/1694] removed use of extract (login and recaptcha) --- inc/forms.php | 123 ++++++++++++++++++++++++++++---------------------- 1 file changed, 70 insertions(+), 53 deletions(-) diff --git a/inc/forms.php b/inc/forms.php index 1946237d..375bf62d 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -258,16 +258,32 @@ function wpmem_inc_resetpassword() { * @since 2.5.1 * * @param string $page - * @param array $arr The elements needed to generate the form (login|reset password|forgotten password). + * @param array $arr { + * The elements needed to generate the form (login|reset password|forgotten password). + * + * @type string $heading Form heading text. + * @type string $action The form action (login|pwdchange|pwdreset). + * @type string $button_text Form submit button text. + * @type array $inputs { + * The form input values. + * + * @type array { + * + * @type string $name The field label. + * @type string $type Input type. + * @type string $tag Input tag name. + * @type string $class Input tag class. + * @type string $div Div wrapper class. + * } + * } + * @type string $redirect_to Optional. URL to redirect to. + * } * @return string $form The HTML for the form as a string. */ function wpmem_login_form( $page, $arr ) { global $wpmem; - // extract the arguments array - extract( $arr ); - // set up default wrappers $defaults = array( @@ -299,7 +315,7 @@ function wpmem_login_form( $page, $arr ) { 'remember_check' => true, 'n' => "\n", 't' => "\t", - 'redirect_to' => ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : ( ( isset( $redirect_to ) ) ? $redirect_to : get_permalink() ), + 'redirect_to' => ( isset( $_REQUEST['redirect_to'] ) ) ? esc_url( $_REQUEST['redirect_to'] ) : ( ( isset( $arr['redirect_to'] ) ) ? $arr['redirect_to'] : get_permalink() ), ); @@ -312,26 +328,26 @@ function wpmem_login_form( $page, $arr ) { * @since 2.9.0 * * @param array An array of arguments to merge with defaults. Default null. - * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange. */ - $args = apply_filters( 'wpmem_login_form_args', '', $action ); + $args = apply_filters( 'wpmem_login_form_args', '', $arr['action'] ); // Merge $args with defaults. - extract( wp_parse_args( $args, $defaults ) ); + $args = wp_parse_args( $args, $defaults ); // Build the input rows. - foreach ( $inputs as $input ) { + foreach ( $arr['inputs'] as $input ) { $label = ''; $field = wpmem_create_formfield( $input['tag'], $input['type'], '', '', $input['class'] ); - $field_before = ( $wrap_inputs ) ? '
    ' : ''; - $field_after = ( $wrap_inputs ) ? '
    ' : ''; + $field_before = ( $args['wrap_inputs'] ) ? '
    ' : ''; + $field_after = ( $args['wrap_inputs'] ) ? '
    ' : ''; $rows[] = array( - 'row_before' => $row_before, + 'row_before' => $args['row_before'], 'label' => $label, 'field_before' => $field_before, 'field' => $field, 'field_after' => $field_after, - 'row_after' => $row_after, + 'row_after' => $args['row_after'], ); } @@ -345,23 +361,23 @@ function wpmem_login_form( $page, $arr ) { * @since 2.9.0 * * @param array $rows An array containing the form rows. - * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange. */ - $rows = apply_filters( 'wpmem_login_form_rows', $rows, $action ); + $rows = apply_filters( 'wpmem_login_form_rows', $rows, $arr['action'] ); // Put the rows from the array into $form. $form = ''; foreach ( $rows as $row_item ) { - $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $n . $row_item['label'] . $n : $row_item['label'] . $n; - $row .= ( $row_item['field_before'] != '' ) ? $row_item['field_before'] . $n . $t . $row_item['field'] . $n . $row_item['field_after'] . $n : $row_item['field'] . $n; - $row .= ( $row_item['row_before'] != '' ) ? $row_item['row_after'] . $n : ''; + $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $args['n'] . $row_item['label'] . $args['n'] : $row_item['label'] . $args['n']; + $row .= ( $row_item['field_before'] != '' ) ? $row_item['field_before'] . $args['n'] . $args['t'] . $row_item['field'] . $args['n'] . $row_item['field_after'] . $args['n'] : $row_item['field'] . $args['n']; + $row .= ( $row_item['row_before'] != '' ) ? $row_item['row_after'] . $args['n'] : ''; $form.= $row; } // Build hidden fields, filter, and add to the form. - $hidden = wpmem_create_formfield( 'redirect_to', 'hidden', $redirect_to ) . $n; - $hidden = $hidden . wpmem_create_formfield( 'a', 'hidden', $action ) . $n; - $hidden = ( $action != 'login' ) ? $hidden . wpmem_create_formfield( 'formsubmit', 'hidden', '1' ) : $hidden; + $hidden = wpmem_create_formfield( 'redirect_to', 'hidden', $args['redirect_to'] ) . $args['n']; + $hidden = $hidden . wpmem_create_formfield( 'a', 'hidden', $arr['action'] ) . $args['n']; + $hidden = ( $arr['action'] != 'login' ) ? $hidden . wpmem_create_formfield( 'formsubmit', 'hidden', '1' ) : $hidden; /** * Filter the hidden field HTML. @@ -369,16 +385,16 @@ function wpmem_login_form( $page, $arr ) { * @since 2.9.0 * * @param string $hidden The generated HTML of hidden fields. - * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange. */ - $form = $form . apply_filters( 'wpmem_login_hidden_fields', $hidden, $action ); + $form = $form . apply_filters( 'wpmem_login_hidden_fields', $hidden, $arr['action'] ); // Build the buttons, filter, and add to the form. - if ( $action == 'login' ) { - $remember_check = ( $remember_check ) ? $t . wpmem_create_formfield( 'rememberme', 'checkbox', 'forever' ) . ' ' . __( 'Remember Me' ) . '  ' . $n : ''; - $buttons = $remember_check . $t . '' . $n; + if ( $arr['action'] == 'login' ) { + $args['remember_check'] = ( $args['remember_check'] ) ? $args['t'] . wpmem_create_formfield( 'rememberme', 'checkbox', 'forever' ) . ' ' . __( 'Remember Me' ) . '  ' . $args['n'] : ''; + $buttons = $args['remember_check'] . $args['t'] . '' . $args['n']; } else { - $buttons = '' . $n; + $buttons = '' . $args['n']; } /** @@ -389,11 +405,11 @@ function wpmem_login_form( $page, $arr ) { * @since 2.9.0 * * @param string $buttons The generated HTML of the form buttons. - * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange. */ - $form = $form . apply_filters( 'wpmem_login_form_buttons', $buttons_before . $n . $buttons . $buttons_after . $n, $action ); + $form = $form . apply_filters( 'wpmem_login_form_buttons', $args['buttons_before'] . $args['n'] . $buttons . $args['buttons_after'] . $args['n'], $arr['action'] ); - if ( ( $wpmem->user_pages['profile'] != null || $page == 'members' ) && $action == 'login' ) { + if ( ( $wpmem->user_pages['profile'] != null || $page == 'members' ) && $arr['action'] == 'login' ) { /** * Filter the forgot password link. @@ -404,11 +420,11 @@ function wpmem_login_form( $page, $arr ) { */ $link = apply_filters( 'wpmem_forgot_link', wpmem_chk_qstr( $wpmem->user_pages['profile'] ) . 'a=pwdreset' ); $str = __( 'Forgot password?', 'wp-members' ) . ' ' . __( 'Click here to reset', 'wp-members' ) . ''; - $form = $form . $link_before . apply_filters( 'wpmem_forgot_link_str', $str ) . $link_after . $n; + $form = $form . $args['link_before'] . apply_filters( 'wpmem_forgot_link_str', $str ) . $args['link_after'] . $args['n']; } - if ( ( $wpmem->user_pages['register'] != null ) && $action == 'login' ) { + if ( ( $wpmem->user_pages['register'] != null ) && $arr['action'] == 'login' ) { /** * Filter the link to the registration page. @@ -419,30 +435,30 @@ function wpmem_login_form( $page, $arr ) { */ $link = apply_filters( 'wpmem_reg_link', $wpmem->user_pages['register'] ); $str = __( 'New User?', 'wp-members' ) . ' ' . __( 'Click here to register', 'wp-members' ) . ''; - $form = $form . $link_before . apply_filters( 'wpmem_reg_link_str', $str ) . $link_after . $n; + $form = $form . $args['link_before'] . apply_filters( 'wpmem_reg_link_str', $str ) . $args['link_after'] . $args['n']; } // Apply the heading. - $form = $heading_before . $heading . $heading_after . $n . $form; + $form = $args['heading_before'] . $arr['heading'] . $args['heading_after'] . $args['n'] . $form; // Apply fieldset wrapper. - $form = $fieldset_before . $n . $form . $fieldset_after . $n; + $form = $args['fieldset_before'] . $args['n'] . $form . $args['fieldset_after'] . $args['n']; // Apply form wrapper. - $form = '
    ' . $n . $form . '
    '; + $form = '
    ' . $args['n'] . $form . '
    '; // Apply anchor. - $form = '' . $n . $form; + $form = '' . $args['n'] . $form; // Apply main wrapper. - $form = $main_div_before . $n . $form . $n . $main_div_after; + $form = $args['main_div_before'] . $args['n'] . $form . $args['n'] . $args['main_div_after']; // Apply wpmem_txt wrapper. - $form = $txt_before . $form . $txt_after; + $form = $args['txt_before'] . $form . $args['txt_after']; // Remove line breaks. - $form = ( $strip_breaks ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; + $form = ( $args['strip_breaks'] ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; /** * Filter the generated HTML of the entire form. @@ -450,9 +466,9 @@ function wpmem_login_form( $page, $arr ) { * @since 2.7.4 * * @param string $form The HTML of the final generated form. - * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange. */ - $form = apply_filters( 'wpmem_login_form', $form, $action ); + $form = apply_filters( 'wpmem_login_form', $form, $arr['action'] ); /** * Filter before the form. @@ -463,9 +479,9 @@ function wpmem_login_form( $page, $arr ) { * @since 2.7.4 * * @param string $str The HTML to add before the form. Default null. - * @param string $action The action being performed by the form. login|pwdreset|pwdchange. + * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange. */ - $form = apply_filters( 'wpmem_login_form_before', '', $action ) . $form; + $form = apply_filters( 'wpmem_login_form_before', '', $arr['action'] ) . $form; return $form; } // End wpmem_login_form. @@ -1013,21 +1029,22 @@ function wpmem_build_rs_captcha() { ); $wpmem_captcha = get_option( 'wpmembers_captcha' ); - extract( wp_parse_args( $wpmem_captcha['really_simple'], $defaults ) ); + $args = ( isset( $wpmem_captcha['really_simple'] ) && is_array( $wpmem_captcha['really_simple'] ) ) ? $wpmem_captcha['really_simple'] : array(); + $args = wp_parse_args( $args, $defaults ); - $img_size = array( $dim_w, $dim_h ); - $fg = explode( ",", $font_color ); - $bg = explode( ",", $bg_color ); + $img_size = array( $args['dim_w'], $args['dim_h'] ); + $fg = explode( ",", $args['font_color'] ); + $bg = explode( ",", $args['bg_color'] ); $wpmem_captcha = new ReallySimpleCaptcha(); - $wpmem_captcha->chars = $characters; - $wpmem_captcha->char_length = $num_char; + $wpmem_captcha->chars = $args['characters']; + $wpmem_captcha->char_length = $args['num_char']; $wpmem_captcha->img_size = $img_size; $wpmem_captcha->fg = $fg; $wpmem_captcha->bg = $bg; - $wpmem_captcha->font_size = $font_size; - $wpmem_captcha->font_char_width = $kerning; - $wpmem_captcha->img_type = $img_type; + $wpmem_captcha->font_size = $args['font_size']; + $wpmem_captcha->font_char_width = $args['kerning']; + $wpmem_captcha->img_type = $args['img_type']; $wpmem_captcha_word = $wpmem_captcha->generate_random_word(); $wpmem_captcha_prefix = mt_rand(); From 94dca6231319d5b9164d7eb2170a66b91fafcbdc Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 4 Dec 2015 11:19:59 -0600 Subject: [PATCH 0189/1694] added 3.0.8 version --- readme.txt | 20 +++++++++----------- wp-members.php | 4 ++-- 2 files changed, 11 insertions(+), 13 deletions(-) diff --git a/readme.txt b/readme.txt index 2d1005f3..f77c5c3e 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 Tested up to: 4.3.1 -Stable tag: 3.0.7.2 +Stable tag: 3.0.8 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -111,7 +111,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.0.7.2 is a minor bug fix release for 3.0.7. +WP-Members 3.0.8 is a feature release, see release notes. WP-Members 3.0.0 is a major version release. Please review the changelog: http://rkt.bz/v30 == Screenshots == @@ -135,16 +135,10 @@ WP-Members 3.0.0 is a major version release. Please review the changelog: http:/ == Changelog == -= 3.0.7.2 = - -* Fix for PayPal extension (http://rkt.bz/r3). 3.0.7 added some logic to avoid errors if the PayPal extension is disabled but the main option setting remained turned on. This release fixes a flaw in that logic that causes the extension to not display certain links or fields. - -= 3.0.7.1 = - - - -* Fix for password reset (typo in object name checking for moderated registration) += 3.0.8 = +* Added retrieval for forgotten username. +* Removed last remaining instances of extract function. = 3.0.7 = @@ -155,6 +149,10 @@ WP-Members 3.0.0 is a major version release. Please review the changelog: http:/ * Changes in core to use fields from WP_Members class (preparing for new form field process). * Reviews and updates to code standards and inline documentation. +* Fix for password reset (typo in object name checking for moderated registration) + +* Fix for PayPal extension (http://rkt.bz/r3); added logic to avoid errors if the PayPal extension is disabled but the main option setting remained turned on. + = 3.0.6 = * Updates to localization function - documented plugin_locale filter, wpmem_localization_file filter, and improved load_textdomain logic. diff --git a/wp-members.php b/wp-members.php index ecfb465f..2cc0e9f1 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.0.7.2 +Version: 3.0.8 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.0.7.2' ); +define( 'WPMEM_VERSION', '3.0.8' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From d89bc89e1e101cc0c8d233b8507e550eaa4e9b4b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 8 Dec 2015 16:18:57 -0600 Subject: [PATCH 0190/1694] updated settings format for user pages --- admin/tab-options.php | 2 +- inc/class-wp-members.php | 18 ++++++++++++++++++ readme.txt | 3 ++- 3 files changed, 21 insertions(+), 2 deletions(-) diff --git a/admin/tab-options.php b/admin/tab-options.php index 5d831adc..c9b81f59 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -402,7 +402,7 @@ function wpmem_admin_page_list( $val, $show_custom_url = true ) { foreach ( $pages as $page ) { $selected = ( get_page_link( $page->ID ) == $val ) ? true : $selected; - $option = ''; echo $option; diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 295becdd..21258788 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -45,6 +45,8 @@ function __construct() { foreach ( $settings as $key => $val ) { $this->$key = $val; } + + $this->load_user_pages(); // Set the stylesheet. $this->cssurl = ( isset( $this->style ) && $this->style == 'use_custom' ) ? $this->cssurl : $this->style; @@ -478,5 +480,21 @@ function excluded_fields( $tag ) { // Return excluded fields. return $excluded_fields; } + + /** + * Set page locations. + * + * Handles numeric page IDs while maintaining + * compatibility with old full url settings. + * + * @since 3.0.8 + */ + function load_user_pages() { + foreach ( $this->user_pages as $key => $val ) { + if ( is_numeric( $val ) ) { + $this->user_pages[ $key ] = get_page_link( $val ); + } + } + } } \ No newline at end of file diff --git a/readme.txt b/readme.txt index f77c5c3e..14f9df81 100644 --- a/readme.txt +++ b/readme.txt @@ -137,8 +137,9 @@ WP-Members 3.0.0 is a major version release. Please review the changelog: http:/ = 3.0.8 = -* Added retrieval for forgotten username. +* Added process for forgotten username retrieval. * Removed last remaining instances of extract function. +* Updated settings for special pages (login|register|user-profile) to store only the numeric primary key ID. This will eliminate the need to update these settings if the site is moved (from a dev to live site, for example). Legacy full URL settings will still be compatible without needing to be updated, but will be automatically updated when main options are saved. = 3.0.7 = From 7bc59d1bf52a13107903602492e27d79216c1f22 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 9 Dec 2015 15:45:46 -0600 Subject: [PATCH 0191/1694] update readme with WP 4.4 tag --- readme.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.txt b/readme.txt index 14f9df81..80a83a73 100644 --- a/readme.txt +++ b/readme.txt @@ -2,7 +2,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.1 -Tested up to: 4.3.1 +Tested up to: 4.4.0 Stable tag: 3.0.8 License: GPLv2 From bb71a6c6b05edf4ec5b879900f8c9b3798859fdb Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 9 Dec 2015 16:28:25 -0600 Subject: [PATCH 0192/1694] cleanup for readme --- readme.txt | 2 -- 1 file changed, 2 deletions(-) diff --git a/readme.txt b/readme.txt index 80a83a73..d12ad425 100644 --- a/readme.txt +++ b/readme.txt @@ -149,9 +149,7 @@ WP-Members 3.0.0 is a major version release. Please review the changelog: http:/ * Fix to plugin_basename. * Changes in core to use fields from WP_Members class (preparing for new form field process). * Reviews and updates to code standards and inline documentation. - * Fix for password reset (typo in object name checking for moderated registration) - * Fix for PayPal extension (http://rkt.bz/r3); added logic to avoid errors if the PayPal extension is disabled but the main option setting remained turned on. = 3.0.6 = From e2e888a9d27d565058c7451b99981c088945d3f1 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 9 Dec 2015 18:04:42 -0600 Subject: [PATCH 0193/1694] corrected syntax error in export file from extract removal --- admin/user-export.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/user-export.php b/admin/user-export.php index 7de2f8f3..ce79688d 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -52,7 +52,7 @@ function wpmem_export_users( $args, $users = null ) { ob_start(); // If exporting all, get all of the users. - $users = ( 'all' == $args'[export'] ) ? get_users( array( 'fields' => 'ID' ) ) : $users; + $users = ( 'all' == $args['export'] ) ? get_users( array( 'fields' => 'ID' ) ) : $users; // Generate headers and a filename based on date of export. header( "Content-Description: File Transfer" ); From 7d4d0a79c37cea9694ce1563b894cc251552fe15 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 21 Dec 2015 15:34:08 -0600 Subject: [PATCH 0194/1694] filter documentation for wpmem_forgot_link_str and wpmem_register_link_str --- inc/forms.php | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/inc/forms.php b/inc/forms.php index 375bf62d..7bf01e99 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -412,7 +412,7 @@ function wpmem_login_form( $page, $arr ) { if ( ( $wpmem->user_pages['profile'] != null || $page == 'members' ) && $arr['action'] == 'login' ) { /** - * Filter the forgot password link. + * Filters the forgot password link. * * @since 2.8.0 * @@ -420,6 +420,13 @@ function wpmem_login_form( $page, $arr ) { */ $link = apply_filters( 'wpmem_forgot_link', wpmem_chk_qstr( $wpmem->user_pages['profile'] ) . 'a=pwdreset' ); $str = __( 'Forgot password?', 'wp-members' ) . ' ' . __( 'Click here to reset', 'wp-members' ) . ''; + /** + * Filters the forgot password HTML. + * + * @since 2.9.0 + * + * @param string $str The forgot password link HTML. + */ $form = $form . $args['link_before'] . apply_filters( 'wpmem_forgot_link_str', $str ) . $args['link_after'] . $args['n']; } @@ -427,7 +434,7 @@ function wpmem_login_form( $page, $arr ) { if ( ( $wpmem->user_pages['register'] != null ) && $arr['action'] == 'login' ) { /** - * Filter the link to the registration page. + * Filters the link to the registration page. * * @since 2.8.0 * @@ -435,6 +442,13 @@ function wpmem_login_form( $page, $arr ) { */ $link = apply_filters( 'wpmem_reg_link', $wpmem->user_pages['register'] ); $str = __( 'New User?', 'wp-members' ) . ' ' . __( 'Click here to register', 'wp-members' ) . ''; + /** + * Filters the register link HTML. + * + * @since 2.9.0 + * + * @param string $str The register link link HTML. + */ $form = $form . $args['link_before'] . apply_filters( 'wpmem_reg_link_str', $str ) . $args['link_after'] . $args['n']; } From ac2d79d207fc0091cd401d84e0bf625f2f180b3b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 21 Dec 2015 15:35:47 -0600 Subject: [PATCH 0195/1694] new wpmem_member_links_args and wpmem_register_links_args filters --- inc/dialogs.php | 81 +++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 72 insertions(+), 9 deletions(-) diff --git a/inc/dialogs.php b/inc/dialogs.php index 66689825..5e22e8f4 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -193,10 +193,44 @@ function wpmem_inc_memberlinks( $page = 'members' ) { switch ( $page ) { case 'members': - $str = ''; + + $arr = array( + 'before_wrapper' => '', + 'wrapper_before' => '
      ', + 'wrapper_after' => '
    ', + 'rows' => array( + '
  • ' . __( 'Edit My Information', 'wp-members' ) . '
  • ', + '
  • ' . __( 'Change Password', 'wp-members' ) . '
  • ', + ), + ); + + if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 && function_exists( 'wpmem_user_page_detail' ) ) { + $arr['rows'][] = wpmem_user_page_detail(); + } + + /** + * Filter the member links array. + * + * @since 3.0.9 + * + * @param array $arr { + * The components of the links. + * + * @type string $before_wrapper Anything that comes before the wrapper. + * @type string $wrapper_before The wrapper opening tag (default:
      ). + * @type string $wrapper_after The wrapper closing tag (default:
    ). + * @type array $rows Row items HTML. + * } + */ + apply_filters( 'wpmem_member_links_args', $arr ); + + $str = $arr['before_wrapper']; + $str.= $arr['wrapper_before']; + foreach ( $arr['rows'] as $row ) { + $str.= $row; + } + $str.= $arr['wrapper_after']; + /** * Filter the links displayed on the User Profile page (logged in state). * @@ -208,11 +242,40 @@ function wpmem_inc_memberlinks( $page = 'members' ) { break; case 'register': - $str = '

    ' . sprintf( __( 'You are logged in as %s', 'wp-members' ), $user_login ) . '

    - '; + + $arr = array( + 'before_wrapper' => '

    ' . sprintf( __( 'You are logged in as %s', 'wp-members' ), $user_login ) . '

    ', + 'wrapper_before' => '
      ', + 'wrapper_after' => '
    ', + 'rows' => array( + '
  • ' . __( 'Click to log out.', 'wp-members' ) . '
  • ', + '
  • ' . __( 'Begin using the site.', 'wp-members' ) . '
  • ', + ), + ); + + /** + * Filter the register links array. + * + * @since 3.0.9 + * + * @param array $arr { + * The components of the links. + * + * @type string $before_wrapper HTML before the wrapper (default: login status). + * @type string $wrapper_before The wrapper opening tag (default:
      ). + * @type string $wrapper_after The wrapper closing tag (default:
    ). + * @type array $rows Row items HTML. + * } + */ + apply_filters( 'wpmem_register_links_args', $arr ); + + $str = $arr['before_wrapper']; + $str.= $arr['wrapper_before']; + foreach ( $arr['rows'] as $row ) { + $str.= $row; + } + $str.= $arr['wrapper_after']; + /** * Filter the links displayed on the Register page (logged in state). * From 4716ae3e3896c1008b98aa6ccf6b24f91ac87a5b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 21 Dec 2015 15:39:45 -0600 Subject: [PATCH 0196/1694] added management for custom post types --- admin/admin.php | 3 +- admin/post.php | 44 ++++++++++---------- admin/tab-options.php | 95 +++++++++++++++++++++++++++++++++++++++++-- 3 files changed, 116 insertions(+), 26 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index bfbf5754..9782e5db 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -270,11 +270,12 @@ function wpmem_admin_action( $action ) { switch ( $action ) { case 'update_settings': + case 'update_cpts': /** * Load Options tab functions. */ include_once( WPMEM_PATH . 'admin/tab-options.php' ); - $did_update = wpmem_update_options(); + $did_update = ( 'update_cpts' == $action ) ? wpmem_update_cpts() : wpmem_update_options(); break; case 'update_fields': diff --git a/admin/post.php b/admin/post.php index 29ea25fa..0a1ebf8f 100644 --- a/admin/post.php +++ b/admin/post.php @@ -42,9 +42,9 @@ * * @since 2.9.2 */ -function wpmem_bulk_posts_action() { - // @todo - holding off on CPT support for now. - if ( ( isset( $_GET['post_type'] ) && $_GET['post_type'] == 'page' ) || ! isset( $_GET['post_type'] ) ) { ?> +function wpmem_bulk_posts_action() { + global $wpmem; + if ( ( isset( $_GET['post_type'] ) && ( $_GET['post_type'] == 'page' || array_key_exists( $_GET['post_type'], $wpmem->post_types ) ) ) || ! isset( $_GET['post_type'] ) ) { ?> $field ) { + $meta_key = $field[2]; + if ( 'user_email' == $meta_key ) { + $wpmem_fields[ $key ][4] = 'y'; + $wpmem_fields[ $key ][5] = 'y'; + } else { + $wpmem_fields[ $key ][4] = ( wpmem_get( $meta_key . "_display" ) ) ? 'y' : ''; + $wpmem_fields[ $key ][5] = ( wpmem_get( $meta_key . "_required" ) ) ? 'y' : ''; + } + } + update_option( 'wpmembers_fields', $wpmem_fields ); + $wpmem->load_fields(); + $did_update = __( 'WP-Members fields were updated', 'wp-members' ); + return $did_update; + + } elseif ( 'delete' == $action ) { + + //echo '
    '; print_r( $_POST['delete'] ); exit();
    +
    +		} elseif ( 'add_field' == wpmem_get( 'wpmem_admin_a' ) || 'edit_field' == wpmem_get( 'wpmem_admin_a' ) ) {
    +
    +			// Check nonce.
    +			//check_admin_referer( 'wpmem-add-fields' );
    +
    +			global $add_field_err_msg;
    +
    +			$add_field_err_msg = false;
    +			$add_name = wpmem_get( 'add_name' );
    +			$add_option = wpmem_get( 'add_option' );
    +
    +			// Error check that field label and option name are included and unique.
    +			$add_field_err_msg = ( ! $add_name   ) ? __( 'Field Label is required. Nothing was updated.', 'wp-members' ) : $add_field_err_msg;
    +			$add_field_err_msg = ( ! $add_option ) ? __( 'Meta Key is required. Nothing was updated.',    'wp-members' ) : $add_field_err_msg;
    +
    +			$add_field_err_msg = ( ! preg_match("/^[A-Za-z0-9_]*$/", $add_option ) ) ? __( 'Meta Key must contain only letters, numbers, and underscores', 'wp-members' ) : $add_field_err_msg;
    +
    +			// Check for duplicate field names.
    +			$chk_fields = array();
    +			foreach ( $wpmem_fields as $field ) {
    +				$chk_fields[] = $field[2];
    +			}
    +			$add_field_err_msg = ( in_array( $add_option, $chk_fields ) ) ? __( 'A field with that meta key already exists', 'wp-members' ) : $add_field_err_msg;
    +
    +			// Error check for reserved terms.
    +			$reserved_terms = wpmem_wp_reserved_terms();
    +			if ( in_array( strtolower( $add_option ), $reserved_terms ) ) {
    +				$add_field_err_msg = sprintf( __( 'Sorry, "%s" is a reserved term. Field was not added.', 'wp-members' ), $submitted_term );
    +			}
    +
    +			// Error check option name for spaces and replace with underscores.
    +			$us_option = preg_replace( "/ /", '_', $add_option );
    +
    +			$arr = array();
    +
    +			$type =  wpmem_get( 'add_type' );
    +
    +			$arr[0] = ( wpmem_get( 'wpmem_admin_a' ) == 'add_field' ) ? ( count( $wpmem_fields ) ) + 2 : false;
    +			$arr[1] = stripslashes( wpmem_get( 'add_name' ) );
    +			$arr[2] = $us_option;
    +			$arr[3] = $type;
    +			$arr[4] = wpmem_get( 'add_display', 'n' );// ( isset( $_POST['add_display'] ) )  ? $_POST['add_display']  : 'n';
    +			$arr[5] = wpmem_get( 'add_required', 'n' ); //( isset( $_POST['add_required'] ) ) ? $_POST['add_required'] : 'n';
    +			$arr[6] = ( $us_option == 'user_nicename' || $us_option == 'display_name' || $us_option == 'nickname' ) ? 'y' : 'n';
    +
    +			if ( 'text' == $type || 'email' == $type || 'textarea' == $type || 'password' == $type || 'url' == $type || 'number' == $type || 'date' == $type ) {
    +				$arr['placeholder'] = wpmem_get( 'add_placeholder' );
    +			}
    +
    +			if ( 'text' == $type || 'email' == $type || 'password' == $type || 'url' == $type || 'number' == $type || 'date' == $type ) {
    +				$arr['pattern'] = wpmem_get( 'add_pattern' );
    +				$arr['title']   = wpmem_get( 'add_title' );
    +			}
    +
    +			if ( 'number' == $type || 'date' == $type ) {
    +				$arr['min'] = wpmem_get( 'add_min' );
    +				$arr['max'] = wpmem_get( 'add_max' );
    +			}
    +
    +			if ( $type == 'checkbox' ) { 
    +				$add_field_err_msg = ( ! $_POST['add_checked_value'] ) ? __( 'Checked value is required for checkboxes. Nothing was updated.', 'wp-members' ) : $add_field_err_msg;
    +				$arr[7] = ( isset( $_POST['add_checked_value'] ) )   ? $_POST['add_checked_value']   : false;
    +				$arr[8] = ( isset( $_POST['add_checked_default'] ) ) ? $_POST['add_checked_default'] : 'n';
    +			}
    +
    +			if (   $type == 'select' 
    +				|| $type == 'multiselect' 
    +				|| $type == 'radio'
    +				|| $type == 'multicheckbox' 
    +			) {
    +				// Get the values.
    +				$str = stripslashes( $_POST['add_dropdown_value'] );
    +				// Remove linebreaks.
    +				$str = trim( str_replace( array("\r", "\r\n", "\n"), '', $str ) );
    +				// Create array.
    +				if ( ! function_exists( 'str_getcsv' ) ) {
    +					$arr[7] = explode( ',', $str );
    +				} else {
    +					$arr[7] = str_getcsv( $str, ',', '"' );
    +				}
    +				// If multiselect or multicheckbox, set delimiter.
    +				if ( 'multiselect' == $type || 'multicheckbox' == $type ) {
    +					$arr[8] = ( isset( $_POST['add_delimiter_value'] ) ) ? $_POST['add_delimiter_value'] : '|';
    +				}
    +			}
    +
    +			if ( $type == 'file' || $type == 'image' ) {
    +				$arr[7] = stripslashes( $_POST['add_file_value'] );
    +			}
    +
    +			if ( wpmem_get( 'add_type' ) == 'hidden' ) { 
    +				$add_field_err_msg = ( ! $_POST['add_hidden_value'] ) ? __( 'A value is required for hidden fields. Nothing was updated.', 'wp-members' ) : $add_field_err_msg;
    +				$arr[7] = ( isset( $_POST['add_hidden_value'] ) )   ? stripslashes( $_POST['add_hidden_value'] ) : '';
    +			}
    +
    +			if ( $action == 'add_field' ) {
    +				if ( ! $add_field_err_msg ) {
    +					array_push( $wpmem_fields, $arr );
    +					$did_update = sprintf( __( '%s was added', 'wp-members' ), $_POST['add_name'] );
    +				} else {
    +					$did_update = $add_field_err_msg;
    +				}
    +			} else {
    +				for ( $row = 0; $row < count( $wpmem_fields ); $row++ ) {
    +					if ( $wpmem_fields[ $row ][2] == wpmem_get( 'field', false, 'get' ) ) {
    +						$arr[0] = $wpmem_fields[ $row ][0];
    +						foreach ( $arr as $key => $value ) {
    +							$wpmem_fields[ $row ][ $key ] = $arr[ $key ];
    +						}
     					}
    -				} ?>
    -				
    - - - -
    -
    - « ' . __( 'Return to Fields Table', 'wp-members' ) . '

    '; + } + + $wpmem_newfields = $wpmem_fields; + + update_option( 'wpmembers_fields', $wpmem_newfields ); + $wpmem->load_fields(); + return $did_update; + } + } +} + +/** + * Reorders form fields. + * + * @since 2.5.1 + * @since 3.1.8 Rebuilt for new List Table. + */ +function wpmem_a_field_reorder() { + + // Start fresh. + $new_order = $wpmem_fields = $field = $key = $wpmem_new_fields = $id = $k = ''; + $wpmem_fields = get_option( 'wpmembers_fields' ); + + // Get the list items + $new_order = $_POST; + + // Put fields in the proper order for the current form. + $wpmem_new_fields = array(); + foreach ( $new_order['list_items'] as $id ) { + foreach( $wpmem_fields as $val ) { + if ( $val[0] == $id ) { + $wpmem_new_fields[] = $val; + } + } + } + + // Save fields array with new current form field order. + update_option( 'wpmembers_fields', $wpmem_new_fields ); + + // Indicate successful transaction. + _e( 'Form field order updated.', 'wp-members' ); + + die(); // This is required to return a proper result. + } // End of file. \ No newline at end of file From 5c99d08e0652100f26896130da98aa87e93b7404 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 22 May 2017 20:26:07 -0500 Subject: [PATCH 0616/1694] 3.1.8 RC 3 --- readme.txt | 6 ++++-- wp-members.php | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/readme.txt b/readme.txt index dd6a3227..e0cdc0bc 100644 --- a/readme.txt +++ b/readme.txt @@ -140,6 +140,8 @@ WP-Members 3.1.7.1 is a minor update, changing only the default for wpmem_curren * Added new native registration handling to accommodate WooCommerce 3.0. * Added support for user file upload on admin/dashboard profile. +* Added meta_key/meta_value attribute to [wpmem_logged_in] shortcode. +* Added wpmem_user_has_meta() API function. * Updated post editor shortcode button javascript to include new(er) shortcodes. * Fixed WP-Members user profile shortcode to only display logged in content (by shortcode) if the wpmem_a 'action' is not set (i.e. logged in content only displays if page is in "member links" state). * Fixed register link in login form to prevent link from displaying if login form is displayed along with the registration form (standard configuration). @@ -147,10 +149,10 @@ WP-Members 3.1.7.1 is a minor update, changing only the default for wpmem_curren * Improved line break stripping process in form builder to allow for line breaks in textarea fields. * Improved field shortcode for textarea fields to display line breaks. * Deprecated old wpmem_do_sc_pages() function, updated wpmem_sc_user_profile(). -* Fields Tab: improved field edit screen: return link at bottom of page, display current field upon successful form submission, success message include return link. +* Fields Tab: ground-up rebuild to utilize WP_List_Table and jquery sorting UI. +* Fields Tab: improved field add/edit screen: return link at bottom of page, display current field upon successful form submission, success message include return link. * Fields Tab: added support for HTML5 field types: number, date. * Fields Tab: added support for HTML5 field attributes: placeholder, pattern (regex), title, min, max. -* Fields Tab: code overview and improvement. = 3.1.7 = diff --git a/wp-members.php b/wp-members.php index 65fcb72d..56329d09 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.1.8 Development Version +Version: 3.1.8 Beta RC 3 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.1.8' ); +define( 'WPMEM_VERSION', '3.1.8 RC 3' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 8c264ba241762a4f602574bfc7dd20dc9dad7e36 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 23 May 2017 09:25:57 -0500 Subject: [PATCH 0617/1694] cleanup --- admin/tab-fields.php | 3 +-- inc/class-wp-members.php | 1 + inc/dialogs.php | 4 ---- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 6a5e0e35..d6b3268c 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -633,8 +633,7 @@ function wpmem_bulk_fields_action() { function wpmem_admin_fields_update() { global $wpmem, $did_update; - - //if ( isset( $_GET['tab'] ) && $_GET['tab'] == 'fields' ) { + if ( isset( $_GET['tab'] ) && $_GET['tab'] == 'fields' ) { // Get the current fields. $wpmem_fields = get_option( 'wpmembers_fields' ); diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 11ab9d80..baead661 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -426,6 +426,7 @@ function load_dependencies() { require_once( WPMEM_PATH . 'inc/core.php' ); require_once( WPMEM_PATH . 'inc/api.php' ); require_once( WPMEM_PATH . 'inc/utilities.php' ); + require_once( WPMEM_PATH . 'inc/forms.php' ); require_once( WPMEM_PATH . 'inc/dialogs.php' ); require_once( WPMEM_PATH . 'inc/sidebar.php' ); require_once( WPMEM_PATH . 'inc/shortcodes.php' ); diff --git a/inc/dialogs.php b/inc/dialogs.php index 4fa687ad..f7443b11 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -24,10 +24,6 @@ */ -// Include the form building functions. -include_once( WPMEM_PATH . 'inc/forms.php' ); - - if ( ! function_exists( 'wpmem_inc_loginfailed' ) ): /** * Login Failed Dialog. From 64696b98e35e4329455cc423ab8150a4ce7af77c Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 23 May 2017 14:58:13 -0500 Subject: [PATCH 0618/1694] fix bottom bulk menu on fields tab --- admin/tab-fields.php | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index d6b3268c..af586425 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -90,11 +90,10 @@ function wpmem_fields_edit_link( $field_id ) { */ function wpmem_a_render_fields_tab() { - global $wpmem, $did_update; + global $wpmem, $did_update, $delete_action; $wpmem_fields = wpmem_fields(); $edit_meta = wpmem_get( 'field', false, 'get' ); $add_meta = wpmem_get( 'add_field', false ); - $delete_action = wpmem_get( 'action' ); if ( 'delete' == $delete_action ) { $delete_fields = wpmem_get( 'delete' ); ?> @@ -632,14 +631,17 @@ function wpmem_bulk_fields_action() { */ function wpmem_admin_fields_update() { - global $wpmem, $did_update; + global $wpmem, $did_update, $delete_action; if ( isset( $_GET['tab'] ) && $_GET['tab'] == 'fields' ) { // Get the current fields. $wpmem_fields = get_option( 'wpmembers_fields' ); $wpmem_ut_fields = get_option( 'wpmembers_utfields' ); - $action = wpmem_get( 'action' ); + $action = wpmem_get( 'action', false ); + $action = ( -1 == $action ) ? wpmem_get( 'action2' ) : $action; + + $delete_action = false; if ( 'save' == $action ) { @@ -667,7 +669,7 @@ function wpmem_admin_fields_update() { } elseif ( 'delete' == $action ) { - //echo '
    '; print_r( $_POST['delete'] ); exit();
    +			$delete_action = 'delete';
     
     		} elseif ( 'add_field' == wpmem_get( 'wpmem_admin_a' ) || 'edit_field' == wpmem_get( 'wpmem_admin_a' ) ) {
     
    
    From 9d2672b97eb340bee6c1741969e924014f579440 Mon Sep 17 00:00:00 2001
    From: Chad Butler 
    Date: Tue, 23 May 2017 15:33:01 -0500
    Subject: [PATCH 0619/1694] debug add/edit field in new fields tab
    
    ---
     admin/tab-fields.php | 9 ++++++---
     1 file changed, 6 insertions(+), 3 deletions(-)
    
    diff --git a/admin/tab-fields.php b/admin/tab-fields.php
    index af586425..924d36c9 100644
    --- a/admin/tab-fields.php
    +++ b/admin/tab-fields.php
    @@ -672,6 +672,9 @@ function wpmem_admin_fields_update() {
     			$delete_action = 'delete';
     
     		} elseif ( 'add_field' == wpmem_get( 'wpmem_admin_a' ) || 'edit_field' == wpmem_get( 'wpmem_admin_a' ) ) {
    +			
    +			// Set action.
    +			$action = wpmem_get( 'wpmem_admin_a' );
     
     			// Check nonce.
     			//check_admin_referer( 'wpmem-add-fields' );
    @@ -730,10 +733,10 @@ function wpmem_admin_fields_update() {
     				$arr['max'] = wpmem_get( 'add_max' );
     			}
     
    -			if ( $type == 'checkbox' ) { 
    +			if ( $type == 'checkbox' ) {
     				$add_field_err_msg = ( ! $_POST['add_checked_value'] ) ? __( 'Checked value is required for checkboxes. Nothing was updated.', 'wp-members' ) : $add_field_err_msg;
    -				$arr[7] = ( isset( $_POST['add_checked_value'] ) )   ? $_POST['add_checked_value']   : false;
    -				$arr[8] = ( isset( $_POST['add_checked_default'] ) ) ? $_POST['add_checked_default'] : 'n';
    +				$arr[7] = wpmem_get( 'add_checked_value', false );
    +				$arr[8] = wpmem_get( 'add_checked_default', 'n' );
     			}
     
     			if (   $type == 'select' 
    
    From 610c589d216e1563af7a9936960b2fe6e41ed7d6 Mon Sep 17 00:00:00 2001
    From: Chad Butler 
    Date: Tue, 23 May 2017 17:31:07 -0500
    Subject: [PATCH 0620/1694] debug user screen checkboxes for fields tab
    
    ---
     admin/tab-fields.php | 62 ++++++++++++++++++++++++--------------------
     1 file changed, 34 insertions(+), 28 deletions(-)
    
    diff --git a/admin/tab-fields.php b/admin/tab-fields.php
    index 924d36c9..ed3cf633 100644
    --- a/admin/tab-fields.php
    +++ b/admin/tab-fields.php
    @@ -155,9 +155,9 @@ function wpmem_a_render_fields_tab() {
      */
     function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key ) {
     	global $wpmem;
    +	$fields = wpmem_fields();
     	if ( $mode == 'edit' ) {
    -		$fields = wpmem_fields();
    -		$field  = $fields[ $meta_key ];	
    +		$field = $fields[ $meta_key ];	
     	}
     	$form_action = ( $mode == 'edit' ) ? 'editfieldform' : 'addfieldform'; 
     	$span_optional = '' . __( '(optional)', 'wp-members' ) . '';
    @@ -347,6 +347,17 @@ function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key )
     		
     		
    + + @@ -376,7 +387,7 @@ function wpmem_a_render_fields_tab_field_table() { $meta = $field[2]; - $ut_checked = ( ( $wpmem_ut_fields ) && ( in_array( $field[1], $wpmem_ut_fields ) ) ) ? true : ''; + $ut_checked = ( ( $wpmem_ut_fields ) && ( in_array( $field[1], $wpmem_ut_fields ) ) ) ? $field[1] : ''; $field_items[] = array( 'order' => $field[0], 'label' => $field[1], @@ -386,34 +397,29 @@ function wpmem_a_render_fields_tab_field_table() { 'req' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_required", 'checkbox', 'y', $field[5] ) : '', //'profile' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_profile", 'checkbox', true, $field[6] ) : '', 'edit' => wpmem_fields_edit_link( $meta ), - 'userscrn' => ( ! in_array( $meta, $wpmem_ut_fields_skip ) ) ? wpmem_create_formfield( 'ut_fields[' . $meta . ']', 'checkbox', true, $ut_checked ) : '', + 'userscrn' => ( ! in_array( $meta, $wpmem_ut_fields_skip ) ) ? wpmem_create_formfield( 'ut_fields[' . $meta . ']', 'checkbox', $field[1], $ut_checked ) : '', 'sort' => '', ); } } - $user_screen_items = array( - 'user_registered' => array( 'label' => __( 'Registration Date', 'wp-members' ), 'meta' => 'user_registered', - 'userscrn' => ( ! in_array( $meta, $wpmem_ut_fields_skip ) ) ? wpmem_create_formfield( 'ut_fields[' . $meta . ']', 'checkbox', true, $ut_checked ) : '', - ), + $extra_user_screen_items = array( + 'user_registered' => 'Registration Date', + 'active' => 'Active', + 'wpmem_reg_ip' => 'Registration IP', + 'exp_type' => 'Subscription Type', + 'expires' => 'Expires', ); - if ( $wpmem->mod_reg == 1 ) { - $user_screen_items[] = array( 'label' => __( 'Active', 'wp-members' ), 'meta' => 'active', - 'userscrn' => ( ( $wpmem_ut_fields ) && ( in_array( 'Active', $wpmem_ut_fields ) ) ) ? 'checked' : false, - ); - } - $user_screen_items[] = array( 'label' => __( 'Registration IP', 'wp-members' ), 'meta' => 'wpmem_reg_ip', - 'userscrn' => ( ( $wpmem_ut_fields ) && ( in_array( 'Registration IP', $wpmem_ut_fields ) ) ) ? 'checked' : false, - ); - if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { - $user_screen_items[] = array( 'label' => 'Subscription Type', 'meta' => 'exp_type', - 'userscrn' => ( ( $wpmem_ut_fields ) && ( in_array( 'Subscription Type', $wpmem_ut_fields ) ) ) ? 'checked' : false, - ); - $user_screen_items[] = array( 'label' => 'Expires', 'meta' => 'expires', - 'userscrn' => ( ( $wpmem_ut_fields ) && ( in_array( 'Expires', $wpmem_ut_fields ) ) ) ? 'checked' : false, - ); + foreach ( $extra_user_screen_items as $key => $item ) { + $ut_checked = ( ( $wpmem_ut_fields ) && ( in_array( $item, $wpmem_ut_fields ) ) ) ? $item : ''; + if ( 'user_registered' == $key || ( 'active' == $key && 1 == $wpmem->mod_reg ) || 'wpmem_reg_ip' == $key || defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 && ( 'exp_type' == $key || 'expires' == $key ) ) { + $user_screen_items[ $key ] = array( 'label' => __( $item, 'wp-members' ), 'meta' => $key, + 'userscrn' => wpmem_create_formfield( "ut_fields[{$key}]", 'checkbox', $item, $ut_checked ), + ); + } } + foreach ( $user_screen_items as $screen_item ) { $field_items[] = array( 'label' => $screen_item['label'], @@ -636,7 +642,6 @@ function wpmem_admin_fields_update() { if ( isset( $_GET['tab'] ) && $_GET['tab'] == 'fields' ) { // Get the current fields. $wpmem_fields = get_option( 'wpmembers_fields' ); - $wpmem_ut_fields = get_option( 'wpmembers_utfields' ); $action = wpmem_get( 'action', false ); $action = ( -1 == $action ) ? wpmem_get( 'action2' ) : $action; @@ -649,7 +654,8 @@ function wpmem_admin_fields_update() { //check_admin_referer( 'wpmem-update-fields' ); // Update user table fields. - update_option( 'wpmembers_utfields', wpmem_get( 'ut_fields' ) ); + $arr = ( isset( $_POST['ut_fields'] ) ) ? $_POST['ut_fields'] : ''; + update_option( 'wpmembers_utfields', $arr ); // Update display/required settings foreach ( $wpmem_fields as $key => $field ) { @@ -711,12 +717,12 @@ function wpmem_admin_fields_update() { $type = wpmem_get( 'add_type' ); - $arr[0] = ( wpmem_get( 'wpmem_admin_a' ) == 'add_field' ) ? ( count( $wpmem_fields ) ) + 2 : false; + $arr[0] = wpmem_get( 'add_order_id' ); $arr[1] = stripslashes( wpmem_get( 'add_name' ) ); $arr[2] = $us_option; $arr[3] = $type; - $arr[4] = wpmem_get( 'add_display', 'n' );// ( isset( $_POST['add_display'] ) ) ? $_POST['add_display'] : 'n'; - $arr[5] = wpmem_get( 'add_required', 'n' ); //( isset( $_POST['add_required'] ) ) ? $_POST['add_required'] : 'n'; + $arr[4] = wpmem_get( 'add_display', 'n' ); + $arr[5] = wpmem_get( 'add_required', 'n' ); $arr[6] = ( $us_option == 'user_nicename' || $us_option == 'display_name' || $us_option == 'nickname' ) ? 'y' : 'n'; if ( 'text' == $type || 'email' == $type || 'textarea' == $type || 'password' == $type || 'url' == $type || 'number' == $type || 'date' == $type ) { From 01f2ea106cfcf292738ba8f5899b7bc4338ee0b0 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 25 May 2017 08:34:01 -0500 Subject: [PATCH 0621/1694] allows email to be removed from profile form --- inc/register.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/register.php b/inc/register.php index 7ecc53ee..2c789907 100644 --- a/inc/register.php +++ b/inc/register.php @@ -271,12 +271,12 @@ function wpmem_registration( $tag ) { * see if it's different, then check if it is a valid address and it exists. */ global $current_user; wp_get_current_user(); - if ( $wpmem->user->post_data['user_email'] != $current_user->user_email ) { + if ( $wpmem->user->post_data['user_email'] != $current_user->user_email ) { if ( email_exists( $wpmem->user->post_data['user_email'] ) ) { return "email"; exit(); } - if ( !is_email( $wpmem->user->post_data['user_email']) ) { + if ( in_array( 'user_email', $wpmem->fields ) && ! is_email( $wpmem->user->post_data['user_email']) ) { $wpmem_themsg = $wpmem->get_text( 'reg_valid_email' ); return "updaterr"; exit(); From fe48cd516592d7c403515f6d4c7aeed0d4344a9e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 25 May 2017 08:34:48 -0500 Subject: [PATCH 0622/1694] fix login form link filters with _reg stem --- inc/class-wp-members-forms.php | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index c78519e9..2f7cb999 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -487,22 +487,26 @@ function login_form( $page, $arr ) { $links_array = array( 'forgot' => array( + 'tag' => 'forgot', 'link' => add_query_arg( 'a', 'pwdreset', $wpmem->user_pages['profile'] ), 'page' => 'profile', 'action' => 'login', ), - 'register' => array( + 'register' => array( + 'tag' => 'reg', 'link' => $wpmem->user_pages['register'], 'page' => 'register', 'action' => 'login', ), 'username' => array( + 'tag' => 'username', 'link' => add_query_arg( 'a', 'getusername', $wpmem->user_pages['profile'] ), 'page' => 'profile', 'action' => 'pwdreset', ), ); foreach ( $links_array as $key => $value ) { + $tag = $value['tag']; if ( ( $wpmem->user_pages[ $value['page'] ] || 'members' == $page ) && $value['action'] == $arr['action'] ) { /** * Filters register, forgot password, and forgot username links. @@ -512,7 +516,7 @@ function login_form( $page, $arr ) { * * @param string The raw link. */ - $link = apply_filters( "wpmem_{$key}_link", $value['link'] ); + $link = apply_filters( "wpmem_{$tag}_link", $value['link'] ); $str = $wpmem->get_text( "{$key}_link_before" ) . '' . $wpmem->get_text( "{$key}_link" ) . ''; /** * Filters the register, forgot password, and forgot username links HTML. @@ -524,7 +528,7 @@ function login_form( $page, $arr ) { * @param string $str The link HTML. * @param string $link The link. */ - $link = $args['link_before'] . apply_filters( "wpmem_{$key}_link_str", $str, $link ) . $args['link_after'] . $args['n']; + $link = $args['link_before'] . apply_filters( "wpmem_{$tag}_link_str", $str, $link ) . $args['link_after'] . $args['n']; /* * If this is the register link, and the current post type is set to * display the register form, and the current page is not the login From 0ddb5d6a6b55529adb29d6068beee624f1c78e85 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 25 May 2017 08:35:33 -0500 Subject: [PATCH 0623/1694] updates for new fields tab --- admin/css/admin.css | 5 ++++- admin/tab-fields.php | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/admin/css/admin.css b/admin/css/admin.css index 9f5cdd4a..3c7baf92 100644 --- a/admin/css/admin.css +++ b/admin/css/admin.css @@ -52,6 +52,9 @@ color: #f00; } +#the-list { + cursor: move; +} #sort { width: 24px; -} \ No newline at end of file +} diff --git a/admin/tab-fields.php b/admin/tab-fields.php index ed3cf633..45511b5d 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -476,7 +476,7 @@ function column_cb( $item ) { if ( in_array( $item['meta'], $this->no_delete ) || in_array( $item['meta'], $this->excludes ) ) { return; } else { - return sprintf( '', $item['meta'] ); + return sprintf( '', $item['meta'], __( 'delete', 'wp-members' ) ); } } From 4a01d37bc6149b5cfd5fce0ab085c032110c3040 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 26 May 2017 15:53:11 -0500 Subject: [PATCH 0624/1694] replaced $_SERVER['REQUEST_URI'] with new wpmem_admin_form_post_url() api function --- admin/includes/api.php | 15 +++++++++++ admin/includes/class-wp-members-admin-api.php | 27 +++++++++++++++++++ admin/tab-captcha.php | 2 +- admin/tab-dialogs.php | 2 +- admin/tab-emails.php | 2 +- admin/tab-fields.php | 24 +++++++++++------ admin/tab-options.php | 4 +-- readme.txt | 1 + 8 files changed, 64 insertions(+), 13 deletions(-) diff --git a/admin/includes/api.php b/admin/includes/api.php index 8b269b31..c94118dc 100644 --- a/admin/includes/api.php +++ b/admin/includes/api.php @@ -83,3 +83,18 @@ function wpmem_is_tab( $tab ) { function wpmem_admin_user_profile( $user_id ) { return add_query_arg( 'user_id', $user_id, admin_url( 'user-edit.php' ) ); } + +/** + * Wrapper for form_post_url(). + * + * @since 3.1.8 + * + * @global object $wpmem The WP_Members Object. + * @param string $tab The plugin tab being displayed. + * @param mixed $args Array of additional arguments|boolean. Default: false. + * @return string $url + */ +function wpmem_admin_form_post_url( $args = false ) { + global $wpmem; + return $wpmem->admin->form_post_url( $args ); +} \ No newline at end of file diff --git a/admin/includes/class-wp-members-admin-api.php b/admin/includes/class-wp-members-admin-api.php index 0963f13b..79ed3428 100644 --- a/admin/includes/class-wp-members-admin-api.php +++ b/admin/includes/class-wp-members-admin-api.php @@ -482,6 +482,33 @@ function get_form( $form = 'default' ) { $this->current_form_fields = wpmem_fields(); } + /** + * Build admin panel form action url. + * + * @since 3.1.8 + * + * @global string $pagenow + * @global string $plugin_page + * @global object $wpmem The WP_Members Object. + * @param mixed $args Array of additional arguments|boolean. Default: false. + * @return string $url + */ + function form_post_url( $args = false ) { + global $pagenow, $plugin_page, $wpmem; + $tab = wpmem_get( 'tab', false, 'get' ); + $params = array( 'page' => $plugin_page ); + if ( $tab ) { + $params['tab'] = $tab; + } + if ( $args ) { + foreach( $args as $key => $val ) { + $params[ $key ] = $val; + } + } + $url = add_query_arg( $params, admin_url( $pagenow ) ); + return $url; + } + } // End of WP_Members_Admin_API class. // End of file. \ No newline at end of file diff --git a/admin/tab-captcha.php b/admin/tab-captcha.php index 280dece1..4dc39e79 100644 --- a/admin/tab-captcha.php +++ b/admin/tab-captcha.php @@ -52,7 +52,7 @@ function wpmem_a_build_captcha_options() {

    -
    + WP-Members

    - +
    admin->dialogs ) ) { diff --git a/admin/tab-emails.php b/admin/tab-emails.php index d3e61a65..452b72d5 100644 --- a/admin/tab-emails.php +++ b/admin/tab-emails.php @@ -42,7 +42,7 @@ function wpmem_a_build_emails() {


    - +
    diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 45511b5d..40335e00 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -87,6 +87,10 @@ function wpmem_fields_edit_link( $field_id ) { * Renders the content of the fields tab. * * @since 3.1.8 + * + * @global object $wpmem The WP_Members Object. + * @global string $did_update + * @global string $delete_action */ function wpmem_a_render_fields_tab() { @@ -103,7 +107,7 @@ function wpmem_a_render_fields_tab() { fields[ $meta ]['label'] . ' (meta key: ' . $meta . ')
    '; } ?> - + " /> @@ -149,9 +153,10 @@ function wpmem_a_render_fields_tab() { * @since 2.8 * @since 3.1.8 Changed name from wpmem_a_field_edit(). * - * @param string $mode The mode for the function (edit|add) - * @param array|null $wpmem_fields the array of fields - * @param string|null $field the field being edited + * @global object $wpmem The WP_Members Object. + * @param string $mode The mode for the function (edit|add) + * @param array|null $wpmem_fields The array of fields + * @param string|null $field The field being edited */ function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key ) { global $wpmem; @@ -161,9 +166,13 @@ function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key ) } $form_action = ( $mode == 'edit' ) ? 'editfieldform' : 'addfieldform'; $span_optional = '' . __( '(optional)', 'wp-members' ) . ''; - $span_required = '' . __( '(required)', 'wp-members' ) . ''; ?> + $span_required = '' . __( '(required)', 'wp-members' ) . ''; + $form_submit = array( 'mode' => $mode ); + if ( isset( $_GET['field'] ) ) { + $form_submit['field'] = $meta_key; + } ?>

    - +
    • @@ -439,12 +448,11 @@ function wpmem_a_render_fields_tab_field_table() { $heading = __( 'Manage Fields', 'wp-members' ); //$description = __( 'Displaying fields for:', 'wp-members' ); //$which_form = $wpmem->form_tags[ $wpmem->admin->current_form ]; - $post_to = $_SERVER['REQUEST_URI']; echo '
      '; printf( '

      %s

      ', $heading ); //printf( '

      %s %s

      ', $description, $which_form ); - printf( '', $post_to ); + printf( '', wpmem_admin_form_post_url() ); $table->items = $field_items; $table->prepare_items(); diff --git a/admin/tab-options.php b/admin/tab-options.php index a6d1af76..7f9ddb3f 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -70,7 +70,7 @@ function wpmem_a_build_options() {

      - +

        @@ -246,7 +246,7 @@ function wpmem_a_build_options() {

        - +
    diff --git a/readme.txt b/readme.txt index e0cdc0bc..8a9798da 100644 --- a/readme.txt +++ b/readme.txt @@ -149,6 +149,7 @@ WP-Members 3.1.7.1 is a minor update, changing only the default for wpmem_curren * Improved line break stripping process in form builder to allow for line breaks in textarea fields. * Improved field shortcode for textarea fields to display line breaks. * Deprecated old wpmem_do_sc_pages() function, updated wpmem_sc_user_profile(). +* Removed $_SERVER['REQUEST_URI'] from all admin tab form action attributes. Replaced with new wpmem_admin_form_post_url() API function. * Fields Tab: ground-up rebuild to utilize WP_List_Table and jquery sorting UI. * Fields Tab: improved field add/edit screen: return link at bottom of page, display current field upon successful form submission, success message include return link. * Fields Tab: added support for HTML5 field types: number, date. From 834a564990745ed43944248cb8f74cecda28b654 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 26 May 2017 15:53:55 -0500 Subject: [PATCH 0625/1694] improved handling for html entities in fields (for display in both form and field shortcode) --- inc/class-wp-members-forms.php | 2 +- inc/shortcodes.php | 10 ++++------ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 2f7cb999..875a2c58 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -107,7 +107,7 @@ function create_form_field( $args ) { break; case "textarea": - $value = stripslashes( esc_textarea( $value ) ); + $value = stripslashes( $value ); // stripslashes( esc_textarea( $value ) ); $class = ( 'textbox' == $class ) ? "textarea" : $class; $rows = ( isset( $args['rows'] ) ) ? $args['rows'] : '5'; $cols = ( isset( $args['cols'] ) ) ? $args['cols'] : '20'; diff --git a/inc/shortcodes.php b/inc/shortcodes.php index aebed81b..7a1790be 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -478,7 +478,7 @@ function wpmem_sc_fields( $atts, $content = null, $tag ) { global $wpmem; $fields = wpmem_fields(); - $field_type = ( isset( $fields[ $field ]['type'] ) ) ? $fields[ $field ]['type'] : 'native'; + $field_type = ( isset( $fields[ $field ]['type'] ) ) ? $fields[ $field ]['type'] : 'native'; // @todo Is this needed? It seems to set the type to "native" if not set. $result = $user_info->{$field}; @@ -522,11 +522,9 @@ function wpmem_sc_fields( $atts, $content = null, $tag ) { return do_shortcode( $result ); } - // Handle textarea fields (this needs to return right away to skip htmlspecialchars()). - // @todo Run htmlspecialchars() earlier so we don't have to do it on return. + // Handle line breaks for textarea fields if ( isset( $field_type ) && 'textarea' == $field_type ) { - $result = htmlentities( $user_info->{$field} ); - return ( $content ) ? do_shortcode( nl2br( $result ) . $content ) : do_shortcode( nl2br( $result ) ); + $result = nl2br( $user_info->{$field} ); } // Remove underscores from value if requested (default: on). @@ -536,7 +534,7 @@ function wpmem_sc_fields( $atts, $content = null, $tag ) { $content = ( $content ) ? $result . $content : $result; - return do_shortcode( htmlspecialchars( $content ) ); + return do_shortcode( $content ); } return; } From 90d0c7b28fcb3f6c54be3a851a4c21dbf102b393 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 26 May 2017 17:02:10 -0500 Subject: [PATCH 0626/1694] fixed issues with user profile (non-admin) file display/upload --- admin/includes/class-wp-members-admin-api.php | 3 +-- inc/class-wp-members.php | 1 + inc/users.php | 6 +++--- wp-members.php | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/admin/includes/class-wp-members-admin-api.php b/admin/includes/class-wp-members-admin-api.php index 79ed3428..15fe46fd 100644 --- a/admin/includes/class-wp-members-admin-api.php +++ b/admin/includes/class-wp-members-admin-api.php @@ -92,7 +92,6 @@ function load_dependencies() { if ( current_user_can( $permissions['users'] ) ) { require_once( WPMEM_PATH . 'admin/users.php' ); require_once( WPMEM_PATH . 'admin/user-profile.php' ); - require_once( WPMEM_PATH . 'inc/users.php' ); } if ( current_user_can( $permissions['options'] ) ) { require_once( WPMEM_PATH . 'admin/tab-options.php' ); @@ -127,7 +126,7 @@ function load_hooks() { add_action( 'wpmem_admin_do_tab', 'wpmem_a_about_tab', 999, 1 ); // If user has a role that cannot edit users, set profile actions for non-admins. - if ( ! current_user_can( 'edit_users' ) ) { + if ( ! current_user_can( 'edit_users' ) ) { // User actions and filters. add_action( 'user_edit_form_tag', 'wpmem_user_profile_multipart' ); add_action( 'show_user_profile', 'wpmem_user_profile' ); diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index baead661..3d87be69 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -431,6 +431,7 @@ function load_dependencies() { require_once( WPMEM_PATH . 'inc/sidebar.php' ); require_once( WPMEM_PATH . 'inc/shortcodes.php' ); require_once( WPMEM_PATH . 'inc/email.php' ); + require_once( WPMEM_PATH . 'inc/users.php' ); require_once( WPMEM_PATH . 'inc/deprecated.php' ); } diff --git a/inc/users.php b/inc/users.php index 635bbcdd..b150bc8f 100644 --- a/inc/users.php +++ b/inc/users.php @@ -26,7 +26,7 @@ */ function wpmem_user_profile() { - global $wpmem, $user_id; + global $wpmem, $user_id, $current_screen; /** * Filter the heading for the user profile additional fields. * @@ -69,9 +69,9 @@ function wpmem_user_profile() { $attachment_url = wp_get_attachment_url( $val ); $empty_file = '' . __( 'None' ) . ''; if ( 'file' == $field['type'] ) { - $input = ( 0 < $attachment_url ) ? '' . $attachment_url . '' : $empty_file; + $input = ( $attachment_url ) ? '' . $attachment_url . '' : $empty_file; } else { - $input = ( 0 < $attachment_url ) ? '' : $empty_file; + $input = ( $attachment_url ) ? '' : $empty_file; } $input.= '
    ' . $wpmem->get_text( 'profile_upload' ) . '
    '; $input.= wpmem_form_field( array( diff --git a/wp-members.php b/wp-members.php index 56329d09..d1518fd3 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.1.8 Beta RC 3 +Version: 3.1.8 Beta RC 4 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.1.8 RC 3' ); +define( 'WPMEM_VERSION', '3.1.8 RC 4' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From a832ecb056a2688166ce4b341daf8e714a67086f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 30 May 2017 17:39:52 -0500 Subject: [PATCH 0627/1694] set legend tag width in default stylesheet --- css/generic-no-float.css | 1 + 1 file changed, 1 insertion(+) diff --git a/css/generic-no-float.css b/css/generic-no-float.css index 9c9d6c49..fe1b4747 100644 --- a/css/generic-no-float.css +++ b/css/generic-no-float.css @@ -150,6 +150,7 @@ see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ line-height: 1; font-weight: 700; margin-bottom: 10px; + width: 100%; } #wpmem_reg .form, #wpmem_login .form { From 1784d51edaec86bbdb534397474a25e68a3876f5 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 30 May 2017 17:41:41 -0500 Subject: [PATCH 0628/1694] set for 3.1.8 release --- readme.txt | 3 +-- wp-members.php | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/readme.txt b/readme.txt index 8a9798da..5df53ca4 100644 --- a/readme.txt +++ b/readme.txt @@ -112,8 +112,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.1.7 is a major update. There are no database changes (rollback is possible). See changelog for important details. Minimum WP version is 3.6. -WP-Members 3.1.7.1 is a minor update, changing only the default for wpmem_current_url(). +WP-Members 3.1.8 is a major update. There are no database changes (rollback is possible). See changelog for important details. Minimum WP version is 3.6. == Screenshots == diff --git a/wp-members.php b/wp-members.php index d1518fd3..428bb89e 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.1.8 Beta RC 4 +Version: 3.1.8 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.1.8 RC 4' ); +define( 'WPMEM_VERSION', '3.1.8' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From eedef2cd24886ff5b478030624c273709b312cec Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 1 Jun 2017 17:59:08 -0500 Subject: [PATCH 0629/1694] fixes issue with textarea field data (defaulting to bio field), and offers alternative for displaying linebreaks with shortcode --- inc/class-wp-members-forms.php | 2 +- inc/shortcodes.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 875a2c58..035e7a0b 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -777,7 +777,7 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { switch ( $meta_key ) { case( 'description' ): case( 'textarea' == $field['type'] ): - $val = get_user_meta( $userdata->ID, 'description', 'true' ); // esc_textarea() is run when field is created. + $val = get_user_meta( $userdata->ID, $meta_key, 'true' ); // esc_textarea() is run when field is created. break; case 'user_email': diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 7a1790be..8d2033f4 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -524,7 +524,7 @@ function wpmem_sc_fields( $atts, $content = null, $tag ) { // Handle line breaks for textarea fields if ( isset( $field_type ) && 'textarea' == $field_type ) { - $result = nl2br( $user_info->{$field} ); + $result = ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) ? $user_info->{$field} : nl2br( $user_info->{$field} ); } // Remove underscores from value if requested (default: on). From eee629c6d3f162d2e4810d22a3dbf311f75935dd Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 1 Jun 2017 17:59:35 -0500 Subject: [PATCH 0630/1694] tag as 3.1.8.1 to fix text area issue --- readme.txt | 8 +++++++- wp-members.php | 4 ++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/readme.txt b/readme.txt index 5df53ca4..4c2017fc 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.6 Tested up to: 4.7 -Stable tag: 3.1.8 +Stable tag: 3.1.8.1 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -113,6 +113,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == WP-Members 3.1.8 is a major update. There are no database changes (rollback is possible). See changelog for important details. Minimum WP version is 3.6. +WP-Members 3.1.8.1 corrects a minor issue for text area fields. See changelog. == Screenshots == @@ -135,6 +136,11 @@ WP-Members 3.1.8 is a major update. There are no database changes (rollback is p == Changelog == += 3.1.8.1 = + +* Corrects an issue with user profile display/update of textarea fields that are not the WP default bio field. +* Added display=raw attribute handling to textarea fields to allow display without converting line breaks to HTML br tags. + = 3.1.8 = * Added new native registration handling to accommodate WooCommerce 3.0. diff --git a/wp-members.php b/wp-members.php index 428bb89e..6438b882 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.1.8 +Version: 3.1.8.1 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.1.8' ); +define( 'WPMEM_VERSION', '3.1.8.1' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 3259ea83649c2b3ae0dc32ae4392278ed4fa237a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 5 Jun 2017 10:56:05 -0500 Subject: [PATCH 0631/1694] fixes issue with user profile edit form heading to use get_text() value --- inc/shortcodes.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 8d2033f4..872e28f6 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -333,7 +333,7 @@ function wpmem_sc_user_profile( $atts, $content, $tag ) { * * @param string The default edit mode heading. */ - $heading = apply_filters( 'wpmem_user_edit_heading', __( 'Edit Your Information', 'wp-members' ) ); + $heading = apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); switch( $wpmem->action ) { From f22a34d2e3f2b65c7b0a22d9a8fdd3b3a3d7033a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 5 Jun 2017 10:56:37 -0500 Subject: [PATCH 0632/1694] improve logic for show register link in login form when login page is not set --- inc/class-wp-members-forms.php | 16 ++++++++++++++-- readme.txt | 2 ++ 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 035e7a0b..65644d40 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -534,8 +534,20 @@ function login_form( $page, $arr ) { * display the register form, and the current page is not the login * page, then do not add the register link, otherwise add the link. */ - $form = ( 'register' == $key && 1 == $wpmem->show_reg[ get_post_type( get_the_ID() ) ] && wpmem_current_url() != wpmem_login_url() ) ? $form : $form . $link; - //$form = ( 'register' == $key && isset( $wpmem->user_pages['profile'] ) && ( wpmem_current_url() == $wpmem->user_pages['profile'] ) && 1 == $wpmem->show_reg[ get_post_type( get_the_ID() ) ] ) ? $form : $form . $link; + if ( 'register' == $key ) { + if ( isset( $wpmem->user_pages['login'] ) && $wpmem->user_pages['login'] != '' ) { + $form = ( 1 == $wpmem->show_reg[ get_post_type( get_the_ID() ) ] && wpmem_current_url() != wpmem_login_url() ) ? $form : $form . $link; + } else { + global $post; + if ( has_shortcode( $post->post_content, 'wpmem_profile' ) ) { + $form = $form; + } else { + $form = ( 1 == $wpmem->show_reg[ get_post_type( get_the_ID() ) ] && ! has_shortcode( $post->post_content, 'wpmem_form' ) ) ? $form : $form . $link; + } + } + } else { + $form = $form . $link; + } } } diff --git a/readme.txt b/readme.txt index 4c2017fc..826a8834 100644 --- a/readme.txt +++ b/readme.txt @@ -140,6 +140,8 @@ WP-Members 3.1.8.1 corrects a minor issue for text area fields. See changelog. * Corrects an issue with user profile display/update of textarea fields that are not the WP default bio field. * Added display=raw attribute handling to textarea fields to allow display without converting line breaks to HTML br tags. +* Fixes issue with User Profile form heading not using the get_text() value. +* Improves logic for displaying register link in login form if login page is not set. = 3.1.8 = From 2c7602cb6bbdf084a0612d3ce85b634073fb3ec3 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 5 Jun 2017 10:57:25 -0500 Subject: [PATCH 0633/1694] add get_field_display_value() to api class --- inc/class-wp-members-api.php | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/inc/class-wp-members-api.php b/inc/class-wp-members-api.php index 6756d1f3..4e06c2fd 100644 --- a/inc/class-wp-members-api.php +++ b/inc/class-wp-members-api.php @@ -62,6 +62,37 @@ function get_select_display_values( $meta_key ) { } return $display_values; } + + /** + * Gets the display/label value of a field. + * + * @since 3.1.8 + * + * @param string $meta The field meta key. + * @param string $user_id The user's ID. + * @param string $value The field's value, if given. + * @return string $value The display value. + */ + function get_field_display_value( $meta, $user_id, $value = null ) { + global $wpmem; + $fields = ( isset( $wpmem->fields ) ) ? $wpmem->fields : wpmem_fields(); + $field = $fields[ $meta ]; + $value = ( $value ) ? $value : get_user_meta( $user_id, $meta, true ); + switch ( $field['type'] ) { + case 'multiselect': + case 'multicheckbox': + break; + case 'select': + case 'radio': + $value = $fields[ $meta ]['options'][ $value ]; + break; + case 'image': + case 'file': + $value = wp_get_attachment_url( $value ); + break; + } + return $value; + } /** * Checks that a given user field value is unique. From 01b7e6843a64b24d0e7ddaed5d787e0aa1dc2669 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 21 Jun 2017 08:06:40 -0500 Subject: [PATCH 0634/1694] add new user search class to allow users > all users screen to search by meta --- admin/includes/class-wp-members-admin-api.php | 3 + .../includes/class-wp-members-user-search.php | 215 ++++++++++++++++++ uninstall.php | 5 + 3 files changed, 223 insertions(+) create mode 100644 admin/includes/class-wp-members-user-search.php diff --git a/admin/includes/class-wp-members-admin-api.php b/admin/includes/class-wp-members-admin-api.php index 15fe46fd..521d24f4 100644 --- a/admin/includes/class-wp-members-admin-api.php +++ b/admin/includes/class-wp-members-admin-api.php @@ -57,6 +57,8 @@ function __construct() { // Load default dialogs. $dialogs = $this->default_dialogs(); + + $this->user_search = new WP_Members_Admin_User_Search(); } /** @@ -92,6 +94,7 @@ function load_dependencies() { if ( current_user_can( $permissions['users'] ) ) { require_once( WPMEM_PATH . 'admin/users.php' ); require_once( WPMEM_PATH . 'admin/user-profile.php' ); + require_once( WPMEM_PATH . 'admin/includes/class-wp-members-user-search.php' ); } if ( current_user_can( $permissions['options'] ) ) { require_once( WPMEM_PATH . 'admin/tab-options.php' ); diff --git a/admin/includes/class-wp-members-user-search.php b/admin/includes/class-wp-members-user-search.php new file mode 100644 index 00000000..04288403 --- /dev/null +++ b/admin/includes/class-wp-members-user-search.php @@ -0,0 +1,215 @@ +get_search_terms(); + $meta_keys = $this->get_meta_keys(); + + // Are we performing an AND (default) or an OR? + $search_with_or = in_array( 'or', $terms ); + + if ( $search_with_or ) { + // Remove the OR keyword(s) from the terms + $terms = array_diff( $terms, array( 'or', 'and' ) ); + + // Reset the array keys + $terms = array_values( $terms ); + } + + // We use a permanent table because you cannot reference MySQL temporary tables more than once per query + $mktable = "{$wpdb->prefix}wpmembers_user_search_keys"; + + // Create our table to store the meta keys + $wpdb->query( $sql = "CREATE TABLE IF NOT EXISTS {$mktable} (meta_key VARCHAR(255) NOT NULL);" ); + + // Empty the table to ensure that we have an accurate set of meta keys + $wpdb->query( $sql = "TRUNCATE TABLE {$mktable};" ); + + // Insert the meta keys into our table + $prepare_values_array = array_fill( 0, count( $meta_keys ), '(%s)' ); + $prepare_values = implode( ", ", $prepare_values_array ); // Add "\n\t\t\t\t\t\t" after the comma for easier debugging + + $insert_sql = $wpdb->prepare( " + INSERT INTO {$mktable} + (meta_key) + VALUES + {$prepare_values}; + ", $meta_keys ); + + $wpdb->query( $insert_sql ); + + // Build our data for $wpdb->prepare + $values = array(); + + // Make sure we replicate each term XX number of times (refer to query below for correct number) + foreach ( $terms as $term ) { + for ( $i = 0; $i < 6; $i++ ) { + $values[] = "%{$term}%"; + } + } + + // Our last value is for HAVING COUNT(*), so let's add that + // Note the min count is 1 if we found OR in the terms + $values[] = ( $search_with_or !== false ? 1 : count( $terms ) ); + + // Query for matching users + $user_ids = $wpdb->get_col( $sql = $wpdb->prepare( " + SELECT user_id + FROM (" . implode( 'UNION ALL', array_fill( 0, count( $terms ), " + SELECT DISTINCT u.ID AS user_id + FROM {$wpdb->users} u + INNER JOIN {$wpdb->usermeta} um + ON um.user_id = u.ID + INNER JOIN {$mktable} mk + ON mk.meta_key = um.meta_key + WHERE LOWER(um.meta_value) LIKE %s + OR LOWER(u.user_login) LIKE %s + OR LOWER(u.user_nicename) LIKE %s + OR LOWER(u.user_email) LIKE %s + OR LOWER(u.user_url) LIKE %s + OR LOWER(u.display_name) LIKE %s + " ) ) . ") AS user_search_union + GROUP BY user_id + HAVING COUNT(*) >= %d; + ", $values ) ); + + // Change query to include our new user IDs + if ( is_array( $user_ids ) && count( $user_ids ) ) { + // Combine the IDs into a comma separated list + $id_string = implode( ',', $user_ids ); + + // Build the SQL we are adding to the query + $extra_sql = " OR ID IN ({$id_string})"; + + // @dale3h 2016/01/28 21:51:00 - Admin Columns Pro fix + $add_after = 'WHERE '; + $add_position = strpos( $user_query->query_where, $add_after ) + strlen( $add_after ); + + // Add the query to the end, after wrapping the rest in parenthesis + $user_query->query_where = substr( $user_query->query_where, 0, $add_position ) . '(' . substr( $user_query->query_where, $add_position ) . ')' . $extra_sql; + } + } + + /** + * Get array of user search terms. + * + * @since 3.1.9 + * + * @return array $terms + */ + public function get_search_terms() { + // Get the WordPress search term(s) + $terms = ( wpmem_get( 's', false, 'get' ) ) ? trim( strtolower( stripslashes( $_GET['s'] ) ) ) : false; + + // Bail out if we cannot find any search term(s) + if ( empty( $terms ) ) { + return array(); + } + + // Split terms by space into an array + $terms = explode( ' ', $terms ); + + // Remove empty terms + foreach ( $terms as $key => $term ) { + if ( empty( $term ) ) { + unset( $terms[ $key ] ); + } + } + + // Reset the array keys + $terms = array_values( $terms ); + + // Return the array of terms + return $terms; + } + + /** + * Get meta keys for query. + * + * @since 3.1.9 + * + * @return array $meta_keys + */ + public function get_meta_keys() { + // Get the meta keys from the settings + $meta_keys = get_option( 'wpmembers_utkeys', $this->get_default_meta_keys() ); + + // Make it an array if it isn't one already + if ( ! is_array( $meta_keys ) ) { + $meta_keys = ! empty( $meta_keys ) ? array( $meta_keys ) : array(); + } + + // Return the meta keys + return $meta_keys; + } + + /** + * Generate default meta keys. + * + * @since 3.1.9 + * + * @return array $meta_keys + */ + public function get_default_meta_keys() { + return array( + 'first_name', + 'last_name', + ); + } +} \ No newline at end of file diff --git a/uninstall.php b/uninstall.php index bc3b5ab7..7511f9c1 100644 --- a/uninstall.php +++ b/uninstall.php @@ -54,6 +54,7 @@ function wpmem_uninstall_options() { delete_option( 'wpmembers_tos' ); delete_option( 'wpmembers_export' ); delete_option( 'wpmembers_utfields' ); + delete_option( 'wpmembers_utkeys' ); delete_option( 'wpmembers_email_newreg' ); delete_option( 'wpmembers_email_newmod' ); @@ -75,6 +76,10 @@ function wpmem_uninstall_options() { delete_option( 'wpmembers_style' ); delete_option( 'wpmembers_autoex' ); delete_option( 'wpmembers_attrib' ); + + // Drop user meta key search table. + global $wpdb; + $wpdb->query( "DROP TABLE IF EXISTS {$wpdb->prefix}wpmembers_user_search_keys" ); } // End of file. \ No newline at end of file From 743966c5d28dd864bea5bdc3e32ac498b8cd9a07 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 21 Jun 2017 09:14:45 -0500 Subject: [PATCH 0635/1694] set 3.1.9 development version --- wp-members.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-members.php b/wp-members.php index 6438b882..800d40ce 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: http://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.1.8.1 +Version: 3.1.9.a Development Version Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -62,7 +62,7 @@ // Initialize constants. -define( 'WPMEM_VERSION', '3.1.8.1' ); +define( 'WPMEM_VERSION', '3.1.9.a' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From eef77faeef5b249aef2622618a0259dcca31ceaa Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 22 Jun 2017 15:13:05 -0500 Subject: [PATCH 0636/1694] recaptcha v1 fully obsolete, removing library due to php 7.1 compatibility issues --- admin/tab-options.php | 2 +- inc/register.php | 54 ++------ lib/recaptchalib.php | 277 ----------------------------------------- wp-members-install.php | 7 +- 4 files changed, 17 insertions(+), 323 deletions(-) delete mode 100644 lib/recaptchalib.php diff --git a/admin/tab-options.php b/admin/tab-options.php index 7f9ddb3f..7a503742 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -177,7 +177,7 @@ function wpmem_a_build_options() { captcha ) { - $captcha[] = 'reCAPTCHA v1 (deprecated)|1'; + $wpmem->captcha = 3; // @todo reCAPTCHA v1 is fully obsolete. Change it to v2. } $captcha[] = __( 'reCAPTCHA', 'wp-members' ) . '|3'; $captcha[] = __( 'Really Simple CAPTCHA', 'wp-members' ) . '|2'; diff --git a/inc/register.php b/inc/register.php index 2c789907..5a5e9f2a 100644 --- a/inc/register.php +++ b/inc/register.php @@ -449,52 +449,18 @@ function wpmem_register_handle_captcha() { // Get the captcha settings (api keys). $wpmem_captcha = get_option( 'wpmembers_captcha' ); - + + /* + * @todo reCAPTCHA v1 is deprecated by Google. It is also no longer allowed + * to be set for new installs of WP-Members. It is NOT compatible with + * PHP 7.1 and is therefore fully obsolete. + */ // If captcha is on, check the captcha. if ( $wpmem->captcha == 1 && $wpmem_captcha['recaptcha'] ) { - - // If there is no api key, the captcha never displayed to the end user. - if ( $wpmem_captcha['recaptcha']['public'] && $wpmem_captcha['recaptcha']['private'] ) { - if ( ! $_POST["recaptcha_response_field"] ) { // validate for empty captcha field - $wpmem_themsg = $wpmem->get_text( 'reg_empty_captcha' ); - return "empty"; - } - } - - // Check to see if the recaptcha library has already been loaded by another plugin. - if ( ! function_exists( '_recaptcha_qsencode' ) ) { - require_once( WPMEM_PATH . 'lib/recaptchalib.php' ); - } - - $publickey = $wpmem_captcha['recaptcha']['public']; - $privatekey = $wpmem_captcha['recaptcha']['private']; - - // The response from reCAPTCHA. - $resp = null; - // The error code from reCAPTCHA, if any. - $error = null; - - if ( $_POST["recaptcha_response_field"] ) { - - $resp = recaptcha_check_answer ( - $privatekey, - $_SERVER["REMOTE_ADDR"], - $_POST["recaptcha_challenge_field"], - $_POST["recaptcha_response_field"] - ); - - if ( ! $resp->is_valid ) { - - // Set the error code so that we can display it. - global $wpmem_captcha_err; - $wpmem_captcha_err = $resp->error; - $wpmem_captcha_err = wpmem_get_captcha_err( $wpmem_captcha_err ); - - return "captcha"; - - } - } // End check recaptcha. - } elseif ( $wpmem->captcha == 2 ) { + $wpmem->captcha = 3; + } + + if ( $wpmem->captcha == 2 ) { if ( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { // Validate Really Simple Captcha. $wpmem_captcha = new ReallySimpleCaptcha(); diff --git a/lib/recaptchalib.php b/lib/recaptchalib.php deleted file mode 100644 index 6246fd4c..00000000 --- a/lib/recaptchalib.php +++ /dev/null @@ -1,277 +0,0 @@ - $value ) - $req .= $key . '=' . urlencode( stripslashes($value) ) . '&'; - - // Cut the last '&' - $req=substr($req,0,strlen($req)-1); - return $req; -} - - - -/** - * Submits an HTTP POST to a reCAPTCHA server - * @param string $host - * @param string $path - * @param array $data - * @param int port - * @return array response - */ -function _recaptcha_http_post($host, $path, $data, $port = 80) { - - $req = _recaptcha_qsencode ($data); - - $http_request = "POST $path HTTP/1.0\r\n"; - $http_request .= "Host: $host\r\n"; - $http_request .= "Content-Type: application/x-www-form-urlencoded;\r\n"; - $http_request .= "Content-Length: " . strlen($req) . "\r\n"; - $http_request .= "User-Agent: reCAPTCHA/PHP\r\n"; - $http_request .= "\r\n"; - $http_request .= $req; - - $response = ''; - if( false == ( $fs = @fsockopen($host, $port, $errno, $errstr, 10) ) ) { - die ('Could not open socket'); - } - - fwrite($fs, $http_request); - - while ( !feof($fs) ) - $response .= fgets($fs, 1160); // One TCP-IP packet - fclose($fs); - $response = explode("\r\n\r\n", $response, 2); - - return $response; -} - - - -/** - * Gets the challenge HTML (javascript and non-javascript version). - * This is called from the browser, and the resulting reCAPTCHA HTML widget - * is embedded within the HTML form it was called from. - * @param string $pubkey A public key for reCAPTCHA - * @param string $error The error given by reCAPTCHA (optional, default is null) - * @param boolean $use_ssl Should the request be made over ssl? (optional, default is false) - - * @return string - The HTML to be embedded in the user's form. - */ -function recaptcha_get_html ($pubkey, $error = null, $use_ssl = false) -{ - if ($pubkey == null || $pubkey == '') { - die ("To use reCAPTCHA you must get an API key from https://www.google.com/recaptcha/admin/create"); - } - - if ($use_ssl) { - $server = RECAPTCHA_API_SECURE_SERVER; - } else { - $server = RECAPTCHA_API_SERVER; - } - - $errorpart = ""; - if ($error) { - $errorpart = "&error=" . $error; - } - return ' - - '; -} - - - - -/** - * A WPMEM_ReCaptchaResponse is returned from recaptcha_check_answer() - */ -class WPMEM_ReCaptchaResponse { - var $is_valid; - var $error; -} - - -/** - * Calls an HTTP POST function to verify if the user's guess was correct - * @param string $privkey - * @param string $remoteip - * @param string $challenge - * @param string $response - * @param array $extra_params an array of extra variables to post to the server - * @return WPMEM_ReCaptchaResponse - */ -function recaptcha_check_answer ($privkey, $remoteip, $challenge, $response, $extra_params = array()) -{ - if ($privkey == null || $privkey == '') { - die ("To use reCAPTCHA you must get an API key from https://www.google.com/recaptcha/admin/create"); - } - - if ($remoteip == null || $remoteip == '') { - die ("For security reasons, you must pass the remote ip to reCAPTCHA"); - } - - - - //discard spam submissions - if ($challenge == null || strlen($challenge) == 0 || $response == null || strlen($response) == 0) { - $recaptcha_response = new WPMEM_ReCaptchaResponse(); - $recaptcha_response->is_valid = false; - $recaptcha_response->error = 'incorrect-captcha-sol'; - return $recaptcha_response; - } - - $response = _recaptcha_http_post (RECAPTCHA_VERIFY_SERVER, "/recaptcha/api/verify", - array ( - 'privatekey' => $privkey, - 'remoteip' => $remoteip, - 'challenge' => $challenge, - 'response' => $response - ) + $extra_params - ); - - $answers = explode ("\n", $response [1]); - $recaptcha_response = new WPMEM_ReCaptchaResponse(); - - if (trim ($answers [0]) == 'true') { - $recaptcha_response->is_valid = true; - } - else { - $recaptcha_response->is_valid = false; - $recaptcha_response->error = $answers [1]; - } - return $recaptcha_response; - -} - -/** - * gets a URL where the user can sign up for reCAPTCHA. If your application - * has a configuration page where you enter a key, you should provide a link - * using this function. - * @param string $domain The domain where the page is hosted - * @param string $appname The name of your application - */ -function recaptcha_get_signup_url ($domain = null, $appname = null) { - return "https://www.google.com/recaptcha/admin/create?" . _recaptcha_qsencode (array ('domains' => $domain, 'app' => $appname)); -} - -function _recaptcha_aes_pad($val) { - $block_size = 16; - $numpad = $block_size - (strlen ($val) % $block_size); - return str_pad($val, strlen ($val) + $numpad, chr($numpad)); -} - -/* Mailhide related code */ - -function _recaptcha_aes_encrypt($val,$ky) { - if (! function_exists ("mcrypt_encrypt")) { - die ("To use reCAPTCHA Mailhide, you need to have the mcrypt php module installed."); - } - $mode=MCRYPT_MODE_CBC; - $enc=MCRYPT_RIJNDAEL_128; - $val=_recaptcha_aes_pad($val); - return mcrypt_encrypt($enc, $ky, $val, $mode, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"); -} - - -function _recaptcha_mailhide_urlbase64 ($x) { - return strtr(base64_encode ($x), '+/', '-_'); -} - -/* gets the reCAPTCHA Mailhide url for a given email, public key and private key */ -function recaptcha_mailhide_url($pubkey, $privkey, $email) { - if ($pubkey == '' || $pubkey == null || $privkey == "" || $privkey == null) { - die ("To use reCAPTCHA Mailhide, you have to sign up for a public and private key, " . - "you can do so at http://www.google.com/recaptcha/mailhide/apikey"); - } - - - $ky = pack('H*', $privkey); - $cryptmail = _recaptcha_aes_encrypt ($email, $ky); - - return "http://www.google.com/recaptcha/mailhide/d?k=" . $pubkey . "&c=" . _recaptcha_mailhide_urlbase64 ($cryptmail); -} - -/** - * gets the parts of the email to expose to the user. - * eg, given johndoe@example,com return ["john", "example.com"]. - * the email is then displayed as john...@example.com - */ -function _recaptcha_mailhide_email_parts ($email) { - $arr = preg_split("/@/", $email ); - - if (strlen ($arr[0]) <= 4) { - $arr[0] = substr ($arr[0], 0, 1); - } else if (strlen ($arr[0]) <= 6) { - $arr[0] = substr ($arr[0], 0, 3); - } else { - $arr[0] = substr ($arr[0], 0, 4); - } - return $arr; -} - -/** - * Gets html to display an email address given a public an private key. - * to get a key, go to: - * - * http://www.google.com/recaptcha/mailhide/apikey - */ -function recaptcha_mailhide_html($pubkey, $privkey, $email) { - $emailparts = _recaptcha_mailhide_email_parts ($email); - $url = recaptcha_mailhide_url ($pubkey, $privkey, $email); - - return htmlentities($emailparts[0]) . "...@" . htmlentities ($emailparts [1]); - -} - - -?> diff --git a/wp-members-install.php b/wp-members-install.php index e31ff90a..5bd75e0b 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -84,6 +84,11 @@ function wpmem_upgrade_settings() { // If install is 3.0 or higher. if ( $is_three ) { + + // reCAPTCHA v1 is obsolete. + if ( isset( $wpmem_settings['captcha'] ) && 1 == $wpmem_settings['captcha'] ) { + $wpmem_settings['captcha'] = 3; + } // If old auto excerpt settings exists, update it. if ( isset( $wpmem_settings['autoex']['auto_ex'] ) ) { @@ -151,7 +156,7 @@ function wpmem_upgrade_settings() { ), 'notify' => $wpmem_settings[4], 'mod_reg' => $wpmem_settings[5], - 'captcha' => $wpmem_settings[6], + 'captcha' => ( 1 == $wpmem_settings[6] ) ? 3 : $wpmem_settings[6], // reCAPTCHA v1 is obsolete, move to v2. 'use_exp' => $wpmem_settings[9], 'use_trial' => $wpmem_settings[10], 'warnings' => $wpmem_settings[11], From 4c0405d23646e9147987534ec7b7ce92f4c11b8b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 22 Jun 2017 15:14:41 -0500 Subject: [PATCH 0637/1694] removing obsolete comments_template.php --- lib/comments_template.php | 7 ------- lib/index.php | 1 - 2 files changed, 8 deletions(-) delete mode 100644 lib/comments_template.php delete mode 100644 lib/index.php diff --git a/lib/comments_template.php b/lib/comments_template.php deleted file mode 100644 index a6e32ba6..00000000 --- a/lib/comments_template.php +++ /dev/null @@ -1,7 +0,0 @@ - Date: Fri, 23 Jun 2017 00:17:06 -0500 Subject: [PATCH 0638/1694] fix search class load for capability --- admin/includes/class-wp-members-admin-api.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/admin/includes/class-wp-members-admin-api.php b/admin/includes/class-wp-members-admin-api.php index 521d24f4..c5ee2e55 100644 --- a/admin/includes/class-wp-members-admin-api.php +++ b/admin/includes/class-wp-members-admin-api.php @@ -58,7 +58,9 @@ function __construct() { // Load default dialogs. $dialogs = $this->default_dialogs(); - $this->user_search = new WP_Members_Admin_User_Search(); + if ( current_user_can( 'edit_users' ) ) { + $this->user_search = new WP_Members_Admin_User_Search(); + } } /** From c169bbda3e2264201d3a0611d40b8891ad4358f6 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 23 Jun 2017 00:17:45 -0500 Subject: [PATCH 0639/1694] set image file type to display medium image on dashboard/admin profile --- admin/user-profile.php | 6 ++++-- inc/users.php | 4 +++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/admin/user-profile.php b/admin/user-profile.php index 690b89fe..69c0adc9 100644 --- a/admin/user-profile.php +++ b/admin/user-profile.php @@ -86,12 +86,14 @@ function wpmem_admin_fields() { // Is this an image or a file? if ( 'file' == $field['type'] || 'image' == $field['type'] ) { - $attachment_url = wp_get_attachment_url( $val ); $empty_file = '' . __( 'None' ) . ''; if ( 'file' == $field['type'] ) { + $attachment_url = wp_get_attachment_url( $val ); $input = ( $attachment_url ) ? '' . $attachment_url . '' : $empty_file; } else { - $input = ( $attachment_url ) ? '' : $empty_file; + $attachment_url = wp_get_attachment_image( $val, 'medium' ); + $edit_url = admin_url( 'upload.php?item=' . $val ); + $input = ( $attachment_url ) ? '' . $attachment_url . '' : $empty_file; } $input.= '
    ' . $wpmem->get_text( 'profile_upload' ) . '
    '; $input.= wpmem_form_field( array( diff --git a/inc/users.php b/inc/users.php index b150bc8f..9de7024f 100644 --- a/inc/users.php +++ b/inc/users.php @@ -69,9 +69,11 @@ function wpmem_user_profile() { $attachment_url = wp_get_attachment_url( $val ); $empty_file = '' . __( 'None' ) . ''; if ( 'file' == $field['type'] ) { + $attachment_url = wp_get_attachment_url( $val ); $input = ( $attachment_url ) ? '' . $attachment_url . '' : $empty_file; } else { - $input = ( $attachment_url ) ? '' : $empty_file; + $attachment_url = wp_get_attachment_image( $val, 'medium' ); + $input = ( $attachment_url ) ? $attachment_url : $empty_file; } $input.= '
    ' . $wpmem->get_text( 'profile_upload' ) . '
    '; $input.= wpmem_form_field( array( From f62820089230c342a96bfd353e51807248b2d1ee Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 23 Jun 2017 09:15:41 -0500 Subject: [PATCH 0640/1694] date field formatting default to wp setting, include 'format' attribute --- inc/shortcodes.php | 11 +++++++++++ readme.txt | 22 ++++++++++++++-------- 2 files changed, 25 insertions(+), 8 deletions(-) diff --git a/inc/shortcodes.php b/inc/shortcodes.php index 872e28f6..0871b833 100644 --- a/inc/shortcodes.php +++ b/inc/shortcodes.php @@ -527,6 +527,17 @@ function wpmem_sc_fields( $atts, $content = null, $tag ) { $result = ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) ? $user_info->{$field} : nl2br( $user_info->{$field} ); } + // Handle date fields. + if ( isset( $field_type ) && 'date' == $field_type ) { + if ( isset( $atts['format'] ) ) { + // Formats date: http://php.net/manual/en/function.date.php + $result = date( $atts['format'], strtotime( $user_info->{$field} ) ); + } else { + // Formats date to whatever the WP setting is. + $result = date_i18n( get_option( 'date_format' ), strtotime( $user_info->{$field} ) ); + } + } + // Remove underscores from value if requested (default: on). if ( isset( $atts['underscores'] ) && 'off' == $atts['underscores'] && $user_info ) { $result = str_replace( '_', ' ', $result ); diff --git a/readme.txt b/readme.txt index 826a8834..839007d2 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 3.6 Tested up to: 4.7 -Stable tag: 3.1.8.1 +Stable tag: 3.1.9 License: GPLv2 WP-Members™ is a free membership management framework for WordPress® that restricts content to registered users. @@ -112,8 +112,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.1.8 is a major update. There are no database changes (rollback is possible). See changelog for important details. Minimum WP version is 3.6. -WP-Members 3.1.8.1 corrects a minor issue for text area fields. See changelog. +WP-Members 3.1.9 is a major update. There are no database changes (rollback is possible). See changelog for important details. Minimum WP version is 3.6. == Screenshots == @@ -136,12 +135,14 @@ WP-Members 3.1.8.1 corrects a minor issue for text area fields. See changelog. == Changelog == -= 3.1.8.1 = += 3.1.9 = -* Corrects an issue with user profile display/update of textarea fields that are not the WP default bio field. -* Added display=raw attribute handling to textarea fields to allow display without converting line breaks to HTML br tags. -* Fixes issue with User Profile form heading not using the get_text() value. -* Improves logic for displaying register link in login form if login page is not set. +* Improved user search in Users > All Users. +* Fully deprecated obsolete reCAPTCHA v1. If v1 is selected as a setting, it will be automatically changed to v2. (v1 users check your API keys for compatibility.) +* Removed obsolete comments_template.php. +* Set image field to display "medium" image in dashboard/admin user profile. Admin profile image display links to media editor. +* Added default format to date field shortcode to date format set in WP settings. +* Added format attribute to date field shortcode for custom date formatting. = 3.1.8 = @@ -162,6 +163,11 @@ WP-Members 3.1.8.1 corrects a minor issue for text area fields. See changelog. * Fields Tab: added support for HTML5 field types: number, date. * Fields Tab: added support for HTML5 field attributes: placeholder, pattern (regex), title, min, max. +* Corrects an issue with user profile display/update of textarea fields that are not the WP default bio field. +* Added display=raw attribute handling to textarea fields to allow display without converting line breaks to HTML br tags. +* Fixes issue with User Profile form heading not using the get_text() value. +* Improves logic for displaying register link in login form if login page is not set. + = 3.1.7 = * API updates: added wpmem_is_user_activated(). From 33f675c420a491f3993a075a857ece0b186a24da Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 23 Jun 2017 12:47:36 -0500 Subject: [PATCH 0641/1694] added customizable user search meta fields in fields tab --- .../includes/class-wp-members-user-search.php | 17 +++++----- admin/tab-fields.php | 31 ++++++++++++------- uninstall.php | 2 +- 3 files changed, 30 insertions(+), 20 deletions(-) diff --git a/admin/includes/class-wp-members-user-search.php b/admin/includes/class-wp-members-user-search.php index 04288403..dc69e858 100644 --- a/admin/includes/class-wp-members-user-search.php +++ b/admin/includes/class-wp-members-user-search.php @@ -188,12 +188,13 @@ public function get_search_terms() { */ public function get_meta_keys() { // Get the meta keys from the settings - $meta_keys = get_option( 'wpmembers_utkeys', $this->get_default_meta_keys() ); - - // Make it an array if it isn't one already - if ( ! is_array( $meta_keys ) ) { - $meta_keys = ! empty( $meta_keys ) ? array( $meta_keys ) : array(); - } + $saved_keys = get_option( 'wpmembers_usfields', $this->get_default_meta_keys() ); + + // Setting is an array of meta_key => meta_value, need the key. + $meta_keys = array(); + foreach ( $saved_keys as $key => $val ) { + $meta_keys[] = $key; + } // Return the meta keys return $meta_keys; @@ -208,8 +209,8 @@ public function get_meta_keys() { */ public function get_default_meta_keys() { return array( - 'first_name', - 'last_name', + 'first_name' => __( 'First Name', 'wp-members' ), + 'last_name' => __( 'Last Name', 'wp-members' ), ); } } \ No newline at end of file diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 40335e00..77258779 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -387,6 +387,8 @@ function wpmem_a_render_fields_tab_field_table() { $wpmem_ut_fields_skip = array( 'user_email', 'confirm_email', 'password', 'confirm_password' ); $wpmem_ut_fields = get_option( 'wpmembers_utfields' ); + $wpmem_us_fields_skip = array( 'user_email', 'confirm_email', 'password', 'confirm_password' ); + $wpmem_us_fields = get_option( 'wpmembers_usfields' ); $wpmem_fields = get_option( 'wpmembers_fields', array() ); foreach ( $wpmem_fields as $key => $field ) { @@ -395,8 +397,8 @@ function wpmem_a_render_fields_tab_field_table() { if ( is_numeric( $key ) ) { $meta = $field[2]; - $ut_checked = ( ( $wpmem_ut_fields ) && ( in_array( $field[1], $wpmem_ut_fields ) ) ) ? $field[1] : ''; + $us_checked = ( ( $wpmem_us_fields ) && ( in_array( $field[1], $wpmem_us_fields ) ) ) ? $field[1] : ''; $field_items[] = array( 'order' => $field[0], 'label' => $field[1], @@ -406,7 +408,8 @@ function wpmem_a_render_fields_tab_field_table() { 'req' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_required", 'checkbox', 'y', $field[5] ) : '', //'profile' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_profile", 'checkbox', true, $field[6] ) : '', 'edit' => wpmem_fields_edit_link( $meta ), - 'userscrn' => ( ! in_array( $meta, $wpmem_ut_fields_skip ) ) ? wpmem_create_formfield( 'ut_fields[' . $meta . ']', 'checkbox', $field[1], $ut_checked ) : '', + 'userscrn' => ( ! in_array( $meta, $wpmem_ut_fields_skip ) ) ? wpmem_create_formfield( 'ut_fields[' . $meta . ']', 'checkbox', $field[1], $ut_checked ) : '', + 'usearch' => ( ! in_array( $meta, $wpmem_us_fields_skip ) ) ? wpmem_create_formfield( 'us_fields[' . $meta . ']', 'checkbox', $field[1], $us_checked ) : '', 'sort' => '', ); } @@ -428,18 +431,19 @@ function wpmem_a_render_fields_tab_field_table() { ); } } - + foreach ( $user_screen_items as $screen_item ) { $field_items[] = array( - 'label' => $screen_item['label'], - 'meta' => $screen_item['meta'], - 'type' => '', - 'display' => '', - 'req' => '', - 'profile' => '', - 'edit' => '', + 'label' => $screen_item['label'], + 'meta' => $screen_item['meta'], + 'type' => '', + 'display' => '', + 'req' => '', + 'profile' => '', + 'edit' => '', 'userscrn' => $screen_item['userscrn'], - 'sort' => '', + 'usearch' => '', + 'sort' => '', ); } @@ -506,6 +510,7 @@ function get_columns() { //'profile' => __( 'Profile Only', 'wp-members' ), 'edit' => __( 'Edit', 'wp-members' ), 'userscrn' => __( 'Users Screen', 'wp-members' ), + 'usearch' => __( 'Users Search', 'wp-members' ), 'sort' => '', ); } @@ -664,6 +669,10 @@ function wpmem_admin_fields_update() { // Update user table fields. $arr = ( isset( $_POST['ut_fields'] ) ) ? $_POST['ut_fields'] : ''; update_option( 'wpmembers_utfields', $arr ); + + // Update user search fields. + $arr = ( isset( $_POST['us_fields'] ) ) ? $_POST['us_fields'] : ''; + update_option( 'wpmembers_usfields', $arr ); // Update display/required settings foreach ( $wpmem_fields as $key => $field ) { diff --git a/uninstall.php b/uninstall.php index 7511f9c1..b08db3bd 100644 --- a/uninstall.php +++ b/uninstall.php @@ -54,7 +54,7 @@ function wpmem_uninstall_options() { delete_option( 'wpmembers_tos' ); delete_option( 'wpmembers_export' ); delete_option( 'wpmembers_utfields' ); - delete_option( 'wpmembers_utkeys' ); + delete_option( 'wpmembers_usfields' ); delete_option( 'wpmembers_email_newreg' ); delete_option( 'wpmembers_email_newmod' ); From 6c03e37677d8974a0f048d485747f55cc2f4d9d9 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 25 Jun 2017 21:51:22 -0500 Subject: [PATCH 0642/1694] stripslashes on new form field entries (placeholder, pattern, title) --- admin/tab-fields.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 77258779..a577504b 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -743,12 +743,12 @@ function wpmem_admin_fields_update() { $arr[6] = ( $us_option == 'user_nicename' || $us_option == 'display_name' || $us_option == 'nickname' ) ? 'y' : 'n'; if ( 'text' == $type || 'email' == $type || 'textarea' == $type || 'password' == $type || 'url' == $type || 'number' == $type || 'date' == $type ) { - $arr['placeholder'] = wpmem_get( 'add_placeholder' ); + $arr['placeholder'] = stripslashes( wpmem_get( 'add_placeholder' ) ); } if ( 'text' == $type || 'email' == $type || 'password' == $type || 'url' == $type || 'number' == $type || 'date' == $type ) { - $arr['pattern'] = wpmem_get( 'add_pattern' ); - $arr['title'] = wpmem_get( 'add_title' ); + $arr['pattern'] = stripslashes( wpmem_get( 'add_pattern' ) ); + $arr['title'] = stripslashes( wpmem_get( 'add_title' ) ); } if ( 'number' == $type || 'date' == $type ) { @@ -808,7 +808,7 @@ function wpmem_admin_fields_update() { } } } - $did_update = sprintf( __( '%s was updated', 'wp-members' ), $add_name ); + $did_update = sprintf( __( '%s was updated', 'wp-members' ), stripslashes( $add_name ) ); $did_update.= '

    « ' . __( 'Return to Fields Table', 'wp-members' ) . '

    '; } From 28bd96fa4e09e776fda4a5f797063eb2a4212eb8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 25 Jun 2017 21:53:25 -0500 Subject: [PATCH 0643/1694] switch "display?" field setting to "admin only" --- admin/tab-fields.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index a577504b..9eead166 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -216,8 +216,8 @@ function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key )
  • - - /> + + />
  • @@ -404,7 +404,7 @@ function wpmem_a_render_fields_tab_field_table() { 'label' => $field[1], 'meta' => $meta, 'type' => $field[3], - 'display' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_display", 'checkbox', 'y', $field[4] ) : '', + 'display' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_display", 'checkbox', 'y', ( ( 'y' == $field[4] ) ? 'n' : 'y' ) ) : '', //@todo Temporary data flip for "admin only"/"display?" checkbox change. 'req' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_required", 'checkbox', 'y', $field[5] ) : '', //'profile' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_profile", 'checkbox', true, $field[6] ) : '', 'edit' => wpmem_fields_edit_link( $meta ), @@ -505,7 +505,7 @@ function get_columns() { 'label' => __( 'Display Label', 'wp-members' ), 'meta' => __( 'Meta Key', 'wp-members' ), 'type' => __( 'Field Type', 'wp-members' ), - 'display' => __( 'Display?', 'wp-members' ), + 'display' => __( 'Admin Only', 'wp-members' ), 'req' => __( 'Required?', 'wp-members' ), //'profile' => __( 'Profile Only', 'wp-members' ), 'edit' => __( 'Edit', 'wp-members' ), @@ -681,7 +681,7 @@ function wpmem_admin_fields_update() { $wpmem_fields[ $key ][4] = 'y'; $wpmem_fields[ $key ][5] = 'y'; } else { - $wpmem_fields[ $key ][4] = ( wpmem_get( $meta_key . "_display" ) ) ? 'y' : ''; + $wpmem_fields[ $key ][4] = ( wpmem_get( $meta_key . "_display" ) ) ? '' : 'y'; // @todo Temporary flip $wpmem_fields[ $key ][5] = ( wpmem_get( $meta_key . "_required" ) ) ? 'y' : ''; } } @@ -738,7 +738,7 @@ function wpmem_admin_fields_update() { $arr[1] = stripslashes( wpmem_get( 'add_name' ) ); $arr[2] = $us_option; $arr[3] = $type; - $arr[4] = wpmem_get( 'add_display', 'n' ); + $arr[4] = wpmem_get( 'add_display', 'y' ); // @todo Temporary flip $arr[5] = wpmem_get( 'add_required', 'n' ); $arr[6] = ( $us_option == 'user_nicename' || $us_option == 'display_name' || $us_option == 'nickname' ) ? 'y' : 'n'; From 72c79a028726146e82c2d21bf99f70e74a734bec Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 26 Jun 2017 08:12:00 -0500 Subject: [PATCH 0644/1694] Revert "switch "display?" field setting to "admin only"" This reverts commit 28bd96fa4e09e776fda4a5f797063eb2a4212eb8. --- admin/tab-fields.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 9eead166..a577504b 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -216,8 +216,8 @@ function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key )
  • - - /> + + />
  • @@ -404,7 +404,7 @@ function wpmem_a_render_fields_tab_field_table() { 'label' => $field[1], 'meta' => $meta, 'type' => $field[3], - 'display' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_display", 'checkbox', 'y', ( ( 'y' == $field[4] ) ? 'n' : 'y' ) ) : '', //@todo Temporary data flip for "admin only"/"display?" checkbox change. + 'display' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_display", 'checkbox', 'y', $field[4] ) : '', 'req' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_required", 'checkbox', 'y', $field[5] ) : '', //'profile' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_profile", 'checkbox', true, $field[6] ) : '', 'edit' => wpmem_fields_edit_link( $meta ), @@ -505,7 +505,7 @@ function get_columns() { 'label' => __( 'Display Label', 'wp-members' ), 'meta' => __( 'Meta Key', 'wp-members' ), 'type' => __( 'Field Type', 'wp-members' ), - 'display' => __( 'Admin Only', 'wp-members' ), + 'display' => __( 'Display?', 'wp-members' ), 'req' => __( 'Required?', 'wp-members' ), //'profile' => __( 'Profile Only', 'wp-members' ), 'edit' => __( 'Edit', 'wp-members' ), @@ -681,7 +681,7 @@ function wpmem_admin_fields_update() { $wpmem_fields[ $key ][4] = 'y'; $wpmem_fields[ $key ][5] = 'y'; } else { - $wpmem_fields[ $key ][4] = ( wpmem_get( $meta_key . "_display" ) ) ? '' : 'y'; // @todo Temporary flip + $wpmem_fields[ $key ][4] = ( wpmem_get( $meta_key . "_display" ) ) ? 'y' : ''; $wpmem_fields[ $key ][5] = ( wpmem_get( $meta_key . "_required" ) ) ? 'y' : ''; } } @@ -738,7 +738,7 @@ function wpmem_admin_fields_update() { $arr[1] = stripslashes( wpmem_get( 'add_name' ) ); $arr[2] = $us_option; $arr[3] = $type; - $arr[4] = wpmem_get( 'add_display', 'y' ); // @todo Temporary flip + $arr[4] = wpmem_get( 'add_display', 'n' ); $arr[5] = wpmem_get( 'add_required', 'n' ); $arr[6] = ( $us_option == 'user_nicename' || $us_option == 'display_name' || $us_option == 'nickname' ) ? 'y' : 'n'; From 62c53bdb4c4b5374de5202754e35b68fb78acd0c Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 28 Jun 2017 10:34:35 -0500 Subject: [PATCH 0645/1694] update fields tab to check both page and tab --- admin/tab-fields.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index a577504b..7834be39 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -622,8 +622,7 @@ public function process_bulk_action() { */ add_action( 'admin_footer', 'wpmem_bulk_fields_action' ); function wpmem_bulk_fields_action() { - // if ( isset( $_GET['tab'] ) && $_GET['tab'] == 'fields' ) { - if ( isset( $_GET['tab'] ) && $_GET['tab'] == 'fields' ) { + if ( 'wpmem-settings' == wpmem_get( 'page', false, 'get' ) && 'fields' == wpmem_get( 'tab', false, 'get' ) ) { ?> Date: Mon, 13 Nov 2017 07:57:34 -0600 Subject: [PATCH 0714/1694] cleanup --- admin/post.php | 2 -- inc/api.php | 2 +- readme.txt | 15 +++++++++++---- 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/admin/post.php b/admin/post.php index f525461b..369c3fc0 100644 --- a/admin/post.php +++ b/admin/post.php @@ -208,12 +208,10 @@ function wpmem_block_meta() { $block = 0; $notice_icon = ''; $notice_text = sprintf( __( '%s are blocked by default.', 'wp-members' ), $post_type->labels->name ); - $text = sprintf( __( 'Unblock this %s', 'wp-members' ), strtolower( $post_type->labels->singular_name ) ); } else { $block = 1; $notice_icon = ''; $notice_text = sprintf( __( '%s are not blocked by default.', 'wp-members' ), $post_type->labels->name ); - $text = sprintf( __( 'Block this %s', 'wp-members' ), strtolower( $post_type->labels->singular_name ) ); } $meta = '_wpmem_block'; $admin_url = get_admin_url(); ?> diff --git a/inc/api.php b/inc/api.php index c96729d8..2b57582d 100644 --- a/inc/api.php +++ b/inc/api.php @@ -221,7 +221,7 @@ function wpmem_form_field( $name, $type=null, $value=null, $valtochk=null, $clas * @global object $wpmem * @param array $args { * @type string $meta_key - * @type string $label_text + * @type string $label * @type string $type * @type string $class (optional) * @type string $required (optional) diff --git a/readme.txt b/readme.txt index 179d22be..ced9030e 100644 --- a/readme.txt +++ b/readme.txt @@ -1,8 +1,8 @@ === WP-Members Membership Plugin === Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber -Requires at least: 3.6 -Tested up to: 4.8 +Requires at least: 4.0 +Tested up to: 4.9 Stable tag: 3.2.0 License: GPLv2 @@ -110,7 +110,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == -WP-Members 3.1.9 is a major update. There are no database changes (rollback is possible). See changelog for important details. Minimum WP version is 3.6. +WP-Members 3.2.0 is a major update. See changelog for important details. Minimum WP version is 4.0. == Screenshots == @@ -136,7 +136,7 @@ WP-Members 3.1.9 is a major update. There are no database changes (rollback is p = 3.2.0 = * Changed default address meta fields to WooCommerce billing meta keys. -* Removed language packs that already install from wordpress.org (de_DE, hu_HU, ja, nl_NL, pt_BR, ru_RU, and sv_SE). +* Removed language packs that install from wordpress.org (de_DE, hu_HU, ja, nl_NL, pt_BR, ru_RU, and sv_SE). * Added wpmem_register_hidden_rows filter. * Added "post_to" key for wpmem_register_form_args. * Rebuild of user export function. User export now uses fputcsv. @@ -145,7 +145,14 @@ WP-Members 3.1.9 is a major update. There are no database changes (rollback is p * Updated empty $fields check to not rewrite fields. * Deprecated wpmem_inc_status(). * Deprecated wpmem_do_sidebar(). +* Deprecated wpmem_create_formfield(), use wpmem_form_field() instead. * Eliminated permission-based file load for admin files. +* Maintain user login state when password is changed. +* Added wpmem_get_sub_str() string manipulation utility. +* Updated login form redirect_to to account for query vars. +* Fixes issue with login status if logout url is encoded (sprintf() has too few arguments). +* Added Membership Products Custom Post Type. +* Added "Hide Post" option for blocking content (currently only by post meta _wpmem_block). = 3.1.9 = From df89597beb159cdcca69d49eec0ee2f88c18ec7c Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 16 Nov 2017 12:09:17 -0600 Subject: [PATCH 0715/1694] changed original cpt wpmem_mem_plan to wpmem_product --- admin/includes/class-wp-members-products-admin.php | 8 ++++---- admin/tab-options.php | 4 ++-- inc/class-wp-members-products.php | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/admin/includes/class-wp-members-products-admin.php b/admin/includes/class-wp-members-products-admin.php index 22e4e236..6eed9ecb 100644 --- a/admin/includes/class-wp-members-products-admin.php +++ b/admin/includes/class-wp-members-products-admin.php @@ -20,8 +20,8 @@ class WP_Members_Products_Admin { * @since 3.2.0 */ function __construct() { - add_filter( 'manage_wpmem_mem_plan_posts_columns', array( $this, 'columns_heading' ) ); - add_action( 'manage_wpmem_mem_plan_posts_custom_column', array( $this, 'columns_content' ), 10, 2 ); + add_filter( 'manage_wpmem_product_posts_columns', array( $this, 'columns_heading' ) ); + add_action( 'manage_wpmem_product_posts_custom_column', array( $this, 'columns_content' ), 10, 2 ); add_action( 'add_meta_boxes', array( $this, 'meta_boxes' ) ); add_action( 'save_post', array( $this, 'save_details' ) ); add_action( 'wpmem_admin_after_block_meta', array( $this, 'add_product_to_post' ), 10, 2 ); @@ -98,12 +98,12 @@ function get_meta( $value ) { * @since 3.2.0 */ function meta_boxes() { - remove_meta_box( 'slugdiv', 'wpmem_mem_plan', 'normal' ); + remove_meta_box( 'slugdiv', 'wpmem_product', 'normal' ); add_meta_box( 'membership_product', __( 'Membership Product Details', 'wp-members' ), array( $this, 'details_html' ), - 'wpmem_mem_plan', + 'wpmem_product', 'normal', 'high' ); diff --git a/admin/tab-options.php b/admin/tab-options.php index 948e77fc..8912739c 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -263,7 +263,7 @@ function wpmem_a_build_options() {
  • $val ) { - if ( 'post' != $key && 'page' != $key && 'wpmem_mem_plan' != $key ) { + if ( 'post' != $key && 'page' != $key && 'wpmem_product' != $key ) { $checked = ( isset( $wpmem->post_types ) && array_key_exists( $key, $wpmem->post_types ) ) ? ' checked' : ''; echo '
    '; } @@ -310,7 +310,7 @@ function wpmem_update_cpts() { if ( $post_types ) { foreach ( $post_types as $post_type ) { $cpt_obj = get_post_type_object( $post_type ); - if ( $cpt_obj->labels->name != 'wpmem_mem_plan' ) { + if ( $cpt_obj->labels->name != 'wpmem_product' ) { $post_arr[ $cpt_obj->name ] = $cpt_obj->labels->name; } } diff --git a/inc/class-wp-members-products.php b/inc/class-wp-members-products.php index 69a95cb3..32fd6661 100644 --- a/inc/class-wp-members-products.php +++ b/inc/class-wp-members-products.php @@ -31,7 +31,7 @@ function __construct() { function load_products() { global $wpdb; - $sql = "SELECT ID, post_title, post_name FROM " . $wpdb->prefix . "posts WHERE post_type = 'wpmem_mem_plan' AND post_status = 'publish';"; + $sql = "SELECT ID, post_title, post_name FROM " . $wpdb->prefix . "posts WHERE post_type = 'wpmem_product' AND post_status = 'publish';"; $result = $wpdb->get_results( $sql ); $this->products = array(); foreach ( $result as $plan ) { @@ -130,7 +130,7 @@ function add_cpt() { 'show_in_rest' => false, //'register_meta_box_cb' => '', // callback for meta box ); - register_post_type( 'wpmem_mem_plan', $args ); + register_post_type( 'wpmem_product', $args ); } } \ No newline at end of file From db6b7e60c9f9e8f8ec35de58c6dc250b49b8938e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 16 Nov 2017 12:10:39 -0600 Subject: [PATCH 0716/1694] moved widget init from core.php to sidebar.php --- inc/core.php | 14 -------------- inc/sidebar.php | 10 ++++++++++ 2 files changed, 10 insertions(+), 14 deletions(-) diff --git a/inc/core.php b/inc/core.php index 0ced1e95..e45d7f9e 100644 --- a/inc/core.php +++ b/inc/core.php @@ -133,20 +133,6 @@ function wpmem_logout( $redirect_to = false ) { endif; -if ( ! function_exists( 'widget_wpmemwidget_init' ) ): -/** - * Initializes the WP-Members widget. - * - * @since 2.0.0 - * @since 3.1.6 Dependencies now loaded by object. - */ -function widget_wpmemwidget_init() { - // Register the WP-Members widget. - register_widget( 'widget_wpmemwidget' ); -} -endif; - - if ( ! function_exists( 'wpmem_change_password' ) ): /** * Handles user password change (not reset). diff --git a/inc/sidebar.php b/inc/sidebar.php index 1748965b..d988fb9a 100644 --- a/inc/sidebar.php +++ b/inc/sidebar.php @@ -24,6 +24,16 @@ exit(); } +/** + * Initializes the WP-Members widget. + * + * @since 3.2.0 Replaces widget_wpmemwidget_init + */ +function wpmem_widget_init() { + // Register the WP-Members widget. + register_widget( 'widget_wpmemwidget' ); +} + if ( ! function_exists( 'wpmem_inc_status' ) ): /** * Generate users login status if logged in and gives logout link. From 6506518da7b450316fe15369df37fccc749c7dc3 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 16 Nov 2017 12:11:21 -0600 Subject: [PATCH 0717/1694] widget init to use sidebar.php method --- inc/class-wp-members.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 8f302089..f73206de 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -366,7 +366,7 @@ function load_hooks() { // Add actions. add_action( 'template_redirect', array( $this, 'get_action' ) ); - add_action( 'widgets_init', 'widget_wpmemwidget_init' ); // initializes the widget + add_action( 'widgets_init', 'wpmem_widget_init' ); // initializes the widget add_action( 'admin_init', array( $this, 'load_admin' ) ); // check user role to load correct dashboard add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu add_action( 'user_register', 'wpmem_wp_reg_finalize' ); // handles wp native registration From 3c32f1b3fbbd3a528b0982c7a3055a3424b636a8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 16 Nov 2017 12:13:17 -0600 Subject: [PATCH 0718/1694] moved native wp registration functions out of core to wp-registration.php --- inc/core.php | 99 ------------------------------------- inc/wp-registration.php | 107 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 107 insertions(+), 99 deletions(-) diff --git a/inc/core.php b/inc/core.php index e45d7f9e..2524d3c4 100644 --- a/inc/core.php +++ b/inc/core.php @@ -202,105 +202,6 @@ function wpmem_no_reset() { endif; -/** - * Add registration fields to the native WP registration. - * - * @since 2.8.3 - * @since 3.1.8 Added $process argument. - */ -function wpmem_wp_register_form( $process = 'wp' ) { - /** - * Load native WP registration functions. - */ - require_once( WPMEM_PATH . 'inc/wp-registration.php' ); - wpmem_do_wp_register_form( $process ); -} - - -/** - * Validates registration fields in the native WP registration. - * - * @since 2.8.3 - * - * @global object $wpmem The WP-Members object class. - * - * @param array $errors A WP_Error object containing any errors encountered during registration. - * @param string $sanitized_user_login User's username after it has been sanitized. - * @param string $user_email User's email. - * @return array $errors A WP_Error object containing any errors encountered during registration. - */ -function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) { - - global $wpmem; - - // Get any meta fields that should be excluded. - $exclude = wpmem_get_excluded_meta( 'register' ); - - foreach ( wpmem_fields( 'wp_validate' ) as $meta_key => $field ) { - $is_error = false; - if ( $field['required'] && $meta_key != 'user_email' && ! in_array( $meta_key, $exclude ) ) { - if ( ( $field['type'] == 'checkbox' || $field['type'] == 'multicheckbox' || $field['type'] == 'multiselect' || $field['type'] == 'radio' ) && ( ! isset( $_POST[ $meta_key ] ) ) ) { - $is_error = true; - } - if ( ( $field['type'] != 'checkbox' && $field['type'] != 'multicheckbox' && $field['type'] != 'multiselect' && $field['type'] != 'radio' ) && ( ! $_POST[ $meta_key ] ) ) { - $is_error = true; - } - if ( $is_error ) { $errors->add( 'wpmem_error', sprintf( $wpmem->get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ) ); } - } - } - - return $errors; -} - - -/** - * Inserts registration data from the native WP registration. - * - * @since 2.8.3 - * @since 3.1.1 Added new 3.1 field types and activate user support. - * - * @todo Compartmentalize file upload along with main register function. - * - * @global object $wpmem The WP-Members object class. - * @param int $user_id The WP user ID. - */ -function wpmem_wp_reg_finalize( $user_id ) { - - global $wpmem; - // Is this WP's native registration? Checks the native submit button. - $is_native = ( __( 'Register' ) == wpmem_get( 'wp-submit' ) ) ? true : false; - // Is this a Users > Add New process? Checks the post action. - $is_add_new = ( 'createuser' == wpmem_get( 'action' ) ) ? true : false; - // Is this a WooCommerce checkout registration? Checks for WC fields. - $is_woo = ( wpmem_get( 'woocommerce_checkout_place_order' ) || wpmem_get( 'woocommerce-register-nonce' ) ) ? true : false; - if ( $is_native || $is_add_new || $is_woo ) { - // Get any excluded meta fields. - $exclude = wpmem_get_excluded_meta( 'register' ); - foreach ( wpmem_fields( 'wp_finalize' ) as $meta_key => $field ) { - $value = wpmem_get( $meta_key, false ); - if ( $value && ! in_array( $meta_key, $exclude ) && 'file' != $field['type'] && 'image' != $field['type'] ) { - if ( 'multiselect' == $field['type'] || 'multicheckbox' == $field['type'] ) { - $value = implode( $field['delimiter'], $value ); - } - $sanitized_value = sanitize_text_field( $value ); - update_user_meta( $user_id, $meta_key, $sanitized_value ); - } - } - } - - // If this is Users > Add New. - if ( is_admin() && $is_add_new ) { - // If moderated registration and activate is checked, set active flags. - if ( 1 == $wpmem->mod_reg && isset( $_POST['activate_user'] ) ) { - update_user_meta( $user_id, 'active', 1 ); - wpmem_set_user_status( $user_id, 0 ); - } - } - - return; -} - - /** * Loads the stylesheet for backend registration. * diff --git a/inc/wp-registration.php b/inc/wp-registration.php index 6df9ea41..d867fdc9 100644 --- a/inc/wp-registration.php +++ b/inc/wp-registration.php @@ -284,4 +284,111 @@ function wpmem_do_wp_newuser_form() { echo '
    '; } + +/** + * Add registration fields to the native WP registration. + * + * @since 2.8.3 + * @since 3.1.8 Added $process argument. + */ +function wpmem_wp_register_form( $process = 'wp' ) { + /** + * Load native WP registration functions. + */ + require_once( WPMEM_PATH . 'inc/wp-registration.php' ); + wpmem_do_wp_register_form( $process ); +} + +/** + * Validates registration fields in the native WP registration. + * + * @since 2.8.3 + * + * @global object $wpmem The WP-Members object class. + * + * @param array $errors A WP_Error object containing any errors encountered during registration. + * @param string $sanitized_user_login User's username after it has been sanitized. + * @param string $user_email User's email. + * @return array $errors A WP_Error object containing any errors encountered during registration. + */ +function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) { + + global $wpmem; + + // Get any meta fields that should be excluded. + $exclude = wpmem_get_excluded_meta( 'register' ); + + foreach ( wpmem_fields( 'wp_validate' ) as $meta_key => $field ) { + $is_error = false; + if ( $field['required'] && $meta_key != 'user_email' && ! in_array( $meta_key, $exclude ) ) { + if ( ( $field['type'] == 'checkbox' || $field['type'] == 'multicheckbox' || $field['type'] == 'multiselect' || $field['type'] == 'radio' ) && ( ! isset( $_POST[ $meta_key ] ) ) ) { + $is_error = true; + } + if ( ( $field['type'] != 'checkbox' && $field['type'] != 'multicheckbox' && $field['type'] != 'multiselect' && $field['type'] != 'radio' ) && ( ! $_POST[ $meta_key ] ) ) { + $is_error = true; + } + if ( $is_error ) { $errors->add( 'wpmem_error', sprintf( $wpmem->get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ) ); } + } + } + + return $errors; +} + +/** + * Inserts registration data from the native WP registration. + * + * @since 2.8.3 + * @since 3.1.1 Added new 3.1 field types and activate user support. + * + * @todo Compartmentalize file upload along with main register function. + * + * @global object $wpmem The WP-Members object class. + * @param int $user_id The WP user ID. + */ +function wpmem_wp_reg_finalize( $user_id ) { + + global $wpmem; + // Is this WP's native registration? Checks the native submit button. + $is_native = ( __( 'Register' ) == wpmem_get( 'wp-submit' ) ) ? true : false; + // Is this a Users > Add New process? Checks the post action. + $is_add_new = ( 'createuser' == wpmem_get( 'action' ) ) ? true : false; + // Is this a WooCommerce checkout registration? Checks for WC fields. + $is_woo = ( wpmem_get( 'woocommerce_checkout_place_order' ) || wpmem_get( 'woocommerce-register-nonce' ) ) ? true : false; + if ( $is_native || $is_add_new || $is_woo ) { + // Get any excluded meta fields. + $exclude = wpmem_get_excluded_meta( 'register' ); + foreach ( wpmem_fields( 'wp_finalize' ) as $meta_key => $field ) { + $value = wpmem_get( $meta_key, false ); + if ( $value && ! in_array( $meta_key, $exclude ) && 'file' != $field['type'] && 'image' != $field['type'] ) { + if ( 'multiselect' == $field['type'] || 'multicheckbox' == $field['type'] ) { + $value = implode( $field['delimiter'], $value ); + } + $sanitized_value = sanitize_text_field( $value ); + update_user_meta( $user_id, $meta_key, $sanitized_value ); + } + } + } + + // If this is Users > Add New. + if ( is_admin() && $is_add_new ) { + // If moderated registration and activate is checked, set active flags. + if ( 1 == $wpmem->mod_reg && isset( $_POST['activate_user'] ) ) { + update_user_meta( $user_id, 'active', 1 ); + wpmem_set_user_status( $user_id, 0 ); + } + } + + return; +} + +/** + * Loads the stylesheet for backend registration. + * + * @since 2.8.7 + */ +function wpmem_wplogin_stylesheet() { + // @todo Should this enqueue styles? + echo ''; +} + // End of file. \ No newline at end of file From 06fab992e8a344681d0696c53db6cb1cdc492c04 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 16 Nov 2017 12:15:42 -0600 Subject: [PATCH 0719/1694] user functions in core moved to new methods in user object --- inc/class-wp-members-user.php | 57 +++++++++++++++++++++++++++++++++++ inc/core.php | 37 +++-------------------- 2 files changed, 61 insertions(+), 33 deletions(-) diff --git a/inc/class-wp-members-user.php b/inc/class-wp-members-user.php index d6a7c8a4..557d4300 100644 --- a/inc/class-wp-members-user.php +++ b/inc/class-wp-members-user.php @@ -507,4 +507,61 @@ function get_user_products( $user_id = false ) { function is_current( $date ) { return ( time() < strtotime( $date ) ) ? true : false; } + + /** + * Checks if a user is activated. + * + * @since 2.7.1 + * @since 3.2.0 Moved from core to user object. + * + * @param object $user The WordPress User object. + * @param string $username The user's username (user_login). + * @param string $password The user's password. + * @return object $user The WordPress User object. + */ + function check_activated( $user, $username, $password ) { + // Password must be validated. + $pass = ( ( ! is_wp_error( $user ) ) && $password ) ? wp_check_password( $password, $user->user_pass, $user->ID ) : false; + + if ( ! $pass ) { + return $user; + } + + // Activation flag must be validated. + if ( ! wpmem_is_user_activated( $user->ID ) ) { + return new WP_Error( 'authentication_failed', __( 'ERROR: User has not been activated.', 'wp-members' ) ); + } + + // If the user is validated, return the $user object. + return $user; + } + + /** + * Prevents users not activated from resetting their password. + * + * @since 2.5.1 + * @since 3.2.0 Moved to user object, renamed no_reset(). + * + * @return bool Returns false if the user is not activated, otherwise true. + */ + function no_reset() { + global $wpmem; + $raw_val = wpmem_get( 'user_login', false ); + if ( $raw_val ) { + if ( strpos( $raw_val, '@' ) ) { + $user = get_user_by( 'email', sanitize_email( $raw_val ) ); + } else { + $username = sanitize_user( $raw_val ); + $user = get_user_by( 'login', $username ); + } + if ( $wpmem->mod_reg == 1 ) { + if ( get_user_meta( $user->ID, 'active', true ) != 1 ) { + return false; + } + } + } + + return true; + } + } \ No newline at end of file diff --git a/inc/core.php b/inc/core.php index 2524d3c4..4feb8922 100644 --- a/inc/core.php +++ b/inc/core.php @@ -72,20 +72,8 @@ function wpmem_securify( $content = null ) { * @return object $user The WordPress User object. */ function wpmem_check_activated( $user, $username, $password ) { - - // Password must be validated. - $pass = ( ( ! is_wp_error( $user ) ) && $password ) ? wp_check_password( $password, $user->user_pass, $user->ID ) : false; - - if ( ! $pass ) { - return $user; - } - - // Activation flag must be validated. - if ( ! wpmem_is_user_activated( $user->ID ) ) { - return new WP_Error( 'authentication_failed', __( 'ERROR: User has not been activated.', 'wp-members' ) ); - } - - // If the user is validated, return the $user object. + global $wpmem; + $user = $wpmem->user->check_activated( $user, $username, $password ); return $user; } endif; @@ -174,30 +162,13 @@ function wpmem_reset_password() { * Prevents users not activated from resetting their password. * * @since 2.5.1 + * @since 3.2.0 Now a wrapper for $wpmem->user->no_reset(). * * @return bool Returns false if the user is not activated, otherwise true. */ function wpmem_no_reset() { - global $wpmem; - - $raw_val = wpmem_get( 'user_login', false ); - if ( $raw_val ) { - if ( strpos( $raw_val, '@' ) ) { - $user = get_user_by( 'email', sanitize_email( $raw_val ) ); - } else { - $username = sanitize_user( $raw_val ); - $user = get_user_by( 'login', $username ); - } - - if ( $wpmem->mod_reg == 1 ) { - if ( get_user_meta( $user->ID, 'active', true ) != 1 ) { - return false; - } - } - } - - return true; + return $wpmem->user->no_reset(); } endif; From 8e9ce11e3e2014f1a3187345a3905010f9502e47 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 16 Nov 2017 12:17:56 -0600 Subject: [PATCH 0720/1694] deprecated and replaced reg securify and some stylesheet functions --- inc/class-wp-members.php | 22 ++++++++++++++++- inc/core.php | 51 ---------------------------------------- inc/deprecated.php | 41 +++++++++++++++++++++++++++++++- 3 files changed, 61 insertions(+), 53 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index f73206de..88fd5fb7 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -383,7 +383,7 @@ function load_hooks() { add_action( 'woocommerce_register_form', 'wpmem_woo_register_form' ); add_filter( 'registration_errors', 'wpmem_wp_reg_validate', 10, 3 ); // native registration validation add_filter( 'comments_open', array( $this, 'do_securify_comments' ), 99 ); // securifies the comments - add_filter( 'wpmem_securify', 'wpmem_reg_securify' ); // adds success message on login form if redirected + add_filter( 'wpmem_securify', array( $this, 'reg_securify' ) ); // adds success message on login form if redirected add_filter( 'query_vars', array( $this, 'add_query_vars' ), 10, 2 ); // adds custom query vars add_filter( 'get_pages', array( $this, 'filter_get_pages' ) ); add_filter( 'wp_get_nav_menu_items', array( $this, 'filter_nav_menu_items' ), null, 3 ); @@ -511,6 +511,7 @@ function load_dependencies() { require_once( WPMEM_PATH . 'inc/sidebar.php' ); require_once( WPMEM_PATH . 'inc/shortcodes.php' ); require_once( WPMEM_PATH . 'inc/email.php' ); + include_once( WPMEM_PATH . 'inc/wp-registration.php' ); //require_once( WPMEM_PATH . 'inc/users.php' ); @deprecated 3.1.9 require_once( WPMEM_PATH . 'inc/deprecated.php' ); @@ -890,6 +891,25 @@ function do_securify_comments_array( $comments , $post_id ) { return $comments; } + /** + * Adds the successful registration message on the login page if reg_nonce validates. + * + * @since 3.1.7 + * @since 3.2.0 Moved to wpmem object, renamed reg_securify() + * + * @param string $content + * @return string $content + */ + function reg_securify( $content ) { + global $wpmem, $wpmem_themsg; + $nonce = wpmem_get( 'reg_nonce', false, 'get' ); + if ( $nonce && wp_verify_nonce( $nonce, 'register_redirect' ) ) { + $content = wpmem_inc_regmessage( 'success', $wpmem_themsg ); + $content = $content . wpmem_inc_login(); + } + return $content; + } + /** * Gets an array of hidden post IDs. * diff --git a/inc/core.php b/inc/core.php index 4feb8922..bd12ebe1 100644 --- a/inc/core.php +++ b/inc/core.php @@ -172,18 +172,6 @@ function wpmem_no_reset() { } endif; - -/** - * Loads the stylesheet for backend registration. - * - * @since 2.8.7 - */ -function wpmem_wplogin_stylesheet() { - // @todo Should this enqueue styles? - echo ''; -} - - /** * Handles retrieving a forgotten username. * @@ -200,43 +188,4 @@ function wpmem_retrieve_username() { return $wpmem->user->retrieve_username(); } - -/** - * Adds the successful registration message on the login page if reg_nonce validates. - * - * @since 3.1.7 - * - * @param string $content - * @return string $content - */ -function wpmem_reg_securify( $content ) { - global $wpmem, $wpmem_themsg; - $nonce = wpmem_get( 'reg_nonce', false, 'get' ); - if ( $nonce && wp_verify_nonce( $nonce, 'register_redirect' ) ) { - $content = wpmem_inc_regmessage( 'success', $wpmem_themsg ); - $content = $content . wpmem_inc_login(); - } - return $content; -} - - -/** - * Enqueues the admin javascript and css files. - * - * Replaces wpmem_admin_enqueue_scripts(). - * Only loads the js and css on admin screens that use them. - * - * @since 3.1.7 - * - * @param str $hook The admin screen hook being loaded. - */ -function wpmem_dashboard_enqueue_scripts( $hook ) { - if ( $hook == 'edit.php' || $hook == 'settings_page_wpmem-settings' ) { - wp_enqueue_style( 'wpmem-admin', WPMEM_DIR . 'admin/css/admin.css', '', WPMEM_VERSION ); - } - if ( $hook == 'settings_page_wpmem-settings' ) { - wp_enqueue_script( 'wpmem-admin', WPMEM_DIR . 'admin/js/admin.js', '', WPMEM_VERSION ); - } -} - // End of file. \ No newline at end of file diff --git a/inc/deprecated.php b/inc/deprecated.php index a4c11faf..c8d2833a 100644 --- a/inc/deprecated.php +++ b/inc/deprecated.php @@ -870,4 +870,43 @@ function wpmem_create_formfield( $name, $type, $value, $valtochk=null, $class='t ); return $wpmem->forms->create_form_field( $args ); } -endif; \ No newline at end of file +endif; + +/** + * Adds the successful registration message on the login page if reg_nonce validates. + * + * @since 3.1.7 + * @deprecated 3.2.0 Use $wpmem->reg_securify() instead. + * + * @param string $content + * @return string $content + */ +function wpmem_reg_securify( $content ) { + global $wpmem, $wpmem_themsg; + $nonce = wpmem_get( 'reg_nonce', false, 'get' ); + if ( $nonce && wp_verify_nonce( $nonce, 'register_redirect' ) ) { + $content = wpmem_inc_regmessage( 'success', $wpmem_themsg ); + $content = $content . wpmem_inc_login(); + } + return $content; +} + +/** + * Enqueues the admin javascript and css files. + * + * Replaces wpmem_admin_enqueue_scripts(). + * Only loads the js and css on admin screens that use them. + * + * @since 3.1.7 + * @deprecated 3.2.0 Use $wpmem->admin->dashboard_enqueue_script() instead. + * + * @param str $hook The admin screen hook being loaded. + */ +function wpmem_dashboard_enqueue_scripts( $hook ) { + if ( $hook == 'edit.php' || $hook == 'settings_page_wpmem-settings' ) { + wp_enqueue_style( 'wpmem-admin', WPMEM_DIR . 'admin/css/admin.css', '', WPMEM_VERSION ); + } + if ( $hook == 'settings_page_wpmem-settings' ) { + wp_enqueue_script( 'wpmem-admin', WPMEM_DIR . 'admin/js/admin.js', '', WPMEM_VERSION ); + } +} \ No newline at end of file From 4c3887e4d1005dff05c07dfefd5a3b78eab5202f Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 16 Nov 2017 12:18:48 -0600 Subject: [PATCH 0721/1694] fixed issue if there are no hidden posts (check isset()) --- inc/class-wp-members.php | 1 + 1 file changed, 1 insertion(+) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 88fd5fb7..5e12a5bc 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -956,6 +956,7 @@ function get_hidden_posts() { foreach ( $wpmem->membership->products as $key => $value ) { if ( ! isset( $wpmem->user->access[ $key ] ) || ! $wpmem->user->is_current( $wpmem->user->access[ $key ] ) ) { $hidden_posts = $this->hidden_posts(); + $hidden_posts = ( is_array( $hidden_posts ) ) ? $hidden_posts : array(); foreach ( $hidden_posts as $post_id ) { if ( 1 == get_post_meta( $post_id, $wpmem->membership->post_stem . $key, true ) ) { $hidden[] = $post_id; From 87d65a22b58c707adf5d849f1edf148a84691bf0 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 16 Nov 2017 12:20:09 -0600 Subject: [PATCH 0722/1694] moved enqueue scripts and plugin links --- admin/admin.php | 22 --------- admin/includes/class-wp-members-admin-api.php | 46 +++++++++++++++++-- 2 files changed, 43 insertions(+), 25 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index 529a8481..bee9e277 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -31,28 +31,6 @@ exit(); } -/** - * Filter to add link to settings from plugin panel. - * - * @since 2.4.0 - * - * @param array $links - * @param string $file - * @return array $links - */ -function wpmem_admin_plugin_links( $links, $file ) { - static $wpmem_plugin; - if ( ! $wpmem_plugin ) { - $wpmem_plugin = plugin_basename( WPMEM_PATH . '/wp-members.php' ); - } - if ( $file == $wpmem_plugin ) { - $settings_link = '' . __( 'Settings', 'wp-members' ) . ''; - $links = array_merge( array( $settings_link ), $links ); - } - return $links; -} - - /** * Creates the captcha tab. * diff --git a/admin/includes/class-wp-members-admin-api.php b/admin/includes/class-wp-members-admin-api.php index a1915af9..17462499 100644 --- a/admin/includes/class-wp-members-admin-api.php +++ b/admin/includes/class-wp-members-admin-api.php @@ -84,7 +84,6 @@ function load_dependencies() { include_once( WPMEM_PATH . 'admin/dialogs.php' ); include_once( WPMEM_PATH . 'admin/post.php' ); include_once( WPMEM_PATH . 'admin/includes/api.php' ); - include_once( WPMEM_PATH . 'inc/wp-registration.php' ); require_once( WPMEM_PATH . 'inc/class-wp-members-user-profile.php' ); include_once( WPMEM_PATH . 'admin/tab-fields.php' ); // Fields tab is used for field reorder (which is ! wpmem-settings). if ( 'wpmem-settings' == wpmem_get( 'page', false, 'get' ) ) { @@ -106,11 +105,11 @@ function load_dependencies() { */ function load_hooks() { - add_action( 'admin_enqueue_scripts', 'wpmem_dashboard_enqueue_scripts' ); + add_action( 'admin_enqueue_scripts', array( $this, 'dashboard_enqueue_scripts' ) ); add_action( 'wpmem_admin_do_tab', 'wpmem_admin_do_tab' ); add_action( 'wp_ajax_wpmem_a_field_reorder', 'wpmem_a_do_field_reorder' ); add_action( 'user_new_form', 'wpmem_admin_add_new_user' ); - add_filter( 'plugin_action_links', 'wpmem_admin_plugin_links', 10, 2 ); + add_filter( 'plugin_action_links', array( $this, 'plugin_links' ), 10, 2 ); add_filter( 'wpmem_admin_tabs', 'wpmem_add_about_tab' ); add_action( 'wpmem_admin_do_tab', 'wpmem_a_about_tab', 999, 1 ); @@ -493,6 +492,47 @@ function form_post_url( $args = false ) { return esc_url( $url ); } + /** + * Enqueues the admin javascript and css files. + * + * Replaces wpmem_admin_enqueue_scripts(). + * Only loads the js and css on admin screens that use them. + * + * @since 3.1.7 + * @deprecated 3.2.0 Moved to admin object, rename dashboard_enqueue_scripts(). + * + * @param str $hook The admin screen hook being loaded. + */ + function dashboard_enqueue_scripts( $hook ) { + if ( $hook == 'edit.php' || $hook == 'settings_page_wpmem-settings' ) { + wp_enqueue_style( 'wpmem-admin', WPMEM_DIR . 'admin/css/admin.css', '', WPMEM_VERSION ); + } + if ( $hook == 'settings_page_wpmem-settings' ) { + wp_enqueue_script( 'wpmem-admin', WPMEM_DIR . 'admin/js/admin.js', '', WPMEM_VERSION ); + } + } + + /** + * Filter to add link to settings from plugin panel. + * + * @since 2.4.0 + * @since 3.2.0 Moved to admin API class, renamed from wpmem_admin_plugin_links(). + * + * @param array $links + * @param string $file + * @return array $links + */ + function plugin_links( $links, $file ) { + static $wpmem_plugin; + if ( ! $wpmem_plugin ) { + $wpmem_plugin = plugin_basename( WPMEM_PATH . '/wp-members.php' ); + } + if ( $file == $wpmem_plugin ) { + $settings_link = '' . __( 'Settings', 'wp-members' ) . ''; + $links = array_merge( array( $settings_link ), $links ); + } + return $links; + } } // End of WP_Members_Admin_API class. // End of file. \ No newline at end of file From 15d67d3287dd33db3df87e1ccc1b97a3bb3e3a75 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 16 Nov 2017 12:20:28 -0600 Subject: [PATCH 0723/1694] moved captcha tab functions --- admin/admin.php | 30 ------------------------------ admin/tab-captcha.php | 29 ++++++++++++++++++++++++++++- 2 files changed, 28 insertions(+), 31 deletions(-) diff --git a/admin/admin.php b/admin/admin.php index bee9e277..b7736eb1 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -31,36 +31,6 @@ exit(); } -/** - * Creates the captcha tab. - * - * @since 2.8.0 - * - * @param string $tab The admin tab being displayed. - * @return string|bool The captcha options tab, otherwise false. - */ -function wpmem_a_captcha_tab( $tab ) { - if ( $tab == 'captcha' ) { - return wpmem_a_build_captcha_options(); - } else { - return false; - } -} - - -/** - * Adds the captcha tab. - * - * @since 2.8.0 - * - * @param array $tabs The array of tabs for the admin panel. - * @return array The updated array of tabs for the admin panel. - */ -function wpmem_add_captcha_tab( $tabs ) { - return array_merge( $tabs, array( 'captcha' => 'Captcha' ) ); -} - - /** * Primary admin function. * diff --git a/admin/tab-captcha.php b/admin/tab-captcha.php index 92dd0586..753355cf 100644 --- a/admin/tab-captcha.php +++ b/admin/tab-captcha.php @@ -24,6 +24,34 @@ exit(); } +/** + * Creates the captcha tab. + * + * @since 2.8.0 + * + * @param string $tab The admin tab being displayed. + * @return string|bool The captcha options tab, otherwise false. + */ +function wpmem_a_captcha_tab( $tab ) { + if ( $tab == 'captcha' ) { + return wpmem_a_build_captcha_options(); + } else { + return false; + } +} + +/** + * Adds the captcha tab. + * + * @since 2.8.0 + * + * @param array $tabs The array of tabs for the admin panel. + * @return array The updated array of tabs for the admin panel. + */ +function wpmem_add_captcha_tab( $tabs ) { + return array_merge( $tabs, array( 'captcha' => 'Captcha' ) ); +} + /** * Builds the captcha options. * @@ -215,7 +243,6 @@ function wpmem_a_build_captcha_options() { Date: Thu, 16 Nov 2017 12:21:20 -0600 Subject: [PATCH 0724/1694] fix product cpt js to show if current value is set --- .../class-wp-members-products-admin.php | 51 ++++++++++--------- 1 file changed, 26 insertions(+), 25 deletions(-) diff --git a/admin/includes/class-wp-members-products-admin.php b/admin/includes/class-wp-members-products-admin.php index 6eed9ecb..e6412064 100644 --- a/admin/includes/class-wp-members-products-admin.php +++ b/admin/includes/class-wp-members-products-admin.php @@ -117,7 +117,9 @@ function meta_boxes() { * @param object $post */ function details_html( $post ) { - $periods = array( __( 'Period', 'wp-members' ) . '|', __( 'Day', 'wp-members' ) . '|d', __( 'Week', 'wp-members' ) . '|w', __( 'Month', 'wp-members' ) . '|m', __( 'Year', 'wp-members' ) . '|y' ); ?> + $periods = array( __( 'Period', 'wp-members' ) . '|', __( 'Day', 'wp-members' ) . '|d', __( 'Week', 'wp-members' ) . '|w', __( 'Month', 'wp-members' ) . '|m', __( 'Year', 'wp-members' ) . '|y' ); + $show_role_detail = ( $this->get_meta( 'membership_product_role_required' ) === 'role-required' ) ? 'show' : 'hide'; + $show_exp_detail = ( $this->get_meta( 'membership_product_expires' ) === 'expires' ) ? 'show' : 'hide'; ?>

    @@ -140,34 +142,33 @@ function details_html( $post ) { - 'membership_product_time_period', 'type'=>'select', 'value'=>$periods, 'compare'=>$this->get_meta( 'membership_product_number_of_periods' ) ) ); ?> + 'membership_product_time_period', 'type'=>'select', 'value'=>$periods, 'compare'=>$this->get_meta( 'membership_product_time_period' ) ) ); ?>

    Date: Thu, 16 Nov 2017 12:21:55 -0600 Subject: [PATCH 0725/1694] updates to form builders for HTML5 --- inc/class-wp-members-forms.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 6c156b4a..be14be64 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -418,11 +418,11 @@ function login_form( $page, $arr ) { 'row_after' => '', 'buttons_before' => '
    ', 'buttons_after' => '
    ', - 'link_before' => '', // Classes & ids. - 'form_id' => '', + 'form_id' => ( 'new' == $tag ) ? 'wpmem_register' : 'wpmem_profile', 'form_class' => 'form', 'button_id' => '', 'button_class' => 'buttons', @@ -1070,7 +1070,7 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { // Start with a clean row. $row = ''; $row = '
    '; - $row.= '
    ' . wpmem_inc_recaptcha( $wpmem_captcha['recaptcha'] ) . '
    '; + $row.= '
    ' . wpmem_inc_recaptcha( $wpmem_captcha['recaptcha'] ) . '
    '; // Add the captcha row to the form. /** @@ -1174,7 +1174,7 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { $form = '
    ' . $args['n'] . $form . $args['n'] . '
    '; // Apply anchor. - $form = '' . $args['n'] . $form; + $form = '' . $args['n'] . $form; // Apply main div wrapper. $form = $args['main_div_before'] . $args['n'] . $form . $args['n'] . $args['main_div_after'] . $args['n']; From 905689f2b6aa9598460d49ab29232a9c1bd2370d Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 21 Nov 2017 11:39:41 -0600 Subject: [PATCH 0726/1694] set user access loaded from _wpmem_products meta key --- inc/class-wp-members-user.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/inc/class-wp-members-user.php b/inc/class-wp-members-user.php index 557d4300..41147b83 100644 --- a/inc/class-wp-members-user.php +++ b/inc/class-wp-members-user.php @@ -494,9 +494,7 @@ function has_access( $product, $user_id = false ) { */ function get_user_products( $user_id = false ) { $user_id = ( ! $user_id ) ? get_current_user_id() : $user_id; - $this->access = array( - - ); + $this->access = get_user_meta( $user_id, '_wpmem_products', true ); } /** From e013b77509ba6427f73b3bed38fac9e33c50ffd8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 21 Nov 2017 11:40:20 -0600 Subject: [PATCH 0727/1694] esc_sql user screen query variable --- admin/users.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/admin/users.php b/admin/users.php index 43f8706b..ccff361e 100644 --- a/admin/users.php +++ b/admin/users.php @@ -538,14 +538,14 @@ function wpmem_a_pre_user_query( $user_search ) { $replace_query = "WHERE 1=1 AND {$wpdb->users}.ID IN ( SELECT {$wpdb->usermeta}.user_id FROM $wpdb->usermeta WHERE {$wpdb->usermeta}.meta_key = 'exp_type' - AND {$wpdb->usermeta}.meta_value = \"$show\" )"; + AND {$wpdb->usermeta}.meta_value = \"" . esc_sql( $show ) . "\" )"; break; case 'pending': $replace_query = "WHERE 1=1 AND {$wpdb->users}.ID IN ( SELECT {$wpdb->usermeta}.user_id FROM $wpdb->usermeta WHERE {$wpdb->usermeta}.meta_key = 'exp_type' - AND {$wpdb->usermeta}.meta_value = \"$show\" )"; + AND {$wpdb->usermeta}.meta_value = \"" . esc_sql( $show ) . "\" )"; break; case 'expired': @@ -557,7 +557,7 @@ function wpmem_a_pre_user_query( $user_search ) { break; } - $user_search->query_where = str_replace( 'WHERE 1=1', $replace_query, $user_search->query_where ); + $user_search->query_where = str_replace( 'WHERE 1=1', $replace_query, $user_search->query_where ); } From b09f32a5b9a550fc8bd95a31413ddadd1990f894 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 21 Nov 2017 11:41:13 -0600 Subject: [PATCH 0728/1694] move user admin actions to appropriate condition (edit_users) --- admin/includes/class-wp-members-admin-api.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/admin/includes/class-wp-members-admin-api.php b/admin/includes/class-wp-members-admin-api.php index 17462499..1c60a503 100644 --- a/admin/includes/class-wp-members-admin-api.php +++ b/admin/includes/class-wp-members-admin-api.php @@ -93,7 +93,7 @@ function load_dependencies() { include_once( WPMEM_PATH . 'admin/tab-about.php' ); include_once( WPMEM_PATH . 'admin/tab-dialogs.php' ); include_once( WPMEM_PATH . 'admin/tab-dropins.php' ); - include_once( WPMEM_PATH . 'admin/tab-memberships.php' ); + //include_once( WPMEM_PATH . 'admin/tab-memberships.php' ); } } @@ -131,6 +131,9 @@ function load_hooks() { add_action( 'wpmem_user_activated', 'wpmem_set_activated_user' ); add_action( 'wpmem_user_deactivated', 'wpmem_set_deactivated_user' ); add_filter( 'user_row_actions', 'wpmem_insert_activate_link', 10, 2 ); + add_action( 'wpmem_admin_after_profile', 'wpmem_profile_show_activate', 7 ); + add_action( 'wpmem_admin_after_profile', 'wpmem_profile_show_expiration', 8 ); + add_action( 'wpmem_admin_after_profile', 'wpmem_profile_show_ip', 9 ); } // If user has a role that can edit posts, add the block/unblock meta boxes and custom post/page columns. @@ -142,11 +145,6 @@ function load_hooks() { add_action( 'manage_posts_custom_column', 'wpmem_post_columns_content', 10, 2 ); add_filter( 'manage_pages_columns', 'wpmem_post_columns' ); add_action( 'manage_pages_custom_column', 'wpmem_post_columns_content', 10, 2 ); - - add_action( 'wpmem_admin_after_profile', 'wpmem_profile_show_activate', 7 ); - add_action( 'wpmem_admin_after_profile', 'wpmem_profile_show_expiration', 8 ); - add_action( 'wpmem_admin_after_profile', 'wpmem_profile_show_ip', 9 ); - add_action( 'admin_footer-edit.php', 'wpmem_bulk_posts_action' ); add_action( 'load-edit.php', 'wpmem_posts_page_load' ); add_action( 'admin_notices', 'wpmem_posts_admin_notices' ); From f13b35c4b847052bed025c380e258e423fb3f677 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 21 Nov 2017 11:41:38 -0600 Subject: [PATCH 0729/1694] cleanup, readme update, new generated pot --- admin/tab-options.php | 2 +- lang/wp-members.pot | 1149 ++++++++++++++++++++++++++--------------- readme.txt | 15 +- 3 files changed, 753 insertions(+), 413 deletions(-) diff --git a/admin/tab-options.php b/admin/tab-options.php index 8912739c..33a6d2b6 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -93,7 +93,7 @@ function wpmem_a_build_options() { $values = array( __( 'Do not block', 'wp-members' ) . '|0', __( 'Block', 'wp-members' ) . '|1', - __( 'Hide', 'wp-members' ) . '|2', + // @todo Future development. __( 'Hide', 'wp-members' ) . '|2', ); echo wpmem_create_formfield( 'wpmem_block_' . $key, 'select', $values, $block ); ?> diff --git a/lang/wp-members.pot b/lang/wp-members.pot index 77edd927..954908f2 100644 --- a/lang/wp-members.pot +++ b/lang/wp-members.pot @@ -3,15 +3,16 @@ msgid "" msgstr "" "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" "Project-Id-Version: WP-Members\n" -"POT-Creation-Date: 2016-05-03 17:34-0500\n" -"PO-Revision-Date: 2016-05-03 17:26-0500\n" +"POT-Creation-Date: 2017-11-16 15:04-0600\n" +"PO-Revision-Date: 2017-11-16 15:03-0600\n" "Last-Translator: \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 1.8.7\n" +"X-Generator: Poedit 2.0.4\n" "X-Poedit-Basepath: ..\n" +"X-Poedit-Flags-xgettext: --add-comments=translators:\n" "X-Poedit-WPHeader: wp-members.php\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;" @@ -20,24 +21,24 @@ msgstr "" "X-Poedit-SearchPath-0: .\n" "X-Poedit-SearchPathExcluded-0: *.js\n" -#: admin/admin.php:72 admin/admin.php:143 +#: admin/admin.php:59 admin/includes/class-wp-members-admin-api.php:531 msgid "Settings" msgstr "" -#: admin/dialogs.php:104 +#: admin/dialogs.php:116 msgid "" "Your WP settings allow anyone to register - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:105 +#: admin/dialogs.php:117 #, php-format msgid "" "You can %s change this here %s making sure the box next to \"Anyone can " "register\" is unchecked." msgstr "" -#: admin/dialogs.php:106 +#: admin/dialogs.php:118 msgid "" "This setting allows a link on the /wp-login.php page to register using the " "WP native registration process thus circumventing any registration you are " @@ -47,20 +48,20 @@ msgid "" "Settings." msgstr "" -#: admin/dialogs.php:110 +#: admin/dialogs.php:122 msgid "" "Your WP settings allow anyone to comment - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:111 +#: admin/dialogs.php:123 #, php-format msgid "" "You can %s change this here %s by checking the box next to \"Users must be " "registered and logged in to comment.\"" msgstr "" -#: admin/dialogs.php:112 +#: admin/dialogs.php:124 msgid "" "This setting allows any users to comment, whether or not they are " "registered. Depending on how you are using WP-Members will determine whether " @@ -68,198 +69,330 @@ msgid "" "you can choose to ignore these warning messages under WP-Members Settings." msgstr "" -#: admin/dialogs.php:116 +#: admin/dialogs.php:128 msgid "" "Your WP settings allow full text rss feeds - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:117 +#: admin/dialogs.php:129 #, php-format msgid "" "You can %s change this here %s by changing \"For each article in a feed, show" "\" to \"Summary.\"" msgstr "" -#: admin/dialogs.php:118 +#: admin/dialogs.php:130 msgid "" "Leaving this set to full text allows anyone to read your protected content " "in an RSS reader. Changing this to Summary prevents this as your feeds will " "only show summary text." msgstr "" -#: admin/dialogs.php:122 +#: admin/dialogs.php:134 msgid "You have set WP-Members to hold registrations for approval" msgstr "" -#: admin/dialogs.php:123 +#: admin/dialogs.php:135 msgid "" "but you have not changed the default message for \"Registration Completed\" " "under \"WP-Members Dialogs and Error Messages.\" You should change this " "message to let users know they are pending approval." msgstr "" -#: admin/dialogs.php:127 -msgid "You have set WP-Members to turn off the registration process" +#: admin/dialogs.php:139 +msgid "You have turned on reCAPTCHA" msgstr "" -#: admin/dialogs.php:128 +#: admin/dialogs.php:140 msgid "" -"but you also set to moderate and/or email admin new registrations. You will " -"need to set up a registration page for users to register." +"but you have not entered API keys. You will need both a public and private " +"key. The CAPTCHA will not display unless a valid API key is included." msgstr "" -#: admin/dialogs.php:132 -msgid "You have turned on reCAPTCHA" +#: admin/dialogs.php:144 +msgid "You have active settings that are not recommended." msgstr "" -#: admin/dialogs.php:133 +#: admin/dialogs.php:145 msgid "" -"but you have not entered API keys. You will need both a public and private " -"key. The CAPTCHA will not display unless a valid API key is included." +"If you will not be changing these settings, you can turn off these warning " +"messages by checking the \"Ignore warning messages\" in the settings below." msgstr "" -#: admin/dialogs.php:157 +#: admin/dialogs.php:169 msgid "Version:" msgstr "" -#: admin/dialogs.php:158 +#: admin/dialogs.php:170 msgid "Quick Start Guide" msgstr "" -#: admin/dialogs.php:159 +#: admin/dialogs.php:171 msgid "Online User Guide" msgstr "" -#: admin/dialogs.php:160 +#: admin/dialogs.php:172 msgid "FAQs" msgstr "" -#: admin/dialogs.php:167 +#: admin/dialogs.php:179 msgid "Thank you for using WP-Members" msgstr "" -#: admin/dialogs.php:168 +#: admin/dialogs.php:180 msgid "A plugin developed by" msgstr "" -#: admin/dialogs.php:169 +#: admin/dialogs.php:181 msgid "Follow" msgstr "" -#: admin/dialogs.php:186 admin/dialogs.php:190 +#: admin/dialogs.php:198 admin/dialogs.php:202 msgid "Latest from RocketGeek" msgstr "" -#: admin/dialogs.php:207 admin/dialogs.php:220 +#: admin/dialogs.php:219 admin/dialogs.php:232 msgid "Latest from ButlerBlog" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:220 +#: admin/includes/class-wp-members-admin-api.php:249 +msgid "Custom email" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:250 +#: admin/includes/class-wp-members-admin-api.php:252 +msgid "Subject" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:253 +msgid "Body" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:255 +msgid "Your custom email message content." +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:333 msgid "Options" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:221 +#: admin/includes/class-wp-members-admin-api.php:334 msgid "Fields" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:222 +#: admin/includes/class-wp-members-admin-api.php:335 msgid "Dialogs" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:223 +#: admin/includes/class-wp-members-admin-api.php:336 msgid "Emails" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:239 +#: admin/includes/class-wp-members-admin-api.php:352 msgid "New Registration" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:248 +#: admin/includes/class-wp-members-admin-api.php:361 msgid "Registration is Moderated" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:254 +#: admin/includes/class-wp-members-admin-api.php:367 msgid "Registration is Moderated, User is Approved" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:262 +#: admin/includes/class-wp-members-admin-api.php:375 msgid "Password Reset" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:269 +#: admin/includes/class-wp-members-admin-api.php:382 msgid "Retrieve Username" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:277 +#: admin/includes/class-wp-members-admin-api.php:390 msgid "Admin Notification" msgstr "" -#: admin/post.php:51 admin/post.php:53 admin/tab-options.php:87 +#: admin/includes/class-wp-members-admin-api.php:416 +msgid "Restricted post (or page), displays above the login/registration form" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:417 +msgid "Username is taken" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:418 +msgid "Email is registered" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:419 +msgid "Registration completed" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:420 +msgid "User update" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:421 +msgid "Passwords did not match" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:422 +msgid "Password changes" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:423 +msgid "Username or email do not exist when trying to reset forgotten password" +msgstr "" + +#: admin/includes/class-wp-members-admin-api.php:424 +msgid "Password reset" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:41 +msgid "Slug" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:42 +msgid "Role" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:43 +#: admin/includes/class-wp-members-products-admin.php:140 +#: admin/tab-fields.php:430 admin/user-export.php:86 +msgid "Expires" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:44 +msgid "Last updated" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:64 +msgid "No role required" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:69 +msgid "Does not expire" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:104 +msgid "Membership Product Details" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:120 +#: admin/includes/class-wp-members-products-admin.php:144 +msgid "Period" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:120 +msgid "Day" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:120 +msgid "Week" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:120 +msgid "Month" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:120 +msgid "Year" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:126 +msgid "Name (slug)" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:131 +msgid "Role Required?" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:134 +msgid "No Role" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:142 +#: admin/includes/class-wp-members-products-admin.php:143 +msgid "Number" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:216 +#: admin/tab-options.php:188 inc/class-wp-members-forms.php:934 +#: inc/class-wp-members-user-profile.php:92 inc/deprecated.php:360 +#: inc/deprecated.php:622 +msgid "None" +msgstr "" + +#: admin/includes/class-wp-members-products-admin.php:222 +msgid "Limit access to:" +msgstr "" + +#: admin/post.php:45 admin/post.php:47 admin/tab-options.php:95 msgid "Block" msgstr "" -#: admin/post.php:52 admin/post.php:54 +#: admin/post.php:46 admin/post.php:48 msgid "Unblock" msgstr "" -#: admin/post.php:188 +#: admin/post.php:143 #, php-format -msgid "%s Restriction" +msgid "%s blocked" msgstr "" -#: admin/post.php:215 +#: admin/post.php:143 #, php-format -msgid "%s are blocked by default." +msgid "%s unblocked" msgstr "" -#: admin/post.php:216 +#: admin/post.php:182 #, php-format -msgid "Unblock this %s" +msgid "%s Restriction" msgstr "" -#: admin/post.php:219 +#: admin/post.php:210 #, php-format -msgid "%s are not blocked by default." +msgid "%s are blocked by default." msgstr "" -#: admin/post.php:220 +#: admin/post.php:214 #, php-format -msgid "Block this %s" +msgid "%s are not blocked by default." msgstr "" -#: admin/post.php:226 admin/tab-fields.php:282 admin/tab-fields.php:473 +#: admin/post.php:220 admin/tab-fields.php:88 admin/tab-fields.php:523 msgid "Edit" msgstr "" -#: admin/post.php:313 +#: admin/post.php:311 msgid "Unblocked?" msgstr "" -#: admin/post.php:313 +#: admin/post.php:311 msgid "Blocked?" msgstr "" -#: admin/post.php:345 admin/post.php:346 admin/user-export.php:108 -msgid "Yes" +#: admin/tab-about.php:34 admin/tab-about.php:56 +msgid "About WP-Members" msgstr "" -#: admin/tab-captcha.php:42 admin/tab-dialogs.php:47 admin/tab-emails.php:80 -#: admin/tab-fields.php:44 admin/tab-options.php:58 +#: admin/tab-captcha.php:74 admin/tab-dialogs.php:40 admin/tab-emails.php:84 +#: admin/tab-fields.php:149 admin/tab-options.php:64 msgid "Need help?" msgstr "" -#: admin/tab-captcha.php:53 +#: admin/tab-captcha.php:85 msgid "Manage reCAPTCHA Options" msgstr "" -#: admin/tab-captcha.php:67 +#: admin/tab-captcha.php:99 msgid "" "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " "while blocking spam on your blog." msgstr "" -#: admin/tab-captcha.php:68 +#: admin/tab-captcha.php:100 #, php-format msgid "" "reCAPTCHA asks commenters to retype two words scanned from a book to prove " @@ -269,1045 +402,1241 @@ msgid "" "the %s reCAPTCHA website%s" msgstr "" -#: admin/tab-captcha.php:73 admin/tab-captcha.php:99 +#: admin/tab-captcha.php:105 admin/tab-captcha.php:131 msgid "reCAPTCHA Keys" msgstr "" -#: admin/tab-captcha.php:75 +#: admin/tab-captcha.php:107 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:76 +#: admin/tab-captcha.php:108 msgid "Public Key" msgstr "" -#: admin/tab-captcha.php:77 +#: admin/tab-captcha.php:109 msgid "Private Key" msgstr "" -#: admin/tab-captcha.php:81 +#: admin/tab-captcha.php:113 msgid "Choose Theme" msgstr "" -#: admin/tab-captcha.php:84 +#: admin/tab-captcha.php:116 msgid "Red" msgstr "" -#: admin/tab-captcha.php:85 +#: admin/tab-captcha.php:117 msgid "White" msgstr "" -#: admin/tab-captcha.php:86 +#: admin/tab-captcha.php:118 msgid "Black Glass" msgstr "" -#: admin/tab-captcha.php:87 +#: admin/tab-captcha.php:119 msgid "Clean" msgstr "" -#: admin/tab-captcha.php:101 +#: admin/tab-captcha.php:133 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:102 +#: admin/tab-captcha.php:134 msgid "Site Key" msgstr "" -#: admin/tab-captcha.php:103 +#: admin/tab-captcha.php:135 msgid "Secret Key" msgstr "" -#: admin/tab-captcha.php:134 +#: admin/tab-captcha.php:166 msgid "Characters for image" msgstr "" -#: admin/tab-captcha.php:138 +#: admin/tab-captcha.php:170 msgid "Number of characters" msgstr "" -#: admin/tab-captcha.php:142 +#: admin/tab-captcha.php:174 msgid "Image dimensions" msgstr "" -#: admin/tab-captcha.php:143 +#: admin/tab-captcha.php:175 msgid "Width" msgstr "" -#: admin/tab-captcha.php:143 +#: admin/tab-captcha.php:175 msgid "Height" msgstr "" -#: admin/tab-captcha.php:146 +#: admin/tab-captcha.php:178 msgid "Font color of characters" msgstr "" -#: admin/tab-captcha.php:150 +#: admin/tab-captcha.php:182 msgid "Background color of image" msgstr "" -#: admin/tab-captcha.php:154 +#: admin/tab-captcha.php:186 msgid "Font size" msgstr "" -#: admin/tab-captcha.php:158 +#: admin/tab-captcha.php:190 msgid "Width between characters" msgstr "" -#: admin/tab-captcha.php:162 +#: admin/tab-captcha.php:194 msgid "Image type" msgstr "" -#: admin/tab-captcha.php:176 +#: admin/tab-captcha.php:208 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: admin/tab-captcha.php:200 +#: admin/tab-captcha.php:232 msgid "Update CAPTCHA Settings" msgstr "" -#: admin/tab-captcha.php:271 +#: admin/tab-captcha.php:302 msgid "CAPTCHA was updated for WP-Members" msgstr "" -#: admin/tab-dialogs.php:32 -msgid "Restricted post (or page), displays above the login/registration form" +#: admin/tab-dialogs.php:50 +msgid "Dialogs and Error Messages" msgstr "" -#: admin/tab-dialogs.php:33 -msgid "Username is taken" +#: admin/tab-dialogs.php:52 +#, php-format +msgid "" +"You can customize the text for dialogs and error messages. Simple HTML is " +"allowed %s etc." msgstr "" -#: admin/tab-dialogs.php:34 -msgid "Email is registered" +#: admin/tab-dialogs.php:63 +msgid "Terms of Service (TOS)" msgstr "" -#: admin/tab-dialogs.php:35 -msgid "Registration completed" +#: admin/tab-dialogs.php:70 +msgid "Update Dialogs" msgstr "" -#: admin/tab-dialogs.php:36 -msgid "User update" +#: admin/tab-dialogs.php:106 +msgid "WP-Members dialogs were updated" msgstr "" -#: admin/tab-dialogs.php:37 -msgid "Passwords did not match" +#: admin/tab-dropins.php:79 admin/tab-dropins.php:378 +msgid "WP-Members Dropin settings were updated" msgstr "" -#: admin/tab-dialogs.php:38 -msgid "Password changes" +#: admin/tab-dropins.php:204 +msgid "Manage Dropins" msgstr "" -#: admin/tab-dialogs.php:39 -msgid "Username or email do not exist when trying to reset forgotten password" +#: admin/tab-dropins.php:205 +msgid "Current dropin folder: " msgstr "" -#: admin/tab-dialogs.php:40 -msgid "Password reset" +#: admin/tab-dropins.php:206 +msgid "" +"You can change location of the dropin folder using the " +"wpmem_dropin_folder filter." msgstr "" -#: admin/tab-dialogs.php:57 -msgid "Dialogs and Error Messages" +#: admin/tab-dropins.php:269 +msgid "Name" msgstr "" -#: admin/tab-dialogs.php:59 -#, php-format -msgid "" -"You can customize the text for dialogs and error messages. Simple HTML is " -"allowed %s etc." +#: admin/tab-dropins.php:270 +msgid "File" msgstr "" -#: admin/tab-dialogs.php:72 -msgid "Terms of Service (TOS)" +#: admin/tab-dropins.php:271 +msgid "Version" msgstr "" -#: admin/tab-dialogs.php:79 -msgid "Update Dialogs" +#: admin/tab-dropins.php:272 +msgid "Description" msgstr "" -#: admin/tab-dialogs.php:118 -msgid "WP-Members dialogs were updated" +#: admin/tab-dropins.php:315 admin/tab-fields.php:568 +msgid "Save Settings" msgstr "" -#: admin/tab-emails.php:37 +#: admin/tab-emails.php:41 msgid "Email Messages" msgstr "" -#: admin/tab-emails.php:40 +#: admin/tab-emails.php:44 msgid "You can customize the content of the emails sent by the plugin." msgstr "" -#: admin/tab-emails.php:42 +#: admin/tab-emails.php:46 msgid "A list of shortcodes is available here." msgstr "" -#: admin/tab-emails.php:49 +#: admin/tab-emails.php:53 msgid "Set a custom email address" msgstr "" -#: admin/tab-emails.php:50 admin/tab-emails.php:54 admin/tab-emails.php:64 +#: admin/tab-emails.php:54 admin/tab-emails.php:58 admin/tab-emails.php:68 +#: admin/tab-fields.php:175 msgid "(optional)" msgstr "" -#: admin/tab-emails.php:53 +#: admin/tab-emails.php:57 msgid "Set a custom email name" msgstr "" -#: admin/tab-emails.php:64 +#: admin/tab-emails.php:68 msgid "Email Signature" msgstr "" -#: admin/tab-emails.php:72 +#: admin/tab-emails.php:76 msgid "Update Emails" msgstr "" -#: admin/tab-emails.php:140 +#: admin/tab-emails.php:146 msgid "WP-Members emails were updated" msgstr "" -#: admin/tab-fields.php:169 -msgid "WP-Members fields were updated" +#: admin/tab-fields.php:110 +msgid "Are you sure you want to delete the following fields?" msgstr "" -#: admin/tab-fields.php:181 -msgid "Field Label is required for adding a new field. Nothing was updated." +#: admin/tab-fields.php:137 +msgid "Fields deleted" msgstr "" -#: admin/tab-fields.php:182 -msgid "Option Name is required for adding a new field. Nothing was updated." +#: admin/tab-fields.php:151 +msgid "Field Manager Documentation" msgstr "" -#: admin/tab-fields.php:184 -msgid "Option Name must contain only letters, numbers, and underscores" -msgstr "" - -#: admin/tab-fields.php:191 -msgid "A field with that option name already exists" -msgstr "" - -#: admin/tab-fields.php:197 -#, php-format -msgid "" -"Sorry, \"%s\" is a reserved term. " -"Field was not added." -msgstr "" - -#: admin/tab-fields.php:215 -msgid "Checked value is required for checkboxes. Nothing was updated." -msgstr "" - -#: admin/tab-fields.php:245 -msgid "field was added" -msgstr "" - -#: admin/tab-fields.php:263 -msgid "field was updated" +#: admin/tab-fields.php:176 admin/tab-fields.php:293 +#: inc/class-wp-members-user-profile.php:124 inc/deprecated.php:385 +#: inc/deprecated.php:646 inc/wp-registration.php:54 +#: inc/wp-registration.php:213 +msgid "(required)" msgstr "" -#: admin/tab-fields.php:309 admin/tab-fields.php:437 +#: admin/tab-fields.php:181 admin/tab-fields.php:378 msgid "Edit Field" msgstr "" -#: admin/tab-fields.php:309 +#: admin/tab-fields.php:181 msgid "Add a Field" msgstr "" -#: admin/tab-fields.php:315 admin/tab-fields.php:467 +#: admin/tab-fields.php:186 msgid "Field Label" msgstr "" -#: admin/tab-fields.php:317 +#: admin/tab-fields.php:188 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: admin/tab-fields.php:320 admin/tab-fields.php:468 -msgid "Option Name" +#: admin/tab-fields.php:191 admin/tab-fields.php:518 +msgid "Meta Key" msgstr "" -#: admin/tab-fields.php:326 +#: admin/tab-fields.php:197 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: admin/tab-fields.php:330 admin/tab-fields.php:469 +#: admin/tab-fields.php:201 admin/tab-fields.php:519 msgid "Field Type" msgstr "" -#: admin/tab-fields.php:336 +#: admin/tab-fields.php:207 msgid "text" msgstr "" -#: admin/tab-fields.php:337 +#: admin/tab-fields.php:208 msgid "email" msgstr "" -#: admin/tab-fields.php:338 +#: admin/tab-fields.php:209 msgid "textarea" msgstr "" -#: admin/tab-fields.php:339 +#: admin/tab-fields.php:210 msgid "checkbox" msgstr "" -#: admin/tab-fields.php:340 +#: admin/tab-fields.php:211 msgid "multiple checkbox" msgstr "" -#: admin/tab-fields.php:341 +#: admin/tab-fields.php:212 msgid "select (dropdown)" msgstr "" -#: admin/tab-fields.php:342 +#: admin/tab-fields.php:213 msgid "multiple select" msgstr "" -#: admin/tab-fields.php:343 +#: admin/tab-fields.php:214 msgid "radio group" msgstr "" -#: admin/tab-fields.php:344 +#: admin/tab-fields.php:215 msgid "password" msgstr "" -#: admin/tab-fields.php:345 +#: admin/tab-fields.php:216 msgid "image" msgstr "" -#: admin/tab-fields.php:346 +#: admin/tab-fields.php:217 msgid "file" msgstr "" -#: admin/tab-fields.php:347 +#: admin/tab-fields.php:218 msgid "url" msgstr "" -#: admin/tab-fields.php:348 +#: admin/tab-fields.php:219 +msgid "number" +msgstr "" + +#: admin/tab-fields.php:220 +msgid "date" +msgstr "" + +#: admin/tab-fields.php:221 msgid "hidden" msgstr "" -#: admin/tab-fields.php:353 admin/tab-fields.php:470 +#: admin/tab-fields.php:226 admin/tab-fields.php:520 msgid "Display?" msgstr "" -#: admin/tab-fields.php:357 admin/tab-fields.php:471 +#: admin/tab-fields.php:230 admin/tab-fields.php:521 msgid "Required?" msgstr "" -#: admin/tab-fields.php:363 -msgid "Additional information for field upload fields" +#: admin/tab-fields.php:235 +msgid "Allow HTML?" msgstr "" -#: admin/tab-fields.php:366 -msgid "Accepted file types:" +#: admin/tab-fields.php:242 +msgid "Placeholder" msgstr "" -#: admin/tab-fields.php:371 -msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" +#: admin/tab-fields.php:250 +msgid "Pattern" +msgstr "" + +#: admin/tab-fields.php:256 +msgid "Title" +msgstr "" + +#: admin/tab-fields.php:265 +msgid "Minimum Value" msgstr "" -#: admin/tab-fields.php:378 -msgid "Additional information for checkbox fields" +#: admin/tab-fields.php:269 +msgid "Maximum Value" msgstr "" -#: admin/tab-fields.php:381 +#: admin/tab-fields.php:277 +msgid "Accepted file types:" +msgstr "" + +#: admin/tab-fields.php:282 +msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" +msgstr "" + +#: admin/tab-fields.php:289 msgid "Checked by default?" msgstr "" -#: admin/tab-fields.php:385 +#: admin/tab-fields.php:293 msgid "Stored value if checked:" msgstr "" -#: admin/tab-fields.php:397 -msgid "Additional information for dropdown fields" +#: admin/tab-fields.php:314 +msgid "Stored values delimiter:" msgstr "" -#: admin/tab-fields.php:400 -msgid "For dropdown, array of values:" +#: admin/tab-fields.php:323 +msgid "Values (Displayed|Stored):" msgstr "" -#: admin/tab-fields.php:425 +#: admin/tab-fields.php:348 msgid "Options should be Option Name|option_value," msgstr "" -#: admin/tab-fields.php:429 +#: admin/tab-fields.php:352 msgid "Visit plugin site for more information" msgstr "" -#: admin/tab-fields.php:437 +#: admin/tab-fields.php:359 +msgid "Value" +msgstr "" + +#: admin/tab-fields.php:378 admin/tab-fields.php:645 admin/tab-fields.php:646 msgid "Add Field" msgstr "" -#: admin/tab-fields.php:458 -msgid "Manage Fields" +#: admin/tab-fields.php:380 admin/tab-fields.php:831 +msgid "Return to Fields Table" msgstr "" -#: admin/tab-fields.php:460 -msgid "" -"Determine which fields will display and which are required. This includes " -"all fields, both native WP fields and WP-Members custom fields." +#: admin/tab-fields.php:420 +msgid "Drag and drop to reorder fields" +msgstr "" + +#: admin/tab-fields.php:426 +msgid "Registration Date" +msgstr "" + +#: admin/tab-fields.php:427 +msgid "Active" +msgstr "" + +#: admin/tab-fields.php:428 +msgid "Registration IP" msgstr "" -#: admin/tab-fields.php:461 -msgid "(Note: Email is always mandatory and cannot be changed.)" +#: admin/tab-fields.php:429 +msgid "Subscription Type" msgstr "" -#: admin/tab-fields.php:466 -msgid "Add/Delete" +#: admin/tab-fields.php:431 +msgid "User ID" msgstr "" -#: admin/tab-fields.php:472 -msgid "Checked?" +#: admin/tab-fields.php:464 +msgid "Manage Fields" msgstr "" -#: admin/tab-fields.php:474 +#: admin/tab-fields.php:503 +msgid "delete" +msgstr "" + +#: admin/tab-fields.php:517 +msgid "Display Label" +msgstr "" + +#: admin/tab-fields.php:524 msgid "Users Screen" msgstr "" -#: admin/tab-fields.php:486 -msgid "Delete" +#: admin/tab-fields.php:525 +msgid "Users Search" msgstr "" -#: admin/tab-fields.php:498 -msgid "(Email cannot be removed)" +#: admin/tab-fields.php:567 +msgid "Delete Selected" msgstr "" -#: admin/tab-fields.php:518 -msgid "Registration Date" +#: admin/tab-fields.php:709 +msgid "WP-Members fields were updated" msgstr "" -#: admin/tab-fields.php:521 -msgid "native" +#: admin/tab-fields.php:731 +msgid "Field Label is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:531 -msgid "Active" +#: admin/tab-fields.php:732 +msgid "Meta Key is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:543 -msgid "Registration IP" +#: admin/tab-fields.php:734 +msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: admin/tab-fields.php:578 -msgid "Update Fields" +#: admin/tab-fields.php:741 +msgid "A field with that meta key already exists" msgstr "" -#: admin/tab-options.php:69 +#: admin/tab-fields.php:746 +#, php-format +msgid "" +"Sorry, \"%s\" is a reserved term. " +"Field was not added." +msgstr "" + +#: admin/tab-fields.php:779 +msgid "Checked value is required for checkboxes. Nothing was updated." +msgstr "" + +#: admin/tab-fields.php:810 +msgid "A value is required for hidden fields. Nothing was updated." +msgstr "" + +#: admin/tab-fields.php:817 +#, php-format +msgid "%s was added" +msgstr "" + +#: admin/tab-fields.php:830 +#, php-format +msgid "%s was updated" +msgstr "" + +#: admin/tab-fields.php:872 +msgid "Form field order updated." +msgstr "" + +#: admin/tab-options.php:75 msgid "Manage Options" msgstr "" -#: admin/tab-options.php:86 +#: admin/tab-options.php:79 +msgid "Content" +msgstr "" + +#: admin/tab-options.php:90 +msgid "Content Blocking" +msgstr "" + +#: admin/tab-options.php:94 msgid "Do not block" msgstr "" -#: admin/tab-options.php:88 +#: admin/tab-options.php:96 msgid "Hide" msgstr "" -#: admin/tab-options.php:99 +#: admin/tab-options.php:108 msgid "Show Excerpts" msgstr "" -#: admin/tab-options.php:100 +#: admin/tab-options.php:109 msgid "Show Login Form" msgstr "" -#: admin/tab-options.php:101 +#: admin/tab-options.php:110 msgid "Show Registration Form" msgstr "" -#: admin/tab-options.php:102 +#: admin/tab-options.php:111 msgid "Auto Excerpt:" msgstr "" -#: admin/tab-options.php:122 +#: admin/tab-options.php:133 msgid "Number of words in excerpt:" msgstr "" -#: admin/tab-options.php:136 +#: admin/tab-options.php:134 +msgid "Custom read more link (optional):" +msgstr "" + +#: admin/tab-options.php:148 msgid "Time-based expiration" msgstr "" -#: admin/tab-options.php:136 +#: admin/tab-options.php:148 msgid "Allows for access to expire" msgstr "" -#: admin/tab-options.php:137 +#: admin/tab-options.php:149 msgid "Trial period" msgstr "" -#: admin/tab-options.php:137 +#: admin/tab-options.php:149 msgid "Allows for a trial period" msgstr "" -#: admin/tab-options.php:153 +#: admin/tab-options.php:151 +msgid "Subscription Settings" +msgstr "" + +#: admin/tab-options.php:161 +msgid "Other Settings" +msgstr "" + +#: admin/tab-options.php:167 +msgid "Enable Products" +msgstr "" + +#: admin/tab-options.php:167 +msgid "Enables creation of different membership products" +msgstr "" + +#: admin/tab-options.php:168 +msgid "Clone menus" +msgstr "" + +#: admin/tab-options.php:168 +msgid "Enables logged in menus" +msgstr "" + +#: admin/tab-options.php:169 msgid "Notify admin" msgstr "" -#: admin/tab-options.php:153 +#: admin/tab-options.php:169 #, php-format msgid "Notify %s for each new registration? %s" msgstr "" -#: admin/tab-options.php:154 +#: admin/tab-options.php:170 msgid "Moderate registration" msgstr "" -#: admin/tab-options.php:154 +#: admin/tab-options.php:170 msgid "Holds new registrations for admin approval" msgstr "" -#: admin/tab-options.php:155 +#: admin/tab-options.php:171 msgid "Ignore warning messages" msgstr "" -#: admin/tab-options.php:155 +#: admin/tab-options.php:171 msgid "Ignores WP-Members warning messages in the admin panel" msgstr "" -#: admin/tab-options.php:167 +#: admin/tab-options.php:182 msgid "Attribution" msgstr "" -#: admin/tab-options.php:169 +#: admin/tab-options.php:184 msgid "" "Attribution is appreciated! Display \"powered by\" link on register form?" msgstr "" -#: admin/tab-options.php:172 +#: admin/tab-options.php:187 msgid "Enable CAPTCHA" msgstr "" -#: admin/tab-options.php:174 admin/user-profile.php:97 inc/forms.php:806 -#: inc/users.php:70 -msgid "None" +#: admin/tab-options.php:192 +msgid "reCAPTCHA" msgstr "" -#: admin/tab-options.php:180 +#: admin/tab-options.php:193 +msgid "Really Simple CAPTCHA" +msgstr "" + +#: admin/tab-options.php:196 msgid "Pages" msgstr "" -#: admin/tab-options.php:184 +#: admin/tab-options.php:200 msgid "Login Page:" msgstr "" -#: admin/tab-options.php:187 +#: admin/tab-options.php:203 msgid "Specify a login page (optional)" msgstr "" -#: admin/tab-options.php:196 +#: admin/tab-options.php:212 msgid "Register Page:" msgstr "" -#: admin/tab-options.php:199 +#: admin/tab-options.php:215 msgid "For creating a register link in the login form" msgstr "" -#: admin/tab-options.php:208 +#: admin/tab-options.php:224 msgid "User Profile Page:" msgstr "" -#: admin/tab-options.php:211 +#: admin/tab-options.php:227 msgid "For creating a forgot password link in the login form" msgstr "" -#: admin/tab-options.php:217 admin/tab-options.php:219 +#: admin/tab-options.php:233 admin/tab-options.php:235 msgid "Stylesheet" msgstr "" -#: admin/tab-options.php:228 +#: admin/tab-options.php:244 msgid "Custom Stylesheet:" msgstr "" -#: admin/tab-options.php:234 admin/tab-options.php:260 +#: admin/tab-options.php:249 admin/tab-options.php:276 msgid "Update Settings" msgstr "" -#: admin/tab-options.php:241 +#: admin/tab-options.php:257 msgid "Custom Post Types" msgstr "" -#: admin/tab-options.php:342 +#: admin/tab-options.php:263 +msgid "Add to WP-Members Settings" +msgstr "" + +#: admin/tab-options.php:360 msgid "Custom Post Type settings were updated" msgstr "" -#: admin/tab-options.php:460 +#: admin/tab-options.php:481 msgid "WP-Members settings were updated" msgstr "" -#: admin/tab-options.php:530 admin/tab-options.php:559 +#: admin/tab-options.php:551 admin/tab-options.php:581 msgid "USE CUSTOM URL BELOW" msgstr "" -#: admin/tab-options.php:548 +#: admin/tab-options.php:570 msgid "Select a page" msgstr "" -#: admin/user-export.php:72 +#: admin/user-export.php:81 msgid "Activated?" msgstr "" -#: admin/user-export.php:73 +#: admin/user-export.php:85 msgid "Subscription" msgstr "" -#: admin/user-export.php:73 -msgid "Expires" -msgstr "" - -#: admin/user-export.php:75 +#: admin/user-export.php:89 msgid "Registered" msgstr "" -#: admin/user-export.php:76 +#: admin/user-export.php:90 msgid "IP" msgstr "" -#: admin/user-export.php:108 admin/users.php:336 -msgid "No" -msgstr "" - -#: admin/user-profile.php:52 -msgid "WP-Members Additional Fields" +#: admin/user-export.php:120 +msgid "Yes" msgstr "" -#: admin/user-profile.php:115 inc/users.php:90 inc/wp-registration.php:37 -#: inc/wp-registration.php:154 -msgid "(required)" +#: admin/user-export.php:120 admin/users.php:404 +msgid "No" msgstr "" -#: admin/user-profile.php:283 +#: admin/user-profile.php:43 inc/wp-registration.php:278 msgid "Activate this user?" msgstr "" -#: admin/user-profile.php:288 +#: admin/user-profile.php:48 msgid "Reactivate this user?" msgstr "" -#: admin/user-profile.php:293 +#: admin/user-profile.php:53 msgid "Deactivate this user?" msgstr "" -#: admin/user-profile.php:339 +#: admin/user-profile.php:101 msgid "IP @ registration" msgstr "" -#: admin/users.php:59 admin/users.php:63 +#: admin/users.php:48 admin/users.php:52 admin/users.php:79 msgid "Activate" msgstr "" -#: admin/users.php:61 admin/users.php:65 +#: admin/users.php:50 admin/users.php:54 msgid "Export" msgstr "" -#: admin/users.php:66 admin/users.php:107 +#: admin/users.php:55 admin/users.php:103 msgid "Export All Users" msgstr "" -#: inc/class-wp-members-widget.php:18 +#: admin/users.php:148 +#, php-format +msgid "%s users activated" +msgstr "" + +#: admin/users.php:151 +msgid "No users selected" +msgstr "" + +#: admin/users.php:175 +#, php-format +msgid "%s activated" +msgstr "" + +#: admin/users.php:180 +msgid "That user is already active" +msgstr "" + +#: inc/api.php:495 inc/class-wp-members.php:1272 +msgid "log in" +msgstr "" + +#: inc/api.php:496 +msgid "log out" +msgstr "" + +#: inc/class-wp-members-products.php:89 +msgid "Product" +msgstr "" + +#: inc/class-wp-members-products.php:90 +msgid "Products" +msgstr "" + +#: inc/class-wp-members-products.php:95 +msgid "Memberships" +msgstr "" + +#: inc/class-wp-members-products.php:96 +#, php-format +msgid "All %s" +msgstr "" + +#: inc/class-wp-members-products.php:97 +#, php-format +msgid "Add New %s" +msgstr "" + +#: inc/class-wp-members-products.php:98 +msgid "Add New" +msgstr "" + +#: inc/class-wp-members-products.php:99 +#, php-format +msgid "New %s" +msgstr "" + +#: inc/class-wp-members-products.php:100 +#, php-format +msgid "Edit %s" +msgstr "" + +#: inc/class-wp-members-products.php:101 +#, php-format +msgid "Update %s" +msgstr "" + +#: inc/class-wp-members-products.php:102 inc/class-wp-members-products.php:103 +#, php-format +msgid "View %s" +msgstr "" + +#: inc/class-wp-members-products.php:104 +#, php-format +msgid "Search %s" +msgstr "" + +#: inc/class-wp-members-products.php:105 +msgid "Not found" +msgstr "" + +#: inc/class-wp-members-products.php:106 +msgid "Not found in Trash" +msgstr "" + +#: inc/class-wp-members-products.php:107 +msgid "Insert into item" +msgstr "" + +#: inc/class-wp-members-products.php:108 +#, php-format +msgid "Save %s Details" +msgstr "" + +#: inc/class-wp-members-products.php:111 +msgid "Membership Product" +msgstr "" + +#: inc/class-wp-members-products.php:112 +msgid "WP-Members Membership Products" +msgstr "" + +#: inc/class-wp-members-user-profile.php:37 inc/deprecated.php:315 +msgid "WP-Members Additional Fields" +msgstr "" + +#: inc/class-wp-members-user-profile.php:37 inc/deprecated.php:589 +msgid "Additional Information" +msgstr "" + +#: inc/class-wp-members-user.php:532 +msgid "ERROR: User has not been activated." +msgstr "" + +#: inc/class-wp-members-widget.php:24 msgid "Displays the WP-Members sidebar login." msgstr "" -#: inc/class-wp-members-widget.php:33 inc/class-wp-members-widget.php:76 +#: inc/class-wp-members-widget.php:39 inc/class-wp-members-widget.php:82 msgid "Login Status" msgstr "" -#: inc/class-wp-members-widget.php:40 +#: inc/class-wp-members-widget.php:46 msgid "Title:" msgstr "" -#: inc/class-wp-members-widget.php:44 +#: inc/class-wp-members-widget.php:50 msgid "Redirect to (optional):" msgstr "" -#: inc/class-wp-members.php:388 inc/shortcodes.php:117 inc/shortcodes.php:386 +#: inc/class-wp-members.php:757 inc/deprecated.php:180 inc/shortcodes.php:97 +#: inc/shortcodes.php:325 msgid "There was an error with the CAPTCHA form." msgstr "" -#: inc/class-wp-members.php:546 +#: inc/class-wp-members.php:1171 msgid "First Name" msgstr "" -#: inc/class-wp-members.php:547 +#: inc/class-wp-members.php:1172 msgid "Last Name" msgstr "" -#: inc/class-wp-members.php:548 +#: inc/class-wp-members.php:1173 msgid "Address 1" msgstr "" -#: inc/class-wp-members.php:549 +#: inc/class-wp-members.php:1174 msgid "Address 2" msgstr "" -#: inc/class-wp-members.php:550 +#: inc/class-wp-members.php:1175 msgid "City" msgstr "" -#: inc/class-wp-members.php:551 +#: inc/class-wp-members.php:1176 msgid "State" msgstr "" -#: inc/class-wp-members.php:552 +#: inc/class-wp-members.php:1177 msgid "Zip" msgstr "" -#: inc/class-wp-members.php:553 +#: inc/class-wp-members.php:1178 msgid "Country" msgstr "" -#: inc/class-wp-members.php:554 +#: inc/class-wp-members.php:1179 msgid "Day Phone" msgstr "" -#: inc/class-wp-members.php:555 inc/class-wp-members.php:588 +#: inc/class-wp-members.php:1180 inc/class-wp-members.php:1211 msgid "Email" msgstr "" -#: inc/class-wp-members.php:556 +#: inc/class-wp-members.php:1181 msgid "Confirm Email" msgstr "" -#: inc/class-wp-members.php:557 +#: inc/class-wp-members.php:1182 msgid "Website" msgstr "" -#: inc/class-wp-members.php:558 +#: inc/class-wp-members.php:1183 msgid "Biographical Info" msgstr "" -#: inc/class-wp-members.php:559 inc/class-wp-members.php:569 -#: inc/class-wp-members.php:645 +#: inc/class-wp-members.php:1184 inc/class-wp-members.php:1194 +#: inc/class-wp-members.php:1271 msgid "Password" msgstr "" -#: inc/class-wp-members.php:560 +#: inc/class-wp-members.php:1185 msgid "Confirm Password" msgstr "" -#: inc/class-wp-members.php:561 +#: inc/class-wp-members.php:1186 msgid "TOS" msgstr "" -#: inc/class-wp-members.php:567 +#: inc/class-wp-members.php:1192 msgid "Existing Users Log In" msgstr "" -#: inc/class-wp-members.php:568 inc/class-wp-members.php:587 -#: inc/class-wp-members.php:608 inc/class-wp-members.php:644 +#: inc/class-wp-members.php:1193 inc/class-wp-members.php:1210 +#: inc/class-wp-members.php:1233 inc/class-wp-members.php:1270 msgid "Username" msgstr "" -#: inc/class-wp-members.php:570 +#: inc/class-wp-members.php:1195 inc/shortcodes.php:645 msgid "Log In" msgstr "" -#: inc/class-wp-members.php:571 +#: inc/class-wp-members.php:1196 msgid "Remember Me" msgstr "" -#: inc/class-wp-members.php:572 +#: inc/class-wp-members.php:1197 msgid "Forgot password?" msgstr "" -#: inc/class-wp-members.php:573 +#: inc/class-wp-members.php:1198 msgid "Click here to reset" msgstr "" -#: inc/class-wp-members.php:574 +#: inc/class-wp-members.php:1199 msgid "New User?" msgstr "" -#: inc/class-wp-members.php:575 +#: inc/class-wp-members.php:1200 msgid "Click here to register" msgstr "" -#: inc/class-wp-members.php:576 -msgid "Forgot username?" -msgstr "" - -#: inc/class-wp-members.php:577 -msgid "Click here" -msgstr "" - -#: inc/class-wp-members.php:580 inc/class-wp-members.php:630 +#: inc/class-wp-members.php:1203 inc/class-wp-members.php:1256 msgid "Change Password" msgstr "" -#: inc/class-wp-members.php:581 +#: inc/class-wp-members.php:1204 msgid "New password" msgstr "" -#: inc/class-wp-members.php:582 +#: inc/class-wp-members.php:1205 msgid "Confirm new password" msgstr "" -#: inc/class-wp-members.php:583 +#: inc/class-wp-members.php:1206 msgid "Update Password" msgstr "" -#: inc/class-wp-members.php:586 +#: inc/class-wp-members.php:1209 msgid "Reset Forgotten Password" msgstr "" -#: inc/class-wp-members.php:589 +#: inc/class-wp-members.php:1212 msgid "Reset Password" msgstr "" -#: inc/class-wp-members.php:592 inc/class-wp-members.php:594 +#: inc/class-wp-members.php:1213 +msgid "Forgot username?" +msgstr "" + +#: inc/class-wp-members.php:1214 +msgid "Click here" +msgstr "" + +#: inc/class-wp-members.php:1217 inc/class-wp-members.php:1219 msgid "Retrieve username" msgstr "" -#: inc/class-wp-members.php:593 +#: inc/class-wp-members.php:1218 msgid "Email Address" msgstr "" -#: inc/class-wp-members.php:597 +#: inc/class-wp-members.php:1222 msgid "New User Registration" msgstr "" -#: inc/class-wp-members.php:598 +#: inc/class-wp-members.php:1223 msgid "Choose a Username" msgstr "" -#: inc/class-wp-members.php:599 +#: inc/class-wp-members.php:1224 msgid "Input the code:" msgstr "" -#: inc/class-wp-members.php:600 +#: inc/class-wp-members.php:1225 #, php-format msgid "Please indicate that you agree to the %s TOS %s" msgstr "" -#: inc/class-wp-members.php:601 +#: inc/class-wp-members.php:1226 msgid "Reset Form" msgstr "" -#: inc/class-wp-members.php:602 inc/class-wp-members.php:648 inc/core.php:522 +#: inc/class-wp-members.php:1227 inc/class-wp-members.php:1274 +#: inc/shortcodes.php:642 inc/wp-registration.php:352 msgid "Register" msgstr "" -#: inc/class-wp-members.php:604 +#: inc/class-wp-members.php:1229 msgid "Required field" msgstr "" -#: inc/class-wp-members.php:607 inc/shortcodes.php:432 +#: inc/class-wp-members.php:1232 inc/deprecated.php:226 msgid "Edit Your Information" msgstr "" -#: inc/class-wp-members.php:609 +#: inc/class-wp-members.php:1234 msgid "Update Profile" msgstr "" -#: inc/class-wp-members.php:610 +#: inc/class-wp-members.php:1235 msgid "Update this file" msgstr "" -#: inc/class-wp-members.php:613 +#: inc/class-wp-members.php:1238 msgid "Login Failed!" msgstr "" -#: inc/class-wp-members.php:614 +#: inc/class-wp-members.php:1239 msgid "You entered an invalid username or password." msgstr "" -#: inc/class-wp-members.php:615 +#: inc/class-wp-members.php:1240 msgid "Click here to continue." msgstr "" -#: inc/class-wp-members.php:616 +#: inc/class-wp-members.php:1241 msgid "Password fields cannot be empty" msgstr "" -#: inc/class-wp-members.php:617 +#: inc/class-wp-members.php:1242 msgid "Sorry, that email address was not found." msgstr "" -#: inc/class-wp-members.php:618 +#: inc/class-wp-members.php:1243 #, php-format msgid "An email was sent to %s with your username." msgstr "" -#: inc/class-wp-members.php:619 +#: inc/class-wp-members.php:1244 #, php-format msgid "Sorry, %s is a required field." msgstr "" -#: inc/class-wp-members.php:620 +#: inc/class-wp-members.php:1245 msgid "You must enter a valid email address." msgstr "" -#: inc/class-wp-members.php:621 +#: inc/class-wp-members.php:1246 msgid "The username cannot include non-alphanumeric characters." msgstr "" -#: inc/class-wp-members.php:622 +#: inc/class-wp-members.php:1247 msgid "Sorry, username is a required field" msgstr "" -#: inc/class-wp-members.php:623 +#: inc/class-wp-members.php:1248 msgid "Passwords did not match." msgstr "" -#: inc/class-wp-members.php:624 +#: inc/class-wp-members.php:1249 msgid "Emails did not match." msgstr "" -#: inc/class-wp-members.php:625 +#: inc/class-wp-members.php:1250 msgid "You must complete the CAPTCHA form." msgstr "" -#: inc/class-wp-members.php:626 +#: inc/class-wp-members.php:1251 msgid "CAPTCHA was not valid." msgstr "" -#: inc/class-wp-members.php:629 +#: inc/class-wp-members.php:1252 inc/register.php:53 +msgid "There was an error processing the form." +msgstr "" + +#: inc/class-wp-members.php:1255 msgid "Edit My Information" msgstr "" -#: inc/class-wp-members.php:631 inc/class-wp-members.php:634 -#: inc/class-wp-members.php:636 inc/class-wp-members.php:640 +#: inc/class-wp-members.php:1257 inc/class-wp-members.php:1260 +#: inc/class-wp-members.php:1262 inc/class-wp-members.php:1266 #, php-format msgid "You are logged in as %s" msgstr "" -#: inc/class-wp-members.php:632 +#: inc/class-wp-members.php:1258 msgid "Click to log out." msgstr "" -#: inc/class-wp-members.php:633 +#: inc/class-wp-members.php:1259 msgid "Begin using the site." msgstr "" -#: inc/class-wp-members.php:635 +#: inc/class-wp-members.php:1261 msgid "Click to log out" msgstr "" -#: inc/class-wp-members.php:637 +#: inc/class-wp-members.php:1263 msgid "click to log out" msgstr "" -#: inc/class-wp-members.php:641 +#: inc/class-wp-members.php:1267 msgid "click here to log out" msgstr "" -#: inc/class-wp-members.php:642 +#: inc/class-wp-members.php:1268 msgid "Login Failed!
    You entered an invalid username or password." msgstr "" -#: inc/class-wp-members.php:643 +#: inc/class-wp-members.php:1269 msgid "You are not logged in." msgstr "" -#: inc/class-wp-members.php:646 -msgid "log in" -msgstr "" - -#: inc/class-wp-members.php:647 +#: inc/class-wp-members.php:1273 msgid "Forgot?" msgstr "" -#: inc/class-wp-members.php:651 +#: inc/class-wp-members.php:1277 msgid "" "This content is restricted to site members. If you are an existing user, " "please log in. New users may register below." msgstr "" -#: inc/class-wp-members.php:652 +#: inc/class-wp-members.php:1278 msgid "Sorry, that username is taken, please try another." msgstr "" -#: inc/class-wp-members.php:653 +#: inc/class-wp-members.php:1279 msgid "" "Sorry, that email address already has an account.
    Please try another." msgstr "" -#: inc/class-wp-members.php:654 +#: inc/class-wp-members.php:1280 msgid "" "Congratulations! Your registration was successful.

    You may now " "log in using the password that was emailed to you." msgstr "" -#: inc/class-wp-members.php:655 +#: inc/class-wp-members.php:1281 msgid "Your information was updated!" msgstr "" -#: inc/class-wp-members.php:656 +#: inc/class-wp-members.php:1282 msgid "Passwords did not match.

    Please try again." msgstr "" -#: inc/class-wp-members.php:657 +#: inc/class-wp-members.php:1283 msgid "Password successfully changed!" msgstr "" -#: inc/class-wp-members.php:658 +#: inc/class-wp-members.php:1284 msgid "Either the username or email address do not exist in our records." msgstr "" -#: inc/class-wp-members.php:659 +#: inc/class-wp-members.php:1285 msgid "" "Password successfully reset!

    An email containing a new password " "has been sent to the email address on file for your account." msgstr "" -#: inc/core.php:106 -msgid "ERROR: User has not been activated." -msgstr "" - -#: inc/register.php:45 -msgid "There was an error processing the form." -msgstr "" - -#: inc/register.php:557 +#: inc/register.php:407 msgid "We were unable to validate the public key." msgstr "" -#: inc/register.php:561 +#: inc/register.php:411 msgid "We were unable to validate the private key." msgstr "" -#: inc/register.php:565 +#: inc/register.php:415 msgid "The challenge parameter of the verify script was incorrect." msgstr "" -#: inc/register.php:569 +#: inc/register.php:419 msgid "The CAPTCHA solution was incorrect." msgstr "" -#: inc/register.php:573 +#: inc/register.php:423 msgid "The parameters to verify were incorrect" msgstr "" -#: inc/register.php:577 +#: inc/register.php:427 msgid "" "reCAPTCHA API keys are tied to a specific domain name for security reasons." msgstr "" -#: inc/register.php:581 +#: inc/register.php:431 msgid "The reCAPTCHA server was not reached. Please try to resubmit." msgstr "" -#: inc/register.php:585 +#: inc/register.php:435 msgid "You have entered an incorrect code value. Please try again." msgstr "" -#: inc/shortcodes.php:346 +#: inc/shortcodes.php:576 msgid "Click here to log out." msgstr "" -#: inc/users.php:37 -msgid "Additional Information" -msgstr "" - -#: inc/utilities.php:202 +#: inc/utilities.php:121 msgid "(more…)" msgstr "" diff --git a/readme.txt b/readme.txt index ced9030e..99dea70c 100644 --- a/readme.txt +++ b/readme.txt @@ -6,11 +6,13 @@ Tested up to: 4.9 Stable tag: 3.2.0 License: GPLv2 -WP-Members membership plugin turns your WordPress site into a membership site. Restrict premium content, require registration with custom fields, and more. +WP-Members membership plugin turns your WordPress site into a membership site. Restrict premium content, create custom registration fields, and more. == Description == -WP-Members™ is the original membership plugin for WordPress®. Perfect for newsletters, premium content sites, clubs/associations, and more! +=== Membership Sites. Simplified. === + +You need a membership site. You want to focus on your business, not mastering a plugin. WP-Members is simple to use, yet flexible in every way imaginable. The plugin restricts selected WordPress® content to registered site members. WP-Members™ puts the registration process on the site front end so it is inline with your content rather than the native WP login page. WP-Members™ requires __no__ modifications to your theme while remainging scalable for users who want to customize the look and feel, or want to restrict only some content. It is a great tool for sites offering premium content to subscribers, and is adaptable to a variety of applications. @@ -153,6 +155,15 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * Fixes issue with login status if logout url is encoded (sprintf() has too few arguments). * Added Membership Products Custom Post Type. * Added "Hide Post" option for blocking content (currently only by post meta _wpmem_block). +* Removed several outdated stylesheets from selecion ( still download for users who may use them). +* Fixed issue with login page logged in state if encoded url exists (decode logout link url). +* Added wpmem_update_user_role() API function. +* Added wpmem_display_message() API function. +* Added wpmem_user_has_access() API function. +* HTML5 update - form anchor tags changed from "name" to "id". +* HTML5 update - form id tags set default value (can still be filtered). +* HTML5 update - removed "align" attribute (captcha, link-text). +* Moved remaining core functions to appropriate object classes, left wrappers for most. = 3.1.9 = From 0104b418a6321bcc05a034d695e7d4afa1c537fc Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 22 Nov 2017 09:47:21 -0600 Subject: [PATCH 0730/1694] password change fix (action was not passing 2nd argument which is the password) --- inc/class-wp-members.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 5e12a5bc..7c58c83f 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -373,7 +373,7 @@ function load_hooks() { add_action( 'login_enqueue_scripts', 'wpmem_wplogin_stylesheet' ); // styles the native registration add_action( 'wp_enqueue_scripts', 'wpmem_enqueue_style' ); // Enqueues the stylesheet. add_action( 'init', array( $this->membership, 'add_cpt' ), 0 ); // Adds membership plans custom post type. - add_action( 'wpmem_pwd_change', array( $this->user, 'set_as_logged_in' ) ); + add_action( 'wpmem_pwd_change', array( $this->user, 'set_as_logged_in' ), 10, 2 ); add_action( 'pre_get_posts', array( $this, 'do_hide_posts' ) ); // Add filters. From 91e8bb6ef72a37ef8bd6d51cdc3332c6986657e3 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 22 Nov 2017 09:48:04 -0600 Subject: [PATCH 0731/1694] screen_icon() is obsolete --- admin/admin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/admin.php b/admin/admin.php index b7736eb1..3c78fcc1 100644 --- a/admin/admin.php +++ b/admin/admin.php @@ -55,7 +55,7 @@ function wpmem_admin() { } ?>
    - + Date: Fri, 15 Dec 2017 10:47:56 -0500 Subject: [PATCH 0732/1694] Update README.md --- README.md | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 77021d59..c147b283 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,17 @@ This is the development repository for the WP-Members plugin for WordPress. ## Usage Information ## -Keep in mind that the branch here is a development branch, so it should be tested prior to loading to a production site. +Keep in mind that the branch here is a development branch, so it should be tested prior to loading to a production site. Although every effort is made to only load stable updates to this repo, this may not necessarily be production ready and some features may be subject to change prior to release. -If you are looking for a production ready version of the plugin, use the version hosted here: +If you need a production ready version of the plugin, use the version hosted here: http://wordpress.org/extend/plugins/wp-members/ + +## Bug Reporting and Pull Requests ## + +I do accept pull requests. However, I have a pretty strict standard on what goes into the production version of the plugin. So please make sure that your pull request actually makes sense and is a proper pull request. Also make sure that your code follows WP's code standards for both PHP and inline documentation. + +Make sure any bug reports are actually bugs. A bug is something broken. A bug is not a feature that you wish to operate differently than it currently does in the plugin. Unfortunately, I get a lot of bug reports that are essentially feature requests or a user's inability to follow setup instructions. I wish I didn't have to say that, but I do. + +## Feature Requests ## + +I am open to feature requests. However, I have a roadmap in place for the plugin so it ultimately needs to make sense for that. Also, I follow Matt Mullenweg's vision for options in WordPress, which essentially boils down to the fact that too many options make the interface more confusing. So something that is better handled as a customization (through actions and filters) will likely be addressed that way (as it should be) rather than being incorporated into the plugin. But if your idea is a good one, don't hold it back because you're not sure. All I'm saying is don't have hurt feelings if I see it differently. From 44234d698028fd6f406e225555b6643041f0a7a8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 30 Dec 2017 22:01:27 -0600 Subject: [PATCH 0733/1694] add username to fields array --- inc/class-wp-members-forms.php | 43 +++------------------------------- wp-members-install.php | 18 +++++++++++++- 2 files changed, 20 insertions(+), 41 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index be14be64..a58c626e 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -731,42 +731,6 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { // Merge $args with defaults. $args = wp_parse_args( $args, $defaults ); - // Username is editable if new reg, otherwise user profile is not. - if ( 'edit' == $tag ) { - // This is the User Profile edit - username is not editable. - $val = $userdata->user_login; - $label = ''; - $input = '

    ' . $val . '

    '; - $field_before = ( $args['wrap_inputs'] ) ? '
    ' : ''; - $field_after = ( $args['wrap_inputs'] ) ? '
    ' : ''; - } else { - // This is a new registration. - $val = ( isset( $_POST['user_login'] ) ) ? stripslashes( $_POST['user_login'] ) : ''; - $label = ''; - $input = wpmem_form_field( array( - 'name' => 'user_login', - 'type' => 'text', - 'value' => $val, - 'compare' => '', - 'required' => true, - ) ); - - } - - // Add the username row to the array. - $rows['username'] = array( - 'meta' => 'username', - 'type' => 'text', - 'value' => $val, - 'label_text' => $wpmem->get_text( 'register_username' ), - 'row_before' => $args['row_before'], - 'label' => $label, - 'field_before' => ( $args['wrap_inputs'] ) ? '
    ' : '', - 'field' => $input, - 'field_after' => ( $args['wrap_inputs'] ) ? '
    ': '', - 'row_after' => $args['row_after'], - ); - /** * Filter the array of form fields. * @@ -792,7 +756,7 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { $val = ''; $label = ''; $input = ''; $field_before = ''; $field_after = ''; // Skips user selected passwords for profile update. - $pass_arr = array( 'password', 'confirm_password', 'password_confirm' ); + $pass_arr = array( 'username', 'password', 'confirm_password', 'password_confirm' ); $do_row = ( 'edit' == $tag && in_array( $meta_key, $pass_arr ) ) ? false : true; // Skips tos, makes tos field hidden on user edit page, unless they haven't got a value for tos. @@ -827,7 +791,7 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { $class = ( $field['type'] == 'password' || $field['type'] == 'email' || $field['type'] == 'url' ) ? 'text' : $field['type']; $label = wpmem_form_label( array( - 'meta_key' => $meta_key, + 'meta_key' => ( 'username' == $meta_key ) ? 'user_login' : $meta_key, 'label' => __( $field['label'], 'wp-members' ), 'type' => $field['type'], 'class' => $class, @@ -948,9 +912,8 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { } else { // For all other input types. - //$input = wpmem_create_formfield( $meta_key, $field['type'], $val, $valtochk ); $formfield_args = array( - 'name' => $meta_key, + 'name' => ( 'username' == $meta_key ) ? 'user_login' : $meta_key, 'type' => $field['type'], 'value' => $val, 'compare' => $valtochk, diff --git a/wp-members-install.php b/wp-members-install.php index 13763317..062a6590 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -61,6 +61,7 @@ function wpmem_do_install() { $wpmem_settings = wpmem_upgrade_settings(); wpmem_upgrade_captcha(); wpmem_append_email(); + wpmem_upgrade_fields(); } @@ -540,6 +541,7 @@ function wpmem_install_settings() { */ function wpmem_install_fields() { $fields = array( + array( 0, 'Choose a Username', 'username', 'text', 'y', 'y', 'y' ), array( 1, 'First Name', 'first_name', 'text', 'y', 'y', 'y' ), array( 2, 'Last Name', 'last_name', 'text', 'y', 'y', 'y' ), array( 3, 'Address 1', 'billing_address_1', 'text', 'y', 'y', 'n' ), @@ -555,7 +557,7 @@ function wpmem_install_fields() { array( 13, 'Biographical Info', 'description', 'textarea', 'n', 'n', 'y' ), array( 14, 'Password', 'password', 'password', 'n', 'n', 'n' ), array( 15, 'Confirm Password', 'confirm_password', 'password', 'n', 'n', 'n' ), - array( 16, 'TOS', 'tos', 'checkbox', 'n', 'n', 'n', 'agree', 'n' ), + array( 16, 'Terms of Service', 'tos', 'checkbox', 'n', 'n', 'n', 'agree', 'n' ), ); update_option( 'wpmembers_fields', $fields, '', 'yes' ); // using update_option to allow for forced update return $fields; @@ -584,4 +586,18 @@ function wpmem_install_dialogs() { update_option( 'wpmembers_dialogs', $wpmem_dialogs_arr, '', 'yes' ); // using update_option to allow for forced update } +/** + * Upgrades fields settings. + * + * @since 3.2.0 + */ +function wpmem_upgrade_fields() { + $fields = get_option( 'wpmembers_fields' ); + // Check if username is in the array. + if ( ! array_key_exists( 'username', $fields ) ) { + $username_array = array( 0, 'Choose a Username', 'username', 'text', 'y', 'y', 'y' ); + array_unshift( $fields, $username_array ); + update_option( 'wpmembers_fields', $fields, '', 'yes' ); + } +} // End of file. \ No newline at end of file From 1e7ff8a5349ec968a4a411061ae510956cc63270 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 30 Dec 2017 22:04:40 -0600 Subject: [PATCH 0734/1694] login and password forms to forms class, add login link span wrappers --- inc/class-wp-members-forms.php | 240 ++++++++++++++++++++++++++++++++- inc/forms.php | 184 +------------------------ 2 files changed, 243 insertions(+), 181 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index a58c626e..adc2b23d 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -420,6 +420,8 @@ function login_form( $page, $arr ) { 'buttons_after' => '
    ', 'link_before' => '', + 'link_span_before' => '', + 'link_span_after' => '', // classes & ids 'form_id' => 'wpmem_' . $arr['action'], @@ -571,6 +573,8 @@ function login_form( $page, $arr ) { */ $link = apply_filters( "wpmem_{$tag}_link", $value['link'] ); $str = $wpmem->get_text( "{$key}_link_before" ) . '' . $wpmem->get_text( "{$key}_link" ) . ''; + $link_str = $args['link_before']; + $link_str.= ( '' != $args['link_span_before'] ) ? sprintf( $args['link_span_before'], $key ) : ''; /** * Filters the register, forgot password, and forgot username links HTML. * @@ -581,7 +585,9 @@ function login_form( $page, $arr ) { * @param string $str The link HTML. * @param string $link The link. */ - $link = $args['link_before'] . apply_filters( "wpmem_{$tag}_link_str", $str, $link ) . $args['link_after'] . $args['n']; + $link_str.= apply_filters( "wpmem_{$tag}_link_str", $str, $link ); + $link_str.= ( '' != $args['link_span_after'] ) ? $args['link_span_after'] : ''; + $link_str.= $args['link_after'] . $args['n']; /* * If this is the register link, and the current post type is set to * display the register form, and the current page is not the login @@ -589,17 +595,17 @@ function login_form( $page, $arr ) { */ if ( 'register' == $key ) { if ( isset( $wpmem->user_pages['login'] ) && $wpmem->user_pages['login'] != '' ) { - $form = ( 1 == $wpmem->show_reg[ get_post_type( get_the_ID() ) ] && wpmem_current_url( true, false ) != wpmem_login_url() ) ? $form : $form . $link; + $form = ( 1 == $wpmem->show_reg[ get_post_type( get_the_ID() ) ] && wpmem_current_url( true, false ) != wpmem_login_url() ) ? $form : $form . $link_str; } else { global $post; if ( has_shortcode( $post->post_content, 'wpmem_profile' ) ) { $form = $form; } else { - $form = ( 1 == $wpmem->show_reg[ get_post_type( get_the_ID() ) ] && ! has_shortcode( $post->post_content, 'wpmem_form' ) ) ? $form : $form . $link; + $form = ( 1 == $wpmem->show_reg[ get_post_type( get_the_ID() ) ] && ! has_shortcode( $post->post_content, 'wpmem_form' ) ) ? $form : $form . $link_str; } } } else { - $form = $form . $link; + $form = $form . $link_str; } } } @@ -1017,7 +1023,9 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { // Put the rows from the array into $form. $form = ''; $enctype = ''; foreach ( $rows as $row_item ) { + // Check form to see if we need multipart enctype. $enctype = ( $row_item['type'] == 'file' || $row_item['type'] == 'image' ) ? "multipart/form-data" : $enctype; + // Assemble row pieces. $row = ( $row_item['row_before'] != '' ) ? $row_item['row_before'] . $args['n'] . $row_item['label'] . $args['n'] : $row_item['label'] . $args['n']; $row .= ( $row_item['field_before'] != '' ) ? $row_item['field_before'] . $args['n'] . $args['t'] . $row_item['field'] . $args['n'] . $row_item['field_after'] . $args['n'] : $row_item['field'] . $args['n']; $row .= ( $row_item['row_after'] != '' ) ? $row_item['row_after'] . $args['n'] : ''; @@ -1219,5 +1227,229 @@ function strip_breaks( $form, $rows ) { } return $form; } + + /** + * Login Dialog. + * + * Loads the login form for user login. + * + * @since 1.8 + * @since 3.1.4 Global $wpmem_regchk no longer needed. + * + * @global object $post The WordPress Post object. + * @global object $wpmem The WP_Members object. + * @param string $page If the form is being displayed in place of blocked content. Default: page. + * @param string $redirect_to Redirect URL. Default: null. + * @param string $show If the form is being displayed in place of blocked content. Default: show. + * @return string $str The generated html for the login form. + */ + function do_login_form( $page = "page", $redirect_to = null, $show = 'show' ) { + + global $post, $wpmem; + + $str = ''; + + if ( $page == "page" ) { + + if ( $wpmem->regchk != "success" ) { + + $dialogs = get_option( 'wpmembers_dialogs' ); + + // This shown above blocked content. + $msg = $wpmem->get_text( 'restricted_msg' ); + $msg = ( $dialogs['restricted_msg'] == $msg ) ? $msg : __( stripslashes( $dialogs['restricted_msg'] ), 'wp-members' ); + $str = '

    ' . $msg . '

    '; + + /** + * Filter the post restricted message. + * + * @since 2.7.3 + * + * @param string $str The post restricted message. + */ + $str = apply_filters( 'wpmem_restricted_msg', $str ); + + } + } + + // Create the default inputs. + $default_inputs = array( + array( + 'name' => $wpmem->get_text( 'login_username' ), + 'type' => 'text', + 'tag' => 'log', + 'class' => 'username', + 'div' => 'div_text', + ), + array( + 'name' => $wpmem->get_text( 'login_password' ), + 'type' => 'password', + 'tag' => 'pwd', + 'class' => 'password', + 'div' => 'div_text', + ), + ); + + /** + * Filter the array of login form fields. + * + * @since 2.9.0 + * + * @param array $default_inputs An array matching the elements used by default. + */ + $default_inputs = apply_filters( 'wpmem_inc_login_inputs', $default_inputs ); + + $defaults = array( + 'heading' => $wpmem->get_text( 'login_heading' ), + 'action' => 'login', + 'button_text' => $wpmem->get_text( 'login_button' ), + 'inputs' => $default_inputs, + 'redirect_to' => $redirect_to, + ); + + /** + * Filter the arguments to override login form defaults. + * + * @since 2.9.0 + * + * @param array $args An array of arguments to use. Default null. + */ + $args = apply_filters( 'wpmem_inc_login_args', '' ); + + $arr = wp_parse_args( $args, $defaults ); + + $str = ( $show == 'show' ) ? $str . wpmem_login_form( $page, $arr ) : $str; + + return $str; + } + + /** + * Change Password Dialog. + * + * Loads the form for changing password. + * + * @since 2.0.0 + * + * @global object $wpmem The WP_Members object. + * @return string $str The generated html for the change password form. + */ + function do_changepassword_form() { + + global $wpmem; + + // create the default inputs + $default_inputs = array( + array( + 'name' => $wpmem->get_text( 'pwdchg_password1' ), + 'type' => 'password', + 'tag' => 'pass1', + 'class' => 'password', + 'div' => 'div_text', + ), + array( + 'name' => $wpmem->get_text( 'pwdchg_password2' ), + 'type' => 'password', + 'tag' => 'pass2', + 'class' => 'password', + 'div' => 'div_text', + ), + ); + + /** + * Filter the array of change password form fields. + * + * @since 2.9.0 + * + * @param array $default_inputs An array matching the elements used by default. + */ + $default_inputs = apply_filters( 'wpmem_inc_changepassword_inputs', $default_inputs ); + + $defaults = array( + 'heading' => $wpmem->get_text( 'pwdchg_heading' ), + 'action' => 'pwdchange', + 'button_text' => $wpmem->get_text( 'pwdchg_button' ), + 'inputs' => $default_inputs, + ); + + /** + * Filter the arguments to override change password form defaults. + * + * @since 2.9.0 + * + * @param array $args An array of arguments to use. Default null. + */ + $args = apply_filters( 'wpmem_inc_changepassword_args', '' ); + + $arr = wp_parse_args( $args, $defaults ); + + $str = wpmem_login_form( 'page', $arr ); + + return $str; + } + + /** + * Reset Password Dialog. + * + * Loads the form for resetting password. + * + * @since 2.1.0 + * + * @global object $wpmem The WP_Members object. + * @return string $str The generated html fo the reset password form. + */ + function do_resetpassword_form() { + + global $wpmem; + + // Create the default inputs. + $default_inputs = array( + array( + 'name' => $wpmem->get_text( 'pwdreset_username' ), + 'type' => 'text', + 'tag' => 'user', + 'class' => 'username', + 'div' => 'div_text', + ), + array( + 'name' => $wpmem->get_text( 'pwdreset_email' ), + 'type' => 'text', + 'tag' => 'email', + 'class' => 'password', + 'div' => 'div_text', + ), + ); + + /** + * Filter the array of reset password form fields. + * + * @since 2.9.0 + * + * @param array $default_inputs An array matching the elements used by default. + */ + $default_inputs = apply_filters( 'wpmem_inc_resetpassword_inputs', $default_inputs ); + + $defaults = array( + 'heading' => $wpmem->get_text( 'pwdreset_heading' ), + 'action' => 'pwdreset', + 'button_text' => $wpmem->get_text( 'pwdreset_button' ), + 'inputs' => $default_inputs, + ); + + /** + * Filter the arguments to override reset password form defaults. + * + * @since 2.9.0 + * + * @param array $args An array of arguments to use. Default null. + */ + $args = apply_filters( 'wpmem_inc_resetpassword_args', '' ); + + $arr = wp_parse_args( $args, $defaults ); + + $str = wpmem_login_form( 'page', $arr ); + + return $str; + } + } // End of WP_Members_Forms class. \ No newline at end of file diff --git a/inc/forms.php b/inc/forms.php index 0213b753..7e8a6812 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -38,6 +38,7 @@ * * @since 1.8 * @since 3.1.4 Global $wpmem_regchk no longer needed. + * @since 3.2.0 Now a wrapper for $wpmem->forms->do_login_form() * * @global object $post The WordPress Post object. * @global object $wpmem The WP_Members object. @@ -47,83 +48,8 @@ * @return string $str The generated html for the login form. */ function wpmem_inc_login( $page = "page", $redirect_to = null, $show = 'show' ) { - - global $post, $wpmem; - - $str = ''; - - if ( $page == "page" ) { - - if ( $wpmem->regchk != "success" ) { - - $dialogs = get_option( 'wpmembers_dialogs' ); - - // This shown above blocked content. - $msg = $wpmem->get_text( 'restricted_msg' ); - $msg = ( $dialogs['restricted_msg'] == $msg ) ? $msg : __( stripslashes( $dialogs['restricted_msg'] ), 'wp-members' ); - $str = '

    ' . $msg . '

    '; - - /** - * Filter the post restricted message. - * - * @since 2.7.3 - * - * @param string $str The post restricted message. - */ - $str = apply_filters( 'wpmem_restricted_msg', $str ); - - } - } - - // Create the default inputs. - $default_inputs = array( - array( - 'name' => $wpmem->get_text( 'login_username' ), - 'type' => 'text', - 'tag' => 'log', - 'class' => 'username', - 'div' => 'div_text', - ), - array( - 'name' => $wpmem->get_text( 'login_password' ), - 'type' => 'password', - 'tag' => 'pwd', - 'class' => 'password', - 'div' => 'div_text', - ), - ); - - /** - * Filter the array of login form fields. - * - * @since 2.9.0 - * - * @param array $default_inputs An array matching the elements used by default. - */ - $default_inputs = apply_filters( 'wpmem_inc_login_inputs', $default_inputs ); - - $defaults = array( - 'heading' => $wpmem->get_text( 'login_heading' ), - 'action' => 'login', - 'button_text' => $wpmem->get_text( 'login_button' ), - 'inputs' => $default_inputs, - 'redirect_to' => $redirect_to, - ); - - /** - * Filter the arguments to override login form defaults. - * - * @since 2.9.0 - * - * @param array $args An array of arguments to use. Default null. - */ - $args = apply_filters( 'wpmem_inc_login_args', '' ); - - $arr = wp_parse_args( $args, $defaults ); - - $str = ( $show == 'show' ) ? $str . wpmem_login_form( $page, $arr ) : $str; - - return $str; + global $wpmem; + return $wpmem->forms->do_login_form( $page = "page", $redirect_to = null, $show = 'show' ); } endif; @@ -135,62 +61,14 @@ function wpmem_inc_login( $page = "page", $redirect_to = null, $show = 'show' ) * Loads the form for changing password. * * @since 2.0.0 + * @since 3.2.0 Now a wrapper for $wpmem->forms->do_changepassword_form() * * @global object $wpmem The WP_Members object. * @return string $str The generated html for the change password form. */ function wpmem_inc_changepassword() { - global $wpmem; - - // create the default inputs - $default_inputs = array( - array( - 'name' => $wpmem->get_text( 'pwdchg_password1' ), - 'type' => 'password', - 'tag' => 'pass1', - 'class' => 'password', - 'div' => 'div_text', - ), - array( - 'name' => $wpmem->get_text( 'pwdchg_password2' ), - 'type' => 'password', - 'tag' => 'pass2', - 'class' => 'password', - 'div' => 'div_text', - ), - ); - - /** - * Filter the array of change password form fields. - * - * @since 2.9.0 - * - * @param array $default_inputs An array matching the elements used by default. - */ - $default_inputs = apply_filters( 'wpmem_inc_changepassword_inputs', $default_inputs ); - - $defaults = array( - 'heading' => $wpmem->get_text( 'pwdchg_heading' ), - 'action' => 'pwdchange', - 'button_text' => $wpmem->get_text( 'pwdchg_button' ), - 'inputs' => $default_inputs, - ); - - /** - * Filter the arguments to override change password form defaults. - * - * @since 2.9.0 - * - * @param array $args An array of arguments to use. Default null. - */ - $args = apply_filters( 'wpmem_inc_changepassword_args', '' ); - - $arr = wp_parse_args( $args, $defaults ); - - $str = wpmem_login_form( 'page', $arr ); - - return $str; + return $wpmem->forms->do_changepassword_form(); } endif; @@ -202,62 +80,14 @@ function wpmem_inc_changepassword() { * Loads the form for resetting password. * * @since 2.1.0 + * @since 3.2.0 Now a wrapper for $wpmem->forms->do_resetpassword_form() * * @global object $wpmem The WP_Members object. * @return string $str The generated html fo the reset password form. */ function wpmem_inc_resetpassword() { - global $wpmem; - - // Create the default inputs. - $default_inputs = array( - array( - 'name' => $wpmem->get_text( 'pwdreset_username' ), - 'type' => 'text', - 'tag' => 'user', - 'class' => 'username', - 'div' => 'div_text', - ), - array( - 'name' => $wpmem->get_text( 'pwdreset_email' ), - 'type' => 'text', - 'tag' => 'email', - 'class' => 'password', - 'div' => 'div_text', - ), - ); - - /** - * Filter the array of reset password form fields. - * - * @since 2.9.0 - * - * @param array $default_inputs An array matching the elements used by default. - */ - $default_inputs = apply_filters( 'wpmem_inc_resetpassword_inputs', $default_inputs ); - - $defaults = array( - 'heading' => $wpmem->get_text( 'pwdreset_heading' ), - 'action' => 'pwdreset', - 'button_text' => $wpmem->get_text( 'pwdreset_button' ), - 'inputs' => $default_inputs, - ); - - /** - * Filter the arguments to override reset password form defaults. - * - * @since 2.9.0 - * - * @param array $args An array of arguments to use. Default null. - */ - $args = apply_filters( 'wpmem_inc_resetpassword_args', '' ); - - $arr = wp_parse_args( $args, $defaults ); - - $str = wpmem_login_form( 'page', $arr ); - - return $str; + return $wpmem->forms->do_resetpassword_form(); } endif; From 82c3d8211e2755e44c6e1bca4058715c7bea87e8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 30 Dec 2017 22:05:45 -0600 Subject: [PATCH 0735/1694] revised pot file --- lang/wp-members.pot | 1149 +++++++++++++++---------------------------- 1 file changed, 410 insertions(+), 739 deletions(-) diff --git a/lang/wp-members.pot b/lang/wp-members.pot index 954908f2..77edd927 100644 --- a/lang/wp-members.pot +++ b/lang/wp-members.pot @@ -3,16 +3,15 @@ msgid "" msgstr "" "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" "Project-Id-Version: WP-Members\n" -"POT-Creation-Date: 2017-11-16 15:04-0600\n" -"PO-Revision-Date: 2017-11-16 15:03-0600\n" +"POT-Creation-Date: 2016-05-03 17:34-0500\n" +"PO-Revision-Date: 2016-05-03 17:26-0500\n" "Last-Translator: \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.0.4\n" +"X-Generator: Poedit 1.8.7\n" "X-Poedit-Basepath: ..\n" -"X-Poedit-Flags-xgettext: --add-comments=translators:\n" "X-Poedit-WPHeader: wp-members.php\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;" @@ -21,24 +20,24 @@ msgstr "" "X-Poedit-SearchPath-0: .\n" "X-Poedit-SearchPathExcluded-0: *.js\n" -#: admin/admin.php:59 admin/includes/class-wp-members-admin-api.php:531 +#: admin/admin.php:72 admin/admin.php:143 msgid "Settings" msgstr "" -#: admin/dialogs.php:116 +#: admin/dialogs.php:104 msgid "" "Your WP settings allow anyone to register - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:117 +#: admin/dialogs.php:105 #, php-format msgid "" "You can %s change this here %s making sure the box next to \"Anyone can " "register\" is unchecked." msgstr "" -#: admin/dialogs.php:118 +#: admin/dialogs.php:106 msgid "" "This setting allows a link on the /wp-login.php page to register using the " "WP native registration process thus circumventing any registration you are " @@ -48,20 +47,20 @@ msgid "" "Settings." msgstr "" -#: admin/dialogs.php:122 +#: admin/dialogs.php:110 msgid "" "Your WP settings allow anyone to comment - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:123 +#: admin/dialogs.php:111 #, php-format msgid "" "You can %s change this here %s by checking the box next to \"Users must be " "registered and logged in to comment.\"" msgstr "" -#: admin/dialogs.php:124 +#: admin/dialogs.php:112 msgid "" "This setting allows any users to comment, whether or not they are " "registered. Depending on how you are using WP-Members will determine whether " @@ -69,330 +68,198 @@ msgid "" "you can choose to ignore these warning messages under WP-Members Settings." msgstr "" -#: admin/dialogs.php:128 +#: admin/dialogs.php:116 msgid "" "Your WP settings allow full text rss feeds - this is not the recommended " "setting." msgstr "" -#: admin/dialogs.php:129 +#: admin/dialogs.php:117 #, php-format msgid "" "You can %s change this here %s by changing \"For each article in a feed, show" "\" to \"Summary.\"" msgstr "" -#: admin/dialogs.php:130 +#: admin/dialogs.php:118 msgid "" "Leaving this set to full text allows anyone to read your protected content " "in an RSS reader. Changing this to Summary prevents this as your feeds will " "only show summary text." msgstr "" -#: admin/dialogs.php:134 +#: admin/dialogs.php:122 msgid "You have set WP-Members to hold registrations for approval" msgstr "" -#: admin/dialogs.php:135 +#: admin/dialogs.php:123 msgid "" "but you have not changed the default message for \"Registration Completed\" " "under \"WP-Members Dialogs and Error Messages.\" You should change this " "message to let users know they are pending approval." msgstr "" -#: admin/dialogs.php:139 -msgid "You have turned on reCAPTCHA" +#: admin/dialogs.php:127 +msgid "You have set WP-Members to turn off the registration process" msgstr "" -#: admin/dialogs.php:140 +#: admin/dialogs.php:128 msgid "" -"but you have not entered API keys. You will need both a public and private " -"key. The CAPTCHA will not display unless a valid API key is included." +"but you also set to moderate and/or email admin new registrations. You will " +"need to set up a registration page for users to register." msgstr "" -#: admin/dialogs.php:144 -msgid "You have active settings that are not recommended." +#: admin/dialogs.php:132 +msgid "You have turned on reCAPTCHA" msgstr "" -#: admin/dialogs.php:145 +#: admin/dialogs.php:133 msgid "" -"If you will not be changing these settings, you can turn off these warning " -"messages by checking the \"Ignore warning messages\" in the settings below." +"but you have not entered API keys. You will need both a public and private " +"key. The CAPTCHA will not display unless a valid API key is included." msgstr "" -#: admin/dialogs.php:169 +#: admin/dialogs.php:157 msgid "Version:" msgstr "" -#: admin/dialogs.php:170 +#: admin/dialogs.php:158 msgid "Quick Start Guide" msgstr "" -#: admin/dialogs.php:171 +#: admin/dialogs.php:159 msgid "Online User Guide" msgstr "" -#: admin/dialogs.php:172 +#: admin/dialogs.php:160 msgid "FAQs" msgstr "" -#: admin/dialogs.php:179 +#: admin/dialogs.php:167 msgid "Thank you for using WP-Members" msgstr "" -#: admin/dialogs.php:180 +#: admin/dialogs.php:168 msgid "A plugin developed by" msgstr "" -#: admin/dialogs.php:181 +#: admin/dialogs.php:169 msgid "Follow" msgstr "" -#: admin/dialogs.php:198 admin/dialogs.php:202 +#: admin/dialogs.php:186 admin/dialogs.php:190 msgid "Latest from RocketGeek" msgstr "" -#: admin/dialogs.php:219 admin/dialogs.php:232 +#: admin/dialogs.php:207 admin/dialogs.php:220 msgid "Latest from ButlerBlog" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:249 -msgid "Custom email" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:250 -#: admin/includes/class-wp-members-admin-api.php:252 -msgid "Subject" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:253 -msgid "Body" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:255 -msgid "Your custom email message content." -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:333 +#: admin/includes/class-wp-members-admin-api.php:220 msgid "Options" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:334 +#: admin/includes/class-wp-members-admin-api.php:221 msgid "Fields" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:335 +#: admin/includes/class-wp-members-admin-api.php:222 msgid "Dialogs" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:336 +#: admin/includes/class-wp-members-admin-api.php:223 msgid "Emails" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:352 +#: admin/includes/class-wp-members-admin-api.php:239 msgid "New Registration" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:361 +#: admin/includes/class-wp-members-admin-api.php:248 msgid "Registration is Moderated" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:367 +#: admin/includes/class-wp-members-admin-api.php:254 msgid "Registration is Moderated, User is Approved" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:375 +#: admin/includes/class-wp-members-admin-api.php:262 msgid "Password Reset" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:382 +#: admin/includes/class-wp-members-admin-api.php:269 msgid "Retrieve Username" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:390 +#: admin/includes/class-wp-members-admin-api.php:277 msgid "Admin Notification" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:416 -msgid "Restricted post (or page), displays above the login/registration form" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:417 -msgid "Username is taken" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:418 -msgid "Email is registered" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:419 -msgid "Registration completed" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:420 -msgid "User update" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:421 -msgid "Passwords did not match" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:422 -msgid "Password changes" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:423 -msgid "Username or email do not exist when trying to reset forgotten password" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:424 -msgid "Password reset" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:41 -msgid "Slug" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:42 -msgid "Role" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:43 -#: admin/includes/class-wp-members-products-admin.php:140 -#: admin/tab-fields.php:430 admin/user-export.php:86 -msgid "Expires" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:44 -msgid "Last updated" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:64 -msgid "No role required" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:69 -msgid "Does not expire" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:104 -msgid "Membership Product Details" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:120 -#: admin/includes/class-wp-members-products-admin.php:144 -msgid "Period" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:120 -msgid "Day" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:120 -msgid "Week" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:120 -msgid "Month" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:120 -msgid "Year" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:126 -msgid "Name (slug)" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:131 -msgid "Role Required?" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:134 -msgid "No Role" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:142 -#: admin/includes/class-wp-members-products-admin.php:143 -msgid "Number" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:216 -#: admin/tab-options.php:188 inc/class-wp-members-forms.php:934 -#: inc/class-wp-members-user-profile.php:92 inc/deprecated.php:360 -#: inc/deprecated.php:622 -msgid "None" -msgstr "" - -#: admin/includes/class-wp-members-products-admin.php:222 -msgid "Limit access to:" -msgstr "" - -#: admin/post.php:45 admin/post.php:47 admin/tab-options.php:95 +#: admin/post.php:51 admin/post.php:53 admin/tab-options.php:87 msgid "Block" msgstr "" -#: admin/post.php:46 admin/post.php:48 +#: admin/post.php:52 admin/post.php:54 msgid "Unblock" msgstr "" -#: admin/post.php:143 +#: admin/post.php:188 #, php-format -msgid "%s blocked" +msgid "%s Restriction" msgstr "" -#: admin/post.php:143 +#: admin/post.php:215 #, php-format -msgid "%s unblocked" +msgid "%s are blocked by default." msgstr "" -#: admin/post.php:182 +#: admin/post.php:216 #, php-format -msgid "%s Restriction" +msgid "Unblock this %s" msgstr "" -#: admin/post.php:210 +#: admin/post.php:219 #, php-format -msgid "%s are blocked by default." +msgid "%s are not blocked by default." msgstr "" -#: admin/post.php:214 +#: admin/post.php:220 #, php-format -msgid "%s are not blocked by default." +msgid "Block this %s" msgstr "" -#: admin/post.php:220 admin/tab-fields.php:88 admin/tab-fields.php:523 +#: admin/post.php:226 admin/tab-fields.php:282 admin/tab-fields.php:473 msgid "Edit" msgstr "" -#: admin/post.php:311 +#: admin/post.php:313 msgid "Unblocked?" msgstr "" -#: admin/post.php:311 +#: admin/post.php:313 msgid "Blocked?" msgstr "" -#: admin/tab-about.php:34 admin/tab-about.php:56 -msgid "About WP-Members" +#: admin/post.php:345 admin/post.php:346 admin/user-export.php:108 +msgid "Yes" msgstr "" -#: admin/tab-captcha.php:74 admin/tab-dialogs.php:40 admin/tab-emails.php:84 -#: admin/tab-fields.php:149 admin/tab-options.php:64 +#: admin/tab-captcha.php:42 admin/tab-dialogs.php:47 admin/tab-emails.php:80 +#: admin/tab-fields.php:44 admin/tab-options.php:58 msgid "Need help?" msgstr "" -#: admin/tab-captcha.php:85 +#: admin/tab-captcha.php:53 msgid "Manage reCAPTCHA Options" msgstr "" -#: admin/tab-captcha.php:99 +#: admin/tab-captcha.php:67 msgid "" "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " "while blocking spam on your blog." msgstr "" -#: admin/tab-captcha.php:100 +#: admin/tab-captcha.php:68 #, php-format msgid "" "reCAPTCHA asks commenters to retype two words scanned from a book to prove " @@ -402,1241 +269,1045 @@ msgid "" "the %s reCAPTCHA website%s" msgstr "" -#: admin/tab-captcha.php:105 admin/tab-captcha.php:131 +#: admin/tab-captcha.php:73 admin/tab-captcha.php:99 msgid "reCAPTCHA Keys" msgstr "" -#: admin/tab-captcha.php:107 +#: admin/tab-captcha.php:75 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:108 +#: admin/tab-captcha.php:76 msgid "Public Key" msgstr "" -#: admin/tab-captcha.php:109 +#: admin/tab-captcha.php:77 msgid "Private Key" msgstr "" -#: admin/tab-captcha.php:113 +#: admin/tab-captcha.php:81 msgid "Choose Theme" msgstr "" -#: admin/tab-captcha.php:116 +#: admin/tab-captcha.php:84 msgid "Red" msgstr "" -#: admin/tab-captcha.php:117 +#: admin/tab-captcha.php:85 msgid "White" msgstr "" -#: admin/tab-captcha.php:118 +#: admin/tab-captcha.php:86 msgid "Black Glass" msgstr "" -#: admin/tab-captcha.php:119 +#: admin/tab-captcha.php:87 msgid "Clean" msgstr "" -#: admin/tab-captcha.php:133 +#: admin/tab-captcha.php:101 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:134 +#: admin/tab-captcha.php:102 msgid "Site Key" msgstr "" -#: admin/tab-captcha.php:135 +#: admin/tab-captcha.php:103 msgid "Secret Key" msgstr "" -#: admin/tab-captcha.php:166 +#: admin/tab-captcha.php:134 msgid "Characters for image" msgstr "" -#: admin/tab-captcha.php:170 +#: admin/tab-captcha.php:138 msgid "Number of characters" msgstr "" -#: admin/tab-captcha.php:174 +#: admin/tab-captcha.php:142 msgid "Image dimensions" msgstr "" -#: admin/tab-captcha.php:175 +#: admin/tab-captcha.php:143 msgid "Width" msgstr "" -#: admin/tab-captcha.php:175 +#: admin/tab-captcha.php:143 msgid "Height" msgstr "" -#: admin/tab-captcha.php:178 +#: admin/tab-captcha.php:146 msgid "Font color of characters" msgstr "" -#: admin/tab-captcha.php:182 +#: admin/tab-captcha.php:150 msgid "Background color of image" msgstr "" -#: admin/tab-captcha.php:186 +#: admin/tab-captcha.php:154 msgid "Font size" msgstr "" -#: admin/tab-captcha.php:190 +#: admin/tab-captcha.php:158 msgid "Width between characters" msgstr "" -#: admin/tab-captcha.php:194 +#: admin/tab-captcha.php:162 msgid "Image type" msgstr "" -#: admin/tab-captcha.php:208 +#: admin/tab-captcha.php:176 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: admin/tab-captcha.php:232 +#: admin/tab-captcha.php:200 msgid "Update CAPTCHA Settings" msgstr "" -#: admin/tab-captcha.php:302 +#: admin/tab-captcha.php:271 msgid "CAPTCHA was updated for WP-Members" msgstr "" -#: admin/tab-dialogs.php:50 -msgid "Dialogs and Error Messages" +#: admin/tab-dialogs.php:32 +msgid "Restricted post (or page), displays above the login/registration form" msgstr "" -#: admin/tab-dialogs.php:52 -#, php-format -msgid "" -"You can customize the text for dialogs and error messages. Simple HTML is " -"allowed %s etc." +#: admin/tab-dialogs.php:33 +msgid "Username is taken" msgstr "" -#: admin/tab-dialogs.php:63 -msgid "Terms of Service (TOS)" +#: admin/tab-dialogs.php:34 +msgid "Email is registered" msgstr "" -#: admin/tab-dialogs.php:70 -msgid "Update Dialogs" +#: admin/tab-dialogs.php:35 +msgid "Registration completed" msgstr "" -#: admin/tab-dialogs.php:106 -msgid "WP-Members dialogs were updated" +#: admin/tab-dialogs.php:36 +msgid "User update" msgstr "" -#: admin/tab-dropins.php:79 admin/tab-dropins.php:378 -msgid "WP-Members Dropin settings were updated" +#: admin/tab-dialogs.php:37 +msgid "Passwords did not match" msgstr "" -#: admin/tab-dropins.php:204 -msgid "Manage Dropins" +#: admin/tab-dialogs.php:38 +msgid "Password changes" msgstr "" -#: admin/tab-dropins.php:205 -msgid "Current dropin folder: " +#: admin/tab-dialogs.php:39 +msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" -#: admin/tab-dropins.php:206 -msgid "" -"You can change location of the dropin folder using the " -"wpmem_dropin_folder filter." +#: admin/tab-dialogs.php:40 +msgid "Password reset" msgstr "" -#: admin/tab-dropins.php:269 -msgid "Name" +#: admin/tab-dialogs.php:57 +msgid "Dialogs and Error Messages" msgstr "" -#: admin/tab-dropins.php:270 -msgid "File" +#: admin/tab-dialogs.php:59 +#, php-format +msgid "" +"You can customize the text for dialogs and error messages. Simple HTML is " +"allowed %s etc." msgstr "" -#: admin/tab-dropins.php:271 -msgid "Version" +#: admin/tab-dialogs.php:72 +msgid "Terms of Service (TOS)" msgstr "" -#: admin/tab-dropins.php:272 -msgid "Description" +#: admin/tab-dialogs.php:79 +msgid "Update Dialogs" msgstr "" -#: admin/tab-dropins.php:315 admin/tab-fields.php:568 -msgid "Save Settings" +#: admin/tab-dialogs.php:118 +msgid "WP-Members dialogs were updated" msgstr "" -#: admin/tab-emails.php:41 +#: admin/tab-emails.php:37 msgid "Email Messages" msgstr "" -#: admin/tab-emails.php:44 +#: admin/tab-emails.php:40 msgid "You can customize the content of the emails sent by the plugin." msgstr "" -#: admin/tab-emails.php:46 +#: admin/tab-emails.php:42 msgid "A list of shortcodes is available here." msgstr "" -#: admin/tab-emails.php:53 +#: admin/tab-emails.php:49 msgid "Set a custom email address" msgstr "" -#: admin/tab-emails.php:54 admin/tab-emails.php:58 admin/tab-emails.php:68 -#: admin/tab-fields.php:175 +#: admin/tab-emails.php:50 admin/tab-emails.php:54 admin/tab-emails.php:64 msgid "(optional)" msgstr "" -#: admin/tab-emails.php:57 +#: admin/tab-emails.php:53 msgid "Set a custom email name" msgstr "" -#: admin/tab-emails.php:68 +#: admin/tab-emails.php:64 msgid "Email Signature" msgstr "" -#: admin/tab-emails.php:76 +#: admin/tab-emails.php:72 msgid "Update Emails" msgstr "" -#: admin/tab-emails.php:146 +#: admin/tab-emails.php:140 msgid "WP-Members emails were updated" msgstr "" -#: admin/tab-fields.php:110 -msgid "Are you sure you want to delete the following fields?" +#: admin/tab-fields.php:169 +msgid "WP-Members fields were updated" msgstr "" -#: admin/tab-fields.php:137 -msgid "Fields deleted" +#: admin/tab-fields.php:181 +msgid "Field Label is required for adding a new field. Nothing was updated." msgstr "" -#: admin/tab-fields.php:151 -msgid "Field Manager Documentation" +#: admin/tab-fields.php:182 +msgid "Option Name is required for adding a new field. Nothing was updated." msgstr "" -#: admin/tab-fields.php:176 admin/tab-fields.php:293 -#: inc/class-wp-members-user-profile.php:124 inc/deprecated.php:385 -#: inc/deprecated.php:646 inc/wp-registration.php:54 -#: inc/wp-registration.php:213 -msgid "(required)" +#: admin/tab-fields.php:184 +msgid "Option Name must contain only letters, numbers, and underscores" +msgstr "" + +#: admin/tab-fields.php:191 +msgid "A field with that option name already exists" +msgstr "" + +#: admin/tab-fields.php:197 +#, php-format +msgid "" +"Sorry, \"%s\" is a reserved term. " +"Field was not added." msgstr "" -#: admin/tab-fields.php:181 admin/tab-fields.php:378 +#: admin/tab-fields.php:215 +msgid "Checked value is required for checkboxes. Nothing was updated." +msgstr "" + +#: admin/tab-fields.php:245 +msgid "field was added" +msgstr "" + +#: admin/tab-fields.php:263 +msgid "field was updated" +msgstr "" + +#: admin/tab-fields.php:309 admin/tab-fields.php:437 msgid "Edit Field" msgstr "" -#: admin/tab-fields.php:181 +#: admin/tab-fields.php:309 msgid "Add a Field" msgstr "" -#: admin/tab-fields.php:186 +#: admin/tab-fields.php:315 admin/tab-fields.php:467 msgid "Field Label" msgstr "" -#: admin/tab-fields.php:188 +#: admin/tab-fields.php:317 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: admin/tab-fields.php:191 admin/tab-fields.php:518 -msgid "Meta Key" +#: admin/tab-fields.php:320 admin/tab-fields.php:468 +msgid "Option Name" msgstr "" -#: admin/tab-fields.php:197 +#: admin/tab-fields.php:326 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: admin/tab-fields.php:201 admin/tab-fields.php:519 +#: admin/tab-fields.php:330 admin/tab-fields.php:469 msgid "Field Type" msgstr "" -#: admin/tab-fields.php:207 +#: admin/tab-fields.php:336 msgid "text" msgstr "" -#: admin/tab-fields.php:208 +#: admin/tab-fields.php:337 msgid "email" msgstr "" -#: admin/tab-fields.php:209 +#: admin/tab-fields.php:338 msgid "textarea" msgstr "" -#: admin/tab-fields.php:210 +#: admin/tab-fields.php:339 msgid "checkbox" msgstr "" -#: admin/tab-fields.php:211 +#: admin/tab-fields.php:340 msgid "multiple checkbox" msgstr "" -#: admin/tab-fields.php:212 +#: admin/tab-fields.php:341 msgid "select (dropdown)" msgstr "" -#: admin/tab-fields.php:213 +#: admin/tab-fields.php:342 msgid "multiple select" msgstr "" -#: admin/tab-fields.php:214 +#: admin/tab-fields.php:343 msgid "radio group" msgstr "" -#: admin/tab-fields.php:215 +#: admin/tab-fields.php:344 msgid "password" msgstr "" -#: admin/tab-fields.php:216 +#: admin/tab-fields.php:345 msgid "image" msgstr "" -#: admin/tab-fields.php:217 +#: admin/tab-fields.php:346 msgid "file" msgstr "" -#: admin/tab-fields.php:218 +#: admin/tab-fields.php:347 msgid "url" msgstr "" -#: admin/tab-fields.php:219 -msgid "number" -msgstr "" - -#: admin/tab-fields.php:220 -msgid "date" -msgstr "" - -#: admin/tab-fields.php:221 +#: admin/tab-fields.php:348 msgid "hidden" msgstr "" -#: admin/tab-fields.php:226 admin/tab-fields.php:520 +#: admin/tab-fields.php:353 admin/tab-fields.php:470 msgid "Display?" msgstr "" -#: admin/tab-fields.php:230 admin/tab-fields.php:521 +#: admin/tab-fields.php:357 admin/tab-fields.php:471 msgid "Required?" msgstr "" -#: admin/tab-fields.php:235 -msgid "Allow HTML?" -msgstr "" - -#: admin/tab-fields.php:242 -msgid "Placeholder" -msgstr "" - -#: admin/tab-fields.php:250 -msgid "Pattern" -msgstr "" - -#: admin/tab-fields.php:256 -msgid "Title" +#: admin/tab-fields.php:363 +msgid "Additional information for field upload fields" msgstr "" -#: admin/tab-fields.php:265 -msgid "Minimum Value" -msgstr "" - -#: admin/tab-fields.php:269 -msgid "Maximum Value" -msgstr "" - -#: admin/tab-fields.php:277 +#: admin/tab-fields.php:366 msgid "Accepted file types:" msgstr "" -#: admin/tab-fields.php:282 +#: admin/tab-fields.php:371 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: admin/tab-fields.php:289 +#: admin/tab-fields.php:378 +msgid "Additional information for checkbox fields" +msgstr "" + +#: admin/tab-fields.php:381 msgid "Checked by default?" msgstr "" -#: admin/tab-fields.php:293 +#: admin/tab-fields.php:385 msgid "Stored value if checked:" msgstr "" -#: admin/tab-fields.php:314 -msgid "Stored values delimiter:" +#: admin/tab-fields.php:397 +msgid "Additional information for dropdown fields" msgstr "" -#: admin/tab-fields.php:323 -msgid "Values (Displayed|Stored):" +#: admin/tab-fields.php:400 +msgid "For dropdown, array of values:" msgstr "" -#: admin/tab-fields.php:348 +#: admin/tab-fields.php:425 msgid "Options should be Option Name|option_value," msgstr "" -#: admin/tab-fields.php:352 +#: admin/tab-fields.php:429 msgid "Visit plugin site for more information" msgstr "" -#: admin/tab-fields.php:359 -msgid "Value" -msgstr "" - -#: admin/tab-fields.php:378 admin/tab-fields.php:645 admin/tab-fields.php:646 +#: admin/tab-fields.php:437 msgid "Add Field" msgstr "" -#: admin/tab-fields.php:380 admin/tab-fields.php:831 -msgid "Return to Fields Table" -msgstr "" - -#: admin/tab-fields.php:420 -msgid "Drag and drop to reorder fields" -msgstr "" - -#: admin/tab-fields.php:426 -msgid "Registration Date" -msgstr "" - -#: admin/tab-fields.php:427 -msgid "Active" -msgstr "" - -#: admin/tab-fields.php:428 -msgid "Registration IP" -msgstr "" - -#: admin/tab-fields.php:429 -msgid "Subscription Type" -msgstr "" - -#: admin/tab-fields.php:431 -msgid "User ID" -msgstr "" - -#: admin/tab-fields.php:464 +#: admin/tab-fields.php:458 msgid "Manage Fields" msgstr "" -#: admin/tab-fields.php:503 -msgid "delete" -msgstr "" - -#: admin/tab-fields.php:517 -msgid "Display Label" -msgstr "" - -#: admin/tab-fields.php:524 -msgid "Users Screen" -msgstr "" - -#: admin/tab-fields.php:525 -msgid "Users Search" -msgstr "" - -#: admin/tab-fields.php:567 -msgid "Delete Selected" +#: admin/tab-fields.php:460 +msgid "" +"Determine which fields will display and which are required. This includes " +"all fields, both native WP fields and WP-Members custom fields." msgstr "" -#: admin/tab-fields.php:709 -msgid "WP-Members fields were updated" +#: admin/tab-fields.php:461 +msgid "(Note: Email is always mandatory and cannot be changed.)" msgstr "" -#: admin/tab-fields.php:731 -msgid "Field Label is required. Nothing was updated." +#: admin/tab-fields.php:466 +msgid "Add/Delete" msgstr "" -#: admin/tab-fields.php:732 -msgid "Meta Key is required. Nothing was updated." +#: admin/tab-fields.php:472 +msgid "Checked?" msgstr "" -#: admin/tab-fields.php:734 -msgid "Meta Key must contain only letters, numbers, and underscores" +#: admin/tab-fields.php:474 +msgid "Users Screen" msgstr "" -#: admin/tab-fields.php:741 -msgid "A field with that meta key already exists" +#: admin/tab-fields.php:486 +msgid "Delete" msgstr "" -#: admin/tab-fields.php:746 -#, php-format -msgid "" -"Sorry, \"%s\" is a reserved term. " -"Field was not added." +#: admin/tab-fields.php:498 +msgid "(Email cannot be removed)" msgstr "" -#: admin/tab-fields.php:779 -msgid "Checked value is required for checkboxes. Nothing was updated." +#: admin/tab-fields.php:518 +msgid "Registration Date" msgstr "" -#: admin/tab-fields.php:810 -msgid "A value is required for hidden fields. Nothing was updated." +#: admin/tab-fields.php:521 +msgid "native" msgstr "" -#: admin/tab-fields.php:817 -#, php-format -msgid "%s was added" +#: admin/tab-fields.php:531 +msgid "Active" msgstr "" -#: admin/tab-fields.php:830 -#, php-format -msgid "%s was updated" +#: admin/tab-fields.php:543 +msgid "Registration IP" msgstr "" -#: admin/tab-fields.php:872 -msgid "Form field order updated." +#: admin/tab-fields.php:578 +msgid "Update Fields" msgstr "" -#: admin/tab-options.php:75 +#: admin/tab-options.php:69 msgid "Manage Options" msgstr "" -#: admin/tab-options.php:79 -msgid "Content" -msgstr "" - -#: admin/tab-options.php:90 -msgid "Content Blocking" -msgstr "" - -#: admin/tab-options.php:94 +#: admin/tab-options.php:86 msgid "Do not block" msgstr "" -#: admin/tab-options.php:96 +#: admin/tab-options.php:88 msgid "Hide" msgstr "" -#: admin/tab-options.php:108 +#: admin/tab-options.php:99 msgid "Show Excerpts" msgstr "" -#: admin/tab-options.php:109 +#: admin/tab-options.php:100 msgid "Show Login Form" msgstr "" -#: admin/tab-options.php:110 +#: admin/tab-options.php:101 msgid "Show Registration Form" msgstr "" -#: admin/tab-options.php:111 +#: admin/tab-options.php:102 msgid "Auto Excerpt:" msgstr "" -#: admin/tab-options.php:133 +#: admin/tab-options.php:122 msgid "Number of words in excerpt:" msgstr "" -#: admin/tab-options.php:134 -msgid "Custom read more link (optional):" -msgstr "" - -#: admin/tab-options.php:148 +#: admin/tab-options.php:136 msgid "Time-based expiration" msgstr "" -#: admin/tab-options.php:148 +#: admin/tab-options.php:136 msgid "Allows for access to expire" msgstr "" -#: admin/tab-options.php:149 +#: admin/tab-options.php:137 msgid "Trial period" msgstr "" -#: admin/tab-options.php:149 +#: admin/tab-options.php:137 msgid "Allows for a trial period" msgstr "" -#: admin/tab-options.php:151 -msgid "Subscription Settings" -msgstr "" - -#: admin/tab-options.php:161 -msgid "Other Settings" -msgstr "" - -#: admin/tab-options.php:167 -msgid "Enable Products" -msgstr "" - -#: admin/tab-options.php:167 -msgid "Enables creation of different membership products" -msgstr "" - -#: admin/tab-options.php:168 -msgid "Clone menus" -msgstr "" - -#: admin/tab-options.php:168 -msgid "Enables logged in menus" -msgstr "" - -#: admin/tab-options.php:169 +#: admin/tab-options.php:153 msgid "Notify admin" msgstr "" -#: admin/tab-options.php:169 +#: admin/tab-options.php:153 #, php-format msgid "Notify %s for each new registration? %s" msgstr "" -#: admin/tab-options.php:170 +#: admin/tab-options.php:154 msgid "Moderate registration" msgstr "" -#: admin/tab-options.php:170 +#: admin/tab-options.php:154 msgid "Holds new registrations for admin approval" msgstr "" -#: admin/tab-options.php:171 +#: admin/tab-options.php:155 msgid "Ignore warning messages" msgstr "" -#: admin/tab-options.php:171 +#: admin/tab-options.php:155 msgid "Ignores WP-Members warning messages in the admin panel" msgstr "" -#: admin/tab-options.php:182 +#: admin/tab-options.php:167 msgid "Attribution" msgstr "" -#: admin/tab-options.php:184 +#: admin/tab-options.php:169 msgid "" "Attribution is appreciated! Display \"powered by\" link on register form?" msgstr "" -#: admin/tab-options.php:187 +#: admin/tab-options.php:172 msgid "Enable CAPTCHA" msgstr "" -#: admin/tab-options.php:192 -msgid "reCAPTCHA" -msgstr "" - -#: admin/tab-options.php:193 -msgid "Really Simple CAPTCHA" +#: admin/tab-options.php:174 admin/user-profile.php:97 inc/forms.php:806 +#: inc/users.php:70 +msgid "None" msgstr "" -#: admin/tab-options.php:196 +#: admin/tab-options.php:180 msgid "Pages" msgstr "" -#: admin/tab-options.php:200 +#: admin/tab-options.php:184 msgid "Login Page:" msgstr "" -#: admin/tab-options.php:203 +#: admin/tab-options.php:187 msgid "Specify a login page (optional)" msgstr "" -#: admin/tab-options.php:212 +#: admin/tab-options.php:196 msgid "Register Page:" msgstr "" -#: admin/tab-options.php:215 +#: admin/tab-options.php:199 msgid "For creating a register link in the login form" msgstr "" -#: admin/tab-options.php:224 +#: admin/tab-options.php:208 msgid "User Profile Page:" msgstr "" -#: admin/tab-options.php:227 +#: admin/tab-options.php:211 msgid "For creating a forgot password link in the login form" msgstr "" -#: admin/tab-options.php:233 admin/tab-options.php:235 +#: admin/tab-options.php:217 admin/tab-options.php:219 msgid "Stylesheet" msgstr "" -#: admin/tab-options.php:244 +#: admin/tab-options.php:228 msgid "Custom Stylesheet:" msgstr "" -#: admin/tab-options.php:249 admin/tab-options.php:276 +#: admin/tab-options.php:234 admin/tab-options.php:260 msgid "Update Settings" msgstr "" -#: admin/tab-options.php:257 +#: admin/tab-options.php:241 msgid "Custom Post Types" msgstr "" -#: admin/tab-options.php:263 -msgid "Add to WP-Members Settings" -msgstr "" - -#: admin/tab-options.php:360 +#: admin/tab-options.php:342 msgid "Custom Post Type settings were updated" msgstr "" -#: admin/tab-options.php:481 +#: admin/tab-options.php:460 msgid "WP-Members settings were updated" msgstr "" -#: admin/tab-options.php:551 admin/tab-options.php:581 +#: admin/tab-options.php:530 admin/tab-options.php:559 msgid "USE CUSTOM URL BELOW" msgstr "" -#: admin/tab-options.php:570 +#: admin/tab-options.php:548 msgid "Select a page" msgstr "" -#: admin/user-export.php:81 +#: admin/user-export.php:72 msgid "Activated?" msgstr "" -#: admin/user-export.php:85 +#: admin/user-export.php:73 msgid "Subscription" msgstr "" -#: admin/user-export.php:89 +#: admin/user-export.php:73 +msgid "Expires" +msgstr "" + +#: admin/user-export.php:75 msgid "Registered" msgstr "" -#: admin/user-export.php:90 +#: admin/user-export.php:76 msgid "IP" msgstr "" -#: admin/user-export.php:120 -msgid "Yes" +#: admin/user-export.php:108 admin/users.php:336 +msgid "No" msgstr "" -#: admin/user-export.php:120 admin/users.php:404 -msgid "No" +#: admin/user-profile.php:52 +msgid "WP-Members Additional Fields" msgstr "" -#: admin/user-profile.php:43 inc/wp-registration.php:278 +#: admin/user-profile.php:115 inc/users.php:90 inc/wp-registration.php:37 +#: inc/wp-registration.php:154 +msgid "(required)" +msgstr "" + +#: admin/user-profile.php:283 msgid "Activate this user?" msgstr "" -#: admin/user-profile.php:48 +#: admin/user-profile.php:288 msgid "Reactivate this user?" msgstr "" -#: admin/user-profile.php:53 +#: admin/user-profile.php:293 msgid "Deactivate this user?" msgstr "" -#: admin/user-profile.php:101 +#: admin/user-profile.php:339 msgid "IP @ registration" msgstr "" -#: admin/users.php:48 admin/users.php:52 admin/users.php:79 +#: admin/users.php:59 admin/users.php:63 msgid "Activate" msgstr "" -#: admin/users.php:50 admin/users.php:54 +#: admin/users.php:61 admin/users.php:65 msgid "Export" msgstr "" -#: admin/users.php:55 admin/users.php:103 +#: admin/users.php:66 admin/users.php:107 msgid "Export All Users" msgstr "" -#: admin/users.php:148 -#, php-format -msgid "%s users activated" -msgstr "" - -#: admin/users.php:151 -msgid "No users selected" -msgstr "" - -#: admin/users.php:175 -#, php-format -msgid "%s activated" -msgstr "" - -#: admin/users.php:180 -msgid "That user is already active" -msgstr "" - -#: inc/api.php:495 inc/class-wp-members.php:1272 -msgid "log in" -msgstr "" - -#: inc/api.php:496 -msgid "log out" -msgstr "" - -#: inc/class-wp-members-products.php:89 -msgid "Product" -msgstr "" - -#: inc/class-wp-members-products.php:90 -msgid "Products" -msgstr "" - -#: inc/class-wp-members-products.php:95 -msgid "Memberships" -msgstr "" - -#: inc/class-wp-members-products.php:96 -#, php-format -msgid "All %s" -msgstr "" - -#: inc/class-wp-members-products.php:97 -#, php-format -msgid "Add New %s" -msgstr "" - -#: inc/class-wp-members-products.php:98 -msgid "Add New" -msgstr "" - -#: inc/class-wp-members-products.php:99 -#, php-format -msgid "New %s" -msgstr "" - -#: inc/class-wp-members-products.php:100 -#, php-format -msgid "Edit %s" -msgstr "" - -#: inc/class-wp-members-products.php:101 -#, php-format -msgid "Update %s" -msgstr "" - -#: inc/class-wp-members-products.php:102 inc/class-wp-members-products.php:103 -#, php-format -msgid "View %s" -msgstr "" - -#: inc/class-wp-members-products.php:104 -#, php-format -msgid "Search %s" -msgstr "" - -#: inc/class-wp-members-products.php:105 -msgid "Not found" -msgstr "" - -#: inc/class-wp-members-products.php:106 -msgid "Not found in Trash" -msgstr "" - -#: inc/class-wp-members-products.php:107 -msgid "Insert into item" -msgstr "" - -#: inc/class-wp-members-products.php:108 -#, php-format -msgid "Save %s Details" -msgstr "" - -#: inc/class-wp-members-products.php:111 -msgid "Membership Product" -msgstr "" - -#: inc/class-wp-members-products.php:112 -msgid "WP-Members Membership Products" -msgstr "" - -#: inc/class-wp-members-user-profile.php:37 inc/deprecated.php:315 -msgid "WP-Members Additional Fields" -msgstr "" - -#: inc/class-wp-members-user-profile.php:37 inc/deprecated.php:589 -msgid "Additional Information" -msgstr "" - -#: inc/class-wp-members-user.php:532 -msgid "ERROR: User has not been activated." -msgstr "" - -#: inc/class-wp-members-widget.php:24 +#: inc/class-wp-members-widget.php:18 msgid "Displays the WP-Members sidebar login." msgstr "" -#: inc/class-wp-members-widget.php:39 inc/class-wp-members-widget.php:82 +#: inc/class-wp-members-widget.php:33 inc/class-wp-members-widget.php:76 msgid "Login Status" msgstr "" -#: inc/class-wp-members-widget.php:46 +#: inc/class-wp-members-widget.php:40 msgid "Title:" msgstr "" -#: inc/class-wp-members-widget.php:50 +#: inc/class-wp-members-widget.php:44 msgid "Redirect to (optional):" msgstr "" -#: inc/class-wp-members.php:757 inc/deprecated.php:180 inc/shortcodes.php:97 -#: inc/shortcodes.php:325 +#: inc/class-wp-members.php:388 inc/shortcodes.php:117 inc/shortcodes.php:386 msgid "There was an error with the CAPTCHA form." msgstr "" -#: inc/class-wp-members.php:1171 +#: inc/class-wp-members.php:546 msgid "First Name" msgstr "" -#: inc/class-wp-members.php:1172 +#: inc/class-wp-members.php:547 msgid "Last Name" msgstr "" -#: inc/class-wp-members.php:1173 +#: inc/class-wp-members.php:548 msgid "Address 1" msgstr "" -#: inc/class-wp-members.php:1174 +#: inc/class-wp-members.php:549 msgid "Address 2" msgstr "" -#: inc/class-wp-members.php:1175 +#: inc/class-wp-members.php:550 msgid "City" msgstr "" -#: inc/class-wp-members.php:1176 +#: inc/class-wp-members.php:551 msgid "State" msgstr "" -#: inc/class-wp-members.php:1177 +#: inc/class-wp-members.php:552 msgid "Zip" msgstr "" -#: inc/class-wp-members.php:1178 +#: inc/class-wp-members.php:553 msgid "Country" msgstr "" -#: inc/class-wp-members.php:1179 +#: inc/class-wp-members.php:554 msgid "Day Phone" msgstr "" -#: inc/class-wp-members.php:1180 inc/class-wp-members.php:1211 +#: inc/class-wp-members.php:555 inc/class-wp-members.php:588 msgid "Email" msgstr "" -#: inc/class-wp-members.php:1181 +#: inc/class-wp-members.php:556 msgid "Confirm Email" msgstr "" -#: inc/class-wp-members.php:1182 +#: inc/class-wp-members.php:557 msgid "Website" msgstr "" -#: inc/class-wp-members.php:1183 +#: inc/class-wp-members.php:558 msgid "Biographical Info" msgstr "" -#: inc/class-wp-members.php:1184 inc/class-wp-members.php:1194 -#: inc/class-wp-members.php:1271 +#: inc/class-wp-members.php:559 inc/class-wp-members.php:569 +#: inc/class-wp-members.php:645 msgid "Password" msgstr "" -#: inc/class-wp-members.php:1185 +#: inc/class-wp-members.php:560 msgid "Confirm Password" msgstr "" -#: inc/class-wp-members.php:1186 +#: inc/class-wp-members.php:561 msgid "TOS" msgstr "" -#: inc/class-wp-members.php:1192 +#: inc/class-wp-members.php:567 msgid "Existing Users Log In" msgstr "" -#: inc/class-wp-members.php:1193 inc/class-wp-members.php:1210 -#: inc/class-wp-members.php:1233 inc/class-wp-members.php:1270 +#: inc/class-wp-members.php:568 inc/class-wp-members.php:587 +#: inc/class-wp-members.php:608 inc/class-wp-members.php:644 msgid "Username" msgstr "" -#: inc/class-wp-members.php:1195 inc/shortcodes.php:645 +#: inc/class-wp-members.php:570 msgid "Log In" msgstr "" -#: inc/class-wp-members.php:1196 +#: inc/class-wp-members.php:571 msgid "Remember Me" msgstr "" -#: inc/class-wp-members.php:1197 +#: inc/class-wp-members.php:572 msgid "Forgot password?" msgstr "" -#: inc/class-wp-members.php:1198 +#: inc/class-wp-members.php:573 msgid "Click here to reset" msgstr "" -#: inc/class-wp-members.php:1199 +#: inc/class-wp-members.php:574 msgid "New User?" msgstr "" -#: inc/class-wp-members.php:1200 +#: inc/class-wp-members.php:575 msgid "Click here to register" msgstr "" -#: inc/class-wp-members.php:1203 inc/class-wp-members.php:1256 +#: inc/class-wp-members.php:576 +msgid "Forgot username?" +msgstr "" + +#: inc/class-wp-members.php:577 +msgid "Click here" +msgstr "" + +#: inc/class-wp-members.php:580 inc/class-wp-members.php:630 msgid "Change Password" msgstr "" -#: inc/class-wp-members.php:1204 +#: inc/class-wp-members.php:581 msgid "New password" msgstr "" -#: inc/class-wp-members.php:1205 +#: inc/class-wp-members.php:582 msgid "Confirm new password" msgstr "" -#: inc/class-wp-members.php:1206 +#: inc/class-wp-members.php:583 msgid "Update Password" msgstr "" -#: inc/class-wp-members.php:1209 +#: inc/class-wp-members.php:586 msgid "Reset Forgotten Password" msgstr "" -#: inc/class-wp-members.php:1212 +#: inc/class-wp-members.php:589 msgid "Reset Password" msgstr "" -#: inc/class-wp-members.php:1213 -msgid "Forgot username?" -msgstr "" - -#: inc/class-wp-members.php:1214 -msgid "Click here" -msgstr "" - -#: inc/class-wp-members.php:1217 inc/class-wp-members.php:1219 +#: inc/class-wp-members.php:592 inc/class-wp-members.php:594 msgid "Retrieve username" msgstr "" -#: inc/class-wp-members.php:1218 +#: inc/class-wp-members.php:593 msgid "Email Address" msgstr "" -#: inc/class-wp-members.php:1222 +#: inc/class-wp-members.php:597 msgid "New User Registration" msgstr "" -#: inc/class-wp-members.php:1223 +#: inc/class-wp-members.php:598 msgid "Choose a Username" msgstr "" -#: inc/class-wp-members.php:1224 +#: inc/class-wp-members.php:599 msgid "Input the code:" msgstr "" -#: inc/class-wp-members.php:1225 +#: inc/class-wp-members.php:600 #, php-format msgid "Please indicate that you agree to the %s TOS %s" msgstr "" -#: inc/class-wp-members.php:1226 +#: inc/class-wp-members.php:601 msgid "Reset Form" msgstr "" -#: inc/class-wp-members.php:1227 inc/class-wp-members.php:1274 -#: inc/shortcodes.php:642 inc/wp-registration.php:352 +#: inc/class-wp-members.php:602 inc/class-wp-members.php:648 inc/core.php:522 msgid "Register" msgstr "" -#: inc/class-wp-members.php:1229 +#: inc/class-wp-members.php:604 msgid "Required field" msgstr "" -#: inc/class-wp-members.php:1232 inc/deprecated.php:226 +#: inc/class-wp-members.php:607 inc/shortcodes.php:432 msgid "Edit Your Information" msgstr "" -#: inc/class-wp-members.php:1234 +#: inc/class-wp-members.php:609 msgid "Update Profile" msgstr "" -#: inc/class-wp-members.php:1235 +#: inc/class-wp-members.php:610 msgid "Update this file" msgstr "" -#: inc/class-wp-members.php:1238 +#: inc/class-wp-members.php:613 msgid "Login Failed!" msgstr "" -#: inc/class-wp-members.php:1239 +#: inc/class-wp-members.php:614 msgid "You entered an invalid username or password." msgstr "" -#: inc/class-wp-members.php:1240 +#: inc/class-wp-members.php:615 msgid "Click here to continue." msgstr "" -#: inc/class-wp-members.php:1241 +#: inc/class-wp-members.php:616 msgid "Password fields cannot be empty" msgstr "" -#: inc/class-wp-members.php:1242 +#: inc/class-wp-members.php:617 msgid "Sorry, that email address was not found." msgstr "" -#: inc/class-wp-members.php:1243 +#: inc/class-wp-members.php:618 #, php-format msgid "An email was sent to %s with your username." msgstr "" -#: inc/class-wp-members.php:1244 +#: inc/class-wp-members.php:619 #, php-format msgid "Sorry, %s is a required field." msgstr "" -#: inc/class-wp-members.php:1245 +#: inc/class-wp-members.php:620 msgid "You must enter a valid email address." msgstr "" -#: inc/class-wp-members.php:1246 +#: inc/class-wp-members.php:621 msgid "The username cannot include non-alphanumeric characters." msgstr "" -#: inc/class-wp-members.php:1247 +#: inc/class-wp-members.php:622 msgid "Sorry, username is a required field" msgstr "" -#: inc/class-wp-members.php:1248 +#: inc/class-wp-members.php:623 msgid "Passwords did not match." msgstr "" -#: inc/class-wp-members.php:1249 +#: inc/class-wp-members.php:624 msgid "Emails did not match." msgstr "" -#: inc/class-wp-members.php:1250 +#: inc/class-wp-members.php:625 msgid "You must complete the CAPTCHA form." msgstr "" -#: inc/class-wp-members.php:1251 +#: inc/class-wp-members.php:626 msgid "CAPTCHA was not valid." msgstr "" -#: inc/class-wp-members.php:1252 inc/register.php:53 -msgid "There was an error processing the form." -msgstr "" - -#: inc/class-wp-members.php:1255 +#: inc/class-wp-members.php:629 msgid "Edit My Information" msgstr "" -#: inc/class-wp-members.php:1257 inc/class-wp-members.php:1260 -#: inc/class-wp-members.php:1262 inc/class-wp-members.php:1266 +#: inc/class-wp-members.php:631 inc/class-wp-members.php:634 +#: inc/class-wp-members.php:636 inc/class-wp-members.php:640 #, php-format msgid "You are logged in as %s" msgstr "" -#: inc/class-wp-members.php:1258 +#: inc/class-wp-members.php:632 msgid "Click to log out." msgstr "" -#: inc/class-wp-members.php:1259 +#: inc/class-wp-members.php:633 msgid "Begin using the site." msgstr "" -#: inc/class-wp-members.php:1261 +#: inc/class-wp-members.php:635 msgid "Click to log out" msgstr "" -#: inc/class-wp-members.php:1263 +#: inc/class-wp-members.php:637 msgid "click to log out" msgstr "" -#: inc/class-wp-members.php:1267 +#: inc/class-wp-members.php:641 msgid "click here to log out" msgstr "" -#: inc/class-wp-members.php:1268 +#: inc/class-wp-members.php:642 msgid "Login Failed!
    You entered an invalid username or password." msgstr "" -#: inc/class-wp-members.php:1269 +#: inc/class-wp-members.php:643 msgid "You are not logged in." msgstr "" -#: inc/class-wp-members.php:1273 +#: inc/class-wp-members.php:646 +msgid "log in" +msgstr "" + +#: inc/class-wp-members.php:647 msgid "Forgot?" msgstr "" -#: inc/class-wp-members.php:1277 +#: inc/class-wp-members.php:651 msgid "" "This content is restricted to site members. If you are an existing user, " "please log in. New users may register below." msgstr "" -#: inc/class-wp-members.php:1278 +#: inc/class-wp-members.php:652 msgid "Sorry, that username is taken, please try another." msgstr "" -#: inc/class-wp-members.php:1279 +#: inc/class-wp-members.php:653 msgid "" "Sorry, that email address already has an account.
    Please try another." msgstr "" -#: inc/class-wp-members.php:1280 +#: inc/class-wp-members.php:654 msgid "" "Congratulations! Your registration was successful.

    You may now " "log in using the password that was emailed to you." msgstr "" -#: inc/class-wp-members.php:1281 +#: inc/class-wp-members.php:655 msgid "Your information was updated!" msgstr "" -#: inc/class-wp-members.php:1282 +#: inc/class-wp-members.php:656 msgid "Passwords did not match.

    Please try again." msgstr "" -#: inc/class-wp-members.php:1283 +#: inc/class-wp-members.php:657 msgid "Password successfully changed!" msgstr "" -#: inc/class-wp-members.php:1284 +#: inc/class-wp-members.php:658 msgid "Either the username or email address do not exist in our records." msgstr "" -#: inc/class-wp-members.php:1285 +#: inc/class-wp-members.php:659 msgid "" "Password successfully reset!

    An email containing a new password " "has been sent to the email address on file for your account." msgstr "" -#: inc/register.php:407 +#: inc/core.php:106 +msgid "ERROR: User has not been activated." +msgstr "" + +#: inc/register.php:45 +msgid "There was an error processing the form." +msgstr "" + +#: inc/register.php:557 msgid "We were unable to validate the public key." msgstr "" -#: inc/register.php:411 +#: inc/register.php:561 msgid "We were unable to validate the private key." msgstr "" -#: inc/register.php:415 +#: inc/register.php:565 msgid "The challenge parameter of the verify script was incorrect." msgstr "" -#: inc/register.php:419 +#: inc/register.php:569 msgid "The CAPTCHA solution was incorrect." msgstr "" -#: inc/register.php:423 +#: inc/register.php:573 msgid "The parameters to verify were incorrect" msgstr "" -#: inc/register.php:427 +#: inc/register.php:577 msgid "" "reCAPTCHA API keys are tied to a specific domain name for security reasons." msgstr "" -#: inc/register.php:431 +#: inc/register.php:581 msgid "The reCAPTCHA server was not reached. Please try to resubmit." msgstr "" -#: inc/register.php:435 +#: inc/register.php:585 msgid "You have entered an incorrect code value. Please try again." msgstr "" -#: inc/shortcodes.php:576 +#: inc/shortcodes.php:346 msgid "Click here to log out." msgstr "" -#: inc/utilities.php:121 +#: inc/users.php:37 +msgid "Additional Information" +msgstr "" + +#: inc/utilities.php:202 msgid "(more…)" msgstr "" From f0c80e9f7aebfcbeb824399ef94ce7c18249c1cf Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 30 Dec 2017 22:07:09 -0600 Subject: [PATCH 0736/1694] add placeholder support for custom fields in woocommerce reg form --- inc/wp-registration.php | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/inc/wp-registration.php b/inc/wp-registration.php index d867fdc9..a24beff9 100644 --- a/inc/wp-registration.php +++ b/inc/wp-registration.php @@ -126,7 +126,7 @@ function wpmem_do_wp_register_form( $process = 'wp' ) { case( 'multicheckbox' ): case( 'radio' ): $row_before = '

    '; - $valtochk = ( isset( $_POST[ $meta_key ] ) ) ? $_POST[ $meta_key ] : ''; + $valtochk = ( isset( $_POST[ $meta_key ] ) ) ? $_POST[ $meta_key ] : ''; // @todo Should this be escaped? $formfield_args = array( 'name' => $meta_key, 'type' => $field['type'], @@ -147,9 +147,16 @@ function wpmem_do_wp_register_form( $process = 'wp' ) { default: $class = ( $is_woo ) ? 'woocommerce-Input woocommerce-Input--text input-text' : 'input'; - $input = ''; + //$input = ''; break; } From 04f6ec7ec86a243e64fabe369dbe3c33e44401bc Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 30 Dec 2017 23:07:19 -0600 Subject: [PATCH 0737/1694] remove username from fields array for native wp registration --- inc/wp-registration.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/inc/wp-registration.php b/inc/wp-registration.php index a24beff9..63044095 100644 --- a/inc/wp-registration.php +++ b/inc/wp-registration.php @@ -49,6 +49,9 @@ function wpmem_do_wp_register_form( $process = 'wp' ) { } if ( isset( $wpmem_fields ) && is_array( $wpmem_fields ) ) { + + unset( $wpmem_fields['username'] ); + foreach ( $wpmem_fields as $meta_key => $field ) { $req = ( $field['required'] ) ? ( ( $is_woo ) ? ' *' : ' ' . __( '(required)' ) . '' ) : ''; From a6872e640f224d2f8bae293b21cef2bd2c5b53e2 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 26 Jan 2018 23:34:26 -0600 Subject: [PATCH 0738/1694] rework form and vaildation for username field as a meta key field --- admin/tab-fields.php | 8 ++++---- inc/class-wp-members.php | 6 ++++-- inc/register.php | 8 ++++---- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 8397c850..df222662 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -411,8 +411,8 @@ function wpmem_a_render_fields_tab_field_table() { 'label' => $field[1], 'meta' => $meta, 'type' => $field[3], - 'display' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_display", 'checkbox', 'y', $field[4] ) : '', - 'req' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_required", 'checkbox', 'y', $field[5] ) : '', + 'display' => ( 'user_email' != $meta && 'username' != $meta ) ? wpmem_create_formfield( $meta . "_display", 'checkbox', 'y', $field[4] ) : '', + 'req' => ( 'user_email' != $meta && 'username' != $meta ) ? wpmem_create_formfield( $meta . "_required", 'checkbox', 'y', $field[5] ) : '', //'profile' => ( $meta != 'user_email' ) ? wpmem_create_formfield( $meta . "_profile", 'checkbox', true, $field[6] ) : '', 'edit' => wpmem_fields_edit_link( $meta ), 'userscrn' => ( ! in_array( $meta, $wpmem_ut_fields_skip ) ) ? wpmem_create_formfield( 'ut_fields[' . $meta . ']', 'checkbox', $field[1], $ut_checked ) : '', @@ -580,7 +580,7 @@ function get_bulk_actions() { */ function column_delete( $item ) { $can_delete = ( $item['meta_key'] == 'user_nicename' || $item['meta_key'] == 'display_name' || $item['meta_key'] == 'nickname' ) ? true : false; - return ( ( $can_delete ) || $item['native'] != true ) ? sprintf( '', $item['meta'] ) : ''; + return ( ( $can_delete ) || ! $item['native'] ) ? sprintf( $item['native'] . '', $item['meta'] ) : ''; } /** @@ -696,7 +696,7 @@ function wpmem_admin_fields_update() { // Update display/required settings foreach ( $wpmem_fields as $key => $field ) { $meta_key = $field[2]; - if ( 'user_email' == $meta_key ) { + if ( 'username' == $meta_key || 'user_email' == $meta_key ) { $wpmem_fields[ $key ][4] = 'y'; $wpmem_fields[ $key ][5] = 'y'; } else { diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 7c58c83f..59cd5eac 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -1120,6 +1120,10 @@ function excluded_fields( $tag ) { // Default excluded fields. $excluded_fields = array( 'password', 'confirm_password', 'confirm_email', 'password_confirm', 'email_confirm' ); + + if ( 'update' == $tag ) { + $excluded_fields[] = 'username'; + } /** * Filter the fields to be excluded when user is created/updated. @@ -1152,7 +1156,6 @@ function load_user_pages() { } } - /** * Returns a requested text string. * @@ -1301,7 +1304,6 @@ function get_text( $str ) { } // End of get_text(). - /** * Load the admin api. * diff --git a/inc/register.php b/inc/register.php index f48e0832..ba645e86 100644 --- a/inc/register.php +++ b/inc/register.php @@ -70,7 +70,7 @@ function wpmem_registration( $tag ) { // Build the $wpmem->user->post_data array from $_POST data. foreach ( $wpmem->fields as $meta_key => $field ) { if ( $field['register'] ) { - if ( 'password' != $meta_key || 'confirm_password' != $meta_key ) { + if ( 'password' != $meta_key && 'confirm_password' != $meta_key && 'username' != $meta_key ) { if ( isset( $_POST[ $meta_key ] ) ) { switch ( $field['type'] ) { case 'checkbox': @@ -117,9 +117,9 @@ function wpmem_registration( $tag ) { // Check for required fields, reverse the array for logical error message order. $wpmem_fields_rev = array_reverse( $wpmem->fields ); + $pass_arr = ( 'update' == $tag ) ? array( 'username', 'password', 'confirm_password', 'password_confirm' ) : array( 'password', 'confirm_password', 'password_confirm' ); foreach ( $wpmem_fields_rev as $meta_key => $field ) { - $pass_arr = array( 'password', 'confirm_password', 'password_confirm' ); - $pass_chk = ( $tag == 'update' && in_array( $meta_key, $pass_arr ) ) ? true : false; + $pass_chk = ( 'update' == $tag && in_array( $meta_key, $pass_arr ) ) ? true : false; // Validation if the field is required. if ( $field['required'] && $pass_chk == false ) { // @todo - verify $field['required'] if ( 'file' == $field['type'] || 'image' == $field['type'] ) { @@ -132,7 +132,7 @@ function wpmem_registration( $tag ) { } } else { // If the required field is any other field type. - if ( ! $wpmem->user->post_data[ $meta_key ] ) { + if ( ! $wpmem->user->post_data[ $meta_key ] ) { $wpmem_themsg = sprintf( $wpmem->get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ); } } From 126a6a793ad88170f109ac75502e4587f52aa28c Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 26 Jan 2018 23:35:08 -0600 Subject: [PATCH 0739/1694] improve wpmem_user_has_role() so it can be used if user is not logged in --- inc/api.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/inc/api.php b/inc/api.php index 2b57582d..2ecd1248 100644 --- a/inc/api.php +++ b/inc/api.php @@ -314,6 +314,7 @@ function wpmem_use_custom_dialog( $defaults, $tag, $dialogs ) { * @since 3.1.1 * @since 3.1.6 Include accepting an array of roles to check. * @since 3.1.9 Return false if user is not logged in. + * @since 3.2.0 Change return false to not logged in AND no user id. * * @global object $current_user Current user object. * @global object $wpmem WP_Members object. @@ -322,7 +323,7 @@ function wpmem_use_custom_dialog( $defaults, $tag, $dialogs ) { * @return boolean $has_role True if user has the role, otherwise false. */ function wpmem_user_has_role( $role, $user_id = false ) { - if ( ! is_user_logged_in() ) { + if ( ! is_user_logged_in() && ! $user_id ) { return false; } global $current_user, $wpmem; From dc87fc6c9ffa9d63d16b73bfa7f75512668e8166 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 26 Jan 2018 23:36:03 -0600 Subject: [PATCH 0740/1694] add id as argument for form fields --- inc/class-wp-members-forms.php | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index adc2b23d..d1486891 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -33,8 +33,10 @@ function __construct() { * @since 3.1.2 Changed $valtochk to $compare. * @since 3.1.6 Added $placeholder. * @since 3.1.7 Added number type & $min, $max, $title and $pattern attributes. + * @since 3.2.0 Added $id argument. * * @param array $args { + * @type string $id * @type string $name * @type string $type * @type string $value @@ -54,6 +56,7 @@ function __construct() { */ function create_form_field( $args ) { + $id = ( isset( $args['id'] ) ) ? esc_attr( $args['id'] ) : esc_attr( $args['name'] ); $name = esc_attr( $args['name'] ); $type = esc_attr( $args['type'] ); $value = maybe_unserialize( $args['value'] ); @@ -92,24 +95,24 @@ function create_form_field( $args ) { $title = ( $title ) ? ' title="' . esc_attr( $title ) . '"' : ''; $min = ( isset( $args['min'] ) && $args['min'] != '' ) ? ' min="' . esc_attr( $args['min'] ) . '"' : ''; $max = ( isset( $args['max'] ) && $args['max'] != '' ) ? ' max="' . esc_attr( $args['max'] ). '"' : ''; - $str = ""; + $str = ""; break; case "password": $class = $this->sanitize_class( $class ); $placeholder = ( $placeholder ) ? ' placeholder="' . esc_attr( $placeholder ) . '"' : ''; - $str = ""; + $str = ""; break; case "image": case "file": $class = ( 'textbox' == $class ) ? "file" : $this->sanitize_class( $class ); - $str = ""; + $str = ""; break; case "checkbox": $class = ( 'textbox' == $class ) ? "checkbox" : $this->sanitize_class( $class ); - $str = ""; + $str = ""; break; case "textarea": @@ -117,7 +120,7 @@ function create_form_field( $args ) { $class = ( 'textbox' == $class ) ? "textarea" : $this->sanitize_class( $class ); $rows = ( isset( $args['rows'] ) ) ? esc_attr( $args['rows'] ) : '5'; $cols = ( isset( $args['cols'] ) ) ? esc_attr( $args['cols'] ) : '20'; - $str = ""; + $str = ""; break; case "hidden": @@ -133,7 +136,7 @@ function create_form_field( $args ) { $class = ( 'textbox' == $class ) ? "dropdown" : $class; $class = ( 'multiselect' == $type ) ? "multiselect" : $class; $pname = ( 'multiselect' == $type ) ? $name . "[]" : $name; - $str = "\n"; foreach ( $value as $option ) { $pieces = explode( '|', $option ); if ( 'multiselect' == $type ) { @@ -162,6 +165,7 @@ function create_form_field( $args ) { $chk = ( isset( $pieces[2] ) && '' == $compare ) ? $pieces[1] : ''; if ( isset( $pieces[1] ) && '' != $pieces[1] ) { $str = $str . $this->create_form_field( array( + 'id' => $id . '[' . $pieces[1] . ']', 'name' => $name . '[]', 'type' => 'checkbox', 'value' => $pieces[1], @@ -179,7 +183,7 @@ function create_form_field( $args ) { $num = 1; foreach ( $value as $option ) { $pieces = explode( '|', $option ); - $id = $this->sanitize_class( $name . '_' . $num ); + $id = $this->sanitize_class( $id . '_' . $num ); if ( isset( $pieces[1] ) && '' != $pieces[1] ) { $str = $str . " " . esc_html( __( $pieces[0], 'wp-members' ) ) . "
    \n"; } else { From fcbee5f82ba2c8e01c403d66427c34c147ba9fa0 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 31 Jan 2018 00:04:36 -0600 Subject: [PATCH 0741/1694] restrict username and email from being unset to display or be required --- admin/tab-fields.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index df222662..dc96a406 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -224,11 +224,21 @@ function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key )

  • + /> + + + +
  • + /> + + + +
  • diff --git a/admin/tab-dropins.php b/admin/tab-dropins.php index cc962076..33ca0adf 100644 --- a/admin/tab-dropins.php +++ b/admin/tab-dropins.php @@ -3,14 +3,14 @@ * WP-Members Dropins Admin Functions * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com/plugins/wp-members/extensions/editor/ - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com/plugins/wp-members/extensions/editor/ + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members Editor * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 */ // Exit if accessed directly. diff --git a/admin/tab-emails.php b/admin/tab-emails.php index 93b46e97..41fcc382 100644 --- a/admin/tab-emails.php +++ b/admin/tab-emails.php @@ -5,13 +5,13 @@ * Functions to manage the emails tab. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions included: * - wpmem_a_build_emails @@ -42,7 +42,7 @@ function wpmem_a_build_emails() {


    - +


    @@ -83,7 +83,7 @@ function wpmem_a_build_emails() {
    diff --git a/admin/tab-fields.php b/admin/tab-fields.php index dc96a406..19bb5df3 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -5,13 +5,13 @@ * Functions to manage the fields tab. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 */ // Exit if accessed directly. @@ -148,7 +148,7 @@ function wpmem_a_render_fields_tab() { } ?>

    - +
  • - +
  • ' : ''; ?> diff --git a/admin/tab-options.php b/admin/tab-options.php index 33a6d2b6..736e039d 100644 --- a/admin/tab-options.php +++ b/admin/tab-options.php @@ -5,13 +5,13 @@ * Functions to manage the plugin options tab. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions included: * - wpmem_a_build_options @@ -40,8 +40,8 @@ function wpmem_a_build_options() { /** This filter is documented in wp-members/inc/email.php */ $admin_email = apply_filters( 'wpmem_notify_addr', get_option( 'admin_email' ) ); - $chg_email = __( sprintf( '%sChange%s or %sFilter%s this address', '', '', '', '' ), 'wp-members' ); - $help_link = __( sprintf( 'See the %sUsers Guide on plugin options%s.', '', '' ), 'wp-members' ); + $chg_email = __( sprintf( '%sChange%s or %sFilter%s this address', '', '', '', '' ), 'wp-members' ); + $help_link = __( sprintf( 'See the %sUsers Guide on plugin options%s.', '', '' ), 'wp-members' ); // Build an array of post types $post_types = get_post_types( array( 'public' => true, '_builtin' => false ), 'names', 'and' ); diff --git a/admin/user-export.php b/admin/user-export.php index b597fc24..318ae0a4 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -5,13 +5,13 @@ * Mananges exporting users to a CSV file. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 */ // Exit if accessed directly. diff --git a/admin/user-profile.php b/admin/user-profile.php index bdc63e96..ff29df97 100644 --- a/admin/user-profile.php +++ b/admin/user-profile.php @@ -5,13 +5,13 @@ * Functions to manage the user profile screen. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions included: * - wpmem_profile_show_activate diff --git a/admin/users.php b/admin/users.php index 3f66c4ef..ef42a1df 100644 --- a/admin/users.php +++ b/admin/users.php @@ -5,13 +5,13 @@ * Functions to manage the Users > All Users page. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions included: * - wpmem_bulk_user_action diff --git a/changelog.txt b/changelog.txt index dcd887dd..835e58d0 100644 --- a/changelog.txt +++ b/changelog.txt @@ -554,16 +554,16 @@ New Features: * Added a new filter hook wpmem_securify. This hook applies a filter to the $content variable at the end of the wpmem_securify function. The primary reason for this hook is to be able to run filters on $content that would give you the ability to block content even if the user is logged in (the wpmem_block filter only works for non-logged in state). This will bring in the ability to block users from content based on defined criteria such as content is for members of "group A" but the user is does not have access to "group A" content. * Added wpmem_email_headers filter hook. This will allow you to easily filter the headers for the email process of the plugin giving you the ability to send HTML email without modifying the plugin. * Added wpmem_user_activated action hook. This hook will give you the ability to run actions at the end of user activation. For sites that moderate registration, this gives you the ability to hook in actions that you might not want to do before approval of the registration (such as would normally be done with wpmem_post_register_data). -* Added new shortcode for creating a user list/member directory. __This shortcode requires installation of the premium add-on module WP-Members User List [available to rocketgeek.com members](http://rocketgeek.com/about/site-membership-subscription/)__. The shortcode has parameters for including a member search function as well as filter hooks for filtering the layout of the directory elements. -* Added new shortcode for protecting inline content with the __premium add-on module WP-Members PayPal Subscription [available to rocketgeek.com members](http://rocketgeek.com/about/site-membership-subscription/)__. +* Added new shortcode for creating a user list/member directory. __This shortcode requires installation of the premium add-on module WP-Members User List [available to rocketgeek.com members](https://rocketgeek.com/about/site-membership-subscription/)__. The shortcode has parameters for including a member search function as well as filter hooks for filtering the layout of the directory elements. +* Added new shortcode for protecting inline content with the __premium add-on module WP-Members PayPal Subscription [available to rocketgeek.com members](https://rocketgeek.com/about/site-membership-subscription/)__. Bug Fix: -* Fixed a bug where the reCAPTCHA error messages do not display on the [shortcode pages "register" and "members-area"](http://rocketgeek.com/plugins/wp-members/users-guide/shortcodes/page-shortcodes/). +* Fixed a bug where the reCAPTCHA error messages do not display on the [shortcode pages "register" and "members-area"](https://rocketgeek.com/plugins/wp-members/users-guide/shortcodes/page-shortcodes/). Code Improvement: -* Completed a rebuild of the login function wpmem_login. Updated the cookie process to switch from [wp_setcookie](http://codex.wordpress.org/Function_Reference/wp_setcookie) (which is deprecated) to [wp_set_auth_cookie](http://codex.wordpress.org/Function_Reference/wp_set_auth_cookie). Also, the [wpmem_login_redirect hook](http://rocketgeek.com/plugins/wp-members/users-guide/filter-hooks/wpmem_login_redirect/) was moved to after the login credentials have been validated and the user is logged in. This allows the hook to access user data without the need to validate the user within the filter. +* Completed a rebuild of the login function wpmem_login. Updated the cookie process to switch from [wp_setcookie](http://codex.wordpress.org/Function_Reference/wp_setcookie) (which is deprecated) to [wp_set_auth_cookie](http://codex.wordpress.org/Function_Reference/wp_set_auth_cookie). Also, the [wpmem_login_redirect hook](https://rocketgeek.com/plugins/wp-members/users-guide/filter-hooks/wpmem_login_redirect/) was moved to after the login credentials have been validated and the user is logged in. This allows the hook to access user data without the need to validate the user within the filter. = 2.7.6 = diff --git a/css/generic-no-float.css b/css/generic-no-float.css index cedb0d18..a849f6e7 100644 --- a/css/generic-no-float.css +++ b/css/generic-no-float.css @@ -4,14 +4,14 @@ * CSS for the WP-Members plugin * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WordPress * @subpackage WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 */ /* @@ -21,11 +21,11 @@ in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/generic-rigid.css b/css/generic-rigid.css index 0fe71dd6..edaa0da3 100644 --- a/css/generic-rigid.css +++ b/css/generic-rigid.css @@ -4,14 +4,14 @@ * CSS for the WP-Members plugin * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WordPress * @subpackage WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 */ /* @@ -21,11 +21,11 @@ There are quite a few examples in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/wp-members-2011.css b/css/wp-members-2011.css index 49f95785..44ec663d 100644 --- a/css/wp-members-2011.css +++ b/css/wp-members-2011.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin using Twenty Eleven Theme * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -20,11 +20,11 @@ There are quite a few examples in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/wp-members-2012.css b/css/wp-members-2012.css index e578ee92..e576391a 100644 --- a/css/wp-members-2012.css +++ b/css/wp-members-2012.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin using Twenty Twelve Theme * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -20,11 +20,11 @@ There are quite a few examples in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/wp-members-2013.css b/css/wp-members-2013.css index 5e721478..4a2aa264 100644 --- a/css/wp-members-2013.css +++ b/css/wp-members-2013.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin using Twenty Thirteen Theme * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -20,11 +20,11 @@ There are quite a few examples in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/wp-members-2014-no-float.css b/css/wp-members-2014-no-float.css index f90b196d..bb29c2fc 100644 --- a/css/wp-members-2014-no-float.css +++ b/css/wp-members-2014-no-float.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin using Twenty Fourteen Theme, no float * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -20,11 +20,11 @@ There are quite a few examples in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/wp-members-2014.css b/css/wp-members-2014.css index fff3fc72..fb28d558 100644 --- a/css/wp-members-2014.css +++ b/css/wp-members-2014.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin using Twenty Fourteen Theme * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -20,11 +20,11 @@ There are quite a few examples in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/wp-members-2015-no-float.css b/css/wp-members-2015-no-float.css index 3739a422..eecd6a83 100644 --- a/css/wp-members-2015-no-float.css +++ b/css/wp-members-2015-no-float.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin - Twenty Fifteen Theme, No Float * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -21,11 +21,11 @@ in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/wp-members-2015.css b/css/wp-members-2015.css index e3818198..b79616f6 100644 --- a/css/wp-members-2015.css +++ b/css/wp-members-2015.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin - Twenty Fifteen Theme * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -21,11 +21,11 @@ in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/wp-members-2016-no-float.css b/css/wp-members-2016-no-float.css index fd3a2c74..90cf2b57 100644 --- a/css/wp-members-2016-no-float.css +++ b/css/wp-members-2016-no-float.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin using Twenty Sixteen Theme, no float * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -20,11 +20,11 @@ There are quite a few examples in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ diff --git a/css/wp-members-kubrick.css b/css/wp-members-kubrick.css index 7ba8902f..0fb1c444 100644 --- a/css/wp-members-kubrick.css +++ b/css/wp-members-kubrick.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin using Kubrick Theme * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -20,11 +20,11 @@ There are quite a few examples in here of what you can do with the table-less forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a cusotm stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ /* Error and Dialog Messages */ diff --git a/css/wp-members.css b/css/wp-members.css index 3d7aef18..a5e03dc9 100644 --- a/css/wp-members.css +++ b/css/wp-members.css @@ -4,7 +4,7 @@ * CSS for the WP-Members plugin using Twenty Ten Theme * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com + * You can find out more about this plugin at https://rocketgeek.com * Copyright (c) 2006-2015 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * @@ -20,11 +20,11 @@ There are quite a few examples in here of what you can do to style the forms. You can build off of this or start from scratch and set your own custom css for the plugin (set the location in the admin panel). -See http://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ for information on how to set up the plugin with a custom stylesheet. For information how to load custom stylesheets with wp_enqueue_style, -see http://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ */ /* Error and Dialog Messages */ diff --git a/inc/api.php b/inc/api.php index 2ecd1248..bef0036b 100644 --- a/inc/api.php +++ b/inc/api.php @@ -3,14 +3,14 @@ * WP-Members API Functions * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions included: * - wpmem_redirect_to_login diff --git a/inc/class-wp-members-email.php b/inc/class-wp-members-email.php index 2e2a1f95..291d7369 100644 --- a/inc/class-wp-members-email.php +++ b/inc/class-wp-members-email.php @@ -49,6 +49,7 @@ class WP_Members_Email { * @since 2.9.7 Major overhaul, added wpmem_email_filter filter. * @since 3.1.0 Can filter in custom shortcodes with wpmem_email_shortcodes. * @since 3.1.1 Added $custom argument for custom emails. + * @since 3.2.0 Moved to WP_Members_Email::to_user(). * * @global object $wpmem The WP_Members object. * @global string $wpmem_mail_from The email from address. @@ -192,6 +193,7 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * Filters the new registration email. * * @since 2.7.4 + * @deprecated 3.2.0 Use wpmem_email_filter instead. * * @param string $arr['body'] The body content of the new registration email. */ @@ -204,6 +206,7 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * Filters the new moderated registration email. * * @since 2.7.4 + * @deprecated 3.2.0 Use wpmem_email_filter instead. * * @param string $arr['body'] The body content of the moderated registration email. */ @@ -216,6 +219,7 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * Filters the reset password email. * * @since 2.7.4 + * @deprecated 3.2.0 Use wpmem_email_filter instead. * * @param string $arr['body'] The body content of the reset password email. */ @@ -228,6 +232,7 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * Filters the approved registration email. * * @since 2.7.4 + * @deprecated 3.2.0 Use wpmem_email_filter instead. * * @param string $arr['body'] The body content of the approved registration email. */ @@ -310,6 +315,7 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * Builds the email for admin notification of new user registration. * * @since 2.3 + * @since 3.2.0 Moved to WP_Members_Email::notify_admin(). * * @global object $wpmem The WP_Members object. * @global string $wpmem_mail_from The email from address. @@ -514,7 +520,8 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { * Filters the wp_mail from address (if set). * * @since 2.7 - * @since 3.1 Converted to use email var in object. + * @since 3.1.0 Converted to use email var in object. + * @since 3.2.0 Moved to WP_Members_Email::from(). * * @global object $wpmem * @param string $email @@ -529,7 +536,8 @@ function from( $email ) { * Filters the wp_mail from name (if set). * * @since 2.7 - * @since 3.1 Converted to use email var in object. + * @since 3.1.0 Converted to use email var in object. + * @since 3.2.0 Moved to WP_Members_Email::from_name(). * * @global object $wpmem * @param string $name diff --git a/inc/core.php b/inc/core.php index bd12ebe1..cc1dd3e5 100644 --- a/inc/core.php +++ b/inc/core.php @@ -6,13 +6,13 @@ * situations. Includes commonly used utility functions. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 */ // Exit if accessed directly. diff --git a/inc/deprecated.php b/inc/deprecated.php index fe8aac1e..1c3b63ce 100644 --- a/inc/deprecated.php +++ b/inc/deprecated.php @@ -7,13 +7,13 @@ * future release. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 */ // Exit if accessed directly. diff --git a/inc/dialogs.php b/inc/dialogs.php index c48adb3e..aca40bd7 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -5,13 +5,13 @@ * Handles functions that output front-end dialogs to end users. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions Included: * - wpmem_inc_loginfailed diff --git a/inc/forms.php b/inc/forms.php index 7e8a6812..f992fa61 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -5,14 +5,14 @@ * Handles functions that build the various forms. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members Form Building Functions * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions Included: * - wpmem_inc_login diff --git a/inc/register.php b/inc/register.php index ba645e86..528025b8 100644 --- a/inc/register.php +++ b/inc/register.php @@ -5,14 +5,14 @@ * Handles new user registration and existing user updates. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members Registration Functions * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions Included: * - wpmem_registration diff --git a/inc/sidebar.php b/inc/sidebar.php index d988fb9a..e4841914 100644 --- a/inc/sidebar.php +++ b/inc/sidebar.php @@ -5,13 +5,13 @@ * Handles functions for the sidebar. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions Included: * - wpmem_inc_status diff --git a/inc/utilities.php b/inc/utilities.php index 11dda2f1..583af2cf 100644 --- a/inc/utilities.php +++ b/inc/utilities.php @@ -6,14 +6,14 @@ * situations. Includes commonly used utility functions. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members Utility Functions * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions included: * - wpmem_create_formfield diff --git a/inc/wp-registration.php b/inc/wp-registration.php index 63044095..5da5e1ab 100644 --- a/inc/wp-registration.php +++ b/inc/wp-registration.php @@ -7,13 +7,13 @@ * Users > Add New screen. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions Included: * - wpmem_do_wp_register_form diff --git a/readme.txt b/readme.txt index 99dea70c..5c306052 100644 --- a/readme.txt +++ b/readme.txt @@ -40,11 +40,11 @@ There are also some special pages that can be created with simple shortcodes: * A User Profile page where registered members can edit their information and change/reset their password: [wpmem_profile] * A Registration page available for those that need a specific URL for registrations (such as email marketing or banner ad landing pages). Note: this is strictly optional as a registration form can also be included by default on blocked content pages: [wpmem_form register] * A Login page. This is also an optional page as the login form is included by default on blocked content. But if you need a specific login page, this can be created with a simple shortcode: [wpmem_form login] -* [And more shortcodes are available](http://rocketgeek.com/plugins/wp-members/users-guide/shortcodes/)! +* [And more shortcodes are available](https://rocketgeek.com/plugins/wp-members/users-guide/shortcodes/)! The plugin runs on a framework with over 100 action and filter hooks so you can fully customize your implementation. -In addition to all of the features above, the plugin can be extended with premium add-on modules available from the support site rocketgeek.com. Members of rocketgeek.com have access to support, examples, tutorials, and code snippets that will help you extend and customize the base plugin using the plugin's framework. Some of the add-ons have their own hooks and shortcodes to further extend the plugin's extensibility. [Visit the site for more info](http://rocketgeek.com/about/site-membership-subscription/). +In addition to all of the features above, the plugin can be extended with premium add-on modules available from the support site rocketgeek.com. Members of rocketgeek.com have access to support, examples, tutorials, and code snippets that will help you extend and customize the base plugin using the plugin's framework. Some of the add-ons have their own hooks and shortcodes to further extend the plugin's extensibility. [Visit the site for more info](https://rocketgeek.com/about/site-membership-subscription/). = What the plugin does not do = @@ -57,7 +57,7 @@ WP-Members™ is designed to run "out-of-the-box" with no modifications to y = Basic Install: = -The best start is to follow the instructions in the [Quick Start Guide](http://rocketgeek.com/plugins/wp-members/quick-start-guide/). There is also a complete [Users Guide available](http://rocketgeek.com/plugins/wp-members/users-guide/) that covers all of the plugin's features in depth. +The best start is to follow the instructions in the [Quick Start Guide](https://rocketgeek.com/plugins/wp-members/quick-start-guide/). There is also a complete [Users Guide available](https://rocketgeek.com/plugins/wp-members/users-guide/) that covers all of the plugin's features in depth. 1. Upload the `/wp-members/` directory and its contents to the `/wp-content/plugins/` directory 2. Activate the plugin through the 'Plugins' menu in WordPress® @@ -77,22 +77,22 @@ NOTE: Please follow instructions for installation. The vast majority of people t = Additional Settings and Information = -A full Users Guide is [available here](http://rocketgeek.com/plugins/wp-members/users-guide/). The guide outlines the installation process, and also documents how to use all of the settings. +A full Users Guide is [available here](https://rocketgeek.com/plugins/wp-members/users-guide/). The guide outlines the installation process, and also documents how to use all of the settings. = Plugin Extensibility = WP-Members™ is designed to be an out-of-the-box usable plugin, but also have an extensible framework for maximum flexibility and customization. For this purpose, there are a number of shortcodes, filters, and actions that can be used. -See [this page](http://rocketgeek.com/plugins/wp-members/users-guide/shortcodes/) for a list of shortcodes and their description. +See [this page](https://rocketgeek.com/plugins/wp-members/users-guide/shortcodes/) for a list of shortcodes and their description. -The plugin has 80 filter and action hooks. For a list of hooks and a description of their use, see [this page](http://rocketgeek.com/plugins/wp-members/users-guide/filter-hooks/) +The plugin has 80 filter and action hooks. For a list of hooks and a description of their use, see [this page](https://rocketgeek.com/plugins/wp-members/users-guide/filter-hooks/) -The plugin's premium support site has __loads__ of tips, tricks, and sample code for you to make maximum use out of the plugin. [Get more information here](http://rocketgeek.com/about/site-membership-subscription/). Members of the premium support site also have access to premium add-on modules. +The plugin's premium support site has __loads__ of tips, tricks, and sample code for you to make maximum use out of the plugin. [Get more information here](https://rocketgeek.com/about/site-membership-subscription/). Members of the premium support site also have access to premium add-on modules. == Frequently Asked Questions == -The FAQs are maintained at http://rocketgeek.com/plugins/wp-members/users-guide/faqs/ +The FAQs are maintained at https://rocketgeek.com/plugins/wp-members/users-guide/faqs/ == Other Notes == @@ -107,7 +107,7 @@ An [official statement is available here](http://butlerblog.com/regarding-wp-mem = Regarding RocketGeek.com = -Premium priority support is available at the plugin's site [RocketGeek.com](http://rocketgeek.com). A site membership includes priority support, members-only forum access, plugin extensions, and a custom code snippet library. [RocketGeek.com](http://rocketgeek.com) is the only site officially managed for this plugin's support. +Premium priority support is available at the plugin's site [RocketGeek.com](https://rocketgeek.com). A site membership includes priority support, members-only forum access, plugin extensions, and a custom code snippet library. [RocketGeek.com](https://rocketgeek.com) is the only site officially managed for this plugin's support. == Upgrade Notice == diff --git a/uninstall.php b/uninstall.php index f6fb110f..7e7132eb 100644 --- a/uninstall.php +++ b/uninstall.php @@ -5,13 +5,13 @@ * Removes all settings WP-Members added to the WP options table * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 */ // Exit if accessed directly. diff --git a/wp-members-install.php b/wp-members-install.php index 062a6590..1849dc03 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -5,13 +5,13 @@ * Functions to install and upgrade WP-Members. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 * * Functions included: * - wpmem_do_install diff --git a/wp-members-tos.php b/wp-members-tos.php index 386762fb..a6da08dd 100644 --- a/wp-members-tos.php +++ b/wp-members-tos.php @@ -5,13 +5,13 @@ * Generates teh Terms of Service pop-up. * * This file is part of the WP-Members plugin by Chad Butler - * You can find out more about this plugin at http://rocketgeek.com - * Copyright (c) 2006-2017 Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2018 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2017 + * @copyright 2006-2018 */ define ( 'WP_USE_THEMES', false ); diff --git a/wp-members.php b/wp-members.php index 74ed0b0f..8cfdb474 100644 --- a/wp-members.php +++ b/wp-members.php @@ -1,8 +1,8 @@ the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. +Plugin URI: https://rocketgeek.com +Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. Version: 3.2.0 Author: Chad Butler Author URI: http://butlerblog.com/ @@ -13,7 +13,7 @@ /* - Copyright (c) 2006-2017 Chad Butler + Copyright (c) 2006-2018 Chad Butler The name WP-Members(tm) is a trademark of butlerblog.com @@ -51,13 +51,13 @@ derivative work you are developing complies with the license, copyright, trademark, or if you do not understand the difference between open source and public domain, contact the original author at: - http://rocketgeek.com/contact/. + https://rocketgeek.com/contact/. INSTALLATION PROCEDURE: For complete installation and usage instructions, - visit http://rocketgeek.com + visit https://rocketgeek.com */ // Exit if accessed directly. From ab90a67aef985f0f109924e6e3a3fe8836fd3174 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 5 Feb 2018 08:51:38 -0600 Subject: [PATCH 0748/1694] add $locale as a parameter for language filters --- wp-members.php | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/wp-members.php b/wp-members.php index 8cfdb474..f5fc2845 100644 --- a/wp-members.php +++ b/wp-members.php @@ -248,24 +248,38 @@ function wpmem_load_textdomain() { * different location (or different file name). * * @since 3.0.0 + * @since 3.2.0 Added locale as a parameter. * - * @param string $file The translation file to load. + * @param string $file The translation file to load. + * @param string $locale The current locale. */ - $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . 'plugins/' . $domain . '-' . $locale . '.mo' ); + $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . 'plugins/' . $domain . '-' . $locale . '.mo', $locale ); $loaded = load_textdomain( $domain, $file ); if ( $loaded ) { return $loaded; } else { + /* + * If there is no wordpress.org language pack or the filtered + * language file does not load, $loaded will be false and will + * end up here to attempt to load one of the legacy language + * packs. Note that the legacy language files are no longer + * actively maintained and may not contain all strings. + * The directory that the file will load from can be changed + * using the wpmem_localization_dir filter. + */ + /** * Filter translation directory. * * @since 3.0.3 + * @since 3.2.0 Added locale as a parameter. * - * @param string $dir The translation directory. + * @param string $dir The translation directory. + * @param string $locale The current locale. */ - $dir = apply_filters( 'wpmem_localization_dir', dirname( plugin_basename( __FILE__ ) ) . '/lang/' ); + $dir = apply_filters( 'wpmem_localization_dir', dirname( plugin_basename( __FILE__ ) ) . '/lang/', $locale ); load_plugin_textdomain( $domain, FALSE, $dir ); } return; From 59c331e6e82ca0143923efabf9839314bc28167a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 5 Feb 2018 09:32:54 -0600 Subject: [PATCH 0749/1694] cleanup, new zh_tw translation --- admin/includes/class-wp-members-admin-api.php | 1 - lang/wp-members-zh_TW.mo | Bin 15092 -> 15712 bytes lang/wp-members-zh_TW.po | 2287 ++++++++--------- 3 files changed, 1010 insertions(+), 1278 deletions(-) diff --git a/admin/includes/class-wp-members-admin-api.php b/admin/includes/class-wp-members-admin-api.php index 1c60a503..36c86db6 100644 --- a/admin/includes/class-wp-members-admin-api.php +++ b/admin/includes/class-wp-members-admin-api.php @@ -93,7 +93,6 @@ function load_dependencies() { include_once( WPMEM_PATH . 'admin/tab-about.php' ); include_once( WPMEM_PATH . 'admin/tab-dialogs.php' ); include_once( WPMEM_PATH . 'admin/tab-dropins.php' ); - //include_once( WPMEM_PATH . 'admin/tab-memberships.php' ); } } diff --git a/lang/wp-members-zh_TW.mo b/lang/wp-members-zh_TW.mo index 1b9eea96f101bbf4dd8a537ce05139317d73edb2..076e495cdddd8989f46a417c58e80c39c752275b 100644 GIT binary patch delta 6808 zcmZ{n32;1k~C&Do&iOO5!-#csEW~bCoxt5|dPRH?i~k=CxRn+Pu<# ze%<~0b$|WuuN(VG;LG=ezZ}x5R`EPUqflaRr4ka9`tJeK$}>o*kstw%furCMI2ZPV zE8#%69`=WYnqHVqeFsc~w;+G&=ll$XUqSi@)wdLe)6jpgHDIddR45b8h9lr|_yWv_ z!{AORF&>5AfoEYa*aBs|R+t1ofr;?vkUtgSNBaE+KF9p(8wwJ6FJ?=INl*qz)0___ z;&o6aaza_jHuyZOgxldM*awcJvv3@g38z4DY95rpm+AL!!;#Fd>=gRKAmmR~@*^D^ z;6iu{J_nyb3E;O-Ebq(gvchCYlS+f^o|+5g`$d}Tp#;Zc)o2>LXC=MpW95@}y$~VInSOO)$vDhmMnKT^#7f{Hi zLH5Y6U+jXi!b30xo`!s@?m`LZQ(gZhlnI_d`TiTt0Yo8zrogGtfa359DC4e!GLAhN z|Ho1Y=oht6viu^ffFDEt)ayhs8y3LnupWwqe+I>|&!7bOCF}|R6Uv0Y)$e^^Wi_kIWUz=BOPvp zrQ93ka6J5GwB^V+?3F#A17*SmP!_rZk^@1tiGpOYQ@<$H^-3tt9EY;Pi%^oR87_m5 zbbD`uM53MqWh-(ZF{p)*F6td9&g|4Y1^H7Q{7jYe{|gF|&HYj>YqFtOH4lo#i=a5O z5pII-LJ#~Dz5`z#$EsihoCd#uxv(GhNgzw0IBDZ&BHRmC!6ul;{OWfUR>Kt&l)^Q2 z8vZftfFHo!d?gMHW0{gt(gmZQ-1}@-o6T@|0?)8To1+ai_i^Qp*T5?{S3-g zm`y=GcnS7|i{M)c*bHUD)03@a{19@`fx{fk{wSo(x%o%7!xG z1}M3<1xml|>G&^6QBH#la76P2l!-4u?ih6siZg$y+kXxFQSZUNN$w=V-f$F@0LMca zH%D_ZltA*J^b2TipMw7~&>kA(!y3)Anys3D0%gFz*9=3M_-kl~Jvq!WaFM15%6MC$ zd{+f!<#kZz`w5ieeKSZwtoQ`V9sXBPJ`BT`;BTM|Fl(B{SD?IqL)U)@WuRhR-v`Ax z6H31;Py*}F{1_%u|3owRIRy!z6H3QlYkm#m|JXo@yl;lpZv+%8Q+0hAOr*XN%7mLB z>7d+Da_JasgD0Vkzc$nAzX{Hh^IxPJE@|GpZf zfxX}zC;_xXneZdcpFwfx3pf@&hW+IHC(W=rj)1Zilc03W)a?tQT)8WuSYM-g3(Bea z9Lh!YCEN)A3rg;+nQ7g8HBh$V8kE3pXx@cEiSQu>;h#fEroYqtH<(7f|14{unUFnG zt0C^IgHZZEfa|y~{ucft^=Y%MoJq{FCL9gLu?a8t98RWPy%^Zb0>^j z4P|R;;R4tM#i_3#x3KyeN-hk0(b@_F$_4Zy6sy-l{=rm!C^>ZyO5j&t#D6J#OoLeS z1r)1(1(RU}N~GUHx%-FAA%UP<^G_j*RtA2P;A$-tXLdsg>?V{6{~B^tsK+oJj^rN* zVpdCn6v#96W0(S);6?aH@HlkNwH)Yy?-EEN6oWhFm&2j(AUp!k zLm4OgW$XLks}#h#mAYXAWGmGc)b+>*!*xYg^8u38%40+O(LrRO3uq=PLub$%sOyof z=z305cqr%p7zNqeQAjMRL;;kC^3h-<&pyP7QGO&_vl^{K?4bGqlBWW-AW5=8NS?hG z)N7jJvOG89zkJ;gFK~sz_jI`w{s`SihtYK;`z6n8vlu$=e6)Hj{s2#nD^FHE z&!c6KosAz~@bn4Jq4>(vD*rO+@)bB9okR=KO|%=ya|uHNuU^gLzV z{bDg3pvxBU-%iPgWSteH@b`Dxrg3Cr%+$? zJv0KnL>k{InBo zJO*E&pupktZ4S6H=jD5i>GQ2$Ivd5dQbOEjxIBfc4X4`(_?+%SR^xa&2^E_^K8!;m zV-Nfuqtp{%Js!8;;r7FT+wW!B0iWMfY~*=-eq(KEiNj~^9W>5-Y4C+U3+;9<0hpf+ zo;O7X@fmifJ#G!27Vw{7OWz}6nR#7&$5wa>vD{1=GS1vOBz1Hl9(JvHfm-JAN`vgJ z+g9vo{b2lb74tB%tEFf*I4WO4{EA%?3S|f5W)~;GZ&Y6RTU+PyJ zPg>&*hk0vwP7jB_^&f`6nK1ZAjsm}06Ug@!c%3EjDrCAn8}mlbMViCw18^LixKR&!KGg1KhQ3q#~QN?MaMg`|Vio!ROf^NWPmJ%%Tt zb;r2(5=O>XtDMEQLWiOkUE<(?nFA*L&Femgi@=P@cCV+z?%C!}SANHP{`e1L+f=~o zQhBQ~zUSEL^pV3EO9&&^n3*+WPDa+ujI3;9#?0IqFJ@%rWM!G3P24m-&lT|6Tp1)r zu`kzfm&B{SmuJj1tm4aAb4}Z%VZoW1S(!QgS8xggM3!s3U-W~uZ}n$=;#0!X=*F(t!Mb0S?Uq)nsk5zy*U!9&9Bm9&-U;2k6{AzaIo1%a>*%&J6|1X`m7NGTU$my8Z@dB4mxuPBjkZ=q8~2+XX}$&RMKXmeHMd`G1GT)4JUmKJTvFyNxP*po&qV7tX0z`{}T`pD3dBwbrVhZK`h%Ros83DcaZ`+PD9i zrdUM{#;VBq`_Zd4u|2mt+wbU#6@iKb?&lv;9)%gGU$^x?Ucs?}*&KEN@SgTcbt@cJHOgom-KndNCoi z_a~v2dn(jW9U9hhM@1{HMjLmB>nb8mXJhA1hfY_UPbM2?ZTjjpdbbbPge&V}C)-2K zhpknF8g7J6m60AyAFezSDm%ht(Z=Jk1Ld7<%`ykQ>1y>;lp-xRt%{j8Wx1I?Wxy!D zj$FGeeOX4hp~{-eiq$NhGHP7-T6yP#8Y?0dswoSd+i$4Q;hIqMF%^CEAbRhjIcVyz zeotd;9X)k%g1KQ@%L{rdu+@6GKs|NX9F&o4dNLfrM=jx__wY8f{|t63%PAbUn%KF> zgBD(NcRX}pZ|HE-)1g@MGoIYNh4rzrU7^YwvUzQ-9F+gtC+?f9IcQC2nV@H<5^lag zw$P#bywRp=$)qcBv!r6>X5GE;xqZ=djggD@Wxm4)!sUm;4K<AkINHP2+;42B+7hWFnLH&;FGI1s&Z z>zQT7mw-{+3|7uPjh4_t$Bz+bXz!iQ_CJs?vhb(lVos`EqNvc_)A5sk?tmhnxrEIBnf^iw;p+_Pn$NnqT9dPidZxrL z0>zaeyBgmy?w4>~ee01~+Y-#g*`o&DI1z5RYGoxcn8Dd&TNll)NHG6B=Shln$gCSl zQYStPNz=N0&f5v8&m4hJLtUh*LRkaFQE}h=*O#6Q;bsh*72KVjZPnpw46ic(DR*ce JPAex&{V#BVpgaHo delta 6184 zcmbW3d2kfhoyVUr*yb=G5SNKV1I7rDW^@>kg@erHBU}oHF~)1sXc}o?G(DaJArgB8 z7$GDCmBl+)^Wv~$~wC>J({UcEKfmdQ;HqT* z*jIe#^IrFRzxRH}Yw_z%pT*+;KBV`4MLUnahN69xvf=H1{LsEVP^rF9hoj(nSOT{} znR3(RPvMh{KZFxu-$6VvXwBb)_yLD~3UAVEDuW&Y>zLH1XDabFA% zhO*&ED4vdibKw*yAq=_izvGU#xZ`H{b>8oToKbZ^vG+qb8QzAy;2$7+sxP2KVgRRz zPowiVolH*PCB_DP1m@%@RR+gF3GEsv&rK*Ey$(mholrbK4dnn`Q0(1?vhhby)_)Ae zu_P47ewRc1<)qVDJq4CQ3F&$$8$_WP+zQ9QeeUz`L-F8!I2Ha9is5V$E0KB(@<`>v z2jEO7c4xcq=R^Lf7l#vnDY|M#a)9knHtvAp!QVmg@HU(WZ78{)!tQc_XZaDsuR=*d zCHy9=hehyba6Igd5vhe-D3S0$IoOOi9r3UXVq29%Sx^aQz$Q2m{shj1cVG$haOz30 z64quZ^%fit`*U@~b1!#UYH1#n4HrOhY$cQwR=JFCpd(fJrptX$LfHnzvv;8s&2{)J z{J?!a`6j7bP&W8i z_#{k1F*uq^lIOWl#xtO-f8HJIQ1%JBjJeOhJDL1T(d=*^{1D29KZ6gzkD)C570iPP zC?U?Kgk|0sD3O@xju${Vz%nQY(jm^OC=`3gU?*&aGVkR$R;5}ip*(1FdBx>T$dy(f zxZ@t!m+@z?AN&)PgY?aJu5mUTz<4Ya$2?FR@Iy&;$Q{>1nHO(%JBOi!?5sQfTbKU` zxmoJppltkw%ibQR>IcH!Jf8q%qsdSV7rLAYB@*+Y*m>1`{s!dWanCXWN-BYC=p4(59e{iCJ;;HQ>uFFvG_#<52VQ~_(ir6Pul7T!mCH~L{(;K`l!$x@ zB|^QYI(!($C8PuB$S3x3_!6vh`7z`ys%V;0q+P9r5}AEas``B>2mBPu#sjB2|KXSn zxtVG?`V73rZ+|1ZCkbpm=fz&V#>) zL*dhu`dhFZ%KQI>60tNSbD8vh7dD{XNZK|uSn|Ju&RjGL9YcBO9dv)&#egfD$+LKl z18NUyLDHmPrFNv%pmy{G+Kc4id^R$U0<|5jln!m584fbPbNHQ) zq)w#uMjOy`GN4(g3Pn*J8il0E)jWeFjgoV@lHWmYi)Ze%{5|J(W!idvn@}HTnECbd zD|xL(Yf%N7hon)XnPQXvYIF*H8y!H>7CTVOTnb)y`{%^vml$Nb4|3pPw=ehxnuum2 z`8Y{?CiCn3i~~#EaWO1JhmelGh1$>(bhquGa}+)AJ}A4Je;IE@W6(gY^ppy~nA;beMuX5aG!m7g<>&uRU#jnfnGr&v=C+5gviQ@fEh6+L{#p)YTX~u zD)eB`jB0BPEo@Yq8w}qhmAlA{8l{@^-XGEQK#g7-(W>>JPmh}6T8++q>nf`BV5Q;n zSjOND)~AEVKIENi1dOO*Y1y$^ezP*HhpPM)dO&+2xYks&1A4`J?YV#+iKsbMx=))O ziw2Ca^s%Cq^Ss6k`xqM)>kVI-^>Ox8Yt)dhSqp}Y=@Sb^!?o6oq2uD29n@U530M1r zhE~HCRoYs=5%5K{8h;?5`TUVkKz9!7yw$_v2jHss`v)_h?zNkVhBE8zUzyJR~ z&xjHGt)(NMv;JY^+g9zU;*PFSFJwIusR;Ws8>wZBms-O{Pw9ANbWZQ#&t_7fmS=pq zm(GsuV{T;iG9uQjv5$4c#{MG98Zv&!*k~*q#ILnlv`R8l>5oLiM4hvT!e)gLiFC{v zUz-(w*&kACVo|NujFF~@sYQ&a7B#hM(`PW>kb3kIUn5h{nHXe3e80sA317+jOlbrS z!zTvBPAo)1?w_fJbm~y@6^j_8IojWJ-y301N7v)ES;MQM(NL+^%bBR$H375IQ(;zn ztwm3K7>^noqe^}#HeHp6&2>gaH2(!({)^bcv(kGdgy|yBlb!;uUR2kf?6<@Snc-;u z!bqjxmp?mJ8OdK}mTK-+awS4xBH}T_mENdc>8%OnS4$;^BmK%3FUz09c0_JoFn=x) zDb)fAUr?%ftITS{tH;8IH>~@8-kO>k?_KZXk=4b8OXd`CcM5UcbDBlm|zO^Boq98I_E;A3~^Mnn2Ymwj+?H&*klay67@XC4n!W3U zeYR;uxihx+?!5b53`gusr&4csJ1?v=Qx^-g4yE$?E$nczu&Z!hObbaf@V_Y*|k zspN$>6Wz_}*5mf^CgmJJBdpCTb*npdy-g)Lo03gCWPQt}JT1|EON@8cC3jp;?(ekg zZjh_Qu*@7LDErpIRQo|EIUOVN=VV#B=d50)Gz!4peOaaJ4)>fmOkJVVP z%^FphYb`1~7f&``NnYHMrxD@%V`*ReUe8sF=#Vq}$_2Z#BiV2@V=KA)2!`xB*QiIi z7BE08n8l%4&AmwOYUN3u9N@1l(meOpkSNL~eX@c4DEr!Rm1^ITZn>h8N1N@YL&;Oe zk{51jR(H|pj{h#Ie4tOJ1g-LEIUP0ALRq6FniK~cC%R5gh)4);zSDE4%ieanBfI2G z);Nlq`u%f>Ik(!m5k2iq_Itancc1#7xKm)Mj_t{oLl|?aVyxoEr#By`9#V%+uunbH z64y^SHl1s&u`d_Fn`~%F)ouIAH^9lSQ+dvY9xCUg>+P2JQtjs`_)H*1T*amnUT0?d jwpmem_dropin_folder filter." +msgstr "" -#: admin/dialogs.php:118 -msgid "" -"Leaving this set to full text allows anyone to read your protected content " -"in an RSS reader. Changing this to Summary prevents this as your feeds will " -"only show summary text." +#: admin/tab-dropins.php:205 +msgid "Current dropin folder: " msgstr "" -"ä¿ç•™é€™è£¡è¨­ç‚ºå…¨æ–‡,å°‡å…許任何人在一RSS閱讀器å¯é–±è®€ä½ ä¿è­·çš„æ–‡ç« å…§å®¹.將此改為概è¦" -"å°±å¯ä»¥é˜²æ­¢,å› ä½ çš„RSS訊æ¯ä¾†æºåªæœƒé¡¯ç¤ºæ¦‚è¦è¨Šæ¯æ–‡å­—." -#: admin/dialogs.php:122 -msgid "You have set WP-Members to hold registrations for approval" -msgstr "你已將WP-Members設為核准中ä¿ç•™è¨»å†Š" +#: admin/tab-dropins.php:204 +msgid "Manage Dropins" +msgstr "" -#: admin/dialogs.php:123 -msgid "" -"but you have not changed the default message for \"Registration Completed\" " -"under \"WP-Members Dialogs and Error Messages.\" You should change this " -"message to let users know they are pending approval." +#: admin/tab-dropins.php:79 admin/tab-dropins.php:378 +msgid "WP-Members Dropin settings were updated" msgstr "" -"但你尚未變更在\"WP-Memberså°è©±æ¡†åŠéŒ¯èª¤è¨Šæ¯\" 裡默èªçš„\"註冊完æˆ\"訊æ¯. 你應該" -"變更此訊æ¯ä»¥è®“用戶知é“他們的註冊正在核å¯ä¸­" -#: admin/dialogs.php:127 -msgid "You have set WP-Members to turn off the registration process" -msgstr "你已設定WP-Members關閉註冊程åº" +#: admin/tab-fields.php:525 +msgid "Users Search" +msgstr "" -#: admin/dialogs.php:128 -msgid "" -"but you also set to moderate and/or email admin new registrations. You will " -"need to set up a registration page for users to register." +#: admin/tab-fields.php:429 +msgid "Subscription Type" msgstr "" -"但你也設定管制 以åŠ/或者 é›»å­éƒµä»¶ç®¡ç†æ–°çš„註冊. 你必須為訪客用戶設一個註冊é " -"é¢." -#: admin/dialogs.php:132 -msgid "You have turned on reCAPTCHA" -msgstr "你已打開驗證碼æœå‹™åŠŸèƒ½" +#: admin/tab-fields.php:872 +msgid "Form field order updated." +msgstr "" -#: admin/dialogs.php:133 -msgid "" -"but you have not entered API keys. You will need both a public and private " -"key. The CAPTCHA will not display unless a valid API key is included." +#: admin/tab-fields.php:830 +msgid "%s was updated" msgstr "" -"但你尚未輸入應用程å¼ä»‹é¢éµ. 你需è¦ä¸€å€‹å…¬é–‹éµåŠä¸€å€‹éš±å¯†éµ. 除éžå«æœ‰ä¸€å€‹æœ‰æ•ˆçš„" -"APIéµå¦å‰‡é©—è­‰ç¢¼åŠŸèƒ½ä¸æœƒé¡¯ç¤º." -#: admin/dialogs.php:157 -msgid "Version:" -msgstr "版本:" +#: admin/tab-fields.php:817 +msgid "%s was added" +msgstr "" -#: admin/dialogs.php:158 -#, fuzzy -msgid "Quick Start Guide" +#: admin/tab-fields.php:732 +msgid "Meta Key is required. Nothing was updated." msgstr "" -"Restricción de acceso a WordPress y registro extendido de usuarios. Para más " -"información, puede descargar la guía de usuario en http://butlerblog.com/wp-members. Vea una " -"demostración en http://" -"butlerblog.com/wpmembers. WP-Members(tm) es marca registrada de " -"butlerblog.com." -#: admin/dialogs.php:159 -#, fuzzy -msgid "Online User Guide" -msgstr "用戶更新" +#: admin/tab-fields.php:731 +msgid "Field Label is required. Nothing was updated." +msgstr "" -#: admin/dialogs.php:160 -msgid "FAQs" +#: admin/tab-dropins.php:315 admin/tab-fields.php:568 +msgid "Save Settings" msgstr "" -#: admin/dialogs.php:167 -#, fuzzy -msgid "Thank you for using WP-Members" -msgstr "æ„Ÿè¬æ‚¨ä½¿ç”¨WP-Members! 您所使用的是 %s 版本" +#: admin/tab-fields.php:567 +msgid "Delete Selected" +msgstr "" -#: admin/dialogs.php:168 -msgid "A plugin developed by" +#: admin/tab-fields.php:517 +msgid "Display Label" msgstr "" -#: admin/dialogs.php:169 -msgid "Follow" -msgstr "追蹤" +#: admin/tab-fields.php:420 +msgid "Drag and drop to reorder fields" +msgstr "" -#: admin/dialogs.php:186 admin/dialogs.php:190 -msgid "Latest from RocketGeek" +#: admin/tab-fields.php:380 admin/tab-fields.php:831 +msgid "Return to Fields Table" msgstr "" -#: admin/dialogs.php:207 admin/dialogs.php:220 -msgid "Latest from ButlerBlog" +#: admin/tab-fields.php:269 +msgid "Maximum Value" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:220 -msgid "Options" -msgstr "é¸é …" +#: admin/tab-fields.php:265 +msgid "Minimum Value" +msgstr "" -#: admin/includes/class-wp-members-admin-api.php:221 -msgid "Fields" -msgstr "å€å¡Š " +#: admin/tab-fields.php:256 +msgid "Title" +msgstr "" -#: admin/includes/class-wp-members-admin-api.php:222 -msgid "Dialogs" -msgstr "å°è©±æ¡†" +#: admin/tab-fields.php:250 +msgid "Pattern" +msgstr "" -#: admin/includes/class-wp-members-admin-api.php:223 -msgid "Emails" -msgstr "é›»å­éƒµä»¶" +#: admin/tab-fields.php:242 +msgid "Placeholder" +msgstr "" -#: admin/includes/class-wp-members-admin-api.php:239 -msgid "New Registration" -msgstr "新註冊" +#: admin/tab-fields.php:235 +msgid "Allow HTML?" +msgstr "" -#: admin/includes/class-wp-members-admin-api.php:248 -msgid "Registration is Moderated" -msgstr "註冊正在核å¯" +#: admin/tab-fields.php:220 +msgid "date" +msgstr "" -#: admin/includes/class-wp-members-admin-api.php:254 -msgid "Registration is Moderated, User is Approved" -msgstr "註冊正在核å¯,用戶核准" +#: admin/tab-fields.php:219 +msgid "number" +msgstr "" -#: admin/includes/class-wp-members-admin-api.php:262 -msgid "Password Reset" -msgstr "密碼é‡è¨­" +#: admin/tab-fields.php:151 +msgid "Field Manager Documentation" +msgstr "" -#: admin/includes/class-wp-members-admin-api.php:269 -msgid "Retrieve Username" +#: admin/tab-fields.php:137 +msgid "Fields deleted" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:277 -msgid "Admin Notification" -msgstr "管ç†å“¡é€šçŸ¥è¡Œç‚º" +#: admin/tab-fields.php:110 +msgid "Are you sure you want to delete the following fields?" +msgstr "" -#: admin/post.php:51 admin/post.php:53 admin/tab-options.php:87 -#, fuzzy -msgid "Block" -msgstr "默èªå°éŽ–ç™¼æ–‡" +#: admin/tab-options.php:90 +msgid "Content Blocking" +msgstr "" -#: admin/post.php:52 admin/post.php:54 -msgid "Unblock" +#: admin/includes/class-wp-members-admin-api.php:274 +msgid "Your custom email message content." msgstr "" -#: admin/post.php:188 -#, php-format -msgid "%s Restriction" +#: admin/includes/class-wp-members-admin-api.php:268 +msgid "Custom email" msgstr "" -#: admin/post.php:215 -#, php-format -msgid "%s are blocked by default." +#: admin/tab-options.php:191 +msgid "Really Simple CAPTCHA" msgstr "" -#: admin/post.php:216 -#, php-format -msgid "Unblock this %s" +#: admin/tab-options.php:190 +msgid "reCAPTCHA" msgstr "" -#: admin/post.php:219 -#, php-format -msgid "%s are not blocked by default." +#: admin/tab-options.php:134 +msgid "Custom read more link (optional):" msgstr "" -#: admin/post.php:220 -#, php-format -msgid "Block this %s" +#: admin/tab-fields.php:191 admin/tab-fields.php:518 +msgid "Meta Key" msgstr "" -#: admin/post.php:226 admin/tab-fields.php:282 admin/tab-fields.php:473 -msgid "Edit" +#: admin/tab-fields.php:359 +msgid "Value" msgstr "" -#: admin/post.php:313 -#, fuzzy -msgid "Unblocked?" -msgstr "附註: 在文章層級,é é¢ä»å¯å–®ç¨é¸æ“‡å°éŽ–æˆ–æ‰“é–‹" +#: admin/tab-fields.php:810 +msgid "A value is required for hidden fields. Nothing was updated." +msgstr "" -#: admin/post.php:313 -#, fuzzy -msgid "Blocked?" -msgstr "附註: 在文章層級,é é¢ä»å¯å–®ç¨é¸æ“‡å°éŽ–æˆ–æ‰“é–‹" +#: admin/tab-fields.php:323 +msgid "Values (Displayed|Stored):" +msgstr "" -#: admin/post.php:345 admin/post.php:346 admin/user-export.php:108 -msgid "Yes" -msgstr "å¯" +#: admin/post.php:143 +msgid "%s blocked" +msgstr "" -#: admin/tab-captcha.php:42 admin/tab-dialogs.php:47 admin/tab-emails.php:80 -#: admin/tab-fields.php:44 admin/tab-options.php:58 -msgid "Need help?" +#: admin/post.php:143 +msgid "%s unblocked" msgstr "" -#: admin/tab-captcha.php:53 -msgid "Manage reCAPTCHA Options" -msgstr "管ç†é©—證碼系統é¸é …" +#: inc/api.php:471 +msgid "log out" +msgstr "登出" -#: admin/tab-captcha.php:67 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." -msgstr "" -"reCAPTCHA 是一個å…費開放的驗證碼系統技術æœå‹™, 它å¯ä»¥å°‡æ–‡å­—內容數字化,幫你擋除" -"éƒ¨è½æ ¼ä¸­çš„垃圾留言,訊æ¯. " +#: admin/users.php:180 +msgid "That user is already active" +msgstr "該用戶帳號已啟用" -#: admin/tab-captcha.php:68 -#, fuzzy, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" -msgstr "" -"驗証碼æœå‹™è¦æ±‚ä½¿ç”¨è€…é‡æ–°è¼¸å…¥å¾žä¸€æœ¬æ›¸æŽƒæä¾†çš„二個字以證明輸入者是人類.如此å¯ä»¥" -"è­˜åˆ¥è¼¸å…¥è€…ä¸æ˜¯è£½é€ åžƒåœ¾æ–‡ä»¶çš„æ©Ÿå™¨äºº, åŒæ™‚也å°åŽŸæ–‡çš„æŽƒæä½œè‡ªå‹•æ›´æ­£.如此, 你比較" -"䏿œƒæ”¶åˆ°åžƒåœ¾æ–‡ä»¶, 大家也ç²å¾—æ­£ç¢ºæ•¸å­—åŒ–çš„é›»å­æ–‡ä»¶. å°å¤§å®¶çš†æœ‰åˆ©! 詳細介紹請åƒ" -"訪reCAPTCHA的網站." - -#: admin/tab-captcha.php:73 admin/tab-captcha.php:99 -msgid "reCAPTCHA Keys" -msgstr " 驗証碼æœå‹™éµ" +#: admin/users.php:175 +msgid "%s activated" +msgstr "" -#: admin/tab-captcha.php:75 -#, fuzzy, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: admin/users.php:151 +msgid "No users selected" msgstr "" -"驗証碼æœå‹™éœ€è¦æ‡‰ç”¨ç¨‹å¼ä»‹é¢éµ, 由一個 \"public\"和一個 \"private\"éµçµ„æˆ. ä½ å¯" -"以註冊一組å…費的驗證碼æœå‹™éµ" -#: admin/tab-captcha.php:76 -msgid "Public Key" -msgstr "公開éµ" +#: admin/users.php:148 +msgid "%s users activated" +msgstr "%s 用戶已啟用" -#: admin/tab-captcha.php:77 -msgid "Private Key" -msgstr "隱密éµ" +#: admin/tab-options.php:261 +msgid "Add to WP-Members Settings" +msgstr "" -#: admin/tab-captcha.php:81 -msgid "Choose Theme" -msgstr "鏿“‡ä¸»é¡Œ" +#: admin/tab-options.php:161 +msgid "Other Settings" +msgstr "" -#: admin/tab-captcha.php:84 -msgid "Red" -msgstr " ç´…" +#: admin/tab-options.php:151 +msgid "Subscription Settings" +msgstr "" -#: admin/tab-captcha.php:85 -msgid "White" -msgstr "白" +#: admin/tab-options.php:79 +msgid "Content" +msgstr "內容" -#: admin/tab-captcha.php:86 -msgid "Black Glass" -msgstr "黑玻璃" +#: admin/tab-fields.php:314 +msgid "Stored values delimiter:" +msgstr "" -#: admin/tab-captcha.php:87 -msgid "Clean" -msgstr "乾淨" +#: admin/tab-about.php:34 admin/tab-about.php:56 +msgid "About WP-Members" +msgstr "關於 WP-Members" -#: admin/tab-captcha.php:101 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: admin/dialogs.php:145 +msgid "If you will not be changing these settings, you can turn off these warning messages by checking the \"Ignore warning messages\" in the settings below." msgstr "" -#: admin/tab-captcha.php:102 -msgid "Site Key" +#: admin/dialogs.php:144 +msgid "You have active settings that are not recommended." msgstr "" -#: admin/tab-captcha.php:103 -msgid "Secret Key" -msgstr "" +#: inc/class-wp-members.php:1057 +msgid "Password successfully reset!

    An email containing a new password has been sent to the email address on file for your account." +msgstr "密碼已æˆåŠŸé‡ç½®ï¼

    åŒ…å«æ–°å¯†ç¢¼çš„é›»å­éƒµä»¶å·²ç™¼é€åˆ°æ‚¨å¸³æˆ¶çš„é›»å­éƒµä»¶åœ°å€ã€‚" -#: admin/tab-captcha.php:134 -msgid "Characters for image" -msgstr "" +#: inc/class-wp-members.php:1056 +msgid "Either the username or email address do not exist in our records." +msgstr "ç”¨æˆ¶åæˆ–é›»å­éƒµä»¶åœ°å€ä¸åœ¨æˆ‘們的記錄中。" -#: admin/tab-captcha.php:138 -msgid "Number of characters" -msgstr "" +#: inc/class-wp-members.php:1055 +msgid "Password successfully changed!" +msgstr "密碼修改æˆåŠŸï¼" -#: admin/tab-captcha.php:142 -msgid "Image dimensions" -msgstr "" +#: inc/class-wp-members.php:1054 +msgid "Passwords did not match.

    Please try again." +msgstr "å¯†ç¢¼ä¸æ­£ç¢ºã€‚

    è«‹é‡è©¦ã€‚" -#: admin/tab-captcha.php:143 -msgid "Width" -msgstr "" +#: inc/class-wp-members.php:1053 +msgid "Your information was updated!" +msgstr "您的資訊已更新ï¼" -#: admin/tab-captcha.php:143 -msgid "Height" -msgstr "" +#: inc/class-wp-members.php:1052 +msgid "Congratulations! Your registration was successful.

    You may now log in using the password that was emailed to you." +msgstr "æ­å–œï¼ 您已完æˆè¨»å†Šã€‚

    您ç¾åœ¨å¯ä»¥ä½¿ç”¨å¯„發給您的密碼登入網站。" -#: admin/tab-captcha.php:146 -msgid "Font color of characters" -msgstr "" +#: inc/class-wp-members.php:1051 +msgid "Sorry, that email address already has an account.
    Please try another." +msgstr "很抱歉,該電å­éƒµä»¶åœ°å€å·²è¢«ä½¿ç”¨ã€‚
    請嘗試其他電å­éƒµä»¶åœ°å€ã€‚" -#: admin/tab-captcha.php:150 -msgid "Background color of image" +#: inc/class-wp-members.php:1050 +msgid "Sorry, that username is taken, please try another." +msgstr "抱歉,帳號已被使用,請嘗試å¦ä¸€çµ„帳號。" + +#: inc/class-wp-members.php:1049 +msgid "This content is restricted to site members. If you are an existing user, please log in. New users may register below." msgstr "" -#: admin/tab-captcha.php:154 -msgid "Font size" +#: inc/class-wp-members.php:1007 +msgid "Update this file" msgstr "" -#: admin/tab-captcha.php:158 -msgid "Width between characters" +#: inc/class-wp-members.php:958 +msgid "TOS" msgstr "" -#: admin/tab-captcha.php:162 -#, fuzzy -msgid "Image type" -msgstr "欄ä½é¡žåž‹" +#: inc/class-wp-members.php:957 +msgid "Confirm Password" +msgstr "確èªå¯†ç¢¼" -#: admin/tab-captcha.php:176 -msgid "" -"To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " -"installed and activated." +#: inc/class-wp-members.php:955 +msgid "Biographical Info" msgstr "" -#: admin/tab-captcha.php:200 -#, fuzzy -msgid "Update CAPTCHA Settings" -msgstr "更新設定" +#: inc/class-wp-members.php:954 +msgid "Website" +msgstr "網站" -#: admin/tab-captcha.php:271 -#, fuzzy -msgid "CAPTCHA was updated for WP-Members" -msgstr "reCAPTCHA已經更新" +#: inc/class-wp-members.php:953 +msgid "Confirm Email" +msgstr "確èªéƒµä»¶" -#: admin/tab-dialogs.php:32 -msgid "Restricted post (or page), displays above the login/registration form" -msgstr "有é™åˆ¶çš„發文(或é é¢), 顯示於登入/註冊表上方" +#: inc/class-wp-members.php:951 +msgid "Day Phone" +msgstr "日間電話" -#: admin/tab-dialogs.php:33 -msgid "Username is taken" -msgstr "帳戶å已被使用" +#: inc/class-wp-members.php:950 +msgid "Country" +msgstr "國家" -#: admin/tab-dialogs.php:34 -msgid "Email is registered" -msgstr "é›»å­éƒµä»¶å·²è¢«è¨»å†Š" +#: inc/class-wp-members.php:949 +msgid "Zip" +msgstr "" -#: admin/tab-dialogs.php:35 -msgid "Registration completed" -msgstr "完æˆè¨»å†Š" +#: inc/class-wp-members.php:948 +msgid "State" +msgstr "å·ž" -#: admin/tab-dialogs.php:36 -msgid "User update" -msgstr "用戶更新" +#: inc/class-wp-members.php:947 +msgid "City" +msgstr "城市" -#: admin/tab-dialogs.php:37 -msgid "Passwords did not match" -msgstr "密碼ä¸ç¬¦" +#: inc/class-wp-members.php:946 +msgid "Address 2" +msgstr "åœ°å€ 2" -#: admin/tab-dialogs.php:38 -msgid "Password changes" -msgstr "更改密碼" +#: inc/class-wp-members.php:945 +msgid "Address 1" +msgstr "åœ°å€ 1" -#: admin/tab-dialogs.php:39 -msgid "Username or email do not exist when trying to reset forgotten password" -msgstr "ç•¶è¦é‡è¨­å¿˜è¨˜çš„å¯†ç¢¼æ™‚ç”¨æˆ¶åæˆ–é›»å­éƒµä»¶ä¸å­˜åœ¨" +#: inc/class-wp-members.php:944 +msgid "Last Name" +msgstr "å§“" -#: admin/tab-dialogs.php:40 -msgid "Password reset" -msgstr "密碼é‡è¨­" +#: inc/class-wp-members.php:943 +msgid "First Name" +msgstr "åå­—" -#: admin/tab-dialogs.php:57 -msgid "Dialogs and Error Messages" -msgstr "å°è©±æ¡†å’ŒéŒ¯èª¤è¨Šæ¯" +#: admin/tab-fields.php:221 +msgid "hidden" +msgstr "" -#: admin/tab-dialogs.php:59 -#, fuzzy, php-format -msgid "" -"You can customize the text for dialogs and error messages. Simple HTML is " -"allowed %s etc." -msgstr "å¯è‡ªè¨­å°è©±æ¡†å’ŒéŒ¯èª¤è¨Šæ¯çš„æ–‡å­—內容, ......" +#: admin/tab-fields.php:218 +msgid "url" +msgstr "ç¶²å€" -#: admin/tab-dialogs.php:72 -msgid "Terms of Service (TOS)" -msgstr "æœå‹™æ¢æ¬¾" +#: admin/tab-fields.php:216 +msgid "image" +msgstr "圖片" -#: admin/tab-dialogs.php:79 -msgid "Update Dialogs" -msgstr "æ›´æ–°å°è©±æ¡†" +#: admin/tab-fields.php:214 +msgid "radio group" +msgstr "" -#: admin/tab-dialogs.php:118 -msgid "WP-Members dialogs were updated" -msgstr "WP_Memberså°è©±æ¡†å·²æ›´æ–°" +#: admin/tab-fields.php:213 +msgid "multiple select" +msgstr "" -#: admin/tab-emails.php:37 -msgid "Email Messages" -msgstr "é›»å­éƒµä»¶è¨Šæ¯" +#: admin/tab-fields.php:212 +msgid "select (dropdown)" +msgstr "鏿“‡ï¼ˆä¸‹æ‹‰ï¼‰" -#: admin/tab-emails.php:40 -msgid "You can customize the content of the emails sent by the plugin." -msgstr "您å¯ä»¥è‡ªè¨‚æ’件發é€çš„é›»å­éƒµä»¶çš„內容" +#: admin/tab-fields.php:211 +msgid "multiple checkbox" +msgstr "" -#: admin/tab-emails.php:42 -msgid "A list of shortcodes is available here." -msgstr "列表的簡碼å¯ä»¥åœ¨é€™è£¡æ‰¾åˆ°" +#: admin/tab-fields.php:208 +msgid "email" +msgstr "電郵地å€" -#: admin/tab-emails.php:49 -msgid "Set a custom email address" -msgstr "設置自定義的電å­éƒµä»¶åœ°å€" +#: inc/class-wp-members.php:986 +msgid "Click here" +msgstr "按這裡" -#: admin/tab-emails.php:50 admin/tab-emails.php:54 admin/tab-emails.php:64 -msgid "(optional)" -msgstr "(é¸é …)" +#: inc/class-wp-members.php:985 +msgid "Forgot username?" +msgstr "忘記用戶å?" -#: admin/tab-emails.php:53 -msgid "Set a custom email name" -msgstr "設置自定義的電å­éƒµä»¶å稱" +#: admin/tab-options.php:356 +msgid "Custom Post Type settings were updated" +msgstr "" -#: admin/tab-emails.php:64 -msgid "Email Signature" -msgstr "電郵簽å" - -#: admin/tab-emails.php:72 -msgid "Update Emails" -msgstr "æ›´æ–°é›»å­éƒµä»¶" - -#: admin/tab-emails.php:140 -msgid "WP-Members emails were updated" -msgstr "WP_Membersé›»å­éƒµä»¶å·²æ›´æ–°" - -#: admin/tab-fields.php:169 -msgid "WP-Members fields were updated" -msgstr "WP_Memberså€å¡Šå·²æ›´æ–°" +#: admin/tab-options.php:255 +msgid "Custom Post Types" +msgstr "自訂文章類型" -#: admin/tab-fields.php:181 -msgid "Field Label is required for adding a new field. Nothing was updated." -msgstr "é¸å¡«æ¨™ç±¤æ˜¯ç”¨ä¾†å¢žåŠ æ–°çš„é¸å¡«.沒有任何更新" +#: admin/post.php:214 +msgid "Block this %s" +msgstr "å°éޖ這個 %s" -#: admin/tab-fields.php:182 -msgid "Option Name is required for adding a new field. Nothing was updated." -msgstr "å§“åé¸å¡«æ˜¯ç”¨ä¾†å¢žåŠ æ–°çš„æ¬„ä½.沒有任何更新" +#: admin/post.php:213 +msgid "%s are not blocked by default." +msgstr "%s é è¨­ä¸è¢«å°éŽ–ã€‚" -#: admin/tab-fields.php:184 -msgid "Option Name must contain only letters, numbers, and underscores" +#: admin/post.php:210 +msgid "Unblock this %s" msgstr "" -#: admin/tab-fields.php:191 -msgid "A field with that option name already exists" -msgstr "" +#: admin/post.php:209 +msgid "%s are blocked by default." +msgstr "%s 被é è¨­å°éŽ–ã€‚" -#: admin/tab-fields.php:197 -#, php-format -msgid "" -"Sorry, \"%s\" is a reserved term. " -"Field was not added." +#: admin/post.php:182 +msgid "%s Restriction" msgstr "" -#: admin/tab-fields.php:215 -#, fuzzy -msgid "Checked value is required for checkboxes. Nothing was updated." -msgstr "é¸å¡«æ¨™ç±¤æ˜¯ç”¨ä¾†å¢žåŠ æ–°çš„é¸å¡«.沒有任何更新" - -#: admin/tab-fields.php:245 -#, fuzzy -msgid "field was added" -msgstr "å€å¡Šæ¨™ç±¤" - -#: admin/tab-fields.php:263 -#, fuzzy -msgid "field was updated" -msgstr "WP_Memberså€å¡Šå·²æ›´æ–°" - -#: admin/tab-fields.php:309 admin/tab-fields.php:437 -#, fuzzy -msgid "Edit Field" -msgstr "編輯你的資訊" - -#: admin/tab-fields.php:309 -#, fuzzy -msgid "Add a Field" -msgstr "增加/刪除" - -#: admin/tab-fields.php:315 admin/tab-fields.php:467 -msgid "Field Label" -msgstr "å€å¡Šæ¨™ç±¤" - -#: admin/tab-fields.php:317 -msgid "The name of the field as it will be displayed to the user." +#: inc/class-wp-members.php:989 inc/class-wp-members.php:991 +msgid "Retrieve username" msgstr "" -#: admin/tab-fields.php:320 admin/tab-fields.php:468 -msgid "Option Name" -msgstr "é¸é …å稱" +#: inc/class-wp-members.php:990 +msgid "Email Address" +msgstr "郵箱地å€" -#: admin/tab-fields.php:326 -msgid "" -"The database meta value for the field. It must be unique and contain no " -"spaces (underscores are ok)." +#: inc/class-wp-members.php:1015 +msgid "An email was sent to %s with your username." msgstr "" -#: admin/tab-fields.php:330 admin/tab-fields.php:469 -msgid "Field Type" -msgstr "欄ä½é¡žåž‹" - -#: admin/tab-fields.php:336 -msgid "text" -msgstr "文字" - -#: admin/tab-fields.php:337 -msgid "email" +#: inc/class-wp-members.php:1014 +msgid "Sorry, that email address was not found." msgstr "" -#: admin/tab-fields.php:338 -msgid "textarea" -msgstr "æ–‡å­—å€ " - -#: admin/tab-fields.php:339 -msgid "checkbox" -msgstr "æ ¸é¸æ¡†" +#: admin/includes/class-wp-members-admin-api.php:401 +msgid "Retrieve Username" +msgstr "" -#: admin/tab-fields.php:340 -msgid "multiple checkbox" +#. Author URI of the plugin/theme +msgid "http://butlerblog.com/" msgstr "" -#: admin/tab-fields.php:341 -msgid "select (dropdown)" +#. Author of the plugin/theme +msgid "Chad Butler" msgstr "" -#: admin/tab-fields.php:342 -msgid "multiple select" +#. Description of the plugin/theme +msgid "WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com." msgstr "" -#: admin/tab-fields.php:343 -msgid "radio group" +#. Plugin URI of the plugin/theme +msgid "https://rocketgeek.com" msgstr "" -#: admin/tab-fields.php:344 -msgid "password" -msgstr "密碼" +#. Plugin Name of the plugin/theme +msgid "WP-Members" +msgstr "WP-Members" -#: admin/tab-fields.php:345 -msgid "image" +#: wp-members-tos.php:37 +msgid "%sprint%s" msgstr "" -#: admin/tab-fields.php:346 -msgid "file" -msgstr "" +#: wp-members-tos.php:35 +msgid "%sclose%s" +msgstr "%s關閉%s" -#: admin/tab-fields.php:347 -msgid "url" -msgstr "" +#: wp-members-tos.php:23 +msgid "Terms of Service" +msgstr "æœå‹™æ¢æ¬¾" -#: admin/tab-fields.php:348 -msgid "hidden" -msgstr "" +#: inc/utilities.php:152 +msgid "(more…)" +msgstr "(繼續閱讀…)" -#: admin/tab-fields.php:353 admin/tab-fields.php:470 -msgid "Display?" -msgstr "顯示?" +#: inc/class-wp-members-user-profile.php:37 inc/deprecated.php:639 +#: inc/users.php:37 +msgid "Additional Information" +msgstr "附加資訊" -#: admin/tab-fields.php:357 admin/tab-fields.php:471 -msgid "Required?" -msgstr "å¿…è¦?" +#: inc/class-wp-members.php:1039 +msgid "click here to log out" +msgstr "點擊此處登出" -#: admin/tab-fields.php:363 -msgid "Additional information for field upload fields" -msgstr "" +#: inc/class-wp-members.php:1045 +msgid "Forgot?" +msgstr "忘記?" -#: admin/tab-fields.php:366 -msgid "Accepted file types:" -msgstr "" +#: inc/api.php:470 inc/class-wp-members.php:1044 +msgid "log in" +msgstr "登入" -#: admin/tab-fields.php:371 -msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" -msgstr "" +#: inc/class-wp-members.php:1041 +msgid "You are not logged in." +msgstr "你尚未登入。" -#: admin/tab-fields.php:378 -#, fuzzy -msgid "Additional information for checkbox fields" -msgstr "WP-members附加å€å¡Š" +#: inc/class-wp-members.php:1040 +msgid "Login Failed!
    You entered an invalid username or password." +msgstr "登入失敗! ä½ è¼¸å…¥äº†ä¸€å€‹ç„¡æ•ˆçš„ç”¨æˆ¶åæˆ–密碼." -#: admin/tab-fields.php:381 -#, fuzzy -msgid "Checked by default?" -msgstr "åˆæ ¼?" +#: inc/shortcodes.php:576 +msgid "Click here to log out." +msgstr "點擊此處登出" -#: admin/tab-fields.php:385 -#, fuzzy -msgid "Stored value if checked:" -msgstr "åˆæ ¼?" +#: inc/register.php:435 +msgid "You have entered an incorrect code value. Please try again." +msgstr "" -#: admin/tab-fields.php:397 -#, fuzzy -msgid "Additional information for dropdown fields" -msgstr "WP-members附加å€å¡Š" +#: inc/register.php:431 +msgid "The reCAPTCHA server was not reached. Please try to resubmit." +msgstr "驗證碼功能伺æœå™¨ç„¡æ³•連線. è«‹å˜—è©¦é‡æ–°æäº¤." -#: admin/tab-fields.php:400 -msgid "For dropdown, array of values:" -msgstr "下拉é¸å–®, 使用一批數值於下拉單" +#: inc/register.php:427 +msgid "reCAPTCHA API keys are tied to a specific domain name for security reasons." +msgstr "驗證碼功能的APIéµå› å®‰å…¨ç¶­è­·èˆ‡ç‰¹å®šç¶²åŸŸå有所連çµ" -#: admin/tab-fields.php:425 -msgid "Options should be Option Name|option_value," -msgstr "é¸é …須為é¸é …值" +#: inc/register.php:423 +msgid "The parameters to verify were incorrect" +msgstr "ç”¨ä»¥é©—è­‰ä¹‹åƒæ•¸ä¸æ­£ç¢º" -#: admin/tab-fields.php:429 -msgid "Visit plugin site for more information" -msgstr "更多資訊請查閱æ’件網站" +#: inc/register.php:419 +msgid "The CAPTCHA solution was incorrect." +msgstr "é©—è­‰ç¢¼è§£ç­”ä¸æ­£ç¢º" -#: admin/tab-fields.php:437 -#, fuzzy -msgid "Add Field" -msgstr "增加/刪除" +#: inc/register.php:415 +msgid "The challenge parameter of the verify script was incorrect." +msgstr "é©—è­‰è…³æœ¬ä¸­çš„ç ´è§£åƒæ•¸ä¸æ­£ç¢º" -#: admin/tab-fields.php:458 -msgid "Manage Fields" -msgstr "å€å¡Šç®¡ç†" +#: inc/register.php:411 +msgid "We were unable to validate the private key." +msgstr "你沒有驗證隱密éµ" -#: admin/tab-fields.php:460 -msgid "" -"Determine which fields will display and which are required. This includes " -"all fields, both native WP fields and WP-Members custom fields." -msgstr "" -"判定哪些å€å¡Šæœƒé¡¯ç¤ºåŠå“ªäº›å€å¡Šæ˜¯å¿…è¦çš„. 這裡包括所有å€å¡Š, 原始WPå€å¡Šå’ŒWP-" -"Members客製å€å¡Š" +#: inc/register.php:407 +msgid "We were unable to validate the public key." +msgstr "你沒有驗證公開éµ" -#: admin/tab-fields.php:461 -msgid "(Note: Email is always mandatory and cannot be changed.)" -msgstr "(註: é›»å­éƒµä»¶æ°¸é æ˜¯æœ‰ç®¡åˆ¶ä¸¦ä¸èƒ½æ”¹è®Šçš„.)" +#: inc/class-wp-members.php:1023 +msgid "CAPTCHA was not valid." +msgstr "驗證碼無效。" -#: admin/tab-fields.php:466 -msgid "Add/Delete" -msgstr "增加/刪除" +#: inc/class-wp-members.php:1022 +msgid "You must complete the CAPTCHA form." +msgstr "你必須完æˆé©—證碼單" -#: admin/tab-fields.php:472 -msgid "Checked?" -msgstr "åˆæ ¼?" +#: inc/class-wp-members.php:1021 +msgid "Emails did not match." +msgstr "é›»å­éƒµä»¶ä¸ç¬¦ã€‚" -#: admin/tab-fields.php:474 -#, fuzzy -msgid "Users Screen" -msgstr "輸出" +#: inc/class-wp-members.php:1020 +msgid "Passwords did not match." +msgstr "" -#: admin/tab-fields.php:486 -msgid "Delete" -msgstr "刪除" +#: inc/class-wp-members.php:1019 +msgid "Sorry, username is a required field" +msgstr "抱歉,帳號為必填欄ä½" -#: admin/tab-fields.php:498 -msgid "(Email cannot be removed)" -msgstr "(電å­éƒµä»¶ä¸èƒ½è¢«åˆªé™¤ï¼‰" +#: inc/class-wp-members.php:1018 +msgid "The username cannot include non-alphanumeric characters." +msgstr "用戶åä¸å¯åŒ…å«éžå­—æ¯å½¢å¼çš„å­—å…ƒ." -#: admin/tab-fields.php:518 -#, fuzzy -msgid "Registration Date" -msgstr "完æˆè¨»å†Š" +#: inc/class-wp-members.php:1017 +msgid "You must enter a valid email address." +msgstr "你必須輸入一個有效的電å­éƒµä»¶" -#: admin/tab-fields.php:521 -#, fuzzy -msgid "native" +#: inc/class-wp-members.php:1024 inc/register.php:53 +msgid "There was an error processing the form." msgstr "" -"判定哪些å€å¡Šæœƒé¡¯ç¤ºåŠå“ªäº›å€å¡Šæ˜¯å¿…è¦çš„. 這裡包括所有å€å¡Š, 原始WPå€å¡Šå’ŒWP-" -"Members客製å€å¡Š" -#: admin/tab-fields.php:531 -#, fuzzy -msgid "Active" -msgstr " 開通 " +#: inc/class-wp-members.php:996 +msgid "Input the code:" +msgstr "" -#: admin/tab-fields.php:543 -#, fuzzy -msgid "Registration IP" -msgstr "註冊ä½å€" +#: inc/class-wp-members.php:994 +msgid "New User Registration" +msgstr "新用戶註冊" -#: admin/tab-fields.php:578 -msgid "Update Fields" -msgstr "æ›´æ–°å€å¡Š" +#: inc/class-wp-members.php:997 +msgid "Please indicate that you agree to the %s TOS %s" +msgstr "è«‹é»žæ“Šæ–¹æ¡†è¡¨ç¤ºæ‚¨åŒæ„æœå‹™æ¢æ¬¾ %s TOS %s" -#: admin/tab-options.php:69 -msgid "Manage Options" -msgstr "é¸é …管ç†" +#: inc/class-wp-members.php:995 +msgid "Choose a Username" +msgstr "é¸å–用戶å稱é¸å–用戶å稱" -#: admin/tab-options.php:86 -msgid "Do not block" -msgstr "" +#: inc/class-wp-members.php:1006 +msgid "Update Profile" +msgstr "更新帳戶資料" -#: admin/tab-options.php:88 -msgid "Hide" +#: inc/class-wp-members.php:998 +msgid "Reset Form" msgstr "" -#: admin/tab-options.php:99 -msgid "Show Excerpts" -msgstr "" +#: inc/class-wp-members.php:1001 +msgid "Required field" +msgstr "å¿…å¡«å€å¡Š" -#: admin/tab-options.php:100 -msgid "Show Login Form" -msgstr "" +#: inc/class-wp-members.php:972 +msgid "Click here to register" +msgstr "點擊此處註冊" -#: admin/tab-options.php:101 -msgid "Show Registration Form" -msgstr "" +#: inc/class-wp-members.php:971 +msgid "New User?" +msgstr "新用戶?" -#: admin/tab-options.php:102 -#, fuzzy -msgid "Auto Excerpt:" -msgstr "顯示引用" +#: inc/class-wp-members.php:970 +msgid "Click here to reset" +msgstr "點擊此處é‡è¨­" -#: admin/tab-options.php:122 -#, fuzzy -msgid "Number of words in excerpt:" -msgstr "顯示引用" +#: inc/class-wp-members.php:969 +msgid "Forgot password?" +msgstr "忘記密碼?" -#: admin/tab-options.php:136 -msgid "Time-based expiration" -msgstr " 計時有效期" +#: inc/class-wp-members.php:968 +msgid "Remember Me" +msgstr "è¨˜ä½æˆ‘" -#: admin/tab-options.php:136 -msgid "Allows for access to expire" -msgstr "考慮(å…許)å­˜å–以終止" +#: inc/class-wp-members.php:984 +msgid "Reset Password" +msgstr "é‡è¨­å¯†ç¢¼" -#: admin/tab-options.php:137 -msgid "Trial period" -msgstr "試用期" +#: inc/class-wp-members.php:981 +msgid "Reset Forgotten Password" +msgstr "é‡è¨­éºå¿˜å¯†ç¢¼" -#: admin/tab-options.php:137 -msgid "Allows for a trial period" -msgstr "考慮(å…許)試用" +#: inc/class-wp-members.php:952 inc/class-wp-members.php:983 +msgid "Email" +msgstr "電郵地å€" -#: admin/tab-options.php:153 -msgid "Notify admin" -msgstr "通知管ç†å“¡" +#: inc/class-wp-members.php:978 +msgid "Update Password" +msgstr "更新密碼" -#: admin/tab-options.php:153 -#, fuzzy, php-format -msgid "Notify %s for each new registration? %s" -msgstr "æ¯ä»¶æ–°è¨»å†Šéƒ½ç™¼é›»éƒµçµ¦ç®¡ç†å“¡" +#: inc/class-wp-members.php:977 +msgid "Confirm new password" +msgstr "ç¢ºèªæ–°å¯†ç¢¼" -#: admin/tab-options.php:154 -msgid "Moderate registration" -msgstr "註冊核å¯" +#: inc/class-wp-members.php:976 +msgid "New password" +msgstr "新密碼" -#: admin/tab-options.php:154 -msgid "Holds new registrations for admin approval" -msgstr "ä¿ç•™æ–°è¨»å†Šä»¥å¾…管ç†å“¡æ ¸å‡†" +#: inc/class-wp-members.php:967 inc/shortcodes.php:645 +msgid "Log In" +msgstr "登入" -#: admin/tab-options.php:155 -msgid "Ignore warning messages" -msgstr "ç•¥éŽè­¦ç¤ºè¨Šæ¯" +#: inc/class-wp-members.php:964 +msgid "Existing Users Log In" +msgstr "ç¾æœ‰ç”¨æˆ¶ç™»å…¥" -#: admin/tab-options.php:155 -msgid "Ignores WP-Members warning messages in the admin panel" -msgstr "ç•¥éŽç®¡ç†å°çš„WP-Members警示訊æ¯" +#: inc/class-wp-members.php:956 inc/class-wp-members.php:966 +#: inc/class-wp-members.php:1043 +msgid "Password" +msgstr "密碼" -#: admin/tab-options.php:167 -msgid "Attribution" -msgstr "" +#: inc/class-wp-members.php:965 inc/class-wp-members.php:982 +#: inc/class-wp-members.php:1005 inc/class-wp-members.php:1042 +msgid "Username" +msgstr "用戶å" -#: admin/tab-options.php:169 -msgid "" -"Attribution is appreciated! Display \"powered by\" link on register form?" -msgstr "" +#: inc/class-wp-members.php:1004 inc/deprecated.php:285 +msgid "Edit Your Information" +msgstr "編輯你的資訊" -#: admin/tab-options.php:172 -#, fuzzy -msgid "Enable CAPTCHA" -msgstr "開啟註冊使用驗證碼功能" +#: inc/class-wp-members.php:1013 +msgid "Password fields cannot be empty" +msgstr "密碼å€å¡Šä¸å¯ç©ºç™½" -#: admin/tab-options.php:174 admin/user-profile.php:97 inc/forms.php:806 -#: inc/users.php:70 -msgid "None" +#: inc/class-wp-members.php:1035 +msgid "click to log out" msgstr "" -#: admin/tab-options.php:180 -msgid "Pages" +#: inc/class-wp-members.php:1033 +msgid "Click to log out" msgstr "" -#: admin/tab-options.php:184 -msgid "Login Page:" -msgstr "" +#: inc/class-wp-members.php:1031 +msgid "Begin using the site." +msgstr "開始使用本網站" -#: admin/tab-options.php:187 -msgid "Specify a login page (optional)" +#: inc/class-wp-members.php:1030 +msgid "Click to log out." msgstr "" -#: admin/tab-options.php:196 -#, fuzzy -msgid "Register Page:" -msgstr "註冊é ç¶²å€ï¼š" +#: inc/class-wp-members.php:1029 inc/class-wp-members.php:1032 +#: inc/class-wp-members.php:1034 inc/class-wp-members.php:1038 +msgid "You are logged in as %s" +msgstr "你已以%så義登入" -#: admin/tab-options.php:199 -msgid "For creating a register link in the login form" -msgstr "" +#: inc/class-wp-members.php:975 inc/class-wp-members.php:1028 +msgid "Change Password" +msgstr "變更密碼" -#: admin/tab-options.php:208 -#, fuzzy -msgid "User Profile Page:" -msgstr "用戶更新" +#: inc/class-wp-members.php:1027 +msgid "Edit My Information" +msgstr "編輯我的資訊 " -#: admin/tab-options.php:211 -msgid "For creating a forgot password link in the login form" -msgstr "" +#: inc/class-wp-members.php:1012 +msgid "Click here to continue." +msgstr "點擊此處繼續" -#: admin/tab-options.php:217 admin/tab-options.php:219 -msgid "Stylesheet" -msgstr "" +#: inc/class-wp-members.php:1011 +msgid "You entered an invalid username or password." +msgstr "ä½ è¼¸å…¥äº†ä¸€å€‹ç„¡æ•ˆçš„ç”¨æˆ¶åæˆ–密碼" -#: admin/tab-options.php:228 -#, fuzzy -msgid "Custom Stylesheet:" -msgstr "客製" +#: inc/class-wp-members.php:1010 +msgid "Login Failed!" +msgstr "登入失敗" -#: admin/tab-options.php:234 admin/tab-options.php:260 -msgid "Update Settings" -msgstr "更新設定" +#: inc/class-wp-members.php:999 inc/class-wp-members.php:1046 inc/core.php:282 +#: inc/shortcodes.php:642 +msgid "Register" +msgstr "註冊" -#: admin/tab-options.php:241 -msgid "Custom Post Types" -msgstr "" +#: inc/class-wp-members.php:1016 +msgid "Sorry, %s is a required field." +msgstr "抱歉, %s 是必須的" -#: admin/tab-options.php:342 -msgid "Custom Post Type settings were updated" -msgstr "" +#: inc/core.php:85 +msgid "ERROR: User has not been activated." +msgstr "錯誤,用戶å尚未開通" -#: admin/tab-options.php:460 -msgid "WP-Members settings were updated" -msgstr "WP-members 已更新設定" +#: inc/class-wp-members.php:712 inc/deprecated.php:239 inc/shortcodes.php:97 +#: inc/shortcodes.php:325 +msgid "There was an error with the CAPTCHA form." +msgstr "驗證碼表單有錯誤" -#: admin/tab-options.php:530 admin/tab-options.php:559 -msgid "USE CUSTOM URL BELOW" +#: inc/class-wp-members-widget.php:50 +msgid "Redirect to (optional):" msgstr "" -#: admin/tab-options.php:548 -#, fuzzy -msgid "Select a page" -msgstr "新註冊" - -#: admin/user-export.php:72 -msgid "Activated?" -msgstr "開通?" - -#: admin/user-export.php:73 -msgid "Subscription" -msgstr "訂閱" - -#: admin/user-export.php:73 -msgid "Expires" -msgstr "éŽæœŸ" - -#: admin/user-export.php:75 -msgid "Registered" -msgstr "註冊éŽçš„" - -#: admin/user-export.php:76 -msgid "IP" -msgstr " ä½å€" - -#: admin/user-export.php:108 admin/users.php:336 -msgid "No" -msgstr " ä¸å¯" - -#: admin/user-profile.php:52 -msgid "WP-Members Additional Fields" -msgstr "WP-members附加å€å¡Š" - -#: admin/user-profile.php:115 inc/users.php:90 inc/wp-registration.php:37 -#: inc/wp-registration.php:154 -msgid "(required)" -msgstr "å¿…è¦?" - -#: admin/user-profile.php:283 -msgid "Activate this user?" -msgstr "開通此用戶?" - -#: admin/user-profile.php:288 -msgid "Reactivate this user?" -msgstr "釿–°é–‹é€šæ­¤ç”¨æˆ¶?" +#: inc/class-wp-members-widget.php:46 +msgid "Title:" +msgstr "標題" -#: admin/user-profile.php:293 -msgid "Deactivate this user?" -msgstr "開除此用戶?" +#: inc/class-wp-members-widget.php:39 inc/class-wp-members-widget.php:82 +msgid "Login Status" +msgstr "會員登入" -#: admin/user-profile.php:339 -msgid "IP @ registration" -msgstr "註冊ä½å€" +#: inc/class-wp-members-widget.php:24 +msgid "Displays the WP-Members sidebar login." +msgstr "" -#: admin/users.php:59 admin/users.php:63 -msgid "Activate" +#: admin/users.php:55 admin/users.php:103 +msgid "Export All Users" msgstr "" -#: admin/users.php:61 admin/users.php:65 +#: admin/users.php:50 admin/users.php:54 msgid "Export" msgstr "輸出" -#: admin/users.php:66 admin/users.php:107 -#, fuzzy -msgid "Export All Users" -msgstr "輸出" - -#: inc/class-wp-members-widget.php:18 -msgid "Displays the WP-Members sidebar login." +#: admin/users.php:48 admin/users.php:52 admin/users.php:79 +msgid "Activate" msgstr "" -#: inc/class-wp-members-widget.php:33 inc/class-wp-members-widget.php:76 -msgid "Login Status" -msgstr "會員登入" - -#: inc/class-wp-members-widget.php:40 -msgid "Title:" -msgstr "標題" - -#: inc/class-wp-members-widget.php:44 -msgid "Redirect to (optional):" -msgstr "" +#: admin/user-profile.php:101 +msgid "IP @ registration" +msgstr "註冊ä½å€" -#: inc/class-wp-members.php:388 inc/shortcodes.php:117 inc/shortcodes.php:386 -msgid "There was an error with the CAPTCHA form." -msgstr "驗證碼表單有錯誤" +#: admin/user-profile.php:53 +msgid "Deactivate this user?" +msgstr "開除此用戶?" -#: inc/class-wp-members.php:546 -msgid "First Name" -msgstr "å" +#: admin/user-profile.php:48 +msgid "Reactivate this user?" +msgstr "釿–°é–‹é€šæ­¤ç”¨æˆ¶?" -#: inc/class-wp-members.php:547 -msgid "Last Name" -msgstr "å§“" +#: admin/user-profile.php:43 inc/wp-registration.php:278 +msgid "Activate this user?" +msgstr "開通此用戶?" -#: inc/class-wp-members.php:548 -msgid "Address 1" -msgstr "åœ°å€ 1" +#: admin/tab-fields.php:176 admin/tab-fields.php:293 +#: inc/class-wp-members-user-profile.php:124 inc/deprecated.php:441 +#: inc/deprecated.php:696 inc/users.php:94 inc/wp-registration.php:54 +#: inc/wp-registration.php:213 +msgid "(required)" +msgstr "å¿…è¦?" -#: inc/class-wp-members.php:549 -msgid "Address 2" -msgstr "åœ°å€ 2" +#: inc/class-wp-members-user-profile.php:37 inc/deprecated.php:371 +msgid "WP-Members Additional Fields" +msgstr "WP-members附加å€å¡Š" -#: inc/class-wp-members.php:550 -msgid "City" -msgstr " 城市" +#: admin/user-export.php:115 admin/users.php:404 +msgid "No" +msgstr "" -#: inc/class-wp-members.php:551 -msgid "State" -msgstr "å·ž" +#: admin/user-export.php:81 +msgid "IP" +msgstr " ä½å€" -#: inc/class-wp-members.php:552 -msgid "Zip" -msgstr "郵éžå€è™Ÿ" +#: admin/user-export.php:80 +msgid "Registered" +msgstr "註冊éŽçš„" -#: inc/class-wp-members.php:553 -msgid "Country" -msgstr "國家" +#: admin/tab-fields.php:430 admin/user-export.php:78 +msgid "Expires" +msgstr "éŽæœŸ" -#: inc/class-wp-members.php:554 -msgid "Day Phone" -msgstr "日間電話" +#: admin/user-export.php:78 +msgid "Subscription" +msgstr "訂閱" -#: inc/class-wp-members.php:555 inc/class-wp-members.php:588 -msgid "Email" -msgstr "é›»å­éƒµä»¶" +#: admin/user-export.php:77 +msgid "Activated?" +msgstr "開通?" -#: inc/class-wp-members.php:556 -msgid "Confirm Email" +#: admin/tab-options.php:564 +msgid "Select a page" msgstr "" -#: inc/class-wp-members.php:557 -msgid "Website" -msgstr "網站" - -#: inc/class-wp-members.php:558 -msgid "Biographical Info" -msgstr "關於我" - -#: inc/class-wp-members.php:559 inc/class-wp-members.php:569 -#: inc/class-wp-members.php:645 -msgid "Password" -msgstr "密碼" - -#: inc/class-wp-members.php:560 -msgid "Confirm Password" +#: admin/tab-options.php:545 admin/tab-options.php:575 +msgid "USE CUSTOM URL BELOW" msgstr "" -#: inc/class-wp-members.php:561 -msgid "TOS" -msgstr "æœå‹™æ¢æ¬¾ " - -#: inc/class-wp-members.php:567 -#, fuzzy -msgid "Existing Users Log In" -msgstr "登入" +#: admin/tab-options.php:475 +msgid "WP-Members settings were updated" +msgstr "WP-members 已更新設定" -#: inc/class-wp-members.php:568 inc/class-wp-members.php:587 -#: inc/class-wp-members.php:608 inc/class-wp-members.php:644 -msgid "Username" -msgstr "用戶å" +#: admin/tab-options.php:248 admin/tab-options.php:274 +msgid "Update Settings" +msgstr "更新設定" -#: inc/class-wp-members.php:570 -msgid "Log In" +#: admin/tab-options.php:242 +msgid "Custom Stylesheet:" msgstr "" -#: inc/class-wp-members.php:571 -msgid "Remember Me" +#: admin/tab-options.php:231 admin/tab-options.php:233 +msgid "Stylesheet" msgstr "" -#: inc/class-wp-members.php:572 -msgid "Forgot password?" -msgstr "忘記密碼?" - -#: inc/class-wp-members.php:573 -msgid "Click here to reset" -msgstr "點擊此處é‡è¨­" +#: admin/tab-options.php:225 +msgid "For creating a forgot password link in the login form" +msgstr "" -#: inc/class-wp-members.php:574 -msgid "New User?" -msgstr "新用戶?" +#: admin/tab-options.php:222 +msgid "User Profile Page:" +msgstr "" -#: inc/class-wp-members.php:575 -msgid "Click here to register" -msgstr "點擊此處註冊Cheatin’uh?" +#: admin/tab-options.php:213 +msgid "For creating a register link in the login form" +msgstr "" -#: inc/class-wp-members.php:576 -msgid "Forgot username?" +#: admin/tab-options.php:210 +msgid "Register Page:" msgstr "" -#: inc/class-wp-members.php:577 -msgid "Click here" +#: admin/tab-options.php:201 +msgid "Specify a login page (optional)" msgstr "" -#: inc/class-wp-members.php:580 inc/class-wp-members.php:630 -msgid "Change Password" -msgstr "變更密碼" +#: admin/tab-options.php:198 +msgid "Login Page:" +msgstr "" -#: inc/class-wp-members.php:581 -msgid "New password" +#: admin/tab-options.php:194 +msgid "Pages" msgstr "" -#: inc/class-wp-members.php:582 -msgid "Confirm new password" +#: admin/tab-options.php:186 inc/class-wp-members-forms.php:893 +#: inc/class-wp-members-user-profile.php:92 inc/deprecated.php:416 +#: inc/deprecated.php:672 inc/users.php:70 +msgid "None" msgstr "" -#: inc/class-wp-members.php:583 -msgid "Update Password" -msgstr "更新密碼" +#: admin/tab-options.php:185 +msgid "Enable CAPTCHA" +msgstr "" -#: inc/class-wp-members.php:586 -msgid "Reset Forgotten Password" -msgstr "é‡è¨­éºå¿˜å¯†ç¢¼" +#: admin/tab-options.php:133 +msgid "Number of words in excerpt:" +msgstr "" -#: inc/class-wp-members.php:589 -msgid "Reset Password" +#: admin/tab-options.php:111 +msgid "Auto Excerpt:" msgstr "" -#: inc/class-wp-members.php:592 inc/class-wp-members.php:594 -msgid "Retrieve username" +#: admin/tab-options.php:182 +msgid "Attribution is appreciated! Display \"powered by\" link on register form?" msgstr "" -#: inc/class-wp-members.php:593 -msgid "Email Address" +#: admin/tab-options.php:180 +msgid "Attribution" msgstr "" -#: inc/class-wp-members.php:597 -#, fuzzy -msgid "New User Registration" -msgstr "新用戶?" +#: admin/tab-options.php:169 +msgid "Ignores WP-Members warning messages in the admin panel" +msgstr "ç•¥éŽç®¡ç†å°çš„WP-Members警示訊æ¯" -#: inc/class-wp-members.php:598 -msgid "Choose a Username" -msgstr "é¸å–用戶å稱é¸å–用戶å稱" +#: admin/tab-options.php:169 +msgid "Ignore warning messages" +msgstr "ç•¥éŽè­¦ç¤ºè¨Šæ¯" -#: inc/class-wp-members.php:599 -msgid "Input the code:" -msgstr "" +#: admin/tab-options.php:168 +msgid "Holds new registrations for admin approval" +msgstr "ä¿ç•™æ–°è¨»å†Šä»¥å¾…管ç†å“¡æ ¸å‡†" -#: inc/class-wp-members.php:600 -#, fuzzy, php-format -msgid "Please indicate that you agree to the %s TOS %s" -msgstr "è«‹å³è¡¨ç¤ºæ‚¨åŒæ„ï¼…s TOSï¼…s的內容" +#: admin/tab-options.php:168 +msgid "Moderate registration" +msgstr "註冊核å¯" -#: inc/class-wp-members.php:601 -#, fuzzy -msgid "Reset Form" -msgstr "驗證碼表單有錯誤" +#: admin/tab-options.php:167 +msgid "Notify %s for each new registration? %s" +msgstr "" -#: inc/class-wp-members.php:602 inc/class-wp-members.php:648 inc/core.php:522 -msgid "Register" -msgstr "註冊" +#: admin/tab-options.php:167 +msgid "Notify admin" +msgstr "通知管ç†å“¡" -#: inc/class-wp-members.php:604 -msgid "Required field" -msgstr "å¿…å¡«å€å¡Š" +#: admin/tab-options.php:149 +msgid "Allows for a trial period" +msgstr "考慮(å…許)試用" -#: inc/class-wp-members.php:607 inc/shortcodes.php:432 -msgid "Edit Your Information" -msgstr "編輯你的資訊" +#: admin/tab-options.php:149 +msgid "Trial period" +msgstr "試用期" -#: inc/class-wp-members.php:609 -#, fuzzy -msgid "Update Profile" -msgstr "用戶更新" +#: admin/tab-options.php:148 +msgid "Allows for access to expire" +msgstr "考慮(å…許)å­˜å–以終止" -#: inc/class-wp-members.php:610 -msgid "Update this file" +#: admin/tab-options.php:148 +msgid "Time-based expiration" +msgstr " 計時有效期" + +#: admin/tab-options.php:110 +msgid "Show Registration Form" msgstr "" -#: inc/class-wp-members.php:613 -msgid "Login Failed!" -msgstr "登入失敗" +#: admin/tab-options.php:109 +msgid "Show Login Form" +msgstr "" -#: inc/class-wp-members.php:614 -msgid "You entered an invalid username or password." -msgstr "ä½ è¼¸å…¥äº†ä¸€å€‹ç„¡æ•ˆçš„ç”¨æˆ¶åæˆ–密碼" +#: admin/tab-options.php:108 +msgid "Show Excerpts" +msgstr "" -#: inc/class-wp-members.php:615 -msgid "Click here to continue." -msgstr "點擊此處繼續" +#: admin/tab-options.php:94 +msgid "Do not block" +msgstr "" -#: inc/class-wp-members.php:616 -msgid "Password fields cannot be empty" -msgstr "密碼å€å¡Šä¸å¯ç©ºç™½" +#: admin/tab-options.php:75 +msgid "Manage Options" +msgstr "é¸é …管ç†" -#: inc/class-wp-members.php:617 -msgid "Sorry, that email address was not found." +#: admin/tab-fields.php:428 +msgid "Registration IP" msgstr "" -#: inc/class-wp-members.php:618 -#, php-format -msgid "An email was sent to %s with your username." +#: admin/tab-fields.php:427 +msgid "Active" msgstr "" -#: inc/class-wp-members.php:619 -#, php-format -msgid "Sorry, %s is a required field." -msgstr "抱歉, %s 是必須的" +#: admin/tab-fields.php:426 +msgid "Registration Date" +msgstr "" -#: inc/class-wp-members.php:620 -msgid "You must enter a valid email address." -msgstr "你必須輸入一個有效的電å­éƒµä»¶" +#: admin/tab-fields.php:503 +msgid "delete" +msgstr "" -#: inc/class-wp-members.php:621 -msgid "The username cannot include non-alphanumeric characters." -msgstr "用戶åä¸å¯åŒ…å«éžå­—æ¯å½¢å¼çš„å­—å…ƒ." +#: admin/tab-fields.php:524 +msgid "Users Screen" +msgstr "" -#: inc/class-wp-members.php:622 -msgid "Sorry, username is a required field" -msgstr "抱歉, ç”¨æˆ¶åæ˜¯å¿…須的" +#: admin/tab-fields.php:464 +msgid "Manage Fields" +msgstr "å€å¡Šç®¡ç†" -#: inc/class-wp-members.php:623 -#, fuzzy -msgid "Passwords did not match." -msgstr "密碼ä¸ç¬¦" +#: admin/tab-fields.php:378 admin/tab-fields.php:645 admin/tab-fields.php:646 +msgid "Add Field" +msgstr "" -#: inc/class-wp-members.php:624 -#, fuzzy -msgid "Emails did not match." -msgstr "密碼ä¸ç¬¦" +#: admin/tab-fields.php:352 +msgid "Visit plugin site for more information" +msgstr "更多資訊請查閱æ’件網站" -#: inc/class-wp-members.php:625 -msgid "You must complete the CAPTCHA form." -msgstr "你必須完æˆé©—證碼單" +#: admin/tab-fields.php:348 +msgid "Options should be Option Name|option_value," +msgstr "é¸é …須為é¸é …值" -#: inc/class-wp-members.php:626 -msgid "CAPTCHA was not valid." +#: admin/tab-fields.php:293 +msgid "Stored value if checked:" msgstr "" -#: inc/class-wp-members.php:629 -msgid "Edit My Information" -msgstr "編輯我的資訊 " - -#: inc/class-wp-members.php:631 inc/class-wp-members.php:634 -#: inc/class-wp-members.php:636 inc/class-wp-members.php:640 -#, php-format -msgid "You are logged in as %s" -msgstr "你已以%så義登入" - -#: inc/class-wp-members.php:632 -#, fuzzy -msgid "Click to log out." -msgstr "登入" +#: admin/tab-fields.php:289 +msgid "Checked by default?" +msgstr "" -#: inc/class-wp-members.php:633 -msgid "Begin using the site." -msgstr "開始使用本網站" +#: admin/tab-fields.php:282 +msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" +msgstr "" -#: inc/class-wp-members.php:635 -#, fuzzy -msgid "Click to log out" -msgstr "登入" +#: admin/tab-fields.php:277 +msgid "Accepted file types:" +msgstr "" -#: inc/class-wp-members.php:637 -#, fuzzy -msgid "click to log out" -msgstr "登入" +#: admin/tab-fields.php:230 admin/tab-fields.php:521 +msgid "Required?" +msgstr "å¿…è¦?" -#: inc/class-wp-members.php:641 -msgid "click here to log out" -msgstr "點擊此處登出" +#: admin/tab-fields.php:226 admin/tab-fields.php:520 +msgid "Display?" +msgstr "顯示?" -#: inc/class-wp-members.php:642 -msgid "Login Failed!
    You entered an invalid username or password." -msgstr "登入失敗! ä½ è¼¸å…¥äº†ä¸€å€‹ç„¡æ•ˆçš„ç”¨æˆ¶åæˆ–密碼." +#: admin/tab-fields.php:217 +msgid "file" +msgstr "" -#: inc/class-wp-members.php:643 -#, fuzzy -msgid "You are not logged in." -msgstr "你已以%så義登入" +#: admin/tab-fields.php:215 +msgid "password" +msgstr "密碼" -#: inc/class-wp-members.php:646 -#, fuzzy -msgid "log in" -msgstr "登入" +#: admin/tab-fields.php:210 +msgid "checkbox" +msgstr "æ ¸é¸æ¡†" -#: inc/class-wp-members.php:647 -msgid "Forgot?" -msgstr "忘記?" +#: admin/tab-fields.php:209 +msgid "textarea" +msgstr "æ–‡å­—å€ " -#: inc/class-wp-members.php:651 -#, fuzzy -msgid "" -"This content is restricted to site members. If you are an existing user, " -"please log in. New users may register below." -msgstr "本內容åªå°æœƒå“¡é–‹æ”¾.å¦‚æžœæ‚¨æ˜¯ç¾æœ‰æœƒå“¡è«‹ç™»å…¥. 新用戶請於下方註冊" +#: admin/tab-fields.php:207 +msgid "text" +msgstr "文字" -#: inc/class-wp-members.php:652 -msgid "Sorry, that username is taken, please try another." -msgstr "抱歉,此用戶å已被採用, è«‹æ›ä¸€å€‹å†è©¦." +#: admin/tab-fields.php:201 admin/tab-fields.php:519 +msgid "Field Type" +msgstr "欄ä½é¡žåž‹" -#: inc/class-wp-members.php:653 -msgid "" -"Sorry, that email address already has an account.
    Please try another." -msgstr "抱歉, 此電å­éƒµä»¶å·²ç¶“有所屬帳戶. è«‹æ›ä¸€å€‹å†è©¦." +#: admin/tab-fields.php:197 +msgid "The database meta value for the field. It must be unique and contain no spaces (underscores are ok)." +msgstr "" -#: inc/class-wp-members.php:654 -#, fuzzy -msgid "" -"Congratulations! Your registration was successful.

    You may now " -"log in using the password that was emailed to you." -msgstr "æ­å–œ! 您已註冊æˆåŠŸ. 您ç¾åœ¨å¯ç”¨æˆ‘們電å­éƒµä»¶ç™¼çµ¦æ‚¨çš„密碼登入" +#: admin/tab-fields.php:188 +msgid "The name of the field as it will be displayed to the user." +msgstr "" -#: inc/class-wp-members.php:655 -msgid "Your information was updated!" -msgstr "你的資料已更新!" +#: admin/tab-fields.php:186 +msgid "Field Label" +msgstr "å€å¡Šæ¨™ç±¤" -#: inc/class-wp-members.php:656 -msgid "Passwords did not match.

    Please try again." -msgstr "密碼ä¸ç¬¦. è«‹å†è©¦ä¸€æ¬¡.." +#: admin/tab-fields.php:181 +msgid "Add a Field" +msgstr "" -#: inc/class-wp-members.php:657 -msgid "Password successfully changed!" +#: admin/tab-fields.php:181 admin/tab-fields.php:378 +msgid "Edit Field" msgstr "" -#: inc/class-wp-members.php:658 -msgid "Either the username or email address do not exist in our records." -msgstr "æ­¤ç”¨æˆ¶åæˆ–é›»å­éƒµä»¶ä¸å­˜åœ¨ä½ çš„æª”案中." +#: admin/post.php:220 admin/tab-fields.php:88 admin/tab-fields.php:523 +msgid "Edit" +msgstr "" -#: inc/class-wp-members.php:659 -msgid "" -"Password successfully reset!

    An email containing a new password " -"has been sent to the email address on file for your account." +#: admin/tab-fields.php:779 +msgid "Checked value is required for checkboxes. Nothing was updated." msgstr "" -#: inc/core.php:106 -msgid "ERROR: User has not been activated." -msgstr "錯誤,用戶å尚未開通" +#: admin/tab-fields.php:746 +msgid "Sorry, \"%s\" is a reserved term. Field was not added." +msgstr "" -#: inc/register.php:45 -#, fuzzy -msgid "There was an error processing the form." -msgstr "驗證碼表單有錯誤" +#: admin/tab-fields.php:741 +msgid "A field with that meta key already exists" +msgstr "" -#: inc/register.php:557 -msgid "We were unable to validate the public key." -msgstr "你沒有驗證公開éµ" +#: admin/tab-fields.php:734 +msgid "Meta Key must contain only letters, numbers, and underscores" +msgstr "" -#: inc/register.php:561 -msgid "We were unable to validate the private key." -msgstr "你沒有驗證隱密éµ" +#: admin/tab-fields.php:709 +msgid "WP-Members fields were updated" +msgstr "WP_Memberså€å¡Šå·²æ›´æ–°" -#: inc/register.php:565 -msgid "The challenge parameter of the verify script was incorrect." -msgstr "é©—è­‰è…³æœ¬ä¸­çš„ç ´è§£åƒæ•¸ä¸æ­£ç¢º" +#: admin/tab-emails.php:146 +msgid "WP-Members emails were updated" +msgstr "WP_Membersé›»å­éƒµä»¶å·²æ›´æ–°" -#: inc/register.php:569 -msgid "The CAPTCHA solution was incorrect." -msgstr "é©—è­‰ç¢¼è§£ç­”ä¸æ­£ç¢º" +#: admin/tab-emails.php:76 +msgid "Update Emails" +msgstr "æ›´æ–°é›»å­éƒµä»¶" -#: inc/register.php:573 -msgid "The parameters to verify were incorrect" -msgstr "ç”¨ä»¥é©—è­‰ä¹‹åƒæ•¸ä¸æ­£ç¢º" +#: admin/includes/class-wp-members-admin-api.php:272 +msgid "Body" +msgstr "主體" -#: inc/register.php:577 -msgid "" -"reCAPTCHA API keys are tied to a specific domain name for security reasons." -msgstr "驗證碼功能的APIéµå› å®‰å…¨ç¶­è­·èˆ‡ç‰¹å®šç¶²åŸŸå有所連çµ" +#: admin/includes/class-wp-members-admin-api.php:269 +#: admin/includes/class-wp-members-admin-api.php:271 +msgid "Subject" +msgstr "主題" -#: inc/register.php:581 -msgid "The reCAPTCHA server was not reached. Please try to resubmit." -msgstr "驗證碼功能伺æœå™¨ç„¡æ³•連線. è«‹å˜—è©¦é‡æ–°æäº¤." +#: admin/tab-emails.php:57 +msgid "Set a custom email name" +msgstr "設置自定義的電å­éƒµä»¶å稱" -#: inc/register.php:585 -msgid "You have entered an incorrect code value. Please try again." -msgstr "" +#: admin/tab-emails.php:54 admin/tab-emails.php:58 admin/tab-emails.php:68 +#: admin/tab-fields.php:175 +msgid "(optional)" +msgstr "(é¸é …)" -#: inc/shortcodes.php:346 -msgid "Click here to log out." -msgstr "" +#: admin/tab-emails.php:53 +msgid "Set a custom email address" +msgstr "設置自定義的電å­éƒµä»¶åœ°å€" -#: inc/users.php:37 -#, fuzzy -msgid "Additional Information" -msgstr "WP-members附加å€å¡Š" +#: admin/tab-emails.php:46 +msgid "A list of shortcodes is available here." +msgstr "列表的簡碼å¯ä»¥åœ¨é€™è£¡æ‰¾åˆ°" -#: inc/utilities.php:202 -msgid "(more…)" -msgstr "" +#: admin/tab-emails.php:44 +msgid "You can customize the content of the emails sent by the plugin." +msgstr "您å¯ä»¥è‡ªè¨‚æ’件發é€çš„é›»å­éƒµä»¶çš„內容" -#: wp-members-tos.php:23 -msgid "Terms of Service" -msgstr "æœå‹™æ¢æ¬¾" +#: admin/tab-emails.php:41 +msgid "Email Messages" +msgstr "é›»å­éƒµä»¶è¨Šæ¯" -#: wp-members-tos.php:35 -#, php-format -msgid "%sclose%s" -msgstr "%s關閉%s" +#: admin/tab-emails.php:68 +msgid "Email Signature" +msgstr "電郵簽å" -#: wp-members-tos.php:37 -#, fuzzy, php-format -msgid "%sprint%s" -msgstr "%S列å°%s" +#: admin/includes/class-wp-members-admin-api.php:409 +msgid "Admin Notification" +msgstr "管ç†å“¡é€šçŸ¥è¡Œç‚º" -#. Plugin Name of the plugin/theme -msgid "WP-Members" -msgstr "WP-Members" +#: admin/includes/class-wp-members-admin-api.php:394 +msgid "Password Reset" +msgstr "密碼é‡è¨­" -#. Plugin URI of the plugin/theme -msgid "http://rocketgeek.com" -msgstr "" +#: admin/includes/class-wp-members-admin-api.php:386 +msgid "Registration is Moderated, User is Approved" +msgstr "註冊正在核å¯,用戶核准" -#. Description of the plugin/theme -msgid "" -"WP access restriction and user registration. For more information on plugin " -"features, refer to the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." -msgstr "" +#: admin/includes/class-wp-members-admin-api.php:380 +msgid "Registration is Moderated" +msgstr "註冊正在核å¯" -#. Author of the plugin/theme -msgid "Chad Butler" -msgstr "Chad Butler" +#: admin/includes/class-wp-members-admin-api.php:371 +msgid "New Registration" +msgstr "新註冊" -#. Author URI of the plugin/theme -msgid "http://butlerblog.com/" -msgstr "http://butlerblog.com/" +#: admin/tab-dialogs.php:106 +msgid "WP-Members dialogs were updated" +msgstr "WP_Memberså°è©±æ¡†å·²æ›´æ–°" -#, fuzzy -#~ msgid "%s posts %sed." -#~ msgstr "默èªå°éŽ–ç™¼æ–‡" +#: admin/tab-dialogs.php:70 +msgid "Update Dialogs" +msgstr "æ›´æ–°å°è©±æ¡†" -#, fuzzy -#~ msgid "Post Restriction" -#~ msgstr "新註冊" +#: admin/tab-dialogs.php:63 +msgid "Terms of Service (TOS)" +msgstr "æœå‹™æ¢æ¬¾" -#, fuzzy -#~ msgid "Page Restriction" -#~ msgstr "新註冊" +#: admin/tab-dialogs.php:52 +msgid "You can customize the text for dialogs and error messages. Simple HTML is allowed %s etc." +msgstr "" -#~ msgid "Subject" -#~ msgstr "主題" +#: admin/tab-dialogs.php:50 +msgid "Dialogs and Error Messages" +msgstr "å°è©±æ¡†å’ŒéŒ¯èª¤è¨Šæ¯" -#~ msgid "Body" -#~ msgstr "主體" +#: admin/includes/class-wp-members-admin-api.php:443 +msgid "Password reset" +msgstr "密碼é‡è¨­" -#~ msgid "dropdown" -#~ msgstr "下拉" +#: admin/includes/class-wp-members-admin-api.php:442 +msgid "Username or email do not exist when trying to reset forgotten password" +msgstr "ç•¶è¦é‡è¨­å¿˜è¨˜çš„å¯†ç¢¼æ™‚ç”¨æˆ¶åæˆ–é›»å­éƒµä»¶ä¸å­˜åœ¨" -#~ msgid "Block Posts by default" -#~ msgstr "默èªå°éŽ–ç™¼æ–‡" +#: admin/includes/class-wp-members-admin-api.php:441 +msgid "Password changes" +msgstr "更改密碼" -#~ msgid "" -#~ "Note: Posts can still be individually blocked or unblocked at the article " -#~ "level" -#~ msgstr "附註: 在文章層級,é é¢ä»å¯å–®ç¨é¸æ“‡å°éŽ–æˆ–æ‰“é–‹" +#: admin/includes/class-wp-members-admin-api.php:440 +msgid "Passwords did not match" +msgstr "密碼ä¸ç¬¦" -#~ msgid "Block Pages by default" -#~ msgstr "默èªå°éŽ–é é¢" +#: admin/includes/class-wp-members-admin-api.php:439 +msgid "User update" +msgstr "用戶更新" -#~ msgid "" -#~ "Note: Pages can still be individually blocked or unblocked at the article " -#~ "level" -#~ msgstr "附註: 在文章層級,é é¢ä»å¯å–®ç¨é¸æ“‡å°éŽ–æˆ–æ‰“é–‹" +#: admin/includes/class-wp-members-admin-api.php:438 +msgid "Registration completed" +msgstr "完æˆè¨»å†Š" -#~ msgid "Show excerpts" -#~ msgstr "顯示引用" +#: admin/includes/class-wp-members-admin-api.php:437 +msgid "Email is registered" +msgstr "é›»å­éƒµä»¶å·²è¢«è¨»å†Š" -#~ msgid "" -#~ "Shows excerpted content above the login/registration on both Posts and " -#~ "Pages" -#~ msgstr "於發文和é é¢çš„註冊/登入上方顯示引用的內容" +#: admin/includes/class-wp-members-admin-api.php:436 +msgid "Username is taken" +msgstr "帳戶å已被使用" -#~ msgid "Turns on CAPTCHA for registration" -#~ msgstr "開啟註冊使用驗證碼功能" +#: admin/includes/class-wp-members-admin-api.php:435 +msgid "Restricted post (or page), displays above the login/registration form" +msgstr "有é™åˆ¶çš„發文(或é é¢), 顯示於登入/註冊表上方" -#, fuzzy -#~ msgid "Hide registration" -#~ msgstr "完æˆè¨»å†Š" +#: admin/tab-captcha.php:275 +msgid "CAPTCHA was updated for WP-Members" +msgstr "" -#~ msgid "Optional" -#~ msgstr "é¸é …" +#: admin/tab-captcha.php:204 +msgid "Update CAPTCHA Settings" +msgstr "" -#, fuzzy -#~ msgid "Automatically creates an excerpt" -#~ msgstr "顯示引用" +#: admin/tab-captcha.php:180 +msgid "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin installed and activated." +msgstr "" -#~ msgid "AIM" -#~ msgstr "AIM" +#: admin/tab-captcha.php:166 +msgid "Image type" +msgstr "" -#~ msgid "Yahoo IM" -#~ msgstr "Yahoo IM" +#: admin/tab-captcha.php:162 +msgid "Width between characters" +msgstr "" -#~ msgid "Jabber/Google Talk" -#~ msgstr "Jabber/Google Talk" +#: admin/tab-captcha.php:158 +msgid "Font size" +msgstr "" -#~ msgid "" -#~ "Password successfully changed!

    You will need to re-login with " -#~ "your new password." -#~ msgstr "å·²æˆåŠŸè®Šæ›´å¯†ç¢¼! ä½ å¿…é ˆç”¨æ–°å¯†ç¢¼é‡æ–°ç™»å…¥." +#: admin/tab-captcha.php:154 +msgid "Background color of image" +msgstr "" -#~ msgid "" -#~ "Password successfully reset!

    An email containing a new " -#~ "password has been sent to the email address on file for your account. You " -#~ "may change this random password then re-login with your new password." -#~ msgstr "" -#~ "å·²æˆåŠŸé‡è¨­å¯†ç¢¼! 一å°å«æœ‰æ–°å¯†ç¢¼çš„é›»å­éƒµä»¶å·²ç™¼é€è‡³ä½ ç”¨æˆ¶æª”案中紀錄的電郵信" -#~ "ç®±. ä½ å¯ä»¥é‡è¨­æ­¤éš¨æ©Ÿå¯†ç¢¼ä¸¦ä»¥æ–°è¨­çš„å¯†ç¢¼é‡æ–°ç™»å…¥." +#: admin/tab-captcha.php:150 +msgid "Font color of characters" +msgstr "" -#~ msgid "Use reCAPTCHA" -#~ msgstr "使用驗證碼" +#: admin/tab-captcha.php:147 +msgid "Height" +msgstr "" -#~ msgid "Turn off registration" -#~ msgstr "關閉註冊(功能)" +#: admin/tab-captcha.php:147 +msgid "Width" +msgstr "" -#~ msgid "Turns off the registration process, only allows login" -#~ msgstr "關閉註冊處ç†ç¨‹åº, åªå…許登入" +#: admin/tab-captcha.php:146 +msgid "Image dimensions" +msgstr "" -#~ msgid "Legacy forms" -#~ msgstr "內建表單" +#: admin/tab-captcha.php:142 +msgid "Number of characters" +msgstr "" -#~ msgid "Members Area URL:" -#~ msgstr "會員專å€ç¶²å€" +#: admin/tab-captcha.php:138 +msgid "Characters for image" +msgstr "" -#~ msgid "Add" -#~ msgstr "增加" +#: admin/tab-captcha.php:107 +msgid "Secret Key" +msgstr "" -#~ msgid "WP-Members expiration periods were updated" -#~ msgstr "有效期é™å·²æ›´æ–°" +#: admin/tab-captcha.php:106 +msgid "Site Key" +msgstr "" -#~ msgid "" -#~ "Settings were saved, but you have required fields that are not set to " -#~ "display!" -#~ msgstr "" -#~ "La configuración se guardó, pero tiene campos obligatorios marcados como " -#~ "no visibles, no tiene sentido!" +#: admin/tab-captcha.php:105 +msgid "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" key. You can sign up for a %s free reCAPTCHA key%s" +msgstr "" -#~ msgid "" -#~ "Note: This will not cause an error for the end user, as only displayed " -#~ "fields are validated. However, you should still check that your " -#~ "displayed and required fields match up. Mismatched fields are " -#~ "highlighted below." -#~ msgstr "" -#~ "注æ„: 這䏿œƒé€ æˆä½¿ç”¨è€…端的錯誤訊æ¯,å› ç‚ºåªæœ‰é¡¯ç¤ºçš„å€å¡Šæ˜¯æœ‰æ•ˆçš„.然而,ä½ ä»å¿…" -#~ "須檢查你這端必è¦é¡¯ç¤ºçš„å€å¡Šæ˜¯ç›¸ç¬¦çš„." +#: admin/tab-captcha.php:91 +msgid "Clean" +msgstr "乾淨" -#~ msgid "If you find this plugin useful, please consider making a donation" -#~ msgstr "如果你èªç‚ºæ­¤æ’件有用處, è«‹è€ƒæ…®çµ¦èˆ‡ä¸€ä»½ææ¬¾" +#: admin/tab-captcha.php:90 +msgid "Black Glass" +msgstr "黑玻璃" -#~ msgid "Subscriptions" -#~ msgstr "訂閱" +#: admin/tab-captcha.php:89 +msgid "White" +msgstr "白" -#~ msgid "PayPal Settings" -#~ msgstr "PayPal 設定" +#: admin/tab-captcha.php:88 +msgid "Red" +msgstr " ç´…" -#~ msgid "If you find this plugin useful, please consider a %s donation %s" -#~ msgstr "如果你èªç‚ºæ­¤æ’件有用處, è«‹è€ƒæ…®çµ¦èˆ‡ä¸€ä»½ææ¬¾" +#: admin/tab-captcha.php:85 +msgid "Choose Theme" +msgstr "鏿“‡ä¸»é¡Œ" -#~ msgid "Custom" -#~ msgstr "客製" +#: admin/tab-captcha.php:81 +msgid "Private Key" +msgstr "隱密éµ" -#~ msgid "%d users were activated." -#~ msgstr "%d 用戶已開通" +#: admin/tab-captcha.php:80 +msgid "Public Key" +msgstr "公開éµ" -#~ msgid "" -#~ "Users ready to export, %s click here %s to generate and download a CSV." -#~ msgstr "用戶準備輸出, %s點擊這è£ç”¢ç”Ÿä¸¦ä¸‹è¼‰ä¸€å€‹æœ‰æ•ˆé©—è­‰." +#: admin/tab-captcha.php:79 +msgid "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" key. You can sign up for a %s free reCAPTCHA key%s" +msgstr "" -#~ msgid "WP-Members Users" -#~ msgstr "WP-members用戶" +#: admin/tab-captcha.php:77 admin/tab-captcha.php:103 +msgid "reCAPTCHA Keys" +msgstr " 驗証碼æœå‹™éµ" -#~ msgid "Add New" -#~ msgstr "新增" +#: admin/tab-captcha.php:72 +msgid "reCAPTCHA asks commenters to retype two words scanned from a book to prove that they are a human. This verifies that they are not a spambot while also correcting the automatic scans of old books. So you get less spam, and the world gets accurately digitized books. Everybody wins! For details, visit the %s reCAPTCHA website%s" +msgstr "" -#~ msgid "No users matched your criteria" -#~ msgstr "ç„¡ç¬¦åˆæ¨™æº–的用戶 " +#: admin/tab-captcha.php:71 +msgid "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books while blocking spam on your blog." +msgstr "reCAPTCHA 是一個å…費開放的驗證碼系統技術æœå‹™, 它å¯ä»¥å°‡æ–‡å­—內容數字化,å¹«ä½ æ“‹é™¤éƒ¨è½æ ¼ä¸­çš„垃圾留言,訊æ¯. " -#~ msgid "Bulk Actions" -#~ msgstr "大批é‡çš„執行" +#: admin/tab-captcha.php:57 +msgid "Manage reCAPTCHA Options" +msgstr "管ç†é©—證碼系統é¸é …" -#~ msgid "Apply" -#~ msgstr "申請" +#: admin/tab-captcha.php:46 admin/tab-dialogs.php:40 admin/tab-emails.php:84 +#: admin/tab-fields.php:149 admin/tab-options.php:64 +msgid "Need help?" +msgstr "" -#~ msgid "Indicates a required field" -#~ msgstr "指å一個必è¦çš„å€å¡Š" +#: admin/post.php:339 admin/post.php:340 admin/user-export.php:115 +msgid "Yes" +msgstr "" -#~ msgid "Login" -#~ msgstr "登入" +#: admin/post.php:307 +msgid "Blocked?" +msgstr "" -#~ msgid "New Password" -#~ msgstr "新密碼" +#: admin/post.php:307 +msgid "Unblocked?" +msgstr "" -#~ msgid "Repeat Password" -#~ msgstr "é‡è¼¸å¯†ç¢¼" +#: admin/post.php:46 admin/post.php:48 +msgid "Unblock" +msgstr "" -#~ msgid "Clear Form" -#~ msgstr "清除表單" +#: admin/post.php:45 admin/post.php:47 admin/tab-options.php:95 +msgid "Block" +msgstr "" -#~ msgid "Submit" -#~ msgstr "æå‡º" +#: admin/dialogs.php:219 admin/dialogs.php:232 +msgid "Latest from ButlerBlog" +msgstr "" -#~ msgid "Remember me" -#~ msgstr " 記得我" +#: admin/dialogs.php:198 admin/dialogs.php:202 +msgid "Latest from RocketGeek" +msgstr "" -#~ msgid "Cheatin’ uh?" -#~ msgstr "Cheatin’ uh?" +#: admin/dialogs.php:181 +msgid "Follow" +msgstr "追蹤" -#~ msgid "there was an error and no users were exported" -#~ msgstr "錯誤,無用戶輸出" +#: admin/dialogs.php:180 +msgid "A plugin developed by" +msgstr "" -#~ msgid "You are not currently logged in." -#~ msgstr "ä½ ç¾åœ¨ä¸¦æœªç™»å…¥." +#: admin/dialogs.php:179 +msgid "Thank you for using WP-Members" +msgstr "" -#~ msgid "login" -#~ msgstr "登入" +#: admin/dialogs.php:172 +msgid "FAQs" +msgstr "" -#~ msgid "Bio" -#~ msgstr "Semblanza" +#: admin/dialogs.php:171 +msgid "Online User Guide" +msgstr "" -#~ msgid "Your registration info for %s" -#~ msgstr "Su información de registro en %s" +#: admin/dialogs.php:170 +msgid "Quick Start Guide" +msgstr "" -#~ msgid "Thank you for registering for %s" -#~ msgstr "Gracias por registrarse en %s" +#: admin/dialogs.php:169 +msgid "Version:" +msgstr "版本:" -#~ msgid "Your registration information is below." -#~ msgstr "Su información de registro está abajo." +#: admin/dialogs.php:140 +msgid "but you have not entered API keys. You will need both a public and private key. The CAPTCHA will not display unless a valid API key is included." +msgstr "但你尚未輸入應用程å¼ä»‹é¢éµ. 你需è¦ä¸€å€‹å…¬é–‹éµåŠä¸€å€‹éš±å¯†éµ. 除éžå«æœ‰ä¸€å€‹æœ‰æ•ˆçš„APIéµå¦å‰‡é©—è­‰ç¢¼åŠŸèƒ½ä¸æœƒé¡¯ç¤º." -#~ msgid "You may wish to retain a copy for your records." -#~ msgstr "Puede guardar una copia de su información." +#: admin/dialogs.php:139 +msgid "You have turned on reCAPTCHA" +msgstr "你已打開驗證碼æœå‹™åŠŸèƒ½" -#~ msgid "username: %s" -#~ msgstr "usuario: %s" +#: admin/dialogs.php:135 +msgid "but you have not changed the default message for \"Registration Completed\" under \"WP-Members Dialogs and Error Messages.\" You should change this message to let users know they are pending approval." +msgstr "但你尚未變更在\"WP-Memberså°è©±æ¡†åŠéŒ¯èª¤è¨Šæ¯\" 裡默èªçš„\"註冊完æˆ\"訊æ¯. 你應該變更此訊æ¯ä»¥è®“用戶知é“他們的註冊正在核å¯ä¸­" -#~ msgid "password: %s" -#~ msgstr "clave: %s" +#: admin/dialogs.php:134 +msgid "You have set WP-Members to hold registrations for approval" +msgstr "你已將WP-Members設為核准中ä¿ç•™è¨»å†Š" -#~ msgid "You may login here:" -#~ msgstr "Puede identificarse en:" +#: admin/dialogs.php:130 +msgid "Leaving this set to full text allows anyone to read your protected content in an RSS reader. Changing this to Summary prevents this as your feeds will only show summary text." +msgstr "ä¿ç•™é€™è£¡è¨­ç‚ºå…¨æ–‡,å°‡å…許任何人在一RSS閱讀器å¯é–±è®€ä½ ä¿è­·çš„æ–‡ç« å…§å®¹.將此改為概è¦å°±å¯ä»¥é˜²æ­¢,å› ä½ çš„RSS訊æ¯ä¾†æºåªæœƒé¡¯ç¤ºæ¦‚è¦è¨Šæ¯æ–‡å­—." -#~ msgid "You may login at: %s" -#~ msgstr "Puede acceder en: %s" +#: admin/dialogs.php:129 +msgid "You can %s change this here %s by changing \"For each article in a feed, show\" to \"Summary.\"" +msgstr "ä½ å¯ä»¥%s在這裡變更%s 用改變\"æ¯ä¸€è¨Šæ¯ä¾†æºä¸€ç¯‡æ–‡ç« ,顯示\" æˆ \"概è¦.\"" -#~ msgid "You originally registered at:" -#~ msgstr "Originalmente se registro en:" +#: admin/dialogs.php:128 +msgid "Your WP settings allow full text rss feeds - this is not the recommended setting." +msgstr "ä½ çš„WP設定å…許全文字的RSS訊æ¯ä¾†æº" -#~ msgid "Password reset for %s" -#~ msgstr "Reiniciada clave para %s" +#: admin/dialogs.php:124 +msgid "This setting allows any users to comment, whether or not they are registered. Depending on how you are using WP-Members will determine whether you should change this setting or not. If you do not change this setting, you can choose to ignore these warning messages under WP-Members Settings." +msgstr "此設定å…許任何用戶發表æ„見, 無論他們有無註冊.你是如何使用WP-Membersæ±ºå®šä½ æ˜¯å¦æ‡‰æ”¹è®Šæ­¤è¨­å®š.如果你沒有變更此設定,ä½ å¯ä»¥åœ¨WP-Membersçš„è¨­å®šä¸­é¸æ“‡å¿½ç•¥é€™äº›è­¦ç¤ºè¨Šæ¯" -#~ msgid "New user registration for %s" -#~ msgstr "Nuevo registro en %s" +#: admin/dialogs.php:123 +msgid "You can %s change this here %s by checking the box next to \"Users must be registered and logged in to comment.\"" +msgstr "ä½ å¯ä»¥%s在這裡變更%s 確èªåœ¨\"任何人å¯è¨»å†Š\"æ—çš„é¸æ¡†æ˜¯æ²’有鉤é¸çš„" -#~ msgid "The following user registered for %s" -#~ msgstr "El siguiente usuario se registró en %s" +#: admin/dialogs.php:122 +msgid "Your WP settings allow anyone to comment - this is not the recommended setting." +msgstr "ä½ çš„WP設定å…許任何人發表æ„見" -#~ msgid "and is pending admin approval" -#~ msgstr "y está pendiente confirmar su permiso de acceso" +#: admin/dialogs.php:118 +msgid "This setting allows a link on the /wp-login.php page to register using the WP native registration process thus circumventing any registration you are using with WP-Members. In some cases, this may suit the users wants/needs, but most users should uncheck this option. If you do not change this setting, you can choose to ignore these warning messages under WP-Members Settings." +msgstr "此設定å…許一æ¢åœ¨/wp-login.phpé é¢ä¸Šçš„連çµç”¨WP原始的註冊程åºä¾†è¨»å†Š.如此一來,就坿¶µè“‹ä»»ä½•使用WP-Members的註冊. æŸäº›æƒ…æ³ä¸‹,這樣的設定é©åˆç”¨æˆ¶çš„需求,但大部分用戶應ä¸è¦é‰¤é¸æ­¤é¸æ¡†. 如果你沒有變更此設定,ä½ å¯ä»¥åœ¨WP-Membersçš„è¨­å®šä¸­é¸æ“‡å¿½ç•¥é€™äº›è­¦ç¤ºè¨Šæ¯" -#~ msgid "expires" -#~ msgstr "Caduca" +#: admin/dialogs.php:117 +msgid "You can %s change this here %s making sure the box next to \"Anyone can register\" is unchecked." +msgstr "ä½ å¯ä»¥%s在這裡變更%s 確èªåœ¨\"任何人å¯è¨»å†Š\"æ—çš„é¸æ¡†æ˜¯æ²’有鉤é¸çš„" -#~ msgid "Extend user:" -#~ msgstr "Extender Usuario:" +#: admin/dialogs.php:116 +msgid "Your WP settings allow anyone to register - this is not the recommended setting." +msgstr "ä½ çš„WP設定å…許任何人註冊-ä¸å»ºè­°æ­¤è¨­å®š" -#~ msgid "Settings saved." -#~ msgstr "Configuración Guardada" +#: admin/includes/class-wp-members-admin-api.php:355 +msgid "Emails" +msgstr "é›»å­éƒµä»¶" -#~ msgid "Sorry," -#~ msgstr "Lo lamentamos," +#: admin/includes/class-wp-members-admin-api.php:354 +msgid "Dialogs" +msgstr "å°è©±æ¡†" -#~ msgid "Agree to %s Terms%s" -#~ msgstr "De acuerdo con las %s condiciones de uso %s" +#: admin/includes/class-wp-members-admin-api.php:353 +msgid "Fields" +msgstr "å€å¡Š " -#~ msgid "http://butlerblog.com/wp-members/" -#~ msgstr "http://butlerblog.com/wp-members/" +#: admin/includes/class-wp-members-admin-api.php:352 +msgid "Options" +msgstr "é¸é …" -#~ msgid "" -#~ "WP access restriction and user registration. For more information and to " -#~ "download the free \"quick start guide,\" visit http://butlerblog.com/wp-members. View " -#~ "the live demo at http://" -#~ "butlerblog.com/wpmembers. WP-Members(tm) is a trademark of butlerblog." -#~ "com." -#~ msgstr "" -#~ "Restricción de acceso a WordPress y registro extendido de usuarios. Para " -#~ "más información, puede descargar la guía de usuario en http://butlerblog.com/wp-members. Vea una " -#~ "demostración en http://" -#~ "butlerblog.com/wpmembers. WP-Members(tm) es marca registrada de " -#~ "butlerblog.com." +#: admin/admin.php:49 admin/admin.php:111 +msgid "Settings" +msgstr " 設定" From 8b3fad3a115e7d5557ca60d5c64b5cd09367cefd Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 8 Feb 2018 20:22:24 -0600 Subject: [PATCH 0750/1694] add 'wp-members' textdomain to all remaining user facing strings --- inc/class-wp-members.php | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index ebf864bc..d8a318b9 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -1153,10 +1153,10 @@ function get_text( $str ) { // Login form. 'login_heading' => __( 'Existing Users Log In', 'wp-members' ), - 'login_username' => __( 'Username' ), - 'login_password' => __( 'Password' ), - 'login_button' => __( 'Log In' ), - 'remember_me' => __( 'Remember Me' ), + 'login_username' => __( 'Username', 'wp-members' ), + 'login_password' => __( 'Password', 'wp-members' ), + 'login_button' => __( 'Log In', 'wp-members' ), + 'remember_me' => __( 'Remember Me', 'wp-members' ), 'forgot_link_before' => __( 'Forgot password?', 'wp-members' ) . ' ', 'forgot_link' => __( 'Click here to reset', 'wp-members' ), 'register_link_before' => __( 'New User?', 'wp-members' ) . ' ', @@ -1164,14 +1164,14 @@ function get_text( $str ) { // Password change form. 'pwdchg_heading' => __( 'Change Password', 'wp-members' ), - 'pwdchg_password1' => __( 'New password' ), - 'pwdchg_password2' => __( 'Confirm new password' ), + 'pwdchg_password1' => __( 'New password', 'wp-members' ), + 'pwdchg_password2' => __( 'Confirm new password', 'wp-members' ), 'pwdchg_button' => __( 'Update Password', 'wp-members' ), // Password reset form. 'pwdreset_heading' => __( 'Reset Forgotten Password', 'wp-members' ), - 'pwdreset_username' => __( 'Username' ), - 'pwdreset_email' => __( 'Email' ), + 'pwdreset_username' => __( 'Username', 'wp-members' ), + 'pwdreset_email' => __( 'Email', 'wp-members' ), 'pwdreset_button' => __( 'Reset Password' ), 'username_link_before' => __( 'Forgot username?', 'wp-members' ) . ' ', 'username_link' => __( 'Click here', 'wp-members' ), @@ -1187,13 +1187,13 @@ function get_text( $str ) { 'register_rscaptcha' => __( 'Input the code:', 'wp-members' ), 'register_tos' => __( 'Please indicate that you agree to the %s TOS %s', 'wp-members' ), 'register_clear' => __( 'Reset Form', 'wp-members' ), - 'register_submit' => __( 'Register' ), + 'register_submit' => __( 'Register', 'wp-members' ), 'register_req_mark' => '*', 'register_required' => '*' . __( 'Required field', 'wp-members' ), // User profile update form. 'profile_heading' => __( 'Edit Your Information', 'wp-members' ), - 'profile_username' => __( 'Username' ), + 'profile_username' => __( 'Username', 'wp-members' ), 'profile_submit' => __( 'Update Profile', 'wp-members' ), 'profile_upload' => __( 'Update this file', 'wp-members' ), @@ -1230,11 +1230,11 @@ function get_text( $str ) { 'sb_logout' => __( 'click here to log out', 'wp-members' ), 'sb_login_failed' => __( 'Login Failed!
    You entered an invalid username or password.', 'wp-members' ), 'sb_not_logged_in' => __( 'You are not logged in.', 'wp-members' ), - 'sb_login_username' => __( 'Username' ), - 'sb_login_password' => __( 'Password' ), + 'sb_login_username' => __( 'Username', 'wp-members' ), + 'sb_login_password' => __( 'Password', 'wp-members' ), 'sb_login_button' => __( 'log in', 'wp-members' ), 'sb_login_forgot' => __( 'Forgot?', 'wp-members' ), - 'sb_login_register' => __( 'Register' ), + 'sb_login_register' => __( 'Register', 'wp-members' ), // Default Dialogs. 'restricted_msg' => __( "This content is restricted to site members. If you are an existing user, please log in. New users may register below.", 'wp-members' ), From ea0247c051a07d8e73829d436fc5764daa83c96e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 11 Feb 2018 18:00:38 -0600 Subject: [PATCH 0751/1694] new wpmem_set_block_status() method --- admin/post.php | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/admin/post.php b/admin/post.php index 0e1ff22e..1b01ba0c 100644 --- a/admin/post.php +++ b/admin/post.php @@ -366,4 +366,34 @@ function wpmem_load_tinymce() { } } +/** + * Sets custom block status for a post. + * + * @since 3.2.0 + * + * @global object $wpmem The WP_Members object class. + * @param int $status 0|1|2 for unblock|block|hide + * @param int $post_id The post ID to set a meta value. + * @param string $post_type The post type. + */ +function wpmem_set_block_status( $status, $post_id, $post_type ) { + global $wpmem; + + // Previous value. + $prev_value = get_post_meta( $post_id, '_wpmem_block', true ); + + // Update accordingly. + if ( $prev_value && $status != $prev_value ) { + if ( $status == $wpmem->block[ $post_type ] ) { + delete_post_meta( $post_id, '_wpmem_block' ); + } else { + update_post_meta( $post_id, '_wpmem_block', $status ); + } + } elseif ( ! $prev_value && $status != $wpmem->block[ $post_type ] ) { + update_post_meta( $post_id, '_wpmem_block', $status ); + } else { + delete_post_meta( $post_id, '_wpmem_block' ); + } +} + // End of File. \ No newline at end of file From bbc42a9db46c19c91e8c0e969a07ecec101ebea3 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 11 Feb 2018 18:02:04 -0600 Subject: [PATCH 0752/1694] update bulk action to include "hide", use wpmem_set_block_status() --- admin/post.php | 46 +++++++++++++++++----------------------------- 1 file changed, 17 insertions(+), 29 deletions(-) diff --git a/admin/post.php b/admin/post.php index 1b01ba0c..4c0104fa 100644 --- a/admin/post.php +++ b/admin/post.php @@ -42,10 +42,12 @@ function wpmem_bulk_posts_action() { if ( ( isset( $_GET['post_type'] ) && ( 'page' == $_GET['post_type'] || 'post' == $_GET['post_type'] || array_key_exists( $_GET['post_type'], $wpmem->post_types ) ) ) || ! isset( $_GET['post_type'] ) ) { ?> post_type; // Update accordingly. - if ( $wpmem->block[ $type ] == 0 ) { - if ( $action == 'block' ) { - update_post_meta( $post_id, '_wpmem_block', 1 ); - } else { - delete_post_meta( $post_id, '_wpmem_block' ); - } - } - - if ( $wpmem->block[ $type ] == 1 ) { - if ( $action == 'unblock' ) { - update_post_meta( $post_id, '_wpmem_block', 0 ); - } else { - delete_post_meta( $post_id, '_wpmem_block' ); - } - } + wpmem_set_block_status( $status, $post_id, $post->post_type ); } // Set the return message. $arr = array( - 'a' => $action, + 'a' => 'updated', 'n' => $x, 'post_type' => $type, ); @@ -272,16 +267,9 @@ function wpmem_block_meta_save( $post_id ) { // Get value. $block = ( isset( $_POST['wpmem_block'] ) ) ? sanitize_text_field( $_POST['wpmem_block'] ) : null; - - // Need the post object. - global $post; - - // Update accordingly. - if ( $block != null ) { - update_post_meta( $post_id, '_wpmem_block', $block ); - } else { - delete_post_meta( $post_id, '_wpmem_block' ); - } + + // Set the value. + wpmem_set_block_status( $block, $post_id, $post->post_type ); /** * Fires after the post block meta box is saved. From 281d500087322bea64790331bfcc57126672b7b1 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 11 Feb 2018 18:03:04 -0600 Subject: [PATCH 0753/1694] update post meta save/update/display --- admin/post.php | 35 ++++++++++++++++++++--------------- 1 file changed, 20 insertions(+), 15 deletions(-) diff --git a/admin/post.php b/admin/post.php index 4c0104fa..de31684f 100644 --- a/admin/post.php +++ b/admin/post.php @@ -200,28 +200,29 @@ function wpmem_block_meta() { $post_type = $wp_post_types[ $post->post_type ]; if ( isset( $wpmem->block[ $post->post_type ] ) && $wpmem->block[ $post->post_type ] == 1 ) { - $block = 0; $notice_icon = ''; $notice_text = sprintf( __( '%s are blocked by default.', 'wp-members' ), $post_type->labels->name ); } else { - $block = 1; $notice_icon = ''; $notice_text = sprintf( __( '%s are not blocked by default.', 'wp-members' ), $post_type->labels->name ); } - $meta = '_wpmem_block'; - $admin_url = get_admin_url(); - - $post_meta_value = get_post_meta( $post->ID, $meta, true ); - $post_meta_value = ( ! $post_meta_value ) ? $wpmem->block[ $post->post_type ] : $post_meta_value; - ?> + + $post_meta_value = get_post_meta( $post->ID, '_wpmem_block', true ); echo $post_meta_value; + + $post_meta_value = ( null == $post_meta_value ) ? $wpmem->block[ $post->post_type ] : $post_meta_value; echo $post_meta_value; + $post_meta_settings = array( + '0' => __( 'Unblock', 'wp-members' ), + '1' => __( 'Block', 'wp-members' ), + '2' => __( 'Hide', 'wp-members' ), + ); ?>

    ' . __( 'Edit', 'wp-members' ) . ''; ?>

    @@ -232,11 +233,12 @@ function wpmem_block_meta() { * Allows actions at the end of the block meta box on pages and posts. * * @since 2.8.8 + * @since 3.2.0 Changed to $post_meta_value (same as $block). * - * @param $post object The WP Post Object. - * @param $block boolean The WP-Members block value. + * @param $post object The WP Post Object. + * @param post_meta_value string The WP-Members block value: 0|1|2 for unblock|block|hide. */ - do_action( 'wpmem_admin_after_block_meta', $post, $block ); + do_action( 'wpmem_admin_after_block_meta', $post, $post_meta_value ); } @@ -246,9 +248,12 @@ function wpmem_block_meta() { * @since 2.8 * * @global object $post - * @param int $post_id The post ID + * @global object $wpmem + * @param int $post_id The post ID */ function wpmem_block_meta_save( $post_id ) { + + global $post, $wpmem; // Quit if we are doing autosave. if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) { From 96161961b57368eced1c704634bc05722864059b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 11 Feb 2018 18:05:42 -0600 Subject: [PATCH 0754/1694] added post_restricted message to get_text() --- inc/class-wp-members-products.php | 7 ++----- inc/class-wp-members.php | 1 + 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/inc/class-wp-members-products.php b/inc/class-wp-members-products.php index 32fd6661..df2c9311 100644 --- a/inc/class-wp-members-products.php +++ b/inc/class-wp-members-products.php @@ -58,16 +58,13 @@ function check_access( $content ) { $post_products = get_post_meta( $post->ID, $wpmem->membership->post_meta, true ); // If the post is restricted to a product. if ( $post_products ) { - // The error message for invalid users. - // @todo Filter this and also translate it. - $error_msg = 'Sorry, you do not have access to this page.'; - // @todo This is the nuts and bolts - work around whether a user has access // to this product or not. if ( $wpmem->user->has_access( $post_products ) ) { return $content; } - return $error_msg; + // The error message for invalid users. + return $wpmem->get_text( 'product_restricted' ); } else { // Content that has no product restriction. return $content; diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index d8a318b9..f3195537 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -1246,6 +1246,7 @@ function get_text( $str ) { 'pwdchangesuccess' => __( "Password successfully changed!", 'wp-members' ), 'pwdreseterr' => __( "Either the username or email address do not exist in our records.", 'wp-members' ), 'pwdresetsuccess' => __( "Password successfully reset!

    An email containing a new password has been sent to the email address on file for your account.", 'wp-members' ), + 'product_restricted' => __( "Sorry, you do not have access to this content.", 'wp-members' ), ); // End of $defaults array. From 3192622b3f6e7014e685ae60f7053ef888ea6aa3 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 11 Feb 2018 18:06:14 -0600 Subject: [PATCH 0755/1694] updated wpmem_default_text_strings filter to pass $defaults --- inc/class-wp-members.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index f3195537..7888d859 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -1254,11 +1254,11 @@ function get_text( $str ) { * Filter default terms. * * @since 3.1.0 + * @since 3.2.0 Passes $defaults param + * + * @param array $defaults */ - $text = apply_filters( 'wpmem_default_text_strings', '' ); - - // Merge filtered $terms with $defaults. - $text = wp_parse_args( $text, $defaults ); + $text = apply_filters( 'wpmem_default_text_strings', $defaults ); // Return the requested text string. return $text[ $str ]; From cd6d5f40c4c06a77dd4f2ce66dddb545a6b55a07 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 11 Feb 2018 18:07:30 -0600 Subject: [PATCH 0756/1694] cleanup --- inc/class-wp-members-forms.php | 3 +++ readme.txt | 7 +++++++ 2 files changed, 10 insertions(+) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index d1486891..06e54def 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -1239,6 +1239,7 @@ function strip_breaks( $form, $rows ) { * * @since 1.8 * @since 3.1.4 Global $wpmem_regchk no longer needed. + * @since 3.2.0 Moved to forms class, renamed do_login_form(). * * @global object $post The WordPress Post object. * @global object $wpmem The WP_Members object. @@ -1333,6 +1334,7 @@ function do_login_form( $page = "page", $redirect_to = null, $show = 'show' ) { * Loads the form for changing password. * * @since 2.0.0 + * @since 3.2.0 Moved to forms class, renamed do_changepassword_form(). * * @global object $wpmem The WP_Members object. * @return string $str The generated html for the change password form. @@ -1397,6 +1399,7 @@ function do_changepassword_form() { * Loads the form for resetting password. * * @since 2.1.0 + * @since 3.2.0 Moved to forms class, renamed do_resetpassword_form(). * * @global object $wpmem The WP_Members object. * @return string $str The generated html fo the reset password form. diff --git a/readme.txt b/readme.txt index 5c306052..df90ba6b 100644 --- a/readme.txt +++ b/readme.txt @@ -139,6 +139,9 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * Changed default address meta fields to WooCommerce billing meta keys. * Removed language packs that install from wordpress.org (de_DE, hu_HU, ja, nl_NL, pt_BR, ru_RU, and sv_SE). +* All remaining user facing strings in get_text() added wp-members textdomain. +* wpmem_default_text_strings filter now must pass $defaults as a parameter. +* Added locale as a parameter for localization filters. * Added wpmem_register_hidden_rows filter. * Added "post_to" key for wpmem_register_form_args. * Rebuild of user export function. User export now uses fputcsv. @@ -148,6 +151,7 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * Deprecated wpmem_inc_status(). * Deprecated wpmem_do_sidebar(). * Deprecated wpmem_create_formfield(), use wpmem_form_field() instead. +* Deprecated a number of non-user callable functions. * Eliminated permission-based file load for admin files. * Maintain user login state when password is changed. * Added wpmem_get_sub_str() string manipulation utility. @@ -164,6 +168,9 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * HTML5 update - form id tags set default value (can still be filtered). * HTML5 update - removed "align" attribute (captcha, link-text). * Moved remaining core functions to appropriate object classes, left wrappers for most. +* Added new email class and shortcode class to replace previous functions/files. +* Added link_span_before/link_span_after wrapper for login link text. +* Updated "TOS" text to "Terms of Service". = 3.1.9 = From f9d6f9089f9908cb01c4da7d6545699832e075fc Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 11 Feb 2018 18:41:41 -0600 Subject: [PATCH 0757/1694] removed debugging code --- admin/post.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/post.php b/admin/post.php index de31684f..40f6e792 100644 --- a/admin/post.php +++ b/admin/post.php @@ -207,9 +207,9 @@ function wpmem_block_meta() { $notice_text = sprintf( __( '%s are not blocked by default.', 'wp-members' ), $post_type->labels->name ); } - $post_meta_value = get_post_meta( $post->ID, '_wpmem_block', true ); echo $post_meta_value; + $post_meta_value = get_post_meta( $post->ID, '_wpmem_block', true ); - $post_meta_value = ( null == $post_meta_value ) ? $wpmem->block[ $post->post_type ] : $post_meta_value; echo $post_meta_value; + $post_meta_value = ( null == $post_meta_value ) ? $wpmem->block[ $post->post_type ] : $post_meta_value; $post_meta_settings = array( '0' => __( 'Unblock', 'wp-members' ), '1' => __( 'Block', 'wp-members' ), From e96e2881bda526f348a71540ea5a9e6e31a70292 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 13 Feb 2018 23:05:36 -0600 Subject: [PATCH 0758/1694] removed sidebar.php and old sidebar function --- inc/class-wp-members-widget.php | 4 +- inc/class-wp-members.php | 24 ++- inc/dialogs.php | 26 +++ inc/sidebar.php | 301 -------------------------------- 4 files changed, 44 insertions(+), 311 deletions(-) delete mode 100644 inc/sidebar.php diff --git a/inc/class-wp-members-widget.php b/inc/class-wp-members-widget.php index 25ccc8ae..b352d88a 100644 --- a/inc/class-wp-members-widget.php +++ b/inc/class-wp-members-widget.php @@ -107,9 +107,7 @@ function widget( $args, $instance ) { echo '
    '; echo $args['before_title'] . $title . $args['after_title']; // The Widget - if ( function_exists( 'wpmem_do_sidebar' ) ) { - $this->do_sidebar( $redirect_to ); - } + $this->do_sidebar( $redirect_to ); echo '
    '; echo $args['after_widget']; } diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 7888d859..9383a68d 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -323,9 +323,9 @@ function load_hooks() { do_action( 'wpmem_load_hooks' ); // Add actions. - add_action( 'template_redirect', array( $this, 'get_action' ) ); - add_action( 'widgets_init', 'wpmem_widget_init' ); // initializes the widget - add_action( 'admin_init', array( $this, 'load_admin' ) ); // check user role to load correct dashboard + add_action( 'template_redirect', array( $this, 'get_action' ) ); + add_action( 'widgets_init', array( $this, 'widget_init' ) ); // initializes the widget + add_action( 'admin_init', array( $this, 'load_admin' ) ); // check user role to load correct dashboard add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu add_action( 'user_register', 'wpmem_wp_reg_finalize' ); // handles wp native registration add_action( 'login_enqueue_scripts', 'wpmem_wplogin_stylesheet' ); // styles the native registration @@ -468,11 +468,11 @@ function load_dependencies() { require_once( WPMEM_PATH . 'inc/utilities.php' ); require_once( WPMEM_PATH . 'inc/forms.php' ); require_once( WPMEM_PATH . 'inc/dialogs.php' ); - require_once( WPMEM_PATH . 'inc/sidebar.php' ); - //require_once( WPMEM_PATH . 'inc/shortcodes.php' ); @deprecated 3.2.0 - //require_once( WPMEM_PATH . 'inc/email.php' ); @deprecated 3.2.0 + //require_once( WPMEM_PATH . 'inc/sidebar.php' ); // @deprecated 3.2.0 + //require_once( WPMEM_PATH . 'inc/shortcodes.php' ); // @deprecated 3.2.0 + //require_once( WPMEM_PATH . 'inc/email.php' ); // @deprecated 3.2.0 include_once( WPMEM_PATH . 'inc/wp-registration.php' ); - //require_once( WPMEM_PATH . 'inc/users.php' ); @deprecated 3.1.9 + //require_once( WPMEM_PATH . 'inc/users.php' ); // @deprecated 3.1.9 require_once( WPMEM_PATH . 'inc/deprecated.php' ); } @@ -1282,6 +1282,16 @@ function load_admin_api() { } } + /** + * Initializes the WP-Members widget. + * + * @since 3.2.0 Replaces widget_wpmemwidget_init + */ + public function widget_init() { + // Register the WP-Members widget. + register_widget( 'widget_wpmemwidget' ); + } + /** * Adds WP-Members query vars to WP's public query vars. * diff --git a/inc/dialogs.php b/inc/dialogs.php index aca40bd7..b8ed1158 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -21,6 +21,7 @@ * - wpmem_page_user_edit * - wpmem_page_forgot_username * - wpmem_inc_forgotusername + * - wpmem_inc_status */ // Exit if accessed directly. @@ -610,4 +611,29 @@ function wpmem_inc_forgotusername() { return $str; } +if ( ! function_exists( 'wpmem_inc_status' ) ): +/** + * Generate users login status if logged in and gives logout link. + * + * @since 1.8 + * @since 3.2.0 Moved from sidebar.php (which is now obsolete). + * + * @global $user_login + * @global object $wpmem + * @return string $status + */ +function wpmem_inc_status() { + + global $user_login, $wpmem; + + /** This filter is documented in wp-members/inc/dialogs.php */ + $logout = apply_filters( 'wpmem_logout_link', $url . '/?a=logout' ); + + $status = '

    ' . sprintf( $wpmem->get_text( 'sb_login_status' ), $user_login ) + . ' | ' . $wpmem->get_text( 'sb_logout_link' ) . '

    '; + + return $status; +} +endif; + // End of file. \ No newline at end of file diff --git a/inc/sidebar.php b/inc/sidebar.php deleted file mode 100644 index e4841914..00000000 --- a/inc/sidebar.php +++ /dev/null @@ -1,301 +0,0 @@ -' . sprintf( $wpmem->get_text( 'sb_login_status' ), $user_login ) - . ' | ' . $wpmem->get_text( 'sb_logout_link' ) . '

    '; - - return $status; -} -endif; - - -if ( ! function_exists( 'wpmem_do_sidebar' ) ): -/** - * Creates the sidebar login form and status. - * - * This function determines if the user is logged in and displays either - * a login form, or the user's login status. Typically used for a sidebar. - * You can call this directly, or with the widget. - * - * @since 2.4.0 - * @since 3.0.0 Added $post_to argument. - * @since 3.1.0 Changed $post_to to $redirect_to. - * - * @param string $redirect_to A URL to redirect to upon login, default null. - * @global string $wpmem_regchk - * @global string $user_login - */ -function wpmem_do_sidebar( $redirect_to = null ) { - - global $wpmem, $wpmem_regchk; - - // Used here and in the logout. - $url = get_bloginfo('url'); - - if ( isset( $_REQUEST['redirect_to'] ) ) { - $post_to = $_REQUEST['redirect_to']; - } elseif ( is_home() || is_front_page() ) { - $post_to = $_SERVER['REQUEST_URI']; - } elseif ( is_single() || is_page() ) { - $post_to = get_permalink(); - } elseif ( is_category() ) { - global $wp_query; - $cat_id = get_query_var( 'cat' ); - $post_to = get_category_link( $cat_id ); - } elseif ( is_search() ) { - $post_to = add_query_arg( 's', get_search_query(), $url ); - } else { - $post_to = $_SERVER['REQUEST_URI']; - } - - // Clean whatever the url is. - $post_to = esc_url( $post_to ); - - if ( ! is_user_logged_in() ){ - - // If the user is not logged in, we need the form. - - // Defaults. - $defaults = array( - // Wrappers. - 'error_before' => '

    ', - 'error_after' => '

    ', - 'fieldset_before' => '
    ', - 'fieldset_after' => '
    ', - 'inputs_before' => '
    ', - 'inputs_after' => '
    ', - 'buttons_before' => '
    ', - 'buttons_after' => '
    ', - - // Messages. - 'error_msg' => $wpmem->get_text( 'sb_login_failed' ), - 'status_msg' => $wpmem->get_text( 'sb_not_logged_in' ) . '
    ', - - // Other. - 'strip_breaks' => true, - 'wrap_inputs' => true, - 'n' => "\n", - 't' => "\t", - 'login_form_action' => true, - ); - - /** - * Filter arguments for the sidebar defaults. - * - * @since 2.9.0 - * - * @param array An array of the defaults to be changed. - */ - $args = apply_filters( 'wpmem_sb_login_args', '' ); - - // Merge $args with defaults. - $args = wp_parse_args( $args, $defaults ); - - $form = ''; - - $label = ''; - $input = ''; - - $input = ( $args['wrap_inputs'] ) ? $args['inputs_before'] . $input . $args['inputs_after'] : $input; - $row1 = $label . $args['n'] . $input . $args['n']; - - $label = ''; - $input = ''; - - $input = ( $args['wrap_inputs'] ) ? $args['inputs_before'] . $input . $args['inputs_after'] : $input; - $row2 = $label . $args['n'] . $input . $args['n']; - - $form = $row1 . $row2; - - // Handle outside elements added to the login form (currently ONLY for login). - if ( $args['login_form_action'] ) { - ob_start(); - do_action( 'login_form' ); - $add_to_form = ob_get_contents(); - ob_end_clean(); - $form.= $add_to_form; - } - - $hidden = '' . $args['n'] . - '' . $args['n'] . - '' . $args['n'] . - ''; - /** - * Filter sidebar login form hidden fields. - * - * @since 2.9.0 - * - * @param string $hidden The HTML for the hidden fields. - */ - $form = $form . apply_filters( 'wpmem_sb_hidden_fields', $hidden ); - - $buttons = ''; - - if ( $wpmem->user_pages['profile'] != null ) { - /** This filter is documented in wp-members/inc/forms.php */ - $link = apply_filters( 'wpmem_forgot_link', add_query_arg( 'a', 'pwdreset', $wpmem->user_pages['profile'] ) ); - $link_html = ' ' . $wpmem->get_text( 'sb_login_forgot' ) . ' '; - /** - * Filter the sidebar forgot password. - * - * @since 3.0.9 - * - * @param string $link_html - * @param string $link - */ - $link_html = apply_filters( 'wpmem_sb_forgot_link_str', $link_html, $link ); - $buttons.= $link_html; - } - - if ( $wpmem->user_pages['register'] != null ) { - /** This filter is documented in wp-members/inc/forms.php */ - $link = apply_filters( 'wpmem_reg_link', $wpmem->user_pages['register'] ); - $link_html = ' ' . $wpmem->get_text( 'sb_login_register' ) . ''; - /** - * Filter the sidebar register link. - * - * @since 3.0.9 - * - * @param string $link_html - * @param string $link - */ - $link_html = apply_filters( 'wpmem_sb_reg_link_str', $link_html, $link ); - $buttons.= $link_html; - } - - $form = $form . $args['n'] . $args['buttons_before'] . $buttons . $args['n'] . $args['buttons_after']; - - $form = $args['fieldset_before'] . $args['n'] . $form . $args['n'] . $args['fieldset_after']; - - $form = '
    ' . $args['n'] . $form . $args['n'] . '
    '; - - // Add status message. - $form = $args['status_msg'] . $args['n'] . $form; - - // Strip breaks. - $form = ( $args['strip_breaks'] ) ? str_replace( array( "\n", "\r", "\t" ), array( '','','' ), $form ) : $form; - - /** - * Filter the sidebar form. - * - * @since unknown - * - * @param string $form The HTML for the sidebar login form. - */ - $form = apply_filters( 'wpmem_sidebar_form', $form ); - - $do_error_msg = ''; - if ( isset( $_POST['slog'] ) && $wpmem_regchk == 'loginfailed' ) { - $do_error_msg = true; - $error_msg = $args['error_before'] . $args['error_msg'] . $args['error_after']; - /** - * Filter the sidebar login failed message. - * - * @since unknown - * - * @param string $error_msg The error message. - */ - $error_msg = apply_filters( 'wpmem_login_failed_sb', $error_msg ); - } - $form = ( $do_error_msg ) ? $error_msg . $form : $form; - - echo $form; - - } else { - - global $user_login; - - /** This filter is documented in wp-members/inc/dialogs.php */ - $logout = apply_filters( 'wpmem_logout_link', add_query_arg( 'a', 'logout', $url ) ); - - // Defaults. - $defaults = array( - 'user_login' => $user_login, - 'wrapper_before' => '

    ', - 'status_text' => sprintf( $wpmem->get_text( 'sb_status' ), $user_login ) . '
    ', - 'link_text' => $wpmem->get_text( 'sb_logout' ), - 'wrapper_after' => '

    ', - ); - - /** - * Filter sidebar login status arguments. - * - * @since 3.1.0 - * @since 3.1.2 Pass default args. - * - * @param array $defaults - * @return array - */ - $args = apply_filters( 'wpmem_sidebar_status_args', $defaults ); - - // Merge $args with $defaults. - $args = wp_parse_args( $args, $defaults ); - - // Generate the message string. - $str = $args['wrapper_before'] . $args['status_text'] . "" . $args['link_text'] . '' . $args['wrapper_after']; - - /** - * Filter the sidebar user login status. - * - * @since unknown - * - * @param string $str The login status for the user. - */ - $str = apply_filters( 'wpmem_sidebar_status', $str ); - - echo $str; - } -} -endif; - -// End of file. \ No newline at end of file From 9f65de35fa59c696edaa79fc0b0a4d239b06753e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 13 Feb 2018 23:12:20 -0600 Subject: [PATCH 0759/1694] update comments --- admin/tab-dropins.php | 1 + inc/class-wp-members-forms.php | 2 ++ inc/class-wp-members-shortcodes.php | 11 +++++++++++ inc/class-wp-members.php | 5 +++-- 4 files changed, 17 insertions(+), 2 deletions(-) diff --git a/admin/tab-dropins.php b/admin/tab-dropins.php index 33ca0adf..11ea4709 100644 --- a/admin/tab-dropins.php +++ b/admin/tab-dropins.php @@ -170,6 +170,7 @@ function wpmem_a_render_dropins_table() { global $wpmem; // Get the dropin folder. + /** This filter is documented in inc/class-wp-members.php */ $folder = apply_filters( 'wpmem_dropin_folder', WPMEM_DROPIN_DIR ); // Set file headers for dropins. diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 06e54def..884235c4 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -652,6 +652,7 @@ function login_form( $page, $arr ) { * the generated form. * * @since 2.7.4 + * @deprecated 3.2.0 Use wpmem_login_form instead. * * @param string $str The HTML to add before the form. Default null. * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange|getusername. @@ -1194,6 +1195,7 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { * the generated form. * * @since 2.7.4 + * @deprecated 3.2.0 Use wpmem_register_form instead. * * @param string $str The HTML to add before the form. Default null. * @param string $tag Toggle new registration or profile update. new|edit. diff --git a/inc/class-wp-members-shortcodes.php b/inc/class-wp-members-shortcodes.php index 6ff4aac8..34098892 100644 --- a/inc/class-wp-members-shortcodes.php +++ b/inc/class-wp-members-shortcodes.php @@ -60,6 +60,7 @@ function __construct() { * * @since 3.0.0 * @since 3.1.3 Added forgot_username shortcode. + * @since 3.2.0 Moved to WP_Members_Shortcodes::forms(). * * @global object $wpmem The WP_Members object. * @global string $wpmem_themsg The WP-Members message container. @@ -171,6 +172,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { * only to logged out users or visitors. * * @since 3.0.0 + * @since 3.2.0 Moved to WP_Members_Shortcodes::logged_in(). * * @global object $wpmem The WP_Members object. * @@ -263,6 +265,7 @@ function logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) { * Handles the [wpmem_logged_out] shortcode. * * @since 3.0.0 + * @since 3.2.0 Moved to WP_Members_Shortcodes::logged_out(). * * @param array $atts * @param string $content @@ -283,6 +286,7 @@ function logged_out( $atts, $content = null, $tag ) { * * @since 3.0.0 * @since 3.1.5 Added total user count features. + * @since 3.2.0 Moved to WP_Members_Shortcodes::user_count(). * * @global object $wpdb The WordPress database object. * @param array $atts { @@ -321,6 +325,7 @@ function user_count( $atts, $content = null ) { * * @since 3.1.0 * @since 3.1.2 Added function arguments. + * @since 3.2.0 Moved to WP_Members_Shortcodes::user_profile(). * * @global object $wpmem The WP_Members object. * @global string $wpmem_themsg The WP-Members message container. @@ -436,6 +441,7 @@ function user_profile( $atts, $content, $tag ) { * * @since 3.1.1 * @since 3.1.6 Uses wpmem_loginout(). + * @since 3.2.0 Moved to WP_Members_Shortcodes::loginout(). * * @param array $atts { * The shortcode attributes. @@ -473,6 +479,7 @@ function loginout( $atts, $content, $tag ) { * @since 3.1.2 * @since 3.1.4 Changed to display value rather than stored value for dropdown/multicheck/radio. * @since 3.1.5 Added display attribute, meta key as a direct attribute, and image/file display. + * @since 3.2.0 Moved to WP_Members_Shortcodes::fields(). * * @global object $wpmem The WP_Members object. * @param array $atts { @@ -587,6 +594,7 @@ function fields( $atts, $content = null, $tag ) { * Logout link shortcode [wpmem_logout]. * * @since 3.1.2 + * @since 3.2.0 Moved to WP_Members_Shortcodes::logout(). * * @param array $atts { * The shortcode attributes. @@ -610,6 +618,7 @@ function logout( $atts, $content, $tag ) { * TOS shortcode [wpmem_tos]. * * @since 3.1.2 + * @since 3.2.0 Moved to WP_Members_Shortcodes::tos(). * * @param array $atts { * The shortcode attributes. @@ -628,6 +637,7 @@ function tos( $atts, $content, $tag ) { * Display user avatar. * * @since 3.1.7 + * @since 3.2.0 Moved to WP_Members_Shortcodes::avatar(). * * @param array $atts { * The shortcode attributes. @@ -657,6 +667,7 @@ function avatar( $atts, $content, $tag ) { * Generates a login link with a return url. * * @since 3.1.7 + * @since 3.2.0 Moved to WP_Members_Shortcodes::login_link(). * * @param array $atts { * The shortcode attributes. diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 9383a68d..27a846ed 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -244,6 +244,7 @@ function __construct() { */ require_once( WPMEM_PATH . 'wp-members-install.php' ); // Update settings. + /** This filter is documented in /inc/class-wp-members.php */ $settings = apply_filters( 'wpmem_settings', wpmem_do_install() ); } @@ -1254,9 +1255,9 @@ function get_text( $str ) { * Filter default terms. * * @since 3.1.0 - * @since 3.2.0 Passes $defaults param + * @since 3.2.0 Passes $defaults param as a required element. * - * @param array $defaults + * @param array $defaults (required) */ $text = apply_filters( 'wpmem_default_text_strings', $defaults ); From 24821dbcbdaf35396b2805f7adbb09040044e68b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 10 Mar 2018 20:23:34 -0600 Subject: [PATCH 0760/1694] deprecated wpmem_settings_loaded, misc cleanup --- .../class-wp-members-products-admin.php | 2 +- admin/tab-about.php | 6 +-- inc/class-wp-members-user.php | 7 ++++ inc/class-wp-members.php | 39 +++++-------------- 4 files changed, 20 insertions(+), 34 deletions(-) diff --git a/admin/includes/class-wp-members-products-admin.php b/admin/includes/class-wp-members-products-admin.php index 029a0348..e6494dc1 100644 --- a/admin/includes/class-wp-members-products-admin.php +++ b/admin/includes/class-wp-members-products-admin.php @@ -140,7 +140,7 @@ function details_html( $post ) { get_meta( 'membership_product_role' ) ); ?>

    -

    +

    get_meta( 'membership_product_expires' ) === 'expires' ) ? 'checked' : ''; ?>> diff --git a/admin/tab-about.php b/admin/tab-about.php index 725dc2bd..3f3158e5 100644 --- a/admin/tab-about.php +++ b/admin/tab-about.php @@ -65,16 +65,16 @@ function wpmem_a_build_about_tab() { ?> to your site and/or business, please consider joining today! (And if you're already a premium support subscriber - Thank You! You make this plugin possible.)

    Introduced in 2006, WP-Members was the first WordPress Membership plugin and through support of the WP community it continues to grow - and be developed. Why put your trust in an unknown? WP-Members has a 10 year track record of active development and support.

    + and be developed. Why put your trust in an unknown? WP-Members has a 12 year track record of active development and support.

    Plugin Documentation | Premium Support | Join Today!

    Premium Extensions

    -

    These are some of the popular extensions that are available to premium support subscribers:

    +

    These are some of the popular extensions that are available:

    Advanced Options
    - This exclusive extension adds a host of extra features to the plugin that are as simple to set up as checking a box. Hides the dashboard, + This exclusive extension adds a host of additional features to the plugin that are as simple to set up as checking a box. Hides the dashboard, override WP default URLs for login and registration, disable certain WP defaults, change WP-Members defaults, notify admin on user profile update, integrate with other popular plugins like WooCommerce, BuddyPress, and ACF (Advanced Custom Fields), and more. See a list of available settings here. diff --git a/inc/class-wp-members-user.php b/inc/class-wp-members-user.php index f6447f85..dc97e7bd 100644 --- a/inc/class-wp-members-user.php +++ b/inc/class-wp-members-user.php @@ -90,6 +90,13 @@ function login() { /** * Filter the redirect url. * + * This is the plugin's original redirect filter. In 3.1.7, + * WP's login_redirect filter hook was added to provide better + * integration support for other plugins and also for users + * who may already be using WP's filter(s). login_redirect + * comes first, then wpmem_login_redirect. So wpmem_login_redirect + * can be used to override a default in login_redirect. + * * @since 2.7.7 * * @param string $redirect_to The url to direct to. diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 27a846ed..d335b33a 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -254,41 +254,20 @@ function __construct() { } $this->load_user_pages(); - - // Set the stylesheet. - $this->cssurl = ( isset( $this->style ) && $this->style == 'use_custom' ) ? $this->cssurl : $this->style; - - // Load forms. - $this->forms = new WP_Members_Forms; - - // Load api. - $this->api = new WP_Members_API; - - // Load user functions. - $this->user = new WP_Members_User( $this ); - - // Load shortcodes. - $this->shortcodes = new WP_Members_Shortcodes(); - - // Load membership plans - $this->membership = new WP_Members_Products(); - - // Load email functions - $this->email = new WP_Members_Email; - - // Load clone menus. - if ( $this->clone_menus ) { - $this->menus = new WP_Members_Menus(); - } + $this->cssurl = ( isset( $this->style ) && $this->style == 'use_custom' ) ? $this->cssurl : $this->style; // Set the stylesheet. + $this->forms = new WP_Members_Forms; // Load forms. + $this->api = new WP_Members_API; // Load api. + $this->user = new WP_Members_User( $this ); // Load user functions. + $this->shortcodes = new WP_Members_Shortcodes(); // Load shortcodes. + $this->membership = new WP_Members_Products(); // Load membership plans + $this->email = new WP_Members_Email; // Load email functions + $this->menus = ( $this->clone_menus ) ? new WP_Members_Menus() : null; // Load clone menus. /** * Fires after main settings are loaded. * * @since 3.0 - * @todo Consider deprecating this action. It is undocumented (and unlikely used by users), - * With the move of the remaining initial loading to the constructor, the object is - * no longer available to this action, and moving it doesn't make much sense since - * wpmem_after_init would come right after it. + * @deprecated 3.2.0 Use wpmem_after_init instead. */ do_action( 'wpmem_settings_loaded' ); From c56e7e6e4f2d5dc628ea12d23b8b4795486530ef Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 10 Mar 2018 20:25:12 -0600 Subject: [PATCH 0761/1694] update membership number generation, changed "lead" to "pad" --- inc/api.php | 12 +++++++----- inc/class-wp-members-api.php | 14 ++++++++------ 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/inc/api.php b/inc/api.php index bef0036b..d94ad869 100644 --- a/inc/api.php +++ b/inc/api.php @@ -373,13 +373,15 @@ function wpmem_user_has_meta( $meta, $value = false, $user_id = false ) { * Creates a membership number. * * @since 3.1.1 + * @since 3.2.0 Changed "lead" to "pad". * * @param array $args { - * @type string $option - * @type string $meta_key - * @type int $start (optional, default 0) - * @type int $increment (optional, default 1) - * @type int $lead + * @type string $option The wp_options name for the counter setting (required). + * @type string $meta_key The field's meta key (required). + * @type int $start Number to start with (optional, default 0). + * @type int $increment Number to increment by (optional, default 1). + * @type int $digits Number of digits for the number (optional). + * @type boolen $pad Pad leading zeros (optional, default true). * } * @return string $membersip_number */ diff --git a/inc/class-wp-members-api.php b/inc/class-wp-members-api.php index 8e0fa054..95413f93 100644 --- a/inc/class-wp-members-api.php +++ b/inc/class-wp-members-api.php @@ -135,7 +135,7 @@ function is_user_value_unique( $key, $val ) { * * @since 3.1.1 * - * @param string $option Option name for the counter setting. + * @param string $option The wp_options name for the counter setting (required). * @param int $start Number to start with (optional, default 0). * @param int $increment Number to increment by (optional, default 1). * @return int $number Next number in the series. @@ -162,13 +162,15 @@ function get_incremental_number( $option, $start = 0, $increment = 1 ) { * Generates a unique membership number based on settings. * * @since 3.1.1 + * @since 3.2.0 Changed "lead" value to "pad". * * @param array $args { - * @type string $option - * @type string $meta_key - * @type int $start (optional, default 0) - * @type int $increment (optional, default 1) - * @type int $lead + * @type string $option The wp_options name for the counter setting (required). + * @type string $meta_key The field's meta key (required). + * @type int $start Number to start with (optional, default 0). + * @type int $increment Number to increment by (optional, default 1). + * @type int $digits Number of digits for the number (optional). + * @type boolen $pad Pad leading zeros (optional, default true). * } * @return string $mem_number */ From c91dd0fbf7995a66beca10577b5fd3698f90542e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 10 Mar 2018 20:25:42 -0600 Subject: [PATCH 0762/1694] email key wpmem_msurl changed to wpmem_profile --- inc/class-wp-members-email.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/inc/class-wp-members-email.php b/inc/class-wp-members-email.php index 291d7369..1b78ac28 100644 --- a/inc/class-wp-members-email.php +++ b/inc/class-wp-members-email.php @@ -49,6 +49,7 @@ class WP_Members_Email { * @since 2.9.7 Major overhaul, added wpmem_email_filter filter. * @since 3.1.0 Can filter in custom shortcodes with wpmem_email_shortcodes. * @since 3.1.1 Added $custom argument for custom emails. + * @since 3.2.0 Changed wpmem_msurl key to wpmem_profile. * @since 3.2.0 Moved to WP_Members_Email::to_user(). * * @global object $wpmem The WP_Members object. @@ -123,7 +124,7 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat $arr['blogname'] = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); $arr['exp_type'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; $arr['exp_date'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; - $arr['wpmem_msurl'] = esc_url( $wpmem->user_pages['profile'] ); + $arr['wpmem_profile'] = esc_url( $wpmem->user_pages['profile'] ); $arr['wpmem_reg'] = esc_url( $wpmem->user_pages['register'] ); $arr['wpmem_login'] = esc_url( $wpmem->user_pages['login'] ); $arr['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); @@ -155,6 +156,7 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * * @since 2.9.7 * @since 3.1.0 Added footer content to the array. + * @since 3.2.0 Changed wpmem_msurl key to wpmem_profile. * * @param array $arr { * An array containing email body, subject, user id, and additional settings. @@ -168,7 +170,7 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * @type string blogname * @type string exp_type * @type string exp_date - * @type string wpmem_msurl + * @type string wpmem_profile * @type string reg_link * @type string do_shortcodes * @type bool add_footer @@ -253,8 +255,8 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat 'password' => $password, 'email' => $arr['user_email'], 'reglink' => $arr['reg_link'], - 'members-area' => $arr['wpmem_msurl'], - 'user-profile' => $arr['wpmem_msurl'], + 'members-area' => $arr['wpmem_profile'], + 'user-profile' => $arr['wpmem_profile'], 'exp-type' => $arr['exp_type'], 'exp-data' => $arr['exp_date'], 'exp-date' => $arr['exp_date'], From e58720b16118df636b79d460b4e9e1c0874552b8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 10 Mar 2018 20:26:42 -0600 Subject: [PATCH 0763/1694] fixed wpmem_tos_link_txt filter --- inc/class-wp-members-forms.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 884235c4..925f43d9 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -652,7 +652,6 @@ function login_form( $page, $arr ) { * the generated form. * * @since 2.7.4 - * @deprecated 3.2.0 Use wpmem_login_form instead. * * @param string $str The HTML to add before the form. Default null. * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange|getusername. @@ -879,7 +878,9 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { * @param string The link text. * @param string $tag Toggle new registration or profile update. new|edit. */ - $input.= apply_filters( 'wpmem_tos_link_txt', sprintf( $wpmem->get_text( 'register_tos' ), $tos_pop, '' ), $tag ); + $tos_link_text = apply_filters( 'wpmem_tos_link_txt', $wpmem->get_text( 'register_tos' ), $tag ); + + $input.= sprintf( $tos_link_text, $tos_pop, '' ); // In previous versions, the div class would end up being the same as the row before. $field_before = ( $args['wrap_inputs'] ) ? '

    ' : ''; @@ -1195,7 +1196,6 @@ function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { * the generated form. * * @since 2.7.4 - * @deprecated 3.2.0 Use wpmem_register_form instead. * * @param string $str The HTML to add before the form. Default null. * @param string $tag Toggle new registration or profile update. new|edit. From 4880bc6b72480d70cd89a92400ed36a2903f80d0 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 10 Mar 2018 20:27:18 -0600 Subject: [PATCH 0764/1694] added raw message and HTML as separate params in wpmem_restricted_msg --- inc/class-wp-members-forms.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 925f43d9..5a95b09b 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -1271,10 +1271,14 @@ function do_login_form( $page = "page", $redirect_to = null, $show = 'show' ) { * Filter the post restricted message. * * @since 2.7.3 + * @since 3.2.0 Added raw message string and HTML as separate params. * - * @param string $str The post restricted message. + * @param string $str The post restricted message with HTML. + * @param string $msg The raw message string. + * @param string The 'before' HTML wrapper. + * @param string The 'after' HTML wrapper. */ - $str = apply_filters( 'wpmem_restricted_msg', $str ); + $str = apply_filters( 'wpmem_restricted_msg', $str, $msg, '

    ', '

    ' ); } } From e03e94d3f31138884e6f38673ef3120f089f9d7a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 10 Mar 2018 20:28:22 -0600 Subject: [PATCH 0765/1694] moved forgot username funcs to correspond with login and password form funcs --- inc/class-wp-members-forms.php | 58 ++++++++++++++++++++++++++++++++++ inc/dialogs.php | 58 ---------------------------------- inc/forms.php | 16 ++++++++++ 3 files changed, 74 insertions(+), 58 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 5a95b09b..59a426f1 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -1463,6 +1463,64 @@ function do_resetpassword_form() { return $str; } + + /** + * Forgot Username Form. + * + * Loads the form for retrieving a username. + * + * @since 3.0.8 + * @since 3.2.0 Moved to forms class, renamed do_forgotusername_form(). + * + * @global object $wpmem The WP_Members object class. + * @return string $str The generated html for the forgot username form. + */ + function do_forgotusername_form() { + + global $wpmem; + + // create the default inputs + $default_inputs = array( + array( + 'name' => $wpmem->get_text( 'username_email' ), + 'type' => 'text', + 'tag' => 'user_email', + 'class' => 'username', + 'div' => 'div_text', + ), + ); + + /** + * Filter the array of forgot username form fields. + * + * @since 2.9.0 + * + * @param array $default_inputs An array matching the elements used by default. + */ + $default_inputs = apply_filters( 'wpmem_inc_forgotusername_inputs', $default_inputs ); + + $defaults = array( + 'heading' => $wpmem->get_text( 'username_heading' ), + 'action' => 'getusername', + 'button_text' => $wpmem->get_text( 'username_button' ), + 'inputs' => $default_inputs, + ); + + /** + * Filter the arguments to override change password form defaults. + * + * @since + * + * @param array $args An array of arguments to use. Default null. + */ + $args = apply_filters( 'wpmem_inc_forgotusername_args', '' ); + + $arr = wp_parse_args( $args, $defaults ); + + $str = wpmem_login_form( 'page', $arr ); + + return $str; + } } // End of WP_Members_Forms class. \ No newline at end of file diff --git a/inc/dialogs.php b/inc/dialogs.php index b8ed1158..8a0f57f4 100644 --- a/inc/dialogs.php +++ b/inc/dialogs.php @@ -553,64 +553,6 @@ function wpmem_page_forgot_username( $wpmem_regchk, $content ) { } - -/** - * Forgot Username Form. - * - * Loads the form for retrieving a username. - * - * @since 3.0.8 - * - * @global object $wpmem The WP_Members object class. - * @return string $str The generated html for the forgot username form. - */ -function wpmem_inc_forgotusername() { - - global $wpmem; - - // create the default inputs - $default_inputs = array( - array( - 'name' => $wpmem->get_text( 'username_email' ), - 'type' => 'text', - 'tag' => 'user_email', - 'class' => 'username', - 'div' => 'div_text', - ), - ); - - /** - * Filter the array of forgot username form fields. - * - * @since 2.9.0 - * - * @param array $default_inputs An array matching the elements used by default. - */ - $default_inputs = apply_filters( 'wpmem_inc_forgotusername_inputs', $default_inputs ); - - $defaults = array( - 'heading' => $wpmem->get_text( 'username_heading' ), - 'action' => 'getusername', - 'button_text' => $wpmem->get_text( 'username_button' ), - 'inputs' => $default_inputs, - ); - - /** - * Filter the arguments to override change password form defaults. - * - * @since - * - * @param array $args An array of arguments to use. Default null. - */ - $args = apply_filters( 'wpmem_inc_forgotusername_args', '' ); - - $arr = wp_parse_args( $args, $defaults ); - - $str = wpmem_login_form( 'page', $arr ); - - return $str; -} - if ( ! function_exists( 'wpmem_inc_status' ) ): /** * Generate users login status if logged in and gives logout link. diff --git a/inc/forms.php b/inc/forms.php index f992fa61..83a50b21 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -130,6 +130,22 @@ function wpmem_login_form( $page, $arr ) { } endif; +/** + * Forgot Username Form. + * + * Loads the form for retrieving a username. + * + * @since 3.0.8 + * @since 3.2.0 Moved to forms.php. + * + * @global object $wpmem The WP_Members object class. + * @return string $str The generated html for the forgot username form. + */ +function wpmem_inc_forgotusername() { + global $wpmem; + return $wpmem->forms->do_forgotusername_form(); +} + if ( ! function_exists( 'wpmem_inc_registration' ) ): /** From d06e3b9f924c53e542d5ee45e40465b2b343fcea Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 10 Mar 2018 20:28:44 -0600 Subject: [PATCH 0766/1694] added logout_redirect filter --- inc/class-wp-members-user.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/inc/class-wp-members-user.php b/inc/class-wp-members-user.php index dc97e7bd..330c717e 100644 --- a/inc/class-wp-members-user.php +++ b/inc/class-wp-members-user.php @@ -116,6 +116,7 @@ function login() { * wrapper and is the direct function called for logout. * * @since 3.1.7 + * @since 3.2.0 Added logout_redirect filter * * @param string $redirect_to URL to redirect the user to (default: false). */ @@ -123,6 +124,8 @@ function logout( $redirect_to = false ) { // Default redirect URL. $redirect_to = ( $redirect_to ) ? $redirect_to : home_url(); + /** This filter is documented in /wp-login.php */ + $redirect_to = apply_filters( 'logout_redirect', $redirect_to, $redirect_to, wp_get_current_user() ); /** * Filter where the user goes when logged out. * From 5690cc38ea09be5ae30c8e0b7445050bdcde84f0 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 7 Apr 2018 10:01:28 -0500 Subject: [PATCH 0767/1694] email class overhaul, changed toggle to tag, condensed unecessary code, added send() method --- inc/class-wp-members-email.php | 358 ++++++++++++++------------------- 1 file changed, 156 insertions(+), 202 deletions(-) diff --git a/inc/class-wp-members-email.php b/inc/class-wp-members-email.php index 1b78ac28..96b3cb55 100644 --- a/inc/class-wp-members-email.php +++ b/inc/class-wp-members-email.php @@ -41,6 +41,15 @@ class WP_Members_Email { */ public $from_name; + /** + * Container for settings. + * + * @since 3.2.0 + * @access public + * @var array + */ + public $settings; + /** * Builds emails for the user. * @@ -50,6 +59,7 @@ class WP_Members_Email { * @since 3.1.0 Can filter in custom shortcodes with wpmem_email_shortcodes. * @since 3.1.1 Added $custom argument for custom emails. * @since 3.2.0 Changed wpmem_msurl key to wpmem_profile. + * @since 3.2.0 Changed toggle key to tag. * @since 3.2.0 Moved to WP_Members_Email::to_user(). * * @global object $wpmem The WP_Members object. @@ -57,81 +67,56 @@ class WP_Members_Email { * @global string $wpmem_mail_from_name The email from name. * @param int $user_ID The User's ID. * @param string $password Password from the registration process. - * @param string $toggle Toggle indicating the email being sent (newreg|newmod|appmod|repass|getuser). + * @param string $tag Tag indicating the email being sent (newreg|newmod|appmod|repass|getuser). * @param array $wpmem_fields Array of the WP-Members fields (defaults to null). * @param array $fields Array of the registration data (defaults to null). * @param array $custom Array of custom email information (defaults to null). */ - function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_data = null, $custom = null ) { + function to_user( $user_id, $password, $tag, $wpmem_fields = null, $field_data = null, $custom = null ) { global $wpmem; // Handle backward compatibility for customizations that may call the email function directly. - $wpmem_fields = wpmem_fields( $toggle ); - - /* - * Determine which email is being sent. - * - * Stored option is an array with keys 'body' and 'subj'. - */ - switch ( $toggle ) { - - case 0: - // This is a new registration. - $arr = get_option( 'wpmembers_email_newreg' ); - $arr['toggle'] = 'newreg'; - break; - - case 1: - // Registration is moderated. - $arr = get_option( 'wpmembers_email_newmod' ); - $arr['toggle'] = 'newmod'; - break; - - case 2: - // Registration is moderated, user is approved. - $arr = get_option( 'wpmembers_email_appmod' ); - $arr['toggle'] = 'appmod'; - break; - - case 3: - // This is a password reset. - $arr = get_option( 'wpmembers_email_repass' ); - $arr['toggle'] = 'repass'; - break; - - case 4: - // This is a retrieve username. - $arr = get_option( 'wpmembers_email_getuser' ); - $arr['toggle'] = 'getuser'; - break; - - case 5: - // This is a custom email. - $arr['subj'] = $custom['subj']; - $arr['body'] = $custom['body']; - $arr['toggle'] = $custom['toggle']; - + $wpmem_fields = wpmem_fields(); + + //Determine email to be sent. Stored option is an array with keys 'body' and 'subj'. + $tag_array = array( 'newreg', 'newmod', 'appmod', 'repass', 'getuser' ); + switch ( $tag ) { + case 0: + case 1: + case 2: + case 3: + case 4: + $tag = $tag_array[ $tag ]; + $this->settings = get_option( 'wpmembers_email_' . $tag ); + $this->settings['tag'] = $tag; + break; + case 5: + // This is a custom email. + $this->settings['subj'] = $custom['subj']; + $this->settings['body'] = $custom['body']; + $this->settings['tag'] = $custom['tag']; + break; } // Get the user ID. $user = new WP_User( $user_id ); // Userdata for default shortcodes. - $arr['user_id'] = $user_id; - $arr['user_login'] = stripslashes( $user->user_login ); - $arr['user_email'] = stripslashes( $user->user_email ); - $arr['blogname'] = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); - $arr['exp_type'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; - $arr['exp_date'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; - $arr['wpmem_profile'] = esc_url( $wpmem->user_pages['profile'] ); - $arr['wpmem_reg'] = esc_url( $wpmem->user_pages['register'] ); - $arr['wpmem_login'] = esc_url( $wpmem->user_pages['login'] ); - $arr['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); - $arr['do_shortcodes'] = true; - $arr['add_footer'] = true; - $arr['footer'] = get_option( 'wpmembers_email_footer' ); - $arr['disable'] = false; + $this->settings['user_id'] = $user_id; + $this->settings['user_login'] = stripslashes( $user->user_login ); + $this->settings['user_email'] = stripslashes( $user->user_email ); + $this->settings['blogname'] = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); + $this->settings['exp_type'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; + $this->settings['exp_date'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; + $this->settings['wpmem_profile'] = esc_url( $wpmem->user_pages['profile'] ); + $this->settings['wpmem_reg'] = esc_url( $wpmem->user_pages['register'] ); + $this->settings['wpmem_login'] = esc_url( $wpmem->user_pages['login'] ); + $this->settings['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); + $this->settings['do_shortcodes'] = true; + $this->settings['add_footer'] = true; + $this->settings['footer'] = get_option( 'wpmembers_email_footer' ); + $this->settings['disable'] = false; // Apply filters (if set) for the sending email address. $default_header = ( $this->from && $this->from_name ) ? 'From: "' . $this->from_name . '" <' . $this->from . '>' : ''; @@ -140,11 +125,12 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * Filters the email headers. * * @since 2.7.4 + * @since 3.2.0 Changed toggle to tag. * - * @param mixed $default_header The email headers. - * @param string $arr['toggle'] Toggle to determine what email is being generated (newreg|newmod|appmod|repass|admin). + * @param mixed $default_header The email headers. + * @param string $this->settings['tag'] Tag to determine what email is being generated (newreg|newmod|appmod|repass|admin). */ - $arr['headers'] = apply_filters( 'wpmem_email_headers', $default_header, $arr['toggle'] ); + $this->settings['headers'] = apply_filters( 'wpmem_email_headers', $default_header, $this->settings['tag'] ); /** * Filter the email. @@ -157,13 +143,14 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * @since 2.9.7 * @since 3.1.0 Added footer content to the array. * @since 3.2.0 Changed wpmem_msurl key to wpmem_profile. + * @since 3.2.0 Change toggle to tag. * - * @param array $arr { + * @param array $this->settings { * An array containing email body, subject, user id, and additional settings. * * @type string subj * @type string body - * @type string toggle + * @type string tag * @type int user_id * @type string user_login * @type string user_email @@ -181,87 +168,40 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * @param array $wpmem_fields An array of the WP-Members fields. * @param array $field_data An array of the posted registration data. */ - $arr = apply_filters( 'wpmem_email_filter', $arr, $wpmem_fields, $field_data ); + $this->settings = apply_filters( 'wpmem_email_filter', $this->settings, $wpmem_fields, $field_data ); // If emails are not disabled, continue the email process. - if ( ! $arr['disable'] ) { - - // Legacy email filters applied. - switch ( $arr['toggle'] ) { - - case 'newreg': - // This is a new registration. - /** - * Filters the new registration email. - * - * @since 2.7.4 - * @deprecated 3.2.0 Use wpmem_email_filter instead. - * - * @param string $arr['body'] The body content of the new registration email. - */ - $arr['body'] = apply_filters( 'wpmem_email_newreg', $arr['body'] ); - break; - - case 'newmod': - // Registration is moderated. - /** - * Filters the new moderated registration email. - * - * @since 2.7.4 - * @deprecated 3.2.0 Use wpmem_email_filter instead. - * - * @param string $arr['body'] The body content of the moderated registration email. - */ - $arr['body'] = apply_filters( 'wpmem_email_newmod', $arr['body'] ); - break; - - case 'appmod': - // Registration is moderated, user is approved. - /** - * Filters the reset password email. - * - * @since 2.7.4 - * @deprecated 3.2.0 Use wpmem_email_filter instead. - * - * @param string $arr['body'] The body content of the reset password email. - */ - $arr['body'] = apply_filters( 'wpmem_email_appmod', $arr['body'] ); - break; - - case 'repass': - // This is a password reset. - /** - * Filters the approved registration email. - * - * @since 2.7.4 - * @deprecated 3.2.0 Use wpmem_email_filter instead. - * - * @param string $arr['body'] The body content of the approved registration email. - */ - $arr['body'] = apply_filters( 'wpmem_email_repass', $arr['body'] ); - break; - - } + if ( ! $this->settings['disable'] ) { + + /** + * Filters the email body based on tag. + * + * @since 2.7.4 + * @deprecated 3.2.0 Use wpmem_email_filter instead. + * + * @param string $this->settings['body'] The body content of the new registration email. + */ + $this->settings['body'] = apply_filters( 'wpmem_email_' . $this->settings['tag'], $this->settings['body'] ); // Get the email footer if needed. - $foot = ( $arr['add_footer'] ) ? $arr['footer'] : ''; + $foot = ( $this->settings['add_footer'] ) ? $this->settings['footer'] : ''; // If doing shortcode replacements. - if ( $arr['do_shortcodes'] ) { + if ( $this->settings['do_shortcodes'] ) { $shortcodes = array( - 'blogname' => $arr['blogname'], - 'username' => $arr['user_login'], + 'blogname' => $this->settings['blogname'], + 'username' => $this->settings['user_login'], 'password' => $password, - 'email' => $arr['user_email'], - 'reglink' => $arr['reg_link'], - 'members-area' => $arr['wpmem_profile'], - 'user-profile' => $arr['wpmem_profile'], - 'exp-type' => $arr['exp_type'], - 'exp-data' => $arr['exp_date'], - 'exp-date' => $arr['exp_date'], - 'login' => $arr['wpmem_login'], - 'register' => $arr['wpmem_reg'], + 'email' => $this->settings['user_email'], + 'reglink' => $this->settings['reg_link'], + 'members-area' => $this->settings['wpmem_profile'], + 'user-profile' => $this->settings['wpmem_profile'], + 'exp-type' => $this->settings['exp_type'], + 'exp-data' => $this->settings['exp_date'], + 'exp-date' => $this->settings['exp_date'], + 'login' => $this->settings['wpmem_login'], + 'register' => $this->settings['wpmem_reg'], ); // Add custom field shortcodes. @@ -276,9 +216,9 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat * @since 3.1.0 * * @param array $shortcodes - * @param string $toggle + * @param string $tag */ - $shortcodes = apply_filters( 'wpmem_email_shortcodes', $shortcodes, $arr['toggle'] ); + $shortcodes = apply_filters( 'wpmem_email_shortcodes', $shortcodes, $this->settings['tag'] ); $shortcd = array(); $replace = array(); @@ -290,27 +230,19 @@ function to_user( $user_id, $password, $toggle, $wpmem_fields = null, $field_dat } // Do replacements for subject, body, and footer shortcodes. - $arr['subj'] = str_replace( $shortcd, $replace, $arr['subj'] ); - $arr['body'] = str_replace( $shortcd, $replace, $arr['body'] ); - $foot = ( $arr['add_footer'] ) ? str_replace( $shortcd, $replace, $foot ) : ''; + $this->settings['subj'] = str_replace( $shortcd, $replace, $this->settings['subj'] ); + $this->settings['body'] = str_replace( $shortcd, $replace, $this->settings['body'] ); + $foot = ( $this->settings['add_footer'] ) ? str_replace( $shortcd, $replace, $foot ) : ''; } // Append footer if needed. - $arr['body'] = ( $arr['add_footer'] ) ? $arr['body'] . "\r\n" . $foot : $arr['body']; - - // @todo The remainder is slated to be moved to an "email send" function. - // Apply WP's "from" and "from name" email filters. - add_filter( 'wp_mail_from', array( $this, 'from' ) ); - add_filter( 'wp_mail_from_name', array( $this, 'from_name' ) ); + $this->settings['body'] = ( $this->settings['add_footer'] ) ? $this->settings['body'] . "\r\n" . $foot : $this->settings['body']; - // Send the message. - wp_mail( $arr['user_email'], stripslashes( $arr['subj'] ), stripslashes( $arr['body'] ), $arr['headers'] ); - // @todo End of slated for move. + // Send message. + $this->send(); } - return; - } /** @@ -350,22 +282,22 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { $user = get_userdata( $user_id ); // Get the email stored values. - $arr = get_option( 'wpmembers_email_notify' ); + $this->settings = get_option( 'wpmembers_email_notify' ); // Userdata for default shortcodes. - $arr['user_id'] = $user_id; - $arr['user_login'] = stripslashes( $user->user_login ); - $arr['user_email'] = stripslashes( $user->user_email ); - $arr['blogname'] = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); - $arr['user_ip'] = ( is_array( $field_data ) ) ? $field_data['wpmem_reg_ip'] : get_user_meta( $user_id, 'wpmem_reg_ip', true ); - $arr['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); - $arr['act_link'] = esc_url( add_query_arg( 'user_id', $user_id, get_admin_url( '', 'user-edit.php' ) ) ); - $arr['exp_type'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; - $arr['exp_date'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; - $arr['do_shortcodes'] = true; - $arr['add_footer'] = true; - $arr['footer'] = get_option( 'wpmembers_email_footer' ); - $arr['disable'] = false; + $this->settings['user_id'] = $user_id; + $this->settings['user_login'] = stripslashes( $user->user_login ); + $this->settings['user_email'] = stripslashes( $user->user_email ); + $this->settings['blogname'] = wp_specialchars_decode( get_option ( 'blogname' ), ENT_QUOTES ); + $this->settings['user_ip'] = ( is_array( $field_data ) ) ? $field_data['wpmem_reg_ip'] : get_user_meta( $user_id, 'wpmem_reg_ip', true ); + $this->settings['reg_link'] = esc_url( get_user_meta( $user_id, 'wpmem_reg_url', true ) ); + $this->settings['act_link'] = esc_url( add_query_arg( 'user_id', $user_id, get_admin_url( '', 'user-edit.php' ) ) ); + $this->settings['exp_type'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'exp_type', true ) : ''; + $this->settings['exp_date'] = ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) ? get_user_meta( $user_id, 'expires', true ) : ''; + $this->settings['do_shortcodes'] = true; + $this->settings['add_footer'] = true; + $this->settings['footer'] = get_option( 'wpmembers_email_footer' ); + $this->settings['disable'] = false; // Builds an array of the user data fields. $field_arr = array(); @@ -388,13 +320,13 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { } } } - $arr['field_arr'] = $field_arr; + $this->settings['field_arr'] = $field_arr; // Apply filters (if set) for the sending email address. $default_header = ( $this->from && $this->from_name ) ? 'From: "' . $this->from_name . '" <' . $this->from . '>' : ''; - /** This filter is documented in email.php */ - $arr['headers'] = apply_filters( 'wpmem_email_headers', $default_header, 'admin' ); + /** This filter is documented in class-wp-members-email.php */ + $this->settings['headers'] = apply_filters( 'wpmem_email_headers', $default_header, 'admin' ); /** * Filters the address the admin notification is sent to. @@ -403,7 +335,7 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { * * @param string The email address of the admin to send to. */ - $arr['admin_email'] = apply_filters( 'wpmem_notify_addr', get_option( 'admin_email' ) ); + $this->settings['admin_email'] = apply_filters( 'wpmem_notify_addr', get_option( 'admin_email' ) ); /** * Filter the email. @@ -416,39 +348,55 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { * * @since 2.9.8 * - * @param array $arr An array containing email body, subject, user id, and additional settings. - * @param array $wpmem_fields An array of the WP-Members fields. - * @param array $arr['field_arr'] An array of the posted registration data. + * @param array $this->settings P + * An array containing email body, subject, user id, and additional settings. + * + * @type integer user_id + * @type string user_login + * @type string user_email + * @type string blogname + * @type string user_ip + * @type string reg_link + * @type string act_link + * @type string exp_type + * @type string exp_date + * @type boolean do_shortcodes + * @type boolean add_footer + * @type boolean footer + * @type boolean disable + * } + * @param array $wpmem_fields An array of the WP-Members fields. + * @param array $field_data An array of the posted registration data. */ - $arr = apply_filters( 'wpmem_notify_filter', $arr, $wpmem_fields, $field_data ); + $this->settings = apply_filters( 'wpmem_notify_filter', $this->settings, $wpmem_fields, $field_data ); // If emails are not disabled, continue the email process. - if ( ! $arr['disable'] ) { + if ( ! $this->settings['disable'] ) { // Split field_arr into field_str. $field_str = ''; - foreach ( $arr['field_arr'] as $key => $val ) { + foreach ( $this->settings['field_arr'] as $key => $val ) { $field_str.= $key . ': ' . $val . "\r\n"; // @todo Location "B" to to label translation. Could be as follows: // $field_str.= __( $key, 'wp-members' ) . ": " . $val . "\r\n"; } // Get the email footer if needed. - $foot = ( $arr['add_footer'] ) ? $arr['footer'] : ''; + $foot = ( $this->settings['add_footer'] ) ? $this->settings['footer'] : ''; // If doing shortcode replacements. - if ( $arr['do_shortcodes'] ) { + if ( $this->settings['do_shortcodes'] ) { $shortcodes = array( - 'blogname' => $arr['blogname'], - 'username' => $arr['user_login'], - 'email' => $arr['user_email'], - 'reglink' => $arr['reg_link'], - 'exp-type' => $arr['exp_type'], - 'exp-data' => $arr['exp_date'], - 'exp-date' => $arr['exp_date'], - 'user-ip' => $arr['user_ip'], - 'activate-user' => $arr['act_link'], + 'blogname' => $this->settings['blogname'], + 'username' => $this->settings['user_login'], + 'email' => $this->settings['user_email'], + 'reglink' => $this->settings['reg_link'], + 'exp-type' => $this->settings['exp_type'], + 'exp-data' => $this->settings['exp_date'], + 'exp-date' => $this->settings['exp_date'], + 'user-ip' => $this->settings['user_ip'], + 'activate-user' => $this->settings['act_link'], 'fields' => $field_str, ); @@ -484,13 +432,13 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { } // Get the subject, body, and footer shortcodes. - $arr['subj'] = str_replace( $shortcd, $replace, $arr['subj'] ); - $arr['body'] = str_replace( $shortcd, $replace, $arr['body'] ); - $foot = ( $arr['add_footer'] ) ? str_replace( $shortcd, $replace, $foot ) : ''; + $this->settings['subj'] = str_replace( $shortcd, $replace, $this->settings['subj'] ); + $this->settings['body'] = str_replace( $shortcd, $replace, $this->settings['body'] ); + $foot = ( $this->settings['add_footer'] ) ? str_replace( $shortcd, $replace, $foot ) : ''; } // Append footer if needed. - $arr['body'] = ( $arr['add_footer'] ) ? $arr['body'] . "\r\n" . $foot : $arr['body']; + $this->settings['body'] = ( $this->settings['add_footer'] ) ? $this->settings['body'] . "\r\n" . $foot : $this->settings['body']; /** * Filters the admin notification email. @@ -503,18 +451,12 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { * * @since 2.8.2 * - * @param string $arr['body'] The admin notification email body. + * @param string $this->settings['body'] The admin notification email body. */ - $arr['body'] = apply_filters( 'wpmem_email_notify', $arr['body'] ); - - // @todo The remainder is slated to be moved to an "email send" function. - // Apply from and from name email filters. - add_filter( 'wp_mail_from', array( $this, 'from' ) ); - add_filter( 'wp_mail_from_name', array( $this, 'from_name' ) ); + $this->settings['body'] = apply_filters( 'wpmem_email_notify', $this->settings['body'] ); // Send the message. - wp_mail( $arr['admin_email'], stripslashes( $arr['subj'] ), stripslashes( $arr['body'] ), $arr['headers'] ); - // @todo End of slated to be moved. + $this->send(); } } @@ -550,4 +492,16 @@ function from_name( $name ) { return ( $this->from_name ) ? stripslashes( $this->from_name ) : stripslashes( $name ); } + /** + * Sends email. + * + * @since 3.2.0 + */ + function send() { + // Apply WP's "from" and "from name" email filters. + add_filter( 'wp_mail_from', array( $this, 'from' ) ); + add_filter( 'wp_mail_from_name', array( $this, 'from_name' ) ); + // Send the message. + wp_mail( $this->settings['user_email'], stripslashes( $this->settings['subj'] ), stripslashes( $this->settings['body'] ), $this->settings['headers'] ); + } } \ No newline at end of file From 4fc89aee647054dd929392dfe33e9cf0c876ab72 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sat, 7 Apr 2018 10:25:21 -0500 Subject: [PATCH 0768/1694] preparing new register form api function, expanding arguments to be used --- inc/api-forms.php | 47 +++++++++++++++++++++++++++++ inc/class-wp-members-forms.php | 13 ++++++-- inc/class-wp-members-shortcodes.php | 20 +++++++++++- inc/class-wp-members.php | 1 + inc/forms.php | 6 ++-- 5 files changed, 82 insertions(+), 5 deletions(-) create mode 100644 inc/api-forms.php diff --git a/inc/api-forms.php b/inc/api-forms.php new file mode 100644 index 00000000..9cfcac74 --- /dev/null +++ b/inc/api-forms.php @@ -0,0 +1,47 @@ +forms->login_form( $args ); +} + +/** + * Invokes a registration or user profile update form. + * + * @since 3.2.0 + * + * @global object $wpmem + * @param array $args { + * Possible arguments for creating the form. + * + * @type string id + * @type string tag + * @type string form + * @type string product + * @type string include_fields + * @type string exclude_fields + * @type string redirect_to + * @type string heading + * } + * @return string $html + */ +function wpmem_register_form( $args ) { + global $wpmem; + return $wpmem->forms->register_form( $args ); +} diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 59a426f1..69a138b1 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -672,11 +672,20 @@ function login_form( $page, $arr ) { * @global object $wpmem The WP_Members object. * @global string $wpmem_regchk Used to determine if the form is in an error state. * @global array $userdata Used to get the user's registration data if they are logged in (user profile edit). - * @param string $tag (optional) Toggles between new registration ('new') and user profile edit ('edit'). + * @param mixed $mixed (optional) String toggles between new registration ('new') and user profile edit ('edit'), or array containing settings arguments. * @param string $heading (optional) The heading text for the form, null (default) for new registration. * @return string $form The HTML for the entire form as a string. */ - function register_form( $tag = 'new', $heading = '', $redirect_to = null ) { + function register_form( $mixed = 'new', $heading = '', $redirect_to = null ) { + + // Handle legacy use. + if ( is_array( $mixed ) ) { + $tag = $mixed['tag']; + $heading = $mixed['heading']; + $redirect_to = $mixed['redirect_to']; + } else { + $tag = $mixed; + } global $wpmem, $wpmem_regchk, $userdata; diff --git a/inc/class-wp-members-shortcodes.php b/inc/class-wp-members-shortcodes.php index 34098892..abc1a95d 100644 --- a/inc/class-wp-members-shortcodes.php +++ b/inc/class-wp-members-shortcodes.php @@ -61,11 +61,29 @@ function __construct() { * @since 3.0.0 * @since 3.1.3 Added forgot_username shortcode. * @since 3.2.0 Moved to WP_Members_Shortcodes::forms(). + * @since 3.2.0 Added id, exclude_fields, include_fields, and product attributes. + * + * @todo Complete support for id, exlude_fields, include_fields, and product attributes + * May require updates to core functions. * * @global object $wpmem The WP_Members object. * @global string $wpmem_themsg The WP-Members message container. * - * @param array $attr + * @param array $atts { + * Possible shortcode attributes (some vary by form). + * + * @type string $id An ID for the form. + * @type string $login Idenifies login form. + * @type string $password Idenifies reset/change password form (login state dependent). + * @type string $user_edit Idenifies user profile edit form. + * @type string $forgot_username Idenifies forgot username form. + * @type string $register Idenifies register form. + * @type string $redirect_to URL to redirect to on form submit. + * @type string $texturize Add/fix texturization for the from HTML. + * @type string $exclude_fields Fields to exclude (register/user_edit forms only). + * @type string $include_fields Fields to include (register/user_edit forms only). + * @type string $product Register for specific product (if products are enabled). + * } * @param string $content * @param string $tag * @return string $content diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index d335b33a..d12c454a 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -445,6 +445,7 @@ function load_dependencies() { require_once( WPMEM_PATH . 'inc/class-wp-members-shortcodes.php' ); require_once( WPMEM_PATH . 'inc/core.php' ); require_once( WPMEM_PATH . 'inc/api.php' ); + require_once( WPMEM_PATH . 'inc/api-forms.php' ); require_once( WPMEM_PATH . 'inc/utilities.php' ); require_once( WPMEM_PATH . 'inc/forms.php' ); require_once( WPMEM_PATH . 'inc/dialogs.php' ); diff --git a/inc/forms.php b/inc/forms.php index 83a50b21..c30e35b9 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -155,6 +155,7 @@ function wpmem_inc_forgotusername() { * * @since 2.5.1 * @since 3.1.7 Now a wrapper for $wpmem->forms->register_form() + * @since 3.2.0 Preparing for deprecation, use wpmem_register_form() instead. * * @global object $wpmem The WP_Members object. * @param string $tag (optional) Toggles between new registration ('new') and user profile edit ('edit'). @@ -162,8 +163,9 @@ function wpmem_inc_forgotusername() { * @return string $form The HTML for the entire form as a string. */ function wpmem_inc_registration( $tag = 'new', $heading = '', $redirect_to = null ) { - global $wpmem; - return $wpmem->forms->register_form( $tag, $heading, $redirect_to ); + global $wpmem; + $args = array( 'tag' => $tag, 'heading' => $heading, 'redirect_to' => $redirect_to ); + return $wpmem->forms->register_form( $args, $heading, $redirect_to ); } // End wpmem_inc_registration. endif; From 74ba631816d7287c84598c9834d22abc27591d62 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 9 Apr 2018 09:12:21 -0500 Subject: [PATCH 0769/1694] forms api debugging --- inc/api-forms.php | 4 ++-- inc/class-wp-members-forms.php | 11 ++++++++++- inc/forms.php | 6 ++++-- 3 files changed, 16 insertions(+), 5 deletions(-) diff --git a/inc/api-forms.php b/inc/api-forms.php index 9cfcac74..5a152e3b 100644 --- a/inc/api-forms.php +++ b/inc/api-forms.php @@ -16,10 +16,10 @@ * } * @return string $html */ -function wpmem_login_form( $args ) { +/*function wpmem_login_form( $args ) { global $wpmem; return $wpmem->forms->login_form( $args ); -} +}*/ /** * Invokes a registration or user profile update form. diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 69a138b1..022edc29 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -391,7 +391,16 @@ function file_upload_dir( $param ) { * } * @return string $form The HTML for the form as a string. */ - function login_form( $page, $arr ) { + function login_form( $mixed, $arr = array() ) { + + // Handle legacy use. + if ( is_array( $mixed ) ) { + $page = $mixed['page']; + $arr = $mixed; + } else { + $page = $mixed; + } + // Set up redirect_to @todo This could be done in a separate method usable by both login & reg. if ( isset( $_REQUEST['redirect_to'] ) ) { diff --git a/inc/forms.php b/inc/forms.php index c30e35b9..884e1dfd 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -126,7 +126,9 @@ function wpmem_inc_resetpassword() { */ function wpmem_login_form( $page, $arr ) { global $wpmem; - return $wpmem->forms->login_form( $page, $arr ); + $args = $arr; + $args['page'] = $page; + return $wpmem->forms->login_form( $args ); } endif; @@ -165,7 +167,7 @@ function wpmem_inc_forgotusername() { function wpmem_inc_registration( $tag = 'new', $heading = '', $redirect_to = null ) { global $wpmem; $args = array( 'tag' => $tag, 'heading' => $heading, 'redirect_to' => $redirect_to ); - return $wpmem->forms->register_form( $args, $heading, $redirect_to ); + return $wpmem->forms->register_form( $args ); } // End wpmem_inc_registration. endif; From 7b2dbafff1033011cfdf800fb2aacd03cd1751e0 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 18 Apr 2018 07:22:00 -0500 Subject: [PATCH 0770/1694] manage_users_custom_column is a filter, not an action --- admin/includes/class-wp-members-admin-api.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/includes/class-wp-members-admin-api.php b/admin/includes/class-wp-members-admin-api.php index 36c86db6..f0b54e73 100644 --- a/admin/includes/class-wp-members-admin-api.php +++ b/admin/includes/class-wp-members-admin-api.php @@ -125,7 +125,7 @@ function load_hooks() { add_action( 'admin_notices', 'wpmem_users_admin_notices' ); add_filter( 'views_users', 'wpmem_users_views' ); add_filter( 'manage_users_columns', 'wpmem_add_user_column' ); - add_action( 'manage_users_custom_column', 'wpmem_add_user_column_content', 10, 3 ); + add_filter( 'manage_users_custom_column', 'wpmem_add_user_column_content', 10, 3 ); add_action( 'wpmem_post_register_data', 'wpmem_set_new_user_non_active' ); add_action( 'wpmem_user_activated', 'wpmem_set_activated_user' ); add_action( 'wpmem_user_deactivated', 'wpmem_set_deactivated_user' ); From d6dbefe592698b101472e573d7092d0b17f932c5 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 18 Apr 2018 07:22:53 -0500 Subject: [PATCH 0771/1694] fix so that wpmem_register_form_rows_userprofile will also work --- inc/class-wp-members-user-profile.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/class-wp-members-user-profile.php b/inc/class-wp-members-user-profile.php index 07f4d8fa..5cd3c3f6 100644 --- a/inc/class-wp-members-user-profile.php +++ b/inc/class-wp-members-user-profile.php @@ -164,7 +164,7 @@ static function profile( $user_obj ) { * } * @param string $tag adminprofile|userprofile */ - $rows = apply_filters( 'wpmem_register_form_rows_admin', $rows, $display . 'profile' ); + $rows = apply_filters( 'wpmem_register_form_rows_' . $display, $rows, $display . 'profile' ); // Handle form rows display from array. foreach ( $rows as $row ) { From 6f9c8b1348a455ba7fdc79f36f7abd8a789c2f9a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 18 Apr 2018 07:23:34 -0500 Subject: [PATCH 0772/1694] cleanup in fields tab --- admin/tab-fields.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 19bb5df3..2afd4679 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -402,9 +402,9 @@ function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key ) function wpmem_a_render_fields_tab_field_table() { global $wpmem; - $wpmem_ut_fields_skip = array( 'user_email', 'confirm_email', 'password', 'confirm_password' ); + $wpmem_ut_fields_skip = array( 'username', 'user_email', 'confirm_email', 'password', 'confirm_password' ); $wpmem_ut_fields = get_option( 'wpmembers_utfields' ); - $wpmem_us_fields_skip = array( 'user_email', 'confirm_email', 'password', 'confirm_password' ); + $wpmem_us_fields_skip = array( 'username', 'user_email', 'confirm_email', 'password', 'confirm_password' ); $wpmem_us_fields = get_option( 'wpmembers_usfields' ); $wpmem_fields = get_option( 'wpmembers_fields', array() ); @@ -496,7 +496,7 @@ class WP_Members_Fields_Table extends WP_List_Table { private $excludes = array( 'user_registered', 'active', 'wpmem_reg_ip', 'exp_type', 'expires', 'user_id' ); - private $no_delete = array( 'user_email', 'first_name', 'last_name', 'user_url' ); + private $no_delete = array( 'username', 'user_email', 'first_name', 'last_name', 'user_url' ); /** * Checkbox at start of row. @@ -753,7 +753,7 @@ function wpmem_admin_fields_update() { // Error check for reserved terms. $reserved_terms = wpmem_wp_reserved_terms(); if ( in_array( strtolower( $add_option ), $reserved_terms ) ) { - $add_field_err_msg = sprintf( __( 'Sorry, "%s" is a reserved term. Field was not added.', 'wp-members' ), $submitted_term ); + $add_field_err_msg = sprintf( __( 'Sorry, "%s" is a reserved term. Field was not added.', 'wp-members' ), $add_option ); } // Error check option name for spaces and replace with underscores. From da9477bf7eae34df07da1d55fce3e1b282722619 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 20 Apr 2018 08:15:13 -0500 Subject: [PATCH 0773/1694] fix setting a post as hidden when first posted --- admin/post.php | 13 ++++++++++--- inc/class-wp-members.php | 24 ++++++++++++++++++------ 2 files changed, 28 insertions(+), 9 deletions(-) diff --git a/admin/post.php b/admin/post.php index 40f6e792..d0d087e9 100644 --- a/admin/post.php +++ b/admin/post.php @@ -259,17 +259,19 @@ function wpmem_block_meta_save( $post_id ) { if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) { return; } - // Quit if the nonce isn't there, or is wrong. if ( ! isset( $_POST['wpmem_block_meta_nonce'] ) || ! wp_verify_nonce( $_POST['wpmem_block_meta_nonce'], 'wpmem_block_meta_nonce' ) ) { return; } - + // Quit if it's a post revision + if ( false !== wp_is_post_revision( $post_id ) ) { + return; + } // Quit if the current user cannot edit posts. if ( ! current_user_can( 'edit_posts' ) ) { return; } - + // Get value. $block = ( isset( $_POST['wpmem_block'] ) ) ? sanitize_text_field( $_POST['wpmem_block'] ) : null; @@ -387,6 +389,11 @@ function wpmem_set_block_status( $status, $post_id, $post_type ) { } else { delete_post_meta( $post_id, '_wpmem_block' ); } + + // If the value is to hide, delete the transient so that it updates. + if ( 2 == $status || ( 2 == $prev_value && $status != $prev_value ) ) { + $wpmem->update_hidden_posts(); + } } // End of File. \ No newline at end of file diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index d12c454a..b34935ba 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -863,16 +863,28 @@ function hidden_posts() { global $wpdb; $hidden = get_transient( '_wpmem_hidden_posts' ); if ( false === $hidden ) { - $sql = "SELECT post_id FROM " . $wpdb->prefix . "postmeta WHERE meta_key = '_wpmem_block' AND meta_value = 2"; - $results = $wpdb->get_results( $sql ); - foreach( $results as $result ) { - $hidden[] = $result->post_id; - } - set_transient( '_wpmem_hidden_posts', $hidden, 60*5 ); + $this->update_hidden_posts(); } return $hidden; } + /** + * Updates the hidden post array transient. + * + * @since 3.2.0 + * + * @global object $wpdb + */ + function update_hidden_posts() { + global $wpdb; + $sql = "SELECT post_id FROM " . $wpdb->prefix . "postmeta WHERE meta_key = '_wpmem_block' AND meta_value = 2"; + $results = $wpdb->get_results( $sql ); + foreach( $results as $result ) { + $hidden[] = $result->post_id; + } + set_transient( '_wpmem_hidden_posts', $hidden, 60*5 ); + } + /** * Gets an array of hidden post IDs. * From 75818b377c913b71affa3c0a931ec9b3c22a5870 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 20 Apr 2018 08:15:49 -0500 Subject: [PATCH 0774/1694] wpmem_default_text_strings set back to not passing $defaults for compatibility reasons --- inc/class-wp-members.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index b34935ba..cd6490be 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -1247,11 +1247,11 @@ function get_text( $str ) { * Filter default terms. * * @since 3.1.0 - * @since 3.2.0 Passes $defaults param as a required element. - * - * @param array $defaults (required) */ - $text = apply_filters( 'wpmem_default_text_strings', $defaults ); + $text = apply_filters( 'wpmem_default_text_strings', '' ); + + // Merge filtered $terms with $defaults. + $text = wp_parse_args( $text, $defaults ); // Return the requested text string. return $text[ $str ]; From e6b4cdfb8026fade6ab285dd75c93093bb5784eb Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 20 Apr 2018 08:16:34 -0500 Subject: [PATCH 0775/1694] cleanup --- inc/class-wp-members-user.php | 2 +- inc/forms.php | 2 +- readme.txt | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members-user.php b/inc/class-wp-members-user.php index 330c717e..13c99d80 100644 --- a/inc/class-wp-members-user.php +++ b/inc/class-wp-members-user.php @@ -457,7 +457,7 @@ public function update_user_role( $user_id, $role, $action = 'change' ) { } /** - * Sets user as logged on on password change. + * Sets user as logged on password change. * * (Hooked to wpmem_pwd_change) * diff --git a/inc/forms.php b/inc/forms.php index 884e1dfd..67729eba 100644 --- a/inc/forms.php +++ b/inc/forms.php @@ -49,7 +49,7 @@ */ function wpmem_inc_login( $page = "page", $redirect_to = null, $show = 'show' ) { global $wpmem; - return $wpmem->forms->do_login_form( $page = "page", $redirect_to = null, $show = 'show' ); + return $wpmem->forms->do_login_form( $page, $redirect_to, $show ); } endif; diff --git a/readme.txt b/readme.txt index df90ba6b..9e21e610 100644 --- a/readme.txt +++ b/readme.txt @@ -137,6 +137,7 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum = 3.2.0 = +* Tested and compatible with Gutenberg. * Changed default address meta fields to WooCommerce billing meta keys. * Removed language packs that install from wordpress.org (de_DE, hu_HU, ja, nl_NL, pt_BR, ru_RU, and sv_SE). * All remaining user facing strings in get_text() added wp-members textdomain. From 422451d05e8e9b2886fcd6000ca44907b1d776a4 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 23 Apr 2018 10:14:45 -0500 Subject: [PATCH 0776/1694] added placeholder, rows, and cols support for textarea --- admin/js/admin.js | 2 ++ admin/tab-fields.php | 17 +++++++++++++++++ inc/api.php | 2 ++ inc/class-wp-members-forms.php | 9 ++++++--- readme.txt | 1 + 5 files changed, 28 insertions(+), 3 deletions(-) diff --git a/admin/js/admin.js b/admin/js/admin.js index c46a70fd..b9042deb 100644 --- a/admin/js/admin.js +++ b/admin/js/admin.js @@ -134,8 +134,10 @@ } if ($("#wpmem_field_type_select").val() == 'textarea' ) $("#wpmem_allowhtml").show(); + $("#wpmem_rows_cols").show(); else $("#wpmem_allowhtml").hide(); + $("#wpmem_rows_cols").hide(); if ($("#wpmem_field_type_select").val() == 'number' || $("#wpmem_field_type_select").val() == 'date' ) $("#wpmem_min_max").show(); else diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 2afd4679..98bac4ff 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -281,6 +281,18 @@ function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key ) ' : ''; ?> + + ' : ''; ?> +
  • + + +
  • +
  • + + +
  • + ' : ''; ?> + ' : ''; ?>
  • @@ -784,6 +796,11 @@ function wpmem_admin_fields_update() { $arr['min'] = filter_var( wpmem_get( 'add_min' ), FILTER_SANITIZE_NUMBER_INT ); $arr['max'] = filter_var( wpmem_get( 'add_max' ), FILTER_SANITIZE_NUMBER_INT ); } + + if ( 'textarea' == $type ) { + $arr['rows'] = filter_var( wpmem_get( 'add_rows' ), FILTER_SANITIZE_NUMBER_INT ); + $arr['cols'] = filter_var( wpmem_get( 'add_cols' ), FILTER_SANITIZE_NUMBER_INT ); + } if ( $type == 'checkbox' ) { $add_field_err_msg = ( ! $_POST['add_checked_value'] ) ? __( 'Checked value is required for checkboxes. Nothing was updated.', 'wp-members' ) : $add_field_err_msg; diff --git a/inc/api.php b/inc/api.php index d94ad869..6ef6be88 100644 --- a/inc/api.php +++ b/inc/api.php @@ -189,6 +189,8 @@ function wpmem_current_url( $slash = true, $getq = true ) { * @type string $title (optional) Defines the title attribute. * @type string $min (optional) Adds a min attribute (HTML5). * @type string $max (optional) Adds a max attribute (HTML5). + * @type string $rows (optional) Adds rows attribute to textarea. + * @type string $cols (optional) Adds cols attribute to textarea. * } * @param string $type The field type. * @param string $value The default value for the field. diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 022edc29..83b17928 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -118,9 +118,10 @@ function create_form_field( $args ) { case "textarea": $value = esc_textarea( stripslashes( $value ) ); // stripslashes( esc_textarea( $value ) ); $class = ( 'textbox' == $class ) ? "textarea" : $this->sanitize_class( $class ); - $rows = ( isset( $args['rows'] ) ) ? esc_attr( $args['rows'] ) : '5'; - $cols = ( isset( $args['cols'] ) ) ? esc_attr( $args['cols'] ) : '20'; - $str = ""; + $placeholder = ( $placeholder ) ? ' placeholder="' . esc_attr( $placeholder ) . '"' : ''; + $rows = ( isset( $args['rows'] ) && $args['rows'] ) ? esc_attr( $args['rows'] ) : '5'; + $cols = ( isset( $args['cols'] ) && $args['cols'] ) ? esc_attr( $args['cols'] ) : '20'; + $str = ""; break; case "hidden": @@ -954,6 +955,8 @@ function register_form( $mixed = 'new', $heading = '', $redirect_to = null ) { 'title' => ( isset( $field['title'] ) ) ? $field['title'] : false, 'min' => ( isset( $field['min'] ) ) ? $field['min'] : false, 'max' => ( isset( $field['max'] ) ) ? $field['max'] : false, + 'rows' => ( isset( $field['rows'] ) ) ? $field['rows'] : false, + 'cols' => ( isset( $field['cols'] ) ) ? $field['cols'] : false, ); if ( 'multicheckbox' == $field['type'] || 'multiselect' == $field['type'] ) { $formfield_args['delimiter'] = $field['delimiter']; diff --git a/readme.txt b/readme.txt index 9e21e610..39495fd6 100644 --- a/readme.txt +++ b/readme.txt @@ -168,6 +168,7 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * HTML5 update - form anchor tags changed from "name" to "id". * HTML5 update - form id tags set default value (can still be filtered). * HTML5 update - removed "align" attribute (captcha, link-text). +* Added placeholder, rows, and cols attribute support for textarea field settings. * Moved remaining core functions to appropriate object classes, left wrappers for most. * Added new email class and shortcode class to replace previous functions/files. * Added link_span_before/link_span_after wrapper for login link text. From ab148b26024ec5c3c3ddff3eec0f8f448a1517ef Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 23 Apr 2018 15:27:58 -0500 Subject: [PATCH 0777/1694] fix wpmem_field shortcode when date field is displayed and field has empty value --- inc/class-wp-members-shortcodes.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members-shortcodes.php b/inc/class-wp-members-shortcodes.php index abc1a95d..7a8cf73a 100644 --- a/inc/class-wp-members-shortcodes.php +++ b/inc/class-wp-members-shortcodes.php @@ -586,10 +586,10 @@ function fields( $atts, $content = null, $tag ) { if ( isset( $field_type ) && 'date' == $field_type ) { if ( isset( $atts['format'] ) ) { // Formats date: http://php.net/manual/en/function.date.php - $result = date( $atts['format'], strtotime( $user_info->{$field} ) ); + $result = ( '' != $user_info->{$field} ) ? date( $atts['format'], strtotime( $user_info->{$field} ) ) : ''; } else { // Formats date to whatever the WP setting is. - $result = date_i18n( get_option( 'date_format' ), strtotime( $user_info->{$field} ) ); + $result = ( '' != $user_info->{$field} ) ? date_i18n( get_option( 'date_format' ), strtotime( $user_info->{$field} ) ) : ''; } } From d7530450f978f13775cb9eabc2d3ffafd285a70a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 23 Apr 2018 15:29:32 -0500 Subject: [PATCH 0778/1694] fixes for handling hidden posts and product access --- inc/class-wp-members-products.php | 49 ++++++++++++++++++++++++++----- inc/class-wp-members.php | 4 +-- 2 files changed, 43 insertions(+), 10 deletions(-) diff --git a/inc/class-wp-members-products.php b/inc/class-wp-members-products.php index df2c9311..41ffd218 100644 --- a/inc/class-wp-members-products.php +++ b/inc/class-wp-members-products.php @@ -26,7 +26,7 @@ function __construct() { $this->load_products(); - add_filter( 'wpmem_securify', array( $this, 'check_access' ) ); + add_filter( 'wpmem_securify', array( $this, 'product_access' ) ); } function load_products() { @@ -44,12 +44,37 @@ function load_products() { * * @since 3.2.0 * - * @global object $post * @global object $wpmem * @param string $content * @return string $content */ - function check_access( $content ) { + function product_access( $content ) { + + global $wpmem; + // Is the user logged in and is this blocked content? + if ( is_user_logged_in() && wpmem_is_blocked() ) { + $access = $this->check_product_access(); + // Handle content. + $content = ( $access ) ? $content : $wpmem->get_text( 'product_restricted' ); + // Handle comments. + if ( ! $access ) { + add_filter( 'wpmem_securify_comments', '__return_false' ); + } + } + // Return unfiltered content for all other cases. + return $content; + } + + /** + * Checks access restriction by product. + * + * @since 3.2.0 + * + * @global object $post + * @global object $wpmem + * @return boolean true if user has access, otherwise false. + */ + function check_product_access() { global $post, $wpmem; // Is the user logged in and is this blocked content? @@ -60,18 +85,26 @@ function check_access( $content ) { if ( $post_products ) { // @todo This is the nuts and bolts - work around whether a user has access // to this product or not. - if ( $wpmem->user->has_access( $post_products ) ) { - return $content; + /** + * Filter whether the user has access or not. + * + * @since 3.2.0 + * + * @param boolean $user_has_access + */ + $user_has_access = apply_filters( 'wpmem_user_has_access', $wpmem->user->has_access( $post_products ) ); + if ( $user_has_access ) { + return true; } // The error message for invalid users. - return $wpmem->get_text( 'product_restricted' ); + return false; } else { // Content that has no product restriction. - return $content; + return true; } } // Return unfiltered content for all other cases. - return $content; + return true; } /** diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index cd6490be..8b8ca31b 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -877,8 +877,8 @@ function hidden_posts() { */ function update_hidden_posts() { global $wpdb; - $sql = "SELECT post_id FROM " . $wpdb->prefix . "postmeta WHERE meta_key = '_wpmem_block' AND meta_value = 2"; - $results = $wpdb->get_results( $sql ); + $hidden = array(); + $results = $wpdb->get_results( "SELECT post_id FROM " . $wpdb->prefix . "postmeta WHERE meta_key = '_wpmem_block' AND meta_value = 2" ); foreach( $results as $result ) { $hidden[] = $result->post_id; } From 12d379168b09800f3c89d098a8d3d94012991f90 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 23 Apr 2018 21:35:05 -0500 Subject: [PATCH 0779/1694] fix logged in shortcode for meta key/value pair attribute --- inc/class-wp-members-shortcodes.php | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/inc/class-wp-members-shortcodes.php b/inc/class-wp-members-shortcodes.php index 7a8cf73a..1600a987 100644 --- a/inc/class-wp-members-shortcodes.php +++ b/inc/class-wp-members-shortcodes.php @@ -179,18 +179,15 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { } /** - * Handles the logged in status shortcodes. + * Handles the logged in status shortcodes [wpmem_logged_in]. * - * There are two shortcodes to display content based on a user being logged - * in - [wp-members status=in] and [wpmem_logged_in] (status=in is a legacy - * shortcode, but will still function). There are several attributes that - * can be used with the shortcode: in|out, sub for subscription only info, - * id, and role. IDs and roles can be comma separated values for multiple - * users and roles. Additionally, status=out can be used to display content - * only to logged out users or visitors. + * There are several attributes that can be used with the shortcode: + * in|out, sub for subscription only info, id, and role. IDs and roles + * can be comma separated values for multiple users and roles. * * @since 3.0.0 * @since 3.2.0 Moved to WP_Members_Shortcodes::logged_in(). + * @since 3.2.0 Added attributes for meta key/value pairs. * * @global object $wpmem The WP_Members object. * @@ -201,6 +198,8 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { * @type int $id * @type string $role * @type string $sub + * @type string $meta_key + * @type string $meta_value * } * @param string $content * @param string $tag @@ -261,7 +260,7 @@ function logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) { // If there is a meta key attribute. if ( isset( $atts['meta_key'] ) ) { - $value = ( isset( $atts['meta_value'] ) ) ? $atta['meta_value'] : false; + $value = ( isset( $atts['meta_value'] ) ) ? $atts['meta_value'] : false; if ( wpmem_user_has_meta( $atts['meta_key'], $value ) ) { $do_return = true; } From 102544f9da07c39e1147b54a00122e9ed098cabf Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 29 Apr 2018 19:43:41 -0500 Subject: [PATCH 0780/1694] fixed bug where native fields set to non-native when labels were updated --- admin/tab-fields.php | 9 ++++++--- readme.txt | 2 +- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/admin/tab-fields.php b/admin/tab-fields.php index 98bac4ff..820f8ce6 100644 --- a/admin/tab-fields.php +++ b/admin/tab-fields.php @@ -184,14 +184,14 @@ function wpmem_a_render_fields_tab_field_edit( $mode, $wpmem_fields, $meta_key )
    • - +
    • $meta_key"; ?> - + @@ -781,7 +781,10 @@ function wpmem_admin_fields_update() { $arr[3] = $type; $arr[4] = ( 'y' == wpmem_get( 'add_display', 'n' ) ) ? 'y' : 'n'; $arr[5] = ( 'y' == wpmem_get( 'add_required', 'n' ) ) ? 'y' : 'n'; - $arr[6] = ( $us_option == 'user_nicename' || $us_option == 'display_name' || $us_option == 'nickname' ) ? 'y' : 'n'; + + // Mark native fields: + $native_fields = array( 'user_login', 'user_pass', 'user_nicename', 'user_email', 'user_url', 'user_registered', 'display_name', 'first_name', 'last_name', 'nickname', 'description' ); + $arr[6] = ( in_array( $us_option, $native_fields ) ) ? 'y' : 'n'; if ( 'text' == $type || 'email' == $type || 'textarea' == $type || 'password' == $type || 'url' == $type || 'number' == $type || 'date' == $type ) { $arr['placeholder'] = sanitize_text_field( stripslashes( wpmem_get( 'add_placeholder' ) ) ); diff --git a/readme.txt b/readme.txt index 39495fd6..19b8790e 100644 --- a/readme.txt +++ b/readme.txt @@ -173,7 +173,7 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * Added new email class and shortcode class to replace previous functions/files. * Added link_span_before/link_span_after wrapper for login link text. * Updated "TOS" text to "Terms of Service". - +* Fixed a bug that caused WP native fields to be set as non-native when labels were updated in the fields tab. = 3.1.9 = From 3b8d65a26492ceb3302fc09c9d238386f77ae2a4 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Fri, 4 May 2018 10:11:57 -0500 Subject: [PATCH 0781/1694] allow tos text label to be edited (filter still takes priority) --- inc/class-wp-members-forms.php | 14 +++++++++++++- inc/class-wp-members.php | 2 +- readme.txt | 2 +- wp-members-install.php | 2 +- 4 files changed, 16 insertions(+), 4 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 83b17928..a3d324be 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -899,7 +899,19 @@ function register_form( $mixed = 'new', $heading = '', $redirect_to = null ) { */ $tos_link_text = apply_filters( 'wpmem_tos_link_txt', $wpmem->get_text( 'register_tos' ), $tag ); - $input.= sprintf( $tos_link_text, $tos_pop, '' ); + // If filtered value is not the default label, use that, otherwise use label. + if ( __( 'Please indicate that you agree to the %s Terms of Service %s', 'wp-members' ) == $tos_link_text ) { + if ( 'TOS' != $field['label'] ) { + $tos_link_text = $field['label']; + } + } + + // If tos string does not contain link identifiers (%s), wrap the whole string. + if ( ! strpos( $tos_link_text, '%s' ) ) { + $tos_link_text = '%s' . $tos_link_text . '%s'; + } + + $input .= ' ' . sprintf( $tos_link_text, $tos_pop, '' ); // In previous versions, the div class would end up being the same as the row before. $field_before = ( $args['wrap_inputs'] ) ? '
      ' : ''; diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 8b8ca31b..d9f4bbfc 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -1178,7 +1178,7 @@ function get_text( $str ) { 'register_heading' => __( 'New User Registration', 'wp-members' ), 'register_username' => __( 'Choose a Username', 'wp-members' ), 'register_rscaptcha' => __( 'Input the code:', 'wp-members' ), - 'register_tos' => __( 'Please indicate that you agree to the %s TOS %s', 'wp-members' ), + 'register_tos' => __( 'Please indicate that you agree to the %s Terms of Service %s', 'wp-members' ), // @note: if default changes, default check after wpmem_tos_link_txt must change. 'register_clear' => __( 'Reset Form', 'wp-members' ), 'register_submit' => __( 'Register', 'wp-members' ), 'register_req_mark' => '*', diff --git a/readme.txt b/readme.txt index 19b8790e..8dc1a6ff 100644 --- a/readme.txt +++ b/readme.txt @@ -172,7 +172,7 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * Moved remaining core functions to appropriate object classes, left wrappers for most. * Added new email class and shortcode class to replace previous functions/files. * Added link_span_before/link_span_after wrapper for login link text. -* Updated "TOS" text to "Terms of Service". +* Updated "TOS" text to accept a custom label (priority to filtered label with wpmem_tos_link_txt). * Fixed a bug that caused WP native fields to be set as non-native when labels were updated in the fields tab. = 3.1.9 = diff --git a/wp-members-install.php b/wp-members-install.php index 1849dc03..682c224f 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -557,7 +557,7 @@ function wpmem_install_fields() { array( 13, 'Biographical Info', 'description', 'textarea', 'n', 'n', 'y' ), array( 14, 'Password', 'password', 'password', 'n', 'n', 'n' ), array( 15, 'Confirm Password', 'confirm_password', 'password', 'n', 'n', 'n' ), - array( 16, 'Terms of Service', 'tos', 'checkbox', 'n', 'n', 'n', 'agree', 'n' ), + array( 16, 'TOS', 'tos', 'checkbox', 'n', 'n', 'n', 'agree', 'n' ), ); update_option( 'wpmembers_fields', $fields, '', 'yes' ); // using update_option to allow for forced update return $fields; From bcb2d67c2f0d4da12272ac96f2a4c5df07ca4124 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 30 May 2018 09:40:19 -0500 Subject: [PATCH 0782/1694] rework users screen: translation, queries, added deactivated filter --- admin/users.php | 87 +++++++++++++++++++++---------------------------- 1 file changed, 38 insertions(+), 49 deletions(-) diff --git a/admin/users.php b/admin/users.php index ef42a1df..1d800a14 100644 --- a/admin/users.php +++ b/admin/users.php @@ -45,11 +45,13 @@ function wpmem_bulk_user_action() { Date: Wed, 6 Jun 2018 14:28:26 -0500 Subject: [PATCH 0795/1694] changes to product cpt meta --- .../class-wp-members-products-admin.php | 94 ++++++++++--------- inc/class-wp-members-products.php | 13 ++- wp-members.php | 4 +- 3 files changed, 62 insertions(+), 49 deletions(-) diff --git a/admin/includes/class-wp-members-products-admin.php b/admin/includes/class-wp-members-products-admin.php index e6494dc1..0820c92a 100644 --- a/admin/includes/class-wp-members-products-admin.php +++ b/admin/includes/class-wp-members-products-admin.php @@ -65,12 +65,12 @@ function columns_content( $column, $post_id ) { echo $post->post_name; break; case 'role': - $role = $this->get_meta( 'membership_product_role' ); + $role = $this->get_meta( 'wpmem_product_role' ); echo ( $role ) ? $role : __( 'No role required', 'wp-members' ); break; case 'expires': - $number = $this->get_meta( 'membership_product_number_of_periods' ); - $period = $this->get_meta( 'membership_product_time_period' ); + $number = $this->get_meta( 'wpmem_product_number_of_periods' ); + $period = $this->get_meta( 'wpmem_product_time_period' ); echo ( $number ) ? $number . ' ' . $period : __( 'Does not expire', 'wp-members' ); break; case 'last_updated': @@ -123,53 +123,52 @@ function meta_boxes() { */ function details_html( $post ) { $periods = array( __( 'Period', 'wp-members' ) . '|', __( 'Day', 'wp-members' ) . '|d', __( 'Week', 'wp-members' ) . '|w', __( 'Month', 'wp-members' ) . '|m', __( 'Year', 'wp-members' ) . '|y' ); - $show_role_detail = ( $this->get_meta( 'membership_product_role_required' ) === 'role-required' ) ? 'show' : 'hide'; - $show_exp_detail = ( $this->get_meta( 'membership_product_expires' ) === 'expires' ) ? 'show' : 'hide'; ?> -
      - -

      - - + $show_role_detail = ( false !== $this->get_meta( 'wpmem_product_role' ) ) ? 'show' : 'hide'; + $show_exp_detail = ( false !== $this->get_meta( 'wpmem_product_expires' ) ) ? 'show' : 'hide'; ?> + + +

      + +

      -

      - get_meta( 'membership_product_role_required' ) === 'role-required' ) ? 'checked' : ''; ?>> - - - get_meta( 'wpmem_product_role' ) ) ? 'checked' : ''; ?>> + + +

      -

      - get_meta( 'membership_product_expires' ) === 'expires' ) ? 'checked' : ''; ?>> - - - - - - 'membership_product_time_period', 'type'=>'select', 'value'=>$periods, 'compare'=>$this->get_meta( 'membership_product_time_period' ) ) ); ?> +

      + get_meta( 'wpmem_product_expires' ) ) ? 'checked' : ''; ?>> + + + + + + 'wpmem_product_time_period', 'type'=>'select', 'value'=>$periods, 'compare'=>$this->get_meta( 'wpmem_product_time_period' ) ) ); ?>

      -
      add_section( 'wp_members' , array( + 'title' => 'WP-Members', + 'priority' => 190, + ) ); + + // Add settings for output description + $wp_customize->add_setting( 'show_logged_out_state', array( + 'default' => '1', + 'type' => 'theme_mod', //'option' + 'capability' => 'edit_theme_options', + 'transport' => 'refresh', + ) ); + + // Add control and output for select field + $wp_customize->add_control( 'show_form_logged_out', array( + 'label' => __( 'Show forms as logged out', 'wp-members' ), + 'section' => 'wp_members', + 'settings' => 'show_logged_out_state', + 'type' => 'checkbox', + 'std' => '1' + ) ); + } } // End of WP_Members class. \ No newline at end of file diff --git a/readme.txt b/readme.txt index 6c08e23d..2bcb7e35 100644 --- a/readme.txt +++ b/readme.txt @@ -176,7 +176,7 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * Updated "TOS" text to accept a custom label (priority to filtered label with wpmem_tos_link_txt). * Updated all processing involving "TOS" to better exclude the field on profile update (if saved value equals the field's checked value). * Fixed a bug that caused WP native fields to be set as non-native when labels were updated in the fields tab. -* Shortcodes and options to display forms while logged in (for use with Customizer and working with CSS). +* Added Customizer control to display login, register, and widget forms when using the Customizer (easier to work on custom CSS). * Added login/out menu item. = 3.1.9 = From d596631aefeb5f92df6b60465da04fdf2daeee5b Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 1 Jul 2018 19:57:55 -0400 Subject: [PATCH 0807/1694] added wpmem_do_expmessage filter --- inc/class-wp-members.php | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index 5c3ef436..cb62dd46 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -759,8 +759,17 @@ function do_securify( $content = null ) { // Protects comments if expiration module is used and user is expired. } elseif ( is_user_logged_in() && $this->is_blocked() == true ){ - $content = ( $this->use_exp == 1 && function_exists( 'wpmem_do_expmessage' ) ) ? wpmem_do_expmessage( $content ) : $content; - + if ( $this->use_exp == 1 && function_exists( 'wpmem_do_expmessage' ) ) { + /** + * Filters the user expired message used by the PayPal extension. + * + * @since 3.2.0 + * + * @param string $message + * @param string $content + */ + $content = apply_filters( 'wpmem_do_expmessage', wpmem_do_expmessage( $content ), $content ); + } } } From fbbb9ea4bfb103ab6591c8657922c47c7e86bf6e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Sun, 1 Jul 2018 20:53:56 -0400 Subject: [PATCH 0808/1694] modified product handling --- inc/class-wp-members-user-profile.php | 44 +++++++++++++++++---------- inc/class-wp-members-user.php | 19 ++++++++++++ 2 files changed, 47 insertions(+), 16 deletions(-) diff --git a/inc/class-wp-members-user-profile.php b/inc/class-wp-members-user-profile.php index 04ad4c98..aecedf3e 100644 --- a/inc/class-wp-members-user-profile.php +++ b/inc/class-wp-members-user-profile.php @@ -331,22 +331,20 @@ static function update( $user_id ) { if ( 1 == $wpmem->enable_products ) { // Update products. if ( isset( $_POST['_wpmem_membership_product'] ) ) { - - foreach ( $_POST['_wpmem_membership_product'] as $product_key ) { - // Does product require a role? - if ( false !== $wpmem->membership->product_detail[ $product_key ]['role'] ) { - //echo 'set role for ' . $product_key . "
      "; - wpmem_update_user_role( $user_id, $wpmem->membership->product_detail[ $product_key ]['role'], 'add' ); + foreach ( $_POST['_wpmem_membership_product'] as $product_key => $product_value ) { + // Enable or Disable? + if ( 'enable' == $product_value ) { + // Does product require a role? + if ( false !== $wpmem->membership->product_detail[ $product_key ]['role'] ) { + wpmem_update_user_role( $user_id, $wpmem->membership->product_detail[ $product_key ]['role'], 'add' ); + } + $wpmem->user->set_user_product( $product_key, $user_id ); + } + if ( 'disable' == $product_value ) { + $wpmem->user->remove_user_product( $product_key, $user_id ); } - // Does product expire? - //if ( false !== $wpmem->membership->product_detail[ $product_key ]['expires'] ) { - // echo 'set expiration for ' . $product_key . "
      "; - //} - $wpmem->user->set_user_product( $product_key, $user_id ); } } - //global $wpmem; - //echo '
      '; print_r( $wpmem->membership );
       			}
       		}
       
      @@ -482,9 +480,23 @@ public static function _show_product( $user_id ) {
       			foreach ( $wpmem->membership->products as $key => $label ) {
       				$checked = ( $user_products && array_key_exists( $key, $user_products ) ) ? "checked" : "";
       				echo "";
      -				echo '' . $label . "";
      -				echo ( isset( $user_products[ $key ] ) && $user_products[ $key ] !== true && $user_products[ $key ] != '' ) ? 'expires: ' . $user_products[ $key ] . '': ' ';
      -				echo '';
      +				echo '
      +				' . $label . '
      +				';
      +				if ( isset( $user_products[ $key ] ) ) {
      +					if ( $user_products[ $key ] !== true ) {
      +						echo __( 'Expires:', 'wp-members' ) . ' ' . $user_products[ $key ];
      +					} else {
      +						_e( 'Enabled', 'wp-members' );
      +					}
      +				} else {
      +					echo " ";
      +				}
      +				echo '';
       			}
       				?>
       		
      diff --git a/inc/class-wp-members-user.php b/inc/class-wp-members-user.php
      index 0b7765cc..8ec230bb 100644
      --- a/inc/class-wp-members-user.php
      +++ b/inc/class-wp-members-user.php
      @@ -549,6 +549,25 @@ function set_user_product( $product, $user_id = false ) {
       		return update_user_meta( $user_id, '_wpmem_products', $user_products );
       	}
       	
      +	/**
      +	 * Removes a product from a user.
      +	 *
      +	 * @since 3.2.0
      +	 *
      +	 * @param string $product
      +	 * @param int    $user_id
      +	 */
      +	function remove_user_product( $product, $user_id = false ) {
      +		global $wpmem;
      +		$user_id = ( ! $user_id ) ? get_current_user_id() : $user_id;
      +		$user_products = $this->get_user_products( $user_id );
      +		if ( $user_products ) {
      +			unset( $user_products[ $product ] );
      +			update_user_meta( $user_id, '_wpmem_products', $user_products );
      +		}
      +		return;
      +	}
      +	
       	/**
       	 * Utility for expiration validation.
       	 *
      
      From b4973a49a70571f9dabcf81c20b021f926f731b4 Mon Sep 17 00:00:00 2001
      From: Chad Butler 
      Date: Sun, 1 Jul 2018 20:55:53 -0400
      Subject: [PATCH 0809/1694] 3.2.0 beta release candidate 2
      
      ---
       wp-members.php | 4 ++--
       1 file changed, 2 insertions(+), 2 deletions(-)
      
      diff --git a/wp-members.php b/wp-members.php
      index 1456e4f6..297cadfe 100644
      --- a/wp-members.php
      +++ b/wp-members.php
      @@ -3,7 +3,7 @@
       Plugin Name: WP-Members
       Plugin URI:  https://rocketgeek.com
       Description: WP access restriction and user registration.  For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com.
      -Version:     3.2.0.rc.1
      +Version:     3.2.0.rc.2
       Author:      Chad Butler
       Author URI:  http://butlerblog.com/
       Text Domain: wp-members
      @@ -66,7 +66,7 @@
       }
       
       // Initialize constants.
      -define( 'WPMEM_VERSION', '3.2.0.rc.1' );
      +define( 'WPMEM_VERSION', '3.2.0.rc.2' );
       define( 'WPMEM_DEBUG', false );
       define( 'WPMEM_DIR',  plugin_dir_url ( __FILE__ ) );
       define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) );
      
      From 131ae15fba8399fcb881e548ec9cacf7cd5e0711 Mon Sep 17 00:00:00 2001
      From: Chad Butler 
      Date: Tue, 3 Jul 2018 08:07:39 -0400
      Subject: [PATCH 0810/1694] fix where password fields were removed when in
       register error
      
      ---
       inc/register.php | 8 +++++---
       1 file changed, 5 insertions(+), 3 deletions(-)
      
      diff --git a/inc/register.php b/inc/register.php
      index a85b14a6..e0a49a92 100644
      --- a/inc/register.php
      +++ b/inc/register.php
      @@ -121,9 +121,11 @@ function wpmem_registration( $tag ) {
       	 */
       	$wpmem->user->post_data = apply_filters( 'wpmem_pre_validate_form', $wpmem->user->post_data, $tag );
       
      -	$pass_arr = ( 'update' == $tag ) ? array( 'username', 'password', 'confirm_password', 'password_confirm' ) : array( 'password', 'confirm_password', 'password_confirm' );
      -	foreach ( $pass_arr as $pass ) {
      -		unset( $wpmem->fields[ $pass ] );
      +	if ( 'update' == $tag ) {
      +		$pass_arr = array( 'username', 'password', 'confirm_password', 'password_confirm' );
      +		foreach ( $pass_arr as $pass ) {
      +			unset( $wpmem->fields[ $pass ] );
      +		}
       	}
       	
       	// Check for required fields, reverse the array for logical error message order.
      
      From 826b59c68d3ca09955a8b704925a73d9365e1025 Mon Sep 17 00:00:00 2001
      From: Chad Butler 
      Date: Tue, 3 Jul 2018 08:10:01 -0400
      Subject: [PATCH 0811/1694] 3.2.0 beta release candidate 3
      
      ---
       readme.txt     | 65 ++++++++++++++++++++++----------------------------
       wp-members.php |  4 ++--
       2 files changed, 30 insertions(+), 39 deletions(-)
      
      diff --git a/readme.txt b/readme.txt
      index 2bcb7e35..6d0ae9e3 100644
      --- a/readme.txt
      +++ b/readme.txt
      @@ -6,20 +6,18 @@ Tested up to: 4.9
       Stable tag: 3.2.0
       License: GPLv2
       
      -WP-Members membership plugin turns your WordPress site into a membership site.  Restrict premium content, create custom registration fields, and more.
      +The WP-Members membership plugin turns your WordPress site into a membership site. Restrict premium content, create custom registration fields, and more.
       
       == Description ==
       
       === Membership Sites. Simplified. ===
       
      -You need a membership site. You want to focus on your business, not mastering a plugin. WP-Members is simple to use, yet flexible in every way imaginable.
      +You need a membership site, but you want to focus on your business, not mastering a plugin. WP-Members is simple to use, easy to set up, yet flexible in every way imaginable.
       
      -The plugin restricts selected WordPress® content to registered site members.  WP-Members™ puts the registration process on the site front end so it is inline with your content rather than the native WP login page.  WP-Members™ requires __no__ modifications to your theme while remainging scalable for users who want to customize the look and feel, or want to restrict only some content.  It is a great tool for sites offering premium content to subscribers, and is adaptable to a variety of applications.
      +The plugin restricts selected WordPress content to registered site members. WP-Members puts the registration process on the site front end so it is part of your content instead of the native WP login page. WP-Members requires no modifications to your theme while remaining scalable for users who want to customize the look and feel, or want to restrict only some content. It is a great tool for sites offering premium content to subscribers and is adaptable to a variety of applications.
       
       Simple to install and configure - yet customizable and scalable!
       
      -[youtube http://www.youtube.com/watch?v=x4MEoRLSY_U]
      -
       = Features: =
       
       * Block posts, pages, and custom post types
      @@ -29,85 +27,78 @@ Simple to install and configure - yet customizable and scalable!
       * Notify admin of new user registrations
       * Hold new registrations for admin approval
       * Create post excerpt teaser content automatically
      -* More than 100 action and filter hooks for extensibility
      +* More than 120 action and filter hooks for customization
      +* A library of API functions for extensibility
       
      -By default, WordPress® allows all content to be "open" and viewable by anyone and allows the site owner to restrict specific content if desired by setting a password for the post.  WP-Members™ operates with the reverse assumption.  It restricts all posts by default but allows the site owner to "unblock" content as desired.  WP-Members™ also offers the ability to change these default plugin settings.  For those that simply want to utilize the member management features and possibly restrict some content, the default setting can easily be toggled to block or unblock pages and/or posts by default.  No matter what the default setting, individual posts or pages can be set to be blocked or unblocked at the article level, overriding the default setting.
      +WP-Members allows you to set content as blocked or hidden to restrict For those that simply want to utilize the member management features and possibly restrict some content, the default setting can easily be toggled to block or unblock pages and/or posts by default. No matter what the default setting, individual posts or pages can be set to be blocked or unblocked at the article level, overriding the default setting.
       
      -The plugin installs with additional registration fields including name, address, phone, and email. Using the WP-Members™ admin panel, you can also create your own custom registration fields and delete existing ones.  Changing the field order is simple with a drag-and-drop interface.  All of the registration process is inline with your theme and content rather than using the WordPress® login page.  This offers you a premium content site with a professional and branded look and feel.  It also provides an opportunity for the user to register without leaving the page to do so - less clicks = more conversions.
      +The plugin installs with additional registration fields including name, address, phone, and email. Using the WP-Members admin panel, you can also create your own custom registration fields and delete existing ones. Changing the field order is simple with a drag-and-drop interface. The registration form will be part of your content rather than using the WordPress login page. This offers you a premium content site with a professional and branded look and feel. It also provides an opportunity for the user to register without leaving the page to do so - less clicks = more conversions.
       
       There are also some special pages that can be created with simple shortcodes:
       
       * A User Profile page where registered members can edit their information and change/reset their password: [wpmem_profile]
      -* A Registration page available for those that need a specific URL for registrations (such as email marketing or banner ad landing pages).  Note: this is strictly optional as a registration form can also be included by default on blocked content pages: [wpmem_form register]
      -* A Login page.  This is also an optional page as the login form is included by default on blocked content.  But if you need a specific login page, this can be created with a simple shortcode: [wpmem_form login]
      +* A Registration page available for those that need a specific URL for registrations (such as email marketing or banner ad landing pages). Note: this is strictly optional as a registration form can also be included by default on blocked content pages: [wpmem_form register]
      +* A Login page. This is also an optional page as the login form is included by default on blocked content. But if you need a specific login page, this can be created with a simple shortcode: [wpmem_form login]
       * [And more shortcodes are available](https://rocketgeek.com/plugins/wp-members/users-guide/shortcodes/)!
       
      -The plugin runs on a framework with over 100 action and filter hooks so you can fully customize your implementation.
      -
      -In addition to all of the features above, the plugin can be extended with premium add-on modules available from the support site rocketgeek.com.  Members of rocketgeek.com have access to support, examples, tutorials, and code snippets that will help you extend and customize the base plugin using the plugin's framework.  Some of the add-ons have their own hooks and shortcodes to further extend the plugin's extensibility.  [Visit the site for more info](https://rocketgeek.com/about/site-membership-subscription/).
      -
      -= What the plugin does not do =
      +Powerful cusotmizations can be constructed with over 100 action and filter hooks, as well as user accessible functions.
       
      -WP-Members does not automatically hide absolutely everything from view.  The default install of the plugin is designed to use "teaser" content to drive users to want to register.  If you want certain content or menu elements completely hidden, there are ways to do that with some customization between your theme and the plugin, but it is not automatic.
      +In addition to all of the features above, the plugin can be extended with premium add-on modules available from the support site rocketgeek.com. Members of rocketgeek.com have access to support, examples, tutorials, and code snippets that will help you extend and customize the base plugin using the plugin's framework. Some of the add-ons have their own hooks and shortcodes to further expand the plugin's extensibility. [Visit the site for more info](https://rocketgeek.com/about/site-membership-subscription/).
       
       
       == Installation ==
       
      -WP-Members™ is designed to run "out-of-the-box" with no modifications to your WP installation necessary.  Please follow the installation instructions below.  __Most of the support issues that arise are a result of improper installation or simply not reading/following directions__.
      +WP-Members is designed to run "out-of-the-box" with no modifications to your WP installation necessary. Please follow the installation instructions below. __Most of the support issues that arise are a result of improper installation or simply not reading/following directions__.
       
       = Basic Install: =
       
      -The best start is to follow the instructions in the [Quick Start Guide](https://rocketgeek.com/plugins/wp-members/quick-start-guide/).  There is also a complete [Users Guide available](https://rocketgeek.com/plugins/wp-members/users-guide/) that covers all of the plugin's features in depth.
      +The best way to begin is to review the [Initial Setup Video](https://rocketgeek.com/plugins/wp-members/docs/videos/). There is also a complete [Users Guide available](https://rocketgeek.com/plugins/wp-members/docs/) that covers all of the plugin's features in depth.
       
       1. Upload the `/wp-members/` directory and its contents to the `/wp-content/plugins/` directory
       2. Activate the plugin through the 'Plugins' menu in WordPress®
       
      -You are ready to begin using WP-Members™.  Now follow the instructions titled "Locking down your site" below.
      -
      -NOTE: Please follow instructions for installation. The vast majority of people that have marked the plugin as "broken" in the plugin compatibility form simply did not read/follow installation instructions. If something is unclear, ask for assistance.
      +You are ready to begin using WP-Members. Now follow the instructions titled "Locking down your site" below.
       
       = Locking down your site: =
       
      -* To begin restricting posts, you will need to be using the `` link in your posts.  Content above to the "more" split will display on summary pages (home, archive, category) but the user will be required to login to view the entire post.  You may also use the plugin's auto excerpt setting to create post excerpts automatically.  If you do not use the "more" tag or the auto excerpt setting, full post content is going to show on archive templates.
      -* To begin restricting pages, change the plugin default setting for pages to be blocked. Unlike posts, the `` link is not necessary in the blocking of pages, but __must__ be used if you have the "show excerpts" setting turned on.
      -* To protect comments, we recommend setting "Users must be registered and logged in to comment" under Settings > Discussion
      -* Also on the page Settings > General, we recommend making sure "Anyone can register" is unchecked.  While not required, this will prevent WP's native registration from colliding with WP-Members™, especially if you are using any of the WP-Members™ additional registration fields.
      -* Under Settings > Reading, we recommend that "For each article in a feed, show" is set to "Summary."  WordPress® installs with full feed settings by default. If you don't change this, your feeds will show full content.
      +* To restrict posts, you will need to use the `` link in your posts. Content above to the "more" split will display on summary pages (home, archive, category) but the user will be required to login to view the entire post. You may also use the plugin's auto excerpt setting to create post excerpts automatically. If you do not use the "more" tag or the auto excerpt setting, full post content is going to show on archive templates, unless the post is marked as hidden.
      +* To begin restricting pages, change the plugin default setting for pages to be blocked. Unlike posts, the `` link is not necessary in the blocking of pages, but __must__ be used if you have the "show excerpts" setting turned on for pages.
      +* To protect comments, we recommend setting "Users must be registered and logged in to comment" under Settings > Discussion.
      +* On the Settings > General page, it is recommended that you uncheck "Anyone can register". While not required, this will prevent WP's native registration from colliding with WP-Members, especially if you are using any of the WP-Members additional registration fields.
      +* Under Settings > Reading, "For each article in a feed, show" is recommended to be set to "Summary."  WordPress installs with full feed settings by default. If you don't change this, your feeds will show full content.
       
       
       = Additional Settings and Information = 
       
      -A full Users Guide is [available here](https://rocketgeek.com/plugins/wp-members/users-guide/).  The guide outlines the installation process, and also documents how to use all of the settings.
      +A full Users Guide is [available here](https://rocketgeek.com/plugins/wp-members/docs/). The guide outlines the installation process, and also documents how to use all of the settings.
       
       = Plugin Extensibility =
       
      -WP-Members™ is designed to be an out-of-the-box usable plugin, but also have an extensible framework for maximum flexibility and customization.  For this purpose, there are a number of shortcodes, filters, and actions that can be used.
      +WP-Members is designed to be an out-of-the-box usable plugin, but also have an extensible framework for maximum flexibility and customization. For this purpose, there are a number of functions, shortcodes, filters, and actions that can be used.
       
       See [this page](https://rocketgeek.com/plugins/wp-members/users-guide/shortcodes/) for a list of shortcodes and their description.
       
      -The plugin has 80 filter and action hooks.  For a list of hooks and a description of their use, see [this page](https://rocketgeek.com/plugins/wp-members/users-guide/filter-hooks/)
      +The plugin has over 120 filter and action hooks. For a list of hooks and a description of their use, see [this page](https://rocketgeek.com/plugins/wp-members/users-guide/filter-hooks/)
       
      -The plugin's premium support site has __loads__ of tips, tricks, and sample code for you to make maximum use out of the plugin.  [Get more information here](https://rocketgeek.com/about/site-membership-subscription/).  Members of the premium support site also have access to premium add-on modules.
      +The plugin's premium support site has many tips, tricks, and sample code for you to make maximum use out of the plugin. [Get more information here](https://rocketgeek.com/plugins/wp-members/support-options/). Members of the premium support site also have access to premium add-on modules.
       
       
       == Frequently Asked Questions ==
       
      -The FAQs are maintained at https://rocketgeek.com/plugins/wp-members/users-guide/faqs/
      +The FAQs are maintained at https://rocketgeek.com/plugins/wp-members/docs/faqs/
       
       
       == Other Notes ==
       
      -= Statement regarding the name WP-Members™ =
      -
      -WP-Members™ is a trademark of butlerblog.com.
      += WP-Members™ is a trademark of butlerblog.com =
       
      -There are a number of commercial vendors offering products called WP-Members™ or a derivative thereof.  Most of these products are neither free, nor are all of them open source.  The original plugin hosted here has been publicly available since 2006 and in no way associated with any of these vendors.  Tagging your support request in the wordpress.org forums attaches it to this plugin.  If you are seeking support for one of these commercial products, you should seek support from the vendor.  If you got it from a site other than [here](http://wordpress.org/extend/plugins/wp-members) then it isn't WP-Members™.
      +There are a number of commercial vendors offering products called WP-Members. Most of these products are neither free and some are not open source. The original plugin hosted here has been publicly available since 2006 and is in no way associated with any of these vendors. If you are seeking support for one of these commercial products, you should seek support from the vendor. If you got it from a site other than [rocketgeek.com](https://rocketgeek.com/plugins/wp-members/) or [wordpress.org](https://wordpress.org/extend/plugins/wp-members) then it isn't WP-Members™.
       
       An [official statement is available here](http://butlerblog.com/regarding-wp-members).
       
      -= Regarding RocketGeek.com =
      += RocketGeek.com =
       
      -Premium priority support is available at the plugin's site [RocketGeek.com](https://rocketgeek.com).  A site membership includes priority support, members-only forum access, plugin extensions, and a custom code snippet library.  [RocketGeek.com](https://rocketgeek.com) is the only site officially managed for this plugin's support.
      +Premium priority support is available at the plugin's site [RocketGeek.com](https://rocketgeek.com). A site membership includes priority support, members-only forum access, plugin extensions, and a custom code snippet library. [RocketGeek.com](https://rocketgeek.com) is the only site officially managed for this plugin's support.
       
       
       == Upgrade Notice ==
      diff --git a/wp-members.php b/wp-members.php
      index 297cadfe..5a712333 100644
      --- a/wp-members.php
      +++ b/wp-members.php
      @@ -3,7 +3,7 @@
       Plugin Name: WP-Members
       Plugin URI:  https://rocketgeek.com
       Description: WP access restriction and user registration.  For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com.
      -Version:     3.2.0.rc.2
      +Version:     3.2.0.rc.3
       Author:      Chad Butler
       Author URI:  http://butlerblog.com/
       Text Domain: wp-members
      @@ -66,7 +66,7 @@
       }
       
       // Initialize constants.
      -define( 'WPMEM_VERSION', '3.2.0.rc.2' );
      +define( 'WPMEM_VERSION', '3.2.0.rc.3' );
       define( 'WPMEM_DEBUG', false );
       define( 'WPMEM_DIR',  plugin_dir_url ( __FILE__ ) );
       define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) );
      
      From fef55763f71e4d3e4ac8c9b9fcd072f533fd1dfd Mon Sep 17 00:00:00 2001
      From: Chad Butler 
      Date: Tue, 3 Jul 2018 09:01:23 -0400
      Subject: [PATCH 0812/1694] added placeholder, pattern, and title attribute
       support for password fields
      
      ---
       inc/class-wp-members-forms.php | 4 +++-
       readme.txt                     | 1 +
       2 files changed, 4 insertions(+), 1 deletion(-)
      
      diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php
      index b008fe25..a1e44883 100644
      --- a/inc/class-wp-members-forms.php
      +++ b/inc/class-wp-members-forms.php
      @@ -101,7 +101,9 @@ function create_form_field( $args ) {
       		case "password":
       			$class = $this->sanitize_class( $class );
       			$placeholder = ( $placeholder ) ? ' placeholder="' . esc_attr( $placeholder ) . '"' : '';
      -			$str = "";
      +			$pattern     = ( $pattern     ) ? ' pattern="' . esc_attr( $pattern ) . '"' : '';
      +			$title       = ( $title       ) ? ' title="' . esc_attr( $title ) . '"' : '';
      +			$str = "";
       			break;
       		
       		case "image":
      diff --git a/readme.txt b/readme.txt
      index 6d0ae9e3..ebe28b82 100644
      --- a/readme.txt
      +++ b/readme.txt
      @@ -159,6 +159,7 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum
       * HTML5 update - form anchor tags changed from "name" to "id".
       * HTML5 update - form id tags set default value (can still be filtered).
       * HTML5 update - removed "align" attribute (captcha, link-text).
      +* HTML5 update - added placeholder, pattern, and title attribute support for password fields.
       * Improved the add a field dialog to adjust required inputs depending on field type.
       * Added placeholder, rows, and cols attribute support for textarea field settings.
       * Moved remaining core functions to appropriate object classes, left wrappers for most.
      
      From 88a75e3dce7758e454690646fbb7dfa8438d24be Mon Sep 17 00:00:00 2001
      From: Chad Butler 
      Date: Tue, 3 Jul 2018 10:56:10 -0400
      Subject: [PATCH 0813/1694] fix excluded fields for admin/user profile update
      
      ---
       inc/class-wp-members-user-profile.php | 3 +--
       inc/class-wp-members.php              | 4 ++++
       2 files changed, 5 insertions(+), 2 deletions(-)
      
      diff --git a/inc/class-wp-members-user-profile.php b/inc/class-wp-members-user-profile.php
      index aecedf3e..d55f12c5 100644
      --- a/inc/class-wp-members-user-profile.php
      +++ b/inc/class-wp-members-user-profile.php
      @@ -296,8 +296,7 @@ static function update( $user_id ) {
       		 */
       		$fields = apply_filters( 'wpmem_' . $display . '_profile_update', $fields, $user_id );
       
      -		// Get any excluded meta fields.
      -		$exclude = wpmem_get_excluded_meta( 'admin-profile' );
      +		// Handle meta update, skip excluded fields.
       		foreach ( $fields as $key => $val ) {
       			if ( ! in_array( $key, $exclude ) ) {
       				if ( ( 'admin' != $display && 'ok' == $chk ) || 'admin' == $display ) {
      diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php
      index cb62dd46..eebf5f04 100644
      --- a/inc/class-wp-members.php
      +++ b/inc/class-wp-members.php
      @@ -1089,6 +1089,10 @@ function excluded_fields( $tag ) {
       			$excluded_fields[] = 'username';
       		}
       
      +		if ( 'admin-profile' == $tag || 'user-profile' == $tag ) {
      +			array_push( $excluded_fields, 'first_name', 'last_name', 'nickname', 'display_name', 'user_email', 'description', 'user_url' );
      +		}
      +
       		/**
       		 * Filter the fields to be excluded when user is created/updated.
       		 *
      
      From c40f019728ccbdd609becb7b556287021174fb62 Mon Sep 17 00:00:00 2001
      From: Chad Butler 
      Date: Mon, 9 Jul 2018 10:25:27 -0400
      Subject: [PATCH 0814/1694] fixes to 3.2 email object (from/from_name)
      
      ---
       admin/tab-emails.php           |  6 ++----
       admin/tab-options.php          |  5 -----
       inc/class-wp-members-email.php | 19 +++++++++++++++----
       wp-members-install.php         | 22 +++++++---------------
       4 files changed, 24 insertions(+), 28 deletions(-)
      
      diff --git a/admin/tab-emails.php b/admin/tab-emails.php
      index 6dbd98ae..30579c36 100644
      --- a/admin/tab-emails.php
      +++ b/admin/tab-emails.php
      @@ -129,10 +129,8 @@ function wpmem_update_emails() {
       	if ( $wpmem->email->from    != $_POST['wp_mail_from'] || $wpmem->email->from_name != $_POST['wp_mail_from_name'] ) {
       		$wpmem->email->from      = sanitize_email( $_POST['wp_mail_from'] );
       		$wpmem->email->from_name = sanitize_text_field( $_POST['wp_mail_from_name'] );
      -		$wpmem_newsettings = get_option( 'wpmembers_settings' );
      -		$wpmem_newsettings['email']['from']      = sanitize_email( $_POST['wp_mail_from'] );
      -		$wpmem_newsettings['email']['from_name'] = sanitize_text_field( $_POST['wp_mail_from_name'] );
      -		update_option( 'wpmembers_settings', $wpmem_newsettings );
      +		update_option( 'wpmembers_email_wpfrom', $wpmem->email->from );
      +		update_option( 'wpmembers_email_wpname', $wpmem->email->from_name );
       	}
       	
       	// Update the various emails being used.
      diff --git a/admin/tab-options.php b/admin/tab-options.php
      index 91aa23fb..559878a7 100644
      --- a/admin/tab-options.php
      +++ b/admin/tab-options.php
      @@ -457,11 +457,6 @@ function wpmem_update_options() {
       		$wpmem_newsettings['form_tags'] = $wpmem->form_tags;
       	}
       
      -	// Leave email settings alone.
      -	if ( isset( $wpmem->email ) ) {
      -		$wpmem_newsettings['email'] = $wpmem->email;
      -	}
      -
       	// Get settings for blocking, excerpts, show login, and show registration for posts, pages, and custom post types.
       	$option_group_array = array( 'block', 'show_excerpt', 'show_login', 'show_reg', 'autoex' );
       	foreach ( $option_group_array as $option_group_item ) {
      diff --git a/inc/class-wp-members-email.php b/inc/class-wp-members-email.php
      index 96b3cb55..e40d7078 100644
      --- a/inc/class-wp-members-email.php
      +++ b/inc/class-wp-members-email.php
      @@ -50,6 +50,16 @@ class WP_Members_Email {
       	 */
       	public $settings;
       	
      +	/**
      +	 * Constructor
      +	 *
      +	 * @since 3.2.0
      +	 */
      +	function __construct() {
      +		$this->from      = get_option( 'wpmembers_email_wpfrom', '' );
      +		$this->from_name = get_option( 'wpmembers_email_wpname', '' );
      +	}
      +	
       	/**
       	 * Builds emails for the user.
       	 *
      @@ -239,7 +249,7 @@ function to_user( $user_id, $password, $tag, $wpmem_fields = null, $field_data =
       			$this->settings['body'] = ( $this->settings['add_footer'] ) ? $this->settings['body'] . "\r\n" . $foot : $this->settings['body'];
       
       			// Send message.
      -			$this->send();
      +			$this->send( 'user' );
       
       		}
       		return;
      @@ -456,7 +466,7 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) {
       			$this->settings['body'] = apply_filters( 'wpmem_email_notify', $this->settings['body'] );
       
       			// Send the message.
      -			$this->send();
      +			$this->send( 'admin' );
       		}
       	}
       
      @@ -497,11 +507,12 @@ function from_name( $name ) {
       	 *
       	 * @since 3.2.0
       	 */
      -	function send() {
      +	function send( $to ) {
      +		$send_to = ( 'user' == $to ) ? $this->settings['user_email'] : $this->settings['admin_email'];
       		// Apply WP's "from" and "from name" email filters.
       		add_filter( 'wp_mail_from',      array( $this, 'from'      ) );
       		add_filter( 'wp_mail_from_name', array( $this, 'from_name' ) );
       		// Send the message.
      -		wp_mail( $this->settings['user_email'], stripslashes( $this->settings['subj'] ), stripslashes( $this->settings['body'] ), $this->settings['headers'] );
      +		wp_mail( $send_to, stripslashes( $this->settings['subj'] ), stripslashes( $this->settings['body'] ), $this->settings['headers'] );
       	}
       }
      \ No newline at end of file
      diff --git a/wp-members-install.php b/wp-members-install.php
      index bb0c6e3e..5c827e41 100644
      --- a/wp-members-install.php
      +++ b/wp-members-install.php
      @@ -50,6 +50,7 @@ function wpmem_do_install() {
       
       	if ( ! get_option( 'wpmembers_settings' ) || $chk_force == true ) {
       
      +		// New install.
       		$wpmem_settings = wpmem_install_settings();
       		wpmem_install_fields();
       		wpmem_install_dialogs();
      @@ -58,6 +59,7 @@ function wpmem_do_install() {
       
       	} else {
       		
      +		// Upgrade.
       		$wpmem_settings = wpmem_upgrade_settings();
       		wpmem_upgrade_captcha();
       		wpmem_append_email();
      @@ -129,14 +131,11 @@ function wpmem_upgrade_settings() {
       			$wpmem_settings['form_tags'] = array( 'default' => 'Registration Default' );
       		}
       		
      -		// If email is not set, add it with existing setting or default.
      -		if ( ! isset( $wpmem_settings['email'] ) ) {
      -			$from = get_option( 'wpmembers_email_wpfrom' );
      -			$name = get_option( 'wpmembers_email_wpname' );
      -			$wpmem_settings['email'] = array(
      -				'from'      => ( $from ) ? $from : '',
      -				'from_name' => ( $name ) ? $name : '',
      -			);
      +		// If email is set in the settings array, change it back to the pre-3.1 option.
      +		if ( isset( $wpmem_settings['email'] ) ) {
      +			update_option( 'wpmembers_email_wpfrom', $wpmem_settings['email']['from'] );
      +			update_option( 'wpmembers_email_wpname', $wpmem_settings['email']['from_name'] );
      +			unset( $wpmem_settings['email'] );
       		}
       		
       		// Version number should be updated no matter what.
      @@ -199,12 +198,6 @@ function wpmem_upgrade_settings() {
       		// Add new settings.
       		$wpmem_newsettings['post_types'] = array();
       		$wpmem_settings['form_tags'] = array( 'default' => 'Registration Default' );
      -		$from = get_option( 'wpmembers_email_wpfrom' );
      -		$name = get_option( 'wpmembers_email_wpname' );
      -		$wpmem_settings['email'] = array(
      -			'from'      => ( $from ) ? $from : '',
      -			'from_name' => ( $name ) ? $name : '',
      -		);
       		
       		// Merge settings.
       		$wpmem_newsettings = array_merge( $wpmem_settings, $wpmem_newsettings ); 
      @@ -511,7 +504,6 @@ function wpmem_install_settings() {
       		'attrib'    => 0,
       		'post_types' => array(),
       		'form_tags'  => array( 'default' => 'Registration Default' ),
      -		'email'      => array( 'from' => '', 'from_name' => '' ),
       	);
       	
       	// Using update_option to allow for forced update.
      
      From 5e7a5a5e30db45a34ab47b2ee748d6b2d3aa513c Mon Sep 17 00:00:00 2001
      From: Chad Butler 
      Date: Mon, 9 Jul 2018 10:26:59 -0400
      Subject: [PATCH 0815/1694] use sanitize_textarea_field for textarea in profile
      
      ---
       inc/class-wp-members-user-profile.php | 5 ++++-
       1 file changed, 4 insertions(+), 1 deletion(-)
      
      diff --git a/inc/class-wp-members-user-profile.php b/inc/class-wp-members-user-profile.php
      index d55f12c5..069aa82e 100644
      --- a/inc/class-wp-members-user-profile.php
      +++ b/inc/class-wp-members-user-profile.php
      @@ -262,7 +262,8 @@ static function update( $user_id ) {
       				&& $field['type'] != 'multiselect' 
       				&& $field['type'] != 'multicheckbox' 
       				&& $field['type'] != 'file' 
      -				&& $field['type'] != 'image' ) {
      +				&& $field['type'] != 'image'
      +			    && $field['type'] != 'textarea' ) {
       				( isset( $_POST[ $meta ] ) && 'password' != $field['type'] ) ? $fields[ $meta ] = sanitize_text_field( $_POST[ $meta ] ) : false;
       				
       				// For user profile (not admin).
      @@ -282,6 +283,8 @@ static function update( $user_id ) {
       				$fields[ $meta ] = ( isset( $_POST[ $meta ] ) ) ? sanitize_text_field( $_POST[ $meta ] ) : '';
       			} elseif ( $field['type'] == 'multiselect' || $field['type'] == 'multicheckbox' ) {
       				$fields[ $meta ] = ( isset( $_POST[ $meta ] ) ) ? implode( $field['delimiter'], wp_unslash( $_POST[ $meta ] ) ) : '';
      +			} elseif ( $field['type'] == 'textarea' ) {
      +				$fields[ $meta ] = ( isset( $_POST[ $meta ] ) ) ? sanitize_textarea_field( $_POST[ $meta ] ) : '';
       			}
       		}
       
      
      From 89b108d99d8753cd370dd94d4d883de8c27a765c Mon Sep 17 00:00:00 2001
      From: Chad Butler 
      Date: Mon, 9 Jul 2018 10:27:45 -0400
      Subject: [PATCH 0816/1694] 3.2.0 beta release candidate 4
      
      ---
       wp-members.php | 4 ++--
       1 file changed, 2 insertions(+), 2 deletions(-)
      
      diff --git a/wp-members.php b/wp-members.php
      index 5a712333..d372b96c 100644
      --- a/wp-members.php
      +++ b/wp-members.php
      @@ -3,7 +3,7 @@
       Plugin Name: WP-Members
       Plugin URI:  https://rocketgeek.com
       Description: WP access restriction and user registration.  For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com.
      -Version:     3.2.0.rc.3
      +Version:     3.2.0.rc.4
       Author:      Chad Butler
       Author URI:  http://butlerblog.com/
       Text Domain: wp-members
      @@ -66,7 +66,7 @@
       }
       
       // Initialize constants.
      -define( 'WPMEM_VERSION', '3.2.0.rc.3' );
      +define( 'WPMEM_VERSION', '3.2.0.rc.4' );
       define( 'WPMEM_DEBUG', false );
       define( 'WPMEM_DIR',  plugin_dir_url ( __FILE__ ) );
       define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) );
      
      From d68d1502d72d7b21949fb927a8763e900db9fa2b Mon Sep 17 00:00:00 2001
      From: Chad Butler 
      Date: Mon, 9 Jul 2018 19:30:51 -0400
      Subject: [PATCH 0817/1694] 3.2.0 cleanup
      
      ---
       admin/dialogs.php | 20 ++++++++++----------
       readme.txt        |  6 ++----
       wp-members.php    |  4 ++--
       3 files changed, 14 insertions(+), 16 deletions(-)
      
      diff --git a/admin/dialogs.php b/admin/dialogs.php
      index b74a4651..da97f751 100644
      --- a/admin/dialogs.php
      +++ b/admin/dialogs.php
      @@ -238,16 +238,16 @@ function butlerblog_dashboard_widget() {
        * @since 2.8.0
        */
       function butlerblog_feed_output() {
      -    echo '
      '; - wp_widget_rss_output( array( - 'url' => 'http://feeds.feedburner.com/butlerblog', - 'title' => __( 'Latest from ButlerBlog', 'wp-members' ), - 'items' => 5, - 'show_summary' => 0, - 'show_author' => 0, - 'show_date' => 1, - ) ); - echo "
      "; + echo '
      '; + wp_widget_rss_output( array( + 'url' => 'https://feeds.feedburner.com/butlerblog', + 'title' => __( 'Latest from ButlerBlog', 'wp-members' ), + 'items' => 5, + 'show_summary' => 0, + 'show_author' => 0, + 'show_date' => 1, + ) ); + echo "
      "; } // End of file. \ No newline at end of file diff --git a/readme.txt b/readme.txt index ebe28b82..1008bc67 100644 --- a/readme.txt +++ b/readme.txt @@ -132,7 +132,6 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * Changed default address meta fields to WooCommerce billing meta keys. * Removed language packs that install from wordpress.org (de_DE, hu_HU, ja, nl_NL, pt_BR, ru_RU, and sv_SE). * All remaining user facing strings in get_text() added wp-members textdomain. -* wpmem_default_text_strings filter now must pass $defaults as a parameter. * Added locale as a parameter for localization filters. * Added wpmem_register_hidden_rows filter. * Added "post_to" key for wpmem_register_form_args. @@ -144,15 +143,14 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum * Deprecated wpmem_do_sidebar(). * Deprecated wpmem_create_formfield(), use wpmem_form_field() instead. * Deprecated a number of non-user callable functions. -* Eliminated permission-based file load for admin files. +* Eliminated capability-based load for admin files. * Maintain user login state when password is changed. * Added wpmem_get_sub_str() string manipulation utility. * Updated login form redirect_to to account for query vars. * Fixes issue with login status if logout url is encoded (sprintf() has too few arguments). * Added Membership Products Custom Post Type. * Added "Hide Post" option for blocking content (currently only by post meta _wpmem_block). -* Removed several outdated stylesheets from selecion ( still download for users who may use them). -* Fixed issue with login page logged in state if encoded url exists (decode logout link url). +* Removed several outdated stylesheets from selection (still packaged with download for users who may use them). * Added wpmem_update_user_role() API function. * Added wpmem_display_message() API function. * Added wpmem_user_has_access() API function. diff --git a/wp-members.php b/wp-members.php index d372b96c..f5fc2845 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.2.0.rc.4 +Version: 3.2.0 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -66,7 +66,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.2.0.rc.4' ); +define( 'WPMEM_VERSION', '3.2.0' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 9c0beb273988a47aa4118eb82d84aec72400ff0a Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 10 Jul 2018 19:39:52 -0400 Subject: [PATCH 0818/1694] install fix for users upgrading from certain beta builds --- wp-members-install.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/wp-members-install.php b/wp-members-install.php index 5c827e41..ff62eb44 100644 --- a/wp-members-install.php +++ b/wp-members-install.php @@ -133,8 +133,10 @@ function wpmem_upgrade_settings() { // If email is set in the settings array, change it back to the pre-3.1 option. if ( isset( $wpmem_settings['email'] ) ) { - update_option( 'wpmembers_email_wpfrom', $wpmem_settings['email']['from'] ); - update_option( 'wpmembers_email_wpname', $wpmem_settings['email']['from_name'] ); + $from = ( is_array( $wpmem_settings['email'] ) ) ? $wpmem_settings['email']['from'] : ''; + $name = ( is_array( $wpmem_settings['email'] ) ) ? $wpmem_settings['email']['from_name'] : ''; + update_option( 'wpmembers_email_wpfrom', $from ); + update_option( 'wpmembers_email_wpname', $name ); unset( $wpmem_settings['email'] ); } From 7c52d822c99b0077e7fb0d5fbe5d02a798ea84a4 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 10 Jul 2018 19:40:53 -0400 Subject: [PATCH 0819/1694] added back "toggle" key, fix for username shortcode in email --- inc/class-wp-members-email.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members-email.php b/inc/class-wp-members-email.php index e40d7078..0e668a8f 100644 --- a/inc/class-wp-members-email.php +++ b/inc/class-wp-members-email.php @@ -127,6 +127,7 @@ function to_user( $user_id, $password, $tag, $wpmem_fields = null, $field_data = $this->settings['add_footer'] = true; $this->settings['footer'] = get_option( 'wpmembers_email_footer' ); $this->settings['disable'] = false; + $this->settings['toggle'] = $this->settings['tag']; // Deprecated since 3.2.0, but remains in the array for legacy reasons. // Apply filters (if set) for the sending email address. $default_header = ( $this->from && $this->from_name ) ? 'From: "' . $this->from_name . '" <' . $this->from . '>' : ''; @@ -174,6 +175,7 @@ function to_user( $user_id, $password, $tag, $wpmem_fields = null, $field_data = * @type string footer * @type bool disable * @type mixed headers + * @type string toggle Deprecated since 3.2.0 * } * @param array $wpmem_fields An array of the WP-Members fields. * @param array $field_data An array of the posted registration data. @@ -216,8 +218,10 @@ function to_user( $user_id, $password, $tag, $wpmem_fields = null, $field_data = // Add custom field shortcodes. foreach ( $wpmem_fields as $meta_key => $field ) { - $val = ( is_array( $field_data ) && $field['register'] ) ? $field_data[ $meta_key ] : get_user_meta( $user_id, $meta_key, true ); - $shortcodes[ $meta_key ] = $val; + if ( ! array_key_exists( $meta_key, $shortcodes ) ) { + $val = ( is_array( $field_data ) && $field['register'] ) ? $field_data[ $meta_key ] : get_user_meta( $user_id, $meta_key, true ); + $shortcodes[ $meta_key ] = $val; + } } /** From 0e27f79a9fe684043d806e17b488df4b3c4830ba Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Tue, 10 Jul 2018 19:41:17 -0400 Subject: [PATCH 0820/1694] 3.2.0.1 fixes --- inc/class-wp-members-forms.php | 2 +- readme.txt | 9 ++++++++- wp-members.php | 4 ++-- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index a1e44883..58331cb8 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -376,7 +376,7 @@ function file_upload_dir( $param ) { * The elements needed to generate the form (login|reset password|forgotten password). * * @type string $heading Form heading text. - * @type string $action The form action (login|pwdchange|pwdreset). + * @type string $action The form action (login|pwdchange|pwdreset|getusername). * @type string $button_text Form submit button text. * @type array $inputs { * The form input values. diff --git a/readme.txt b/readme.txt index 1008bc67..4d1029c2 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 4.9 -Stable tag: 3.2.0 +Stable tag: 3.2.0.1 License: GPLv2 The WP-Members membership plugin turns your WordPress site into a membership site. Restrict premium content, create custom registration fields, and more. @@ -104,6 +104,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == WP-Members 3.2.0 is a major update. See changelog for important details. Minimum WP version is 4.0. +WP-Members 3.2.0.1 is a minor fix for 3.2.0. See changelog. == Screenshots == @@ -126,6 +127,12 @@ WP-Members 3.2.0 is a major update. See changelog for important details. Minimum == Changelog == += 3.2.0.1 = + +* Fix install routine for 3.2.0 beta users. +* Fix forgot username email (username shortcode). +* Reapply "toggle" and a key in the email array (wpmem_email_filter). This key is still deprecated and you should being using "tag" instead, but adding it back in will allow certain filter functions using it to still work (as long as the filter is not changing the value of the key). + = 3.2.0 = * Tested and compatible with Gutenberg. diff --git a/wp-members.php b/wp-members.php index f5fc2845..d28510bc 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.2.0 +Version: 3.2.0.1 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -66,7 +66,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.2.0' ); +define( 'WPMEM_VERSION', '3.2.0.1' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From e9cfc3ef4e2bed6071a45698b8a5eb448f52aeb8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 16 Jul 2018 22:26:42 -0400 Subject: [PATCH 0821/1694] fix default form id to have _form suffix (avoids duplicate id for wpmem_login) --- inc/class-wp-members-forms.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members-forms.php b/inc/class-wp-members-forms.php index 58331cb8..00008815 100644 --- a/inc/class-wp-members-forms.php +++ b/inc/class-wp-members-forms.php @@ -440,7 +440,7 @@ function login_form( $mixed, $arr = array() ) { 'link_span_after' => '', // classes & ids - 'form_id' => 'wpmem_' . $arr['action'], + 'form_id' => 'wpmem_' . $arr['action'] . '_form', 'form_class' => 'form', 'button_id' => '', 'button_class' => 'buttons', @@ -719,7 +719,7 @@ function register_form( $mixed = 'new', $heading = '', $redirect_to = null ) { 'buttons_after' => '
      ', // Classes & ids. - 'form_id' => ( 'new' == $tag ) ? 'wpmem_register' : 'wpmem_profile', + 'form_id' => ( 'new' == $tag ) ? 'wpmem_register_form' : 'wpmem_profile_form', 'form_class' => 'form', 'button_id' => '', 'button_class' => 'buttons', From 4cf0a344df7c0e42f0641518f40b4537e8b5d0d8 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 16 Jul 2018 22:28:54 -0400 Subject: [PATCH 0822/1694] fix user profile update (wouldn't submit without nonce-like error) --- inc/class-wp-members-user-profile.php | 6 +++++- inc/class-wp-members.php | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members-user-profile.php b/inc/class-wp-members-user-profile.php index 069aa82e..628ca6f9 100644 --- a/inc/class-wp-members-user-profile.php +++ b/inc/class-wp-members-user-profile.php @@ -236,7 +236,11 @@ static function update( $user_id ) { $wpmem_fields = ( 'admin' == $display ) ? wpmem_fields( 'admin_profile_update' ) : wpmem_fields( 'dashboard_profile_update' ); $exclude = wpmem_get_excluded_meta( $display . '-profile' ); - + + foreach ( $exclude as $excluded ) { + unset( $wpmem_fields[ $excluded ] ); + } + // If tos is an active field, this is the dashboard profile, and user has current field value. if ( isset( $wpmem_fields['tos'] ) && get_user_meta( $user_id, 'tos', true ) == $wpmem_fields['tos']['checked_value'] ) { unset( $wpmem_fields['tos'] ); diff --git a/inc/class-wp-members.php b/inc/class-wp-members.php index eebf5f04..9bc57185 100644 --- a/inc/class-wp-members.php +++ b/inc/class-wp-members.php @@ -1085,7 +1085,7 @@ function excluded_fields( $tag ) { // Default excluded fields. $excluded_fields = array( 'password', 'confirm_password', 'confirm_email', 'password_confirm', 'email_confirm' ); - if ( 'update' == $tag ) { + if ( 'update' == $tag || 'admin-profile' == $tag || 'user-profile' == $tag || 'wp-register' == $tag ) { $excluded_fields[] = 'username'; } From 6b3c7aa0a62cd76277081da281d998081e01cf4c Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 16 Jul 2018 22:30:46 -0400 Subject: [PATCH 0823/1694] fix to make sure username is removed from native wp reg (for validation) --- inc/wp-registration.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/wp-registration.php b/inc/wp-registration.php index fe910a1d..7017174d 100644 --- a/inc/wp-registration.php +++ b/inc/wp-registration.php @@ -334,7 +334,7 @@ function wpmem_wp_reg_validate( $errors, $sanitized_user_login, $user_email ) { global $wpmem; // Get any meta fields that should be excluded. - $exclude = wpmem_get_excluded_meta( 'register' ); + $exclude = wpmem_get_excluded_meta( 'wp-register' ); foreach ( wpmem_fields( 'wp_validate' ) as $meta_key => $field ) { $is_error = false; @@ -374,7 +374,7 @@ function wpmem_wp_reg_finalize( $user_id ) { $is_woo = ( wpmem_get( 'woocommerce_checkout_place_order' ) || wpmem_get( 'woocommerce-register-nonce' ) ) ? true : false; if ( $is_native || $is_add_new || $is_woo ) { // Get any excluded meta fields. - $exclude = wpmem_get_excluded_meta( 'register' ); + $exclude = wpmem_get_excluded_meta( 'wp-register' ); foreach ( wpmem_fields( 'wp_finalize' ) as $meta_key => $field ) { $value = wpmem_get( $meta_key, false ); if ( $value && ! in_array( $meta_key, $exclude ) && 'file' != $field['type'] && 'image' != $field['type'] ) { From 8be05fc75a27a803f80595c9fcbba4282ab18f71 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 16 Jul 2018 22:58:52 -0400 Subject: [PATCH 0824/1694] load new js/css for post editor interface --- admin/css/admin.css | 7 ++++++ admin/includes/class-wp-members-admin-api.php | 9 ++++--- admin/js/admin.js | 25 +++++++++++++++++++ 3 files changed, 37 insertions(+), 4 deletions(-) diff --git a/admin/css/admin.css b/admin/css/admin.css index 7af8e161..ba0434c8 100644 --- a/admin/css/admin.css +++ b/admin/css/admin.css @@ -58,3 +58,10 @@ #sort { width: 24px; } + +#wpmem_block input { + vertical-align: -webkit-baseline-middle; +} +#wpmem_post_block_status { + font-weight: 600; +} \ No newline at end of file diff --git a/admin/includes/class-wp-members-admin-api.php b/admin/includes/class-wp-members-admin-api.php index ac5a151a..78259fbb 100644 --- a/admin/includes/class-wp-members-admin-api.php +++ b/admin/includes/class-wp-members-admin-api.php @@ -505,15 +505,16 @@ function form_post_url( $args = false ) { * Only loads the js and css on admin screens that use them. * * @since 3.1.7 - * @deprecated 3.2.0 Moved to admin object, rename dashboard_enqueue_scripts(). + * @since 3.2.0 Moved into admin object, renamed dashboard_enqueue_scripts(). + * @since 3.2.1 Load js for post.php hook. * * @param str $hook The admin screen hook being loaded. */ function dashboard_enqueue_scripts( $hook ) { - if ( $hook == 'edit.php' || $hook == 'settings_page_wpmem-settings' ) { + if ( 'edit.php' == $hook || 'settings_page_wpmem-settings' == $hook || 'post.php' == $hook ) { wp_enqueue_style( 'wpmem-admin', WPMEM_DIR . 'admin/css/admin.css', '', WPMEM_VERSION ); - } - if ( $hook == 'settings_page_wpmem-settings' ) { + } + if ( 'settings_page_wpmem-settings' == $hook || 'post.php' == $hook ) { wp_enqueue_script( 'wpmem-admin', WPMEM_DIR . 'admin/js/admin.js', '', WPMEM_VERSION ); } } diff --git a/admin/js/admin.js b/admin/js/admin.js index 97853056..188daae1 100644 --- a/admin/js/admin.js +++ b/admin/js/admin.js @@ -181,3 +181,28 @@ }); }); })(jQuery); + +/** + * JS for post block status meta box + * + * @since 3.2.1 + */ +(function($) { + $(document).ready(function() { + $("#wpmem_block").hide(); + }); + $(document).ready(function() { + $("#wpmem_edit_block_status").click(function() { + $("#wpmem_block").show('normal'); + $("#wpmem_edit_block_status").hide(); + }); + $("#wpmem_cancel_block_status").click(function() { + $("#wpmem_block").hide('normal'); + $("#wpmem_edit_block_status").show(); + }); + $("#wpmem_ok_block_status").click(function() { + $("#wpmem_block").hide('normal'); + $("#wpmem_edit_block_status").show(); + }); + }); +})(jQuery); \ No newline at end of file From 1a44c40d9654c22f131ebda3e1eee82cc31ae0a1 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Mon, 16 Jul 2018 23:01:24 -0400 Subject: [PATCH 0825/1694] update post editor block metabox interface to make it more intuitive --- admin/post.php | 41 ++++++++++++++++++++++------------------- 1 file changed, 22 insertions(+), 19 deletions(-) diff --git a/admin/post.php b/admin/post.php index d0d087e9..686aa7e4 100644 --- a/admin/post.php +++ b/admin/post.php @@ -197,34 +197,37 @@ function wpmem_block_meta() { wp_nonce_field( 'wpmem_block_meta_nonce', 'wpmem_block_meta_nonce' ); - $post_type = $wp_post_types[ $post->post_type ]; - - if ( isset( $wpmem->block[ $post->post_type ] ) && $wpmem->block[ $post->post_type ] == 1 ) { - $notice_icon = ''; - $notice_text = sprintf( __( '%s are blocked by default.', 'wp-members' ), $post_type->labels->name ); - } else { - $notice_icon = ''; - $notice_text = sprintf( __( '%s are not blocked by default.', 'wp-members' ), $post_type->labels->name ); - } - + $post_type = $wp_post_types[ $post->post_type ]; $post_meta_value = get_post_meta( $post->ID, '_wpmem_block', true ); - $post_meta_value = ( null == $post_meta_value ) ? $wpmem->block[ $post->post_type ] : $post_meta_value; $post_meta_settings = array( '0' => __( 'Unblock', 'wp-members' ), '1' => __( 'Block', 'wp-members' ), '2' => __( 'Hide', 'wp-members' ), - ); ?> -

      - ' . __( 'Edit', 'wp-members' ) . ''; ?> -

      + ); + + switch ( $post_meta_value ) { + case 0: + $notice_text = __( 'Unblocked', 'wp-members' ); + $notice_icon = ''; + break; + case 1: + $notice_text = __( 'Blocked', 'wp-members' ); + $notice_icon = ''; + break; + case 2: + $notice_text = __( 'Hidden', 'wp-members' ); + $notice_icon = ''; + break; + } ?> +

      -
      '; } ?> - - +

      +
  • Date: Mon, 16 Jul 2018 23:02:02 -0400 Subject: [PATCH 0826/1694] change all posts block column to show all post status (not just opposite default) --- admin/post.php | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/admin/post.php b/admin/post.php index 686aa7e4..a6b3a5e8 100644 --- a/admin/post.php +++ b/admin/post.php @@ -309,7 +309,7 @@ function wpmem_post_columns( $columns ) { $post_type = ( isset( $_REQUEST['post_type'] ) ) ? sanitize_text_field( $_REQUEST['post_type'] ) : 'post'; if ( $post_type == 'page' || $post_type == 'post' || array_key_exists( $post_type, $wpmem->post_types ) ) { - $columns['wpmem_block'] = ( $wpmem->block[ $post_type ] == 1 ) ? __( 'Unblocked?', 'wp-members' ) : __( 'Blocked?', 'wp-members' ); + $columns['wpmem_block'] = __( 'Status', 'wp-members' ); } return $columns; } @@ -341,9 +341,20 @@ function wpmem_post_columns_content( $column_name, $post_ID ) { $block_meta = ( $old_block ) ? 1 : ( ( $old_unblock ) ? 0 : $block_meta ); } - echo ( $wpmem->block[ $post_type ] == 1 && $block_meta == '0' ) ? '' : ''; - echo ( $wpmem->block[ $post_type ] == 0 && $block_meta == '1' ) ? '' : ''; - echo ( 2 == $block_meta ) ? '' : ''; + if ( $wpmem->block[ $post_type ] == 1 ) { + $block_span = array( 'lock', 'green', 'Blocked' ); + } + if ( $wpmem->block[ $post_type ] == 0 ) { + $block_span = array( 'unlock', 'red', 'Unblocked' ); + } + if ( $wpmem->block[ $post_type ] == 1 && $block_meta == '0' ) { + $block_span = array( 'unlock', 'red', 'Unblocked' ); + } elseif ( $wpmem->block[ $post_type ] == 0 && $block_meta == '1' ) { + $block_span = array( 'lock', 'green', 'Blocked' ); + } elseif ( 2 == $block_meta ) { + $block_span = array( 'hidden', '', 'Hidden' ); + } + echo ''; } } From 58a6b0cc2b81e1a49ab164185d902989e114adb4 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 18 Jul 2018 10:37:04 -0400 Subject: [PATCH 0827/1694] change fields shortcode clickable attribute to default to false --- inc/class-wp-members-shortcodes.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/class-wp-members-shortcodes.php b/inc/class-wp-members-shortcodes.php index 5286186a..35802c63 100644 --- a/inc/class-wp-members-shortcodes.php +++ b/inc/class-wp-members-shortcodes.php @@ -609,8 +609,8 @@ function fields( $atts, $content = null, $tag ) { $content = ( $content ) ? $result . $content : $result; - // Is it clickable? - $content = ( isset( $atts['clickable'] ) && ( false == $atts['clickable'] || 'false' == $atts['clickable'] ) ) ? $content : make_clickable( $content ); + // Make it clickable? + $content = ( isset( $atts['clickable'] ) && ( true === $atts['clickable'] || 'true' == $atts['clickable'] ) ) ? make_clickable( $content ) : $content; return do_shortcode( $content ); } From f51e1395d93212903a7b352a28ef3e1c1dfee0ef Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 18 Jul 2018 10:54:04 -0400 Subject: [PATCH 0828/1694] fix update post when block status is not changed --- admin/post.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/post.php b/admin/post.php index a6b3a5e8..598170ee 100644 --- a/admin/post.php +++ b/admin/post.php @@ -392,7 +392,7 @@ function wpmem_set_block_status( $status, $post_id, $post_type ) { $prev_value = get_post_meta( $post_id, '_wpmem_block', true ); // Update accordingly. - if ( $prev_value && $status != $prev_value ) { + if ( false !== $prev_value && $status != $prev_value ) { if ( $status == $wpmem->block[ $post_type ] ) { delete_post_meta( $post_id, '_wpmem_block' ); } else { @@ -400,7 +400,7 @@ function wpmem_set_block_status( $status, $post_id, $post_type ) { } } elseif ( ! $prev_value && $status != $wpmem->block[ $post_type ] ) { update_post_meta( $post_id, '_wpmem_block', $status ); - } else { + } elseif ( $status != $prev_value ) { delete_post_meta( $post_id, '_wpmem_block' ); } From d545d45ef02e8c098a4d0e5ec50efec5499709c2 Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Wed, 18 Jul 2018 10:54:56 -0400 Subject: [PATCH 0829/1694] potential 3.2.1 fix release --- readme.txt | 15 +++++++++------ wp-members.php | 4 ++-- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/readme.txt b/readme.txt index 4d1029c2..b913bf8c 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 4.9 -Stable tag: 3.2.0.1 +Stable tag: 3.2.1 License: GPLv2 The WP-Members membership plugin turns your WordPress site into a membership site. Restrict premium content, create custom registration fields, and more. @@ -104,7 +104,7 @@ Premium priority support is available at the plugin's site [RocketGeek.com](http == Upgrade Notice == WP-Members 3.2.0 is a major update. See changelog for important details. Minimum WP version is 4.0. -WP-Members 3.2.0.1 is a minor fix for 3.2.0. See changelog. +WP-Members 3.2.1 is a fix update for 3.2.0. See changelog. == Screenshots == @@ -127,11 +127,14 @@ WP-Members 3.2.0.1 is a minor fix for 3.2.0. See changelog. == Changelog == -= 3.2.0.1 = += 3.2.1 = -* Fix install routine for 3.2.0 beta users. -* Fix forgot username email (username shortcode). -* Reapply "toggle" and a key in the email array (wpmem_email_filter). This key is still deprecated and you should being using "tag" instead, but adding it back in will allow certain filter functions using it to still work (as long as the filter is not changing the value of the key). +* Fixed duplicate ID in login form. +* Fixed user profile update for excluded fields. +* Fixed native WP registration, excluded WP-Members username field in form validation. +* Fixed update post when block status is not changed. +* Rebuilt user interface for post restriction metabox to make it more intuitive. +* Changed "clickable" attribute for field shortcode default to false. = 3.2.0 = diff --git a/wp-members.php b/wp-members.php index d28510bc..6db49dd1 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.2.0.1 +Version: 3.2.1 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -66,7 +66,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.2.0.1' ); +define( 'WPMEM_VERSION', '3.2.1' ); define( 'WPMEM_DEBUG', false ); define( 'WPMEM_DIR', plugin_dir_url ( __FILE__ ) ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From c054e51849cf4366c4009dbf0688eb80be3b1e3e Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 19 Jul 2018 14:37:41 -0400 Subject: [PATCH 0830/1694] added wpmem_user_export_header and wpmem_user_export_row filters --- admin/user-export.php | 69 +++++++++++++++++++++++++------------------ 1 file changed, 40 insertions(+), 29 deletions(-) diff --git a/admin/user-export.php b/admin/user-export.php index 318ae0a4..f29b3fb9 100644 --- a/admin/user-export.php +++ b/admin/user-export.php @@ -24,6 +24,7 @@ * * @since 2.9.7 * @since 3.2.0 Updated to use fputcsv. + * @since 3.2.1 Added user data filters. * * @param array $args * @param array $users @@ -38,7 +39,7 @@ function wpmem_export_users( $args, $users = null ) { $defaults = array( 'export' => 'all', 'filename' => 'wp-members-user-export-' . $today . '.csv', - 'export_fields' => wpmem_fields(), //array(), + 'export_fields' => wpmem_fields(), 'exclude_fields' => array( 'password', 'confirm_password', 'confirm_email' ), 'entity_decode' => false, ); @@ -67,27 +68,36 @@ function wpmem_export_users( $args, $users = null ) { $handle = fopen( 'php://output', 'w' ); fputs( $handle, "\xEF\xBB\xBF" ); // UTF-8 BOM - $header = [ 'User ID', 'Username' ]; + $header = array( 'ID' => 'User ID', 'username' => 'Username' ); // Remove excluded fields from $export_fields while setting up $header array. foreach ( $args['export_fields'] as $meta => $field ) { if ( in_array( $meta, $args['exclude_fields'] ) ) { unset( $args['export_fields'][ $meta ] ); } else { - $header[] = $field['label']; + $header[ $meta ] = $field['label']; } } - if ( $wpmem->mod_reg == 1 ) { - $header[] = __( 'Activated?', 'wp-members'); + if ( 1 == $wpmem->mod_reg ) { + $header['active'] = __( 'Activated?', 'wp-members'); } - if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { - $header[] = __( 'Subscription', 'wp-members' ); - $header[] = __( 'Expires', 'wp-members' ); + if ( defined( 'WPMEM_EXP_MODULE' ) && 1 == $wpmem->use_exp ) { + $header['exp_type'] = __( 'Subscription', 'wp-members' ); + $header['expires'] = __( 'Expires', 'wp-members' ); } - $header[] = __( 'Registered', 'wp-members' ); - $header[] = __( 'IP', 'wp-members' ); + $header['user_registered'] = __( 'Registered', 'wp-members' ); + $header['wpmem_reg_ip'] = __( 'IP', 'wp-members' ); + + /** + * Filters user export header row before assembly. + * + * @since 3.2.1 + * + * @param array $header The header column values + */ + $header = apply_filters( 'wpmem_user_export_header', $header ); fputcsv( $handle, $header ); @@ -98,40 +108,41 @@ function wpmem_export_users( $args, $users = null ) { $user_info = get_userdata( $user ); $wp_user_fields = [ 'user_email', 'user_nicename', 'user_url', 'display_name' ]; - $row = array(); + $row = array( 'ID' => $user_info->ID, 'username' => $user_info->user_login ); foreach ( $args['export_fields'] as $meta => $field ) { if ( in_array( $meta, $wp_user_fields ) ) { - $row[] = $user_info->{$meta}; + $row[ $meta ] = $user_info->{$meta}; } else { $raw_data = get_user_meta( $user, $meta, true ); - $row[] = ( $args['entity_decode'] ) ? html_entity_decode( $raw_data ) : $raw_data; + $row[ $meta ] = ( $args['entity_decode'] ) ? html_entity_decode( $raw_data ) : $raw_data; } } - $row = array_merge( - [ - $user_info->ID, - $user_info->user_login, - ], - $row - ); - - if ( $wpmem->mod_reg == 1 ) { - $row[] = get_user_meta( $user, 'active', 1 ) ? __( 'Yes' ) : __( 'No' ); + if ( 1 == $wpmem->mod_reg ) { + $row['active'] = get_user_meta( $user, 'active', 1 ) ? __( 'Yes' ) : __( 'No' ); } - if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { - $row[] = get_user_meta( $user, 'exp_type', true ); - $row[] = get_user_meta( $user, 'expires', true ); + if ( defined( 'WPMEM_EXP_MODULE' ) && 1 == $wpmem->use_exp ) { + $row['exp_type'] = get_user_meta( $user, 'exp_type', true ); + $row['expires'] = get_user_meta( $user, 'expires', true ); } - $row[] = $user_info->user_registered; - $row[] = get_user_meta( $user, 'wpmem_reg_ip', true ); + $row['user_registered'] = $user_info->user_registered; + $row['wpmem_reg_ip'] = get_user_meta( $user, 'wpmem_reg_ip', true ); + + /** + * Filter the user data before assembly. + * + * @since 3.2.1 + * + * @param array $row The user data row + */ + $row = apply_filters( 'wpmem_user_export_row', $row ); fputcsv( $handle, $row ); // Update the user record as being exported. - if ( 'all' != $args['export'] ){ + if ( 'all' != $args['export'] ) { update_user_meta( $user, 'exported', 1 ); } } From d60862de54aaf41a8a7dbd6db00af14f0234f6cf Mon Sep 17 00:00:00 2001 From: Chad Butler Date: Thu, 19 Jul 2018 17:45:06 -0400 Subject: [PATCH 0831/1694] refine post status update interface --- admin/css/admin.css | 9 +++++++++ admin/js/admin.js | 18 +++++++++++++++++ admin/post.php | 47 +++++++++++++++++++++------------------------ 3 files changed, 49 insertions(+), 25 deletions(-) diff --git a/admin/css/admin.css b/admin/css/admin.css index ba0434c8..1124f62d 100644 --- a/admin/css/admin.css +++ b/admin/css/admin.css @@ -64,4 +64,13 @@ } #wpmem_post_block_status { font-weight: 600; +} +#wpmem_post_icon_0 { + color: red; +} +#wpmem_post_icon_1 { + color: green; +} +#wpmem_post_icon_2 { + color: black; } \ No newline at end of file diff --git a/admin/js/admin.js b/admin/js/admin.js index 188daae1..a47e0d17 100644 --- a/admin/js/admin.js +++ b/admin/js/admin.js @@ -199,10 +199,28 @@ $("#wpmem_cancel_block_status").click(function() { $("#wpmem_block").hide('normal'); $("#wpmem_edit_block_status").show(); + $("#wpmem_post_block_status").text($("input[name=wpmem_block_original_label]").val()); + $('#wpmem_post_block_status_' + $('input[name=wpmem_block_original_value]')).val().prop("checked", true); }); $("#wpmem_ok_block_status").click(function() { $("#wpmem_block").hide('normal'); $("#wpmem_edit_block_status").show(); + $("#wpmem_post_block_status").text($("input[name=wpmem_block]:checked + label").text()); + if($('#wpmem_block_status_0').is(':checked')) { + $("#wpmem_post_icon_0").show(); + $("#wpmem_post_icon_1").hide(); + $("#wpmem_post_icon_2").hide(); + } + if($('#wpmem_block_status_1').is(':checked')) { + $("#wpmem_post_icon_0").hide(); + $("#wpmem_post_icon_1").show(); + $("#wpmem_post_icon_2").hide(); + } + if($('#wpmem_block_status_2').is(':checked')) { + $("#wpmem_post_icon_0").hide(); + $("#wpmem_post_icon_1").hide(); + $("#wpmem_post_icon_2").show(); + } }); }); })(jQuery); \ No newline at end of file diff --git a/admin/post.php b/admin/post.php index 598170ee..76207882 100644 --- a/admin/post.php +++ b/admin/post.php @@ -47,7 +47,7 @@ function wpmem_bulk_posts_action() { jQuery('
    Date: Mon, 13 Jan 2020 18:19:20 -0500 Subject: [PATCH 1181/1694] update setting membership expiration, includes "no gap" option --- .../admin/class-wp-members-products-admin.php | 21 +++++-- includes/class-wp-members-user.php | 58 ++++++++++++++++--- readme.txt | 48 +++++++-------- wp-members.php | 2 +- 4 files changed, 91 insertions(+), 38 deletions(-) diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index 5015fa8b..9d322fe1 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -156,7 +156,8 @@ function details_html( $post ) { $product_default = $this->get_meta( 'wpmem_product_default' ); $product_expires = $this->get_meta( 'wpmem_product_expires' ); $product_role = $this->get_meta( 'wpmem_product_role' ); - + $product_no_gap = $this->get_meta( 'wpmem_product_no_gap' ); + $product_expires = ( false !== $product_expires ) ? $product_expires[0] : $product_expires; $periods = array( __( 'Period', 'wp-members' ) . '|', __( 'Day', 'wp-members' ) . '|day', __( 'Week', 'wp-members' ) . '|week', __( 'Month', 'wp-members' ) . '|month', __( 'Year', 'wp-members' ) . '|year' ); @@ -166,11 +167,11 @@ function details_html( $post ) {

    : post_name ); ?>

    - > + />

    - > + />

    - > + /> @@ -187,6 +188,8 @@ function details_html( $post ) { 'wpmem_product_time_period', 'type'=>'select', 'value'=>$periods, 'compare'=>( ( isset( $period[1] ) ) ? $period[1] : '' ) ) ); ?> + + 'wpmem_product_no_gap', 'type'=>'checkbox', 'value'=>'1', 'compare'=>( ( isset( $product_no_gap ) ) && 1 == $product_no_gap ) ? $product_no_gap : '' ) ); ?>

    ' : $form; + /** * Filter the generated HTML of the entire form. * diff --git a/readme.txt b/readme.txt index df9fcf1d..efe01646 100644 --- a/readme.txt +++ b/readme.txt @@ -2,7 +2,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 -Tested up to: 5.3 +Tested up to: 5.4 Stable tag: 3.3.2.2 License: GPLv2 @@ -131,6 +131,8 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. * Set a default product for publishing posts/pages. * Updated activation/deactivation processing so that a (admin) user cannot activate or deactivate themselves. Also, if a user has "edit_users" capability, they can log in without being activated. * Load email "from" address with main settings rather than when email is sent. This corrects issues with Advanced Options extension, and also keeps the value loaded for use outside of WP-Members email function. +* WP 5.4 adds the wp_nav_menu_item_custom_fields action, so now WP-Members only loads its custom walker if WP is 5.3 or lower. +* Image file field type now shows an immediate preview when the "choose file" button is clicked and an image selected (both profile update and new registration). = 3.3.2 = @@ -175,8 +177,6 @@ Including all 3.3.0.x patches: = 3.3.0 = -* @todo Need to resolve duplicate wpmem_login_form_defaults. (maybe took care of itself with backing out of _args deprecation) - * REMOVED [wp-members] shortcode tag. THIS TAG IS OBSOLETE WILL NO LONGER FUNCTION. See: https://rocketgeek.com/shortcodes/list-of-replacement-shortcodes/ * REMOVED tinymce button for shortcodes as no longer necessary with gutenberg. * Deprecated wpmem_inc_login_args filter, use wpmem_login_form_defaults instead. From 7f1b77cb562895158faa187e9a11e37c07ab5271 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 31 Mar 2020 20:01:38 -0400 Subject: [PATCH 1219/1694] don't add javascript (for now) for file field --- includes/class-wp-members-forms.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index fd9b8210..769badbf 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -129,7 +129,7 @@ function create_form_field( $args ) { $accept = ''; } $class = ( 'textbox' == $class ) ? "file" : $this->sanitize_class( $class ); - $str = "'; + $str = "'; break; case "checkbox": From 5454848332eadd63b2e86fa927b16862f7b5b590 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 1 Apr 2020 08:43:34 -0400 Subject: [PATCH 1220/1694] wpmem_login_failed_args now passes $args (reparsed with $defaults) --- includes/legacy/dialogs.php | 5 +++-- readme.txt | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index cabdbba6..f99da115 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -60,11 +60,12 @@ function wpmem_inc_loginfailed() { * Filter the login failed dialog arguments. * * @since 2.9.0 + * @since 3.3.3 Should pass defaults to filter. * * @param array An array of arguments to merge with defaults. */ - $args = apply_filters( 'wpmem_login_failed_args', '' ); - + $args = apply_filters( 'wpmem_login_failed_args', $defaults ); + // Merge $args with defaults. $args = wp_parse_args( $args, $defaults ); diff --git a/readme.txt b/readme.txt index efe01646..d9fc0feb 100644 --- a/readme.txt +++ b/readme.txt @@ -133,6 +133,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. * Load email "from" address with main settings rather than when email is sent. This corrects issues with Advanced Options extension, and also keeps the value loaded for use outside of WP-Members email function. * WP 5.4 adds the wp_nav_menu_item_custom_fields action, so now WP-Members only loads its custom walker if WP is 5.3 or lower. * Image file field type now shows an immediate preview when the "choose file" button is clicked and an image selected (both profile update and new registration). +* wpmem_login_failed_args updated to pass $args (similar to other _args filters in the plugin, now parses defaults). = 3.3.2 = From 56275acded03f9111bacc0351f40cf30b72b5aa0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 22 Apr 2020 09:44:28 -0400 Subject: [PATCH 1221/1694] fix undefined $file_type error --- includes/class-wp-members-forms.php | 4 ++-- readme.txt | 5 ++++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 769badbf..57a42fe7 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -72,7 +72,7 @@ function create_form_field( $args ) { $placeholder = ( isset( $args['placeholder'] ) ) ? $args['placeholder'] : false; $pattern = ( isset( $args['pattern'] ) ) ? $args['pattern'] : false; $title = ( isset( $args['title'] ) ) ? $args['title'] : false; - $file_types = ( isset( $args['file_types'] ) ) ? $args['file_types'] : false; + $file_types = ( isset( $args['file_types'] ) ) ? $args['file_types'] : false; // Handle field creation by type. switch ( $type ) { @@ -129,7 +129,7 @@ function create_form_field( $args ) { $accept = ''; } $class = ( 'textbox' == $class ) ? "file" : $this->sanitize_class( $class ); - $str = "'; + $str = "'; break; case "checkbox": diff --git a/readme.txt b/readme.txt index d9fc0feb..7d76ac4b 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 5.4 -Stable tag: 3.3.2.2 +Stable tag: 3.3.3 License: GPLv2 == Description == @@ -124,6 +124,9 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. == Changelog == += 3.3.4 = +* Fixed logic in upload input type (image or file) to correct undefined variable ($file_type). + = 3.3.3 = * If WooCommerce is active, any standard WC user meta fields are removed from the WP-Members additional fields in the User Profile Edit (since they already display in the WC field blocks). From bc3ddbb9c95c814ec5842fb732b8dcf123feaf1c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 22 Apr 2020 09:46:55 -0400 Subject: [PATCH 1222/1694] check if wpmem_renew() exists before calling it. --- includes/class-wp-members-shortcodes.php | 6 +++++- readme.txt | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index cbd04851..cb175854 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -458,7 +458,11 @@ function user_profile( $atts, $content, $tag ) { break; case "renew": - $content = wpmem_renew(); + if ( function_exists( 'wpmem_renew' ) ) { + $content = wpmem_renew(); + } else { + $content = ''; + } break; default: diff --git a/readme.txt b/readme.txt index 7d76ac4b..0ba6735a 100644 --- a/readme.txt +++ b/readme.txt @@ -126,6 +126,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. = 3.3.4 = * Fixed logic in upload input type (image or file) to correct undefined variable ($file_type). +* Added function_exists check for wpmem_renew() (a PayPal extension function used in the core plugin). = 3.3.3 = From a9444367b56b915604ff4a997835c8f02ee858e1 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 22 Apr 2020 09:49:54 -0400 Subject: [PATCH 1223/1694] update product shortcode message to use product_restricted message --- includes/class-wp-members-shortcodes.php | 4 ++-- readme.txt | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index cb175854..dce299f3 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -306,8 +306,8 @@ function logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) { } elseif ( true === $atts['msg'] || "true" === strtolower( $atts['msg'] ) ) { $do_return = true; $settings = array( - 'wrapper_before' => '
    ', - 'msg' => sprintf( __( 'Sorry, your account does not currently have access to %s content', 'wp-members' ), $wpmem->membership->products[ $membership ]['title'] ), + 'wrapper_before' => '
    ', + 'msg' => sprintf( $wpmem->get_text( 'product_restricted' ), $wpmem->membership->products[ $membership ]['title'] ), 'wrapper_after' => '
    ', ); /** diff --git a/readme.txt b/readme.txt index 0ba6735a..77c0c31d 100644 --- a/readme.txt +++ b/readme.txt @@ -127,6 +127,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. = 3.3.4 = * Fixed logic in upload input type (image or file) to correct undefined variable ($file_type). * Added function_exists check for wpmem_renew() (a PayPal extension function used in the core plugin). +* Updated product access shortcode error message to use the product_restricted message and changed the class to product_restricted_msg = 3.3.3 = From 0fcb9180d4da0e158c1ec34ba06aa3abfd6dbcf9 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 22 Apr 2020 09:51:42 -0400 Subject: [PATCH 1224/1694] fixed wpmem_a_extens_user() typo --- includes/class-wp-members-user-profile.php | 4 ++-- readme.txt | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-user-profile.php b/includes/class-wp-members-user-profile.php index 01cc3fe2..65fb57ce 100644 --- a/includes/class-wp-members-user-profile.php +++ b/includes/class-wp-members-user-profile.php @@ -501,8 +501,8 @@ public static function _show_expiration( $user_id ) { */ if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { if ( ( $wpmem->mod_reg == 1 && get_user_meta( $user_id, 'active', true ) == 1 ) || ( $wpmem->mod_reg != 1 ) ) { - if ( function_exists( 'wpmem_a_extenduser' ) ) { - wpmem_a_extenduser( $user_id ); + if ( function_exists( 'wpmem_a_extend_user' ) ) { + wpmem_a_extend_user( $user_id ); } } } diff --git a/readme.txt b/readme.txt index 77c0c31d..eabd3d09 100644 --- a/readme.txt +++ b/readme.txt @@ -127,6 +127,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. = 3.3.4 = * Fixed logic in upload input type (image or file) to correct undefined variable ($file_type). * Added function_exists check for wpmem_renew() (a PayPal extension function used in the core plugin). +* Fixed function name typo for wpmem_a_extend_user() (a PayPal extension function used in the core plugin). * Updated product access shortcode error message to use the product_restricted message and changed the class to product_restricted_msg = 3.3.3 = From cac6e68a810acb71a1073fa92c41076b35d61fd3 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 22 Apr 2020 09:52:49 -0400 Subject: [PATCH 1225/1694] inline documentation for wp_nav_menu_item_custom_fields action in walker class --- .../walkers/class-wp-members-walker-nav-menu.php | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/includes/walkers/class-wp-members-walker-nav-menu.php b/includes/walkers/class-wp-members-walker-nav-menu.php index 5df5c38c..0c1529c3 100644 --- a/includes/walkers/class-wp-members-walker-nav-menu.php +++ b/includes/walkers/class-wp-members-walker-nav-menu.php @@ -190,8 +190,18 @@ public function start_el( &$output, $item, $depth = 0, $args = array(), $id = 0

    diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index dce299f3..8a1efca1 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -130,6 +130,13 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { break; case in_array( 'register', $atts ): + + // Set up register form args. + $reg_form_args = array( 'tag' => 'new' ); + if ( isset( $redirect_to ) ) { + $reg_form_args['redirect_to'] = $redirect_to; + } + if ( is_user_logged_in() && '1' != $customizer ) { /* * If the user is logged in, return any nested content (if any) @@ -139,7 +146,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { } elseif ( is_user_logged_in() && is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) { $wpmem_themsg = __( "This is a generic message to display the form message dialog in the Customizer.", 'wp-members' ); $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); - $content .= wpmem_register_form( 'new', $redirect_to ); + $content .= wpmem_register_form( $reg_form_args ); } else { if ( $wpmem->regchk == 'loginfailed' ) { $content = wpmem_inc_loginfailed() . wpmem_inc_login( 'login', $redirect_to ); @@ -151,7 +158,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; } $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ) : ''; - $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login( 'login', $redirect_to ) : wpmem_register_form( 'new', $redirect_to ); + $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login( 'login', $redirect_to ) : wpmem_register_form( $reg_form_args ); } break; diff --git a/includes/class-wp-members-shortcodes.php.bak b/includes/class-wp-members-shortcodes.php.bak new file mode 100644 index 00000000..dce299f3 --- /dev/null +++ b/includes/class-wp-members-shortcodes.php.bak @@ -0,0 +1,813 @@ +regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to ); + } + break; + + case in_array( 'register', $atts ): + if ( is_user_logged_in() && '1' != $customizer ) { + /* + * If the user is logged in, return any nested content (if any) + * or the default bullet links if no nested content. + */ + $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'register' ); + } elseif ( is_user_logged_in() && is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) { + $wpmem_themsg = __( "This is a generic message to display the form message dialog in the Customizer.", 'wp-members' ); + $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content .= wpmem_register_form( 'new', $redirect_to ); + } else { + if ( $wpmem->regchk == 'loginfailed' ) { + $content = wpmem_inc_loginfailed() . wpmem_inc_login( 'login', $redirect_to ); + break; + } + // @todo Can this be moved into another function? Should $wpmem get an error message handler? + if ( $wpmem->regchk == 'captcha' ) { + global $wpmem_captcha_err; + $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; + } + $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ) : ''; + $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login( 'login', $redirect_to ) : wpmem_register_form( 'new', $redirect_to ); + } + break; + + case in_array( 'password', $atts ): + $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + break; + + case in_array( 'user_edit', $atts ): + $content = wpmem_page_user_edit( $wpmem->regchk, $content ); + break; + + case in_array( 'forgot_username', $atts ): + $content = wpmem_page_forgot_username( $wpmem->regchk, $content ); + break; + + case in_array( 'customizer_login', $atts ): + $content = wpmem_inc_login( 'login', $redirect_to ); + break; + + case in_array( 'customizer_register', $atts ): + $content = wpmem_register_form( 'new', $redirect_to ); + break; + + } + + /* + * This is for texturizing. Need to work it into an argument in the function call as to whether the + * [wpmem_txt] shortcode is even included. @todo - Is this a temporary solution or is there something + * cleaner that can be worked out? + */ + if ( 1 == $wpmem->texturize ) { + if ( array_key_exists( 'texturize', $atts ) && $atts['texturize'] == 'false' ) { + $content = str_replace( array( '[wpmem_txt]', '[/wpmem_txt]' ), array( '', '' ), $content ); + } + if ( strstr( $content, '[wpmem_txt]' ) ) { + // Fixes the wptexturize. + remove_filter( 'the_content', 'wpautop' ); + remove_filter( 'the_content', 'wptexturize' ); + add_filter( 'the_content', array( 'WP_Members', 'texturize' ), 999 ); + } + } // End texturize functions + } + return do_shortcode( $content ); + } + + /** + * Handles the logged in status shortcodes [wpmem_logged_in]. + * + * There are several attributes that can be used with the shortcode: + * in|out, sub for subscription only info, id, and role. IDs and roles + * can be comma separated values for multiple users and roles. + * + * @since 3.0.0 + * @since 3.2.0 Moved to WP_Members_Shortcodes::logged_in(). + * @since 3.2.0 Added attributes for meta key/value pairs. + * @since 3.2.3 Added product attribute. + * @since 3.3.0 Added compare attribute for meta key/value compare (=|!=). + * + * @global object $wpmem The WP_Members object. + * + * @param array $atts { + * The shortcode attributes. + * + * @type string $status + * @type int $id + * @type string $role + * @type string $sub + * @type string $meta_key + * @type string $meta_value + * @type string $product + * @type string $membership + * } + * @param string $content + * @param string $tag + * @return string $content + */ + function logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) { + + global $wpmem; + + // Handles the 'status' attribute. + if ( ( isset( $atts['status'] ) ) || $tag == 'wpmem_logged_in' ) { + + $do_return = false; + + // If there is a status attribute of "out" and the user is not logged in. + $do_return = ( isset( $atts['status'] ) && $atts['status'] == 'out' && ! is_user_logged_in() ) ? true : $do_return; + + if ( is_user_logged_in() ) { + + // In case $current_user is not already global + $current_user = wp_get_current_user(); + + // If there is a status attribute of "in" and the user is logged in. + $do_return = ( isset( $atts['status'] ) && $atts['status'] == 'in' ) ? true : $do_return; + + // If using the wpmem_logged_in tag with no attributes & the user is logged in. + $do_return = ( $tag == 'wpmem_logged_in' && ( ! $atts ) ) ? true : $do_return; + + // If there is an "id" attribute and the user ID is in it. + if ( isset( $atts['id'] ) ) { + $ids = explode( ',', $atts['id'] ); + foreach ( $ids as $id ) { + if ( trim( $id ) == $current_user->ID ) { + $do_return = true; + } + } + } + + // If there is a "role" attribute and the user has a matching role. + if ( isset( $atts['role'] ) ) { + $roles = explode( ',', $atts['role'] ); + if ( wpmem_user_has_role( $roles ) ) { + $do_return = true; + } + } + + // If there is a status attribute of "sub" and the user is logged in. + if ( ( isset( $atts['status'] ) ) && $atts['status'] == 'sub' ) { + if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { + if ( ! wpmem_chk_exp() ) { + $do_return = true; + } elseif ( $atts['msg'] == "true" ) { + $do_return = true; + $content = wpmem_sc_expmessage(); + } + } + } + + // If there is a meta key attribute. + if ( isset( $atts['meta_key'] ) ) { + $do_return = false; + $value = ( isset( $atts['meta_value'] ) ) ? $atts['meta_value'] : false; + if ( ! isset( $atts['compare'] ) || "=" == $atts['compare'] ) { + if ( wpmem_user_has_meta( $atts['meta_key'], $value ) ) { + $do_return = true; + } + } + if ( isset( $atts['compare'] ) && "!=" == $atts['compare'] ) { + if ( ! wpmem_user_has_meta( $atts['meta_key'], $value ) ) { + $do_return = true; + } + } + } + + // If there is a product attribute. + if ( isset( $atts['product'] ) || isset( $atts['membership'] ) ) { + // @todo What if attribute is comma separated/multiple? + $membership = ( isset( $atts['membership'] ) ) ? $atts['membership'] : $atts['product']; + if ( wpmem_user_has_access( $membership ) ) { + $do_return = true; + } elseif ( true === $atts['msg'] || "true" === strtolower( $atts['msg'] ) ) { + $do_return = true; + $settings = array( + 'wrapper_before' => '
    ', + 'msg' => sprintf( $wpmem->get_text( 'product_restricted' ), $wpmem->membership->products[ $membership ]['title'] ), + 'wrapper_after' => '
    ', + ); + /** + * Filter the access failed message. + * + * @since 3.3.0 + * @since 3.3.3 Changed from 'wpmem_sc_product_access_denied' + * + * @param array $settings. + */ + $settings = apply_filters( 'wpmem_sc_product_restricted', $settings ); + $content = $settings['wrapper_before'] . $settings['msg'] . $settings['wrapper_after']; + } + } + + // Prevents display if the current page is the user profile and an action is being handled. + if ( ( wpmem_current_url( true, false ) == wpmem_profile_url() ) && isset( $_GET['a'] ) ) { + $do_return = false; + } + + } + + // Return content (or empty content) depending on the result of the above logic. + return ( $do_return ) ? do_shortcode( $content ) : ''; + } + } + + /** + * Handles the [wpmem_logged_out] shortcode. + * + * @since 3.0.0 + * @since 3.2.0 Moved to WP_Members_Shortcodes::logged_out(). + * + * @param array $atts + * @param string $content + * @param string $tag + * @return string $content + */ + function logged_out( $atts, $content = null, $tag ) { + return ( ! is_user_logged_in() ) ? do_shortcode( $content ) : ''; + } + + /** + * User count shortcode [wpmem_show_count]. + * + * User count displays a total user count or a count of users by specific + * role (role="some_role"). It also accepts attributes for counting users + * by a meta field (key="meta_key" value="meta_value"). A label can be + * displayed using the attribute label (label="Some label:"). + * + * @since 3.0.0 + * @since 3.1.5 Added total user count features. + * @since 3.2.0 Moved to WP_Members_Shortcodes::user_count(). + * + * @global object $wpdb The WordPress database object. + * @param array $atts { + * The shortcode attributes. + * + * @type string $key + * @type string $value + * @type string $role + * @type string $label + * } + * @param string $content The shortcode content. + * @return string $content + */ + function user_count( $atts, $content = null ) { + if ( isset( $atts['key'] ) && isset( $atts['value'] ) ) { + // If by meta key. + global $wpdb; + $user_count = $wpdb->get_var( $wpdb->prepare( + "SELECT COUNT(*) FROM $wpdb->usermeta WHERE meta_key = %s AND meta_value = %s", + $atts['key'], + $atts['value'] + ) ); + } else { + // If no meta, it's a total count. + $users = count_users(); + $user_count = ( isset( $atts['role'] ) ) ? $users['avail_roles'][ $atts['role'] ] : $users['total_users']; + } + + // Assemble the output and return. + $content = ( isset( $atts['label'] ) ) ? $atts['label'] . ' ' . $user_count : $content . ' ' . $user_count; + return do_shortcode( $content ); + } + + /** + * Creates the user profile dashboard area [wpmem_profile]. + * + * @since 3.1.0 + * @since 3.1.2 Added function arguments. + * @since 3.2.0 Moved to WP_Members_Shortcodes::user_profile(). + * + * @global object $wpmem The WP_Members object. + * @global string $wpmem_themsg The WP-Members message container. + * @param string $atts { + * The shortcode attributes. + * + * @type string $redirect_to + * @type string $register "hide" removes registration form, any other value is false. + * } + * @param string $content + * @param string $tag + * @return string $content + */ + function user_profile( $atts, $content, $tag ) { + + // @todo $redirect_to is not currently used in the user profile. + $redirect_to = ( isset( $atts['redirect_to'] ) ) ? $atts['redirect_to'] : null; + $hide_register = ( isset( $atts['register'] ) && 'hide' == $atts['register'] ) ? true : false; + + global $wpmem, $wpmem_themsg; + + $content = ''; + + if ( $wpmem->regchk == "captcha" ) { + global $wpmem_captcha_err; + $wpmem_themsg = $wpmem->get_text( 'reg_captcha_err' ) . '

    ' . $wpmem_captcha_err; + } + + if ( $wpmem->regchk == "loginfailed" ) { + return wpmem_inc_loginfailed(); + } + + if ( is_user_logged_in() ) { + + switch( $wpmem->action ) { + + case "edit": + $content = $content . wpmem_register_form( 'edit' ); + break; + + case "update": + // Determine if there are any errors/empty fields. + if ( $wpmem->regchk == "updaterr" || $wpmem->regchk == "email" ) { + $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_register_form( 'edit' ); + } else { + //Case "editsuccess". + $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_inc_memberlinks(); + } + break; + + case "pwdchange": + $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + $content = ( 'pwdchangesuccess' == $wpmem->regchk ) ? $content . wpmem_inc_memberlinks() : $content; + break; + + case "renew": + if ( function_exists( 'wpmem_renew' ) ) { + $content = wpmem_renew(); + } else { + $content = ''; + } + break; + + default: + $content = wpmem_inc_memberlinks(); + break; + } + + } else { + + if ( $wpmem->action == 'register' && ! $hide_register ) { + + switch( $wpmem->regchk ) { + + case "success": + $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_inc_login(); + break; + + default: + $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_register_form(); + break; + } + + } elseif ( $wpmem->action == 'pwdreset' ) { + + $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + + } elseif( $wpmem->action == 'getusername' ) { + + $content = wpmem_page_forgot_username( $wpmem->regchk, $content ); + + } else { + + $content = $content . wpmem_inc_login( 'members' ); + $content = ( ! $hide_register ) ? $content . wpmem_register_form() : $content; + } + } + + return $content; + } + + /** + * Log in/out shortcode [wpmem_loginout]. + * + * @since 3.1.1 + * @since 3.1.6 Uses wpmem_loginout(). + * @since 3.2.0 Moved to WP_Members_Shortcodes::loginout(). + * + * @param array $atts { + * The shortcode attributes. + * + * @type string $login_redirect_to The url to redirect to after login (optional). + * @type string $logout_redirect_to The url to redirect to after logout (optional). + * @type string $login_text Text for the login link (optional). + * @type string $logout_text Text for the logout link (optional). + * } + * @param string $content + * @param string $tag + * @return string $content + */ + function loginout( $atts, $content, $tag ) { + $link = wpmem_loginout( $atts ); + return do_shortcode( $link ); + } + + /** + * Function to handle field shortcodes [wpmem_field]. + * + * Shortcode to display the data for a given user field. Requires + * that a field meta key be passed as an attribute. Can either of + * the following: + * - [wpmem_field field="meta_key"] + * - [wpmem_field meta_key] + * + * Other attributes: + * + * - id (numeric user ID or "get" to retrieve uid from query string. + * - underscores="true" strips underscores from the displayed value. + * - display="raw" displays the stored value for dropdowns, radios, files. + * - size(thumbnail|medium|large|full|w,h): image field only. + * - clickable + * - label + * + * Filter the end result with `wpmem_field_shortcode`. + * + * @since 3.1.2 + * @since 3.1.4 Changed to display value rather than stored value for dropdown/multicheck/radio. + * @since 3.1.5 Added display attribute, meta key as a direct attribute, and image/file display. + * @since 3.2.0 Moved to WP_Members_Shortcodes::fields(). + * @since 3.2.0 Added clickable attribute. + * @since 3.2.5 Added label attribute. + * + * @global object $wpmem The WP_Members object. + * @param array $atts { + * The shortcode attributes. + * + * @type string {meta_key} + * @type string $field + * @type int $id + * @type string $underscores + * @type string $display + * @type string $size + * @type string $clickable default:false + * @type string $label default:false + * } + * @param string $content Any content passed with the shortcode (default:null). + * @param string $tag The shortcode tag (wpmem_form). + * @return string $content Content to return. + */ + function fields( $atts, $content = null, $tag ) { + + // What field? + $field = ( isset( $atts[0] ) ) ? $atts[0] : $atts['field']; + + // What user? + if ( isset( $atts['id'] ) ) { + $the_ID = ( $atts['id'] == 'get' ) ? filter_var( wpmem_get( 'uid', '', 'get' ), FILTER_SANITIZE_NUMBER_INT ) : $atts['id']; // Ultimately, the_ID will be checked to determine if it is numeric by WP_User::get_data_by(). + } else { + $the_ID = get_current_user_id(); + } + $user_info = get_userdata( $the_ID ); + + // If there is userdata. + if ( $user_info && isset( $user_info->{$field} ) ) { + + global $wpmem; + $fields = wpmem_fields(); + $field_type = ( isset( $fields[ $field ]['type'] ) ) ? $fields[ $field ]['type'] : 'native'; // @todo Is this needed? It seems to set the type to "native" if not set. + + $user_info_field = ( isset( $field ) && is_object( $user_info ) ) ? $user_info->{$field} : ''; + $result = false; + + // Handle each field type. + switch ( $field_type ) { + + // Select and radio groups have single selections. + case 'select': + case 'radio': + $result = ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) ? $user_info_field : $fields[ $field ]['options'][ $user_info_field ]; + break; + + // Multiple select and multiple checkbox have multiple selections. + case 'multiselect': + case 'multicheckbox': + if ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) { + $result = $user_info_field; + } else { + $saved_vals = explode( $fields[ $field ]['delimiter'], $user_info_field ); + $result = ''; $x = 1; + foreach ( $saved_vals as $value ) { + $result.= ( $x > 1 ) ? ', ' : ''; $x++; + $result.= $fields[ $field ]['options'][ $value ]; + } + } + break; + + case 'file': + case 'image': + if ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) { + $result = $user_info_field; + } else { + if ( 'file' == $field_type ) { + $attachment_url = wp_get_attachment_url( $user_info_field ); + $result = ( $attachment_url ) ? '' . get_the_title( $user_info_field ) . '' : ''; + } else { + $size = 'thumbnail'; + if ( isset( $atts['size'] ) ) { + $sizes = array( 'thumbnail', 'medium', 'large', 'full' ); + $size = ( ! in_array( $atts['size'], $sizes ) ) ? explode( ",", $atts['size'] ) : $atts['size']; + } + $image = wp_get_attachment_image_src( $user_info_field, $size ); + $result = ( $image ) ? '' : ''; + } + } + break; + + case 'textarea': + // Handle line breaks for textarea fields + $result = ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) ? $user_info_field : nl2br( $user_info_field ); + break; + + case 'date': + if ( isset( $atts['format'] ) ) { + // Formats date: https://secure.php.net/manual/en/function.date.php + $result = ( '' != $user_info_field ) ? date( $atts['format'], strtotime( $user_info_field ) ) : ''; + } else { + // Formats date to whatever the WP setting is. + $result = ( '' != $user_info_field ) ? date_i18n( get_option( 'date_format' ), strtotime( $user_info_field ) ) : ''; + } + break; + + // Handle all other fields. + default: + $result = ( ! $result ) ? $user_info_field : $result; + break; + } + + // Remove underscores from value if requested (default: on). + if ( isset( $atts['underscores'] ) && 'off' == $atts['underscores'] && $user_info ) { + $result = str_replace( '_', ' ', $result ); + } + + $content = ( $content ) ? $result . $content : $result; + + // Make it clickable? + $content = ( isset( $atts['clickable'] ) && ( true == $atts['clickable'] || 'true' == $atts['clickable'] ) ) ? make_clickable( $content ) : $content; + + // Display field label? + $content = ( isset( $fields[ $field ] ) && isset( $atts['label'] ) && ( true == $atts['label'] ) ) ? $fields[ $field ]['label'] . ": " . $content : $content; + } + + /** + * Filters the field shortcode before returning value. + * + * @since 3.2.5 + * + * @param string $content + * @param array $atts + */ + $content = apply_filters( 'wpmem_field_shortcode', $content, $atts ); + + return do_shortcode( $content ); + } + + /** + * Logout link shortcode [wpmem_logout]. + * + * @since 3.1.2 + * @since 3.2.0 Moved to WP_Members_Shortcodes::logout(). + * + * @param array $atts { + * The shortcode attributes. + * + * @type string $url + * } + * @param string $content + * @param string $tag + * @retrun string $content + */ + function logout( $atts, $content, $tag ) { + // Logout link shortcode. + if ( is_user_logged_in() && $tag == 'wpmem_logout' ) { + $link = ( isset( $atts['url'] ) ) ? add_query_arg( array( 'a'=>'logout', 'redirect_to'=>$atts['url'] ) ) : add_query_arg( 'a', 'logout' ); + $text = ( $content ) ? $content : __( 'Click here to log out.', 'wp-members' ); + return do_shortcode( '' . $text . '' ); + } + } + + /** + * TOS shortcode [wpmem_tos]. + * + * @since 3.1.2 + * @since 3.2.0 Moved to WP_Members_Shortcodes::tos(). + * + * @param array $atts { + * The shortcode attributes. + * + * @type string $url + * } + * @param string $content + * @param string $tag + * @retrun string $content + */ + function tos( $atts, $content, $tag ) { + return esc_url( $atts['url'] ); + } + + /** + * Display user avatar. + * + * @since 3.1.7 + * @since 3.2.0 Moved to WP_Members_Shortcodes::avatar(). + * + * @param array $atts { + * The shortcode attributes. + * + * @type string $id The user email or id. + * @type int $size Avatar size (square) in pixels. + * } + * @param string $content + * @param string $tag + * @retrun string $content + */ + function avatar( $atts, $content, $tag ) { + $content = ''; + $size = ( isset( $atts['size'] ) ) ? $atts['size'] : ''; + if ( isset( $atts['id'] ) ) { + $content = get_avatar( $atts['id'], $size ); + } elseif ( is_user_logged_in() ) { + // If the user is logged in and this isn't specifying a user ID, return the current user avatar. + global $current_user; + wp_get_current_user(); + $content = get_avatar( $current_user->ID, $size ); + } + return do_shortcode( $content ); + } + + /** + * Generates a login link with a return url. + * + * @since 3.1.7 + * @since 3.2.0 Moved to WP_Members_Shortcodes::login_link(). + * + * @param array $atts { + * The shortcode attributes. + * } + * @param string $content + * @param string $tag + * @return string $content + */ + function login_link( $atts, $content, $tag ) { + if ( 'wpmem_reg_link' == $tag ) { + $text = ( $content ) ? $content : __( 'Register' ); + $link = add_query_arg( 'redirect_to', wpmem_current_url(), wpmem_register_url() ); + } else { + $text = ( $content ) ? $content : __( 'Log In' ); + $link = wpmem_login_url( wpmem_current_url() ); + } + $content = '' . $text . ''; + return do_shortcode( $content ); + } + + /** + * Generate a nonce for a WP-Members form. + * + * For situations where a hardcoded form may exist, this shortcode + * can output the appropriate nonce. + * + * @since 3.3.0 + * + * @param array $atts { + * The shortcode attributes. + * + * $form string The form to generate the nonce for (register|update|login) + * } + * $param string $content + * @param string $tag + * @return string $content + */ + function form_nonce( $atts, $content, $tag ) { + $nonce = ( isset( $atts['form'] ) ) ? $atts['form'] : 'register'; + $content = wpmem_form_nonce( $nonce, false ); + return do_shortcode( $content ); + } +} + +// End of file. \ No newline at end of file From e3f07a81c9969ace5f9958418c3aba279b06fe54 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 3 May 2020 13:40:54 -0400 Subject: [PATCH 1230/1694] updated captcha class for implementation in api --- includes/class-wp-members-captcha.php | 74 ++++++++++++++++++++------- 1 file changed, 56 insertions(+), 18 deletions(-) diff --git a/includes/class-wp-members-captcha.php b/includes/class-wp-members-captcha.php index e68297a4..8b377adf 100644 --- a/includes/class-wp-members-captcha.php +++ b/includes/class-wp-members-captcha.php @@ -16,6 +16,22 @@ } class WP_Members_Captcha { + + /** + * Display a CAPTCHA. + * + * @since 3.3.4 + * + * @param string $type Type of captcha to display. + * @param array $keys Google reCAPTCHA keys (if used). + */ + static function show( $type, $keys = false ) { + if ( 'rs_captcha' == $type ) { + return self::rs_captcha(); + } else { + return self::recaptcha( $keys ); + } + } /** * Create reCAPTCHA form. @@ -130,38 +146,60 @@ static function rs_captcha() { captcha' ); } else { - return; + return "Really Simple CAPTCHA is not enabled"; } } /** - * Process registration captcha. + * Process a captcha. * * @since 3.1.6 * @since 3.3.0 Ported from wpmem_register_handle_captcha() in register.php. + * @since 3.3.4 Added argument to specify which captcha type to validate. * * @global $wpmem * @global $wpmem_themsg + * @param $which_captcha * @return $string */ - static function validate() { + static function validate( $which_captcha = false ) { global $wpmem, $wpmem_themsg; + + if ( ! $which_captcha ) { - // Get the captcha settings (api keys). - $wpmem_captcha = get_option( 'wpmembers_captcha' ); + // Get the captcha settings (api keys). + $wpmem_captcha = get_option( 'wpmembers_captcha' ); - /* - * @todo reCAPTCHA v1 is deprecated by Google. It is also no longer allowed - * to be set for new installs of WP-Members. It is NOT compatible with - * PHP 7.1 and is therefore fully obsolete. - */ - // If captcha is on, check the captcha. - if ( $wpmem->captcha == 1 && $wpmem_captcha['recaptcha'] ) { - $wpmem->captcha = 3; - } + /* + * @todo reCAPTCHA v1 is deprecated by Google. It is also no longer allowed + * to be set for new installs of WP-Members. It is NOT compatible with + * PHP 7.1 and is therefore fully obsolete. + */ + // If captcha is on, check the captcha. + if ( $wpmem->captcha == 1 && $wpmem_captcha['recaptcha'] ) { + $wpmem->captcha = 3; + } + + switch ( $wpmem->captcha ) { + case 1: + case 3: + $captcha = "recaptcha_v2"; + break; + case 4: + $captcha = "recaptcha_v3"; + break; + case 2: + default: + $captcha = "rs_captcha"; + break; + } + + } else { + $captcha = $which_captcha; + } - if ( 2 == $wpmem->captcha ) { + if ( 'rs_captcha' == $captcha ) { if ( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { // Validate Really Simple Captcha. $wpmem_captcha = new ReallySimpleCaptcha(); @@ -187,7 +225,7 @@ static function validate() { $privatekey = $wpmem_captcha['recaptcha']['private']; - if ( 3 == $wpmem->captcha && $wpmem_captcha['recaptcha'] ) { + if ( 'recaptcha_v2' == $captcha && $wpmem_captcha['recaptcha'] ) { $captcha = wpmem_get( 'g-recaptcha-response', false ); @@ -221,7 +259,7 @@ static function validate() { } return "empty"; } - } elseif ( 4 == $wpmem->captcha && $wpmem_captcha['recaptcha'] ) { + } elseif ( 'recaptcha_v3' == $captcha && $wpmem_captcha['recaptcha'] ) { $captcha = wpmem_get( 'recaptcha_response', false ); if ( $_SERVER['REQUEST_METHOD'] === 'POST' && false !== $captcha ) { @@ -246,6 +284,6 @@ static function validate() { } } - return "passed_captcha"; + return true; } } \ No newline at end of file From ad6e08679a6fb5f7b75e4afe69500f96aa77f4bb Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 3 May 2020 13:41:47 -0400 Subject: [PATCH 1231/1694] fix variable type --- includes/class-wp-members-forms.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 57a42fe7..ccd6ba3b 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1366,7 +1366,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { * * @param string The default edit mode heading. */ - $heading = ( isset( $heading ) ) ? $headhing : apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); + $heading = ( isset( $heading ) ) ? $heading : apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); } else { /** * Filter the registration form heading. @@ -1376,7 +1376,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { * @param string $str * @param string $tag Toggle new registration or profile update. new|edit. */ - $heading = ( isset( $heading ) ) ? $headhing : apply_filters( 'wpmem_register_heading', $wpmem->get_text( 'register_heading' ), $tag ); + $heading = ( isset( $heading ) ) ? $heading : apply_filters( 'wpmem_register_heading', $wpmem->get_text( 'register_heading' ), $tag ); } $form = $args['heading_before'] . $heading . $args['heading_after'] . $args['n'] . $form; From 5644d0975c95121839a05cd7712c4a99228fe192 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 3 May 2020 13:43:05 -0400 Subject: [PATCH 1232/1694] update product restricted messaging --- includes/class-wp-members-products.php | 46 +++++++++++++++++++++++--- 1 file changed, 41 insertions(+), 5 deletions(-) diff --git a/includes/class-wp-members-products.php b/includes/class-wp-members-products.php index ab9a90c2..42369934 100644 --- a/includes/class-wp-members-products.php +++ b/includes/class-wp-members-products.php @@ -94,7 +94,9 @@ function __construct() { $this->load_products(); - add_filter( 'wpmem_securify', array( $this, 'product_access' ) ); + add_filter( 'wpmem_securify', array( $this, 'product_access' ) ); + add_filter( 'wpmem_product_restricted_msg', array( $this, 'access_message' ) ); + add_filter( 'wpmem_restricted_msg', array( $this, 'access_message' ) ); } /** @@ -183,7 +185,7 @@ function product_access( $content ) { global $post, $wpmem; // Is the user logged in and is this blocked content? - if ( is_user_logged_in() && wpmem_is_blocked() ) { + if ( ! is_admin() && is_user_logged_in() && wpmem_is_blocked() ) { // @todo Should is_admin() check be run on securify in general? // Get the post access products. $post_products = $this->get_post_products( $post->ID ); @@ -219,18 +221,24 @@ function product_access( $content ) { * Filter the product restricted message HTML. * * @since 3.3.3 + * @since 3.3.4 Added $post_products * - * @param array $product_restricted { + * @param array $product_restricted { * $type string $wrapper_before * $type string $message * $type string $wrapper_after * } + * @param array $post_products { + * Membership product slugs the post is restricted to. + * + * @type string $slug + * } */ - $product_restricted = apply_filters( 'wpmem_product_restricted', array( + $product_restricted = apply_filters( 'wpmem_product_restricted_args', array( 'wrapper_before' => '
    ', 'message' => '

    ' . $message . '

    ', 'wrapper_after' => '
    ', - ) ); + ), $post_products ); $content = ( $access ) ? $content : $product_restricted['wrapper_before'] . $product_restricted['message'] . $product_restricted['wrapper_after']; @@ -242,6 +250,34 @@ function product_access( $content ) { // Return unfiltered content for all other cases. return $content; } + + /** + * Filters the access message if the user does not have + * access to this membership. + * + * @since 3.3.4 + * + * @global stdClass $post + * @param string $msg + * @return string $msg + */ + function access_message( $msg ) { + global $post; + $post_products = $this->get_post_products( $post->ID ); + if ( $post_products ) { + foreach( $post_products as $post_product ) { + $membership_id = array_search( $post_product, $this->product_by_id ); + $message = get_post_meta( $membership_id, 'wpmem_product_message', true ); + if ( $message ) { + $product_message = ( isset( $product_message ) ) ? $product_message . '

    ' . $message . '

    ' : '

    ' . $message . '

    '; + } + } + if ( isset( $product_message ) ) { + $msg = $product_message; + } + } + return $msg; + } /** * Register Membership Plans Custom Post Type From 938b28d44b8688728ec29ffa3b1c6449ac4223ee Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 3 May 2020 13:43:44 -0400 Subject: [PATCH 1233/1694] added product access messaging --- .../admin/class-wp-members-products-admin.php | 111 +++++++++++++++++- 1 file changed, 107 insertions(+), 4 deletions(-) diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index ddc93378..ae3e07e2 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -131,6 +131,7 @@ function get_meta( $value ) { * Handles meta boxes for CPT editor. * * @since 3.2.0 + * @since 3.3.4 Added message meta box. */ function meta_boxes() { remove_meta_box( 'slugdiv', 'wpmem_product', 'normal' ); @@ -142,6 +143,12 @@ function meta_boxes() { 'normal', 'high' ); + add_meta_box( + 'membership_product_message', + __( 'Membership Product Message (optional)', 'wp-members' ), + array( $this, 'message_meta_box_detail' ), + 'wpmem_product' + ); } /** @@ -179,12 +186,14 @@ function details_html( $post ) { $product_expires = $this->get_meta( 'wpmem_product_expires' ); $product_role = $this->get_meta( 'wpmem_product_role' ); $product_no_gap = $this->get_meta( 'wpmem_product_no_gap' ); + $product_fixed_period = $this->get_meta( 'wpmem_product_fixed_period' ); $product_expires = ( false !== $product_expires ) ? $product_expires[0] : $product_expires; $periods = array( __( 'Period', 'wp-members' ) . '|', __( 'Day', 'wp-members' ) . '|day', __( 'Week', 'wp-members' ) . '|week', __( 'Month', 'wp-members' ) . '|month', __( 'Year', 'wp-members' ) . '|year' ); $show_role_detail = ( false !== $product_role ) ? 'show' : 'hide'; - $show_exp_detail = ( false !== $product_expires ) ? 'show' : 'hide'; ?> + $show_exp_detail = ( false !== $product_expires ) ? 'show' : 'hide'; + $show_exp_fixed = ( false !== $product_fixed_period ) ? 'show' : 'hide'; ?>

    @@ -225,8 +234,54 @@ function details_html( $post ) { 'wpmem_product_time_period', 'type'=>'select', 'value'=>$periods, 'compare'=>( ( isset( $period[1] ) ) ? $period[1] : '' ) ) ); ?> - - 'wpmem_product_no_gap', 'type'=>'checkbox', 'value'=>'1', 'compare'=>( ( isset( $product_no_gap ) ) && 1 == $product_no_gap ) ? $product_no_gap : '' ) ); ?> +
    + + 'wpmem_product_no_gap', 'type'=>'checkbox', 'value'=>'1', 'compare'=>( ( isset( $product_no_gap ) ) && 1 == $product_no_gap ) ? $product_no_gap : '' ) ); ?> + + +
    + 'wpmem_product_fixed_period', 'type'=>'checkbox', 'value'=>'1', 'compare'=>( false != $product_fixed_period ) ? 1 : '' ) ); ?> + +
    + + + + + + +
    + + + + + + + 'wpmem_product_fixed_period_grace_period', 'type'=>'select', 'value'=>$periods, 'compare'=>( ( isset( $period_grace_per ) ) ? $period_grace_per : '' ) ) ); ?> +
    + + +

    ID, 'wpmem_product_message', true ); + $message = ( $product_message ) ? $product_message : ''; + echo ''; + echo ''; + } + /** * Saves meta fields for CPT * * @since 3.2.0 + * @since 3.3.4 Added message meta. * * @param int $post_id */ @@ -269,7 +347,7 @@ function save_details( $post_id ) { if ( ! current_user_can( 'edit_posts', $post_id ) ) return; $post = get_post( $post_id ); - + $product_name = wpmem_get( 'wpmem_product_name', false ); $product_name = ( $product_name ) ? $product_name : $post->post_name; update_post_meta( $post_id, 'wpmem_product_name', sanitize_text_field( $product_name ) ); @@ -298,7 +376,27 @@ function save_details( $post_id ) { } else { delete_post_meta( $post_id, 'wpmem_product_no_gap' ); } + + $fixed_period = sanitize_text_field( wpmem_get( 'wpmem_product_fixed_period' ) ); + if ( $fixed_period ) { + + // Start and end. + $period_start = wpmem_get( 'wpmem_product_fixed_period_start' ); + $period_end = wpmem_get( 'wpmem_product_fixed_period_end' ); + + // Is there an entry grace period? + $grace_number = wpmem_get( 'wpmem_product_fixed_period_grace_number', false ); + $grace_period = wpmem_get( 'wpmem_product_fixed_period_grace_period', false ); + $save_fixed_period = $period_start . '-' . $period_end; + if ( $grace_number && $grace_period ) { + $save_fixed_period .= '-' . $grace_number . '-' . $grace_period; + } + update_post_meta( $post_id, 'wpmem_product_fixed_period', $save_fixed_period ); + } else { + delete_post_meta( $post_id, 'wpmem_product_fixed_period' ); + } } + foreach( $this->get_post_types() as $key => $post_type ) { if ( false !== wpmem_get( 'wpmem_product_set_default_' . $key, false ) ) { update_post_meta( $post_id, 'wpmem_product_set_default_' . $key, 1 ); @@ -306,6 +404,11 @@ function save_details( $post_id ) { delete_post_meta( $post_id, 'wpmem_product_set_default_' . $key ); } } + + $product_message = wpmem_get( 'product_message', false ); + if ( false !== $product_message && '' != $product_message ) { + update_post_meta( $post_id, 'wpmem_product_message', $product_message ); + } } /** From 86f85a28a8dc17a8bd8ec58dee658d1e32210eb0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 3 May 2020 13:44:04 -0400 Subject: [PATCH 1234/1694] update captcha --- includes/class-wp-members-user.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index e8e90600..0ba6628d 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -345,7 +345,7 @@ function register_validate( $tag ) { // Process CAPTCHA. if ( 0 != $wpmem->captcha ) { $check_captcha = WP_Members_Captcha::validate(); - if ( 'passed_captcha' != $check_captcha ) { + if ( true != $check_captcha ) { return $check_captcha; } } From 3b0c1f4f25026e1be98a7fb3b6c53b6121a9a86f Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 3 May 2020 13:44:31 -0400 Subject: [PATCH 1235/1694] put wpmem_a_extenduser() back --- includes/class-wp-members-user-profile.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-user-profile.php b/includes/class-wp-members-user-profile.php index 65fb57ce..b78f974b 100644 --- a/includes/class-wp-members-user-profile.php +++ b/includes/class-wp-members-user-profile.php @@ -375,7 +375,7 @@ static function update( $user_id ) { if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { if ( function_exists( 'wpmem_a_extenduser' ) ) { - wpmem_a_extend_user( $user_id ); + wpmem_a_extenduser( $user_id ); } } From e87551ffb9ce44dda5a352970b05e1f707235649 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 3 May 2020 13:45:24 -0400 Subject: [PATCH 1236/1694] update admin.css --- assets/css/admin.css | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/assets/css/admin.css b/assets/css/admin.css index 015b132e..66381e6a 100644 --- a/assets/css/admin.css +++ b/assets/css/admin.css @@ -115,4 +115,11 @@ } #wpmem_user_profile_tabs .ui-state-active a { color: #fff; -} \ No newline at end of file +} + +#wpmem_product_fixed_period_select input, +#wpmem_product_no_gap, +#wpmem_product_fixed_period { + margin-top: 10px; + margin-left: 24px; +} From 5866ff7dfb93491903ed3ddb3a8cf101c2e4009b Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 3 May 2020 13:45:36 -0400 Subject: [PATCH 1237/1694] set version for testing --- readme.txt | 1 + wp-members.php | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/readme.txt b/readme.txt index 41de3aeb..b5456b41 100644 --- a/readme.txt +++ b/readme.txt @@ -133,6 +133,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. * Added function_exists check for wpmem_renew() (a PayPal extension function used in the core plugin). * Fixed function name typo for wpmem_a_extend_user() (a PayPal extension function used in the core plugin). * Updated product access shortcode error message to use the product_restricted message and changed the class to product_restricted_msg +* Updated CAPTCHA class for more flexibility (can now be implemented into API for calling directly in the login or other forms). = 3.3.3 = diff --git a/wp-members.php b/wp-members.php index bb7fed31..65218994 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.3.3 +Version: 3.3.4 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -64,7 +64,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.3.3' ); +define( 'WPMEM_VERSION', '3.3.4' ); define( 'WPMEM_DB_VERSION', '2.2.0' ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From ded3e8fd8cfd373ecc908ce968834ebc414858a8 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 10 May 2020 16:42:24 -0400 Subject: [PATCH 1238/1694] moved user export from admin to user api --- includes/admin/api.php | 19 ------------------- includes/api/api-users.php | 23 +++++++++++++++++++++++ 2 files changed, 23 insertions(+), 19 deletions(-) diff --git a/includes/admin/api.php b/includes/admin/api.php index 7ac0ce23..144349d5 100644 --- a/includes/admin/api.php +++ b/includes/admin/api.php @@ -95,23 +95,4 @@ function wpmem_admin_form_post_url( $args = false ) { function wpmem_wp_reserved_terms() { global $wpmem; return $wpmem->admin->wp_reserved_terms(); -} - -/** - * Export all or selected users - * - * @since 2.9.7 - * @since 3.2.0 Updated to use fputcsv. - * @since 3.2.1 Added user data filters. - * @since 3.3.0 Call object class static method. - * - * @global object $wpmem - * - * @param array $args - * @param array $users - */ -function wpmem_export_users( $args, $users = null ) { - global $wpmem; - include_once( $wpmem->path . 'includes/admin/class-wp-members-export.php' ); - WP_Members_Export::export_users( $args, $users ); } \ No newline at end of file diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 5cc4591e..3c2c10bd 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -760,4 +760,27 @@ function wpmem_get_user_ip() { */ return apply_filters( 'wpmem_get_ip', $ip ); } + +/** + * Export all or selected users + * + * @since 2.9.7 + * @since 3.2.0 Updated to use fputcsv. + * @since 3.2.1 Added user data filters. + * @since 3.3.0 Call object class static method. + * @since 3.3.4 Moved into general API. + * + * @todo Move object class file to main /includes/ + * + * @global object $wpmem + * + * @param array $args + * @param array $users + */ +function wpmem_export_users( $args, $users = null ) { + global $wpmem; + include_once( $wpmem->path . 'includes/admin/class-wp-members-export.php' ); + WP_Members_Export::export_users( $args, $users ); +} + // End of file. \ No newline at end of file From ee325282d1cf8458322300d37e6115a99fab9837 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 10 May 2020 16:43:01 -0400 Subject: [PATCH 1239/1694] fixed whitespace in default select/multiselect/multicheckbox/radio options --- .../tabs/class-wp-members-admin-tab-fields.php | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-fields.php b/includes/admin/tabs/class-wp-members-admin-tab-fields.php index 907d2c24..d30f2a02 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-fields.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-fields.php @@ -344,15 +344,15 @@ public static function build_field_edit( $mode, $wpmem_fields, $meta_key ) { } } } else { if (version_compare(PHP_VERSION, '5.3.0') >= 0) { ?> - ---- Select One ----|, - Choice One|choice_one, - "1,000|one_thousand", - "1,000-10,000|1,000-10,000", - Last Row|last_row - ---- Select One ----|, - Choice One|choice_one, - Choice 2|choice_two, - Last Row|last_row +---- Select One ----|, +Choice One|choice_one, +"1,000|one_thousand", +"1,000-10,000|1,000-10,000", +Last Row|last_row +---- Select One ----|, +Choice One|choice_one, +Choice 2|choice_two, +Last Row|last_row
  • From 52589a3982859d0eecfd5e6beddcc0be9a2006cb Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 10 May 2020 16:43:30 -0400 Subject: [PATCH 1240/1694] fixed classname for multicheckbox label --- includes/class-wp-members-forms.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index ccd6ba3b..e78eca39 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -196,7 +196,7 @@ function create_form_field( $args ) { $chk = ( isset( $pieces[2] ) && '' == $compare ) ? $pieces[1] : ''; if ( isset( $pieces[1] ) && '' != $pieces[1] ) { $id_value = esc_attr( $id . '[' . $pieces[1] . ']' ); - $label = wpmem_form_label( array( 'meta_key'=>$id_value, 'label'=>esc_html( __( $pieces[0], 'wp-members' ) ), 'type'=>'radio', 'id'=>$id_value ) ); + $label = wpmem_form_label( array( 'meta_key'=>$id_value, 'label'=>esc_html( __( $pieces[0], 'wp-members' ) ), 'type'=>'multicheckbox', 'id'=>$id_value ) ); $str = $str . $this->create_form_field( array( 'id' => $id_value, 'name' => $name . '[]', From 9c86c18686a21dd68bd36fc1a1d6333c0d84b72b Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 10 May 2020 16:44:00 -0400 Subject: [PATCH 1241/1694] fixed adding fields to woocommerce checkout --- includes/api/api-forms.php | 156 +++++++++++++++++++++++++++++ includes/class-wp-members-user.php | 6 +- includes/class-wp-members.php | 12 ++- 3 files changed, 170 insertions(+), 4 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index d89ed308..5b860cd4 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -360,4 +360,160 @@ function wpmem_sanitize_field( $data, $type = 'text' ) { function wpmem_form_nonce( $nonce, $echo = false ) { $form = ( 'update' == $nonce || 'register' == $nonce ) ? 'longform' : 'shortform'; return wp_nonce_field( 'wpmem_' . $form . '_nonce', '_wpmem_' . $nonce . '_nonce', true, $echo ); +} + +// @todo Experimental +/** + * Create WP-Members fields set for woo checkout. + * + * @since 3.3.4 + * + * @param array $checkout_fields + */ +function wpmem_woo_checkout_fields( $checkout_fields = false ) { + $woo_checkout = array( + 'billing_first_name', + 'billing_last_name', + 'billing_company', + 'billing_country', + 'billing_address_1', + 'billing_address_2', + 'billing_city', + 'billing_state', + 'billing_postcode', + 'billing_phone', + 'billing_email', + 'account_username', + 'account_password', + ); + $fields = wpmem_fields();// echo '
    '; print_r( $fields ); echo '
    '; + + if ( ! $checkout_fields ) { + $checkout_fields = WC()->checkout()->checkout_fields; + } + + foreach ( $fields as $meta_key => $field ) { + + if ( 1 != $fields[ $meta_key ]['register'] ) { + unset( $fields[ $meta_key ] ); + } else { + if ( isset( $checkout_fields['billing'][ $meta_key ] ) ) { + unset( $fields[ $meta_key ] ); + } + if ( isset( $checkout_fields['shipping'][ $meta_key ] ) ) { + unset( $fields[ $meta_key ] ); + } + if ( isset( $checkout_fields['account'][ $meta_key ] ) ) { + unset( $fields[ $meta_key ] ); + } + if ( isset( $checkout_fields['order'][ $meta_key ] ) ) { + unset( $fields[ $meta_key ] ); + } + } + } + unset( $fields['username'] ); + unset( $fields['password'] ); + unset( $fields['confirm_password'] ); + unset( $fields['confirm_email'] ); + unset( $fields['user_email'] ); + unset( $fields['first_name'] ); + unset( $fields['last_name'] ); + + return $fields; +} + +/** + * Adds WP-Members custom fields to woo checkout. + * + * @since 3.3.4 + * + * @param array $checkout_fields + */ +function wpmem_woo_checkout_form( $checkout_fields ) { + + $fields = wpmem_woo_checkout_fields( $checkout_fields ); + + foreach ( $fields as $meta_key => $field ) { + $checkout_fields['order'][ $meta_key ] = array( + 'type' => $fields[ $meta_key ]['type'], + 'label' => $fields[ $meta_key ]['label'], + 'required' => $fields[ $meta_key ]['required'], + ); + if ( isset( $fields[ $meta_key ]['placeholder'] ) ) { + $checkout_fields['order'][ $meta_key ]['placeholder'] = $fields[ $meta_key ]['placeholder']; + } + } + + return $checkout_fields; +} + +/** + * Saves WP-Members custom fields for woo checkout. + * + * @since 3.3.4 + * + * @param int $order_id + */ +function wpmem_woo_checkout_update_meta( $order_id ) { + + // Get user id from order. + $order = wc_get_order( $order_id ); + $user_id = $order->get_user_id(); + + $checkout_fields = WC()->checkout()->checkout_fields; //write_log( $checkout_fields ); + $fields = wpmem_fields(); //write_log( $fields ); + foreach ( $fields as $meta_key => $field ) { write_log( $meta_key ); + if ( isset( $checkout_fields['order'][ $meta_key ] ) && isset( $_POST[ $meta_key ] ) ) { write_log( 'user ' . $user_id . ' meta_key: ' . $meta_key . 'post: ' . sanitize_text_field( $_POST[ $meta_key ] ) ); + switch ( $fields[ $meta_key ]['type'] ) { + case 'checkbox': + update_user_meta( $user_id, $meta_key, $field['checked_value'] ); + break; + case 'textarea': + update_user_meta( $user_id, $meta_key, sanitize_textarea_field( $_POST[ $meta_key ] ) ); + break; + case 'multicheckbox': + case 'multiselect': + update_user_meta( $user_id, $meta_key, wpmem_sanitize_array( $_POST[ $meta_key ] ) ); + break; + default: + update_user_meta( $user_id, $meta_key, sanitize_text_field( $_POST[ $meta_key ] ) ); + break; + } + } + } +} + +function wpmem_form_field_wc_custom_field_types( $field, $key, $args, $value ) { + + $wpmem_fields = wpmem_fields(); + /* @type string $name (required) The field meta key. + * @type string $type (required) The field HTML type (url, email, image, file, checkbox, text, textarea, password, hidden, select, multiselect, multicheckbox, radio). + * @type string $value (optional) The field's value (can be a null value). + * @type string $compare (optional) Compare value. + * @type string $class (optional) Class identifier for the field. + * @type boolean $required (optional) If a value is required default: true). + * @type string $delimiter (optional) The field delimiter (pipe or comma, default: | ). + * @type string $placeholder (optional) Defines the placeholder attribute. + * @type string $pattern (optional) Adds a regex pattern to the field (HTML5). + * @type string $title (optional) Defines the title attribute. + * @type string $min (optional) Adds a min attribute (HTML5). + * @type string $max (optional) Adds a max attribute (HTML5). + * @type string $rows (optional) Adds rows attribute to textarea. + * @type string $cols (optional) Adds cols attribute to textarea. + */ + $field_args = array( + 'name' => $key, + 'type' => $wpmem_fields[ $key ]['type'], + 'required' => $wpmem_fields[ $key ]['required'], + 'delimiter' => $wpmem_fields[ $key ]['delimiter'], + 'value' => $wpmem_fields[ $key ]['values'], + ); + + $field_html = wpmem_form_field( $field_args ); + $field_html = str_replace( 'class="' . $wpmem_fields[ $key ]['type'] . '"', 'class="' . $wpmem_fields[ $key ]['type'] . '" style="display:initial;"', $field_html ); + $field = '

    + '; + $field .= $field_html; + $field .= '

    '; + return $field; } \ No newline at end of file diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 0ba6628d..2cb4dc37 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -172,8 +172,10 @@ function set_reg_type() { $this->reg_type['is_native'] = ( __( 'Register' ) == wpmem_get( 'wp-submit' ) ) ? true : false; // Is this a Users > Add New process? Checks the post action. $this->reg_type['is_add_new'] = ( 'createuser' == wpmem_get( 'action' ) ) ? true : false; - // Is this a WooCommerce checkout registration? Checks for WC fields. - $this->reg_type['is_woo'] = ( wpmem_get( 'woocommerce_checkout_place_order' ) || wpmem_get( 'woocommerce-register-nonce' ) ) ? true : false; + // Is this a WooCommerce my account registration? Checks for WC fields. + $this->reg_type['is_woo'] = ( wpmem_get( 'woocommerce-register-nonce' ) ) ? true : false; + // Is this a WooCommerce checkout? + $this->reg_type['is_woo_checkout'] = ( wpmem_get( 'woocommerce_checkout_place_order' ) ) ? true : false; } /** diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 1cfd73ee..28d8dab9 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -428,8 +428,16 @@ function load_hooks() { add_action( 'wpmem_pwd_change', array( $this->user, 'set_as_logged_in' ), 10 ); } - add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration - add_action( 'woocommerce_register_form', 'wpmem_woo_register_form' ); + add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration + add_action( 'woocommerce_register_form', 'wpmem_woo_register_form' ); + add_filter( 'woocommerce_checkout_fields', 'wpmem_woo_checkout_form' ); + add_action( 'woocommerce_checkout_update_order_meta', 'wpmem_woo_checkout_update_meta' ); + //add_action( 'woocommerce_after_order_notes', 'wpmem_woo_checkout_form2' ); + // Adds custom field types to use WP-Members field types on WooCommerce checkout. + //add_action( 'woocommerce_form_field_multiselect', 'wpmem_form_field_wc_multiselect', 10, 4 ); + add_action( 'woocommerce_form_field_multicheckbox', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); + add_action( 'woocommerce_form_field_multiselect', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); + add_action( 'woocommerce_form_field_radio', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); // Add filters. add_filter( 'the_content', array( $this, 'do_securify' ), 99 ); From 28b8ad6d6853d01517c4fd67c05677b7b625360d Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 10 May 2020 16:49:36 -0400 Subject: [PATCH 1242/1694] update readme --- includes/class-wp-members-shortcodes.php.bak | 813 ------------------- readme.txt | 3 + 2 files changed, 3 insertions(+), 813 deletions(-) delete mode 100644 includes/class-wp-members-shortcodes.php.bak diff --git a/includes/class-wp-members-shortcodes.php.bak b/includes/class-wp-members-shortcodes.php.bak deleted file mode 100644 index dce299f3..00000000 --- a/includes/class-wp-members-shortcodes.php.bak +++ /dev/null @@ -1,813 +0,0 @@ -regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to ); - } - break; - - case in_array( 'register', $atts ): - if ( is_user_logged_in() && '1' != $customizer ) { - /* - * If the user is logged in, return any nested content (if any) - * or the default bullet links if no nested content. - */ - $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'register' ); - } elseif ( is_user_logged_in() && is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) { - $wpmem_themsg = __( "This is a generic message to display the form message dialog in the Customizer.", 'wp-members' ); - $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); - $content .= wpmem_register_form( 'new', $redirect_to ); - } else { - if ( $wpmem->regchk == 'loginfailed' ) { - $content = wpmem_inc_loginfailed() . wpmem_inc_login( 'login', $redirect_to ); - break; - } - // @todo Can this be moved into another function? Should $wpmem get an error message handler? - if ( $wpmem->regchk == 'captcha' ) { - global $wpmem_captcha_err; - $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; - } - $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ) : ''; - $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login( 'login', $redirect_to ) : wpmem_register_form( 'new', $redirect_to ); - } - break; - - case in_array( 'password', $atts ): - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); - break; - - case in_array( 'user_edit', $atts ): - $content = wpmem_page_user_edit( $wpmem->regchk, $content ); - break; - - case in_array( 'forgot_username', $atts ): - $content = wpmem_page_forgot_username( $wpmem->regchk, $content ); - break; - - case in_array( 'customizer_login', $atts ): - $content = wpmem_inc_login( 'login', $redirect_to ); - break; - - case in_array( 'customizer_register', $atts ): - $content = wpmem_register_form( 'new', $redirect_to ); - break; - - } - - /* - * This is for texturizing. Need to work it into an argument in the function call as to whether the - * [wpmem_txt] shortcode is even included. @todo - Is this a temporary solution or is there something - * cleaner that can be worked out? - */ - if ( 1 == $wpmem->texturize ) { - if ( array_key_exists( 'texturize', $atts ) && $atts['texturize'] == 'false' ) { - $content = str_replace( array( '[wpmem_txt]', '[/wpmem_txt]' ), array( '', '' ), $content ); - } - if ( strstr( $content, '[wpmem_txt]' ) ) { - // Fixes the wptexturize. - remove_filter( 'the_content', 'wpautop' ); - remove_filter( 'the_content', 'wptexturize' ); - add_filter( 'the_content', array( 'WP_Members', 'texturize' ), 999 ); - } - } // End texturize functions - } - return do_shortcode( $content ); - } - - /** - * Handles the logged in status shortcodes [wpmem_logged_in]. - * - * There are several attributes that can be used with the shortcode: - * in|out, sub for subscription only info, id, and role. IDs and roles - * can be comma separated values for multiple users and roles. - * - * @since 3.0.0 - * @since 3.2.0 Moved to WP_Members_Shortcodes::logged_in(). - * @since 3.2.0 Added attributes for meta key/value pairs. - * @since 3.2.3 Added product attribute. - * @since 3.3.0 Added compare attribute for meta key/value compare (=|!=). - * - * @global object $wpmem The WP_Members object. - * - * @param array $atts { - * The shortcode attributes. - * - * @type string $status - * @type int $id - * @type string $role - * @type string $sub - * @type string $meta_key - * @type string $meta_value - * @type string $product - * @type string $membership - * } - * @param string $content - * @param string $tag - * @return string $content - */ - function logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) { - - global $wpmem; - - // Handles the 'status' attribute. - if ( ( isset( $atts['status'] ) ) || $tag == 'wpmem_logged_in' ) { - - $do_return = false; - - // If there is a status attribute of "out" and the user is not logged in. - $do_return = ( isset( $atts['status'] ) && $atts['status'] == 'out' && ! is_user_logged_in() ) ? true : $do_return; - - if ( is_user_logged_in() ) { - - // In case $current_user is not already global - $current_user = wp_get_current_user(); - - // If there is a status attribute of "in" and the user is logged in. - $do_return = ( isset( $atts['status'] ) && $atts['status'] == 'in' ) ? true : $do_return; - - // If using the wpmem_logged_in tag with no attributes & the user is logged in. - $do_return = ( $tag == 'wpmem_logged_in' && ( ! $atts ) ) ? true : $do_return; - - // If there is an "id" attribute and the user ID is in it. - if ( isset( $atts['id'] ) ) { - $ids = explode( ',', $atts['id'] ); - foreach ( $ids as $id ) { - if ( trim( $id ) == $current_user->ID ) { - $do_return = true; - } - } - } - - // If there is a "role" attribute and the user has a matching role. - if ( isset( $atts['role'] ) ) { - $roles = explode( ',', $atts['role'] ); - if ( wpmem_user_has_role( $roles ) ) { - $do_return = true; - } - } - - // If there is a status attribute of "sub" and the user is logged in. - if ( ( isset( $atts['status'] ) ) && $atts['status'] == 'sub' ) { - if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 ) { - if ( ! wpmem_chk_exp() ) { - $do_return = true; - } elseif ( $atts['msg'] == "true" ) { - $do_return = true; - $content = wpmem_sc_expmessage(); - } - } - } - - // If there is a meta key attribute. - if ( isset( $atts['meta_key'] ) ) { - $do_return = false; - $value = ( isset( $atts['meta_value'] ) ) ? $atts['meta_value'] : false; - if ( ! isset( $atts['compare'] ) || "=" == $atts['compare'] ) { - if ( wpmem_user_has_meta( $atts['meta_key'], $value ) ) { - $do_return = true; - } - } - if ( isset( $atts['compare'] ) && "!=" == $atts['compare'] ) { - if ( ! wpmem_user_has_meta( $atts['meta_key'], $value ) ) { - $do_return = true; - } - } - } - - // If there is a product attribute. - if ( isset( $atts['product'] ) || isset( $atts['membership'] ) ) { - // @todo What if attribute is comma separated/multiple? - $membership = ( isset( $atts['membership'] ) ) ? $atts['membership'] : $atts['product']; - if ( wpmem_user_has_access( $membership ) ) { - $do_return = true; - } elseif ( true === $atts['msg'] || "true" === strtolower( $atts['msg'] ) ) { - $do_return = true; - $settings = array( - 'wrapper_before' => '
    ', - 'msg' => sprintf( $wpmem->get_text( 'product_restricted' ), $wpmem->membership->products[ $membership ]['title'] ), - 'wrapper_after' => '
    ', - ); - /** - * Filter the access failed message. - * - * @since 3.3.0 - * @since 3.3.3 Changed from 'wpmem_sc_product_access_denied' - * - * @param array $settings. - */ - $settings = apply_filters( 'wpmem_sc_product_restricted', $settings ); - $content = $settings['wrapper_before'] . $settings['msg'] . $settings['wrapper_after']; - } - } - - // Prevents display if the current page is the user profile and an action is being handled. - if ( ( wpmem_current_url( true, false ) == wpmem_profile_url() ) && isset( $_GET['a'] ) ) { - $do_return = false; - } - - } - - // Return content (or empty content) depending on the result of the above logic. - return ( $do_return ) ? do_shortcode( $content ) : ''; - } - } - - /** - * Handles the [wpmem_logged_out] shortcode. - * - * @since 3.0.0 - * @since 3.2.0 Moved to WP_Members_Shortcodes::logged_out(). - * - * @param array $atts - * @param string $content - * @param string $tag - * @return string $content - */ - function logged_out( $atts, $content = null, $tag ) { - return ( ! is_user_logged_in() ) ? do_shortcode( $content ) : ''; - } - - /** - * User count shortcode [wpmem_show_count]. - * - * User count displays a total user count or a count of users by specific - * role (role="some_role"). It also accepts attributes for counting users - * by a meta field (key="meta_key" value="meta_value"). A label can be - * displayed using the attribute label (label="Some label:"). - * - * @since 3.0.0 - * @since 3.1.5 Added total user count features. - * @since 3.2.0 Moved to WP_Members_Shortcodes::user_count(). - * - * @global object $wpdb The WordPress database object. - * @param array $atts { - * The shortcode attributes. - * - * @type string $key - * @type string $value - * @type string $role - * @type string $label - * } - * @param string $content The shortcode content. - * @return string $content - */ - function user_count( $atts, $content = null ) { - if ( isset( $atts['key'] ) && isset( $atts['value'] ) ) { - // If by meta key. - global $wpdb; - $user_count = $wpdb->get_var( $wpdb->prepare( - "SELECT COUNT(*) FROM $wpdb->usermeta WHERE meta_key = %s AND meta_value = %s", - $atts['key'], - $atts['value'] - ) ); - } else { - // If no meta, it's a total count. - $users = count_users(); - $user_count = ( isset( $atts['role'] ) ) ? $users['avail_roles'][ $atts['role'] ] : $users['total_users']; - } - - // Assemble the output and return. - $content = ( isset( $atts['label'] ) ) ? $atts['label'] . ' ' . $user_count : $content . ' ' . $user_count; - return do_shortcode( $content ); - } - - /** - * Creates the user profile dashboard area [wpmem_profile]. - * - * @since 3.1.0 - * @since 3.1.2 Added function arguments. - * @since 3.2.0 Moved to WP_Members_Shortcodes::user_profile(). - * - * @global object $wpmem The WP_Members object. - * @global string $wpmem_themsg The WP-Members message container. - * @param string $atts { - * The shortcode attributes. - * - * @type string $redirect_to - * @type string $register "hide" removes registration form, any other value is false. - * } - * @param string $content - * @param string $tag - * @return string $content - */ - function user_profile( $atts, $content, $tag ) { - - // @todo $redirect_to is not currently used in the user profile. - $redirect_to = ( isset( $atts['redirect_to'] ) ) ? $atts['redirect_to'] : null; - $hide_register = ( isset( $atts['register'] ) && 'hide' == $atts['register'] ) ? true : false; - - global $wpmem, $wpmem_themsg; - - $content = ''; - - if ( $wpmem->regchk == "captcha" ) { - global $wpmem_captcha_err; - $wpmem_themsg = $wpmem->get_text( 'reg_captcha_err' ) . '

    ' . $wpmem_captcha_err; - } - - if ( $wpmem->regchk == "loginfailed" ) { - return wpmem_inc_loginfailed(); - } - - if ( is_user_logged_in() ) { - - switch( $wpmem->action ) { - - case "edit": - $content = $content . wpmem_register_form( 'edit' ); - break; - - case "update": - // Determine if there are any errors/empty fields. - if ( $wpmem->regchk == "updaterr" || $wpmem->regchk == "email" ) { - $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); - $content = $content . wpmem_register_form( 'edit' ); - } else { - //Case "editsuccess". - $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); - $content = $content . wpmem_inc_memberlinks(); - } - break; - - case "pwdchange": - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); - $content = ( 'pwdchangesuccess' == $wpmem->regchk ) ? $content . wpmem_inc_memberlinks() : $content; - break; - - case "renew": - if ( function_exists( 'wpmem_renew' ) ) { - $content = wpmem_renew(); - } else { - $content = ''; - } - break; - - default: - $content = wpmem_inc_memberlinks(); - break; - } - - } else { - - if ( $wpmem->action == 'register' && ! $hide_register ) { - - switch( $wpmem->regchk ) { - - case "success": - $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); - $content = $content . wpmem_inc_login(); - break; - - default: - $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); - $content = $content . wpmem_register_form(); - break; - } - - } elseif ( $wpmem->action == 'pwdreset' ) { - - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); - - } elseif( $wpmem->action == 'getusername' ) { - - $content = wpmem_page_forgot_username( $wpmem->regchk, $content ); - - } else { - - $content = $content . wpmem_inc_login( 'members' ); - $content = ( ! $hide_register ) ? $content . wpmem_register_form() : $content; - } - } - - return $content; - } - - /** - * Log in/out shortcode [wpmem_loginout]. - * - * @since 3.1.1 - * @since 3.1.6 Uses wpmem_loginout(). - * @since 3.2.0 Moved to WP_Members_Shortcodes::loginout(). - * - * @param array $atts { - * The shortcode attributes. - * - * @type string $login_redirect_to The url to redirect to after login (optional). - * @type string $logout_redirect_to The url to redirect to after logout (optional). - * @type string $login_text Text for the login link (optional). - * @type string $logout_text Text for the logout link (optional). - * } - * @param string $content - * @param string $tag - * @return string $content - */ - function loginout( $atts, $content, $tag ) { - $link = wpmem_loginout( $atts ); - return do_shortcode( $link ); - } - - /** - * Function to handle field shortcodes [wpmem_field]. - * - * Shortcode to display the data for a given user field. Requires - * that a field meta key be passed as an attribute. Can either of - * the following: - * - [wpmem_field field="meta_key"] - * - [wpmem_field meta_key] - * - * Other attributes: - * - * - id (numeric user ID or "get" to retrieve uid from query string. - * - underscores="true" strips underscores from the displayed value. - * - display="raw" displays the stored value for dropdowns, radios, files. - * - size(thumbnail|medium|large|full|w,h): image field only. - * - clickable - * - label - * - * Filter the end result with `wpmem_field_shortcode`. - * - * @since 3.1.2 - * @since 3.1.4 Changed to display value rather than stored value for dropdown/multicheck/radio. - * @since 3.1.5 Added display attribute, meta key as a direct attribute, and image/file display. - * @since 3.2.0 Moved to WP_Members_Shortcodes::fields(). - * @since 3.2.0 Added clickable attribute. - * @since 3.2.5 Added label attribute. - * - * @global object $wpmem The WP_Members object. - * @param array $atts { - * The shortcode attributes. - * - * @type string {meta_key} - * @type string $field - * @type int $id - * @type string $underscores - * @type string $display - * @type string $size - * @type string $clickable default:false - * @type string $label default:false - * } - * @param string $content Any content passed with the shortcode (default:null). - * @param string $tag The shortcode tag (wpmem_form). - * @return string $content Content to return. - */ - function fields( $atts, $content = null, $tag ) { - - // What field? - $field = ( isset( $atts[0] ) ) ? $atts[0] : $atts['field']; - - // What user? - if ( isset( $atts['id'] ) ) { - $the_ID = ( $atts['id'] == 'get' ) ? filter_var( wpmem_get( 'uid', '', 'get' ), FILTER_SANITIZE_NUMBER_INT ) : $atts['id']; // Ultimately, the_ID will be checked to determine if it is numeric by WP_User::get_data_by(). - } else { - $the_ID = get_current_user_id(); - } - $user_info = get_userdata( $the_ID ); - - // If there is userdata. - if ( $user_info && isset( $user_info->{$field} ) ) { - - global $wpmem; - $fields = wpmem_fields(); - $field_type = ( isset( $fields[ $field ]['type'] ) ) ? $fields[ $field ]['type'] : 'native'; // @todo Is this needed? It seems to set the type to "native" if not set. - - $user_info_field = ( isset( $field ) && is_object( $user_info ) ) ? $user_info->{$field} : ''; - $result = false; - - // Handle each field type. - switch ( $field_type ) { - - // Select and radio groups have single selections. - case 'select': - case 'radio': - $result = ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) ? $user_info_field : $fields[ $field ]['options'][ $user_info_field ]; - break; - - // Multiple select and multiple checkbox have multiple selections. - case 'multiselect': - case 'multicheckbox': - if ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) { - $result = $user_info_field; - } else { - $saved_vals = explode( $fields[ $field ]['delimiter'], $user_info_field ); - $result = ''; $x = 1; - foreach ( $saved_vals as $value ) { - $result.= ( $x > 1 ) ? ', ' : ''; $x++; - $result.= $fields[ $field ]['options'][ $value ]; - } - } - break; - - case 'file': - case 'image': - if ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) { - $result = $user_info_field; - } else { - if ( 'file' == $field_type ) { - $attachment_url = wp_get_attachment_url( $user_info_field ); - $result = ( $attachment_url ) ? '' . get_the_title( $user_info_field ) . '' : ''; - } else { - $size = 'thumbnail'; - if ( isset( $atts['size'] ) ) { - $sizes = array( 'thumbnail', 'medium', 'large', 'full' ); - $size = ( ! in_array( $atts['size'], $sizes ) ) ? explode( ",", $atts['size'] ) : $atts['size']; - } - $image = wp_get_attachment_image_src( $user_info_field, $size ); - $result = ( $image ) ? '' : ''; - } - } - break; - - case 'textarea': - // Handle line breaks for textarea fields - $result = ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) ? $user_info_field : nl2br( $user_info_field ); - break; - - case 'date': - if ( isset( $atts['format'] ) ) { - // Formats date: https://secure.php.net/manual/en/function.date.php - $result = ( '' != $user_info_field ) ? date( $atts['format'], strtotime( $user_info_field ) ) : ''; - } else { - // Formats date to whatever the WP setting is. - $result = ( '' != $user_info_field ) ? date_i18n( get_option( 'date_format' ), strtotime( $user_info_field ) ) : ''; - } - break; - - // Handle all other fields. - default: - $result = ( ! $result ) ? $user_info_field : $result; - break; - } - - // Remove underscores from value if requested (default: on). - if ( isset( $atts['underscores'] ) && 'off' == $atts['underscores'] && $user_info ) { - $result = str_replace( '_', ' ', $result ); - } - - $content = ( $content ) ? $result . $content : $result; - - // Make it clickable? - $content = ( isset( $atts['clickable'] ) && ( true == $atts['clickable'] || 'true' == $atts['clickable'] ) ) ? make_clickable( $content ) : $content; - - // Display field label? - $content = ( isset( $fields[ $field ] ) && isset( $atts['label'] ) && ( true == $atts['label'] ) ) ? $fields[ $field ]['label'] . ": " . $content : $content; - } - - /** - * Filters the field shortcode before returning value. - * - * @since 3.2.5 - * - * @param string $content - * @param array $atts - */ - $content = apply_filters( 'wpmem_field_shortcode', $content, $atts ); - - return do_shortcode( $content ); - } - - /** - * Logout link shortcode [wpmem_logout]. - * - * @since 3.1.2 - * @since 3.2.0 Moved to WP_Members_Shortcodes::logout(). - * - * @param array $atts { - * The shortcode attributes. - * - * @type string $url - * } - * @param string $content - * @param string $tag - * @retrun string $content - */ - function logout( $atts, $content, $tag ) { - // Logout link shortcode. - if ( is_user_logged_in() && $tag == 'wpmem_logout' ) { - $link = ( isset( $atts['url'] ) ) ? add_query_arg( array( 'a'=>'logout', 'redirect_to'=>$atts['url'] ) ) : add_query_arg( 'a', 'logout' ); - $text = ( $content ) ? $content : __( 'Click here to log out.', 'wp-members' ); - return do_shortcode( '' . $text . '' ); - } - } - - /** - * TOS shortcode [wpmem_tos]. - * - * @since 3.1.2 - * @since 3.2.0 Moved to WP_Members_Shortcodes::tos(). - * - * @param array $atts { - * The shortcode attributes. - * - * @type string $url - * } - * @param string $content - * @param string $tag - * @retrun string $content - */ - function tos( $atts, $content, $tag ) { - return esc_url( $atts['url'] ); - } - - /** - * Display user avatar. - * - * @since 3.1.7 - * @since 3.2.0 Moved to WP_Members_Shortcodes::avatar(). - * - * @param array $atts { - * The shortcode attributes. - * - * @type string $id The user email or id. - * @type int $size Avatar size (square) in pixels. - * } - * @param string $content - * @param string $tag - * @retrun string $content - */ - function avatar( $atts, $content, $tag ) { - $content = ''; - $size = ( isset( $atts['size'] ) ) ? $atts['size'] : ''; - if ( isset( $atts['id'] ) ) { - $content = get_avatar( $atts['id'], $size ); - } elseif ( is_user_logged_in() ) { - // If the user is logged in and this isn't specifying a user ID, return the current user avatar. - global $current_user; - wp_get_current_user(); - $content = get_avatar( $current_user->ID, $size ); - } - return do_shortcode( $content ); - } - - /** - * Generates a login link with a return url. - * - * @since 3.1.7 - * @since 3.2.0 Moved to WP_Members_Shortcodes::login_link(). - * - * @param array $atts { - * The shortcode attributes. - * } - * @param string $content - * @param string $tag - * @return string $content - */ - function login_link( $atts, $content, $tag ) { - if ( 'wpmem_reg_link' == $tag ) { - $text = ( $content ) ? $content : __( 'Register' ); - $link = add_query_arg( 'redirect_to', wpmem_current_url(), wpmem_register_url() ); - } else { - $text = ( $content ) ? $content : __( 'Log In' ); - $link = wpmem_login_url( wpmem_current_url() ); - } - $content = '' . $text . ''; - return do_shortcode( $content ); - } - - /** - * Generate a nonce for a WP-Members form. - * - * For situations where a hardcoded form may exist, this shortcode - * can output the appropriate nonce. - * - * @since 3.3.0 - * - * @param array $atts { - * The shortcode attributes. - * - * $form string The form to generate the nonce for (register|update|login) - * } - * $param string $content - * @param string $tag - * @return string $content - */ - function form_nonce( $atts, $content, $tag ) { - $nonce = ( isset( $atts['form'] ) ) ? $atts['form'] : 'register'; - $content = wpmem_form_nonce( $nonce, false ); - return do_shortcode( $content ); - } -} - -// End of file. \ No newline at end of file diff --git a/readme.txt b/readme.txt index b5456b41..b4e389f1 100644 --- a/readme.txt +++ b/readme.txt @@ -134,6 +134,9 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. * Fixed function name typo for wpmem_a_extend_user() (a PayPal extension function used in the core plugin). * Updated product access shortcode error message to use the product_restricted message and changed the class to product_restricted_msg * Updated CAPTCHA class for more flexibility (can now be implemented into API for calling directly in the login or other forms). +* Moved user export function from Admin API to User API. +* Fixed adding WP-Members fields to WooCommerce checkout. + = 3.3.3 = From dfca3d9106fd1db92ef9cb87724bc965d4f73b1a Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 15 May 2020 20:50:01 -0400 Subject: [PATCH 1243/1694] remove debug code from checkout fields --- includes/api/api-forms.php | 8 ++++---- wp-members.php | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 5b860cd4..a6d61d67 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -460,10 +460,10 @@ function wpmem_woo_checkout_update_meta( $order_id ) { $order = wc_get_order( $order_id ); $user_id = $order->get_user_id(); - $checkout_fields = WC()->checkout()->checkout_fields; //write_log( $checkout_fields ); - $fields = wpmem_fields(); //write_log( $fields ); - foreach ( $fields as $meta_key => $field ) { write_log( $meta_key ); - if ( isset( $checkout_fields['order'][ $meta_key ] ) && isset( $_POST[ $meta_key ] ) ) { write_log( 'user ' . $user_id . ' meta_key: ' . $meta_key . 'post: ' . sanitize_text_field( $_POST[ $meta_key ] ) ); + $checkout_fields = WC()->checkout()->checkout_fields; + $fields = wpmem_fields(); + foreach ( $fields as $meta_key => $field ) { + if ( isset( $checkout_fields['order'][ $meta_key ] ) && isset( $_POST[ $meta_key ] ) ) { switch ( $fields[ $meta_key ]['type'] ) { case 'checkbox': update_user_meta( $user_id, $meta_key, $field['checked_value'] ); diff --git a/wp-members.php b/wp-members.php index 65218994..461d00af 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.3.4 +Version: 3.3.4.1 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -64,7 +64,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.3.4' ); +define( 'WPMEM_VERSION', '3.3.4.1' ); define( 'WPMEM_DB_VERSION', '2.2.0' ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From f3e2b0e9dc77c37b91048e5ab225fe377ba3e679 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 15 May 2020 20:50:38 -0400 Subject: [PATCH 1244/1694] added pasword reset link option --- .../class-wp-members-admin-tab-options.php | 2 + includes/class-wp-members-pwd-reset.php | 249 ++++++++++++++++++ includes/class-wp-members.php | 15 ++ readme.txt | 6 +- 4 files changed, 271 insertions(+), 1 deletion(-) create mode 100644 includes/class-wp-members-pwd-reset.php diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index fdf6ec94..3015e1e7 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -179,6 +179,7 @@ static function build_settings() { /** This filter is defined in class-wp-members.php */ $dropin_dir = apply_filters( 'wpmem_dropin_dir', $wpmem->dropin_dir ); $arr = array( + array(__('Password Reset', 'wp-members'),'wpmem_settings_pwd_reset',__('Send password reset link instead of new password. (Requires additional configuration)','wp-members'),'pwd_reset_link'), array(__('Enable Products', 'wp-members'),'wpmem_settings_products',__('Enables creation of different membership products','wp-members'),'enable_products'), array(__('Clone menus','wp-members'),'wpmem_settings_menus',__('Enables logged in menus','wp-members'),'clone_menus'), array(__('Notify admin','wp-members'),'wpmem_settings_notify',sprintf(__('Notify %s for each new registration? %s','wp-members'),$admin_email,$chg_email),'notify'), @@ -479,6 +480,7 @@ static function update( $action ) { $wpmem_newsettings = array( 'version' => $wpmem->version, 'db_version' => $wpmem->db_version, + 'pwd_reset_link' => filter_var( wpmem_get( 'wpmem_settings_pwd_reset', 0 ), FILTER_SANITIZE_NUMBER_INT ), 'enable_products' => filter_var( wpmem_get( 'wpmem_settings_products', 0 ), FILTER_SANITIZE_NUMBER_INT ), 'clone_menus' => filter_var( wpmem_get( 'wpmem_settings_menus', 0 ), FILTER_SANITIZE_NUMBER_INT ), 'notify' => filter_var( wpmem_get( 'wpmem_settings_notify', 0 ), FILTER_SANITIZE_NUMBER_INT ), diff --git a/includes/class-wp-members-pwd-reset.php b/includes/class-wp-members-pwd-reset.php new file mode 100644 index 00000000..d99b3dc5 --- /dev/null +++ b/includes/class-wp-members-pwd-reset.php @@ -0,0 +1,249 @@ +form_submitted_key_not_found = __( "Sorry, no password reset key was found. Please check your email and try again.", 'wp-members' ); + $this->form_load_key_not_found = __( "Sorry, no password reset key was found. Please check your email and try again.", 'wp-members' ); + $this->key_is_expired = __( "Sorry, the password reset key is expired.", 'wp-members' ); + + add_filter( 'wpmem_email_filter', array( $this, 'add_reset_key_to_email' ), 10, 3 ); + add_filter( 'the_content', array( $this, 'display_content' ), 100 ); + add_filter( 'wpmem_login_hidden_fields', array( $this, 'add_hidden_form_field' ), 10, 2 ); + add_action( 'wpmem_get_action', array( $this, 'get_wpmem_action' ) ); + add_filter( 'wpmem_regchk', array( $this, 'change_regchk' ), 10, 2 ); + add_filter( 'wpmem_resetpassword_form_defaults', array( $this, 'reset_password_form' ) ); + } + + /** + * Create a password reset key for the user. + * + * @since 3.3.5 + * + * @param int $user_id + * @return string $key + */ + function generate_reset_key( $user_id ) { + $key = md5( wp_generate_password() ); + update_user_meta( $user_id, $this->reset_key_meta, $key ); + update_user_meta( $user_id, $this->reset_key_exp, time() + 21600 ); + return $key; + } + + // utility for getting the user ID by the password_reset_key + function get_user_by_pwd_key( $key ) { + // Get the user account the key is for. + $users = get_users( array( + 'meta_key' => $this->reset_key_meta, + 'meta_value' => $key, + 'number' => 1, + 'count_total' => false + ) ); + if ( $users ) { + foreach( $users as $user ) { + return $user->ID; + } + } + return false; + } + + // Check if key is expired. + function key_is_valid( $key, $user_id ) { + $expires = get_user_meta( $user_id, $this->reset_key_exp, true ); + return ( time() < $expires ) ? true : false; + } + + // Include the key in the email to user. + function add_reset_key_to_email( $arr, $wpmem_fields, $field_data ) { + // Only do this for new registrations. + if ( $arr['toggle'] == 'repass' ) { + // Get the stored key. + $key = $this->generate_reset_key( $arr['user_id'] ); + $query_args = array( + 'a' => $this->form_action, + 'key' => $key, + ); + // Add text and link to the email body. + $arr['body'] = $arr['body'] . "\r\n" + . add_query_arg( $query_args, trailingslashit( wpmem_profile_url() ) ); + } + return $arr; + } + + function display_content( $content ) { + if ( ! is_user_logged_in() && in_the_loop() && $this->form_action == wpmem_get( 'a', false, 'request' ) ) { + // Define variables + $result = false; $user_id = false; + + // Check for key + $key = sanitize_text_field( wpmem_get( 'key', false, 'request' ) ); + + // Validate + if ( 1 == wpmem_get( 'formsubmit' ) && false !== wpmem_get( 'a', false, $this->form_action ) ) { + // form was submitted, validate fields + $user_id = $this->get_user_by_pwd_key( $key ); + if ( $user_id ) { + // Key was found, is it expired? + if ( true === $this->key_is_valid( $key, $user_id ) ) { + $result = $this->change_password( $user_id ); + } else { + return $this->key_is_expired; + } + } else { + $result = 'submittedkeynotfound'; + } + } + if ( $result != 'pwdchangesuccess' ) { + + if ( 'submittedkeynotfound' == $result ) { + // If somehow the form was submitted but the key not found. + return $this->form_submitted_key_not_found; + } + + // If no key found on initial form load, or if no key was passed + if ( $key ) { + $user_id = $this->get_user_by_pwd_key( $key ); + if ( ! $user_id ) { + return $this->form_load_key_not_found; + } else { + if ( false === $this->key_is_valid( $key, $user_id ) ) { + return $this->key_is_expired; + } + } + } else { + return $this->form_load_key_not_found; + } + + $content = wpmem_change_password_form(); + } else { + $content = wpmem_inc_regmessage( 'pwdchangesuccess' ); + if ( $user_id ) { + delete_user_meta( $user_id, $this->reset_key_meta ); + delete_user_meta( $user_id, $this->reset_key_exp ); + } + } + } + return $content; + } + + function add_hidden_form_field( $hidden_fields, $action ) { + if ( $this->form_action == wpmem_get( 'a', false, 'request' ) ) { + $hidden_fields = str_replace( 'pwdchange', $this->form_action, $hidden_fields ); + $hidden_fields.= wpmem_create_formfield( $this->reset_key_meta, 'hidden', wpmem_get( 'key', null, 'request' ) ); + } + return $hidden_fields; + } + + function get_wpmem_action() { + global $wpmem; + if ( 'pwdreset' == $wpmem->action && isset( $_POST['formsubmit'] ) ) { + + $user_to_check = wpmem_get( 'user', false ); + $user_to_check = ( strpos( $user_to_check, '@' ) ) ? sanitize_email( $user_to_check ) : sanitize_user( $user_to_check ); + + if ( username_exists( $user_to_check ) ) { + $user = get_user_by( 'login', $user_to_check ); + if ( ( 1 == $wpmem->mod_reg ) && ( 1 != get_user_meta( $user->ID, 'active', true ) ) ) { + $user = false; + } + } elseif ( email_exists( $user_to_check ) ) { + $user = get_user_by( 'email', $user_to_check ); + } else { + $user = false; + } + + if ( false === $user ) { + return "pwdreseterr"; + } + + $new_pass = ''; + wpmem_email_to_user( $user->ID, $new_pass, 3 ); + do_action( 'wpmem_pwd_reset', $user->ID, $new_pass ); + $wpmem->action = 'pwdreset_link'; + global $wpmem_regchk; + $wpmem->regchk = 'pwdresetsuccess'; + return "pwdresetsuccess"; + } + return; + } + + function change_regchk( $regchk, $action ) { + global $wpmem; + if ( 'pwdreset_link' == $action && 'pwdresetsuccess' == $wpmem->regchk ) { + global $wpmem; + $wpmem->action = 'pwdreset'; + return 'pwdresetsuccess'; + } + return $regchk; + } + + /** + * Change a user's password() + * (A custom version of $wpmem->user->password_change().) + */ + function change_password( $user_id ) { + if ( isset( $_POST['formsubmit'] ) ) { + $args = array( + 'pass1' => wpmem_get( 'pass1', false ), + 'pass2' => wpmem_get( 'pass2', false ), + ); + } + + $is_error = false; + // Check for both fields being empty. + $is_error = ( ! $args['pass1'] && ! $args['pass2'] ) ? "pwdchangempty" : $is_error; + // Make sure the fields match. + $is_error = ( $args['pass1'] != $args['pass2'] ) ? "pwdchangerr" : $is_error; + /** + * Filters the password change error. + * + * @since 3.1.5 + * @since 3.1.7 Moved to user object. + * + * @param string $is_error + * @param int $user_id The user's numeric ID. + * @param string $args['pass1'] The user's new plain text password. + */ + $is_error = apply_filters( 'wpmem_pwd_change_error', $is_error, $user_id, $args['pass1'] ); + + // Verify nonce. + $is_error = ( ! wp_verify_nonce( $_REQUEST['_wpmem_pwdchange_nonce'], 'wpmem_shortform_nonce' ) ) ? "reg_generic" : $is_error; + if ( $is_error ) { + return $is_error; + } + wp_set_password( $args['pass1'] , $user_id ); + return "pwdchangesuccess"; + } + + function reset_password_form( $args ) { + global $wpmem; + $args['inputs'][0]['name'] = $wpmem->get_text( 'login_username' ); + unset( $args['inputs'][1] ); + return $args; + } +} \ No newline at end of file diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 28d8dab9..3a332e1d 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -298,6 +298,17 @@ class WP_Members { */ public $is_rest = false; + /** + * Temporary setting for password reset. + * Will default to 0 until 3.4.0, then 1 until 3.5.0 + * at which point we'll remove the old process. + * + * @since 3.3.5 + * @access public + * @var string + */ + public $pwd_reset_link = 0; + /** * Plugin initialization function. * @@ -357,6 +368,9 @@ function __construct() { if ( $this->clone_menus ) { $this->menus_clone = new WP_Members_Clone_Menus(); // Load clone menus. } + if ( 1 == $this->pwd_reset_link ) { + $this->pwd_reset = new WP_Members_Pwd_Reset; + } // @todo Is this a temporary fix? $this->email->load_from(); @@ -559,6 +573,7 @@ function load_dependencies() { require_once( $this->path . 'includes/class-wp-members-forms.php' ); require_once( $this->path . 'includes/class-wp-members-menus.php' ); require_once( $this->path . 'includes/class-wp-members-products.php' ); + require_once( $this->path . 'includes/class-wp-members-pwd-reset.php' ); require_once( $this->path . 'includes/class-wp-members-shortcodes.php' ); require_once( $this->path . 'includes/class-wp-members-user.php' ); require_once( $this->path . 'includes/class-wp-members-user-profile.php' ); diff --git a/readme.txt b/readme.txt index b4e389f1..3642b97d 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 5.4 -Stable tag: 3.3.3 +Stable tag: 3.3.4.1 License: GPLv2 == Description == @@ -124,6 +124,10 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. == Changelog == += 3.3.5 = + +* Added optional password reset link (instead of sending password). This option will become the default setting in 3.4.0. + = 3.3.4 = * Updated pre_get_posts to merge post__not_in with any existing values. This will allow for better integration with other plugins (such as Search Exclude). From bce9c13df170d3a0860b05e25532a9a7d31af5d0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 17 May 2020 10:21:20 -0400 Subject: [PATCH 1245/1694] only run wc filter on wpmem fields --- includes/api/api-forms.php | 66 +++++++++++++++++++++----------------- 1 file changed, 37 insertions(+), 29 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index a6d61d67..d60979c0 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -484,36 +484,44 @@ function wpmem_woo_checkout_update_meta( $order_id ) { } function wpmem_form_field_wc_custom_field_types( $field, $key, $args, $value ) { - + $wpmem_fields = wpmem_fields(); - /* @type string $name (required) The field meta key. - * @type string $type (required) The field HTML type (url, email, image, file, checkbox, text, textarea, password, hidden, select, multiselect, multicheckbox, radio). - * @type string $value (optional) The field's value (can be a null value). - * @type string $compare (optional) Compare value. - * @type string $class (optional) Class identifier for the field. - * @type boolean $required (optional) If a value is required default: true). - * @type string $delimiter (optional) The field delimiter (pipe or comma, default: | ). - * @type string $placeholder (optional) Defines the placeholder attribute. - * @type string $pattern (optional) Adds a regex pattern to the field (HTML5). - * @type string $title (optional) Defines the title attribute. - * @type string $min (optional) Adds a min attribute (HTML5). - * @type string $max (optional) Adds a max attribute (HTML5). - * @type string $rows (optional) Adds rows attribute to textarea. - * @type string $cols (optional) Adds cols attribute to textarea. - */ - $field_args = array( - 'name' => $key, - 'type' => $wpmem_fields[ $key ]['type'], - 'required' => $wpmem_fields[ $key ]['required'], - 'delimiter' => $wpmem_fields[ $key ]['delimiter'], - 'value' => $wpmem_fields[ $key ]['values'], - ); + /** + * @type string $name (required) The field meta key. + * @type string $type (required) The field HTML type (url, email, image, file, checkbox, text, textarea, password, hidden, select, multiselect, multicheckbox, radio). + * @type string $value (optional) The field's value (can be a null value). + * @type string $compare (optional) Compare value. + * @type string $class (optional) Class identifier for the field. + * @type boolean $required (optional) If a value is required default: true). + * @type string $delimiter (optional) The field delimiter (pipe or comma, default: | ). + * @type string $placeholder (optional) Defines the placeholder attribute. + * @type string $pattern (optional) Adds a regex pattern to the field (HTML5). + * @type string $title (optional) Defines the title attribute. + * @type string $min (optional) Adds a min attribute (HTML5). + * @type string $max (optional) Adds a max attribute (HTML5). + * @type string $rows (optional) Adds rows attribute to textarea. + * @type string $cols (optional) Adds cols attribute to textarea. + */ - $field_html = wpmem_form_field( $field_args ); - $field_html = str_replace( 'class="' . $wpmem_fields[ $key ]['type'] . '"', 'class="' . $wpmem_fields[ $key ]['type'] . '" style="display:initial;"', $field_html ); - $field = '

    - '; - $field .= $field_html; - $field .= '

    '; + // Let's only mess with WP-Members fields (in case another checkout fields plugin is used). + if ( array_key_exists( $key, $wpmem_fields ) ) { + + $field_args = array( + 'name' => $key, + 'type' => $wpmem_fields[ $key ]['type'], + 'required' => $wpmem_fields[ $key ]['required'], + 'delimiter' => $wpmem_fields[ $key ]['delimiter'], + 'value' => $wpmem_fields[ $key ]['values'], + ); + + $field_html = wpmem_form_field( $field_args ); + $field_html = str_replace( 'class="' . $wpmem_fields[ $key ]['type'] . '"', 'class="' . $wpmem_fields[ $key ]['type'] . '" style="display:initial;"', $field_html ); + $field = '

    + '; + $field .= $field_html; + $field .= '

    '; + + } + return $field; } \ No newline at end of file From ab0b0281704010056f90c0d728c4f5062bafc739 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 17 May 2020 10:24:58 -0400 Subject: [PATCH 1246/1694] only run add wpmem fields to checkout if not logged in (new user reg) --- includes/class-wp-members.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 3a332e1d..dfc59f79 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -444,14 +444,14 @@ function load_hooks() { add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration add_action( 'woocommerce_register_form', 'wpmem_woo_register_form' ); - add_filter( 'woocommerce_checkout_fields', 'wpmem_woo_checkout_form' ); + add_action( 'woocommerce_checkout_update_order_meta', 'wpmem_woo_checkout_update_meta' ); - //add_action( 'woocommerce_after_order_notes', 'wpmem_woo_checkout_form2' ); - // Adds custom field types to use WP-Members field types on WooCommerce checkout. - //add_action( 'woocommerce_form_field_multiselect', 'wpmem_form_field_wc_multiselect', 10, 4 ); - add_action( 'woocommerce_form_field_multicheckbox', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); - add_action( 'woocommerce_form_field_multiselect', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); - add_action( 'woocommerce_form_field_radio', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); + add_action( 'woocommerce_form_field_multicheckbox', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); + add_action( 'woocommerce_form_field_multiselect', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); + add_action( 'woocommerce_form_field_radio', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); + if ( ! is_user_logged_in() ) { + add_filter( 'woocommerce_checkout_fields', 'wpmem_woo_checkout_form' ); + } // Add filters. add_filter( 'the_content', array( $this, 'do_securify' ), 99 ); From 9a55f1952d385b9934dbd94753d8c1713d70e9ea Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 17 May 2020 11:27:20 -0400 Subject: [PATCH 1247/1694] @todo review --- includes/class-wp-members-clone-menus.php | 1 - includes/class-wp-members-menus.php | 2 +- includes/install.php | 5 +++++ 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-clone-menus.php b/includes/class-wp-members-clone-menus.php index f9792ce4..2ce7a77c 100644 --- a/includes/class-wp-members-clone-menus.php +++ b/includes/class-wp-members-clone-menus.php @@ -74,7 +74,6 @@ function serve_menu( $args ) { * Filter the served menu. * * @since 3.2.6 - * @todo Determine what extra parameters to pass and how (then document them). * * @param boolean * @param string $theme_loc diff --git a/includes/class-wp-members-menus.php b/includes/class-wp-members-menus.php index 70b91fa2..741c2213 100644 --- a/includes/class-wp-members-menus.php +++ b/includes/class-wp-members-menus.php @@ -65,7 +65,7 @@ public function load_hooks() { global $wp_version; if ( version_compare( $wp_version, '5.4', '<' ) ) { - add_filter( 'wp_edit_nav_menu_walker', array( $this, 'edit_nav_menu_walker' ) ); // @todo No longer needed in WP 5.4? + add_filter( 'wp_edit_nav_menu_walker', array( $this, 'edit_nav_menu_walker' ) ); } add_action( 'wp_update_nav_menu_item', array( $this, 'update_nav_menu_item' ), 10, 2 ); diff --git a/includes/install.php b/includes/install.php index 4a03a630..80915dcf 100644 --- a/includes/install.php +++ b/includes/install.php @@ -19,6 +19,11 @@ exit(); } +/** + * @todo Updates/install revisions needed: + * - if reCAPTCHA is "1", update to "3" - reCAPTCHA v1 is fully obsolete by Google. + */ + /** * Installs or upgrades the plugin. * From 6bbd55714e6195264a05ccef7443cc7d78951fd5 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 17 May 2020 11:27:41 -0400 Subject: [PATCH 1248/1694] updated default product restricted messaging --- includes/class-wp-members-products.php | 15 ++++++++++++--- includes/class-wp-members.php | 3 ++- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/includes/class-wp-members-products.php b/includes/class-wp-members-products.php index 42369934..553b337a 100644 --- a/includes/class-wp-members-products.php +++ b/includes/class-wp-members-products.php @@ -201,8 +201,17 @@ function product_access( $content ) { // Content that has no product restriction. $access = true; } - - // Handle content. + + // Handle default membership restricted message. + if ( 1 == count( $post_products ) ) { + $message = $wpmem->get_text( 'product_restricted_single' ) + . "
    " . $wpmem->membership->products[ $post_products[0] ]['title']; + } else { + $message = $wpmem->get_text( 'product_restricted_multiple' ) . "
    "; + foreach ( $post_products as $post_product ) { + $message .= $wpmem->membership->products[ $post_product ]['title'] . "
    "; + } + } /** * Filter the product restricted message. * @@ -215,7 +224,7 @@ function product_access( $content ) { * @type string $slug * } */ - $message = apply_filters( 'wpmem_product_restricted_msg', $wpmem->get_text( 'product_restricted' ), $post_products ); + $message = apply_filters( 'wpmem_product_restricted_msg', $message, $post_products ); /** * Filter the product restricted message HTML. diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index dfc59f79..57ffd306 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -1598,7 +1598,8 @@ function get_text( $str ) { 'pwdreseterr' => __( "Either the username or email address do not exist in our records.", 'wp-members' ), 'pwdresetsuccess' => __( "Password successfully reset!

    An email containing a new password has been sent to the email address on file for your account.", 'wp-members' ), - 'product_restricted' => __( "Sorry, you do not have access to this content.", 'wp-members' ), + 'product_restricted_single' => __( "This content requires the following membership: ", 'wp-members' ), + 'product_restricted_multiple' => __( "This content requires one of the following memberships: ", 'wp-members' ), ); // End of $defaults array. From 47e844d6aa777243d180dc81ba5e65ac48ba7d4e Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 17 May 2020 20:29:20 -0400 Subject: [PATCH 1249/1694] fix bug that causes register form heading to not display when shortcode is used --- includes/class-wp-members-forms.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index e78eca39..6c4c63b8 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1366,7 +1366,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { * * @param string The default edit mode heading. */ - $heading = ( isset( $heading ) ) ? $heading : apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); + $heading = ( isset( $heading ) && '' != $heading ) ? $heading : apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); } else { /** * Filter the registration form heading. @@ -1376,7 +1376,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { * @param string $str * @param string $tag Toggle new registration or profile update. new|edit. */ - $heading = ( isset( $heading ) ) ? $heading : apply_filters( 'wpmem_register_heading', $wpmem->get_text( 'register_heading' ), $tag ); + $heading = ( isset( $heading ) && '' != $heading ) ? $heading : apply_filters( 'wpmem_register_heading', $wpmem->get_text( 'register_heading' ), $tag ); } $form = $args['heading_before'] . $heading . $args['heading_after'] . $args['n'] . $form; From e99f7b00cd0006c7c7ff65a2fe32b5b40b6c51d5 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 17 May 2020 20:29:56 -0400 Subject: [PATCH 1250/1694] added new user activation link option --- .../class-wp-members-admin-tab-options.php | 4 +- includes/class-wp-members-activation-link.php | 155 ++++++++++++++++++ includes/class-wp-members.php | 8 +- includes/legacy/dialogs.php | 4 +- readme.txt | 10 +- 5 files changed, 172 insertions(+), 9 deletions(-) create mode 100644 includes/class-wp-members-activation-link.php diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index 3015e1e7..117c0287 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -179,7 +179,7 @@ static function build_settings() { /** This filter is defined in class-wp-members.php */ $dropin_dir = apply_filters( 'wpmem_dropin_dir', $wpmem->dropin_dir ); $arr = array( - array(__('Password Reset', 'wp-members'),'wpmem_settings_pwd_reset',__('Send password reset link instead of new password. (Requires additional configuration)','wp-members'),'pwd_reset_link'), + array(__('Activation', 'wp-members'),'wpmem_settings_pwd_reset',__('Send initial activation link and password reset link instead of new password. (Requires additional configuration)','wp-members'),'key_link'), array(__('Enable Products', 'wp-members'),'wpmem_settings_products',__('Enables creation of different membership products','wp-members'),'enable_products'), array(__('Clone menus','wp-members'),'wpmem_settings_menus',__('Enables logged in menus','wp-members'),'clone_menus'), array(__('Notify admin','wp-members'),'wpmem_settings_notify',sprintf(__('Notify %s for each new registration? %s','wp-members'),$admin_email,$chg_email),'notify'), @@ -480,7 +480,7 @@ static function update( $action ) { $wpmem_newsettings = array( 'version' => $wpmem->version, 'db_version' => $wpmem->db_version, - 'pwd_reset_link' => filter_var( wpmem_get( 'wpmem_settings_pwd_reset', 0 ), FILTER_SANITIZE_NUMBER_INT ), + 'key_link' => filter_var( wpmem_get( 'wpmem_settings_pwd_reset', 0 ), FILTER_SANITIZE_NUMBER_INT ), 'enable_products' => filter_var( wpmem_get( 'wpmem_settings_products', 0 ), FILTER_SANITIZE_NUMBER_INT ), 'clone_menus' => filter_var( wpmem_get( 'wpmem_settings_menus', 0 ), FILTER_SANITIZE_NUMBER_INT ), 'notify' => filter_var( wpmem_get( 'wpmem_settings_notify', 0 ), FILTER_SANITIZE_NUMBER_INT ), diff --git a/includes/class-wp-members-activation-link.php b/includes/class-wp-members-activation-link.php new file mode 100644 index 00000000..77b39ad9 --- /dev/null +++ b/includes/class-wp-members-activation-link.php @@ -0,0 +1,155 @@ +send_welcome = true; + $this->show_success = true; + $this->send_notify = true; + $this->auto_delete = true; + + $this->email_text = __( 'Click to activate your account: ', 'wp-members' ); + $this->success_message = __( 'Thank you for activating your account.', 'wp-members' ); + $this->expired_message = __( 'Activation key was expired or invalid', 'wp-members' ); + + add_action( 'wpmem_after_init', array( $this, 'default_to_mod' ) ); + add_action( 'user_register', array( $this, 'generate_key' ) ); + add_filter( 'wpmem_email_filter', array( $this, 'add_key_to_email' ), 10, 3 ); + add_action( 'template_redirect', array( $this, 'validate_key' ) ); + add_filter( 'the_content', array( $this, 'activation_success' ), 100 ); + } + + function default_to_mod() { + global $wpmem; + $wpmem->mod_reg = 1; + } + + /** + * Create an activation key for the + * user at registration. + */ + function generate_key( $user_id ) { + + // Generate a random key. + $key = md5( wp_generate_password() ); + + // Save this for the new user account. + add_user_meta( $user_id, $this->activation_key_meta, $key ); + add_user_meta( $user_id, $this->activation_key_exp, time() + 21600 ); + } + + // Check if key is expired. + function key_is_valid( $key, $user_id ) { + $expires = get_user_meta( $user_id, $this->activation_key_exp, true ); + return ( time() < $expires ) ? true : false; + } + + /** + * Include the activation key in the new user + * registration email as an activation link. + */ + function add_key_to_email( $arr, $wpmem_fields, $field_data ) { + + /** + * Filter the return url + * + * @since 3.3.5 + */ + $url = apply_filters( 'wpmem_activation_link_return_url', trailingslashit( wpmem_profile_url() ) ); + + // Only do this for new registrations. + if ( $arr['toggle'] == 'newmod' ) { + // Get the stored key. + $key = get_user_meta( $arr['user_id'], $this->activation_key_meta, true ); + $exp = get_user_meta( $arr['user_id'], $this->activation_key_exp, true ); + // Add text and link to the email body. + $arr['body'] = $arr['body'] . "\r\n" + . $this->email_text + . add_query_arg( array( 'a'=>'activate', 'key'=>$key ), $url ); + } + + return $arr; + } + + /** + * Check for an activation key and if one exists, + * validate and log in user. + */ + function validate_key() { + + // Check for activation key. + $key = ( 'activate' == wpmem_get( 'a', false, 'get' ) ) ? wpmem_get( 'key', false, 'get' ) : false; + if ( false !== $key ) { + + // Get the user account the key is for. + $users = get_users( array( + 'meta_key' => $this->activation_key_meta, + 'meta_value' => $key, + 'number' => 1, + 'count_total' => false + ) ); + + if ( $users ) { + foreach( $users as $user ) { + + if ( true === $this->key_is_valid( $key, $user->ID ) ) { + + $this->validated = true; + + // The provided activation key was valid, log in. + wp_set_auth_cookie( $user->ID, true ); + wp_set_current_user( $user->ID ); + + // Delete activation_key meta and set active. + delete_user_meta( $user->ID, $this->activation_key_meta ); + delete_user_meta( $user->ID, $this->activation_key_exp ); + update_user_meta( $user->ID, $this->activation_confirm, time() ); + update_user_meta( $user->ID, 'active', '1' ); + + if ( $this->send_welcome ) { + // Send a welcome email + wpmem_email_to_user( $user->ID, '', 2 ); + } + + if ( $this->send_notify ) { + // Send a welcome email + global $wpmem; + wpmem_notify_admin( $user->ID, $wpmem->fields ); + } + break; + } else { + $this->validated = false; + break; + } + } + + } else { + $this->validated = false; + } + } + } + + function activation_success( $content ) { + + if ( $this->show_success && 'activate' == wpmem_get( 'a', false, 'get' ) && isset( $this->validated ) ) { + + if ( true === $this->validated ) { + $content = wpmem_inc_regmessage( '', $this->success_message ) . $content; + } elseif ( false === $this->validated ) { + $content = wpmem_inc_regmessage( '', $this->expired_message ) . $content; + } + } + + return $content; + } +} \ No newline at end of file diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 57ffd306..14d87957 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -307,7 +307,7 @@ class WP_Members { * @access public * @var string */ - public $pwd_reset_link = 0; + public $key_link = 0; /** * Plugin initialization function. @@ -368,8 +368,9 @@ function __construct() { if ( $this->clone_menus ) { $this->menus_clone = new WP_Members_Clone_Menus(); // Load clone menus. } - if ( 1 == $this->pwd_reset_link ) { - $this->pwd_reset = new WP_Members_Pwd_Reset; + if ( 1 == $this->key_link ) { + $this->pwd_reset = new WP_Members_Pwd_Reset; + $this->act_newreg = new WP_Members_Activation_Link; } // @todo Is this a temporary fix? @@ -566,6 +567,7 @@ function load_dependencies() { include( $wpmem_pluggable ); } + require_once( $this->path . 'includes/class-wp-members-activation-link.php' ); require_once( $this->path . 'includes/class-wp-members-api.php' ); require_once( $this->path . 'includes/class-wp-members-clone-menus.php' ); require_once( $this->path . 'includes/class-wp-members-captcha.php' ); diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index f99da115..c718d1df 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -236,8 +236,8 @@ function wpmem_inc_memberlinks( $page = 'member' ) { 'wrapper_before' => '
      ', 'wrapper_after' => '
    ', 'rows' => array( - '
  • ' . $wpmem->get_text( 'profile_edit' ) . '
  • ', - '
  • ' . $wpmem->get_text( 'profile_password' ) . '
  • ', + '
  • ' . $wpmem->get_text( 'profile_edit' ) . '
  • ', + '
  • ' . $wpmem->get_text( 'profile_password' ) . '
  • ', ), 'after_wrapper' => '', ); diff --git a/readme.txt b/readme.txt index 3642b97d..7e51a901 100644 --- a/readme.txt +++ b/readme.txt @@ -41,6 +41,11 @@ Get support along with all of the plugin's premium extensions in one [cost savin Premium support subscribers have access to priority email support, examples, tutorials, and code snippets that will help you extend and customize the base plugin using the plugin's framework. [Visit the site for more info](https://rocketgeek.com/plugins/wp-members/support-options/). += Free Extensions = + +* [Stop Spam Registrations](https://rocketgeek.com/product/stop-spam-registrations/) - Uses stopforumspam.com's API to block spam registrations. +* [Send Test Emails](https://rocketgeek.com/product/send-test-emails/) - A utility to send test versions of the plugin's emails. + = Premium Extensions = The plugin has several premium extensions for additional functionality. You can purchase any of them individually, or get them all for a significant discount in the Pro Bundle. @@ -100,7 +105,7 @@ The FAQs are maintained at https://rocketgeek.com/plugins/wp-members/docs/faqs/ == Upgrade Notice == -WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. See changelog for important details. Minimum WP version is 4.0. +WP-Members 3.3.0 is a major update. WP-Members 3.3.4 is an improvement release. See changelog for important details. Minimum WP version is 4.0. == Screenshots == @@ -126,7 +131,8 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.3 is an improvement release. = 3.3.5 = -* Added optional password reset link (instead of sending password). This option will become the default setting in 3.4.0. +* Added optional new user activation link and password reset link (instead of sending password). This option will become the default setting in 3.4.0. +* Updated the default product restricted message to display required membership(s). This eliminates the custom message string "product_restricted" and replaces with two new ones: product_restricted_single and product_restricted_multiple. (Note this only affects the default message if no custom membership message is established in the membership properties). = 3.3.4 = From 30705cba6db18168d52603e18d86067806cc5d6f Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 22 May 2020 17:37:11 -0400 Subject: [PATCH 1251/1694] add datepicker support for products admin --- includes/admin/class-wp-members-admin-api.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/includes/admin/class-wp-members-admin-api.php b/includes/admin/class-wp-members-admin-api.php index 384ac8de..9e571fd6 100644 --- a/includes/admin/class-wp-members-admin-api.php +++ b/includes/admin/class-wp-members-admin-api.php @@ -564,6 +564,17 @@ function dashboard_enqueue_scripts( $hook ) { wp_enqueue_style( 'select2-style' ); wp_enqueue_script( 'select2' ); } + + //if ( ( 'post-new.php' == $hook && isset( $_GET['post_type'] ) && 'wpmem_product' == $_GET['post_type'] ) || ) + if ( 'wpmem_product' == get_post_type() ) { + wp_enqueue_script( 'jquery' ); + wp_enqueue_script( 'jquery-ui-core' );// enqueue jQuery UI Core + wp_enqueue_script( 'jquery-ui-datepicker' ); // enqueue jQuery UI Datepicker + if ( ! wp_style_is( 'jquery-ui-style', 'enqueued' ) ) { + wp_register_style( 'jquery-ui-style', $wpmem->url . 'assets/css/jquery-ui' . wpmem_get_suffix() . '.css' ); + } + wp_enqueue_style( 'jquery-ui-style' ); + } } if ( 'user-edit' == $current_screen->id || 'profile' == $current_screen->id ) { wp_enqueue_script( 'jquery' ); @@ -580,6 +591,7 @@ function dashboard_enqueue_scripts( $hook ) { wp_enqueue_script( 'jquery' ); wp_enqueue_script( 'jquery-ui-core' );// enqueue jQuery UI Core wp_enqueue_script( 'jquery-ui-dialog' ); + wp_enqueue_script( 'jquery-ui-datepicker' ); // enqueue jQuery UI Datepicker if ( ! wp_style_is( 'jquery-ui-style', 'enqueued' ) ) { wp_register_style( 'jquery-ui-style', $wpmem->url . 'assets/css/jquery-ui' . wpmem_get_suffix() . '.css' ); From 9edfcb4bdcfeae0b8eb7434ce3c362e574e09d54 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 22 May 2020 17:37:37 -0400 Subject: [PATCH 1252/1694] add media upload support --- includes/class-wp-members-forms.php | 1 + 1 file changed, 1 insertion(+) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 6c4c63b8..fd5e4547 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -387,6 +387,7 @@ function do_file_upload( $file = array(), $user_id = false ) { // Get WordPress file upload processing scripts. require_once( ABSPATH . 'wp-admin/includes/file.php' ); + require_once( ABSPATH . 'wp-admin/includes/media.php' ); $file_return = wp_handle_upload( $file, array( 'test_form' => false ) ); From a1f9983df692c128584100e3e6e452a4f791a8dd Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 22 May 2020 17:40:19 -0400 Subject: [PATCH 1253/1694] add new barebones stylesheet --- assets/css/forms/wp-members-styles.css | 279 +++++++++++++++++++++ assets/css/forms/wp-members-styles.min.css | 1 + 2 files changed, 280 insertions(+) create mode 100644 assets/css/forms/wp-members-styles.css create mode 100644 assets/css/forms/wp-members-styles.min.css diff --git a/assets/css/forms/wp-members-styles.css b/assets/css/forms/wp-members-styles.css new file mode 100644 index 00000000..a8366720 --- /dev/null +++ b/assets/css/forms/wp-members-styles.css @@ -0,0 +1,279 @@ +/** + * WP-Members Styles CSS + * + * CSS for the WP-Members plugin + * + * This file is part of the WP-Members plugin by Chad Butler + * You can find out more about this plugin at https://rocketgeek.com + * Copyright (c) 2006-2020 Chad Butler + * WP-Members(tm) is a trademark of butlerblog.com + * + * @package WP-Members + * @author Chad Butler + * @copyright 2006-2020 + */ + +/* +This stylesheet is designed to integrate WP-Members floated form elements +as simply as possible with most themes. There are quite a few examples +in here of what you can do to style the forms. You can build off of this +or start from scratch and set your own custom css for the plugin +(set the location in the admin panel). + +See https://rocketgeek.com/tips-and-tricks/setting-up-a-custom-wp-members-stylesheet/ +for information on how to set up the plugin with a custom stylesheet. + +For information how to load custom stylesheets with wp_enqueue_style, +see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ +*/ + + +/* Error and Dialog Messages */ + +#wpmem_msg, +.wpmem_msg, +#wpmem_restricted_msg { + background: #F9F9F9; + border:1px solid lightGrey; + border-radius: 3px; + padding: 20px; + width: 100%; +} + +#wpmem_msg p, +.wpmem_msg p, +#wpmem_restricted_msg p { + margin: initial; + padding: initial; +} + +/* Sidebar Login Widget */ + +#wp-members { + width: 100%; +} +#wp-members fieldset { + border:none; + padding:0px +} +#wp-members input { + font-family: inherit; +} +#wp-members input[type="text"], +#wp-members input[type="password"]{ + margin: 0 0 4px 0; +} +#wp-members input[type="submit"] { + padding: 5px 6px 4px; + margin: 0 4px 0 0; +} +#wp-members .button_div { + margin-top:4px; +} +#wp-members .err { + width:100%; + padding: 5px; + font-family: inherit; + border: 1px solid #ccc; + border-radius: 3px; +} + + +/* Login Form and Registration Form */ +#wpmem_reg, +#wpmem_login {} + +#wpmem_reg label, +#wpmem_login label { + display: initial; +} + +#wpmem_reg input[type="text"], +#wpmem_reg input[type="password"], +#wpmem_reg input[type="email"], +#wpmem_reg input[type="url"], +#wpmem_reg input[type="number"], +#wpmem_reg input[type="date"], +#wpmem_reg textarea, +#wpmem_login input[type="text"], +#wpmem_login input[type="password"] { + border: 1px solid rgba(0, 0, 0, 0.1); + border-radius: 2px; + color: rgb(43, 43, 43); + padding: 8px 10px 8px; + background: none repeat scroll 0% 0% #fff; +} + +#wpmem_reg input, +#wpmem_reg button, +#wpmem_reg select, +#wpmem_reg textarea, +#wpmem_login input, +#wpmem_login button { + -moz-box-sizing: border-box; + font-size: 100%; + margin: 0px; + max-width: 100%; + vertical-align: baseline; +} + +#wpmem_reg input:focus, +#wpmem_reg textarea:focus, +#wpmem_login input:focus { + border: 1px solid rgba(0, 0, 0, 0.3); + outline: 0px none; +} + +#wpmem_reg select { + width:100%; + padding: 8px 10px 7px; + border: 1px solid rgba(0, 0, 0, 0.1); + border-radius: 2px; + color: rgb(43, 43, 43); + margin: 5px 0; +} + +#wpmem_reg fieldset, +#wpmem_login fieldset { + border: none; + padding: 0; + margin: 40px 0; +} +#wpmem_reg legend, +#wpmem_login legend { + font-size: 115%; + line-height: 1; + margin-bottom: 10px; + width: 100%; +} +#wpmem_reg .form, +#wpmem_login .form { + margin:0; + padding:0; +} +#wpmem_reg .clear, +#wpmem_login .clear { + clear:both; +} +#wpmem_reg .holder, +#wpmem_login .holder { + background-color:#fff; +} + +#wpmem_login .div_text, +#wpmem_reg .div_text, +#wpmem_reg .div_textarea, +#wpmem_reg .div_select, +#wpmem_reg .div_checkbox, +#wpmem_reg .div_multiselect, +#wpmem_reg .div_multicheckbox, +#wpmem_reg .div_radio, +#wpmem_reg .div_image, +#wpmem_reg .div_file, +#wpmem_reg .div_url, +#wpmem_reg .div_number, +#wpmem_reg .div_date { + width:100%; + margin:0 0 14px 0; +} +#wpmem_login input[type="checkbox"] { + margin: 12px 2px; +} +#wpmem_reg .div_textarea textarea, +#wpmem_reg .file, +#wpmem_reg .image, +#wpmem_reg .username, +#wpmem_reg .password, +#wpmem_reg .textbox, +#wpmem_login .textbox, +#wpmem_login .username, +#wpmem_login .password { + width:100%; +} + + +#wpmem_reg textarea { + height:185px; +} +#wpmem_reg .req { + color: #bd3500; + font-size: 22px; + line-height: 50%; +} + +#wpmem_reg .req-text { + margin: 20px 0px 0px 5px; +} + +#wpmem_reg .noinput { + width:93%; + padding: 8px 10px 7px; + border: 1px solid rgba(0, 0, 0, 0.1); + border-radius: 2px; + color: rgb(43, 43, 43); + margin: 5px 0; +} + +#wpmem_reg .captcha { + width: 100%; + margin: 5px 0px; +} +#wpmem_reg .captcha table{ + line-height: 0px; +} +#wpmem_login .link-text { + padding: 4px 0; + width: 100%; + text-align:right; +} + +#tos { + margin-right:5px; +} + + +/* Buttons */ + +#wpmem_reg .button_div, +#wpmem_login .button_div { + width:100%; + /* height:55px; */ + padding: 6px 0; + text-align: right; +} + + +/** for smaller screens */ + +@media screen and (max-width: 720px) { + #wpmem_reg label.text, #wpmem_reg label.checkbox, + #wpmem_reg label.textarea , #wpmem_reg label.select, + #wpmem_login label, #wpmem_reg .div_text, #wpmem_reg .div_textarea, + #wpmem_reg .div_select, #wpmem_login .div_text, + #wpmem_reg .div_checkbox, #wpmem_reg .button_div, #wpmem_login .button_div { + float: none; + } + + #wpmem_reg label.text, #wpmem_reg label.checkbox, + #wpmem_reg label.textarea , #wpmem_reg label.select { + width: 90%; + padding: 5px 0 0 0; + } + #wpmem_reg label.textarea { + height: 26px; + } + #wpmem_reg .div_text, #wpmem_reg .div_textarea, + #wpmem_reg .div_select, #wpmem_login .div_text, + #wpmem_reg .div_checkbox { + width: 98%; + } + #wpmem_msg, .wpmem_msg { + width: 100%; + } + + #wpmem_reg .button_div, + #wpmem_login .button_div, + #wpmem_login .link-text { + width:98%; + } +} \ No newline at end of file diff --git a/assets/css/forms/wp-members-styles.min.css b/assets/css/forms/wp-members-styles.min.css new file mode 100644 index 00000000..d37798f1 --- /dev/null +++ b/assets/css/forms/wp-members-styles.min.css @@ -0,0 +1 @@ +#wpmem_msg,#wpmem_restricted_msg,.wpmem_msg{background:#f9f9f9;border:1px solid #d3d3d3;border-radius:3px;padding:20px;width:100%}#wpmem_msg p,#wpmem_restricted_msg p,.wpmem_msg p{margin:initial;padding:initial}#wp-members{width:100%}#wp-members fieldset{border:none;padding:0}#wp-members input{font-family:inherit}#wp-members input[type=password],#wp-members input[type=text]{margin:0 0 4px 0}#wp-members input[type=submit]{padding:5px 6px 4px;margin:0 4px 0 0}#wp-members .button_div{margin-top:4px}#wp-members .err{width:100%;padding:5px;font-family:inherit;border:1px solid #ccc;border-radius:3px}#wpmem_login label,#wpmem_reg label{display:initial}#wpmem_login input[type=password],#wpmem_login input[type=text],#wpmem_reg input[type=date],#wpmem_reg input[type=email],#wpmem_reg input[type=number],#wpmem_reg input[type=password],#wpmem_reg input[type=text],#wpmem_reg input[type=url],#wpmem_reg textarea{border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;padding:8px 10px 8px;background:none repeat scroll 0 0 #fff}#wpmem_login button,#wpmem_login input,#wpmem_reg button,#wpmem_reg input,#wpmem_reg select,#wpmem_reg textarea{-moz-box-sizing:border-box;font-size:100%;margin:0;max-width:100%;vertical-align:baseline}#wpmem_login input:focus,#wpmem_reg input:focus,#wpmem_reg textarea:focus{border:1px solid rgba(0,0,0,.3);outline:0 none}#wpmem_reg select{width:100%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0}#wpmem_login fieldset,#wpmem_reg fieldset{border:none;padding:0;margin:40px 0}#wpmem_login legend,#wpmem_reg legend{font-size:115%;line-height:1;margin-bottom:10px;width:100%}#wpmem_login .form,#wpmem_reg .form{margin:0;padding:0}#wpmem_login .clear,#wpmem_reg .clear{clear:both}#wpmem_login .holder,#wpmem_reg .holder{background-color:#fff}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_date,#wpmem_reg .div_file,#wpmem_reg .div_image,#wpmem_reg .div_multicheckbox,#wpmem_reg .div_multiselect,#wpmem_reg .div_number,#wpmem_reg .div_radio,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg .div_url{width:100%;margin:0 0 14px 0}#wpmem_login input[type=checkbox]{margin:12px 2px}#wpmem_login .password,#wpmem_login .textbox,#wpmem_login .username,#wpmem_reg .div_textarea textarea,#wpmem_reg .file,#wpmem_reg .image,#wpmem_reg .password,#wpmem_reg .textbox,#wpmem_reg .username{width:100%}#wpmem_reg textarea{height:185px}#wpmem_reg .req{color:#bd3500;font-size:22px;line-height:50%}#wpmem_reg .req-text{margin:20px 0 0 5px}#wpmem_reg .noinput{width:93%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0}#wpmem_reg .captcha{width:100%;margin:5px 0}#wpmem_reg .captcha table{line-height:0}#wpmem_login .link-text{padding:4px 0;width:100%;text-align:right}#tos{margin-right:5px}#wpmem_login .button_div,#wpmem_reg .button_div{width:100%;padding:6px 0;text-align:right}@media screen and (max-width:720px){#wpmem_login .button_div,#wpmem_login .div_text,#wpmem_login label,#wpmem_reg .button_div,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{float:none}#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{width:90%;padding:5px 0 0 0}#wpmem_reg label.textarea{height:26px}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea{width:98%}#wpmem_msg,.wpmem_msg{width:100%}#wpmem_login .button_div,#wpmem_login .link-text,#wpmem_reg .button_div{width:98%}} \ No newline at end of file From a82e9a68c6c0397ed695246720da5bd2f8b9f912 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 22 May 2020 17:41:02 -0400 Subject: [PATCH 1254/1694] introduce wp cli support --- includes/class-wp-members.php | 4 +++ includes/cli/class-wp-members-cli.php | 36 +++++++++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 includes/cli/class-wp-members-cli.php diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 14d87957..59ce4216 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -588,6 +588,10 @@ function load_dependencies() { require_once( $this->path . 'includes/api/api-utilities.php' ); require_once( $this->path . 'includes/legacy/dialogs.php' ); require_once( $this->path . 'includes/deprecated.php' ); + + if ( defined( 'WP_CLI' ) && WP_CLI ) { + require_once( $this->path . 'includes/cli/class-wp-members-cli.php' ); + } } /** diff --git a/includes/cli/class-wp-members-cli.php b/includes/cli/class-wp-members-cli.php new file mode 100644 index 00000000..d21199e2 --- /dev/null +++ b/includes/cli/class-wp-members-cli.php @@ -0,0 +1,36 @@ +display_user_detail( $user->ID, $all ); + } + + private function display_user_detail( $user_id, $all ) { + WP_CLI::line( __( 'User: %s', 'wp-members' ) ); + + $values = wpmem_user_data( $user_id, $all ); + foreach ( $values as $key => $meta ) { + $list[] = array( + 'meta' => $key, + 'value' => $meta, + ); + } + + $formatter = new \WP_CLI\Formatter( $assoc_args, array( 'meta', 'value' ) ); + + $formatter->display_items( $list ); + } + + } + + WP_CLI::add_command( 'mem', 'WP_Members_CLI' ); + +} \ No newline at end of file From 12df5d010748711f659410eb7c3b6b35164985ab Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 22 May 2020 17:45:50 -0400 Subject: [PATCH 1255/1694] add back deprecated constant for backward compatibility with older extensions --- includes/deprecated.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/includes/deprecated.php b/includes/deprecated.php index 8b414f4e..edc8bb10 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -411,9 +411,10 @@ function wpmem_build_rs_captcha() { * * @since 3.3.0 */ +add_action( 'wpmem_after_init', 'wpmem_load_deprecated_constants' ); function wpmem_load_deprecated_constants() { global $wpmem; - ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem->block['post'] ) : ''; // @todo Can deprecate? Probably 3.3 +/* ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem->block['post'] ) : ''; // @todo Can deprecate? Probably 3.3 ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $wpmem->block['page'] ) : ''; // @todo Can deprecate? Probably 3.3 ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $wpmem->show_excerpt['post'] ) : ''; // @todo Can deprecate? Probably 3.3 ( ! defined( 'WPMEM_NOTIFY_ADMIN' ) ) ? define( 'WPMEM_NOTIFY_ADMIN', $wpmem->notify ) : ''; // @todo Can deprecate? Probably 3.3 @@ -424,8 +425,8 @@ function wpmem_load_deprecated_constants() { ( ! defined( 'WPMEM_MSURL' ) ) ? define( 'WPMEM_MSURL', $wpmem->user_pages['profile'] ) : ''; // @todo Can deprecate? Probably 3.3 ( ! defined( 'WPMEM_REGURL' ) ) ? define( 'WPMEM_REGURL', $wpmem->user_pages['register'] ) : ''; // @todo Can deprecate? Probably 3.3 ( ! defined( 'WPMEM_LOGURL' ) ) ? define( 'WPMEM_LOGURL', $wpmem->user_pages['login'] ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_DROPIN_DIR' ) ) ? define( 'WPMEM_DROPIN_DIR', WP_PLUGIN_DIR . '/wp-members-dropins/' ) : ''; - define( 'WPMEM_CSSURL', $wpmem->cssurl ); + ( ! defined( 'WPMEM_DROPIN_DIR' ) ) ? define( 'WPMEM_DROPIN_DIR', WP_PLUGIN_DIR . '/wp-members-dropins/' ) : '';*/ + ( ! defined( 'WPMEM_CSSURL' ) ) ? define( 'WPMEM_CSSURL', $wpmem->cssurl ) : ''; } if ( ! function_exists( 'wpmem_registration' ) ): From d1796877094fe8743691e927b1e85f7c6971f4c7 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 22 May 2020 17:55:47 -0400 Subject: [PATCH 1256/1694] updated translation files --- i18n/languages/wp-members-ca_CA.mo | Bin 18774 -> 18668 bytes i18n/languages/wp-members-ca_CA.po | 1765 ++++++++++++++++----------- i18n/languages/wp-members-da_DK.mo | Bin 18291 -> 18170 bytes i18n/languages/wp-members-da_DK.po | 1777 ++++++++++++++++----------- i18n/languages/wp-members-fi.mo | Bin 15736 -> 15636 bytes i18n/languages/wp-members-fi.po | 1743 +++++++++++++++----------- i18n/languages/wp-members-he_IL.mo | Bin 27907 -> 27821 bytes i18n/languages/wp-members-he_IL.po | 1763 ++++++++++++++++----------- i18n/languages/wp-members-hi_IN.mo | Bin 25021 -> 24980 bytes i18n/languages/wp-members-hi_IN.po | 1767 ++++++++++++++++----------- i18n/languages/wp-members-ko_KR.mo | Bin 22516 -> 22395 bytes i18n/languages/wp-members-ko_KR.po | 1827 ++++++++++++++++------------ i18n/languages/wp-members-nb_NO.mo | Bin 15031 -> 14954 bytes i18n/languages/wp-members-nb_NO.po | 1761 ++++++++++++++++----------- i18n/languages/wp-members-pl_PL.mo | Bin 12181 -> 12140 bytes i18n/languages/wp-members-pl_PL.po | 1777 ++++++++++++++++----------- i18n/languages/wp-members-pt_PT.mo | Bin 10843 -> 10802 bytes i18n/languages/wp-members-pt_PT.po | 1763 ++++++++++++++++----------- i18n/languages/wp-members-sk_SK.mo | Bin 16401 -> 16360 bytes i18n/languages/wp-members-sk_SK.po | 1797 +++++++++++++++------------ i18n/languages/wp-members-sr_RS.mo | Bin 15867 -> 15826 bytes i18n/languages/wp-members-sr_RS.po | 1784 ++++++++++++++++----------- i18n/languages/wp-members-tr_TR.mo | Bin 17820 -> 17779 bytes i18n/languages/wp-members-tr_TR.po | 1785 ++++++++++++++++----------- i18n/languages/wp-members.pot | 1624 +++++++++++++++---------- 25 files changed, 13455 insertions(+), 9478 deletions(-) diff --git a/i18n/languages/wp-members-ca_CA.mo b/i18n/languages/wp-members-ca_CA.mo index 07a64fa163e7758bf1eb99e959472d57dadb28a8..fdfa43082b6b26fb187c99915fd95ba32cb29470 100644 GIT binary patch delta 4111 zcmY+{2~bv5AII_k!y+yS3g$vWj~OBuh=8b=0SeeFlnY^*W>{JxVZCA&Mei+r%W`>3 z$=9W{z09oyTgWz>X|v2`Y?&OF8ndQ!%6x4b)B67IJuvg0dH(lv?zzu%?z#VS&J{mj z89Kfqx4f$Ph)4!qq_xm!#vK<#Wb9NiFlj4 zz6|NoR-^jafa-c9_B8Wshr95h^D|7~3x}}}p2Tx8w!2wZ9Ej&&KJu{&4(f0^M&lfe z!kh7YyagGvtw9ZJBVLTJVJ!Ez(^U9aNA9X0CZRey4|`!MGEy6b>fmx@Og0-Eu>oW7 zSJV@pMGdecUsihxCgA|=h{dQ3j>AOmZ&g(EgBmPG594qbYUH0FANz`fQh5sX{nM!L zb?*_Jhfz1oM}6;N)Idv78Jdi`@wM)H9eQe*?;1SR5AH>Ev>G$;QH;Rds7&oaW#%yE z<8P>bvKW;zFao#X7}S)V#6naWW1$GuerZqguP2yFLvNgeeAgDC2C~+jZ$fqa7N+5D zR7WRK1N{pJVGN^Ef4QjNkH+(`(zVwkA6v*l_gmMC{12tlLW5HDJ?cq*K@CLTiiDo1 zj+0Q=(@~koLrqZ`G6tKBTC{bj0WC)Tt_Ae~ZzCW3h=ck$>QO1BasstT^7%FQwuz|4 zQiCZt569sO%)tZLALIFv7Hcl5;}NKgOhRSoD%1nqfXYZMYM_m%e!V6t>Zln<;^(Lo zC$Q(VO$u;0HlW&@F&+2gtr*2iqk;EDBlgE%lY`79k#{Y^Y}7!8p&qORm62)48t|-^ zic;9%F5K_V*C0E|Hln6xCo1LdVHtjj%1}7W*1~ku3v2>%$?8x~xZJq~`PhdXG&RRD zL;JsXzaV8}P^m0Oe+p2ks==vv7v6*ia5`4-b}7WoI0cX4g;+{D3veE4KwD86-pwHu zf5h?F;{pcD{cR?diTEOtJ&WO6k(i3_U^=eEpHNS{kjK^HT#B00$FT!8qpr7NIlhfb zbsY0n7NT#Q%lXWKX1C)$^z_ENj0x2bEAb#-oQ9n^FCb6arzNP>I>~u8YS+xhJlueq z!hINnN1Vs73+Mks4dgFWM&n46rZ)9L@~_Hp8Z>9+$hxvxWF6XK)DNF6Dr09+i!>rL$WR9IZn7e*z$*0nLk(nmCiz$D-lsvC*o*8e`xG^hA5q(?b5^jJ z`r~HKM`N_EqcV32^&n^5dAGsA-1k9U&qrmj5cOc=Q1_YTQ7NV(wYqmw zXOZc$=%pQ7gW1nQkX zU`X)AbPRKzhhwn{<8VD{&bQzrxC1q?i8;J{uom?o@1h>;YfQkOkqzTnRBq6ahOt~I zK&5;vYVlMfW3d}i16_~0VXJH3g__HgsJZUMiqy7CL9LaM7{*HHeAEN1LjT|YgH)8F zACMhpzoTxDLK^e}8Gu@3rPvL}qf%Gx&TE~G7^ZzW>Pfeu9^ehvz8f{rV>lHf@)?}= z|8y!0-qxW8@-gx%umf0vp<%&(E<>$>m8b#iMD3b)QFH$-DuX|v2KpyzAYFNX>pU6z zVHT>N3Fr~lz=54(%~*toQ7Hyhcjcf#4ifgeI>qDfpfKKtfkwK=8UKA|Gs8PY< z>w>)OEE#)Yv1^}#eK@Zj<@WzQH1wun4JPAuOvJsYCp?1VF_M3g^rV%@EZH>FnplB) zfUTH;`;m8zMHiY4#v#bd&}Lv7-iPYvg+edb7OgaBgm0o!_61&t-{GBDUc`Lk2RIrt zis=mNkYw0icixGM{KRUJjbNLRWZFTz278X-H@E=R|2G~LjrbBKIs)r)kG_BpVo7N* z($6r3^Fz)vsJZT27MPAzoadvq*D|aK@uwTsbAFupybY@_30`zxqSji?Au4>&ZXnu9 zcPeDiFS@CU2C1Tzdq1I-{a@k9+=%O&X2d3XEz}khHxriqGS`3#FlL)<477!};659y9c{ERr#3G`S;0gVb#_>gBJHfQr!^G3Xe7$Xy z3zfTx>-`$52VWp~Bl$%W_iy5#!Kpp()az^_@fs0BJV3M+<(5qP{ok;xQ|e&4QM}ZZm$LZUweu3NJ1-+b>#p3#+LlQqHWS% zxW6qVo^5XlDq6D5gs!VRMJy$nbVBJ&%p!Op`KuDz%Rp+^5X)W561mOR#)Gt2Kdy?};9#X3U>e5YEZY$K zP}9=VEVWScA#2TQjWRbA+iJR&)#j$Twe_$`5AV*~uc-}Ugo?S}FZ(TxacXN=2bOiQqiQo@XR5M0(^Y)`wh)s1Pi6R|JOzzE!6f8UMV z(!7Pb&r#H^Ph*rZKJ%&l;d|@P7|scIunPusGNvnb!%)n?&X|XM%rw4q!%A$6%PPkihAG_RO)A-I$Vy*)DqMbu0fwpsIv!lpxXOU7aT&}=nN*{Cm4XYP$R#C%8-j* z48$&|8yBK7P=ZIX3^jF;q%jA3V+hWQBLDiq%K?pG1;*fu$Tj95sw3xY`zzFqf5g6c z3w5JNdZCW?!bFTm-LD9B{cP-sHTL*+CBGipbP#LL4WoS8S02@&m*^KI_Z!Z}@{?^;t6P#q~o4QvjQ5uaH}MQdO) zDuoTs59Ww%pG9_-X+llSHB`!PVjkW_WoW3IPGCOjMYag}$<(0+c+C1W@-eshO4R=E z(92ofS*Vnip;Ea3{ZoKSRV|j_>*&RQa5`4m7YJH~TX8ytzBVLrZ$ofxJ@d;pc=cTsbC0o&mf)bHP8KK_JS zd>-a4&qZgklJ>fOC%RLMBuf)?hm}`bvC|_F9&(rl=0JSoc^Dp>|Cprr}N0 z6!u{F%4D*2AO_RUMs;KiDx<~y$-m}yAqV7Y)ST@=)|EMhtV44db>VG$yahEiF-dl0 zsE+2KGBz3+q$xmUs0MjgnOYo+`_O;CB=WDGv~WPFi%51d5sU0B(-YN^Ow_h2LM^6B z>t;Mc`yFhHQyy_LI2|>ha@$^pS_7+Xdmk#3hkaBu!V{2_wzo-uTLQ|ZSMWA{VjT&)pYc^_*r=s5d zTTtiKqZ{|)Ncz&|jb$)^&|ff8f~nM&K28K)bTWo(*7@^Qi2uu z7=D2a&ICT{bR+|LC73)Mj`J}ekE7N=3#tPT@qX6s@u23u5H+A;R7dBaIxT;*=z`6twQvVxFd*A`6L!T2+L@>k7T`EsfEwv}WcJMGs5NmH zHGt?G=hZ$O6KQ*qjb$2;m!kPH$LG8#e&c{{6g$M(7ICN^#-mb}i={XoSKvvUfdg{+ z!-Ly!CVq<~#bk0&?JDHfrWx5Frt>f-!z1x2+N*q27Et*COYw0gI04_s0KA45^*e6C zqa&P-=Hxjk9%U^@&GkBKJr>d4hsx+5IM&6&Wge?&Pa4HPDd=mW5=dp(XlJpFLe4XD ziPoYi(kN7VIQY}4>NH{#p{@A}@dlxhtt4I}v`|}1FI&-o_d50Z$swV>6Vx{l&k&Cj z(+MqD6|FN(*+N1~Leu^Pv4>bpsH`WB5qkeXsK z`DQh7=>CJ$hY*d#DnjKT@glKJ4T|15bBITYt;GE$p2iH~C3~Ha%p_DQ9n5^(MMM&>60CoJd5-ToBAn>#KjQ3IRW+b<#8EXUxkLlOd)5CQ1GAIx z5`(pD^!MRmqKKGXf4f7RtG>Qd#|Ym6+WUypL~HR-Ibs|0aH_3$NA0W+iD5(@F@;d+ zODrdL5N{FtiNl08UNZ46q1VRK#4qICqmUw_DAo>&Q zh%#alp|ZL0X2-1oVHNXA=ew)D?h0?Y+gnqe+_)rsMD*y1Ny8SE&8(j1txOs|v$`zH zo$5)+O!A~9c~ae;jI8u@>K;$~!f{Cx%ATE9_5bH(W~HapUyJ|FmD+eZVN;v>zen_J J9Gd)g?0<;irfUEI diff --git a/i18n/languages/wp-members-ca_CA.po b/i18n/languages/wp-members-ca_CA.po index 30b44bae..7322c401 100644 --- a/i18n/languages/wp-members-ca_CA.po +++ b/i18n/languages/wp-members-ca_CA.po @@ -4,8 +4,8 @@ msgid "" msgstr "" "Project-Id-Version: WP-Members 3.2.6\n" "Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2019-04-02 08:55-0400\n" -"PO-Revision-Date: 2019-04-02 09:51-0400\n" +"POT-Creation-Date: 2020-05-22 17:48-0400\n" +"PO-Revision-Date: 2020-05-22 17:49-0400\n" "Last-Translator: \n" "Language-Team: \n" "Language: ca_CA\n" @@ -14,450 +14,685 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "X-Poedit-KeywordsList: __;_e\n" "X-Poedit-Basepath: .\n" -"X-Generator: Poedit 2.2.1\n" +"X-Generator: Poedit 2.3.1\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-SearchPath-0: /home/aure/raid/www/wordpress_31RC2_coitcv/wp-content/" "plugins/wp-members\n" -#: admin/dialogs.php:116 -msgid "" -"Your WP settings allow anyone to register - this is not the recommended " -"setting." -msgstr "" -"La seva configuració de WP permet que qualsevol persona pugui registrar-se, " -"això no és el més recomenat. " - -#: admin/dialogs.php:117 -#, php-format -msgid "" -"You can %s change this here %s making sure the box next to \"Anyone can " -"register\" is unchecked." -msgstr "" -"Pot %s canviar això aquí %s revistant la casella \"Qualsevol pot registrar-se" -"\" està demercada." - -#: admin/dialogs.php:118 -msgid "" -"This setting allows a link on the /wp-login.php page to register using the " -"WP native registration process thus circumventing any registration you are " -"using with WP-Members. In some cases, this may suit the users wants/needs, " -"but most users should uncheck this option. If you do not change this " -"setting, you can choose to ignore these warning messages under WP-Members " -"Settings." -msgstr "" -"La configuració permet un enllaç a /wp-login.php per registra-se usant el " -"procés WP i així eludir qualsevol registre que utilitzem amb WP-Members. En " -"alguns casos, pot ser útil, però la majoria de vegades aquesta opció ha " -"d'estar desactivada. Si decideix deixar la configuració aixó, pot escollir " -"ignorar els missatges d'alerta en la configuració de WP-Members." - -#: admin/dialogs.php:122 -msgid "" -"Your WP settings allow anyone to comment - this is not the recommended " -"setting." -msgstr "" -"La seva configuració de WP permet a qualsevol fer comentaris, això no és el " -"més recomenat. " - -#: admin/dialogs.php:123 -#, php-format -msgid "" -"You can %s change this here %s by checking the box next to \"Users must be " -"registered and logged in to comment.\"" -msgstr "" -"Pot %s canviar %s això marcant la casella al costat de \"Els usuaris han " -"d'estar registrats i connectats per fer comentaris.\"" - -#: admin/dialogs.php:124 -msgid "" -"This setting allows any users to comment, whether or not they are " -"registered. Depending on how you are using WP-Members will determine whether " -"you should change this setting or not. If you do not change this setting, " -"you can choose to ignore these warning messages under WP-Members Settings." -msgstr "" -"Aquesta condició permet a qualsevol usuari comentar, estigui o no registrat. " -"Depenen de com estigui usant el WP-Members haurà de canviar aquesta opció. " -"Si decideix deixar la configuració així, pot marcar \"ignorar els missatges " -"d'alerta en el panell la configuració de WP-Members." - -#: admin/dialogs.php:128 -msgid "" -"Your WP settings allow full text rss feeds - this is not the recommended " -"setting." -msgstr "" -"La teva configuració de WP permet textos complets en el canal RSS, això no " -"és el més recomenat." - -#: admin/dialogs.php:129 -#, php-format -msgid "" -"You can %s change this here %s by changing \"For each article in a feed, show" -"\" to \"Summary.\"" -msgstr "" -"Pots %s canviar això aquí %s per canviar-ho \"Per a cada article en una " -"font , mostra\" el \"Resum.\"" - -#: admin/dialogs.php:130 -msgid "" -"Leaving this set to full text allows anyone to read your protected content " -"in an RSS reader. Changing this to Summary prevents this as your feeds will " -"only show summary text." -msgstr "" -"Deixant l'opció a text complet permet a qualsevol llegir el text del seu " -"contingut protegit amb un lector de RSS. Canviar això evita aquesta " -"possibilitat." - -#: admin/dialogs.php:134 -msgid "You have set WP-Members to hold registrations for approval" -msgstr "" -"Ha configurat WP-Members perquè els nous registres estiguin retinguts fins " -"que siguin aprovats. " - -#: admin/dialogs.php:135 -msgid "" -"but you have not changed the default message for \"Registration Completed\" " -"under \"WP-Members Dialogs and Error Messages.\" You should change this " -"message to let users know they are pending approval." -msgstr "" -"però no ha canviat el missatge per defecte per \"Registre Complet\" a \"WP-" -"Members Diàlegs i Missatges d'Error.\" Heu de canviar aquest missatge perquè " -"els usuaris sàpiguen que estan pendents d'aprovació." - -#: admin/dialogs.php:139 -msgid "You have turned on reCAPTCHA" -msgstr "Ha activat reCAPTCHA, el sistema per prevenir registres falsos." - -#: admin/dialogs.php:140 -msgid "" -"but you have not entered API keys. You will need both a public and private " -"key. The CAPTCHA will not display unless a valid API key is included." -msgstr "" -"però no ha introduit les claus API. Necessitaràs una clau pública i privada. " -"El CAPTCHA no es mostrarà si no es mostra una clau API vàlida." - -#: admin/dialogs.php:144 -msgid "You have active settings that are not recommended." -msgstr "" - -#: admin/dialogs.php:145 -msgid "" -"If you will not be changing these settings, you can turn off these warning " -"messages by checking the \"Ignore warning messages\" in the settings below." -msgstr "" - -#: admin/dialogs.php:169 -msgid "Version:" -msgstr "Versió:" - -#: admin/dialogs.php:170 -msgid "Quick Start Guide" -msgstr "" - -#: admin/dialogs.php:171 -msgid "Online User Guide" -msgstr "" - -#: admin/dialogs.php:172 -msgid "FAQs" -msgstr "" - -#: admin/dialogs.php:179 -msgid "Thank you for using WP-Members" -msgstr "Gràcies per utilitzar WP-Members" - -#: admin/dialogs.php:180 -msgid "A plugin developed by" -msgstr "" - -#: admin/dialogs.php:181 -msgid "Follow" -msgstr "Continuar:" - -#: admin/dialogs.php:198 admin/dialogs.php:202 -msgid "Latest from RocketGeek" -msgstr "" - -#: admin/dialogs.php:219 -msgid "Like WP-Members?" -msgstr "" - -#: admin/dialogs.php:220 -#, php-format -msgid "" -"If you like WP-Members please give it a %s★★★★★" -"%s rating. Thanks!!" -msgstr "" - -#: admin/dialogs.php:231 admin/dialogs.php:244 -msgid "Latest from ButlerBlog" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:256 +#: includes/admin/class-wp-members-admin-api.php:292 msgid "Custom email" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:257 -#: admin/includes/class-wp-members-admin-api.php:259 +#: includes/admin/class-wp-members-admin-api.php:293 +#: includes/admin/class-wp-members-admin-api.php:295 msgid "Subject" msgstr "Assumpte" -#: admin/includes/class-wp-members-admin-api.php:260 +#: includes/admin/class-wp-members-admin-api.php:296 msgid "Body" msgstr "Cos" -#: admin/includes/class-wp-members-admin-api.php:262 +#: includes/admin/class-wp-members-admin-api.php:298 msgid "Your custom email message content." msgstr "" -#: admin/includes/class-wp-members-admin-api.php:340 +#: includes/admin/class-wp-members-admin-api.php:376 msgid "Options" msgstr "Opcions" -#: admin/includes/class-wp-members-admin-api.php:341 +#: includes/admin/class-wp-members-admin-api.php:377 msgid "Fields" msgstr "Camps" -#: admin/includes/class-wp-members-admin-api.php:342 +#: includes/admin/class-wp-members-admin-api.php:378 msgid "Dialogs" msgstr "Diàlegs" -#: admin/includes/class-wp-members-admin-api.php:343 +#: includes/admin/class-wp-members-admin-api.php:379 msgid "Emails" msgstr "Emails" -#: admin/includes/class-wp-members-admin-api.php:359 +#: includes/admin/class-wp-members-admin-api.php:395 msgid "New Registration" msgstr "Nou registre" -#: admin/includes/class-wp-members-admin-api.php:368 +#: includes/admin/class-wp-members-admin-api.php:404 msgid "Registration is Moderated" msgstr "Registre complet" -#: admin/includes/class-wp-members-admin-api.php:374 +#: includes/admin/class-wp-members-admin-api.php:410 msgid "Registration is Moderated, User is Approved" msgstr "El seu registre ha estat aprovat" -#: admin/includes/class-wp-members-admin-api.php:382 +#: includes/admin/class-wp-members-admin-api.php:418 msgid "Password Reset" msgstr "Contrasenya reiniciada" -#: admin/includes/class-wp-members-admin-api.php:389 +#: includes/admin/class-wp-members-admin-api.php:425 msgid "Retrieve Username" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:397 +#: includes/admin/class-wp-members-admin-api.php:433 msgid "Admin Notification" msgstr "Notificació de l'administrador" -#: admin/includes/class-wp-members-admin-api.php:423 +#: includes/admin/class-wp-members-admin-api.php:459 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Les entrades (o pàgines) bloquejades mostren sempre el formulari " "d'identificació/registre" -#: admin/includes/class-wp-members-admin-api.php:424 +#: includes/admin/class-wp-members-admin-api.php:460 msgid "Username is taken" msgstr "El nom d'usuari ja està en ús" -#: admin/includes/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:461 msgid "Email is registered" msgstr "L'email ja està registrat" -#: admin/includes/class-wp-members-admin-api.php:426 +#: includes/admin/class-wp-members-admin-api.php:462 msgid "Registration completed" msgstr "Registre complet" -#: admin/includes/class-wp-members-admin-api.php:427 +#: includes/admin/class-wp-members-admin-api.php:463 msgid "User update" msgstr "Actualitza l'usuari" -#: admin/includes/class-wp-members-admin-api.php:428 +#: includes/admin/class-wp-members-admin-api.php:464 msgid "Passwords did not match" msgstr "Les contrasenyes no coincideixen" -#: admin/includes/class-wp-members-admin-api.php:429 +#: includes/admin/class-wp-members-admin-api.php:465 msgid "Password changes" msgstr "Canvi de contrasenya" -#: admin/includes/class-wp-members-admin-api.php:430 +#: includes/admin/class-wp-members-admin-api.php:466 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "L'usuari o email no existeixen quan intentem restablir la contrasenya " "oblidada " -#: admin/includes/class-wp-members-admin-api.php:431 +#: includes/admin/class-wp-members-admin-api.php:467 msgid "Password reset" msgstr "Contrasenya restablerta" -#: admin/includes/class-wp-members-admin-api.php:564 +#: includes/admin/class-wp-members-admin-api.php:623 msgid "Settings" msgstr "Preferències" -#: admin/includes/class-wp-members-products-admin.php:57 -msgid "Slug" +#: includes/admin/class-wp-members-admin-posts.php:30 +#: includes/admin/class-wp-members-admin-posts.php:33 +msgid "Unblock" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:58 -msgid "Role" +#: includes/admin/class-wp-members-admin-posts.php:31 +#: includes/admin/class-wp-members-admin-posts.php:34 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 +msgid "Block" +msgstr "Bloquejar" + +#: includes/admin/class-wp-members-admin-posts.php:32 +#: includes/admin/class-wp-members-admin-posts.php:35 +msgid "Hide" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s blocked" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:59 -#: admin/includes/class-wp-members-products-admin.php:162 -#: admin/tab-fields.php:459 admin/user-export.php:69 +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:165 +#, php-format +msgid "%s Restriction" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:195 +msgid "Unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:196 +msgid "Blocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:197 +msgid "Hidden" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +msgid "Status:" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:68 +#: includes/admin/tabs/class-wp-members-fields-table.php:65 +#: includes/walkers/class-wp-members-walker-nav-menu.php:140 +msgid "Edit" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:218 +msgid "Ok" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:219 +#: includes/walkers/class-wp-members-walker-nav-menu.php:224 +msgid "Cancel" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:305 +#: includes/admin/class-wp-members-products-admin.php:629 +msgid "Status" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:28 +#: includes/admin/class-wp-members-admin-users.php:33 +#: includes/admin/class-wp-members-admin-users.php:59 +msgid "Activate" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:29 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:62 +msgid "Deactivate" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:31 +#: includes/admin/class-wp-members-admin-users.php:36 +msgid "Export" +msgstr "Exportar" + +#: includes/admin/class-wp-members-admin-users.php:37 +#: includes/admin/class-wp-members-admin-users.php:88 +msgid "Export All Users" +msgstr "Exportar tots els usuaris" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:129 +msgid "No users selected" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 +msgid "You cannot activate or deactivate yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:152 +#, php-format +msgid "%s activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:157 +#, php-format +msgid "%s deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:161 +msgid "That user is already active" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:288 +msgid "Pending" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:289 +msgid "Trial" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:290 +#: includes/admin/class-wp-members-export.php:74 +msgid "Subscription" +msgstr "Subscripció" + +#: includes/admin/class-wp-members-admin-users.php:291 +msgid "Expired" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:294 +msgid "Activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:295 +msgid "Pending Activation" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:296 +msgid "Deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:298 +msgid "Not Exported" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:387 +#: includes/admin/class-wp-members-export.php:160 +msgid "No" +msgstr "" + +#: includes/admin/class-wp-members-export.php:64 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-export.php:65 +#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 +msgid "Username" +msgstr "" + +#: includes/admin/class-wp-members-export.php:71 +msgid "Activated?" +msgstr "Activa?" + +#: includes/admin/class-wp-members-export.php:75 +#: includes/admin/class-wp-members-products-admin.php:64 +#: includes/admin/class-wp-members-products-admin.php:632 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 msgid "Expires" msgstr "Expira" -#: admin/includes/class-wp-members-products-admin.php:60 +#: includes/admin/class-wp-members-export.php:77 +msgid "Registered" +msgstr "Registrat" + +#: includes/admin/class-wp-members-export.php:78 +msgid "IP" +msgstr "IP" + +#: includes/admin/class-wp-members-export.php:160 +#: includes/admin/class-wp-members-products-admin.php:104 +msgid "Yes" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:62 +msgid "Slug" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:63 +msgid "Role" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:66 +msgid "Default" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:68 msgid "Last updated" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:80 +#: includes/admin/class-wp-members-products-admin.php:92 +msgid "slug:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:95 msgid "No role required" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:84 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "Does not expire" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:120 +#: includes/admin/class-wp-members-products-admin.php:140 msgid "Membership Product Details" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 -#: admin/includes/class-wp-members-products-admin.php:167 +#: includes/admin/class-wp-members-products-admin.php:148 +msgid "Membership Product Message (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 +msgid "Posts" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +msgid "Pages" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:235 +#: includes/admin/class-wp-members-products-admin.php:280 msgid "Period" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Day" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Week" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Month" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Year" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:199 msgid "Name (slug)" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:153 -msgid "Role Required?" +#: includes/admin/class-wp-members-products-admin.php:201 +msgid "Optional Defaults" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:204 +msgid "Assign as default at registration? (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:212 +#, php-format +msgid "Pre-selected by default for new %s" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:218 +msgid "Optional Properties" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:156 +#: includes/admin/class-wp-members-products-admin.php:221 +msgid "Role Required? (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:224 msgid "No Role" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:164 -#: admin/includes/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:230 +msgid "Expires (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:232 +#: includes/admin/class-wp-members-products-admin.php:234 +#: includes/admin/class-wp-members-products-admin.php:277 +#: includes/admin/class-wp-members-products-admin.php:279 msgid "Number" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:245 -#: admin/tab-options.php:207 inc/class-wp-members-forms.php:999 -#: inc/class-wp-members-user-profile.php:106 inc/deprecated.php:360 -#: inc/deprecated.php:622 +#: includes/admin/class-wp-members-products-admin.php:240 +msgid "Use \"no gap\" renewal" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:244 +msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:261 +msgid "Period Start (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:262 +msgid "Period End (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:275 +msgid "Fixed period grace period" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:284 +msgid "" +"Grace period is the point at which expiration date is for following time " +"period. For example, if user who register August 1st would be part of the " +"following year's Sept 1 - Aug 31 membership, set this at 1 Month. Leave " +"blank for no grace period." +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:333 +msgid "" +"Restricted Message (displays when a user does not have access to a " +"membership)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:435 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 +#: includes/class-wp-members-forms.php:1092 +#: includes/class-wp-members-user-profile.php:112 msgid "None" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:251 +#: includes/admin/class-wp-members-products-admin.php:450 msgid "Limit access to:" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:321 +#: includes/admin/class-wp-members-products-admin.php:520 msgid "Required Membership" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:360 +#: includes/admin/class-wp-members-products-admin.php:559 +#: includes/admin/class-wp-members-products-admin.php:630 msgid "Membership" msgstr "" -#: admin/post.php:45 admin/post.php:48 -msgid "Unblock" +#: includes/admin/class-wp-members-products-admin.php:599 +#: includes/class-wp-members-products.php:308 +msgid "Memberships" msgstr "" -#: admin/post.php:46 admin/post.php:49 admin/tab-options.php:114 -msgid "Block" -msgstr "Bloquejar" +#: includes/admin/class-wp-members-products-admin.php:626 +msgid "Product Access" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:631 +msgid "Enabled?" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:641 +msgid "Enable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:642 +msgid "Disable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:647 +msgid "Expiration date (optional)" +msgstr "" + +#: includes/admin/dialogs.php:117 +msgid "" +"Your WP settings allow anyone to register - this is not the recommended " +"setting." +msgstr "" +"La seva configuració de WP permet que qualsevol persona pugui registrar-se, " +"això no és el més recomenat. " + +#: includes/admin/dialogs.php:118 +#, php-format +msgid "" +"You can %s change this here %s making sure the box next to \"Anyone can " +"register\" is unchecked." +msgstr "" +"Pot %s canviar això aquí %s revistant la casella \"Qualsevol pot registrar-se" +"\" està demercada." + +#: includes/admin/dialogs.php:119 +msgid "" +"This setting allows a link on the /wp-login.php page to register using the " +"WP native registration process thus circumventing any registration you are " +"using with WP-Members. In some cases, this may suit the users wants/needs, " +"but most users should uncheck this option. If you do not change this " +"setting, you can choose to ignore these warning messages under WP-Members " +"Settings." +msgstr "" +"La configuració permet un enllaç a /wp-login.php per registra-se usant el " +"procés WP i així eludir qualsevol registre que utilitzem amb WP-Members. En " +"alguns casos, pot ser útil, però la majoria de vegades aquesta opció ha " +"d'estar desactivada. Si decideix deixar la configuració aixó, pot escollir " +"ignorar els missatges d'alerta en la configuració de WP-Members." + +#: includes/admin/dialogs.php:123 +msgid "" +"Your WP settings allow anyone to comment - this is not the recommended " +"setting." +msgstr "" +"La seva configuració de WP permet a qualsevol fer comentaris, això no és el " +"més recomenat. " + +#: includes/admin/dialogs.php:124 +#, php-format +msgid "" +"You can %s change this here %s by checking the box next to \"Users must be " +"registered and logged in to comment.\"" +msgstr "" +"Pot %s canviar %s això marcant la casella al costat de \"Els usuaris han " +"d'estar registrats i connectats per fer comentaris.\"" + +#: includes/admin/dialogs.php:125 +msgid "" +"This setting allows any users to comment, whether or not they are " +"registered. Depending on how you are using WP-Members will determine whether " +"you should change this setting or not. If you do not change this setting, " +"you can choose to ignore these warning messages under WP-Members Settings." +msgstr "" +"Aquesta condició permet a qualsevol usuari comentar, estigui o no registrat. " +"Depenen de com estigui usant el WP-Members haurà de canviar aquesta opció. " +"Si decideix deixar la configuració així, pot marcar \"ignorar els missatges " +"d'alerta en el panell la configuració de WP-Members." + +#: includes/admin/dialogs.php:129 +msgid "" +"Your WP settings allow full text rss feeds - this is not the recommended " +"setting." +msgstr "" +"La teva configuració de WP permet textos complets en el canal RSS, això no " +"és el més recomenat." + +#: includes/admin/dialogs.php:130 +#, php-format +msgid "" +"You can %s change this here %s by changing \"For each article in a feed, show" +"\" to \"Summary.\"" +msgstr "" +"Pots %s canviar això aquí %s per canviar-ho \"Per a cada article en una " +"font , mostra\" el \"Resum.\"" + +#: includes/admin/dialogs.php:131 +msgid "" +"Leaving this set to full text allows anyone to read your protected content " +"in an RSS reader. Changing this to Summary prevents this as your feeds will " +"only show summary text." +msgstr "" +"Deixant l'opció a text complet permet a qualsevol llegir el text del seu " +"contingut protegit amb un lector de RSS. Canviar això evita aquesta " +"possibilitat." + +#: includes/admin/dialogs.php:135 +msgid "You have set WP-Members to hold registrations for approval" +msgstr "" +"Ha configurat WP-Members perquè els nous registres estiguin retinguts fins " +"que siguin aprovats. " + +#: includes/admin/dialogs.php:136 +msgid "" +"but you have not changed the default message for \"Registration Completed\" " +"under \"WP-Members Dialogs and Error Messages.\" You should change this " +"message to let users know they are pending approval." +msgstr "" +"però no ha canviat el missatge per defecte per \"Registre Complet\" a \"WP-" +"Members Diàlegs i Missatges d'Error.\" Heu de canviar aquest missatge perquè " +"els usuaris sàpiguen que estan pendents d'aprovació." + +#: includes/admin/dialogs.php:140 +msgid "You have turned on reCAPTCHA" +msgstr "Ha activat reCAPTCHA, el sistema per prevenir registres falsos." -#: admin/post.php:47 admin/post.php:50 -msgid "Hide" +#: includes/admin/dialogs.php:141 +msgid "" +"but you have not entered API keys. You will need both a public and private " +"key. The CAPTCHA will not display unless a valid API key is included." msgstr "" +"però no ha introduit les claus API. Necessitaràs una clau pública i privada. " +"El CAPTCHA no es mostrarà si no es mostra una clau API vàlida." -#: admin/post.php:138 -#, php-format -msgid "%s blocked" +#: includes/admin/dialogs.php:145 +msgid "You have active settings that are not recommended." msgstr "" -#: admin/post.php:138 -#, php-format -msgid "%s unblocked" +#: includes/admin/dialogs.php:146 +msgid "" +"If you will not be changing these settings, you can turn off these warning " +"messages by checking the \"Ignore warning messages\" in the settings below." msgstr "" -#: admin/post.php:177 -#, php-format -msgid "%s Restriction" -msgstr "" +#: includes/admin/dialogs.php:174 +msgid "Version:" +msgstr "Versió:" -#: admin/post.php:206 -msgid "Unblocked" +#: includes/admin/dialogs.php:175 +msgid "Quick Start Guide" msgstr "" -#: admin/post.php:207 -msgid "Blocked" +#: includes/admin/dialogs.php:176 +msgid "Online User Guide" msgstr "" -#: admin/post.php:208 -msgid "Hidden" +#: includes/admin/dialogs.php:177 +msgid "FAQs" msgstr "" -#: admin/post.php:214 -msgid "Status:" -msgstr "" +#: includes/admin/dialogs.php:184 +msgid "Thank you for using WP-Members" +msgstr "Gràcies per utilitzar WP-Members" -#: admin/post.php:214 admin/tab-fields.php:88 admin/tab-fields.php:554 -msgid "Edit" +#: includes/admin/dialogs.php:185 +msgid "A plugin developed by" msgstr "" -#: admin/post.php:229 -msgid "Ok" +#: includes/admin/dialogs.php:186 +msgid "Follow" +msgstr "Continuar:" + +#: includes/admin/dialogs.php:203 includes/admin/dialogs.php:207 +msgid "Latest from RocketGeek" msgstr "" -#: admin/post.php:230 -msgid "Cancel" +#: includes/admin/dialogs.php:224 +msgid "Like WP-Members?" msgstr "" -#: admin/post.php:314 -msgid "Status" +#: includes/admin/dialogs.php:225 +#, php-format +msgid "" +"If you like WP-Members please give it a %s★★★★★" +"%s rating. Thanks!!" msgstr "" -#: admin/tab-about.php:34 admin/tab-about.php:54 -msgid "About WP-Members" +#: includes/admin/dialogs.php:236 includes/admin/dialogs.php:249 +msgid "Latest from ButlerBlog" msgstr "" -#: admin/tab-captcha.php:66 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:67 #, php-format msgid "See the %sUsers Guide on CAPTCHA%s." msgstr "" -#: admin/tab-captcha.php:73 admin/tab-dialogs.php:57 admin/tab-emails.php:101 -#: admin/tab-fields.php:153 admin/tab-options.php:82 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" -#: admin/tab-captcha.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 msgid "Manage reCAPTCHA Options" msgstr "Gestionar les opcions de reCAPTCHA" -#: admin/tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 msgid "" "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " "while blocking spam on your blog." @@ -465,7 +700,7 @@ msgstr "" "reCAPTCHA és un servei gratuit i accessible que ajuda als registres digitals " "mentre bloqueja el spam del seu blog." -#: admin/tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 #, php-format msgid "" "reCAPTCHA asks commenters to retype two words scanned from a book to prove " @@ -480,11 +715,12 @@ msgstr "" "exactitud en els registres. Tothom hi guanya! Per a més informació, visiteu " "el %s lloc web de reCAPTCHA %s" -#: admin/tab-captcha.php:104 admin/tab-captcha.php:130 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 msgid "reCAPTCHA Keys" msgstr "Claus de reCAPTCHA" -#: admin/tab-captcha.php:106 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " @@ -493,108 +729,108 @@ msgstr "" "reCAPTCHA requereix una clau d'encriptació pública y privada. Pot apuntar-se " "per %s per aconseguir claus gratuïtes%s." -#: admin/tab-captcha.php:107 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 msgid "Public Key" msgstr "Clau pública" -#: admin/tab-captcha.php:108 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 msgid "Private Key" msgstr "Clau privada" -#: admin/tab-captcha.php:112 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 msgid "Choose Theme" msgstr "Escull el tema" -#: admin/tab-captcha.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 msgid "Red" msgstr "Vermell" -#: admin/tab-captcha.php:116 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 msgid "White" msgstr "Blanc" -#: admin/tab-captcha.php:117 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 msgid "Black Glass" msgstr "Negre cristall" -#: admin/tab-captcha.php:118 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 msgid "Clean" msgstr "Clar" -#: admin/tab-captcha.php:132 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 msgid "Site Key" msgstr "" -#: admin/tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 msgid "Secret Key" msgstr "" -#: admin/tab-captcha.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 msgid "Characters for image" msgstr "" -#: admin/tab-captcha.php:169 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 msgid "Number of characters" msgstr "" -#: admin/tab-captcha.php:173 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 msgid "Image dimensions" msgstr "" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Width" msgstr "" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Height" msgstr "" -#: admin/tab-captcha.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Font color of characters" msgstr "" -#: admin/tab-captcha.php:181 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Background color of image" msgstr "" -#: admin/tab-captcha.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Font size" msgstr "" -#: admin/tab-captcha.php:189 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Width between characters" msgstr "" -#: admin/tab-captcha.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Image type" msgstr "Tipus d'Imatge" -#: admin/tab-captcha.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: admin/tab-captcha.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 msgid "Update CAPTCHA Settings" msgstr "Actualizar configuració de CAPTCHA" -#: admin/tab-captcha.php:301 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 msgid "CAPTCHA was updated for WP-Members" msgstr "CAPTCHA s'ha actualitzat per WP-Members" -#: admin/tab-dialogs.php:67 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:67 msgid "Dialogs and Error Messages" msgstr "Diàlegs i missatges d'error" -#: admin/tab-dialogs.php:69 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:69 #, php-format msgid "" "You can customize the text for dialogs and error messages. Simple HTML is " @@ -603,375 +839,339 @@ msgstr "" "Pot personalitzar els textes pels diàlegs i els missatges d'error. Es permet " "HTML simple %s etc." -#: admin/tab-dialogs.php:80 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:80 msgid "Terms of Service (TOS)" msgstr "Condicions d'ús" -#: admin/tab-dialogs.php:87 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:87 msgid "Update Dialogs" msgstr "Actualitza els diàlegs" -#: admin/tab-dialogs.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:124 msgid "WP-Members dialogs were updated" msgstr "Els diàlegs de WP-Members s'han actualitzat" -#: admin/tab-dropins.php:78 admin/tab-dropins.php:378 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:88 +#: includes/admin/tabs/class-wp-members-dropins-table.php:180 msgid "WP-Members Dropin settings were updated" msgstr "" -#: admin/tab-dropins.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:216 msgid "Manage Dropins" msgstr "" -#: admin/tab-dropins.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:217 msgid "Current dropin folder: " msgstr "" -#: admin/tab-dropins.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:218 msgid "" "You can change location of the dropin folder using the " "wpmem_dropin_folder filter." msgstr "" -#: admin/tab-dropins.php:269 -msgid "Name" -msgstr "" - -#: admin/tab-dropins.php:270 -msgid "File" -msgstr "" - -#: admin/tab-dropins.php:271 -msgid "Version" -msgstr "" - -#: admin/tab-dropins.php:272 -msgid "Description" -msgstr "" - -#: admin/tab-dropins.php:315 admin/tab-fields.php:597 -msgid "Save Settings" -msgstr "" - -#: admin/tab-emails.php:58 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:57 msgid "Email Messages" msgstr "Missatges d'email" -#: admin/tab-emails.php:61 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:60 msgid "You can customize the content of the emails sent by the plugin." msgstr "Pots personalitzar el contingut dels emails enviats per el plugin." -#: admin/tab-emails.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:62 msgid "A list of shortcodes is available here." msgstr "En aquesta pàgina podeu trobar una llista de codis." -#: admin/tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:69 msgid "Set a custom email address" msgstr "Configureu una adreça de correu electrònic personalitzada" -#: admin/tab-emails.php:71 admin/tab-emails.php:75 admin/tab-emails.php:85 -#: admin/tab-fields.php:179 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 msgid "(optional)" msgstr "(opcional)" -#: admin/tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:73 msgid "Set a custom email name" msgstr "Establiu un nom de correu electrònic personalitzat" -#: admin/tab-emails.php:85 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 msgid "Email Signature" msgstr "Signatura email" -#: admin/tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 msgid "Update Emails" msgstr "Actualizar emails" -#: admin/tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 msgid "WP-Members emails were updated" msgstr "Els emails de WP-Members s'han actualitzat" -#: admin/tab-fields.php:113 inc/class-wp-members.php:1207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 +#: includes/class-wp-members.php:1498 msgid "No fields selected for deletion" msgstr "" -#: admin/tab-fields.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:95 msgid "Are you sure you want to delete the following fields?" msgstr "" -#: admin/tab-fields.php:141 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:122 msgid "Fields deleted" msgstr "" -#: admin/tab-fields.php:155 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:136 msgid "Field Manager Documentation" msgstr "" -#: admin/tab-fields.php:180 admin/tab-fields.php:322 -#: inc/class-wp-members-user-profile.php:138 inc/deprecated.php:385 -#: inc/deprecated.php:646 inc/wp-registration.php:57 -#: inc/wp-registration.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/class-wp-members-forms.php:1626 +#: includes/class-wp-members-forms.php:1803 +#: includes/class-wp-members-user-profile.php:144 msgid "(required)" msgstr "(requerit)" -#: admin/tab-fields.php:185 admin/tab-fields.php:407 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 msgid "Edit Field" msgstr "Edita Camp" -#: admin/tab-fields.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 msgid "Add a Field" msgstr "Afegir un camp" -#: admin/tab-fields.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 msgid "Field Label" msgstr "Etiqueta del camp" -#: admin/tab-fields.php:192 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: admin/tab-fields.php:195 admin/tab-fields.php:547 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: admin/tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: admin/tab-fields.php:205 admin/tab-fields.php:548 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Tipus de camp" -#: admin/tab-fields.php:211 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 msgid "text" msgstr "text" -#: admin/tab-fields.php:212 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 msgid "email" msgstr "" -#: admin/tab-fields.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "textarea" msgstr "àrea de text" -#: admin/tab-fields.php:214 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "checkbox" msgstr "checkbox" -#: admin/tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "multiple checkbox" msgstr "" -#: admin/tab-fields.php:216 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "select (dropdown)" msgstr "" -#: admin/tab-fields.php:217 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple select" msgstr "" -#: admin/tab-fields.php:218 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "radio group" msgstr "" -#: admin/tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "password" msgstr "Contrasenya " -#: admin/tab-fields.php:220 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "image" msgstr "" -#: admin/tab-fields.php:221 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "file" msgstr "" -#: admin/tab-fields.php:222 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "url" msgstr "" -#: admin/tab-fields.php:223 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "number" msgstr "" -#: admin/tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "date" msgstr "" -#: admin/tab-fields.php:225 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "hidden" msgstr "" -#: admin/tab-fields.php:227 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "membership" msgstr "" -#: admin/tab-fields.php:233 admin/tab-fields.php:549 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Mostrar?" -#: admin/tab-fields.php:237 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 msgid "This field is always displayed" msgstr "" -#: admin/tab-fields.php:242 admin/tab-fields.php:550 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 msgid "Required?" msgstr "Obligatori?" -#: admin/tab-fields.php:246 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 msgid "This field is always required" msgstr "" -#: admin/tab-fields.php:252 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 msgid "Allow HTML?" msgstr "" -#: admin/tab-fields.php:259 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 msgid "Placeholder" msgstr "" -#: admin/tab-fields.php:267 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 msgid "Pattern" msgstr "" -#: admin/tab-fields.php:273 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 msgid "Title" msgstr "" -#: admin/tab-fields.php:282 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 msgid "Minimum Value" msgstr "" -#: admin/tab-fields.php:286 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Maximum Value" msgstr "" -#: admin/tab-fields.php:294 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 msgid "Rows" msgstr "" -#: admin/tab-fields.php:298 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Columns" msgstr "" -#: admin/tab-fields.php:306 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 msgid "Accepted file types:" msgstr "" -#: admin/tab-fields.php:311 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: admin/tab-fields.php:318 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 msgid "Checked by default?" msgstr "Marcada per defecte?" -#: admin/tab-fields.php:322 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 msgid "Stored value if checked:" msgstr "Valor emmagatzemat si s'activa:" -#: admin/tab-fields.php:343 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 msgid "Stored values delimiter:" msgstr "" -#: admin/tab-fields.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 msgid "Values (Displayed|Stored):" msgstr "" -#: admin/tab-fields.php:377 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 msgid "Options should be Option Name|option_value," msgstr "Les opcions han de ser Option Name|option_value," -#: admin/tab-fields.php:381 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 msgid "Visit plugin site for more information" msgstr "Per a més informació visita la pàgina del plugin " -#: admin/tab-fields.php:388 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Value" msgstr "" -#: admin/tab-fields.php:407 admin/tab-fields.php:674 admin/tab-fields.php:675 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 msgid "Add Field" msgstr "afegir camp" -#: admin/tab-fields.php:409 admin/tab-fields.php:868 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 msgid "Return to Fields Table" msgstr "" -#: admin/tab-fields.php:449 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 msgid "Drag and drop to reorder fields" msgstr "" -#: admin/tab-fields.php:455 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 msgid "Registration Date" msgstr "Data de Registre" -#: admin/tab-fields.php:456 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 msgid "Active" msgstr "Activar" -#: admin/tab-fields.php:457 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 msgid "Registration IP" msgstr "Adreça IP" -#: admin/tab-fields.php:458 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 msgid "Subscription Type" msgstr "" -#: admin/tab-fields.php:460 admin/user-export.php:58 -msgid "User ID" -msgstr "" - -#: admin/tab-fields.php:493 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 msgid "Manage Fields" msgstr "Gestionar camps" -#: admin/tab-fields.php:532 -msgid "delete" -msgstr "" - -#: admin/tab-fields.php:546 -msgid "Display Label" -msgstr "" - -#: admin/tab-fields.php:552 -msgid "Users Screen" -msgstr "" - -#: admin/tab-fields.php:553 -msgid "Users Search" -msgstr "" - -#: admin/tab-fields.php:555 -msgid "Sort" -msgstr "" - -#: admin/tab-fields.php:596 -msgid "Delete Selected" -msgstr "" - -#: admin/tab-fields.php:738 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 msgid "WP-Members fields were updated" msgstr "Els camps dels WP-Members s'han actualitzat" -#: admin/tab-fields.php:760 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 msgid "Field Label is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:761 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:763 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: admin/tab-fields.php:770 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 msgid "A field with that meta key already exists" msgstr "" -#: admin/tab-fields.php:775 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 #, php-format msgid "" "Sorry, \"%s\" is a
    : User has not been activated." msgstr "ERROR: L'usuari no ha estat activat." -#: inc/class-wp-members-widget.php:24 +#: includes/class-wp-members-widget.php:24 msgid "Displays the WP-Members sidebar login." msgstr "" -#: inc/class-wp-members-widget.php:39 inc/class-wp-members-widget.php:82 +#: includes/class-wp-members-widget.php:39 +#: includes/class-wp-members-widget.php:82 msgid "Login Status" msgstr "Estat de la identificació" -#: inc/class-wp-members-widget.php:46 +#: includes/class-wp-members-widget.php:46 msgid "Title:" msgstr "Titol:" -#: inc/class-wp-members-widget.php:50 +#: includes/class-wp-members-widget.php:50 msgid "Redirect to (optional):" msgstr "" -#: inc/class-wp-members.php:1183 +#: includes/class-wp-members.php:1028 includes/class-wp-members.php:1038 +msgid "You must be logged in to view this content." +msgstr "" + +#: includes/class-wp-members.php:1044 +msgid "The page you are looking for does not exist" +msgstr "" + +#: includes/class-wp-members.php:1436 +#, php-format +msgid "" +"You have a linked page in the WP-Members page settings that corresponds to a " +"post ID that no longer exists. Please %s review and update the %s page " +"settings %s." +msgstr "" + +#: includes/class-wp-members.php:1474 msgid "First Name" msgstr "Nom" -#: inc/class-wp-members.php:1184 +#: includes/class-wp-members.php:1475 msgid "Last Name" msgstr "Cognoms" -#: inc/class-wp-members.php:1185 +#: includes/class-wp-members.php:1476 msgid "Address 1" msgstr "Adreça (línia 1)" -#: inc/class-wp-members.php:1186 +#: includes/class-wp-members.php:1477 msgid "Address 2" msgstr "Adreça (línia 2)" -#: inc/class-wp-members.php:1187 +#: includes/class-wp-members.php:1478 msgid "City" msgstr "Ciutat" -#: inc/class-wp-members.php:1188 +#: includes/class-wp-members.php:1479 msgid "State" msgstr "Província" -#: inc/class-wp-members.php:1189 +#: includes/class-wp-members.php:1480 msgid "Zip" msgstr "CP" -#: inc/class-wp-members.php:1190 +#: includes/class-wp-members.php:1481 msgid "Country" msgstr "País" -#: inc/class-wp-members.php:1191 +#: includes/class-wp-members.php:1482 msgid "Day Phone" msgstr "Telèfon" -#: inc/class-wp-members.php:1192 inc/class-wp-members.php:1233 +#: includes/class-wp-members.php:1483 includes/class-wp-members.php:1524 msgid "Email" msgstr "" -#: inc/class-wp-members.php:1193 +#: includes/class-wp-members.php:1484 msgid "Confirm Email" msgstr "" -#: inc/class-wp-members.php:1194 +#: includes/class-wp-members.php:1485 msgid "Website" msgstr "Lloc web" -#: inc/class-wp-members.php:1195 +#: includes/class-wp-members.php:1486 msgid "Biographical Info" msgstr "Informació biogràfica" -#: inc/class-wp-members.php:1196 inc/class-wp-members.php:1216 -#: inc/class-wp-members.php:1295 +#: includes/class-wp-members.php:1487 includes/class-wp-members.php:1507 +#: includes/class-wp-members.php:1587 msgid "Password" msgstr "" -#: inc/class-wp-members.php:1197 +#: includes/class-wp-members.php:1488 msgid "Confirm Password" msgstr "" -#: inc/class-wp-members.php:1208 +#: includes/class-wp-members.php:1499 msgid "You are not logged in." msgstr "No ha entrat en" -#: inc/class-wp-members.php:1214 +#: includes/class-wp-members.php:1505 msgid "Existing Users Log In" msgstr "Usuaris Existents Entrada" -#: inc/class-wp-members.php:1215 inc/class-wp-members.php:1294 +#: includes/class-wp-members.php:1506 includes/class-wp-members.php:1586 msgid "Username or Email" msgstr "" -#: inc/class-wp-members.php:1218 +#: includes/class-wp-members.php:1509 msgid "Remember Me" msgstr "" -#: inc/class-wp-members.php:1219 +#: includes/class-wp-members.php:1510 msgid "Forgot password?" msgstr "Has oblidat la contrasenya?" -#: inc/class-wp-members.php:1220 +#: includes/class-wp-members.php:1511 msgid "Click here to reset" msgstr "Prem aquí per reiniciar" -#: inc/class-wp-members.php:1221 +#: includes/class-wp-members.php:1512 msgid "New User?" msgstr "Nou usuari?" -#: inc/class-wp-members.php:1222 +#: includes/class-wp-members.php:1513 msgid "Click here to register" msgstr "Prem aquí per registrar-te" -#: inc/class-wp-members.php:1225 inc/class-wp-members.php:1279 +#: includes/class-wp-members.php:1516 includes/class-wp-members.php:1571 msgid "Change Password" msgstr "Canvia la contrasenya" -#: inc/class-wp-members.php:1226 +#: includes/class-wp-members.php:1517 msgid "New password" msgstr "" -#: inc/class-wp-members.php:1227 +#: includes/class-wp-members.php:1518 msgid "Confirm new password" msgstr "" -#: inc/class-wp-members.php:1228 +#: includes/class-wp-members.php:1519 msgid "Update Password" msgstr "Actualitza la contrasenya" -#: inc/class-wp-members.php:1231 +#: includes/class-wp-members.php:1522 msgid "Reset Forgotten Password" msgstr "Reinicia la contrasenya oblidada" -#: inc/class-wp-members.php:1234 +#: includes/class-wp-members.php:1525 msgid "Reset Password" msgstr "" -#: inc/class-wp-members.php:1235 +#: includes/class-wp-members.php:1526 msgid "Forgot username?" msgstr "" -#: inc/class-wp-members.php:1236 +#: includes/class-wp-members.php:1527 msgid "Click here" msgstr "" -#: inc/class-wp-members.php:1239 inc/class-wp-members.php:1241 +#: includes/class-wp-members.php:1530 includes/class-wp-members.php:1532 msgid "Retrieve username" msgstr "" -#: inc/class-wp-members.php:1240 +#: includes/class-wp-members.php:1531 msgid "Email Address" msgstr "" -#: inc/class-wp-members.php:1244 +#: includes/class-wp-members.php:1535 msgid "New User Registration" msgstr "Registre d'un nou usuari" -#: inc/class-wp-members.php:1245 +#: includes/class-wp-members.php:1536 msgid "Choose a Username" msgstr "Escull un nom d'usuari" -#: inc/class-wp-members.php:1246 +#: includes/class-wp-members.php:1537 msgid "Input the code:" msgstr "" -#: inc/class-wp-members.php:1248 +#: includes/class-wp-members.php:1539 msgid "Reset Form" msgstr "Restablir el Formulari" -#: inc/class-wp-members.php:1251 +#: includes/class-wp-members.php:1542 msgid "Required field" msgstr "Camp obligatori" -#: inc/class-wp-members.php:1254 inc/deprecated.php:226 +#: includes/class-wp-members.php:1545 includes/deprecated - Copy.php:741 msgid "Edit Your Information" msgstr "Edita la teva informació" -#: inc/class-wp-members.php:1256 +#: includes/class-wp-members.php:1547 msgid "Update Profile" msgstr "Actualitzar Perfil" -#: inc/class-wp-members.php:1257 +#: includes/class-wp-members.php:1548 msgid "Update this file" msgstr "" -#: inc/class-wp-members.php:1260 +#: includes/class-wp-members.php:1551 msgid "Login Failed!" msgstr "¡Error d'identificació!" -#: inc/class-wp-members.php:1261 +#: includes/class-wp-members.php:1552 msgid "You entered an invalid username or password." msgstr "Ha introduit un nom d'usuari o una contrasenya incorrecta" -#: inc/class-wp-members.php:1262 +#: includes/class-wp-members.php:1553 msgid "Click here to continue." msgstr "Prem aquí per continuar." -#: inc/class-wp-members.php:1263 +#: includes/class-wp-members.php:1554 msgid "Password fields cannot be empty" msgstr "La contrasenya no coincideix" -#: inc/class-wp-members.php:1264 +#: includes/class-wp-members.php:1555 msgid "Sorry, that email address was not found." msgstr "" -#: inc/class-wp-members.php:1265 +#: includes/class-wp-members.php:1556 #, php-format msgid "An email was sent to %s with your username." msgstr "" -#: inc/class-wp-members.php:1266 +#: includes/class-wp-members.php:1557 #, php-format msgid "Sorry, %s is a required field." msgstr "Disculpa, %s és un camp obligatori." -#: inc/class-wp-members.php:1267 +#: includes/class-wp-members.php:1558 msgid "You must enter a valid email address." msgstr "Heu d'introduir un adreça de correu electrònic vàlida" -#: inc/class-wp-members.php:1268 +#: includes/class-wp-members.php:1559 msgid "The username cannot include non-alphanumeric characters." msgstr "El nom d'usuari no pot contenir caràcters que no siguin alfanumèrics." -#: inc/class-wp-members.php:1269 +#: includes/class-wp-members.php:1560 msgid "Sorry, username is a required field" msgstr "Disculpa, el nom d'usuari és obligatori" -#: inc/class-wp-members.php:1270 +#: includes/class-wp-members.php:1561 msgid "Passwords did not match." msgstr "Les contrasenyes no coincideixen" -#: inc/class-wp-members.php:1271 +#: includes/class-wp-members.php:1562 msgid "Emails did not match." msgstr "Les correus electrònics no coincideixen" -#: inc/class-wp-members.php:1272 +#: includes/class-wp-members.php:1563 msgid "You must complete the CAPTCHA form." msgstr "Heu de completar la paraula mostrada en la imatge" -#: inc/class-wp-members.php:1273 +#: includes/class-wp-members.php:1564 msgid "CAPTCHA was not valid." msgstr "" -#: inc/class-wp-members.php:1274 inc/register.php:52 -msgid "There was an error processing the form." -msgstr "Hi hagut un error amb el formulari" +#: includes/class-wp-members.php:1567 +#, php-format +msgid "" +"Sorry, you can only upload the following file types for the %s field: %s." +msgstr "" -#: inc/class-wp-members.php:1278 +#: includes/class-wp-members.php:1570 msgid "Edit My Information" msgstr "Editar la meva informació" -#: inc/class-wp-members.php:1280 inc/class-wp-members.php:1283 -#: inc/class-wp-members.php:1285 inc/class-wp-members.php:1290 +#: includes/class-wp-members.php:1572 includes/class-wp-members.php:1575 +#: includes/class-wp-members.php:1577 includes/class-wp-members.php:1582 #, php-format msgid "You are logged in as %s" msgstr "S'ha identificat com %s" -#: inc/class-wp-members.php:1281 -msgid "Click to log out." -msgstr "Prem aquí per desconnectar-te" +#: includes/class-wp-members.php:1573 +msgid "Log out" +msgstr "" + +#: includes/class-wp-members.php:1574 +msgid "Edit profile" +msgstr "" -#: inc/class-wp-members.php:1282 +#: includes/class-wp-members.php:1574 msgid "Begin using the site." msgstr "Comença a utilitzar el web" -#: inc/class-wp-members.php:1284 +#: includes/class-wp-members.php:1576 msgid "Click to log out" msgstr "Prem aquí per desconnectar-te" -#: inc/class-wp-members.php:1286 +#: includes/class-wp-members.php:1578 msgid "click to log out" msgstr "Prem aquí per desconnectar-te" -#: inc/class-wp-members.php:1287 +#: includes/class-wp-members.php:1579 msgid "Log Out" msgstr "" -#: inc/class-wp-members.php:1291 +#: includes/class-wp-members.php:1583 msgid "click here to log out" msgstr "Prem aquí per desconnectar-te" -#: inc/class-wp-members.php:1292 +#: includes/class-wp-members.php:1584 msgid "Login Failed!
    You entered an invalid username or password." msgstr "" "Identificació fallada!
    Has introduit un nom d'usuari o una contrasenya " "incorrectes." -#: inc/class-wp-members.php:1297 +#: includes/class-wp-members.php:1589 msgid "Forgot?" msgstr "Has oblidat la contrasenya?" -#: inc/class-wp-members.php:1301 +#: includes/class-wp-members.php:1593 msgid "" "This content is restricted to site members. If you are an existing user, " "please log in. New users may register below." @@ -1787,7 +2023,7 @@ msgstr "" "Aquest contingut és exclussiu pels usuaris registrats. Si ja ets un usuari " "registrat, siusplau identifica't. Si és un nou usuari, siusplau registra't. " -#: inc/class-wp-members.php:1302 +#: includes/class-wp-members.php:1594 msgid "" "Congratulations! Your registration was successful.

    You may now " "log in using the password that was emailed to you." @@ -1796,96 +2032,164 @@ msgstr "" "la sessió identifican-te amb la contrasenya que ha estat enviada a la teva " "adreça de correu. " -#: inc/class-wp-members.php:1305 +#: includes/class-wp-members.php:1597 msgid "Sorry, that username is taken, please try another." msgstr "" "Ho sentim, aquest nom d'usuari ja està agafat, siusplau prova'n un altre. " -#: inc/class-wp-members.php:1306 +#: includes/class-wp-members.php:1598 msgid "" "Sorry, that email address already has an account.
    Please try another." msgstr "Ho sentim, aquest email ja està agafat, siusplau prova'n un altre. " -#: inc/class-wp-members.php:1307 +#: includes/class-wp-members.php:1599 msgid "Your information was updated!" msgstr "La teva informació ha estat actualitzada!" -#: inc/class-wp-members.php:1310 +#: includes/class-wp-members.php:1602 msgid "Passwords did not match.

    Please try again." msgstr "" "Les contrasenyes no coincideixen

    Siusplau intenta-ho de nou." -#: inc/class-wp-members.php:1311 +#: includes/class-wp-members.php:1603 msgid "Password successfully changed!" msgstr "" -#: inc/class-wp-members.php:1312 +#: includes/class-wp-members.php:1604 msgid "Either the username or email address do not exist in our records." msgstr "El nom d'usuari o email no existeixen en la nostra base de dades." -#: inc/class-wp-members.php:1313 +#: includes/class-wp-members.php:1605 msgid "" "Password successfully reset!

    An email containing a new password " "has been sent to the email address on file for your account." msgstr "" -#: inc/class-wp-members.php:1315 -msgid "Sorry, you do not have access to this content." +#: includes/class-wp-members.php:1607 +msgid "This content requires the following membership: " +msgstr "" + +#: includes/class-wp-members.php:1608 +msgid "This content requires one of the following memberships: " msgstr "" -#: inc/class-wp-members.php:1433 +#: includes/class-wp-members.php:1721 msgid "Show forms as logged out" msgstr "" -#: inc/class-wp-members.php:1442 +#: includes/class-wp-members.php:1730 msgid "Show form message dialog" msgstr "" -#: inc/class-wp-members.php:1538 +#: includes/class-wp-members.php:1838 msgid "(more…)" msgstr "" -#: inc/register.php:417 +#: includes/cli/class-wp-members-cli.php:17 +#, php-format +msgid "User: %s" +msgstr "" + +#: includes/deprecated - Copy.php:472 includes/deprecated.php:473 msgid "We were unable to validate the public key." msgstr "No s'ha pogut validar la clau pública." -#: inc/register.php:421 +#: includes/deprecated - Copy.php:476 includes/deprecated.php:477 msgid "We were unable to validate the private key." msgstr "No s'ha pogut validar la clau privada." -#: inc/register.php:425 +#: includes/deprecated - Copy.php:480 includes/deprecated.php:481 msgid "The challenge parameter of the verify script was incorrect." msgstr "El paràmetre de verificació del script és incorrecte." -#: inc/register.php:429 +#: includes/deprecated - Copy.php:484 includes/deprecated.php:485 msgid "The CAPTCHA solution was incorrect." msgstr "La resolució de CAPTCHA és incorrecte." -#: inc/register.php:433 +#: includes/deprecated - Copy.php:488 includes/deprecated.php:489 msgid "The parameters to verify were incorrect" msgstr "Els paràmetres a verificar són incorrectes" -#: inc/register.php:437 +#: includes/deprecated - Copy.php:492 includes/deprecated.php:493 msgid "" "reCAPTCHA API keys are tied to a specific domain name for security reasons." msgstr "" "Les claus de reCAPTCHA van associades a un domini específic per raons de " "seguretat. " -#: inc/register.php:441 +#: includes/deprecated - Copy.php:496 includes/deprecated.php:497 msgid "The reCAPTCHA server was not reached. Please try to resubmit." msgstr "El servidor de reCAPTCHA no respond, siusplau intenta-ho de nou." -#: inc/register.php:445 -msgid "You have entered an incorrect code value. Please try again." +#. translators: %s: title of menu item which is invalid +#: includes/walkers/class-wp-members-walker-nav-menu.php:92 +#, php-format +msgid "%s (Invalid)" +msgstr "" + +#. translators: %s: title of menu item in draft status +#: includes/walkers/class-wp-members-walker-nav-menu.php:96 +#, php-format +msgid "%s (Pending)" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:123 +msgid "Move up" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:136 +msgid "Move down" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:138 +msgid "Edit Menu Item" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:149 +msgid "URL" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:156 +msgid "Navigation Label" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:162 +msgid "Title Attribute" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:169 +msgid "Open link in a new window/tab" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:174 +msgid "CSS Classes (optional)" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:180 +msgid "Link Relationship (XFN)" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:188 +msgid "" +"The description will be displayed in the menu if the current theme supports " +"it." +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:210 +#, php-format +msgid "Original: %s" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:223 +msgid "Remove" msgstr "" -#: wp-members-tos.php:35 +#: templates/tos.php:32 #, php-format msgid "%sclose%s" msgstr "%stanca%s" -#: wp-members-tos.php:37 +#: templates/tos.php:34 #, php-format msgid "%sprint%s" msgstr "%simprimeix%s" @@ -1915,6 +2219,9 @@ msgstr "" msgid "http://butlerblog.com/" msgstr "" +#~ msgid "Click to log out." +#~ msgstr "Prem aquí per desconnectar-te" + #~ msgid "You have set WP-Members to turn off the registration process" #~ msgstr "Ha configurat WP-Members per desactivar el procés de registre " diff --git a/i18n/languages/wp-members-da_DK.mo b/i18n/languages/wp-members-da_DK.mo index 231475d95f27e11011820ab04c7103029de90326..b88b35c00f1011ae7023ec246d6aa623cb4fccd6 100644 GIT binary patch delta 4329 zcmYk<2~bs49LMnkB8aIW$YPc}gb-0=aYIxD-1nu;H3TzJ2~bHAjh7mwiA$Dci?+CA zq@?14Whxe0T9Y%mRBAI~r8raLXpKb+eShyBsyqGO=bZcQyZ4;`x%XnXR(sX2@^XI{ z=(FCi)sVZ%Kwo40yo||hp}oc|4=~0bS6E-bR`fSwbKGG)fF0={!)ACLgYcI9-mkSW zoZ1AUAGXC1W85Z!hAxn7&A>qVBe5-JVmn-jEpa^t<7VVPbC8ca@Dw)1^XP+@umjfO zo!FF;$r*}HKXZ#Nz=?h zO{fGl(B-J_H{o5l4OO9P^x^vEBn|#EU-F?JT)}kw9W{_XZJd&)qh>M|b^J6`NefZG zTZCGg=WYK@)P?t>jysGRcnzvz=g_S+thERHgzEod`wgfc_;PlgC=_Ec9KCTks&b=H zmCD4PScIxT1y*1cY5+4Sqn0oa`{Uve>aY9kkp1E_)C|sJ82*U-)-<3763kW9k49af zFKQrzu_F#coo_B`z$MrjpFve}532N4sOwaRQh%NJG&{oavi-t~tJ5?AsDZ@r(F4;_ zr7J>JY8h%ktFZ}gL0w=w>H@n_#~np2-6>=)<^t;GzUii+5w@VGA0(q@HU#;~jI;Y^ z;~@GAQ6)Trx|zN}4fGo7!rIv${BbzOU=q&9NZf|1#7R_z+^1=%WM89Z@B^wMb*Pcn zqfXeGXHX|dz&?0Cs^n`?k5d&U<88Y?ftN`q`V+7Sm*PU+EA<$Og`AYixy=UZuA8F* zHIRL%8687arf@UZTI`RoPG%Ev5Q76O>a~s2BB`w(Kr~Vq4vLn(YOnn>-j%V zgF%^E{yAiK;oyceIwF<6dcu^z|a2)?`rH)0d~5Nq%VuESEM ztqO#(Zn|kB(5|_vXsXKI`{#3`rvqL`^hZ@;L)MJxx_ZQp#QdCJ-p)R<^x)U{# z{m6r0P9XQ8xr{o`U#Rmoi*xRY_UKPPA&&ZM<|*vZf$6AHkHnT(VE32caQZ8-1)f2@ zf-j?9K)<3&{u}DTe2W}b?=yN96O6BDry&cmiyfg0#u)N$3Q0eoe@zlOSw`)3*&fKP%`l2FtIB5Xev zRr2nrwH#shKZL4W7HZ%*s0$ZhD_mf|FGbzVWvEJ>Kn>_5QX#jwNF$9Mw^3`7oM_B( z%s}=1lbp2;LcL(3P)jux12G3x>P6O%>^Z&1HpP9>vJH|H3P#+AsW z%${D$q%Z5Q62Ht2&FEbW!o4^eKSezaq5Yh{b}rO$Lop2RLl@?vX1vO} z1Ec7lLT&?d11XA$N_Fm~$*4+Bchk^gk%OT)2UW^tr~$l+FJc|e!jk^Z<8%%0qaT^Z zTMUbEAa2KY_!IKlH~#6)QpRHz{Yf|u58+sJx5{u1%tV#66i;CpzKs(GIHmjpHRI-7 zr42@+ZrWtj(~*IhI2={_a@609gP2EOe}ju5AN5pSM}F@%H)wF2`G~Y9+H`=*rENRe z;%V`=!{^96!peCz-LPHBWU`0MCwlWWZe=ty)7R_{&Hg>x_MGJ~9T$lvTI))(gs9x> z$sn?W{C|6Zj-KJocIRy59`-z5nr%7RK&BIIJgJ^-sZ})Bhi0KNYoieVZp;5|IsaHt zNp&Y{<6bgP5?`Xb{UM^IXxy|MN60jyo9`vkxIIeadBV%jtR`-6KAs>kWHE^)JXM~* zb|2t)qHPV)TkToWgXrdZii{yeM31j-$O1Bn>?4~?a3E4Y`{P;QF4e1E0HX zTWll)ZT}sss3ylqh&pVcq&4YCMiOnsWR<7&-^cqjUm#Va3E4#+B<_QJ^d&*$Eu!sZ z2hYFjU!nab8A@IxndEWOxJA+UxUqx1$sDrC?#s2li+WXS3np_(JLjR}e W%5$;9yu7+qy1H!juDsB7L)bsP)2cQA delta 4433 zcmYk(zv@`@mGQ$!Q>6%AMP!m(Ug?7ATW~M1- z1xaOU<7i$Oj4Zr1;&P4s(U>#SvdN^SE3;a;Y?{)p-{(D>RcHC|+55cjIcM+RKIee9 zHUxaLF~GSP9kkW3ohET)LPuk|1Q@d{OnZ$v7->uhHdwT2xIXbWTfUC>I9!7lQch}jtgh! zGW4Qm)_{CucA+MA7&YK`?dKojZS*f;C$4XPprH!~b#pHef;yl#=HpP*fEJ=kUxS*_ z)5xKw9#z`?sN>#5eebO8UqB7)I_i7hqbBeRIx1ZxM`?}XP+v&0{S@2JMjeocI?-fI z#%UOcPoOHX7FDr29EOdk3S7ngcms9*?UYkXxw|{{&!y4K4&876w;y!iESf?|s&b8}${j@w@CM2HiaO61sPElEEuDuuo4J}8hlcL*!Tit& zi%p|y$X=e_~skZYQ3)QqQDmmps?FQAs{Fec+=R0SjA-IB(lD%cw} zfqtk8W@8B!V->!E4|07IM?G_~2B%>Q4#t@NtRs#_s%DlWADMa_fX8qWUdCd~VCQ69 zgH+f22Rq=m*orr?7LO;o6_~>MI4XS!4XyQ~s3lm1D$zO|kF}^$U&NvSW4^+<^fOr4 z$8ZM*VIRt&;}S42kV#-L{kxfsmZSuAo(k)t!PGyD9c$P@6-_PbfJ3N(9l=mMXZL?> z`&UpUy^gwIu+KFTHIbgkgJF`9`_UAl&Qppy?`+gPvC>EVLuhPahi2Yjzqk`s>I2vX zKd}4Ta2)+FF$}X(+*fcRGGTKcs^lf83qOQBX{H7>py!ddt~rPrNUK9b_rOP}5|#|H zcQL9G3s7IIK@D&->O?Q1zW+B=1>Qo<=mhG0aSlh|7wEyHRCmBW)c0~w192wM&=<;3 z7pg!#M$1u^*@U`4z3uNnm3|*;O;6eV@1q8I0X6V8)OkP0aQxbS{xj;P_N4hM=9oMh z8c_kNR8uhz=b;ABh^Mi|_E)95Yy1rAMbm&<+kay;wxQ1RKWoHLcc#gxf#+K9#Sqp0 z5gJ;v#mFj{8q|pQpi2BU{sE7nX7m|qhF_sB_$@|YrwsS~&;!-aMqO|$YCxsvKR>E+ zdoWaM-%LYmdJ=WPk5Dtegc`^-)B!g!3O$+pHG{FJ3yeX%AMQtez7)IQdW^w3)PN4) zcs!1g*m)T1-S@@78fYDA z<|nZSzK34Cf|_y1QLY29Km9`Fb}^MmF-?O*LpRfTR4M<9dXcoDW^fr*${$e!=$dQH zb6Ad*_#NtTD$C#F1yn+eGWLiM&K~6P6NgeE+lm7HZwwH&(^J-DT~C`^n2hPsA>wPbEsK(syO;{RiDl5L9+5>6t>YND+td4o(LdrAA&fyRTj(~RS6oA;a9Ngl9$ zXTEKW#y^w0$wZ=;NGGCg0~zLTxj!ELUAw(mOCy$e$>T)Z5i-Z$;(yUr@jQ8fMCwv2 zXe=jvNDE0O!9zC3\n" "Language-Team: mikael.boldt@mail.dk\n" "Language: da_DK\n" @@ -15,448 +15,683 @@ msgstr "" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-KeywordsList: __;_e;_c\n" "X-Poedit-Basepath: D:/downloads/wp-members\n" -"X-Generator: Poedit 2.2.1\n" +"X-Generator: Poedit 2.3.1\n" "X-Poedit-SearchPath-0: D:/downloads/wp-members\n" -#: admin/dialogs.php:116 -msgid "" -"Your WP settings allow anyone to register - this is not the recommended " -"setting." -msgstr "" -"Dine WP indstillinger tillader alle at registrere sig - dette kan ikke " -"anbefales." - -#: admin/dialogs.php:117 -#, php-format -msgid "" -"You can %s change this here %s making sure the box next to \"Anyone can " -"register\" is unchecked." -msgstr "" -"Du kan %s ændre dette her %s ved at sørge for boksen ved siden af \"Alle kan " -"registrere \" er u-markeret." - -#: admin/dialogs.php:118 -msgid "" -"This setting allows a link on the /wp-login.php page to register using the " -"WP native registration process thus circumventing any registration you are " -"using with WP-Members. In some cases, this may suit the users wants/needs, " -"but most users should uncheck this option. If you do not change this " -"setting, you can choose to ignore these warning messages under WP-Members " -"Settings." -msgstr "" -"Denne indstilling tillader at et link pÃ¥ /wp-login.php siden for at lade sig " -"registrere ved hjælp af WP oprindelige registreringsprocessen sÃ¥ledes omgÃ¥r " -"enhver form for registrering, du bruger sammen med WP-Members. I nogle " -"tilfælde passer dette til brugernes ønsker/behov, men de fleste brugere bør " -"fjerne markeringen af denne mulighed. Hvis du ikke ændrer denne indstilling, " -"kan du vælge at ignorere disse advarsler i henhold til WP-medlemmer " -"indstillinger." - -#: admin/dialogs.php:122 -msgid "" -"Your WP settings allow anyone to comment - this is not the recommended " -"setting." -msgstr "" -"Dine WP indstillinger tillader alle at skrive kommentarer - denne " -"indstilling kan ikke anbefales." - -#: admin/dialogs.php:123 -#, php-format -msgid "" -"You can %s change this here %s by checking the box next to \"Users must be " -"registered and logged in to comment.\"" -msgstr "" -"Du kan %s ændre dette her %s ved at sørge for boksen ved siden af \"Brugere " -"skal være registrerede og logget ind for at kommentere \" er markeret." - -#: admin/dialogs.php:124 -msgid "" -"This setting allows any users to comment, whether or not they are " -"registered. Depending on how you are using WP-Members will determine whether " -"you should change this setting or not. If you do not change this setting, " -"you can choose to ignore these warning messages under WP-Members Settings." -msgstr "" -"Denne indstilling gør det muligt for alle brugere at kommentere, selv om de " -"ikker er registreret. Afhængigt af, hvordan du bruger WP-Members afgør om " -"du bør ændre denne indstilling eller ej. Hvis du ikke ændrer denne " -"indstilling, kan du vælge at ignorere disse advarsler i henhold til WP-" -"Members indstillinger." - -#: admin/dialogs.php:128 -msgid "" -"Your WP settings allow full text rss feeds - this is not the recommended " -"setting." -msgstr "" -"Din WP indstilling tilader fuld RSS feeds - denne indstilling kan ikke " -"anbefales" - -#: admin/dialogs.php:129 -#, php-format -msgid "" -"You can %s change this here %s by changing \"For each article in a feed, show" -"\" to \"Summary.\"" -msgstr "" -"Du kan %s ændre dette %s ved at ændre \"For hvert indlæg, vis \" to \"Resume." -"\"" - -#: admin/dialogs.php:130 -msgid "" -"Leaving this set to full text allows anyone to read your protected content " -"in an RSS reader. Changing this to Summary prevents this as your feeds will " -"only show summary text." -msgstr "" -"At sætte RSS til fuld tekst giver alle mulighed for at læse dit beskyttet " -"indhold i en RSS-læser. At ændre RSS til Oversigt forhindrer dette og dine " -"feeds vil kun blive vist som summarisk tekst." - -#: admin/dialogs.php:134 -msgid "You have set WP-Members to hold registrations for approval" -msgstr "Du har sat WP-Members til at vente pÃ¥ godkendelse af registreringer" - -#: admin/dialogs.php:135 -msgid "" -"but you have not changed the default message for \"Registration Completed\" " -"under \"WP-Members Dialogs and Error Messages.\" You should change this " -"message to let users know they are pending approval." -msgstr "" -"men du har ikke ændret standard besked for \"Registrering fuldført\" under " -"\"WP-Members Dialoger og Fejlmeldinger.\" Du bør ændre denne besked sÃ¥ " -"brugerne ved at deres tilmelding afventer godkendelsel." - -#: admin/dialogs.php:139 -msgid "You have turned on reCAPTCHA" -msgstr "Du har slÃ¥et reCAPTCHA til" - -#: admin/dialogs.php:140 -msgid "" -"but you have not entered API keys. You will need both a public and private " -"key. The CAPTCHA will not display unless a valid API key is included." -msgstr "" -"men du ikke har indtastet API nøgler. Du skal bruge bÃ¥de en offentlig og " -"privat nøgle. Den CAPTCHA vises ikke, medmindre at en gyldig API-nøgle er " -"inkluderet." - -#: admin/dialogs.php:144 -msgid "You have active settings that are not recommended." -msgstr "" - -#: admin/dialogs.php:145 -msgid "" -"If you will not be changing these settings, you can turn off these warning " -"messages by checking the \"Ignore warning messages\" in the settings below." -msgstr "" - -#: admin/dialogs.php:169 -msgid "Version:" -msgstr "Version:" - -#: admin/dialogs.php:170 -msgid "Quick Start Guide" -msgstr "" - -#: admin/dialogs.php:171 -msgid "Online User Guide" -msgstr "" - -#: admin/dialogs.php:172 -msgid "FAQs" -msgstr "" - -#: admin/dialogs.php:179 -msgid "Thank you for using WP-Members" -msgstr "Thank you for using WP-Members" - -#: admin/dialogs.php:180 -msgid "A plugin developed by" -msgstr "" - -#: admin/dialogs.php:181 -msgid "Follow" -msgstr "Følg" - -#: admin/dialogs.php:198 admin/dialogs.php:202 -msgid "Latest from RocketGeek" -msgstr "" - -#: admin/dialogs.php:219 -msgid "Like WP-Members?" -msgstr "" - -#: admin/dialogs.php:220 -#, php-format -msgid "" -"If you like WP-Members please give it a %s★★★★★" -"%s rating. Thanks!!" -msgstr "" - -#: admin/dialogs.php:231 admin/dialogs.php:244 -msgid "Latest from ButlerBlog" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:256 +#: includes/admin/class-wp-members-admin-api.php:292 msgid "Custom email" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:257 -#: admin/includes/class-wp-members-admin-api.php:259 +#: includes/admin/class-wp-members-admin-api.php:293 +#: includes/admin/class-wp-members-admin-api.php:295 msgid "Subject" msgstr "Emne" -#: admin/includes/class-wp-members-admin-api.php:260 +#: includes/admin/class-wp-members-admin-api.php:296 msgid "Body" msgstr "Brødtekst" -#: admin/includes/class-wp-members-admin-api.php:262 +#: includes/admin/class-wp-members-admin-api.php:298 msgid "Your custom email message content." msgstr "" -#: admin/includes/class-wp-members-admin-api.php:340 +#: includes/admin/class-wp-members-admin-api.php:376 msgid "Options" msgstr "Valg" -#: admin/includes/class-wp-members-admin-api.php:341 +#: includes/admin/class-wp-members-admin-api.php:377 msgid "Fields" msgstr "Felter" -#: admin/includes/class-wp-members-admin-api.php:342 +#: includes/admin/class-wp-members-admin-api.php:378 msgid "Dialogs" msgstr "Dialog" -#: admin/includes/class-wp-members-admin-api.php:343 +#: includes/admin/class-wp-members-admin-api.php:379 msgid "Emails" msgstr "Email" -#: admin/includes/class-wp-members-admin-api.php:359 +#: includes/admin/class-wp-members-admin-api.php:395 msgid "New Registration" msgstr "Ny Bruger Registrering" -#: admin/includes/class-wp-members-admin-api.php:368 +#: includes/admin/class-wp-members-admin-api.php:404 msgid "Registration is Moderated" msgstr "Registrering fuldført" -#: admin/includes/class-wp-members-admin-api.php:374 +#: includes/admin/class-wp-members-admin-api.php:410 msgid "Registration is Moderated, User is Approved" msgstr "Din registrering er godkendt" -#: admin/includes/class-wp-members-admin-api.php:382 +#: includes/admin/class-wp-members-admin-api.php:418 msgid "Password Reset" msgstr "Kodeord Nulstillet" -#: admin/includes/class-wp-members-admin-api.php:389 +#: includes/admin/class-wp-members-admin-api.php:425 msgid "Retrieve Username" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:397 +#: includes/admin/class-wp-members-admin-api.php:433 msgid "Admin Notification" msgstr "Admin Meddelelse" -#: admin/includes/class-wp-members-admin-api.php:423 +#: includes/admin/class-wp-members-admin-api.php:459 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Vises over Log pÃ¥ / Registrering pÃ¥ Post eller Side med begrænset adgang" -#: admin/includes/class-wp-members-admin-api.php:424 +#: includes/admin/class-wp-members-admin-api.php:460 msgid "Username is taken" msgstr "Brugernavn er taget" -#: admin/includes/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:461 msgid "Email is registered" msgstr "Email er registreret" -#: admin/includes/class-wp-members-admin-api.php:426 +#: includes/admin/class-wp-members-admin-api.php:462 msgid "Registration completed" msgstr "Registrering fuldført - afventer godkendelse" -#: admin/includes/class-wp-members-admin-api.php:427 +#: includes/admin/class-wp-members-admin-api.php:463 msgid "User update" msgstr "Bruger opdatering" -#: admin/includes/class-wp-members-admin-api.php:428 +#: includes/admin/class-wp-members-admin-api.php:464 msgid "Passwords did not match" msgstr "Kodeordene er ikke ens" -#: admin/includes/class-wp-members-admin-api.php:429 +#: includes/admin/class-wp-members-admin-api.php:465 msgid "Password changes" msgstr "Ændret Kodeord" -#: admin/includes/class-wp-members-admin-api.php:430 +#: includes/admin/class-wp-members-admin-api.php:466 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "Brugernavn eller Email eksisterer ikke nÃ¥r glemt Kodeord forsøges nulstillet" -#: admin/includes/class-wp-members-admin-api.php:431 +#: includes/admin/class-wp-members-admin-api.php:467 msgid "Password reset" msgstr "Nulstil Kodeord" -#: admin/includes/class-wp-members-admin-api.php:564 +#: includes/admin/class-wp-members-admin-api.php:623 msgid "Settings" msgstr "Indstillinger" -#: admin/includes/class-wp-members-products-admin.php:57 -msgid "Slug" +#: includes/admin/class-wp-members-admin-posts.php:30 +#: includes/admin/class-wp-members-admin-posts.php:33 +msgid "Unblock" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:58 -msgid "Role" +#: includes/admin/class-wp-members-admin-posts.php:31 +#: includes/admin/class-wp-members-admin-posts.php:34 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 +msgid "Block" +msgstr "Bloker" + +#: includes/admin/class-wp-members-admin-posts.php:32 +#: includes/admin/class-wp-members-admin-posts.php:35 +msgid "Hide" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s blocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:165 +#, php-format +msgid "%s Restriction" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:195 +msgid "Unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:196 +msgid "Blocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:197 +msgid "Hidden" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +msgid "Status:" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:68 +#: includes/admin/tabs/class-wp-members-fields-table.php:65 +#: includes/walkers/class-wp-members-walker-nav-menu.php:140 +msgid "Edit" +msgstr "Redigere" + +#: includes/admin/class-wp-members-admin-posts.php:218 +msgid "Ok" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:219 +#: includes/walkers/class-wp-members-walker-nav-menu.php:224 +msgid "Cancel" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:305 +#: includes/admin/class-wp-members-products-admin.php:629 +msgid "Status" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:28 +#: includes/admin/class-wp-members-admin-users.php:33 +#: includes/admin/class-wp-members-admin-users.php:59 +msgid "Activate" +msgstr "Aktiver" + +#: includes/admin/class-wp-members-admin-users.php:29 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:62 +msgid "Deactivate" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:31 +#: includes/admin/class-wp-members-admin-users.php:36 +msgid "Export" +msgstr "Eksporter" + +#: includes/admin/class-wp-members-admin-users.php:37 +#: includes/admin/class-wp-members-admin-users.php:88 +msgid "Export All Users" +msgstr "Eksporter Alle Brugere" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:129 +msgid "No users selected" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 +msgid "You cannot activate or deactivate yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:152 +#, php-format +msgid "%s activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:157 +#, php-format +msgid "%s deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:161 +msgid "That user is already active" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:288 +msgid "Pending" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:289 +msgid "Trial" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:290 +#: includes/admin/class-wp-members-export.php:74 +msgid "Subscription" +msgstr "Abonnement" + +#: includes/admin/class-wp-members-admin-users.php:291 +msgid "Expired" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:294 +msgid "Activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:295 +msgid "Pending Activation" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:296 +msgid "Deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:298 +msgid "Not Exported" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:59 -#: admin/includes/class-wp-members-products-admin.php:162 -#: admin/tab-fields.php:459 admin/user-export.php:69 +#: includes/admin/class-wp-members-admin-users.php:387 +#: includes/admin/class-wp-members-export.php:160 +msgid "No" +msgstr "Nej" + +#: includes/admin/class-wp-members-export.php:64 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-export.php:65 +#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 +msgid "Username" +msgstr "Brugernavn" + +#: includes/admin/class-wp-members-export.php:71 +msgid "Activated?" +msgstr "Aktiveret?" + +#: includes/admin/class-wp-members-export.php:75 +#: includes/admin/class-wp-members-products-admin.php:64 +#: includes/admin/class-wp-members-products-admin.php:632 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 msgid "Expires" msgstr "Udløber" -#: admin/includes/class-wp-members-products-admin.php:60 +#: includes/admin/class-wp-members-export.php:77 +msgid "Registered" +msgstr "Registreret" + +#: includes/admin/class-wp-members-export.php:78 +msgid "IP" +msgstr "IP" + +#: includes/admin/class-wp-members-export.php:160 +#: includes/admin/class-wp-members-products-admin.php:104 +msgid "Yes" +msgstr "Ja" + +#: includes/admin/class-wp-members-products-admin.php:62 +msgid "Slug" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:63 +msgid "Role" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:66 +msgid "Default" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:68 msgid "Last updated" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:80 +#: includes/admin/class-wp-members-products-admin.php:92 +msgid "slug:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:95 msgid "No role required" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:84 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "Does not expire" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:120 +#: includes/admin/class-wp-members-products-admin.php:140 msgid "Membership Product Details" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 -#: admin/includes/class-wp-members-products-admin.php:167 +#: includes/admin/class-wp-members-products-admin.php:148 +msgid "Membership Product Message (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 +msgid "Posts" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +msgid "Pages" +msgstr "Sider" + +#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:235 +#: includes/admin/class-wp-members-products-admin.php:280 msgid "Period" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Day" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Week" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Month" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Year" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:199 msgid "Name (slug)" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:153 -msgid "Role Required?" +#: includes/admin/class-wp-members-products-admin.php:201 +msgid "Optional Defaults" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:204 +msgid "Assign as default at registration? (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:212 +#, php-format +msgid "Pre-selected by default for new %s" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:218 +msgid "Optional Properties" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:221 +msgid "Role Required? (optional)" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:156 +#: includes/admin/class-wp-members-products-admin.php:224 msgid "No Role" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:164 -#: admin/includes/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:230 +msgid "Expires (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:232 +#: includes/admin/class-wp-members-products-admin.php:234 +#: includes/admin/class-wp-members-products-admin.php:277 +#: includes/admin/class-wp-members-products-admin.php:279 msgid "Number" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:245 -#: admin/tab-options.php:207 inc/class-wp-members-forms.php:999 -#: inc/class-wp-members-user-profile.php:106 inc/deprecated.php:360 -#: inc/deprecated.php:622 +#: includes/admin/class-wp-members-products-admin.php:240 +msgid "Use \"no gap\" renewal" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:244 +msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:261 +msgid "Period Start (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:262 +msgid "Period End (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:275 +msgid "Fixed period grace period" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:284 +msgid "" +"Grace period is the point at which expiration date is for following time " +"period. For example, if user who register August 1st would be part of the " +"following year's Sept 1 - Aug 31 membership, set this at 1 Month. Leave " +"blank for no grace period." +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:333 +msgid "" +"Restricted Message (displays when a user does not have access to a " +"membership)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:435 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 +#: includes/class-wp-members-forms.php:1092 +#: includes/class-wp-members-user-profile.php:112 msgid "None" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:251 +#: includes/admin/class-wp-members-products-admin.php:450 msgid "Limit access to:" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:321 +#: includes/admin/class-wp-members-products-admin.php:520 msgid "Required Membership" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:360 +#: includes/admin/class-wp-members-products-admin.php:559 +#: includes/admin/class-wp-members-products-admin.php:630 msgid "Membership" msgstr "" -#: admin/post.php:45 admin/post.php:48 -msgid "Unblock" +#: includes/admin/class-wp-members-products-admin.php:599 +#: includes/class-wp-members-products.php:308 +msgid "Memberships" msgstr "" -#: admin/post.php:46 admin/post.php:49 admin/tab-options.php:114 -msgid "Block" -msgstr "Bloker" +#: includes/admin/class-wp-members-products-admin.php:626 +msgid "Product Access" +msgstr "" -#: admin/post.php:47 admin/post.php:50 -msgid "Hide" +#: includes/admin/class-wp-members-products-admin.php:631 +msgid "Enabled?" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:641 +msgid "Enable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:642 +msgid "Disable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:647 +msgid "Expiration date (optional)" +msgstr "" + +#: includes/admin/dialogs.php:117 +msgid "" +"Your WP settings allow anyone to register - this is not the recommended " +"setting." +msgstr "" +"Dine WP indstillinger tillader alle at registrere sig - dette kan ikke " +"anbefales." + +#: includes/admin/dialogs.php:118 +#, php-format +msgid "" +"You can %s change this here %s making sure the box next to \"Anyone can " +"register\" is unchecked." +msgstr "" +"Du kan %s ændre dette her %s ved at sørge for boksen ved siden af \"Alle kan " +"registrere \" er u-markeret." + +#: includes/admin/dialogs.php:119 +msgid "" +"This setting allows a link on the /wp-login.php page to register using the " +"WP native registration process thus circumventing any registration you are " +"using with WP-Members. In some cases, this may suit the users wants/needs, " +"but most users should uncheck this option. If you do not change this " +"setting, you can choose to ignore these warning messages under WP-Members " +"Settings." +msgstr "" +"Denne indstilling tillader at et link pÃ¥ /wp-login.php siden for at lade sig " +"registrere ved hjælp af WP oprindelige registreringsprocessen sÃ¥ledes omgÃ¥r " +"enhver form for registrering, du bruger sammen med WP-Members. I nogle " +"tilfælde passer dette til brugernes ønsker/behov, men de fleste brugere bør " +"fjerne markeringen af denne mulighed. Hvis du ikke ændrer denne indstilling, " +"kan du vælge at ignorere disse advarsler i henhold til WP-medlemmer " +"indstillinger." + +#: includes/admin/dialogs.php:123 +msgid "" +"Your WP settings allow anyone to comment - this is not the recommended " +"setting." +msgstr "" +"Dine WP indstillinger tillader alle at skrive kommentarer - denne " +"indstilling kan ikke anbefales." + +#: includes/admin/dialogs.php:124 +#, php-format +msgid "" +"You can %s change this here %s by checking the box next to \"Users must be " +"registered and logged in to comment.\"" +msgstr "" +"Du kan %s ændre dette her %s ved at sørge for boksen ved siden af \"Brugere " +"skal være registrerede og logget ind for at kommentere \" er markeret." + +#: includes/admin/dialogs.php:125 +msgid "" +"This setting allows any users to comment, whether or not they are " +"registered. Depending on how you are using WP-Members will determine whether " +"you should change this setting or not. If you do not change this setting, " +"you can choose to ignore these warning messages under WP-Members Settings." +msgstr "" +"Denne indstilling gør det muligt for alle brugere at kommentere, selv om de " +"ikker er registreret. Afhængigt af, hvordan du bruger WP-Members afgør om " +"du bør ændre denne indstilling eller ej. Hvis du ikke ændrer denne " +"indstilling, kan du vælge at ignorere disse advarsler i henhold til WP-" +"Members indstillinger." + +#: includes/admin/dialogs.php:129 +msgid "" +"Your WP settings allow full text rss feeds - this is not the recommended " +"setting." +msgstr "" +"Din WP indstilling tilader fuld RSS feeds - denne indstilling kan ikke " +"anbefales" + +#: includes/admin/dialogs.php:130 +#, php-format +msgid "" +"You can %s change this here %s by changing \"For each article in a feed, show" +"\" to \"Summary.\"" +msgstr "" +"Du kan %s ændre dette %s ved at ændre \"For hvert indlæg, vis \" to \"Resume." +"\"" + +#: includes/admin/dialogs.php:131 +msgid "" +"Leaving this set to full text allows anyone to read your protected content " +"in an RSS reader. Changing this to Summary prevents this as your feeds will " +"only show summary text." +msgstr "" +"At sætte RSS til fuld tekst giver alle mulighed for at læse dit beskyttet " +"indhold i en RSS-læser. At ændre RSS til Oversigt forhindrer dette og dine " +"feeds vil kun blive vist som summarisk tekst." + +#: includes/admin/dialogs.php:135 +msgid "You have set WP-Members to hold registrations for approval" +msgstr "Du har sat WP-Members til at vente pÃ¥ godkendelse af registreringer" + +#: includes/admin/dialogs.php:136 +msgid "" +"but you have not changed the default message for \"Registration Completed\" " +"under \"WP-Members Dialogs and Error Messages.\" You should change this " +"message to let users know they are pending approval." +msgstr "" +"men du har ikke ændret standard besked for \"Registrering fuldført\" under " +"\"WP-Members Dialoger og Fejlmeldinger.\" Du bør ændre denne besked sÃ¥ " +"brugerne ved at deres tilmelding afventer godkendelsel." + +#: includes/admin/dialogs.php:140 +msgid "You have turned on reCAPTCHA" +msgstr "Du har slÃ¥et reCAPTCHA til" + +#: includes/admin/dialogs.php:141 +msgid "" +"but you have not entered API keys. You will need both a public and private " +"key. The CAPTCHA will not display unless a valid API key is included." msgstr "" +"men du ikke har indtastet API nøgler. Du skal bruge bÃ¥de en offentlig og " +"privat nøgle. Den CAPTCHA vises ikke, medmindre at en gyldig API-nøgle er " +"inkluderet." -#: admin/post.php:138 -#, php-format -msgid "%s blocked" +#: includes/admin/dialogs.php:145 +msgid "You have active settings that are not recommended." msgstr "" -#: admin/post.php:138 -#, php-format -msgid "%s unblocked" +#: includes/admin/dialogs.php:146 +msgid "" +"If you will not be changing these settings, you can turn off these warning " +"messages by checking the \"Ignore warning messages\" in the settings below." msgstr "" -#: admin/post.php:177 -#, php-format -msgid "%s Restriction" -msgstr "" +#: includes/admin/dialogs.php:174 +msgid "Version:" +msgstr "Version:" -#: admin/post.php:206 -msgid "Unblocked" +#: includes/admin/dialogs.php:175 +msgid "Quick Start Guide" msgstr "" -#: admin/post.php:207 -msgid "Blocked" +#: includes/admin/dialogs.php:176 +msgid "Online User Guide" msgstr "" -#: admin/post.php:208 -msgid "Hidden" +#: includes/admin/dialogs.php:177 +msgid "FAQs" msgstr "" -#: admin/post.php:214 -msgid "Status:" +#: includes/admin/dialogs.php:184 +msgid "Thank you for using WP-Members" +msgstr "Thank you for using WP-Members" + +#: includes/admin/dialogs.php:185 +msgid "A plugin developed by" msgstr "" -#: admin/post.php:214 admin/tab-fields.php:88 admin/tab-fields.php:554 -msgid "Edit" -msgstr "Redigere" +#: includes/admin/dialogs.php:186 +msgid "Follow" +msgstr "Følg" -#: admin/post.php:229 -msgid "Ok" +#: includes/admin/dialogs.php:203 includes/admin/dialogs.php:207 +msgid "Latest from RocketGeek" msgstr "" -#: admin/post.php:230 -msgid "Cancel" +#: includes/admin/dialogs.php:224 +msgid "Like WP-Members?" msgstr "" -#: admin/post.php:314 -msgid "Status" +#: includes/admin/dialogs.php:225 +#, php-format +msgid "" +"If you like WP-Members please give it a %s★★★★★" +"%s rating. Thanks!!" msgstr "" -#: admin/tab-about.php:34 admin/tab-about.php:54 -msgid "About WP-Members" +#: includes/admin/dialogs.php:236 includes/admin/dialogs.php:249 +msgid "Latest from ButlerBlog" msgstr "" -#: admin/tab-captcha.php:66 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:67 #, php-format msgid "See the %sUsers Guide on CAPTCHA%s." msgstr "" -#: admin/tab-captcha.php:73 admin/tab-dialogs.php:57 admin/tab-emails.php:101 -#: admin/tab-fields.php:153 admin/tab-options.php:82 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" -#: admin/tab-captcha.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 msgid "Manage reCAPTCHA Options" msgstr "Administrer reCAPTCHA Valg" -#: admin/tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 msgid "" "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " "while blocking spam on your blog." @@ -464,7 +699,7 @@ msgstr "" "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " "while blocking spam on your blog." -#: admin/tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 #, php-format msgid "" "reCAPTCHA asks commenters to retype two words scanned from a book to prove " @@ -479,11 +714,12 @@ msgstr "" "world gets accurately digitized books. Everybody wins! For details, visit " "the %s reCAPTCHA website%s" -#: admin/tab-captcha.php:104 admin/tab-captcha.php:130 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 msgid "reCAPTCHA Keys" msgstr "reCAPTCHA Keys" -#: admin/tab-captcha.php:106 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " @@ -492,108 +728,108 @@ msgstr "" "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " "key. You can sign up for a %s free reCAPTCHA key%s" -#: admin/tab-captcha.php:107 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 msgid "Public Key" msgstr "Public Key" -#: admin/tab-captcha.php:108 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 msgid "Private Key" msgstr "Private Key" -#: admin/tab-captcha.php:112 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 msgid "Choose Theme" msgstr "Choose Theme" -#: admin/tab-captcha.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 msgid "Red" msgstr "Rød" -#: admin/tab-captcha.php:116 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 msgid "White" msgstr "Hvid" -#: admin/tab-captcha.php:117 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 msgid "Black Glass" msgstr "Sort Glas" -#: admin/tab-captcha.php:118 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 msgid "Clean" msgstr "Ren" -#: admin/tab-captcha.php:132 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 msgid "Site Key" msgstr "" -#: admin/tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 msgid "Secret Key" msgstr "" -#: admin/tab-captcha.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 msgid "Characters for image" msgstr "" -#: admin/tab-captcha.php:169 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 msgid "Number of characters" msgstr "" -#: admin/tab-captcha.php:173 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 msgid "Image dimensions" msgstr "" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Width" msgstr "" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Height" msgstr "" -#: admin/tab-captcha.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Font color of characters" msgstr "" -#: admin/tab-captcha.php:181 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Background color of image" msgstr "" -#: admin/tab-captcha.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Font size" msgstr "" -#: admin/tab-captcha.php:189 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Width between characters" msgstr "" -#: admin/tab-captcha.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Image type" msgstr "" -#: admin/tab-captcha.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: admin/tab-captcha.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 msgid "Update CAPTCHA Settings" msgstr "Update CAPTCHA Settings" -#: admin/tab-captcha.php:301 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 msgid "CAPTCHA was updated for WP-Members" msgstr "CAPTCHA er opdateret for WP-Members" -#: admin/tab-dialogs.php:67 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:67 msgid "Dialogs and Error Messages" msgstr "Dialoger og Fejlmeldinger" -#: admin/tab-dialogs.php:69 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:69 #, php-format msgid "" "You can customize the text for dialogs and error messages. Simple HTML is " @@ -602,375 +838,339 @@ msgstr "" "Du kan tilpasse tekster til dialog og fejlmeldinger. Simpel HTML er tilladt " "%s osv." -#: admin/tab-dialogs.php:80 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:80 msgid "Terms of Service (TOS)" msgstr "VilkÃ¥r for Deltagelse" -#: admin/tab-dialogs.php:87 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:87 msgid "Update Dialogs" msgstr "Opdater Dialoger" -#: admin/tab-dialogs.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:124 msgid "WP-Members dialogs were updated" msgstr "WP-Members dialoger er opdateret" -#: admin/tab-dropins.php:78 admin/tab-dropins.php:378 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:88 +#: includes/admin/tabs/class-wp-members-dropins-table.php:180 msgid "WP-Members Dropin settings were updated" msgstr "" -#: admin/tab-dropins.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:216 msgid "Manage Dropins" msgstr "" -#: admin/tab-dropins.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:217 msgid "Current dropin folder: " msgstr "" -#: admin/tab-dropins.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:218 msgid "" "You can change location of the dropin folder using the " "wpmem_dropin_folder filter." msgstr "" -#: admin/tab-dropins.php:269 -msgid "Name" -msgstr "" - -#: admin/tab-dropins.php:270 -msgid "File" -msgstr "" - -#: admin/tab-dropins.php:271 -msgid "Version" -msgstr "" - -#: admin/tab-dropins.php:272 -msgid "Description" -msgstr "" - -#: admin/tab-dropins.php:315 admin/tab-fields.php:597 -msgid "Save Settings" -msgstr "" - -#: admin/tab-emails.php:58 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:57 msgid "Email Messages" msgstr "Email Besked" -#: admin/tab-emails.php:61 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:60 msgid "You can customize the content of the emails sent by the plugin." msgstr "Du kan tilpasse indholdet af emails sendt fra denne plugin" -#: admin/tab-emails.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:62 msgid "A list of shortcodes is available here." msgstr "liste med shortcodes kan ses her." -#: admin/tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:69 msgid "Set a custom email address" msgstr "Indsæt en gyldig Email-adresse" -#: admin/tab-emails.php:71 admin/tab-emails.php:75 admin/tab-emails.php:85 -#: admin/tab-fields.php:179 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 msgid "(optional)" msgstr "(obligatorisk)" -#: admin/tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:73 msgid "Set a custom email name" msgstr "Skriv dit email navn her" -#: admin/tab-emails.php:85 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 msgid "Email Signature" msgstr "Email underskrift" -#: admin/tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 msgid "Update Emails" msgstr "Opdater Emails" -#: admin/tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 msgid "WP-Members emails were updated" msgstr "WP-Members emails er opdateret" -#: admin/tab-fields.php:113 inc/class-wp-members.php:1207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 +#: includes/class-wp-members.php:1498 msgid "No fields selected for deletion" msgstr "" -#: admin/tab-fields.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:95 msgid "Are you sure you want to delete the following fields?" msgstr "" -#: admin/tab-fields.php:141 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:122 msgid "Fields deleted" msgstr "" -#: admin/tab-fields.php:155 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:136 msgid "Field Manager Documentation" msgstr "" -#: admin/tab-fields.php:180 admin/tab-fields.php:322 -#: inc/class-wp-members-user-profile.php:138 inc/deprecated.php:385 -#: inc/deprecated.php:646 inc/wp-registration.php:57 -#: inc/wp-registration.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/class-wp-members-forms.php:1626 +#: includes/class-wp-members-forms.php:1803 +#: includes/class-wp-members-user-profile.php:144 msgid "(required)" msgstr "(pÃ¥krævet)" -#: admin/tab-fields.php:185 admin/tab-fields.php:407 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 msgid "Edit Field" msgstr "" -#: admin/tab-fields.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 msgid "Add a Field" msgstr "" -#: admin/tab-fields.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 msgid "Field Label" msgstr "Felt Etiket" -#: admin/tab-fields.php:192 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: admin/tab-fields.php:195 admin/tab-fields.php:547 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: admin/tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: admin/tab-fields.php:205 admin/tab-fields.php:548 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Felt Type" -#: admin/tab-fields.php:211 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 msgid "text" msgstr "Tekst" -#: admin/tab-fields.php:212 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 msgid "email" msgstr "" -#: admin/tab-fields.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "textarea" msgstr "Tekstfelt" -#: admin/tab-fields.php:214 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "checkbox" msgstr "Markeringsboks" -#: admin/tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "multiple checkbox" msgstr "" -#: admin/tab-fields.php:216 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "select (dropdown)" msgstr "" -#: admin/tab-fields.php:217 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple select" msgstr "" -#: admin/tab-fields.php:218 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "radio group" msgstr "" -#: admin/tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "password" msgstr "Kodeord" -#: admin/tab-fields.php:220 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "image" msgstr "" -#: admin/tab-fields.php:221 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "file" msgstr "" -#: admin/tab-fields.php:222 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "url" msgstr "" -#: admin/tab-fields.php:223 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "number" msgstr "" -#: admin/tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "date" msgstr "" -#: admin/tab-fields.php:225 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "hidden" msgstr "" -#: admin/tab-fields.php:227 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "membership" msgstr "" -#: admin/tab-fields.php:233 admin/tab-fields.php:549 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Vis?" -#: admin/tab-fields.php:237 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 msgid "This field is always displayed" msgstr "" -#: admin/tab-fields.php:242 admin/tab-fields.php:550 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 msgid "Required?" msgstr "Obligatorisk?" -#: admin/tab-fields.php:246 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 msgid "This field is always required" msgstr "" -#: admin/tab-fields.php:252 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 msgid "Allow HTML?" msgstr "" -#: admin/tab-fields.php:259 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 msgid "Placeholder" msgstr "" -#: admin/tab-fields.php:267 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 msgid "Pattern" msgstr "" -#: admin/tab-fields.php:273 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 msgid "Title" msgstr "" -#: admin/tab-fields.php:282 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 msgid "Minimum Value" msgstr "" -#: admin/tab-fields.php:286 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Maximum Value" msgstr "" -#: admin/tab-fields.php:294 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 msgid "Rows" msgstr "" -#: admin/tab-fields.php:298 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Columns" msgstr "" -#: admin/tab-fields.php:306 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 msgid "Accepted file types:" msgstr "" -#: admin/tab-fields.php:311 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: admin/tab-fields.php:318 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 msgid "Checked by default?" msgstr "Markering?" -#: admin/tab-fields.php:322 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 msgid "Stored value if checked:" msgstr "" -#: admin/tab-fields.php:343 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 msgid "Stored values delimiter:" msgstr "" -#: admin/tab-fields.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 msgid "Values (Displayed|Stored):" msgstr "" -#: admin/tab-fields.php:377 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 msgid "Options should be Option Name|option_value," msgstr "Valg skal skrives Valg Navn|valg_værdi," -#: admin/tab-fields.php:381 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 msgid "Visit plugin site for more information" msgstr "Besøg Plugin Site for mere information" -#: admin/tab-fields.php:388 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Value" msgstr "" -#: admin/tab-fields.php:407 admin/tab-fields.php:674 admin/tab-fields.php:675 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 msgid "Add Field" msgstr "" -#: admin/tab-fields.php:409 admin/tab-fields.php:868 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 msgid "Return to Fields Table" msgstr "" -#: admin/tab-fields.php:449 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 msgid "Drag and drop to reorder fields" msgstr "" -#: admin/tab-fields.php:455 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 msgid "Registration Date" msgstr "" -#: admin/tab-fields.php:456 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 msgid "Active" msgstr "Aktiver" -#: admin/tab-fields.php:457 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 msgid "Registration IP" msgstr "IP @ registration" -#: admin/tab-fields.php:458 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 msgid "Subscription Type" msgstr "" -#: admin/tab-fields.php:460 admin/user-export.php:58 -msgid "User ID" -msgstr "" - -#: admin/tab-fields.php:493 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 msgid "Manage Fields" msgstr "Administrer Felter" -#: admin/tab-fields.php:532 -msgid "delete" -msgstr "" - -#: admin/tab-fields.php:546 -msgid "Display Label" -msgstr "" - -#: admin/tab-fields.php:552 -msgid "Users Screen" -msgstr "" - -#: admin/tab-fields.php:553 -msgid "Users Search" -msgstr "" - -#: admin/tab-fields.php:555 -msgid "Sort" -msgstr "" - -#: admin/tab-fields.php:596 -msgid "Delete Selected" -msgstr "" - -#: admin/tab-fields.php:738 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 msgid "WP-Members fields were updated" msgstr "WP-Members felter er opdateret" -#: admin/tab-fields.php:760 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 msgid "Field Label is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:761 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:763 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: admin/tab-fields.php:770 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 msgid "A field with that meta key already exists" msgstr "" -#: admin/tab-fields.php:775 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 #, php-format msgid "" "Sorry, \"%s\" is a
    מונח שמור. השדה ×œ× " "התווסף." -#: admin/tab-fields.php:816 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:659 msgid "Checked value is required for checkboxes. Nothing was updated." msgstr "ערך מסומן ×”×•× ×—×•×‘×” עבור תיבות סימון. ×©×•× ×“×‘×¨ ×œ× ×¢×•×“×›×Ÿ." -#: admin/tab-fields.php:847 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:690 msgid "A value is required for hidden fields. Nothing was updated." msgstr "" -#: admin/tab-fields.php:854 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:697 #, php-format msgid "%s was added" msgstr "" -#: admin/tab-fields.php:867 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:710 #, php-format msgid "%s was updated" msgstr "" -#: admin/tab-fields.php:909 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:753 msgid "Form field order updated." msgstr "" -#: admin/tab-options.php:60 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:56 #, php-format msgid "%sChange%s or %sFilter%s this address" msgstr "" -#: admin/tab-options.php:61 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:57 #, php-format msgid "See the %sUsers Guide on plugin options%s." msgstr "" -#: admin/tab-options.php:66 -msgid "Posts" -msgstr "" - -#: admin/tab-options.php:67 admin/tab-options.php:215 -msgid "Pages" -msgstr "עמודי×" - -#: admin/tab-options.php:94 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:90 msgid "Manage Options" msgstr "ניהול ×”×פשרויות" -#: admin/tab-options.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:94 msgid "Content" msgstr "" -#: admin/tab-options.php:109 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:105 msgid "Content Blocking" msgstr "" -#: admin/tab-options.php:113 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:109 msgid "Do not block" msgstr "×œ× ×œ×—×¡×•×" -#: admin/tab-options.php:127 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:123 msgid "Show Excerpts" msgstr "להציג תקצירי×" -#: admin/tab-options.php:128 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:124 msgid "Show Login Form" msgstr "להציג טופס כניסה" -#: admin/tab-options.php:129 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:125 msgid "Show Registration Form" msgstr "להציג טופס הרשמה" -#: admin/tab-options.php:130 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:126 msgid "Auto Excerpt:" msgstr "תקציר ×וטומטי:" -#: admin/tab-options.php:152 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:148 msgid "Number of words in excerpt:" msgstr "מספר ×”×ž×™×œ×™× ×‘×ª×§×¦×™×¨:" -#: admin/tab-options.php:153 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:149 msgid "Custom read more link (optional):" msgstr "" -#: admin/tab-options.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:163 msgid "Time-based expiration" msgstr "תפוגה מבוססת זמן" -#: admin/tab-options.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:163 msgid "Allows for access to expire" msgstr "מ×פשר לגישה לפוג" -#: admin/tab-options.php:168 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:164 msgid "Trial period" msgstr "תקופת ניסיון" -#: admin/tab-options.php:168 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:164 msgid "Allows for a trial period" msgstr "מ×פשר תקופת ניסיון" -#: admin/tab-options.php:170 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:166 msgid "Subscription Settings" msgstr "" -#: admin/tab-options.php:180 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:176 msgid "Other Settings" msgstr "" -#: admin/tab-options.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:182 +msgid "Activation" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:182 +msgid "" +"Send initial activation link and password reset link instead of new " +"password. (Requires additional configuration)" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:183 msgid "Enable Products" msgstr "" -#: admin/tab-options.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:183 msgid "Enables creation of different membership products" msgstr "" -#: admin/tab-options.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:184 msgid "Clone menus" msgstr "" -#: admin/tab-options.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:184 msgid "Enables logged in menus" msgstr "" -#: admin/tab-options.php:188 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:185 msgid "Notify admin" msgstr "להודיע למנהל" -#: admin/tab-options.php:188 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:185 #, php-format msgid "Notify %s for each new registration? %s" msgstr "להודיע ל %s מנהל על כל הרשמה חדשה? %s" -#: admin/tab-options.php:189 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:186 msgid "Moderate registration" msgstr "בקרת הרשמה" -#: admin/tab-options.php:189 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:186 msgid "Holds new registrations for admin approval" msgstr "עוצר הרשמת ×ž×©×ª×ž×©×™× ×—×“×©×™× ×¢×“ ל×ישור מנהל" -#: admin/tab-options.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:187 msgid "Ignore warning messages" msgstr "×œ×”×ª×¢×œ× ×ž×”×•×“×¢×•×ª ×זהרה" -#: admin/tab-options.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:187 msgid "Ignores WP-Members warning messages in the admin panel" msgstr "×œ×”×ª×¢×œ× ×ž×”×•×“×¢×•×ª ×זהרה של וורדפרס-×—×‘×¨×™× ×‘×œ×•×— הבקרה" -#: admin/tab-options.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:198 msgid "Attribution" msgstr "ייחוס" -#: admin/tab-options.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:200 msgid "" "Attribution is appreciated! Display \"powered by\" link on register form?" msgstr "ייחוס תתקבל בברכה! להציג \"מופעל על ידי\" על הקישור בטופס ההרשמה?" -#: admin/tab-options.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:203 msgid "Enable CAPTCHA" msgstr "הפעלת קוד ×ימות" -#: admin/tab-options.php:211 -msgid "reCAPTCHA" +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:208 +msgid "reCAPTCHA v2" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:209 +msgid "reCAPTCHA v3" msgstr "" -#: admin/tab-options.php:212 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:210 msgid "Really Simple CAPTCHA" msgstr "" -#: admin/tab-options.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:217 msgid "Login Page:" msgstr "עמוד כניסה" -#: admin/tab-options.php:222 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:220 msgid "Specify a login page (optional)" msgstr "× × ×œ×¦×™×™×Ÿ עמוד כניסה (רשות)" -#: admin/tab-options.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:229 msgid "Register Page:" msgstr "עמוד ההרשמה" -#: admin/tab-options.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:232 msgid "For creating a register link in the login form" msgstr "כדי ליצור קישור להרשמה בטופס הכניסה" -#: admin/tab-options.php:243 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:241 msgid "User Profile Page:" msgstr "עמוד פרופיל המשתמש:" -#: admin/tab-options.php:246 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 msgid "For creating a forgot password link in the login form" msgstr "כדי ליצור קישור ל×יפוס סיסמה בטופס הכניסה" -#: admin/tab-options.php:252 admin/tab-options.php:254 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:250 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:252 msgid "Stylesheet" msgstr "גיליון עיצוב" -#: admin/tab-options.php:263 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:261 msgid "Custom Stylesheet:" msgstr "גיליון עיצוב מות×× ×ישית:" -#: admin/tab-options.php:268 admin/tab-options.php:295 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:266 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:293 msgid "Update Settings" msgstr "עדכן ההגדרות" -#: admin/tab-options.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:274 msgid "Custom Post Types" msgstr "סוגי פוסט" -#: admin/tab-options.php:282 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:280 msgid "Add to WP-Members Settings" msgstr "" -#: admin/tab-options.php:312 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:296 +msgid "" +"Please keep in mind that Custom Post Types are \"custom\" and therefore, not " +"all of them will function exactly the same way. WP-Members will certainly " +"work with any post type that operate like a post or a page; but you will " +"need to review any custom post type added to determine that it functions the " +"way you expect." +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:315 msgid "Close" msgstr "" -#: admin/tab-options.php:330 admin/tab-options.php:331 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:333 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:334 msgid "WP-Members Settings" msgstr "" -#: admin/tab-options.php:332 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:335 msgid "" "The following is your WP-Members settings information if needed for support." msgstr "" -#: admin/tab-options.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:362 msgid "Click to Copy" msgstr "" -#: admin/tab-options.php:435 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:442 msgid "Custom Post Type settings were updated" msgstr "הגדרות סוגי פוסט עודכנו" -#: admin/tab-options.php:551 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:551 msgid "WP-Members settings were updated" msgstr "הגדרות וורדפרס-×—×‘×¨×™× ×¢×•×“×›× ×•" -#: admin/tab-options.php:621 admin/tab-options.php:651 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:623 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:654 msgid "USE CUSTOM URL BELOW" msgstr "להשתמש בכתובת URL מות×מת ×ישית להלן" -#: admin/tab-options.php:640 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:643 msgid "Select a page" msgstr "בחירת עמוד" -#: admin/user-export.php:59 inc/class-wp-members.php:1232 -#: inc/class-wp-members.php:1255 -msgid "Username" -msgstr "×©× ×ž×©×ª×ž×©" - -#: admin/user-export.php:65 -msgid "Activated?" -msgstr "פעיל?" - -#: admin/user-export.php:68 admin/users.php:317 -msgid "Subscription" -msgstr "מנוי" - -#: admin/user-export.php:71 -msgid "Registered" -msgstr "רשו×" - -#: admin/user-export.php:72 -msgid "IP" -msgstr "כתובת IP" - -#: admin/user-export.php:135 -msgid "Yes" -msgstr "כן" - -#: admin/user-export.php:135 admin/users.php:399 -msgid "No" -msgstr "ל×" - -#: admin/users.php:49 admin/users.php:54 admin/users.php:80 -msgid "Activate" -msgstr "הפעלה" - -#: admin/users.php:50 admin/users.php:55 admin/users.php:83 -msgid "Deactivate" +#: includes/admin/tabs/class-wp-members-dropins-table.php:70 +msgid "Name" msgstr "" -#: admin/users.php:52 admin/users.php:57 -msgid "Export" -msgstr "יצו×" - -#: admin/users.php:58 admin/users.php:109 -msgid "Export All Users" -msgstr "×™×¦×•× ×›×œ המשתמשי×" - -#: admin/users.php:158 -#, php-format -msgid "%s users activated" +#: includes/admin/tabs/class-wp-members-dropins-table.php:71 +msgid "Enabled" msgstr "" -#: admin/users.php:158 -#, php-format -msgid "%s users deactivated" +#: includes/admin/tabs/class-wp-members-dropins-table.php:72 +msgid "File" msgstr "" -#: admin/users.php:161 -msgid "No users selected" +#: includes/admin/tabs/class-wp-members-dropins-table.php:73 +msgid "Version" msgstr "" -#: admin/users.php:181 -#, php-format -msgid "%s activated" +#: includes/admin/tabs/class-wp-members-dropins-table.php:74 +#: includes/walkers/class-wp-members-walker-nav-menu.php:186 +msgid "Description" msgstr "" -#: admin/users.php:186 -#, php-format -msgid "%s deactivated" +#: includes/admin/tabs/class-wp-members-dropins-table.php:117 +#: includes/admin/tabs/class-wp-members-fields-table.php:108 +msgid "Save Settings" msgstr "" -#: admin/users.php:190 -msgid "That user is already active" +#: includes/admin/tabs/class-wp-members-fields-table.php:43 +msgid "delete" msgstr "" -#: admin/users.php:315 -msgid "Pending" +#: includes/admin/tabs/class-wp-members-fields-table.php:57 +msgid "Display Label" msgstr "" -#: admin/users.php:316 -msgid "Trial" +#: includes/admin/tabs/class-wp-members-fields-table.php:61 +msgid "Required" msgstr "" -#: admin/users.php:318 -msgid "Expired" -msgstr "" +#: includes/admin/tabs/class-wp-members-fields-table.php:63 +msgid "Users Screen" +msgstr "מסך המשתמשי×" -#: admin/users.php:321 -msgid "Not Activated" +#: includes/admin/tabs/class-wp-members-fields-table.php:64 +msgid "Users Search" msgstr "" -#: admin/users.php:322 -msgid "Deactivated" +#: includes/admin/tabs/class-wp-members-fields-table.php:66 +msgid "Sort" msgstr "" -#: admin/users.php:324 -msgid "Not Exported" +#: includes/admin/tabs/class-wp-members-fields-table.php:107 +msgid "Delete Selected" msgstr "" -#: inc/api.php:304 inc/class-wp-members.php:1296 +#: includes/api/api.php:328 includes/class-wp-members.php:1588 msgid "log in" msgstr "כניסה" -#: inc/api.php:305 +#: includes/api/api.php:329 msgid "log out" msgstr "" -#: inc/class-wp-members-forms.php:961 inc/class-wp-members.php:1247 -#: inc/wp-registration.php:77 +#: includes/class-wp-members-activation-link.php:21 +msgid "Click to activate your account: " +msgstr "" + +#: includes/class-wp-members-activation-link.php:22 +msgid "Thank you for activating your account." +msgstr "" + +#: includes/class-wp-members-activation-link.php:23 +msgid "Activation key was expired or invalid" +msgstr "" + +#: includes/class-wp-members-captcha.php:217 includes/deprecated - Copy.php:500 +#: includes/deprecated.php:501 +msgid "You have entered an incorrect code value. Please try again." +msgstr "הזנת ערך קוד שגוי. × × × ×¡×” שוב." + +#: includes/class-wp-members-forms.php:1048 +#: includes/class-wp-members-forms.php:1646 includes/class-wp-members.php:1538 #, php-format msgid "Please indicate that you agree to the %s Terms of Service %s" msgstr "" -#: inc/class-wp-members-forms.php:962 inc/class-wp-members.php:1198 -#: inc/wp-registration.php:78 +#: includes/class-wp-members-forms.php:1049 +#: includes/class-wp-members-forms.php:1647 includes/class-wp-members.php:1489 msgid "TOS" msgstr "תנ××™ השימוש" -#: inc/class-wp-members-forms.php:962 inc/wp-registration.php:78 -#: wp-members-tos.php:23 +#: includes/class-wp-members-forms.php:1049 +#: includes/class-wp-members-forms.php:1647 templates/tos.php:20 msgid "Terms of Service" msgstr "תנ××™ שימוש" -#: inc/class-wp-members-products.php:212 -msgid "Product" +#: includes/class-wp-members-forms.php:1868 +#: includes/class-wp-members-user-profile.php:473 +msgid "Activate this user?" +msgstr "ל×שר ×ת המשתמש ×”×–×”?" + +#: includes/class-wp-members-menus.php:131 +msgid "Display" msgstr "" -#: inc/class-wp-members-products.php:213 -msgid "Products" +#: includes/class-wp-members-menus.php:139 +msgid "Logged In Users" msgstr "" -#: inc/class-wp-members-products.php:218 -msgid "Memberships" +#: includes/class-wp-members-menus.php:146 +msgid "Logged Out Users" +msgstr "" + +#: includes/class-wp-members-menus.php:153 +msgid "All Users" +msgstr "" + +#: includes/class-wp-members-menus.php:167 +#, php-format +msgid "%sAdd membership products%s to restrict menu to a membership" +msgstr "" + +#: includes/class-wp-members-menus.php:169 +msgid "Restrict menu item to a membership product" +msgstr "" + +#: includes/class-wp-members-products.php:302 +msgid "Product" +msgstr "" + +#: includes/class-wp-members-products.php:303 +msgid "Products" msgstr "" -#: inc/class-wp-members-products.php:219 +#: includes/class-wp-members-products.php:309 #, php-format msgid "All %s" msgstr "" -#: inc/class-wp-members-products.php:220 +#: includes/class-wp-members-products.php:310 #, php-format msgid "Add New %s" msgstr "" -#: inc/class-wp-members-products.php:221 +#: includes/class-wp-members-products.php:311 msgid "Add New" msgstr "" -#: inc/class-wp-members-products.php:222 +#: includes/class-wp-members-products.php:312 #, php-format msgid "New %s" msgstr "" -#: inc/class-wp-members-products.php:223 +#: includes/class-wp-members-products.php:313 #, php-format msgid "Edit %s" msgstr "" -#: inc/class-wp-members-products.php:224 +#: includes/class-wp-members-products.php:314 #, php-format msgid "Update %s" msgstr "" -#: inc/class-wp-members-products.php:225 inc/class-wp-members-products.php:226 +#: includes/class-wp-members-products.php:315 +#: includes/class-wp-members-products.php:316 #, php-format msgid "View %s" msgstr "" -#: inc/class-wp-members-products.php:227 +#: includes/class-wp-members-products.php:317 #, php-format msgid "Search %s" msgstr "" -#: inc/class-wp-members-products.php:228 +#: includes/class-wp-members-products.php:318 msgid "Not found" msgstr "" -#: inc/class-wp-members-products.php:229 +#: includes/class-wp-members-products.php:319 msgid "Not found in Trash" msgstr "" -#: inc/class-wp-members-products.php:230 +#: includes/class-wp-members-products.php:320 msgid "Insert into item" msgstr "" -#: inc/class-wp-members-products.php:231 +#: includes/class-wp-members-products.php:321 #, php-format msgid "Save %s Details" msgstr "" -#: inc/class-wp-members-products.php:234 +#: includes/class-wp-members-products.php:324 msgid "Membership Product" msgstr "" -#: inc/class-wp-members-products.php:235 +#: includes/class-wp-members-products.php:325 msgid "WP-Members Membership Products" msgstr "" -#: inc/class-wp-members-shortcodes.php:135 +#: includes/class-wp-members-pwd-reset.php:31 +#: includes/class-wp-members-pwd-reset.php:32 +msgid "" +"Sorry, no password reset key was found. Please check your email and try " +"again." +msgstr "" + +#: includes/class-wp-members-pwd-reset.php:33 +msgid "Sorry, the password reset key is expired." +msgstr "" + +#: includes/class-wp-members-shortcodes.php:147 msgid "" "This is a generic message to display the form message dialog in the " "Customizer." msgstr "" -#: inc/class-wp-members-shortcodes.php:146 inc/class-wp-members.php:1275 -#: inc/deprecated.php:180 +#: includes/class-wp-members-shortcodes.php:158 +#: includes/class-wp-members.php:1566 includes/deprecated - Copy.php:695 msgid "There was an error with the CAPTCHA form." msgstr "היתה שגי××” בטופס קוד ×”×ימות." -#: inc/class-wp-members-shortcodes.php:676 +#: includes/class-wp-members-shortcodes.php:717 msgid "Click here to log out." msgstr "× × ×œ×œ×—×•×¥ ×›×ן כדי להתנתק." -#: inc/class-wp-members-shortcodes.php:745 inc/class-wp-members.php:1249 -#: inc/class-wp-members.php:1298 inc/wp-registration.php:366 +#: includes/class-wp-members-shortcodes.php:786 +#: includes/class-wp-members-user.php:172 includes/class-wp-members.php:1540 +#: includes/class-wp-members.php:1590 msgid "Register" msgstr "הרשמה" -#: inc/class-wp-members-shortcodes.php:748 inc/class-wp-members.php:1217 +#: includes/class-wp-members-shortcodes.php:789 +#: includes/class-wp-members.php:1508 msgid "Log In" msgstr "כניסה" -#: inc/class-wp-members-user-profile.php:38 inc/deprecated.php:315 +#: includes/class-wp-members-user-profile.php:38 msgid "WP-Members Additional Fields" msgstr "שדות × ×•×¡×¤×™× ×©×œ וורדפרס-חברי×" -#: inc/class-wp-members-user-profile.php:38 inc/deprecated.php:589 +#: includes/class-wp-members-user-profile.php:38 msgid "Additional Information" msgstr "מידע נוסף" -#: inc/class-wp-members-user-profile.php:448 inc/wp-registration.php:296 -msgid "Activate this user?" -msgstr "ל×שר ×ת המשתמש ×”×–×”?" - -#: inc/class-wp-members-user-profile.php:453 +#: includes/class-wp-members-user-profile.php:463 msgid "Reactivate this user?" msgstr "ל×שר מחדש ×ת המשתמש ×”×–×”?" -#: inc/class-wp-members-user-profile.php:458 +#: includes/class-wp-members-user-profile.php:468 msgid "Deactivate this user?" msgstr "לבטל ×ת המשתמש ×”×–×”?" -#: inc/class-wp-members-user-profile.php:507 +#: includes/class-wp-members-user-profile.php:522 msgid "IP @ registration" msgstr "כתובת IP והרשמה" -#: inc/class-wp-members-user-profile.php:526 -msgid "Product Access" -msgstr "" - -#: inc/class-wp-members-user-profile.php:534 -msgid "Enable" -msgstr "" - -#: inc/class-wp-members-user-profile.php:535 -msgid "Disable" -msgstr "" - -#: inc/class-wp-members-user-profile.php:541 -msgid "Expires:" -msgstr "" - -#: inc/class-wp-members-user-profile.php:543 -msgid "Enabled" -msgstr "" +#: includes/class-wp-members-user.php:199 includes/class-wp-members.php:1565 +msgid "There was an error processing the form." +msgstr "×ירעה שגי××” בעיבוד הטופס." -#: inc/class-wp-members-user.php:712 +#: includes/class-wp-members-user.php:1118 msgid "ERROR: User has not been activated." msgstr "שגי××”: המשתמש ×ינו פעיל." -#: inc/class-wp-members-widget.php:24 +#: includes/class-wp-members-widget.php:24 msgid "Displays the WP-Members sidebar login." msgstr "מציג ×ת הכניסה של וורדפרס-×—×‘×¨×™× ×‘×¡×¨×’×œ הצד" -#: inc/class-wp-members-widget.php:39 inc/class-wp-members-widget.php:82 +#: includes/class-wp-members-widget.php:39 +#: includes/class-wp-members-widget.php:82 msgid "Login Status" msgstr "מצב ההתחברות" -#: inc/class-wp-members-widget.php:46 +#: includes/class-wp-members-widget.php:46 msgid "Title:" msgstr "כותרת:" -#: inc/class-wp-members-widget.php:50 +#: includes/class-wp-members-widget.php:50 msgid "Redirect to (optional):" msgstr "להפנות ל (רשות):" -#: inc/class-wp-members.php:1183 +#: includes/class-wp-members.php:1028 includes/class-wp-members.php:1038 +msgid "You must be logged in to view this content." +msgstr "" + +#: includes/class-wp-members.php:1044 +msgid "The page you are looking for does not exist" +msgstr "" + +#: includes/class-wp-members.php:1436 +#, php-format +msgid "" +"You have a linked page in the WP-Members page settings that corresponds to a " +"post ID that no longer exists. Please %s review and update the %s page " +"settings %s." +msgstr "" + +#: includes/class-wp-members.php:1474 msgid "First Name" msgstr "ש×" -#: inc/class-wp-members.php:1184 +#: includes/class-wp-members.php:1475 msgid "Last Name" msgstr "×©× ×ž×©×¤×—×”" -#: inc/class-wp-members.php:1185 +#: includes/class-wp-members.php:1476 msgid "Address 1" msgstr "כתובת" -#: inc/class-wp-members.php:1186 +#: includes/class-wp-members.php:1477 msgid "Address 2" msgstr "כתובת 2" -#: inc/class-wp-members.php:1187 +#: includes/class-wp-members.php:1478 msgid "City" msgstr "יישוב" -#: inc/class-wp-members.php:1188 +#: includes/class-wp-members.php:1479 msgid "State" msgstr "מדינה" -#: inc/class-wp-members.php:1189 +#: includes/class-wp-members.php:1480 msgid "Zip" msgstr "מיקוד" -#: inc/class-wp-members.php:1190 +#: includes/class-wp-members.php:1481 msgid "Country" msgstr "×רץ" -#: inc/class-wp-members.php:1191 +#: includes/class-wp-members.php:1482 msgid "Day Phone" msgstr "טלפון" -#: inc/class-wp-members.php:1192 inc/class-wp-members.php:1233 +#: includes/class-wp-members.php:1483 includes/class-wp-members.php:1524 msgid "Email" msgstr "×ימייל" -#: inc/class-wp-members.php:1193 +#: includes/class-wp-members.php:1484 msgid "Confirm Email" msgstr "×ישור ×”×ימייל" -#: inc/class-wp-members.php:1194 +#: includes/class-wp-members.php:1485 msgid "Website" msgstr "×תר" -#: inc/class-wp-members.php:1195 +#: includes/class-wp-members.php:1486 msgid "Biographical Info" msgstr "מידע ביוגרפי" -#: inc/class-wp-members.php:1196 inc/class-wp-members.php:1216 -#: inc/class-wp-members.php:1295 +#: includes/class-wp-members.php:1487 includes/class-wp-members.php:1507 +#: includes/class-wp-members.php:1587 msgid "Password" msgstr "סיסמה" -#: inc/class-wp-members.php:1197 +#: includes/class-wp-members.php:1488 msgid "Confirm Password" msgstr "×ישור הסיסמה" -#: inc/class-wp-members.php:1208 +#: includes/class-wp-members.php:1499 msgid "You are not logged in." msgstr "עוד ×œ× × ×›× ×¡×ª." -#: inc/class-wp-members.php:1214 +#: includes/class-wp-members.php:1505 msgid "Existing Users Log In" msgstr "כניסת ×ž×©×ª×ž×©×™× ×¨×©×•×ž×™×" -#: inc/class-wp-members.php:1215 inc/class-wp-members.php:1294 +#: includes/class-wp-members.php:1506 includes/class-wp-members.php:1586 msgid "Username or Email" msgstr "" -#: inc/class-wp-members.php:1218 +#: includes/class-wp-members.php:1509 msgid "Remember Me" msgstr "זכור ×ותי" -#: inc/class-wp-members.php:1219 +#: includes/class-wp-members.php:1510 msgid "Forgot password?" msgstr "ל×פס ×ת הסיסמה?" -#: inc/class-wp-members.php:1220 +#: includes/class-wp-members.php:1511 msgid "Click here to reset" msgstr "× × ×œ×œ×—×•×¥ ×›×ן כדי ל×פס" -#: inc/class-wp-members.php:1221 +#: includes/class-wp-members.php:1512 msgid "New User?" msgstr "משתמש חדש?" -#: inc/class-wp-members.php:1222 +#: includes/class-wp-members.php:1513 msgid "Click here to register" msgstr "× × ×œ×œ×—×•×¥ ×›×ן כדי להירש×" -#: inc/class-wp-members.php:1225 inc/class-wp-members.php:1279 +#: includes/class-wp-members.php:1516 includes/class-wp-members.php:1571 msgid "Change Password" msgstr "החלפת סיסמה" -#: inc/class-wp-members.php:1226 +#: includes/class-wp-members.php:1517 msgid "New password" msgstr "סיסמה חדשה" -#: inc/class-wp-members.php:1227 +#: includes/class-wp-members.php:1518 msgid "Confirm new password" msgstr "×ישור הסיסמה החדשה" -#: inc/class-wp-members.php:1228 +#: includes/class-wp-members.php:1519 msgid "Update Password" msgstr "עדכון הסיסמה" -#: inc/class-wp-members.php:1231 +#: includes/class-wp-members.php:1522 msgid "Reset Forgotten Password" msgstr "×יפוס סיסמה שנשכחה" -#: inc/class-wp-members.php:1234 +#: includes/class-wp-members.php:1525 msgid "Reset Password" msgstr "×יפוס סיסמה" -#: inc/class-wp-members.php:1235 +#: includes/class-wp-members.php:1526 msgid "Forgot username?" msgstr "שכחת ×ת ×©× ×”×ž×©×ª×ž×©?" -#: inc/class-wp-members.php:1236 +#: includes/class-wp-members.php:1527 msgid "Click here" msgstr "ללחוץ ×›×ן" -#: inc/class-wp-members.php:1239 inc/class-wp-members.php:1241 +#: includes/class-wp-members.php:1530 includes/class-wp-members.php:1532 msgid "Retrieve username" msgstr "שחזור ×©× ×”×ž×©×ª×ž×©" -#: inc/class-wp-members.php:1240 +#: includes/class-wp-members.php:1531 msgid "Email Address" msgstr "כתובת ×ימייל" -#: inc/class-wp-members.php:1244 +#: includes/class-wp-members.php:1535 msgid "New User Registration" msgstr "×¨×™×©×•× ×ž×©×ª×ž×© חדש" -#: inc/class-wp-members.php:1245 +#: includes/class-wp-members.php:1536 msgid "Choose a Username" msgstr "בחירת ×©× ×ž×©×ª×ž×©" -#: inc/class-wp-members.php:1246 +#: includes/class-wp-members.php:1537 msgid "Input the code:" msgstr "להזין ×ת הקוד:" -#: inc/class-wp-members.php:1248 +#: includes/class-wp-members.php:1539 msgid "Reset Form" msgstr "×יפוס הטופס" -#: inc/class-wp-members.php:1251 +#: includes/class-wp-members.php:1542 msgid "Required field" msgstr "שדה חובה" -#: inc/class-wp-members.php:1254 inc/deprecated.php:226 +#: includes/class-wp-members.php:1545 includes/deprecated - Copy.php:741 msgid "Edit Your Information" msgstr "עריכת ×”×¤×¨×˜×™× ×©×œ×š" -#: inc/class-wp-members.php:1256 +#: includes/class-wp-members.php:1547 msgid "Update Profile" msgstr "עדכון הפרופיל" -#: inc/class-wp-members.php:1257 +#: includes/class-wp-members.php:1548 msgid "Update this file" msgstr "עדכון הקובץ ×”×–×”" -#: inc/class-wp-members.php:1260 +#: includes/class-wp-members.php:1551 msgid "Login Failed!" msgstr "הכניסה נכשלה!" -#: inc/class-wp-members.php:1261 +#: includes/class-wp-members.php:1552 msgid "You entered an invalid username or password." msgstr "הזנת ×©× ×ž×©×ª×ž×© ×ו סיסמה שגויי×." -#: inc/class-wp-members.php:1262 +#: includes/class-wp-members.php:1553 msgid "Click here to continue." msgstr "× × ×œ×œ×—×•×¥ ×›×ן כדי להמשיך" -#: inc/class-wp-members.php:1263 +#: includes/class-wp-members.php:1554 msgid "Password fields cannot be empty" msgstr "שדות הסיסמה ×”× ×©×“×•×ª חובה" -#: inc/class-wp-members.php:1264 +#: includes/class-wp-members.php:1555 msgid "Sorry, that email address was not found." msgstr "מצטערי×, כתובת ×”×ימייל הזו ××™× × ×”" -#: inc/class-wp-members.php:1265 +#: includes/class-wp-members.php:1556 #, php-format msgid "An email was sent to %s with your username." msgstr "×ימייל ×¢× ×©× ×”×ž×©×ª×ž×© שלך נשלח ל %s" -#: inc/class-wp-members.php:1266 +#: includes/class-wp-members.php:1557 #, php-format msgid "Sorry, %s is a required field." msgstr "מצטערי×, %s ×”×•× ×©×“×” חובה" -#: inc/class-wp-members.php:1267 +#: includes/class-wp-members.php:1558 msgid "You must enter a valid email address." msgstr "חובה להזין ×ימייל תקף" -#: inc/class-wp-members.php:1268 +#: includes/class-wp-members.php:1559 msgid "The username cannot include non-alphanumeric characters." msgstr "×©× ×”×ž×©×ª×ž×© ×ינו יכול לכלול ×ª×•×•×™× ×©××™× × ×לפ×-נומריי×." -#: inc/class-wp-members.php:1269 +#: includes/class-wp-members.php:1560 msgid "Sorry, username is a required field" msgstr "מצטערי×, ×©× ×”×ž×©×ª×ž×© ×”×•× ×©×“×” חובה" -#: inc/class-wp-members.php:1270 +#: includes/class-wp-members.php:1561 msgid "Passwords did not match." msgstr "הסיסמ×ות ×ינן תו×מות" -#: inc/class-wp-members.php:1271 +#: includes/class-wp-members.php:1562 msgid "Emails did not match." msgstr "כתובות ×”×ימייל ×ינן תו×מות" -#: inc/class-wp-members.php:1272 +#: includes/class-wp-members.php:1563 msgid "You must complete the CAPTCHA form." msgstr "חובה ×œ×”×©×œ×™× ×ת טופס קוד ×”×ימות." -#: inc/class-wp-members.php:1273 +#: includes/class-wp-members.php:1564 msgid "CAPTCHA was not valid." msgstr "קוד ×”×ימות ×ינו תקף" -#: inc/class-wp-members.php:1274 inc/register.php:52 -msgid "There was an error processing the form." -msgstr "×ירעה שגי××” בעיבוד הטופס." +#: includes/class-wp-members.php:1567 +#, php-format +msgid "" +"Sorry, you can only upload the following file types for the %s field: %s." +msgstr "" -#: inc/class-wp-members.php:1278 +#: includes/class-wp-members.php:1570 msgid "Edit My Information" msgstr "עריכת ×”×¤×¨×˜×™× ×©×œ×š" -#: inc/class-wp-members.php:1280 inc/class-wp-members.php:1283 -#: inc/class-wp-members.php:1285 inc/class-wp-members.php:1290 +#: includes/class-wp-members.php:1572 includes/class-wp-members.php:1575 +#: includes/class-wp-members.php:1577 includes/class-wp-members.php:1582 #, php-format msgid "You are logged in as %s" msgstr "×תה מחובר ×›- %s." -#: inc/class-wp-members.php:1281 -msgid "Click to log out." -msgstr "יצי××”" +#: includes/class-wp-members.php:1573 +msgid "Log out" +msgstr "" + +#: includes/class-wp-members.php:1574 +msgid "Edit profile" +msgstr "" -#: inc/class-wp-members.php:1282 +#: includes/class-wp-members.php:1574 msgid "Begin using the site." msgstr "×פשר להתחיל להשתמש ב×תר" -#: inc/class-wp-members.php:1284 +#: includes/class-wp-members.php:1576 msgid "Click to log out" msgstr "ללחוץ כדי לצ×ת" -#: inc/class-wp-members.php:1286 +#: includes/class-wp-members.php:1578 msgid "click to log out" msgstr "ללחוץ כדי לצ×ת" -#: inc/class-wp-members.php:1287 +#: includes/class-wp-members.php:1579 msgid "Log Out" msgstr "" -#: inc/class-wp-members.php:1291 +#: includes/class-wp-members.php:1583 msgid "click here to log out" msgstr "ללחוץ ×›×ן כדי לצ×ת" -#: inc/class-wp-members.php:1292 +#: includes/class-wp-members.php:1584 msgid "Login Failed!
    You entered an invalid username or password." msgstr "הכניסה נכשלה!
    הזנת ×©× ×ž×©×ª×ž×© ×ו סיסמה שגויי×." -#: inc/class-wp-members.php:1297 +#: includes/class-wp-members.php:1589 msgid "Forgot?" msgstr "שכחת?" -#: inc/class-wp-members.php:1301 +#: includes/class-wp-members.php:1593 msgid "" "This content is restricted to site members. If you are an existing user, " "please log in. New users may register below." @@ -1773,39 +2009,39 @@ msgstr "" "תוכן ×–×” מוגבל לחברי ×”×תר. ×× ×תה משתמש ×§×™×™×, × × ×œ×”×™×›× ×¡. ×ž×©×ª×ž×©×™× ×—×“×©×™× " "×™×›×•×œ×™× ×œ×”×™×¨×©× ×œ×”×œ×Ÿ." -#: inc/class-wp-members.php:1302 +#: includes/class-wp-members.php:1594 msgid "" "Congratulations! Your registration was successful.

    You may now " "log in using the password that was emailed to you." msgstr "" "יופי! ההרשמה הצליחה

    ×פשר להתחבר כעת ×¢× ×”×¡×™×¡×ž×” שנשלחה ×ליך ב×ימייל." -#: inc/class-wp-members.php:1305 +#: includes/class-wp-members.php:1597 msgid "Sorry, that username is taken, please try another." msgstr "מצטערי×, ×©× ×”×ž×©×ª×ž×© ×”×–×” תפוס, × × ×œ× ×¡×•×ª ×©× ×חר." -#: inc/class-wp-members.php:1306 +#: includes/class-wp-members.php:1598 msgid "" "Sorry, that email address already has an account.
    Please try another." msgstr "מצטערי×, כבר יש חשבון ×¢× ×”×ימייל ×”×–×”.
    × × ×œ× ×¡×•×ª ×חר." -#: inc/class-wp-members.php:1307 +#: includes/class-wp-members.php:1599 msgid "Your information was updated!" msgstr "המידע שלך עודכן!" -#: inc/class-wp-members.php:1310 +#: includes/class-wp-members.php:1602 msgid "Passwords did not match.

    Please try again." msgstr "הסיסמ×ות ×ינן תו×מות.

    × × ×œ× ×¡×•×ª שוב." -#: inc/class-wp-members.php:1311 +#: includes/class-wp-members.php:1603 msgid "Password successfully changed!" msgstr "הסיסמה הוחלפה בהצלחה!" -#: inc/class-wp-members.php:1312 +#: includes/class-wp-members.php:1604 msgid "Either the username or email address do not exist in our records." msgstr "×©× ×”×ž×©×ª×ž×© ×ו כתובת ×”×ימייל ×œ× ×§×™×™×ž×™× ×‘×¨×©×•×ž×•×ª שלנו." -#: inc/class-wp-members.php:1313 +#: includes/class-wp-members.php:1605 msgid "" "Password successfully reset!

    An email containing a new password " "has been sent to the email address on file for your account." @@ -1813,61 +2049,129 @@ msgstr "" "הסיסמה ×ופסה בהצלחה!

    ×ימייל ×¢× ×”×¡×™×¡×ž×” החדשה נשלח ×ל כתובת ×”×ימייל " "שלך." -#: inc/class-wp-members.php:1315 -msgid "Sorry, you do not have access to this content." +#: includes/class-wp-members.php:1607 +msgid "This content requires the following membership: " +msgstr "" + +#: includes/class-wp-members.php:1608 +msgid "This content requires one of the following memberships: " msgstr "" -#: inc/class-wp-members.php:1433 +#: includes/class-wp-members.php:1721 msgid "Show forms as logged out" msgstr "" -#: inc/class-wp-members.php:1442 +#: includes/class-wp-members.php:1730 msgid "Show form message dialog" msgstr "" -#: inc/class-wp-members.php:1538 +#: includes/class-wp-members.php:1838 msgid "(more…)" msgstr "עוד..." -#: inc/register.php:417 +#: includes/cli/class-wp-members-cli.php:17 +#, php-format +msgid "User: %s" +msgstr "" + +#: includes/deprecated - Copy.php:472 includes/deprecated.php:473 msgid "We were unable to validate the public key." msgstr "×œ× ×”×¦×œ×—× ×• ל×מת ×ת המפתח הציבורי." -#: inc/register.php:421 +#: includes/deprecated - Copy.php:476 includes/deprecated.php:477 msgid "We were unable to validate the private key." msgstr "הצלחנו ל×מת ×ת המפתח הפרטי." -#: inc/register.php:425 +#: includes/deprecated - Copy.php:480 includes/deprecated.php:481 msgid "The challenge parameter of the verify script was incorrect." msgstr "הפרמטר המ×תגר של קוד ×”×ימות ×”×™×” שגוי." -#: inc/register.php:429 +#: includes/deprecated - Copy.php:484 includes/deprecated.php:485 msgid "The CAPTCHA solution was incorrect." msgstr "פתרון קוד ×”×ימות ×”×™×” שגוי" -#: inc/register.php:433 +#: includes/deprecated - Copy.php:488 includes/deprecated.php:489 msgid "The parameters to verify were incorrect" msgstr "×”×¤×¨×ž×˜×¨×™× ×œ×ימות היו שגויי×" -#: inc/register.php:437 +#: includes/deprecated - Copy.php:492 includes/deprecated.php:493 msgid "" "reCAPTCHA API keys are tied to a specific domain name for security reasons." msgstr "מפתחות קוד ×”×ימות של-API reCAPTCHA קשורות לדומיין ספציפי מסיבות ×בטחה." -#: inc/register.php:441 +#: includes/deprecated - Copy.php:496 includes/deprecated.php:497 msgid "The reCAPTCHA server was not reached. Please try to resubmit." msgstr "השרת של קוד ×”×ימות reCAPTCHA ×ינו נגיש. × × ×œ× ×¡×•×ª שוב." -#: inc/register.php:445 -msgid "You have entered an incorrect code value. Please try again." -msgstr "הזנת ערך קוד שגוי. × × × ×¡×” שוב." +#. translators: %s: title of menu item which is invalid +#: includes/walkers/class-wp-members-walker-nav-menu.php:92 +#, php-format +msgid "%s (Invalid)" +msgstr "" + +#. translators: %s: title of menu item in draft status +#: includes/walkers/class-wp-members-walker-nav-menu.php:96 +#, php-format +msgid "%s (Pending)" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:123 +msgid "Move up" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:136 +msgid "Move down" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:138 +msgid "Edit Menu Item" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:149 +msgid "URL" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:156 +msgid "Navigation Label" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:162 +msgid "Title Attribute" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:169 +msgid "Open link in a new window/tab" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:174 +msgid "CSS Classes (optional)" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:180 +msgid "Link Relationship (XFN)" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:188 +msgid "" +"The description will be displayed in the menu if the current theme supports " +"it." +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:210 +#, php-format +msgid "Original: %s" +msgstr "" + +#: includes/walkers/class-wp-members-walker-nav-menu.php:223 +msgid "Remove" +msgstr "" -#: wp-members-tos.php:35 +#: templates/tos.php:32 #, php-format msgid "%sclose%s" msgstr "%sסגירה%s" -#: wp-members-tos.php:37 +#: templates/tos.php:34 #, php-format msgid "%sprint%s" msgstr "%sספרינט%s" @@ -1897,6 +2201,9 @@ msgstr "Chad Butler" msgid "http://butlerblog.com/" msgstr "http://butlerblog.com/" +#~ msgid "Click to log out." +#~ msgstr "יצי××”" + #~ msgid "You have set WP-Members to turn off the registration process" #~ msgstr "הגדרת ×ת וורדפרס-×—×‘×¨×™× ×œ×›×‘×•×ª ×ת תהליך ההרשמה" diff --git a/i18n/languages/wp-members-hi_IN.mo b/i18n/languages/wp-members-hi_IN.mo index 038562c2b1d56419ee56c221e9b3082cea92d08f..a680691908d4d4dba975811d057094d34f74e689 100644 GIT binary patch delta 1347 zcmXZcT}YEr7{Kx8HKVl9bZ)3wjhQo>v$Zw9Q&BT5zcO3uB)`p(WKc?=W!i=2>TUtm@i=qTDFNCKtEREdrZT` z3<*dIgQ5(P_2|WB>_fF+0h90>7GuPAJ-||oXI_oGk~S>GD|iIoViekJdVp^9Ft5T` zoWMK`+5#dj21`8HgPSu&aM5Wh>mnG@9lFRIjzV=Ydj`aslvFwb?`jy$0bxH$)+)kSc2RoARYz;EtjwlU!dC9LLJOli52L>ml(uy?B`Uq z@iZpl3O1rCU*tI+!*NV4piyxFW6@Qpm#z$roGsw|1anr2yebnRdGd$o4VbxCFHH&ZsdQl`=gTAm)l~10EXv=o zS(W+ifU0B(GzzguI;x)Ooplhm5B*dwF+V#&f*G2*NC*zbZco06ZY_Ois$F+>3p>EBOk%Y29X4(vS zo%jfUU|b{lR|Adwy~dx|gtH#KMh3q6#X)AgjD}{t)}#Da@v`nIZooJuMzmlEb1@13 zVGN}(wUTPSPiv!zv7ueR;DwGg+=hiCGfB}Klg;*qo@qe6!Qxbl4qk YyVGgjnUn8!&G@%2YMN`N#oATy9}IS_+5i9m delta 1372 zcmYM!Sx8h-9LMqBSXP#_$w->fRBE|QjiaWH+R&c4R--m4E`^vRS&^9pT_PWfHrgI~ zNurdBqG*bUs28!)m!O4GS|A|4hj9}A9(DWzDT{d&Zo)!bhuydae_{eI zO_HTJ28~HlBz9mBPoh~cf-yKPS@L5FM&LG_j;+WN9l~XJ3v2K@nstE`JHQ&OV7?2d zU?1k-K#C=$Gl)u+R^n>R#$$LHAE61b#VrxEj-om64o2d8Gy#4_CyrYv&BZu03HZ?j z+JI)=-ce5>#nLs4!88UhumwLN9Z|(1i6j)nwb+53_!P}XEgtEYLpqGJm>=|#JzhW) zK!B{+N^MB8>PAzcXJ`U*W=ONq%4J|Ot3tD&15Lz_u>=Rve2|oBZ&->!=KIk+e~mf# z7f)jLV!LAfXbv96LX6@W?M&u(2aIyqnM49trY$OTs?(sn&Ug4Z`}$K-se z4lm(#3|}I3VF=4H=qLNJB!XFEq)*EwiYM1<`x2I;X-yNdg^pq>=c}KAxl})pDr(Le z+e)MuI)=ocUNjX5E0Ch`AvWSmG%d^Lq7aM9(A=35{9#KC;s%^cxr}?T8T--N#~`c7 z?nwwuCHgP|2e1@}@DHXJQ$8+T8W$rPkMr^h&%4T`w^+)L{0O?&(=NP+UM%9&O0;k@ zzQQl)3s8SENTz;IFt$S4h(j2Od3^Pig9`8v<^}Cu_wrw*iudnuD*Bk1OI3(HSdTH7 zP%TZS6@EUTG_Y\n" "Language: hi_IN\n" @@ -16,469 +16,709 @@ msgstr "" "_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n" "X-Textdomain-Support: yes\n" "X-Poedit-Basepath: .\n" -"X-Generator: Poedit 2.2.1\n" +"X-Generator: Poedit 2.3.1\n" "X-Poedit-SearchPath-0: .\n" -# @ wp-members -#: admin/dialogs.php:116 -msgid "Your WP settings allow anyone to register - this is not the recommended setting." -msgstr "आपके WP सेटिंगà¥à¤¸ किसी को भी रजिसà¥à¤Ÿà¤° करने के लिठअनà¥à¤®à¤¤à¤¿ देते हैं - यह सिफारिश की सेटिंग नहीं है." - -# @ wp-members -#: admin/dialogs.php:117 -#, php-format -msgid "" -"You can %s change this here %s making sure the box next to \"Anyone can register\" is " -"unchecked." -msgstr "" -"आप%s में परिवरà¥à¤¤à¤¨ के यहां%s बनाने यकीन है कि अगले करने के लिठबॉकà¥à¤¸ \"कोई भी रजिसà¥à¤Ÿà¤° कर सकते हैं \" " -"अनियंतà¥à¤°à¤¿à¤¤ है" - -# @ wp-members -#: admin/dialogs.php:118 -msgid "" -"This setting allows a link on the /wp-login.php page to register using the WP native " -"registration process thus circumventing any registration you are using with WP-Members. In " -"some cases, this may suit the users wants/needs, but most users should uncheck this option. " -"If you do not change this setting, you can choose to ignore these warning messages under WP-" -"Members Settings." -msgstr "" -"यह सेटिंग / wp-login.php पृषà¥à¤  पर à¤à¤• लिंक WP देशी पंजीकरण पà¥à¤°à¤•à¥à¤°à¤¿à¤¯à¤¾ इस पà¥à¤°à¤•ार का उपयोग कर आप किसी भी " -"पंजीकरण WP-सदसà¥à¤¯ के साथ पà¥à¤°à¤¯à¥‹à¤— कर रहे हैं धोखा रजिसà¥à¤Ÿà¤° करने के लिठअनà¥à¤®à¤¤à¤¿ देता है. कà¥à¤› मामलों में, यह " -"उपयोगकरà¥à¤¤à¤¾à¤“ं को सूट / की जरूरत है चाहता है, हो सकता है, लेकिन अधिकांश उपयोगकरà¥à¤¤à¤¾à¤“ं को इस विकलà¥à¤ª को अनचेक " -"करना चाहिà¤. यदि आप इस सेटिंग को बदल नहीं है, तà¥à¤® WP-सदसà¥à¤¯ सेटिंगà¥à¤¸ के तहत इन चेतावनी संदेशों को अनदेखा करने " -"के लिठचà¥à¤¨ सकते हैं." - -# @ wp-members -#: admin/dialogs.php:122 -msgid "Your WP settings allow anyone to comment - this is not the recommended setting." -msgstr "आपके WP सेटिंगà¥à¤¸ किसी को भी टिपà¥à¤ªà¤£à¥€ करने के लिठअनà¥à¤®à¤¤à¤¿ देते हैं - यह सिफारिश की सेटिंग नहीं है." - -# @ wp-members -#: admin/dialogs.php:123 -#, php-format -msgid "" -"You can %s change this here %s by checking the box next to \"Users must be registered and " -"logged in to comment.\"" -msgstr "" -"आप%s में परिवरà¥à¤¤à¤¨ के इस%s अगले बॉकà¥à¤¸ की जाà¤à¤š करके यहाठकर सकते हैं \"उपयोगकरà¥à¤¤à¤¾à¤“ं को पंजीकृत होना चाहिठऔर में " -"लॉग इन टिपà¥à¤ªà¤£à¥€ करने के लिठ\"" - -# @ wp-members -#: admin/dialogs.php:124 -msgid "" -"This setting allows any users to comment, whether or not they are registered. Depending on " -"how you are using WP-Members will determine whether you should change this setting or not. " -"If you do not change this setting, you can choose to ignore these warning messages under WP-" -"Members Settings." -msgstr "" -"यह सेटिंग किसी भी उपयोगकरà¥à¤¤à¤¾à¤“ं को टिपà¥à¤ªà¤£à¥€ करने के लिà¤, चाहे या नहीं वे पंजीकृत हैं अनà¥à¤®à¤¤à¤¿ देता है. कैसे आप WP-" -"सदसà¥à¤¯à¥‹à¤‚ का उपयोग कर रहे हैं के आधार पर निरà¥à¤§à¤¾à¤°à¤¿à¤¤ होगा कि कà¥à¤¯à¤¾ आप इस सेटिंग को बदलने चाहिठया नहीं. यदि " -"आप इस सेटिंग को बदल नहीं है, तà¥à¤® WP-सदसà¥à¤¯ सेटिंगà¥à¤¸ के तहत इन चेतावनी संदेशों को अनदेखा करने के लिठचà¥à¤¨ सकते हैं." - -# @ wp-members -#: admin/dialogs.php:128 -msgid "Your WP settings allow full text rss feeds - this is not the recommended setting." -msgstr "आपका WP सेटिंगà¥à¤¸ पूरà¥à¤£ पाठ आरà¤à¤¸à¤à¤¸ फ़ीड की अनà¥à¤®à¤¤à¤¿ यह सिफारिश की सेटिंग नहीं है." - -# @ wp-members -#: admin/dialogs.php:129 -#, php-format -msgid "" -"You can %s change this here %s by changing \"For each article in a feed, show\" to \"Summary." -"\"" -msgstr "" -"आप बदल रहा है \"पà¥à¤°à¤¤à¥à¤¯à¥‡à¤• लेख के लिठà¤à¤• फ़ीड दिखाने के लिà¤, \" \"सारांश \"%s परिवरà¥à¤¤à¤¨ यह है यहां%s कर सकते हैं" - -# @ wp-members -#: admin/dialogs.php:130 -msgid "" -"Leaving this set to full text allows anyone to read your protected content in an RSS reader. " -"Changing this to Summary prevents this as your feeds will only show summary text." -msgstr "" -"पूरà¥à¤£ पाठ करने के लिठइस सेट को छोड़कर किसी को भी à¤à¤• आरà¤à¤¸à¤à¤¸ रीडर में संरकà¥à¤·à¤¿à¤¤ सामगà¥à¤°à¥€ को पढ़ने के लिठ" -"अनà¥à¤®à¤¤à¤¿ देता है. यह करने के लिठसारांश बदलने से अपने फ़ीड के रूप में इस रोकता केवल सारांश पाठ दि" - -# @ wp-members -#: admin/dialogs.php:134 -msgid "You have set WP-Members to hold registrations for approval" -msgstr "आप WP-सदसà¥à¤¯ सेट करने के लिठअनà¥à¤®à¥‹à¤¦à¤¨ के लिठपंजीकरण पकड़ है" - -# @ wp-members -#: admin/dialogs.php:135 -msgid "" -"but you have not changed the default message for \"Registration Completed\" under \"WP-" -"Members Dialogs and Error Messages.\" You should change this message to let users know they " -"are pending approval." -msgstr "" -"लेकिन आप के लिठडिफ़ॉलà¥à¤Ÿ संदेश नहीं बदल गया है \"पंजीकरण पूरà¥à¤£ \" के अंतरà¥à¤—त \"WP-सदसà¥à¤¯ संवाद और तà¥à¤°à¥à¤Ÿà¤¿ संदेश \" " -"आप इस संदेश को बदलने के लिठउपयोगकरà¥à¤¤à¤¾à¤“ं को पता है कि वे अनà¥à¤®à¥‹à¤¦à¤¨ के लिठलंबित कर रहे हैं " - -# @ wp-members -#: admin/dialogs.php:139 -msgid "You have turned on reCAPTCHA" -msgstr "आप reCAPTCHA पर बदल गया है" - -# @ wp-members -#: admin/dialogs.php:140 -msgid "" -"but you have not entered API keys. You will need both a public and private key. The " -"CAPTCHA will not display unless a valid API key is included." -msgstr "" -"लेकिन आप à¤à¤ªà¥€à¤†à¤ˆ कà¥à¤‚जी दरà¥à¤œ नहीं की है. तà¥à¤® दोनों सारà¥à¤µà¤œà¤¨à¤¿à¤• और निजी कà¥à¤‚जी की आवशà¥à¤¯à¤•ता होगी. कॅपà¥à¤šà¤¾ है जब तक " -"à¤à¤• मानà¥à¤¯ API कà¥à¤‚जी शामिल है पà¥à¤°à¤¦à¤°à¥à¤¶à¤¿à¤¤ नहीं होगा." - -#: admin/dialogs.php:144 -msgid "You have active settings that are not recommended." -msgstr "" - -#: admin/dialogs.php:145 -msgid "" -"If you will not be changing these settings, you can turn off these warning messages by " -"checking the \"Ignore warning messages\" in the settings below." -msgstr "" - -# @ wp-members -#: admin/dialogs.php:169 -msgid "Version:" -msgstr "संसà¥à¤•रण:" - -#: admin/dialogs.php:170 -#, fuzzy -msgid "Quick Start Guide" -msgstr "नवीनीकरण उपयोगकरà¥à¤¤à¤¾" - -#: admin/dialogs.php:171 -#, fuzzy -msgid "Online User Guide" -msgstr "नवीनीकरण उपयोगकरà¥à¤¤à¤¾" - -#: admin/dialogs.php:172 -msgid "FAQs" -msgstr "" - -# @ wp-members -#: admin/dialogs.php:179 -#, fuzzy -msgid "Thank you for using WP-Members" -msgstr "WP-सदसà¥à¤¯ का उपयोग करने के लिठधनà¥à¤¯à¤µà¤¾à¤¦! संसà¥à¤®à¤°à¤£%s का उपयोग कर रहे हैं" - -#: admin/dialogs.php:180 -msgid "A plugin developed by" -msgstr "" - -# @ wp-members -#: admin/dialogs.php:181 -msgid "Follow" -msgstr "पालन करें" - -#: admin/dialogs.php:198 admin/dialogs.php:202 -msgid "Latest from RocketGeek" -msgstr "" - -#: admin/dialogs.php:219 -msgid "Like WP-Members?" -msgstr "" - -#: admin/dialogs.php:220 -#, php-format -msgid "" -"If you like WP-Members please give it a %s★★★★★%s rating. " -"Thanks!!" -msgstr "" - -#: admin/dialogs.php:231 admin/dialogs.php:244 -msgid "Latest from ButlerBlog" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:256 +#: includes/admin/class-wp-members-admin-api.php:292 msgid "Custom email" msgstr "" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:257 -#: admin/includes/class-wp-members-admin-api.php:259 +#: includes/admin/class-wp-members-admin-api.php:293 +#: includes/admin/class-wp-members-admin-api.php:295 msgid "Subject" msgstr "विषय" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:260 +#: includes/admin/class-wp-members-admin-api.php:296 msgid "Body" msgstr "शरीर" -#: admin/includes/class-wp-members-admin-api.php:262 +#: includes/admin/class-wp-members-admin-api.php:298 msgid "Your custom email message content." msgstr "" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:340 +#: includes/admin/class-wp-members-admin-api.php:376 msgid "Options" msgstr "विकलà¥à¤ª" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:341 +#: includes/admin/class-wp-members-admin-api.php:377 msgid "Fields" msgstr "फ़ीलà¥à¤¡" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:342 +#: includes/admin/class-wp-members-admin-api.php:378 msgid "Dialogs" msgstr "संवाद" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:343 +#: includes/admin/class-wp-members-admin-api.php:379 msgid "Emails" msgstr "ईमेल" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:359 +#: includes/admin/class-wp-members-admin-api.php:395 msgid "New Registration" msgstr "नया पंजीकरण" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:368 +#: includes/admin/class-wp-members-admin-api.php:404 msgid "Registration is Moderated" msgstr "पंजीकरण संचालित है" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:374 +#: includes/admin/class-wp-members-admin-api.php:410 msgid "Registration is Moderated, User is Approved" msgstr "पंजीकरण संचालित है, उपयोगकरà¥à¤¤à¤¾ सà¥à¤µà¥€à¤•ृत" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:382 +#: includes/admin/class-wp-members-admin-api.php:418 msgid "Password Reset" msgstr "पासवरà¥à¤¡ रीसेट" -#: admin/includes/class-wp-members-admin-api.php:389 +#: includes/admin/class-wp-members-admin-api.php:425 msgid "Retrieve Username" msgstr "" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:397 +#: includes/admin/class-wp-members-admin-api.php:433 msgid "Admin Notification" msgstr "वà¥à¤¯à¤µà¤¸à¥à¤¥à¤¾à¤ªà¤• अधिसूचना" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:423 +#: includes/admin/class-wp-members-admin-api.php:459 msgid "Restricted post (or page), displays above the login/registration form" msgstr "रतिबंधित पोसà¥à¤Ÿ, (या पृषà¥à¤ ) पà¥à¤°à¤ªà¤¤à¥à¤° लॉग इन / पंजीकरण ऊपर पà¥à¤°à¤¦à¤°à¥à¤¶à¤¿à¤¤ करता है" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:424 +#: includes/admin/class-wp-members-admin-api.php:460 msgid "Username is taken" msgstr "उपयोगकरà¥à¤¤à¤¾ नाम लिया है" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:461 msgid "Email is registered" msgstr "ईमेल पंजीकृत है" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:426 +#: includes/admin/class-wp-members-admin-api.php:462 msgid "Registration completed" msgstr "पंजीकरण पूरा किया" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:427 +#: includes/admin/class-wp-members-admin-api.php:463 msgid "User update" msgstr "नवीनीकरण उपयोगकरà¥à¤¤à¤¾" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:428 +#: includes/admin/class-wp-members-admin-api.php:464 msgid "Passwords did not match" msgstr "कूटशबà¥à¤¦ मेल नहीं खाता" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:429 +#: includes/admin/class-wp-members-admin-api.php:465 msgid "Password changes" msgstr "पासवरà¥à¤¡ परिवरà¥à¤¤à¤¨" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:430 +#: includes/admin/class-wp-members-admin-api.php:466 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "उपयोगकरà¥à¤¤à¤¾ नाम या ईमेल जब भूल पासवरà¥à¤¡ रीसेट करने की कोशिश मौजूद नहीं है" # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:431 +#: includes/admin/class-wp-members-admin-api.php:467 msgid "Password reset" msgstr "पासवरà¥à¤¡ रीसेट" # @ default # @ wp-members -#: admin/includes/class-wp-members-admin-api.php:564 +#: includes/admin/class-wp-members-admin-api.php:623 msgid "Settings" msgstr "सेटिंगà¥à¤¸" -#: admin/includes/class-wp-members-products-admin.php:57 -msgid "Slug" +#: includes/admin/class-wp-members-admin-posts.php:30 +#: includes/admin/class-wp-members-admin-posts.php:33 +msgid "Unblock" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:58 -msgid "Role" +#: includes/admin/class-wp-members-admin-posts.php:31 +#: includes/admin/class-wp-members-admin-posts.php:34 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 +#, fuzzy +msgid "Block" +msgstr "डिफ़ॉलà¥à¤Ÿ रूप से बà¥à¤²à¥‰à¤• पोसà¥à¤Ÿ" + +#: includes/admin/class-wp-members-admin-posts.php:32 +#: includes/admin/class-wp-members-admin-posts.php:35 +msgid "Hide" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s blocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:165 +#, php-format +msgid "%s Restriction" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:195 +msgid "Unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:196 +msgid "Blocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:197 +msgid "Hidden" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +msgid "Status:" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:68 +#: includes/admin/tabs/class-wp-members-fields-table.php:65 +#: includes/walkers/class-wp-members-walker-nav-menu.php:140 +#, fuzzy +msgid "Edit" +msgstr "जानकारी संपादित करें" + +#: includes/admin/class-wp-members-admin-posts.php:218 +msgid "Ok" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:219 +#: includes/walkers/class-wp-members-walker-nav-menu.php:224 +msgid "Cancel" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:305 +#: includes/admin/class-wp-members-products-admin.php:629 +msgid "Status" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:28 +#: includes/admin/class-wp-members-admin-users.php:33 +#: includes/admin/class-wp-members-admin-users.php:59 +msgid "Activate" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:29 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:62 +msgid "Deactivate" msgstr "" # @ wp-members -#: admin/includes/class-wp-members-products-admin.php:59 -#: admin/includes/class-wp-members-products-admin.php:162 admin/tab-fields.php:459 -#: admin/user-export.php:69 +#: includes/admin/class-wp-members-admin-users.php:31 +#: includes/admin/class-wp-members-admin-users.php:36 +msgid "Export" +msgstr "निरà¥à¤¯à¤¾à¤¤" + +#: includes/admin/class-wp-members-admin-users.php:37 +#: includes/admin/class-wp-members-admin-users.php:88 +#, fuzzy +msgid "Export All Users" +msgstr "निरà¥à¤¯à¤¾à¤¤" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:129 +msgid "No users selected" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 +msgid "You cannot activate or deactivate yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:152 +#, php-format +msgid "%s activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:157 +#, php-format +msgid "%s deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:161 +msgid "That user is already active" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:288 +msgid "Pending" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:289 +msgid "Trial" +msgstr "" + +# @ wp-members +#: includes/admin/class-wp-members-admin-users.php:290 +#: includes/admin/class-wp-members-export.php:74 +msgid "Subscription" +msgstr "सदसà¥à¤¯à¤¤à¤¾" + +#: includes/admin/class-wp-members-admin-users.php:291 +msgid "Expired" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:294 +msgid "Activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:295 +msgid "Pending Activation" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:296 +msgid "Deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:298 +msgid "Not Exported" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:387 +#: includes/admin/class-wp-members-export.php:160 +msgid "No" +msgstr "" + +#: includes/admin/class-wp-members-export.php:64 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-export.php:65 includes/class-wp-members.php:1523 +#: includes/class-wp-members.php:1546 +msgid "Username" +msgstr "" + +# @ wp-members +#: includes/admin/class-wp-members-export.php:71 +msgid "Activated?" +msgstr "सकà¥à¤°à¤¿à¤¯?" + +# @ wp-members +#: includes/admin/class-wp-members-export.php:75 +#: includes/admin/class-wp-members-products-admin.php:64 +#: includes/admin/class-wp-members-products-admin.php:632 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 msgid "Expires" msgstr "समापà¥à¤¤ हो" -#: admin/includes/class-wp-members-products-admin.php:60 +# @ wp-members +#: includes/admin/class-wp-members-export.php:77 +msgid "Registered" +msgstr "पंजीकृत" + +# @ wp-members +#: includes/admin/class-wp-members-export.php:78 +msgid "IP" +msgstr "IP" + +# @ wp-members +#: includes/admin/class-wp-members-export.php:160 +#: includes/admin/class-wp-members-products-admin.php:104 +msgid "Yes" +msgstr "हां" + +#: includes/admin/class-wp-members-products-admin.php:62 +msgid "Slug" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:63 +msgid "Role" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:66 +msgid "Default" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:68 msgid "Last updated" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:80 +#: includes/admin/class-wp-members-products-admin.php:92 +msgid "slug:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:95 msgid "No role required" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:84 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "Does not expire" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:120 +#: includes/admin/class-wp-members-products-admin.php:140 msgid "Membership Product Details" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 -#: admin/includes/class-wp-members-products-admin.php:167 +#: includes/admin/class-wp-members-products-admin.php:148 +msgid "Membership Product Message (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 +msgid "Posts" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#, fuzzy +msgid "Pages" +msgstr "डिफ़ॉलà¥à¤Ÿ रूप से बà¥à¤²à¥‰à¤• पनà¥à¤¨à¥‡" + +#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:235 +#: includes/admin/class-wp-members-products-admin.php:280 msgid "Period" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Day" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Week" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Month" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Year" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:199 msgid "Name (slug)" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:153 -msgid "Role Required?" +#: includes/admin/class-wp-members-products-admin.php:201 +msgid "Optional Defaults" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:204 +msgid "Assign as default at registration? (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:212 +#, php-format +msgid "Pre-selected by default for new %s" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:218 +msgid "Optional Properties" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:156 +#: includes/admin/class-wp-members-products-admin.php:221 +msgid "Role Required? (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:224 msgid "No Role" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:164 -#: admin/includes/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:230 +msgid "Expires (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:232 +#: includes/admin/class-wp-members-products-admin.php:234 +#: includes/admin/class-wp-members-products-admin.php:277 +#: includes/admin/class-wp-members-products-admin.php:279 msgid "Number" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:245 admin/tab-options.php:207 -#: inc/class-wp-members-forms.php:999 inc/class-wp-members-user-profile.php:106 -#: inc/deprecated.php:360 inc/deprecated.php:622 +#: includes/admin/class-wp-members-products-admin.php:240 +msgid "Use \"no gap\" renewal" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:244 +msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:261 +msgid "Period Start (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:262 +msgid "Period End (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:275 +msgid "Fixed period grace period" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:284 +msgid "" +"Grace period is the point at which expiration date is for following time period. For " +"example, if user who register August 1st would be part of the following year's Sept 1 - Aug " +"31 membership, set this at 1 Month. Leave blank for no grace period." +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:333 +msgid "Restricted Message (displays when a user does not have access to a membership)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:435 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 +#: includes/class-wp-members-forms.php:1092 includes/class-wp-members-user-profile.php:112 msgid "None" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:251 +#: includes/admin/class-wp-members-products-admin.php:450 msgid "Limit access to:" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:321 +#: includes/admin/class-wp-members-products-admin.php:520 msgid "Required Membership" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:360 +#: includes/admin/class-wp-members-products-admin.php:559 +#: includes/admin/class-wp-members-products-admin.php:630 msgid "Membership" msgstr "" -#: admin/post.php:45 admin/post.php:48 -msgid "Unblock" +#: includes/admin/class-wp-members-products-admin.php:599 +#: includes/class-wp-members-products.php:308 +msgid "Memberships" msgstr "" -#: admin/post.php:46 admin/post.php:49 admin/tab-options.php:114 -#, fuzzy -msgid "Block" -msgstr "डिफ़ॉलà¥à¤Ÿ रूप से बà¥à¤²à¥‰à¤• पोसà¥à¤Ÿ" +#: includes/admin/class-wp-members-products-admin.php:626 +msgid "Product Access" +msgstr "" -#: admin/post.php:47 admin/post.php:50 -msgid "Hide" +#: includes/admin/class-wp-members-products-admin.php:631 +msgid "Enabled?" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:641 +msgid "Enable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:642 +msgid "Disable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:647 +msgid "Expiration date (optional)" msgstr "" -#: admin/post.php:138 +# @ wp-members +#: includes/admin/dialogs.php:117 +msgid "Your WP settings allow anyone to register - this is not the recommended setting." +msgstr "आपके WP सेटिंगà¥à¤¸ किसी को भी रजिसà¥à¤Ÿà¤° करने के लिठअनà¥à¤®à¤¤à¤¿ देते हैं - यह सिफारिश की सेटिंग नहीं है." + +# @ wp-members +#: includes/admin/dialogs.php:118 #, php-format -msgid "%s blocked" +msgid "" +"You can %s change this here %s making sure the box next to \"Anyone can register\" is " +"unchecked." +msgstr "" +"आप%s में परिवरà¥à¤¤à¤¨ के यहां%s बनाने यकीन है कि अगले करने के लिठबॉकà¥à¤¸ \"कोई भी रजिसà¥à¤Ÿà¤° कर सकते हैं \" " +"अनियंतà¥à¤°à¤¿à¤¤ है" + +# @ wp-members +#: includes/admin/dialogs.php:119 +msgid "" +"This setting allows a link on the /wp-login.php page to register using the WP native " +"registration process thus circumventing any registration you are using with WP-Members. In " +"some cases, this may suit the users wants/needs, but most users should uncheck this option. " +"If you do not change this setting, you can choose to ignore these warning messages under WP-" +"Members Settings." msgstr "" +"यह सेटिंग / wp-login.php पृषà¥à¤  पर à¤à¤• लिंक WP देशी पंजीकरण पà¥à¤°à¤•à¥à¤°à¤¿à¤¯à¤¾ इस पà¥à¤°à¤•ार का उपयोग कर आप किसी भी " +"पंजीकरण WP-सदसà¥à¤¯ के साथ पà¥à¤°à¤¯à¥‹à¤— कर रहे हैं धोखा रजिसà¥à¤Ÿà¤° करने के लिठअनà¥à¤®à¤¤à¤¿ देता है. कà¥à¤› मामलों में, यह " +"उपयोगकरà¥à¤¤à¤¾à¤“ं को सूट / की जरूरत है चाहता है, हो सकता है, लेकिन अधिकांश उपयोगकरà¥à¤¤à¤¾à¤“ं को इस विकलà¥à¤ª को अनचेक " +"करना चाहिà¤. यदि आप इस सेटिंग को बदल नहीं है, तà¥à¤® WP-सदसà¥à¤¯ सेटिंगà¥à¤¸ के तहत इन चेतावनी संदेशों को अनदेखा करने " +"के लिठचà¥à¤¨ सकते हैं." -#: admin/post.php:138 +# @ wp-members +#: includes/admin/dialogs.php:123 +msgid "Your WP settings allow anyone to comment - this is not the recommended setting." +msgstr "आपके WP सेटिंगà¥à¤¸ किसी को भी टिपà¥à¤ªà¤£à¥€ करने के लिठअनà¥à¤®à¤¤à¤¿ देते हैं - यह सिफारिश की सेटिंग नहीं है." + +# @ wp-members +#: includes/admin/dialogs.php:124 #, php-format -msgid "%s unblocked" +msgid "" +"You can %s change this here %s by checking the box next to \"Users must be registered and " +"logged in to comment.\"" +msgstr "" +"आप%s में परिवरà¥à¤¤à¤¨ के इस%s अगले बॉकà¥à¤¸ की जाà¤à¤š करके यहाठकर सकते हैं \"उपयोगकरà¥à¤¤à¤¾à¤“ं को पंजीकृत होना चाहिठऔर में " +"लॉग इन टिपà¥à¤ªà¤£à¥€ करने के लिठ\"" + +# @ wp-members +#: includes/admin/dialogs.php:125 +msgid "" +"This setting allows any users to comment, whether or not they are registered. Depending on " +"how you are using WP-Members will determine whether you should change this setting or not. " +"If you do not change this setting, you can choose to ignore these warning messages under WP-" +"Members Settings." msgstr "" +"यह सेटिंग किसी भी उपयोगकरà¥à¤¤à¤¾à¤“ं को टिपà¥à¤ªà¤£à¥€ करने के लिà¤, चाहे या नहीं वे पंजीकृत हैं अनà¥à¤®à¤¤à¤¿ देता है. कैसे आप WP-" +"सदसà¥à¤¯à¥‹à¤‚ का उपयोग कर रहे हैं के आधार पर निरà¥à¤§à¤¾à¤°à¤¿à¤¤ होगा कि कà¥à¤¯à¤¾ आप इस सेटिंग को बदलने चाहिठया नहीं. यदि " +"आप इस सेटिंग को बदल नहीं है, तà¥à¤® WP-सदसà¥à¤¯ सेटिंगà¥à¤¸ के तहत इन चेतावनी संदेशों को अनदेखा करने के लिठचà¥à¤¨ सकते हैं." -#: admin/post.php:177 +# @ wp-members +#: includes/admin/dialogs.php:129 +msgid "Your WP settings allow full text rss feeds - this is not the recommended setting." +msgstr "आपका WP सेटिंगà¥à¤¸ पूरà¥à¤£ पाठ आरà¤à¤¸à¤à¤¸ फ़ीड की अनà¥à¤®à¤¤à¤¿ यह सिफारिश की सेटिंग नहीं है." + +# @ wp-members +#: includes/admin/dialogs.php:130 #, php-format -msgid "%s Restriction" +msgid "" +"You can %s change this here %s by changing \"For each article in a feed, show\" to \"Summary." +"\"" msgstr "" +"आप बदल रहा है \"पà¥à¤°à¤¤à¥à¤¯à¥‡à¤• लेख के लिठà¤à¤• फ़ीड दिखाने के लिà¤, \" \"सारांश \"%s परिवरà¥à¤¤à¤¨ यह है यहां%s कर सकते हैं" -#: admin/post.php:206 -msgid "Unblocked" +# @ wp-members +#: includes/admin/dialogs.php:131 +msgid "" +"Leaving this set to full text allows anyone to read your protected content in an RSS reader. " +"Changing this to Summary prevents this as your feeds will only show summary text." +msgstr "" +"पूरà¥à¤£ पाठ करने के लिठइस सेट को छोड़कर किसी को भी à¤à¤• आरà¤à¤¸à¤à¤¸ रीडर में संरकà¥à¤·à¤¿à¤¤ सामगà¥à¤°à¥€ को पढ़ने के लिठ" +"अनà¥à¤®à¤¤à¤¿ देता है. यह करने के लिठसारांश बदलने से अपने फ़ीड के रूप में इस रोकता केवल सारांश पाठ दि" + +# @ wp-members +#: includes/admin/dialogs.php:135 +msgid "You have set WP-Members to hold registrations for approval" +msgstr "आप WP-सदसà¥à¤¯ सेट करने के लिठअनà¥à¤®à¥‹à¤¦à¤¨ के लिठपंजीकरण पकड़ है" + +# @ wp-members +#: includes/admin/dialogs.php:136 +msgid "" +"but you have not changed the default message for \"Registration Completed\" under \"WP-" +"Members Dialogs and Error Messages.\" You should change this message to let users know they " +"are pending approval." msgstr "" +"लेकिन आप के लिठडिफ़ॉलà¥à¤Ÿ संदेश नहीं बदल गया है \"पंजीकरण पूरà¥à¤£ \" के अंतरà¥à¤—त \"WP-सदसà¥à¤¯ संवाद और तà¥à¤°à¥à¤Ÿà¤¿ संदेश \" " +"आप इस संदेश को बदलने के लिठउपयोगकरà¥à¤¤à¤¾à¤“ं को पता है कि वे अनà¥à¤®à¥‹à¤¦à¤¨ के लिठलंबित कर रहे हैं " + +# @ wp-members +#: includes/admin/dialogs.php:140 +msgid "You have turned on reCAPTCHA" +msgstr "आप reCAPTCHA पर बदल गया है" + +# @ wp-members +#: includes/admin/dialogs.php:141 +msgid "" +"but you have not entered API keys. You will need both a public and private key. The " +"CAPTCHA will not display unless a valid API key is included." +msgstr "" +"लेकिन आप à¤à¤ªà¥€à¤†à¤ˆ कà¥à¤‚जी दरà¥à¤œ नहीं की है. तà¥à¤® दोनों सारà¥à¤µà¤œà¤¨à¤¿à¤• और निजी कà¥à¤‚जी की आवशà¥à¤¯à¤•ता होगी. कॅपà¥à¤šà¤¾ है जब तक " +"à¤à¤• मानà¥à¤¯ API कà¥à¤‚जी शामिल है पà¥à¤°à¤¦à¤°à¥à¤¶à¤¿à¤¤ नहीं होगा." + +#: includes/admin/dialogs.php:145 +msgid "You have active settings that are not recommended." +msgstr "" + +#: includes/admin/dialogs.php:146 +msgid "" +"If you will not be changing these settings, you can turn off these warning messages by " +"checking the \"Ignore warning messages\" in the settings below." +msgstr "" + +# @ wp-members +#: includes/admin/dialogs.php:174 +msgid "Version:" +msgstr "संसà¥à¤•रण:" + +#: includes/admin/dialogs.php:175 +#, fuzzy +msgid "Quick Start Guide" +msgstr "नवीनीकरण उपयोगकरà¥à¤¤à¤¾" + +#: includes/admin/dialogs.php:176 +#, fuzzy +msgid "Online User Guide" +msgstr "नवीनीकरण उपयोगकरà¥à¤¤à¤¾" -#: admin/post.php:207 -msgid "Blocked" +#: includes/admin/dialogs.php:177 +msgid "FAQs" msgstr "" -#: admin/post.php:208 -msgid "Hidden" -msgstr "" +# @ wp-members +#: includes/admin/dialogs.php:184 +#, fuzzy +msgid "Thank you for using WP-Members" +msgstr "WP-सदसà¥à¤¯ का उपयोग करने के लिठधनà¥à¤¯à¤µà¤¾à¤¦! संसà¥à¤®à¤°à¤£%s का उपयोग कर रहे हैं" -#: admin/post.php:214 -msgid "Status:" +#: includes/admin/dialogs.php:185 +msgid "A plugin developed by" msgstr "" -#: admin/post.php:214 admin/tab-fields.php:88 admin/tab-fields.php:554 -#, fuzzy -msgid "Edit" -msgstr "जानकारी संपादित करें" +# @ wp-members +#: includes/admin/dialogs.php:186 +msgid "Follow" +msgstr "पालन करें" -#: admin/post.php:229 -msgid "Ok" +#: includes/admin/dialogs.php:203 includes/admin/dialogs.php:207 +msgid "Latest from RocketGeek" msgstr "" -#: admin/post.php:230 -msgid "Cancel" +#: includes/admin/dialogs.php:224 +msgid "Like WP-Members?" msgstr "" -#: admin/post.php:314 -msgid "Status" +#: includes/admin/dialogs.php:225 +#, php-format +msgid "" +"If you like WP-Members please give it a %s★★★★★%s rating. " +"Thanks!!" msgstr "" -#: admin/tab-about.php:34 admin/tab-about.php:54 -msgid "About WP-Members" +#: includes/admin/dialogs.php:236 includes/admin/dialogs.php:249 +msgid "Latest from ButlerBlog" msgstr "" -#: admin/tab-captcha.php:66 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:67 #, php-format msgid "See the %sUsers Guide on CAPTCHA%s." msgstr "" -#: admin/tab-captcha.php:73 admin/tab-dialogs.php:57 admin/tab-emails.php:101 -#: admin/tab-fields.php:153 admin/tab-options.php:82 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" # @ wp-members -#: admin/tab-captcha.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 msgid "Manage reCAPTCHA Options" msgstr "ReCAPTCHA विकलà¥à¤ª पà¥à¤°à¤¬à¤‚धित करें" # @ wp-members -#: admin/tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 msgid "" "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books while blocking " "spam on your blog." @@ -487,7 +727,7 @@ msgstr "" "अवरà¥à¤¦à¥à¤§ है." # @ wp-members -#: admin/tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 #, php-format msgid "" "reCAPTCHA asks commenters to retype two words scanned from a book to prove that they are a " @@ -501,12 +741,13 @@ msgstr "" "वेबसाइट%s की यातà¥à¤°à¤¾" # @ wp-members -#: admin/tab-captcha.php:104 admin/tab-captcha.php:130 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 msgid "reCAPTCHA Keys" msgstr "reCAPTCHA कà¥à¤‚जी" # @ wp-members -#: admin/tab-captcha.php:106 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" key. You can " @@ -516,538 +757,501 @@ msgstr "" "reCAPTCHA कà¥à¤‚जी%s के लिठसाइन अप कर सकते हैं" # @ wp-members -#: admin/tab-captcha.php:107 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 msgid "Public Key" msgstr "सारà¥à¤µà¤œà¤¨à¤¿à¤• कà¥à¤‚जी" # @ wp-members -#: admin/tab-captcha.php:108 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 msgid "Private Key" msgstr "निजी कà¥à¤‚जी" # @ wp-members -#: admin/tab-captcha.php:112 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 msgid "Choose Theme" msgstr "थीम चà¥à¤¨à¥‡à¤‚" # @ wp-members -#: admin/tab-captcha.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 msgid "Red" msgstr "लाल" # @ wp-members -#: admin/tab-captcha.php:116 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 msgid "White" msgstr "सफ़ेद" # @ wp-members -#: admin/tab-captcha.php:117 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 msgid "Black Glass" msgstr "काले गà¥à¤²à¤¾à¤¸" # @ wp-members -#: admin/tab-captcha.php:118 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 msgid "Clean" msgstr "सà¥à¤µà¤šà¥à¤›" -#: admin/tab-captcha.php:132 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" key. You can sign " "up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 msgid "Site Key" msgstr "" -#: admin/tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 msgid "Secret Key" msgstr "" -#: admin/tab-captcha.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 #, fuzzy msgid "Characters for image" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" -#: admin/tab-captcha.php:169 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 #, fuzzy msgid "Number of characters" msgstr "कà¥à¤› अंशः दिखाà¤à¤" -#: admin/tab-captcha.php:173 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 #, fuzzy msgid "Image dimensions" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Width" msgstr "" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Height" msgstr "" -#: admin/tab-captcha.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Font color of characters" msgstr "" -#: admin/tab-captcha.php:181 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 #, fuzzy msgid "Background color of image" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" -#: admin/tab-captcha.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Font size" msgstr "" -#: admin/tab-captcha.php:189 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Width between characters" msgstr "" -#: admin/tab-captcha.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 #, fuzzy msgid "Image type" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" -#: admin/tab-captcha.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin installed and " "activated." msgstr "" # @ wp-members -#: admin/tab-captcha.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 msgid "Update CAPTCHA Settings" msgstr "अपडेट करें CAPTCHA सेटिंगà¥à¤¸" # @ wp-members -#: admin/tab-captcha.php:301 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 msgid "CAPTCHA was updated for WP-Members" msgstr "CAPTCHA WP-सदसà¥à¤¯ के लिठअपडेट किया गया था" # @ wp-members -#: admin/tab-dialogs.php:67 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:67 msgid "Dialogs and Error Messages" msgstr "संवाद और तà¥à¤°à¥à¤Ÿà¤¿ संदेश" # @ wp-members -#: admin/tab-dialogs.php:69 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:69 #, php-format msgid "" "You can customize the text for dialogs and error messages. Simple HTML is allowed %s etc." msgstr "आप संवाद और तà¥à¤°à¥à¤Ÿà¤¿ संदेश के लिठपाठ को अनà¥à¤•ूलित कर सकते हैं. सरल HTML%s आदि की अनà¥à¤®à¤¤à¤¿ दी है" # @ wp-members -#: admin/tab-dialogs.php:80 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:80 msgid "Terms of Service (TOS)" msgstr "सेवा की शरà¥à¤¤à¥‡à¤‚ (TOS)" # @ wp-members -#: admin/tab-dialogs.php:87 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:87 msgid "Update Dialogs" msgstr "संवाद अपडेट करें" # @ wp-members -#: admin/tab-dialogs.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:124 msgid "WP-Members dialogs were updated" msgstr "WP-सदसà¥à¤¯ संवाद अपडेट की गई थीं" -#: admin/tab-dropins.php:78 admin/tab-dropins.php:378 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:88 +#: includes/admin/tabs/class-wp-members-dropins-table.php:180 msgid "WP-Members Dropin settings were updated" msgstr "" -#: admin/tab-dropins.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:216 msgid "Manage Dropins" msgstr "" -#: admin/tab-dropins.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:217 msgid "Current dropin folder: " msgstr "" -#: admin/tab-dropins.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:218 msgid "" "You can change location of the dropin folder using the wpmem_dropin_folder " "filter." msgstr "" -#: admin/tab-dropins.php:269 -msgid "Name" -msgstr "" - -#: admin/tab-dropins.php:270 -msgid "File" -msgstr "" - -#: admin/tab-dropins.php:271 -msgid "Version" -msgstr "" - -#: admin/tab-dropins.php:272 -msgid "Description" -msgstr "" - -#: admin/tab-dropins.php:315 admin/tab-fields.php:597 -msgid "Save Settings" -msgstr "" - # @ wp-members -#: admin/tab-emails.php:58 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:57 msgid "Email Messages" msgstr "ईमेल संदेश" # @ wp-members -#: admin/tab-emails.php:61 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:60 msgid "You can customize the content of the emails sent by the plugin." msgstr "आप पà¥à¤²à¤—इन दà¥à¤µà¤¾à¤°à¤¾ भेजे गठईमेल की सामगà¥à¤°à¥€ को अनà¥à¤•ूलित कर सकते हैं." # @ wp-members -#: admin/tab-emails.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:62 msgid "A list of shortcodes is available here." msgstr "शॉरà¥à¤Ÿà¤•ोड की à¤à¤• सूची यहाठउपलबà¥à¤§ है." # @ wp-members -#: admin/tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:69 msgid "Set a custom email address" msgstr "à¤à¤• कसà¥à¤Ÿà¤® ईमेल पता सेट करें" # @ wp-members -#: admin/tab-emails.php:71 admin/tab-emails.php:75 admin/tab-emails.php:85 -#: admin/tab-fields.php:179 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 msgid "(optional)" msgstr "(वैकलà¥à¤ªà¤¿à¤•)" # @ wp-members -#: admin/tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:73 msgid "Set a custom email name" msgstr "à¤à¤• कसà¥à¤Ÿà¤® ईमेल का नाम सेट करें" # @ wp-members -#: admin/tab-emails.php:85 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 msgid "Email Signature" msgstr "ईमेल हसà¥à¤¤à¤¾à¤•à¥à¤·à¤°" # @ wp-members -#: admin/tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 msgid "Update Emails" msgstr "ईमेल अपडेट करें" # @ wp-members -#: admin/tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 msgid "WP-Members emails were updated" msgstr "WP-सदसà¥à¤¯ ईमेल अपडेट की गई थीं" -#: admin/tab-fields.php:113 inc/class-wp-members.php:1207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 +#: includes/class-wp-members.php:1498 msgid "No fields selected for deletion" msgstr "" -#: admin/tab-fields.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:95 msgid "Are you sure you want to delete the following fields?" msgstr "" -#: admin/tab-fields.php:141 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:122 msgid "Fields deleted" msgstr "" -#: admin/tab-fields.php:155 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:136 msgid "Field Manager Documentation" msgstr "" # @ wp-members -#: admin/tab-fields.php:180 admin/tab-fields.php:322 inc/class-wp-members-user-profile.php:138 -#: inc/deprecated.php:385 inc/deprecated.php:646 inc/wp-registration.php:57 -#: inc/wp-registration.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/class-wp-members-forms.php:1626 includes/class-wp-members-forms.php:1803 +#: includes/class-wp-members-user-profile.php:144 msgid "(required)" msgstr "आवशà¥à¤¯à¤•ता है?" # @ wp-members -#: admin/tab-fields.php:185 admin/tab-fields.php:407 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 #, fuzzy msgid "Edit Field" msgstr "जानकारी संपादित करें" # @ wp-members -#: admin/tab-fields.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 #, fuzzy msgid "Add a Field" msgstr "जोड़ना" # @ wp-members -#: admin/tab-fields.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 msgid "Field Label" msgstr "कà¥à¤·à¥‡à¤¤à¥à¤° लेबल" -#: admin/tab-fields.php:192 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: admin/tab-fields.php:195 admin/tab-fields.php:547 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: admin/tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 msgid "" "The database meta value for the field. It must be unique and contain no spaces (underscores " "are ok)." msgstr "" # @ wp-members -#: admin/tab-fields.php:205 admin/tab-fields.php:548 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" # @ wp-members -#: admin/tab-fields.php:211 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 msgid "text" msgstr "पाठ" -#: admin/tab-fields.php:212 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 msgid "email" msgstr "" # @ wp-members -#: admin/tab-fields.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "textarea" msgstr "textarea" # @ wp-members -#: admin/tab-fields.php:214 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "checkbox" msgstr "चेकबॉकà¥à¤¸" -#: admin/tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "multiple checkbox" msgstr "" -#: admin/tab-fields.php:216 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "select (dropdown)" msgstr "" -#: admin/tab-fields.php:217 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple select" msgstr "" -#: admin/tab-fields.php:218 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "radio group" msgstr "" # @ wp-members -#: admin/tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "password" msgstr "पासवरà¥à¤¡" -#: admin/tab-fields.php:220 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "image" msgstr "" -#: admin/tab-fields.php:221 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "file" msgstr "" -#: admin/tab-fields.php:222 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "url" msgstr "" -#: admin/tab-fields.php:223 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "number" msgstr "" -#: admin/tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "date" msgstr "" -#: admin/tab-fields.php:225 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "hidden" msgstr "" -#: admin/tab-fields.php:227 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "membership" msgstr "" # @ wp-members -#: admin/tab-fields.php:233 admin/tab-fields.php:549 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "पà¥à¤°à¤¦à¤°à¥à¤¶à¤¿à¤¤ करते हैं?" -#: admin/tab-fields.php:237 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 msgid "This field is always displayed" msgstr "" # @ wp-members -#: admin/tab-fields.php:242 admin/tab-fields.php:550 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 msgid "Required?" msgstr "आवशà¥à¤¯à¤•ता है?" -#: admin/tab-fields.php:246 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 msgid "This field is always required" msgstr "" -#: admin/tab-fields.php:252 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 msgid "Allow HTML?" msgstr "" -#: admin/tab-fields.php:259 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 msgid "Placeholder" msgstr "" -#: admin/tab-fields.php:267 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 msgid "Pattern" msgstr "" -#: admin/tab-fields.php:273 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 msgid "Title" msgstr "" -#: admin/tab-fields.php:282 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 msgid "Minimum Value" msgstr "" -#: admin/tab-fields.php:286 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Maximum Value" msgstr "" -#: admin/tab-fields.php:294 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 msgid "Rows" msgstr "" -#: admin/tab-fields.php:298 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Columns" msgstr "" -#: admin/tab-fields.php:306 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 msgid "Accepted file types:" msgstr "" -#: admin/tab-fields.php:311 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" # @ wp-members -#: admin/tab-fields.php:318 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 #, fuzzy msgid "Checked by default?" msgstr "जाà¤à¤š की?" # @ wp-members -#: admin/tab-fields.php:322 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 #, fuzzy msgid "Stored value if checked:" msgstr "चेकबॉकà¥à¤¸ के लिà¤, मान संगà¥à¤°à¤¹à¥€à¤¤ यदि जांचा जाता है:" -#: admin/tab-fields.php:343 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 msgid "Stored values delimiter:" msgstr "" -#: admin/tab-fields.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 msgid "Values (Displayed|Stored):" msgstr "" # @ wp-members -#: admin/tab-fields.php:377 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 msgid "Options should be Option Name|option_value," msgstr "विकलà¥à¤ª का नाम होना चाहिà¤, option_value" # @ wp-members -#: admin/tab-fields.php:381 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 msgid "Visit plugin site for more information" msgstr "अधिक जानकारी के लिठपà¥à¤²à¤—इन साइट पर जाà¤à¤" -#: admin/tab-fields.php:388 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Value" msgstr "" # @ wp-members -#: admin/tab-fields.php:407 admin/tab-fields.php:674 admin/tab-fields.php:675 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 #, fuzzy msgid "Add Field" msgstr "जोड़ना" -#: admin/tab-fields.php:409 admin/tab-fields.php:868 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 msgid "Return to Fields Table" msgstr "" -#: admin/tab-fields.php:449 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 msgid "Drag and drop to reorder fields" msgstr "" # @ wp-members -#: admin/tab-fields.php:455 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 #, fuzzy msgid "Registration Date" msgstr "पंजीकरण पूरा किया" # @ wp-members -#: admin/tab-fields.php:456 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 #, fuzzy msgid "Active" msgstr "सकà¥à¤°à¤¿à¤¯" # @ wp-members -#: admin/tab-fields.php:457 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 #, fuzzy msgid "Registration IP" msgstr "आईपी ​​@ पंजीकरण" -#: admin/tab-fields.php:458 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 msgid "Subscription Type" msgstr "" -#: admin/tab-fields.php:460 admin/user-export.php:58 -msgid "User ID" -msgstr "" - # @ wp-members -#: admin/tab-fields.php:493 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 msgid "Manage Fields" msgstr "फीलà¥à¤¡à¥à¤¸ पà¥à¤°à¤¬à¤‚धित" -#: admin/tab-fields.php:532 -msgid "delete" -msgstr "" - -#: admin/tab-fields.php:546 -msgid "Display Label" -msgstr "" - -#: admin/tab-fields.php:552 -#, fuzzy -msgid "Users Screen" -msgstr "%d उपयोगकरà¥à¤¤à¤¾à¤“ं में सकà¥à¤°à¤¿à¤¯ थे." - -#: admin/tab-fields.php:553 -msgid "Users Search" -msgstr "" - -#: admin/tab-fields.php:555 -msgid "Sort" -msgstr "" - -#: admin/tab-fields.php:596 -msgid "Delete Selected" -msgstr "" - # @ wp-members -#: admin/tab-fields.php:738 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 msgid "WP-Members fields were updated" msgstr "WP-सदसà¥à¤¯ फ़ीलà¥à¤¡à¥à¤¸ अपडेट की गई थीं" -#: admin/tab-fields.php:760 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 msgid "Field Label is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:761 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:763 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: admin/tab-fields.php:770 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 msgid "A field with that meta key already exists" msgstr "" -#: admin/tab-fields.php:775 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 #, php-format msgid "" "Sorry, \"%s\" is a http://butlerblog.com/wp-members. Veja uma " -"demo em http://butlerblog.com/" -"wpmembers. WP-Members(tm) é uma marca registrada de butlerblog.com." - -#: admin/dialogs.php:171 -#, fuzzy -msgid "Online User Guide" -msgstr "Aviso de confirmação de atualização de dados do usuário:" - -#: admin/dialogs.php:172 -msgid "FAQs" -msgstr "" - -#: admin/dialogs.php:179 -#, fuzzy -msgid "Thank you for using WP-Members" -msgstr "Obrigado por usar o WP-Members! Você está a utilizar a versão" - -#: admin/dialogs.php:180 -msgid "A plugin developed by" -msgstr "" - -#: admin/dialogs.php:181 -msgid "Follow" -msgstr "Seguir" - -#: admin/dialogs.php:198 admin/dialogs.php:202 -msgid "Latest from RocketGeek" -msgstr "" - -#: admin/dialogs.php:219 -msgid "Like WP-Members?" -msgstr "" - -#: admin/dialogs.php:220 -#, php-format -msgid "" -"If you like WP-Members please give it a %s★★★★★" -"%s rating. Thanks!!" -msgstr "" - -#: admin/dialogs.php:231 admin/dialogs.php:244 -msgid "Latest from ButlerBlog" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:256 +#: includes/admin/class-wp-members-admin-api.php:292 msgid "Custom email" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:257 -#: admin/includes/class-wp-members-admin-api.php:259 +#: includes/admin/class-wp-members-admin-api.php:293 +#: includes/admin/class-wp-members-admin-api.php:295 msgid "Subject" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:260 +#: includes/admin/class-wp-members-admin-api.php:296 msgid "Body" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:262 +#: includes/admin/class-wp-members-admin-api.php:298 msgid "Your custom email message content." msgstr "" -#: admin/includes/class-wp-members-admin-api.php:340 +#: includes/admin/class-wp-members-admin-api.php:376 msgid "Options" msgstr "Opções" -#: admin/includes/class-wp-members-admin-api.php:341 +#: includes/admin/class-wp-members-admin-api.php:377 msgid "Fields" msgstr "Campos" -#: admin/includes/class-wp-members-admin-api.php:342 +#: includes/admin/class-wp-members-admin-api.php:378 #, fuzzy msgid "Dialogs" msgstr "Notificações de Atualização" -#: admin/includes/class-wp-members-admin-api.php:343 +#: includes/admin/class-wp-members-admin-api.php:379 #, fuzzy msgid "Emails" msgstr "eMail" -#: admin/includes/class-wp-members-admin-api.php:359 +#: includes/admin/class-wp-members-admin-api.php:395 msgid "New Registration" msgstr "Moderar Registo:" -#: admin/includes/class-wp-members-admin-api.php:368 +#: includes/admin/class-wp-members-admin-api.php:404 msgid "Registration is Moderated" msgstr "Aviso de processo de registo completo:" -#: admin/includes/class-wp-members-admin-api.php:374 +#: includes/admin/class-wp-members-admin-api.php:410 #, fuzzy msgid "Registration is Moderated, User is Approved" msgstr "Aviso de processo de registo completo:" -#: admin/includes/class-wp-members-admin-api.php:382 +#: includes/admin/class-wp-members-admin-api.php:418 msgid "Password Reset" msgstr "Aviso de confirmação de redefinição de password:" -#: admin/includes/class-wp-members-admin-api.php:389 +#: includes/admin/class-wp-members-admin-api.php:425 msgid "Retrieve Username" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:397 +#: includes/admin/class-wp-members-admin-api.php:433 #, fuzzy msgid "Admin Notification" msgstr "Notificar Administrador:" -#: admin/includes/class-wp-members-admin-api.php:423 +#: includes/admin/class-wp-members-admin-api.php:459 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Aviso para posts ou páginas restritos, exibido acima do formulário de login:" -#: admin/includes/class-wp-members-admin-api.php:424 +#: includes/admin/class-wp-members-admin-api.php:460 msgid "Username is taken" msgstr "Username já registado" -#: admin/includes/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:461 msgid "Email is registered" msgstr "Email já registado" -#: admin/includes/class-wp-members-admin-api.php:426 +#: includes/admin/class-wp-members-admin-api.php:462 msgid "Registration completed" msgstr "Registo completo" -#: admin/includes/class-wp-members-admin-api.php:427 +#: includes/admin/class-wp-members-admin-api.php:463 msgid "User update" msgstr "Aviso de confirmação de atualização de dados do usuário:" -#: admin/includes/class-wp-members-admin-api.php:428 +#: includes/admin/class-wp-members-admin-api.php:464 msgid "Passwords did not match" msgstr "As passwords não coincidem" -#: admin/includes/class-wp-members-admin-api.php:429 +#: includes/admin/class-wp-members-admin-api.php:465 msgid "Password changes" msgstr "Aviso de confirmação de alteração de senha:" -#: admin/includes/class-wp-members-admin-api.php:430 +#: includes/admin/class-wp-members-admin-api.php:466 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "Aviso para nome de usuário ou email não encontrado durante tentativa de " "reiniciar uma senha esquecida:" -#: admin/includes/class-wp-members-admin-api.php:431 +#: includes/admin/class-wp-members-admin-api.php:467 msgid "Password reset" msgstr "Redefinição de password" -#: admin/includes/class-wp-members-admin-api.php:564 +#: includes/admin/class-wp-members-admin-api.php:623 msgid "Settings" msgstr "Configurações" -#: admin/includes/class-wp-members-products-admin.php:57 +#: includes/admin/class-wp-members-admin-posts.php:30 +#: includes/admin/class-wp-members-admin-posts.php:33 +msgid "Unblock" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:31 +#: includes/admin/class-wp-members-admin-posts.php:34 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 +#, fuzzy +msgid "Block" +msgstr "Bloquear Posts por Padrão:" + +#: includes/admin/class-wp-members-admin-posts.php:32 +#: includes/admin/class-wp-members-admin-posts.php:35 +msgid "Hide" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s blocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:165 +#, php-format +msgid "%s Restriction" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:195 +msgid "Unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:196 +msgid "Blocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:197 +msgid "Hidden" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +msgid "Status:" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:68 +#: includes/admin/tabs/class-wp-members-fields-table.php:65 +#: includes/walkers/class-wp-members-walker-nav-menu.php:140 +#, fuzzy +msgid "Edit" +msgstr "Edite suas Informações" + +#: includes/admin/class-wp-members-admin-posts.php:218 +msgid "Ok" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:219 +#: includes/walkers/class-wp-members-walker-nav-menu.php:224 +msgid "Cancel" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:305 +#: includes/admin/class-wp-members-products-admin.php:629 +msgid "Status" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:28 +#: includes/admin/class-wp-members-admin-users.php:33 +#: includes/admin/class-wp-members-admin-users.php:59 +msgid "Activate" +msgstr "Activar" + +#: includes/admin/class-wp-members-admin-users.php:29 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:62 +msgid "Deactivate" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:31 +#: includes/admin/class-wp-members-admin-users.php:36 +msgid "Export" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:37 +#: includes/admin/class-wp-members-admin-users.php:88 +#, fuzzy +msgid "Export All Users" +msgstr "Log In" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:129 +msgid "No users selected" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 +msgid "You cannot activate or deactivate yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:152 +#, php-format +msgid "%s activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:157 +#, php-format +msgid "%s deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:161 +msgid "That user is already active" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:288 +msgid "Pending" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:289 +msgid "Trial" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:290 +#: includes/admin/class-wp-members-export.php:74 +msgid "Subscription" +msgstr "Subscrição" + +#: includes/admin/class-wp-members-admin-users.php:291 +msgid "Expired" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:294 +msgid "Activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:295 +msgid "Pending Activation" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:296 +msgid "Deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:298 +msgid "Not Exported" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:387 +#: includes/admin/class-wp-members-export.php:160 +msgid "No" +msgstr "" + +#: includes/admin/class-wp-members-export.php:64 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-export.php:65 +#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 +msgid "Username" +msgstr "Utilizador" + +#: includes/admin/class-wp-members-export.php:71 +msgid "Activated?" +msgstr "Ativo?" + +#: includes/admin/class-wp-members-export.php:75 +#: includes/admin/class-wp-members-products-admin.php:64 +#: includes/admin/class-wp-members-products-admin.php:632 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 +msgid "Expires" +msgstr "" + +#: includes/admin/class-wp-members-export.php:77 +msgid "Registered" +msgstr "Registado" + +#: includes/admin/class-wp-members-export.php:78 +#, fuzzy +msgid "IP" +msgstr "Registo completo" + +#: includes/admin/class-wp-members-export.php:160 +#: includes/admin/class-wp-members-products-admin.php:104 +msgid "Yes" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:62 msgid "Slug" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:58 +#: includes/admin/class-wp-members-products-admin.php:63 msgid "Role" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:59 -#: admin/includes/class-wp-members-products-admin.php:162 -#: admin/tab-fields.php:459 admin/user-export.php:69 -msgid "Expires" +#: includes/admin/class-wp-members-products-admin.php:66 +msgid "Default" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:60 +#: includes/admin/class-wp-members-products-admin.php:68 msgid "Last updated" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:80 +#: includes/admin/class-wp-members-products-admin.php:92 +msgid "slug:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:95 msgid "No role required" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:84 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "Does not expire" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:120 +#: includes/admin/class-wp-members-products-admin.php:140 msgid "Membership Product Details" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 -#: admin/includes/class-wp-members-products-admin.php:167 +#: includes/admin/class-wp-members-products-admin.php:148 +msgid "Membership Product Message (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 +msgid "Posts" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#, fuzzy +msgid "Pages" +msgstr "Bloquear Páginas por Padrão:" + +#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:235 +#: includes/admin/class-wp-members-products-admin.php:280 msgid "Period" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Day" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Week" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Month" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Year" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:199 msgid "Name (slug)" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:153 -msgid "Role Required?" +#: includes/admin/class-wp-members-products-admin.php:201 +msgid "Optional Defaults" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:156 +#: includes/admin/class-wp-members-products-admin.php:204 +msgid "Assign as default at registration? (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:212 +#, php-format +msgid "Pre-selected by default for new %s" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:218 +msgid "Optional Properties" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:221 +msgid "Role Required? (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:224 msgid "No Role" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:164 -#: admin/includes/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:230 +msgid "Expires (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:232 +#: includes/admin/class-wp-members-products-admin.php:234 +#: includes/admin/class-wp-members-products-admin.php:277 +#: includes/admin/class-wp-members-products-admin.php:279 msgid "Number" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:245 -#: admin/tab-options.php:207 inc/class-wp-members-forms.php:999 -#: inc/class-wp-members-user-profile.php:106 inc/deprecated.php:360 -#: inc/deprecated.php:622 +#: includes/admin/class-wp-members-products-admin.php:240 +msgid "Use \"no gap\" renewal" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:244 +msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:261 +msgid "Period Start (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:262 +msgid "Period End (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:275 +msgid "Fixed period grace period" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:284 +msgid "" +"Grace period is the point at which expiration date is for following time " +"period. For example, if user who register August 1st would be part of the " +"following year's Sept 1 - Aug 31 membership, set this at 1 Month. Leave " +"blank for no grace period." +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:333 +msgid "" +"Restricted Message (displays when a user does not have access to a " +"membership)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:435 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 +#: includes/class-wp-members-forms.php:1092 +#: includes/class-wp-members-user-profile.php:112 msgid "None" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:251 +#: includes/admin/class-wp-members-products-admin.php:450 msgid "Limit access to:" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:321 +#: includes/admin/class-wp-members-products-admin.php:520 msgid "Required Membership" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:360 +#: includes/admin/class-wp-members-products-admin.php:559 +#: includes/admin/class-wp-members-products-admin.php:630 msgid "Membership" msgstr "" -#: admin/post.php:45 admin/post.php:48 -msgid "Unblock" +#: includes/admin/class-wp-members-products-admin.php:599 +#: includes/class-wp-members-products.php:308 +msgid "Memberships" msgstr "" -#: admin/post.php:46 admin/post.php:49 admin/tab-options.php:114 -#, fuzzy -msgid "Block" -msgstr "Bloquear Posts por Padrão:" +#: includes/admin/class-wp-members-products-admin.php:626 +msgid "Product Access" +msgstr "" -#: admin/post.php:47 admin/post.php:50 -msgid "Hide" +#: includes/admin/class-wp-members-products-admin.php:631 +msgid "Enabled?" msgstr "" -#: admin/post.php:138 +#: includes/admin/class-wp-members-products-admin.php:641 +msgid "Enable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:642 +msgid "Disable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:647 +msgid "Expiration date (optional)" +msgstr "" + +#: includes/admin/dialogs.php:117 +msgid "" +"Your WP settings allow anyone to register - this is not the recommended " +"setting." +msgstr "" +"Suas configurações do WordPress permitem que qualquer um se registre. Esta " +"não é uma configuração recomendada." + +#: includes/admin/dialogs.php:118 #, php-format -msgid "%s blocked" +msgid "" +"You can %s change this here %s making sure the box next to \"Anyone can " +"register\" is unchecked." +msgstr "" + +#: includes/admin/dialogs.php:119 +msgid "" +"This setting allows a link on the /wp-login.php page to register using the " +"WP native registration process thus circumventing any registration you are " +"using with WP-Members. In some cases, this may suit the users wants/needs, " +"but most users should uncheck this option. If you do not change this " +"setting, you can choose to ignore these warning messages under WP-Members " +"Settings." +msgstr "" +"Esta configuração permite o registro de usuários através de um link na " +"página /wp-login.php usando o processo nativo de registro do WordPress, " +"contornando assim qualquer registro de usuário que você esteja realizando " +"através do WP-Members. Em alguns casos, isso pode atender os usuários que " +"querem/precisam, mas a maioria dos usuários deve desmarcar essa opção. Se " +"você não quiser mudar esta configuração, pode optar por ignorar esta " +"mensagem de aviso nas Opções de Gerenciamento do WP-Membros." + +#: includes/admin/dialogs.php:123 +msgid "" +"Your WP settings allow anyone to comment - this is not the recommended " +"setting." msgstr "" +"Suas configurações do WordPress permitem que qualquer possa comentar. Esta " +"não é uma configuração recomendada." -#: admin/post.php:138 +#: includes/admin/dialogs.php:124 #, php-format -msgid "%s unblocked" +msgid "" +"You can %s change this here %s by checking the box next to \"Users must be " +"registered and logged in to comment.\"" +msgstr "" + +#: includes/admin/dialogs.php:125 +msgid "" +"This setting allows any users to comment, whether or not they are " +"registered. Depending on how you are using WP-Members will determine whether " +"you should change this setting or not. If you do not change this setting, " +"you can choose to ignore these warning messages under WP-Members Settings." +msgstr "" +"Esta configuração permite a qualquer usuário comentar, independente de estar " +"registrado ou não. A forma como você está utilizando o WP-Members irá " +"determinar se você deve ou não alterar esta configuração. Se você não quiser " +"mudar esta configuração, pode optar por ignorar esta mensagem de aviso nas " +"Opções de Gerenciamento do WP-Membros." + +#: includes/admin/dialogs.php:129 +msgid "" +"Your WP settings allow full text rss feeds - this is not the recommended " +"setting." msgstr "" +"Suas configurações do WordPress permitem feeds RSS com texto completo. Esta " +"não é uma configuração recomendada." -#: admin/post.php:177 +#: includes/admin/dialogs.php:130 #, php-format -msgid "%s Restriction" +msgid "" +"You can %s change this here %s by changing \"For each article in a feed, show" +"\" to \"Summary.\"" +msgstr "" + +#: includes/admin/dialogs.php:131 +msgid "" +"Leaving this set to full text allows anyone to read your protected content " +"in an RSS reader. Changing this to Summary prevents this as your feeds will " +"only show summary text." +msgstr "" +"Deixando esta configuração ajustada para texto completo, permitirá a " +"qualquer um ler seu conteúdo protegido num leitor RSS. Alterar isto para " +"\"Sumário\" assegura que seus feeds vão exibir somente um resumo." + +#: includes/admin/dialogs.php:135 +msgid "You have set WP-Members to hold registrations for approval" +msgstr "" +"Você ajustou o WP-Members para interceptar seus registros de usuário para " +"aprovação." + +#: includes/admin/dialogs.php:136 +msgid "" +"but you have not changed the default message for \"Registration Completed\" " +"under \"WP-Members Dialogs and Error Messages.\" You should change this " +"message to let users know they are pending approval." +msgstr "" + +#: includes/admin/dialogs.php:140 +msgid "You have turned on reCAPTCHA" +msgstr "" + +#: includes/admin/dialogs.php:141 +msgid "" +"but you have not entered API keys. You will need both a public and private " +"key. The CAPTCHA will not display unless a valid API key is included." msgstr "" -#: admin/post.php:206 -msgid "Unblocked" +#: includes/admin/dialogs.php:145 +msgid "You have active settings that are not recommended." msgstr "" -#: admin/post.php:207 -msgid "Blocked" +#: includes/admin/dialogs.php:146 +msgid "" +"If you will not be changing these settings, you can turn off these warning " +"messages by checking the \"Ignore warning messages\" in the settings below." msgstr "" -#: admin/post.php:208 -msgid "Hidden" +#: includes/admin/dialogs.php:174 +msgid "Version:" +msgstr "Versão:" + +#: includes/admin/dialogs.php:175 +#, fuzzy +msgid "Quick Start Guide" msgstr "" +"Restrição de acesso e registo no WordPress. Para maiores informações e para " +"baixar o \"guia de início rápido\" gratuito, visite http://butlerblog.com/wp-members. Veja uma " +"demo em http://butlerblog.com/" +"wpmembers. WP-Members(tm) é uma marca registrada de butlerblog.com." -#: admin/post.php:214 -msgid "Status:" +#: includes/admin/dialogs.php:176 +#, fuzzy +msgid "Online User Guide" +msgstr "Aviso de confirmação de atualização de dados do usuário:" + +#: includes/admin/dialogs.php:177 +msgid "FAQs" msgstr "" -#: admin/post.php:214 admin/tab-fields.php:88 admin/tab-fields.php:554 +#: includes/admin/dialogs.php:184 #, fuzzy -msgid "Edit" -msgstr "Edite suas Informações" +msgid "Thank you for using WP-Members" +msgstr "Obrigado por usar o WP-Members! Você está a utilizar a versão" -#: admin/post.php:229 -msgid "Ok" +#: includes/admin/dialogs.php:185 +msgid "A plugin developed by" msgstr "" -#: admin/post.php:230 -msgid "Cancel" +#: includes/admin/dialogs.php:186 +msgid "Follow" +msgstr "Seguir" + +#: includes/admin/dialogs.php:203 includes/admin/dialogs.php:207 +msgid "Latest from RocketGeek" msgstr "" -#: admin/post.php:314 -msgid "Status" +#: includes/admin/dialogs.php:224 +msgid "Like WP-Members?" +msgstr "" + +#: includes/admin/dialogs.php:225 +#, php-format +msgid "" +"If you like WP-Members please give it a %s★★★★★" +"%s rating. Thanks!!" msgstr "" -#: admin/tab-about.php:34 admin/tab-about.php:54 -msgid "About WP-Members" +#: includes/admin/dialogs.php:236 includes/admin/dialogs.php:249 +msgid "Latest from ButlerBlog" msgstr "" -#: admin/tab-captcha.php:66 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:67 #, php-format msgid "See the %sUsers Guide on CAPTCHA%s." msgstr "" -#: admin/tab-captcha.php:73 admin/tab-dialogs.php:57 admin/tab-emails.php:101 -#: admin/tab-fields.php:153 admin/tab-options.php:82 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" -#: admin/tab-captcha.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 msgid "Manage reCAPTCHA Options" msgstr "Gerenciar Opções do reCAPTCHA" -#: admin/tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 msgid "" "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " "while blocking spam on your blog." @@ -465,7 +703,7 @@ msgstr "" "reCAPTCHA é um serviço de CAPTCHA gratuito e acessível que ajuda a " "digitalizar livros enquanto bloqueia spam no seu blog." -#: admin/tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 #, fuzzy, php-format msgid "" "reCAPTCHA asks commenters to retype two words scanned from a book to prove " @@ -480,11 +718,12 @@ msgstr "" "Desda forma, você obtém menos spam e o mundo recebe melhores digitalizações " "de livros. Todo mundo ganha! Para detalhes, visite o" -#: admin/tab-captcha.php:104 admin/tab-captcha.php:130 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 msgid "reCAPTCHA Keys" msgstr "Chaves do reCAPTCHA" -#: admin/tab-captcha.php:106 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 #, fuzzy, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " @@ -493,507 +732,470 @@ msgstr "" "reCAPTCHA exige uma Chave API (\"API Key\"), que consiste em um par de " "chaves \"pública\" e \"privada\". Você pode se registrar para uma" -#: admin/tab-captcha.php:107 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 msgid "Public Key" msgstr "Chave Pública" -#: admin/tab-captcha.php:108 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 msgid "Private Key" msgstr "Chave Privada" -#: admin/tab-captcha.php:112 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 msgid "Choose Theme" msgstr "Selecione o Tema" -#: admin/tab-captcha.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 msgid "Red" msgstr "Vermelho" -#: admin/tab-captcha.php:116 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 msgid "White" msgstr "Branco" -#: admin/tab-captcha.php:117 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 msgid "Black Glass" msgstr "Vidro Fumê" -#: admin/tab-captcha.php:118 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 msgid "Clean" msgstr "Limpo" -#: admin/tab-captcha.php:132 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 msgid "Site Key" msgstr "" -#: admin/tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 msgid "Secret Key" msgstr "" -#: admin/tab-captcha.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 msgid "Characters for image" msgstr "" -#: admin/tab-captcha.php:169 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 msgid "Number of characters" msgstr "" -#: admin/tab-captcha.php:173 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 msgid "Image dimensions" msgstr "" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Width" msgstr "" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Height" msgstr "" -#: admin/tab-captcha.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Font color of characters" msgstr "" -#: admin/tab-captcha.php:181 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Background color of image" msgstr "" -#: admin/tab-captcha.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Font size" msgstr "" -#: admin/tab-captcha.php:189 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Width between characters" msgstr "" -#: admin/tab-captcha.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 #, fuzzy msgid "Image type" msgstr "Campo" -#: admin/tab-captcha.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: admin/tab-captcha.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 #, fuzzy msgid "Update CAPTCHA Settings" msgstr "Atualizar Configuração do reCAPTCHA" -#: admin/tab-captcha.php:301 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 #, fuzzy msgid "CAPTCHA was updated for WP-Members" msgstr "WP-Members" -#: admin/tab-dialogs.php:67 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:67 msgid "Dialogs and Error Messages" msgstr "Notificações e Mensagens de Erro" -#: admin/tab-dialogs.php:69 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:69 #, fuzzy, php-format msgid "" "You can customize the text for dialogs and error messages. Simple HTML is " "allowed %s etc." msgstr "Você pode customizar os textos a seguir. HTML simples é permitido." -#: admin/tab-dialogs.php:80 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:80 msgid "Terms of Service (TOS)" msgstr "" -#: admin/tab-dialogs.php:87 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:87 msgid "Update Dialogs" msgstr "Notificações de Atualização" -#: admin/tab-dialogs.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:124 #, fuzzy msgid "WP-Members dialogs were updated" msgstr "Campos Adicionais do WP-Members" -#: admin/tab-dropins.php:78 admin/tab-dropins.php:378 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:88 +#: includes/admin/tabs/class-wp-members-dropins-table.php:180 msgid "WP-Members Dropin settings were updated" msgstr "" -#: admin/tab-dropins.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:216 msgid "Manage Dropins" msgstr "" -#: admin/tab-dropins.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:217 msgid "Current dropin folder: " msgstr "" -#: admin/tab-dropins.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:218 msgid "" "You can change location of the dropin folder using the " "wpmem_dropin_folder filter." msgstr "" -#: admin/tab-dropins.php:269 -msgid "Name" -msgstr "" - -#: admin/tab-dropins.php:270 -msgid "File" -msgstr "" - -#: admin/tab-dropins.php:271 -msgid "Version" -msgstr "" - -#: admin/tab-dropins.php:272 -msgid "Description" -msgstr "" - -#: admin/tab-dropins.php:315 admin/tab-fields.php:597 -msgid "Save Settings" -msgstr "" - -#: admin/tab-emails.php:58 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:57 #, fuzzy msgid "Email Messages" msgstr "eMail" -#: admin/tab-emails.php:61 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:60 msgid "You can customize the content of the emails sent by the plugin." msgstr "" -#: admin/tab-emails.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:62 msgid "A list of shortcodes is available here." msgstr "" -#: admin/tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:69 #, fuzzy msgid "Set a custom email address" msgstr "Inseriu um username ou password inválidos." -#: admin/tab-emails.php:71 admin/tab-emails.php:75 admin/tab-emails.php:85 -#: admin/tab-fields.php:179 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 msgid "(optional)" msgstr "" -#: admin/tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:73 #, fuzzy msgid "Set a custom email name" msgstr "Inseriu um username ou password inválidos." -#: admin/tab-emails.php:85 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 msgid "Email Signature" msgstr "Aviso de email já registado:" -#: admin/tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 #, fuzzy msgid "Update Emails" msgstr "Aviso de confirmação de atualização de dados do usuário:" -#: admin/tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 #, fuzzy msgid "WP-Members emails were updated" msgstr "WP-Members possui direitos autorais" -#: admin/tab-fields.php:113 inc/class-wp-members.php:1207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 +#: includes/class-wp-members.php:1498 msgid "No fields selected for deletion" msgstr "" -#: admin/tab-fields.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:95 msgid "Are you sure you want to delete the following fields?" msgstr "" -#: admin/tab-fields.php:141 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:122 msgid "Fields deleted" msgstr "" -#: admin/tab-fields.php:155 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:136 msgid "Field Manager Documentation" msgstr "" -#: admin/tab-fields.php:180 admin/tab-fields.php:322 -#: inc/class-wp-members-user-profile.php:138 inc/deprecated.php:385 -#: inc/deprecated.php:646 inc/wp-registration.php:57 -#: inc/wp-registration.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/class-wp-members-forms.php:1626 +#: includes/class-wp-members-forms.php:1803 +#: includes/class-wp-members-user-profile.php:144 msgid "(required)" msgstr "Requerido?" -#: admin/tab-fields.php:185 admin/tab-fields.php:407 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 #, fuzzy msgid "Edit Field" msgstr "Edite suas Informações" -#: admin/tab-fields.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 #, fuzzy msgid "Add a Field" msgstr "Campo" -#: admin/tab-fields.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 msgid "Field Label" msgstr "Campo" -#: admin/tab-fields.php:192 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: admin/tab-fields.php:195 admin/tab-fields.php:547 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: admin/tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: admin/tab-fields.php:205 admin/tab-fields.php:548 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-fields-table.php:59 #, fuzzy msgid "Field Type" msgstr "Campo" -#: admin/tab-fields.php:211 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 #, fuzzy msgid "text" msgstr "" "Suas configurações do WordPress permitem feeds RSS com texto completo. Esta " "não é uma configuração recomendada." -#: admin/tab-fields.php:212 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 msgid "email" msgstr "" -#: admin/tab-fields.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "textarea" msgstr "" -#: admin/tab-fields.php:214 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 #, fuzzy msgid "checkbox" msgstr "Campos Adicionais do WP-Members" -#: admin/tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "multiple checkbox" msgstr "" -#: admin/tab-fields.php:216 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "select (dropdown)" msgstr "" -#: admin/tab-fields.php:217 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple select" msgstr "" -#: admin/tab-fields.php:218 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "radio group" msgstr "" -#: admin/tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "password" msgstr "Password" -#: admin/tab-fields.php:220 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "image" msgstr "" -#: admin/tab-fields.php:221 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "file" msgstr "" -#: admin/tab-fields.php:222 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "url" msgstr "" -#: admin/tab-fields.php:223 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "number" msgstr "" -#: admin/tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "date" msgstr "" -#: admin/tab-fields.php:225 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "hidden" msgstr "" -#: admin/tab-fields.php:227 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "membership" msgstr "" -#: admin/tab-fields.php:233 admin/tab-fields.php:549 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Exibir?" -#: admin/tab-fields.php:237 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 msgid "This field is always displayed" msgstr "" -#: admin/tab-fields.php:242 admin/tab-fields.php:550 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 msgid "Required?" msgstr "Requerido?" -#: admin/tab-fields.php:246 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 msgid "This field is always required" msgstr "" -#: admin/tab-fields.php:252 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 msgid "Allow HTML?" msgstr "" -#: admin/tab-fields.php:259 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 msgid "Placeholder" msgstr "" -#: admin/tab-fields.php:267 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 msgid "Pattern" msgstr "" -#: admin/tab-fields.php:273 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 msgid "Title" msgstr "" -#: admin/tab-fields.php:282 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 msgid "Minimum Value" msgstr "" -#: admin/tab-fields.php:286 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Maximum Value" msgstr "" -#: admin/tab-fields.php:294 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 msgid "Rows" msgstr "" -#: admin/tab-fields.php:298 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Columns" msgstr "" -#: admin/tab-fields.php:306 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 msgid "Accepted file types:" msgstr "" -#: admin/tab-fields.php:311 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: admin/tab-fields.php:318 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 #, fuzzy msgid "Checked by default?" msgstr "Bloquear Posts por Padrão:" -#: admin/tab-fields.php:322 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 #, fuzzy msgid "Stored value if checked:" msgstr "Bloquear Posts por Padrão:" -#: admin/tab-fields.php:343 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 msgid "Stored values delimiter:" msgstr "" -#: admin/tab-fields.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 msgid "Values (Displayed|Stored):" msgstr "" -#: admin/tab-fields.php:377 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 msgid "Options should be Option Name|option_value," msgstr "" -#: admin/tab-fields.php:381 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 msgid "Visit plugin site for more information" msgstr "" -#: admin/tab-fields.php:388 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Value" msgstr "" -#: admin/tab-fields.php:407 admin/tab-fields.php:674 admin/tab-fields.php:675 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 #, fuzzy msgid "Add Field" msgstr "Campo" -#: admin/tab-fields.php:409 admin/tab-fields.php:868 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 msgid "Return to Fields Table" msgstr "" -#: admin/tab-fields.php:449 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 msgid "Drag and drop to reorder fields" msgstr "" -#: admin/tab-fields.php:455 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 #, fuzzy msgid "Registration Date" msgstr "Registo completo" -#: admin/tab-fields.php:456 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 #, fuzzy msgid "Active" msgstr "Activar" -#: admin/tab-fields.php:457 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 #, fuzzy msgid "Registration IP" msgstr "Registo completo" -#: admin/tab-fields.php:458 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 msgid "Subscription Type" msgstr "" -#: admin/tab-fields.php:460 admin/user-export.php:58 -msgid "User ID" -msgstr "" - -#: admin/tab-fields.php:493 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 msgid "Manage Fields" msgstr "Gerenciar Campos" -#: admin/tab-fields.php:532 -msgid "delete" -msgstr "" - -#: admin/tab-fields.php:546 -msgid "Display Label" -msgstr "" - -#: admin/tab-fields.php:552 -#, fuzzy -msgid "Users Screen" -msgstr "Log In" - -#: admin/tab-fields.php:553 -msgid "Users Search" -msgstr "" - -#: admin/tab-fields.php:555 -msgid "Sort" -msgstr "" - -#: admin/tab-fields.php:596 -msgid "Delete Selected" -msgstr "" - -#: admin/tab-fields.php:738 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 #, fuzzy msgid "WP-Members fields were updated" msgstr "Campos Adicionais do WP-Members" -#: admin/tab-fields.php:760 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 msgid "Field Label is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:761 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:763 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: admin/tab-fields.php:770 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 msgid "A field with that meta key already exists" msgstr "" -#: admin/tab-fields.php:775 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 #, php-format msgid "" "Sorry, \"%s\" is a " -"http://butlerblog.com/wp-members . Quick Start Guide je k " -"dispozícii tiež. WP-Älenov (TM) je obchodná znaÄka butlerblog.com." - -#: admin/dialogs.php:171 -#, fuzzy -msgid "Online User Guide" -msgstr "Používateľom aktualizácie" - -#: admin/dialogs.php:172 -msgid "FAQs" -msgstr "" - -#: admin/dialogs.php:179 -#, fuzzy -msgid "Thank you for using WP-Members" -msgstr "ÄŽakujeme, že používate WP Älenov! Používate verziu %s" - -#: admin/dialogs.php:180 -msgid "A plugin developed by" -msgstr "" - -#: admin/dialogs.php:181 -msgid "Follow" -msgstr "Postupujte" - -#: admin/dialogs.php:198 admin/dialogs.php:202 -msgid "Latest from RocketGeek" -msgstr "" - -#: admin/dialogs.php:219 -msgid "Like WP-Members?" -msgstr "" - -#: admin/dialogs.php:220 -#, php-format -msgid "" -"If you like WP-Members please give it a %s★★★★★" -"%s rating. Thanks!!" -msgstr "" - -#: admin/dialogs.php:231 admin/dialogs.php:244 -msgid "Latest from ButlerBlog" -msgstr "" - -#: admin/includes/class-wp-members-admin-api.php:256 +#: includes/admin/class-wp-members-admin-api.php:292 msgid "Custom email" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:257 -#: admin/includes/class-wp-members-admin-api.php:259 +#: includes/admin/class-wp-members-admin-api.php:293 +#: includes/admin/class-wp-members-admin-api.php:295 msgid "Subject" msgstr "Predmet" -#: admin/includes/class-wp-members-admin-api.php:260 +#: includes/admin/class-wp-members-admin-api.php:296 msgid "Body" msgstr "Telo" -#: admin/includes/class-wp-members-admin-api.php:262 +#: includes/admin/class-wp-members-admin-api.php:298 msgid "Your custom email message content." msgstr "" -#: admin/includes/class-wp-members-admin-api.php:340 +#: includes/admin/class-wp-members-admin-api.php:376 msgid "Options" msgstr "Možnosti" -#: admin/includes/class-wp-members-admin-api.php:341 +#: includes/admin/class-wp-members-admin-api.php:377 msgid "Fields" msgstr "Polia" -#: admin/includes/class-wp-members-admin-api.php:342 +#: includes/admin/class-wp-members-admin-api.php:378 msgid "Dialogs" msgstr "Dialógové okná" -#: admin/includes/class-wp-members-admin-api.php:343 +#: includes/admin/class-wp-members-admin-api.php:379 msgid "Emails" msgstr "E-mailov" -#: admin/includes/class-wp-members-admin-api.php:359 +#: includes/admin/class-wp-members-admin-api.php:395 msgid "New Registration" msgstr "Nový zápis" -#: admin/includes/class-wp-members-admin-api.php:368 +#: includes/admin/class-wp-members-admin-api.php:404 msgid "Registration is Moderated" msgstr "Registrácia je moderovaná" -#: admin/includes/class-wp-members-admin-api.php:374 +#: includes/admin/class-wp-members-admin-api.php:410 msgid "Registration is Moderated, User is Approved" msgstr "Registrácia je moderovaná, schválené používateľom" -#: admin/includes/class-wp-members-admin-api.php:382 +#: includes/admin/class-wp-members-admin-api.php:418 msgid "Password Reset" msgstr "Vynulovanie hesla" -#: admin/includes/class-wp-members-admin-api.php:389 +#: includes/admin/class-wp-members-admin-api.php:425 msgid "Retrieve Username" msgstr "" -#: admin/includes/class-wp-members-admin-api.php:397 +#: includes/admin/class-wp-members-admin-api.php:433 msgid "Admin Notification" msgstr "Admin oznámenia" -#: admin/includes/class-wp-members-admin-api.php:423 +#: includes/admin/class-wp-members-admin-api.php:459 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Vyhradené miesto (alebo stránky), zobrazí nad prihlasovacie/registraÄný " "formulár" -#: admin/includes/class-wp-members-admin-api.php:424 +#: includes/admin/class-wp-members-admin-api.php:460 msgid "Username is taken" msgstr "BraÅ¥ meno" -#: admin/includes/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:461 msgid "Email is registered" msgstr "E-mail je registrovaný" -#: admin/includes/class-wp-members-admin-api.php:426 +#: includes/admin/class-wp-members-admin-api.php:462 msgid "Registration completed" msgstr "Registrácia dokonÄená" -#: admin/includes/class-wp-members-admin-api.php:427 +#: includes/admin/class-wp-members-admin-api.php:463 msgid "User update" msgstr "Používateľom aktualizácie" -#: admin/includes/class-wp-members-admin-api.php:428 +#: includes/admin/class-wp-members-admin-api.php:464 msgid "Passwords did not match" msgstr "Passwords did not match" -#: admin/includes/class-wp-members-admin-api.php:429 +#: includes/admin/class-wp-members-admin-api.php:465 msgid "Password changes" msgstr "Zmeny hesla" -#: admin/includes/class-wp-members-admin-api.php:430 +#: includes/admin/class-wp-members-admin-api.php:466 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "Uživateľské meno alebo e-mail neexistujú pri pokuse o obnovenie zabudnutého " "hesla" -#: admin/includes/class-wp-members-admin-api.php:431 +#: includes/admin/class-wp-members-admin-api.php:467 msgid "Password reset" msgstr "Vynulovanie hesla" -#: admin/includes/class-wp-members-admin-api.php:564 +#: includes/admin/class-wp-members-admin-api.php:623 msgid "Settings" msgstr "Nastavenia" -#: admin/includes/class-wp-members-products-admin.php:57 -msgid "Slug" +#: includes/admin/class-wp-members-admin-posts.php:30 +#: includes/admin/class-wp-members-admin-posts.php:33 +msgid "Unblock" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:58 -msgid "Role" +#: includes/admin/class-wp-members-admin-posts.php:31 +#: includes/admin/class-wp-members-admin-posts.php:34 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 +#, fuzzy +msgid "Block" +msgstr "Blok miest v predvolenom nastavení" + +#: includes/admin/class-wp-members-admin-posts.php:32 +#: includes/admin/class-wp-members-admin-posts.php:35 +msgid "Hide" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s blocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:125 +#, php-format +msgid "%s unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:165 +#, php-format +msgid "%s Restriction" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:195 +msgid "Unblocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:196 +msgid "Blocked" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:197 +msgid "Hidden" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +msgid "Status:" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:68 +#: includes/admin/tabs/class-wp-members-fields-table.php:65 +#: includes/walkers/class-wp-members-walker-nav-menu.php:140 +#, fuzzy +msgid "Edit" +msgstr "UpraviÅ¥ vaÅ¡e informácie" + +#: includes/admin/class-wp-members-admin-posts.php:218 +msgid "Ok" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:219 +#: includes/walkers/class-wp-members-walker-nav-menu.php:224 +msgid "Cancel" +msgstr "" + +#: includes/admin/class-wp-members-admin-posts.php:305 +#: includes/admin/class-wp-members-products-admin.php:629 +msgid "Status" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:28 +#: includes/admin/class-wp-members-admin-users.php:33 +#: includes/admin/class-wp-members-admin-users.php:59 +msgid "Activate" +msgstr "AktivovaÅ¥" + +#: includes/admin/class-wp-members-admin-users.php:29 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:62 +msgid "Deactivate" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:31 +#: includes/admin/class-wp-members-admin-users.php:36 +msgid "Export" +msgstr "Vývoz" + +#: includes/admin/class-wp-members-admin-users.php:37 +#: includes/admin/class-wp-members-admin-users.php:88 +#, fuzzy +msgid "Export All Users" +msgstr "Vývoz" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:126 +#, php-format +msgid "%s users deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:129 +msgid "No users selected" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 +msgid "You cannot activate or deactivate yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:152 +#, php-format +msgid "%s activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:157 +#, php-format +msgid "%s deactivated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:161 +msgid "That user is already active" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:288 +msgid "Pending" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:289 +msgid "Trial" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:290 +#: includes/admin/class-wp-members-export.php:74 +msgid "Subscription" +msgstr "Predplatné" + +#: includes/admin/class-wp-members-admin-users.php:291 +msgid "Expired" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:294 +msgid "Activated" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:295 +msgid "Pending Activation" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:296 +msgid "Deactivated" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:59 -#: admin/includes/class-wp-members-products-admin.php:162 -#: admin/tab-fields.php:459 admin/user-export.php:69 +#: includes/admin/class-wp-members-admin-users.php:298 +msgid "Not Exported" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:387 +#: includes/admin/class-wp-members-export.php:160 +msgid "No" +msgstr "nie" + +#: includes/admin/class-wp-members-export.php:64 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-export.php:65 +#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 +msgid "Username" +msgstr "Username" + +#: includes/admin/class-wp-members-export.php:71 +msgid "Activated?" +msgstr "Aktivovaný?" + +#: includes/admin/class-wp-members-export.php:75 +#: includes/admin/class-wp-members-products-admin.php:64 +#: includes/admin/class-wp-members-products-admin.php:632 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 msgid "Expires" msgstr "Uplynie" -#: admin/includes/class-wp-members-products-admin.php:60 +#: includes/admin/class-wp-members-export.php:77 +msgid "Registered" +msgstr "Registrované" + +#: includes/admin/class-wp-members-export.php:78 +msgid "IP" +msgstr "IP" + +#: includes/admin/class-wp-members-export.php:160 +#: includes/admin/class-wp-members-products-admin.php:104 +msgid "Yes" +msgstr "áno" + +#: includes/admin/class-wp-members-products-admin.php:62 +msgid "Slug" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:63 +msgid "Role" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:66 +msgid "Default" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:68 msgid "Last updated" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:80 +#: includes/admin/class-wp-members-products-admin.php:92 +msgid "slug:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:95 msgid "No role required" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:84 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "Does not expire" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:120 +#: includes/admin/class-wp-members-products-admin.php:140 msgid "Membership Product Details" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 -#: admin/includes/class-wp-members-products-admin.php:167 +#: includes/admin/class-wp-members-products-admin.php:148 +msgid "Membership Product Message (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 +msgid "Posts" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#, fuzzy +msgid "Pages" +msgstr "BlokovaÅ¥ stránky v predvolenom nastavení" + +#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:235 +#: includes/admin/class-wp-members-products-admin.php:280 msgid "Period" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Day" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Week" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Month" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:142 +#: includes/admin/class-wp-members-products-admin.php:193 msgid "Year" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:199 msgid "Name (slug)" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:153 -msgid "Role Required?" +#: includes/admin/class-wp-members-products-admin.php:201 +msgid "Optional Defaults" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:156 +#: includes/admin/class-wp-members-products-admin.php:204 +msgid "Assign as default at registration? (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:212 +#, php-format +msgid "Pre-selected by default for new %s" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:218 +msgid "Optional Properties" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:221 +msgid "Role Required? (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:224 msgid "No Role" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:164 -#: admin/includes/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:230 +msgid "Expires (optional)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:232 +#: includes/admin/class-wp-members-products-admin.php:234 +#: includes/admin/class-wp-members-products-admin.php:277 +#: includes/admin/class-wp-members-products-admin.php:279 msgid "Number" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:245 -#: admin/tab-options.php:207 inc/class-wp-members-forms.php:999 -#: inc/class-wp-members-user-profile.php:106 inc/deprecated.php:360 -#: inc/deprecated.php:622 +#: includes/admin/class-wp-members-products-admin.php:240 +msgid "Use \"no gap\" renewal" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:244 +msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:261 +msgid "Period Start (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:262 +msgid "Period End (dd-mm)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:275 +msgid "Fixed period grace period" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:284 +msgid "" +"Grace period is the point at which expiration date is for following time " +"period. For example, if user who register August 1st would be part of the " +"following year's Sept 1 - Aug 31 membership, set this at 1 Month. Leave " +"blank for no grace period." +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:333 +msgid "" +"Restricted Message (displays when a user does not have access to a " +"membership)" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:435 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 +#: includes/class-wp-members-forms.php:1092 +#: includes/class-wp-members-user-profile.php:112 msgid "None" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:251 +#: includes/admin/class-wp-members-products-admin.php:450 msgid "Limit access to:" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:321 +#: includes/admin/class-wp-members-products-admin.php:520 msgid "Required Membership" msgstr "" -#: admin/includes/class-wp-members-products-admin.php:360 +#: includes/admin/class-wp-members-products-admin.php:559 +#: includes/admin/class-wp-members-products-admin.php:630 msgid "Membership" msgstr "" -#: admin/post.php:45 admin/post.php:48 -msgid "Unblock" +#: includes/admin/class-wp-members-products-admin.php:599 +#: includes/class-wp-members-products.php:308 +msgid "Memberships" msgstr "" -#: admin/post.php:46 admin/post.php:49 admin/tab-options.php:114 -#, fuzzy -msgid "Block" -msgstr "Blok miest v predvolenom nastavení" +#: includes/admin/class-wp-members-products-admin.php:626 +msgid "Product Access" +msgstr "" -#: admin/post.php:47 admin/post.php:50 -msgid "Hide" +#: includes/admin/class-wp-members-products-admin.php:631 +msgid "Enabled?" msgstr "" -#: admin/post.php:138 +#: includes/admin/class-wp-members-products-admin.php:641 +msgid "Enable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:642 +msgid "Disable" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:647 +msgid "Expiration date (optional)" +msgstr "" + +#: includes/admin/dialogs.php:117 +msgid "" +"Your WP settings allow anyone to register - this is not the recommended " +"setting." +msgstr "" +"VaÅ¡a WP nastavenie umožňuje, aby niekto zaregistrovaÅ¥ - to nie je odporúÄané " +"nastavenie." + +#: includes/admin/dialogs.php:118 #, php-format -msgid "%s blocked" +msgid "" +"You can %s change this here %s making sure the box next to \"Anyone can " +"register\" is unchecked." msgstr "" +"Môžete% s to zmeniÅ¥ tu% s to, aby políÄko \"Každý sa môže zaregistrovaÅ¥\" je " +"aktívny." + +#: includes/admin/dialogs.php:119 +msgid "" +"This setting allows a link on the /wp-login.php page to register using the " +"WP native registration process thus circumventing any registration you are " +"using with WP-Members. In some cases, this may suit the users wants/needs, " +"but most users should uncheck this option. If you do not change this " +"setting, you can choose to ignore these warning messages under WP-Members " +"Settings." +msgstr "" +"Toto nastavenie umožňuje odkaz na / wp-login.php stránke zaregistrovaÅ¥ " +"pomocou WP natívne proces registrácie a tým obísÅ¥ žiadny záznam, ktorý " +"používate s WP-poslancov. V niektorých prípadoch to môže vyhovovaÅ¥ " +"používateľom wants/potreby, ale väÄÅ¡ina užívateľov by odÅ¡krtnite túto voľbu. " +"Ak nemáte toto nastavenie zmeniÅ¥, môžete zvoliÅ¥ ignorovanie týchto varovných " +"správ v rámci WP-poslancov nastavenia." -#: admin/post.php:138 +#: includes/admin/dialogs.php:123 +msgid "" +"Your WP settings allow anyone to comment - this is not the recommended " +"setting." +msgstr "" +"VaÅ¡a WP nastavenie umožňuje, aby niekto komentár - to nie je odporúÄané " +"nastavenie." + +#: includes/admin/dialogs.php:124 #, php-format -msgid "%s unblocked" +msgid "" +"You can %s change this here %s by checking the box next to \"Users must be " +"registered and logged in to comment.\"" +msgstr "" +"Môžete %s to zmeniÅ¥ tu %s zaÅ¡krtnutím políÄka vedľa \"Používatelia musia byÅ¥ " +"registrovaný a prihlásený komentovaÅ¥.\"" + +#: includes/admin/dialogs.php:125 +msgid "" +"This setting allows any users to comment, whether or not they are " +"registered. Depending on how you are using WP-Members will determine whether " +"you should change this setting or not. If you do not change this setting, " +"you can choose to ignore these warning messages under WP-Members Settings." msgstr "" +"Toto nastavenie umožňuje používateľom akékoľvek pripomienky, Äi už sú alebo " +"nie sú zaregistrovaní. V závislosti od spôsobu používania WP-Älenov urÄí, Äi " +"by ste mali zmeniÅ¥ toto nastavenie, alebo nie. Ak nemáte toto nastavenie " +"zmeniÅ¥, môžete zvoliÅ¥ ignorovanie týchto varovných správ v rámci WP-" +"poslancov nastavenia." -#: admin/post.php:177 +#: includes/admin/dialogs.php:129 +msgid "" +"Your WP settings allow full text rss feeds - this is not the recommended " +"setting." +msgstr "" +"VaÅ¡a WP nastavenie umožňuje fulltextové RSS - toto nie je odporúÄané " +"nastavenie." + +#: includes/admin/dialogs.php:130 #, php-format -msgid "%s Restriction" +msgid "" +"You can %s change this here %s by changing \"For each article in a feed, show" +"\" to \"Summary.\"" +msgstr "" +"Môžete %s to zmeniÅ¥ tu %s tým, že mení \"U každého Älánku v krmivách, " +"ukazujú,\" na \"Celková.\"" + +#: includes/admin/dialogs.php:131 +msgid "" +"Leaving this set to full text allows anyone to read your protected content " +"in an RSS reader. Changing this to Summary prevents this as your feeds will " +"only show summary text." +msgstr "" +"Ponechanie tejto sady k úplnému zneniu umožňuje každému si preÄítaÅ¥ " +"chráneného obsahu v RSS ÄítaÄke. Zmena na súhrn bráni to ako zdroja sa " +"zobrazí len súhrnné text." + +#: includes/admin/dialogs.php:135 +msgid "You have set WP-Members to hold registrations for approval" +msgstr "Nastavili ste WP-Älenovia držaÅ¥ zápisov na schválenie" + +#: includes/admin/dialogs.php:136 +msgid "" +"but you have not changed the default message for \"Registration Completed\" " +"under \"WP-Members Dialogs and Error Messages.\" You should change this " +"message to let users know they are pending approval." +msgstr "" +"ale vy ste nezmenili predvolené správu pre \"Registrácia dokonÄená\" v \"WP-" +"ÄŒlenov dialógy a chybové hlásenia.\" by ste mali zmeniÅ¥ túto správu daÅ¥ " +"používateľom vedieÅ¥, že sa Äaká na schválenie." + +#: includes/admin/dialogs.php:140 +msgid "You have turned on reCAPTCHA" +msgstr "Zapli ste reCAPTCHA" + +#: includes/admin/dialogs.php:141 +msgid "" +"but you have not entered API keys. You will need both a public and private " +"key. The CAPTCHA will not display unless a valid API key is included." +msgstr "" +"ale vy ste nezadali API kľúÄa. Budete potrebovaÅ¥ obaja verejný a súkromný " +"kľúÄ. CAPTCHA sa nezobrazí, ak platné API kÄ¾ÃºÄ je súÄasÅ¥ou dodávky." + +#: includes/admin/dialogs.php:145 +msgid "You have active settings that are not recommended." +msgstr "" + +#: includes/admin/dialogs.php:146 +msgid "" +"If you will not be changing these settings, you can turn off these warning " +"messages by checking the \"Ignore warning messages\" in the settings below." +msgstr "" + +#: includes/admin/dialogs.php:174 +msgid "Version:" +msgstr "Verzia:" + +#: includes/admin/dialogs.php:175 +#, fuzzy +msgid "Quick Start Guide" msgstr "" +"WP obmedzenie prístupu a registraÄné. Pre viac informácií a na stiahnutie v " +"užívateľskej príruÄke, nájdete " +"http://butlerblog.com/wp-members . Quick Start Guide je k " +"dispozícii tiež. WP-Älenov (TM) je obchodná znaÄka butlerblog.com." -#: admin/post.php:206 -msgid "Unblocked" -msgstr "" +#: includes/admin/dialogs.php:176 +#, fuzzy +msgid "Online User Guide" +msgstr "Používateľom aktualizácie" -#: admin/post.php:207 -msgid "Blocked" +#: includes/admin/dialogs.php:177 +msgid "FAQs" msgstr "" -#: admin/post.php:208 -msgid "Hidden" -msgstr "" +#: includes/admin/dialogs.php:184 +#, fuzzy +msgid "Thank you for using WP-Members" +msgstr "ÄŽakujeme, že používate WP Älenov! Používate verziu %s" -#: admin/post.php:214 -msgid "Status:" +#: includes/admin/dialogs.php:185 +msgid "A plugin developed by" msgstr "" -#: admin/post.php:214 admin/tab-fields.php:88 admin/tab-fields.php:554 -#, fuzzy -msgid "Edit" -msgstr "UpraviÅ¥ vaÅ¡e informácie" +#: includes/admin/dialogs.php:186 +msgid "Follow" +msgstr "Postupujte" -#: admin/post.php:229 -msgid "Ok" +#: includes/admin/dialogs.php:203 includes/admin/dialogs.php:207 +msgid "Latest from RocketGeek" msgstr "" -#: admin/post.php:230 -msgid "Cancel" +#: includes/admin/dialogs.php:224 +msgid "Like WP-Members?" msgstr "" -#: admin/post.php:314 -msgid "Status" +#: includes/admin/dialogs.php:225 +#, php-format +msgid "" +"If you like WP-Members please give it a %s★★★★★" +"%s rating. Thanks!!" msgstr "" -#: admin/tab-about.php:34 admin/tab-about.php:54 -msgid "About WP-Members" +#: includes/admin/dialogs.php:236 includes/admin/dialogs.php:249 +msgid "Latest from ButlerBlog" msgstr "" -#: admin/tab-captcha.php:66 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:67 #, php-format msgid "See the %sUsers Guide on CAPTCHA%s." msgstr "" -#: admin/tab-captcha.php:73 admin/tab-dialogs.php:57 admin/tab-emails.php:101 -#: admin/tab-fields.php:153 admin/tab-options.php:82 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" -#: admin/tab-captcha.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 msgid "Manage reCAPTCHA Options" msgstr "SpravovaÅ¥ reCAPTCHA možnosti" -#: admin/tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 msgid "" "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " "while blocking spam on your blog." @@ -469,7 +706,7 @@ msgstr "" "ReCaptcha je zadarmo, prístupný CAPTCHA služba, ktorá pomáha pri " "digitalizácii kníh blokovanie nevyžiadanej poÅ¡ty na svojom blogu." -#: admin/tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 #, php-format msgid "" "reCAPTCHA asks commenters to retype two words scanned from a book to prove " @@ -484,11 +721,12 @@ msgstr "" "dostane presne digitalizované knihy. VÅ¡etci víťazí! Podrobnosti nájdete %s " "ReCaptcha stránky%s" -#: admin/tab-captcha.php:104 admin/tab-captcha.php:130 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 msgid "reCAPTCHA Keys" msgstr "reCAPTCHA klávesy" -#: admin/tab-captcha.php:106 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " @@ -497,111 +735,111 @@ msgstr "" "ReCaptcha vyžaduje API kľúÄ, skladajúci sa z \"verejnosÅ¥\" a \"súkromný\" " "kľúÄ. Môžete sa zaregistrovaÅ¥ pre %s bez kľúÄa s ReCaptcha%s" -#: admin/tab-captcha.php:107 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 msgid "Public Key" msgstr "Verejný kľúÄ" -#: admin/tab-captcha.php:108 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 msgid "Private Key" msgstr "Súkromný kľúÄ" -#: admin/tab-captcha.php:112 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 msgid "Choose Theme" msgstr "VybraÅ¥ tému" -#: admin/tab-captcha.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 msgid "Red" msgstr "Red" -#: admin/tab-captcha.php:116 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 msgid "White" msgstr "Biela" -#: admin/tab-captcha.php:117 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 msgid "Black Glass" msgstr "ÄŒierneho skla" -#: admin/tab-captcha.php:118 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 msgid "Clean" msgstr "VyÄistite" -#: admin/tab-captcha.php:132 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: admin/tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 msgid "Site Key" msgstr "" -#: admin/tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 msgid "Secret Key" msgstr "" -#: admin/tab-captcha.php:165 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 msgid "Characters for image" msgstr "" -#: admin/tab-captcha.php:169 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 msgid "Number of characters" msgstr "" -#: admin/tab-captcha.php:173 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 msgid "Image dimensions" msgstr "" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Width" msgstr "" -#: admin/tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 msgid "Height" msgstr "" -#: admin/tab-captcha.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Font color of characters" msgstr "" -#: admin/tab-captcha.php:181 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Background color of image" msgstr "" -#: admin/tab-captcha.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Font size" msgstr "" -#: admin/tab-captcha.php:189 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Width between characters" msgstr "" -#: admin/tab-captcha.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 #, fuzzy msgid "Image type" msgstr "Typ poľa" -#: admin/tab-captcha.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: admin/tab-captcha.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 #, fuzzy msgid "Update CAPTCHA Settings" msgstr "AktualizovaÅ¥ nastavenia" -#: admin/tab-captcha.php:301 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 #, fuzzy msgid "CAPTCHA was updated for WP-Members" msgstr "reCAPTCHA bol aktualizovaný poslancov WP" -#: admin/tab-dialogs.php:67 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:67 msgid "Dialogs and Error Messages" msgstr "Dialógové okná a chybových hlásení" -#: admin/tab-dialogs.php:69 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:69 #, php-format msgid "" "You can customize the text for dialogs and error messages. Simple HTML is " @@ -610,383 +848,346 @@ msgstr "" "Môžete upraviÅ¥ text dialógov a chybové správy. Jednoduché HTML je povolené " "%s atÄ" -#: admin/tab-dialogs.php:80 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:80 msgid "Terms of Service (TOS)" msgstr "Zmluvné podmienky služby (TOS)" -#: admin/tab-dialogs.php:87 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:87 msgid "Update Dialogs" msgstr "Aktualizácia Dialogs" -#: admin/tab-dialogs.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:124 msgid "WP-Members dialogs were updated" msgstr "WP-Älenovia dialógy boli aktualizované" -#: admin/tab-dropins.php:78 admin/tab-dropins.php:378 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:88 +#: includes/admin/tabs/class-wp-members-dropins-table.php:180 msgid "WP-Members Dropin settings were updated" msgstr "" -#: admin/tab-dropins.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:216 msgid "Manage Dropins" msgstr "" -#: admin/tab-dropins.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:217 msgid "Current dropin folder: " msgstr "" -#: admin/tab-dropins.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-dropins.php:218 msgid "" "You can change location of the dropin folder using the " "wpmem_dropin_folder filter." msgstr "" -#: admin/tab-dropins.php:269 -msgid "Name" -msgstr "" - -#: admin/tab-dropins.php:270 -msgid "File" -msgstr "" - -#: admin/tab-dropins.php:271 -msgid "Version" -msgstr "" - -#: admin/tab-dropins.php:272 -msgid "Description" -msgstr "" - -#: admin/tab-dropins.php:315 admin/tab-fields.php:597 -msgid "Save Settings" -msgstr "" - -#: admin/tab-emails.php:58 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:57 msgid "Email Messages" msgstr "E-mailové správy" -#: admin/tab-emails.php:61 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:60 msgid "You can customize the content of the emails sent by the plugin." msgstr "Môžete prispôsobiÅ¥ obsah e-mailov odoslané plugin." -#: admin/tab-emails.php:63 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:62 msgid "A list of shortcodes is available here." msgstr "Tu je k dispozícii zoznam shortcodes." -#: admin/tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:69 msgid "Set a custom email address" msgstr "NastaviÅ¥ vlastnú e-mailovú adresu" -#: admin/tab-emails.php:71 admin/tab-emails.php:75 admin/tab-emails.php:85 -#: admin/tab-fields.php:179 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 msgid "(optional)" msgstr "(voliteľné)" -#: admin/tab-emails.php:74 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:73 msgid "Set a custom email name" msgstr "NastaviÅ¥ názov vlastného e-mailu" -#: admin/tab-emails.php:85 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 msgid "Email Signature" msgstr "Podpis e-mailu" -#: admin/tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 msgid "Update Emails" msgstr "Aktualizácia e-mailov" -#: admin/tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 msgid "WP-Members emails were updated" msgstr "WP-Älenovia e-maily boli aktualizované" -#: admin/tab-fields.php:113 inc/class-wp-members.php:1207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 +#: includes/class-wp-members.php:1498 msgid "No fields selected for deletion" msgstr "" -#: admin/tab-fields.php:115 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:95 msgid "Are you sure you want to delete the following fields?" msgstr "" -#: admin/tab-fields.php:141 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:122 msgid "Fields deleted" msgstr "" -#: admin/tab-fields.php:155 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:136 msgid "Field Manager Documentation" msgstr "" -#: admin/tab-fields.php:180 admin/tab-fields.php:322 -#: inc/class-wp-members-user-profile.php:138 inc/deprecated.php:385 -#: inc/deprecated.php:646 inc/wp-registration.php:57 -#: inc/wp-registration.php:231 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/class-wp-members-forms.php:1626 +#: includes/class-wp-members-forms.php:1803 +#: includes/class-wp-members-user-profile.php:144 msgid "(required)" msgstr "Vyžadováno?" -#: admin/tab-fields.php:185 admin/tab-fields.php:407 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 #, fuzzy msgid "Edit Field" msgstr "UpraviÅ¥ vaÅ¡e informácie" -#: admin/tab-fields.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 #, fuzzy msgid "Add a Field" msgstr "PridaÅ¥ a odstrániÅ¥" -#: admin/tab-fields.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 msgid "Field Label" msgstr "OznaÄenie poľa" -#: admin/tab-fields.php:192 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: admin/tab-fields.php:195 admin/tab-fields.php:547 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: admin/tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: admin/tab-fields.php:205 admin/tab-fields.php:548 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Typ poľa" -#: admin/tab-fields.php:211 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 msgid "text" msgstr "textu" -#: admin/tab-fields.php:212 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 msgid "email" msgstr "" -#: admin/tab-fields.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "textarea" msgstr "Textarea" -#: admin/tab-fields.php:214 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "checkbox" msgstr "Checkbox" -#: admin/tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "multiple checkbox" msgstr "" -#: admin/tab-fields.php:216 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "select (dropdown)" msgstr "" -#: admin/tab-fields.php:217 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple select" msgstr "" -#: admin/tab-fields.php:218 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "radio group" msgstr "" -#: admin/tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "password" msgstr "heslo" -#: admin/tab-fields.php:220 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "image" msgstr "" -#: admin/tab-fields.php:221 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "file" msgstr "" -#: admin/tab-fields.php:222 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "url" msgstr "" -#: admin/tab-fields.php:223 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "number" msgstr "" -#: admin/tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "date" msgstr "" -#: admin/tab-fields.php:225 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "hidden" msgstr "" -#: admin/tab-fields.php:227 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "membership" msgstr "" -#: admin/tab-fields.php:233 admin/tab-fields.php:549 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "ZobraziÅ¥?" -#: admin/tab-fields.php:237 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 msgid "This field is always displayed" msgstr "" -#: admin/tab-fields.php:242 admin/tab-fields.php:550 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 msgid "Required?" msgstr "Vyžadováno?" -#: admin/tab-fields.php:246 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 msgid "This field is always required" msgstr "" -#: admin/tab-fields.php:252 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 msgid "Allow HTML?" msgstr "" -#: admin/tab-fields.php:259 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 msgid "Placeholder" msgstr "" -#: admin/tab-fields.php:267 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 msgid "Pattern" msgstr "" -#: admin/tab-fields.php:273 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 msgid "Title" msgstr "" -#: admin/tab-fields.php:282 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 msgid "Minimum Value" msgstr "" -#: admin/tab-fields.php:286 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Maximum Value" msgstr "" -#: admin/tab-fields.php:294 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 msgid "Rows" msgstr "" -#: admin/tab-fields.php:298 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Columns" msgstr "" -#: admin/tab-fields.php:306 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 msgid "Accepted file types:" msgstr "" -#: admin/tab-fields.php:311 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: admin/tab-fields.php:318 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 #, fuzzy msgid "Checked by default?" msgstr "SkontrolovaÅ¥?" -#: admin/tab-fields.php:322 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 #, fuzzy msgid "Stored value if checked:" msgstr "SkontrolovaÅ¥?" -#: admin/tab-fields.php:343 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 msgid "Stored values delimiter:" msgstr "" -#: admin/tab-fields.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 msgid "Values (Displayed|Stored):" msgstr "" -#: admin/tab-fields.php:377 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 msgid "Options should be Option Name|option_value," msgstr "Možnosti by mala byÅ¥ možnosÅ¥ Name|option_value" -#: admin/tab-fields.php:381 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 msgid "Visit plugin site for more information" msgstr "Môžete tiež navÅ¡tíviÅ¥ lokalitu plugin pre ÄalÅ¡ie informácie" -#: admin/tab-fields.php:388 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Value" msgstr "" -#: admin/tab-fields.php:407 admin/tab-fields.php:674 admin/tab-fields.php:675 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 #, fuzzy msgid "Add Field" msgstr "PridaÅ¥ a odstrániÅ¥" -#: admin/tab-fields.php:409 admin/tab-fields.php:868 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 msgid "Return to Fields Table" msgstr "" -#: admin/tab-fields.php:449 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 msgid "Drag and drop to reorder fields" msgstr "" -#: admin/tab-fields.php:455 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 #, fuzzy msgid "Registration Date" msgstr "Registrácia dokonÄená" -#: admin/tab-fields.php:456 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 #, fuzzy msgid "Active" msgstr "AktivovaÅ¥" -#: admin/tab-fields.php:457 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 msgid "Registration IP" msgstr "IP @ registrácie" -#: admin/tab-fields.php:458 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 msgid "Subscription Type" msgstr "" -#: admin/tab-fields.php:460 admin/user-export.php:58 -msgid "User ID" -msgstr "" - -#: admin/tab-fields.php:493 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 msgid "Manage Fields" msgstr "SpravovaÅ¥ polia" -#: admin/tab-fields.php:532 -msgid "delete" -msgstr "" - -#: admin/tab-fields.php:546 -msgid "Display Label" -msgstr "" - -#: admin/tab-fields.php:552 -#, fuzzy -msgid "Users Screen" -msgstr "Vývoz" - -#: admin/tab-fields.php:553 -msgid "Users Search" -msgstr "" - -#: admin/tab-fields.php:555 -msgid "Sort" -msgstr "" - -#: admin/tab-fields.php:596 -msgid "Delete Selected" -msgstr "" - -#: admin/tab-fields.php:738 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 msgid "WP-Members fields were updated" msgstr "WP-Älenovia polia boli aktualizované" -#: admin/tab-fields.php:760 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 msgid "Field Label is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:761 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: admin/tab-fields.php:763 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: admin/tab-fields.php:770 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 msgid "A field with that meta key already exists" msgstr "" -#: admin/tab-fields.php:775 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 #, php-format msgid "" "Sorry, \"%s\" is a %s', $link, $text ); - return $link; + global $wpmem; + return $wpmem->loginout_args( $args ); } /** diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 59ce4216..9c1806e2 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -2023,4 +2023,45 @@ function load_default_tos() { } } + /** + * Builds defaults for login/out links/buttons. + * + * @since 3.3.5 + * + * @param array $args + * @return string $html + */ + function loginout_args( $args = array() ) { + $defaults = array( + 'format' => ( isset( $args['format'] ) ) ? $args['format'] : 'link', + 'login_redirect_to' => ( isset( $args['login_redirect_to'] ) ) ? $args['login_redirect_to'] : wpmem_current_url(), + 'logout_redirect_to' => ( isset( $args['logout_redirect_to'] ) ) ? $args['logout_redirect_to'] : wpmem_current_url(), // @todo - This is not currently active. + 'login_text' => ( isset( $args['login_text'] ) ) ? $args['login_text'] : __( 'log in', 'wp-members' ), + 'logout_text' => ( isset( $args['logout_text'] ) ) ? $args['logout_text'] : __( 'log out', 'wp-members' ), + 'class' => ( isset( $args['class'] ) ) ? $args['class'] : 'wpmem_loginout_link', + 'id' => ( isset( $args['id'] ) ) ? $args['id'] : 'wpmem_loginout_link', + ); + $args = wp_parse_args( $args, $defaults ); + $redirect = ( is_user_logged_in() ) ? $args['logout_redirect_to'] : $args['login_redirect_to']; + $text = ( is_user_logged_in() ) ? $args['logout_text'] : $args['login_text']; + if ( is_user_logged_in() ) { + /** This filter is defined in /inc/dialogs.php */ + $link = apply_filters( 'wpmem_logout_link', add_query_arg( 'a', 'logout' ) ); + } else { + $link = wpmem_login_url( $redirect ); + } + + if ( 'button' == $args['format'] ) { + if ( wpmem_current_url() != wpmem_login_url() || is_user_logged_in() ) { + $html = '
    '; + $html.= ( is_user_logged_in() ) ? '' : ''; + $html.= '
    '; + } else { + $html = ''; + } + } else { + $html = sprintf( '%s', $link, $args['id'], $args['class'], $text ); + } + return $html; + } } // End of WP_Members class. \ No newline at end of file diff --git a/readme.txt b/readme.txt index 7e51a901..b1c5d403 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 5.4 -Stable tag: 3.3.4.1 +Stable tag: 3.3.5 License: GPLv2 == Description == @@ -105,7 +105,7 @@ The FAQs are maintained at https://rocketgeek.com/plugins/wp-members/docs/faqs/ == Upgrade Notice == -WP-Members 3.3.0 is a major update. WP-Members 3.3.4 is an improvement release. See changelog for important details. Minimum WP version is 4.0. +WP-Members 3.3.0 is a major update. WP-Members 3.3.5 is an improvement release. See changelog for important details. Minimum WP version is 4.0. == Screenshots == @@ -133,6 +133,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.4 is an improvement release. * Added optional new user activation link and password reset link (instead of sending password). This option will become the default setting in 3.4.0. * Updated the default product restricted message to display required membership(s). This eliminates the custom message string "product_restricted" and replaces with two new ones: product_restricted_single and product_restricted_multiple. (Note this only affects the default message if no custom membership message is established in the membership properties). +* Added login/logout button to login/logout link api function wpmem_loginout() and shortcode [wpmem_loginout]. It will continue to display a hyperlink by default, but accepts arguments to display as a button. Also added ID and class options for link or button. = 3.3.4 = From 50b961873919f76e54580c86869b6a945453265c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 4 Jun 2020 08:52:10 -0400 Subject: [PATCH 1259/1694] add cli and updates --- includes/cli/class-wp-members-cli-user.php | 14 +++++++ includes/cli/class-wp-members-cli.php | 43 +++++++++++++++++++++- 2 files changed, 56 insertions(+), 1 deletion(-) create mode 100644 includes/cli/class-wp-members-cli-user.php diff --git a/includes/cli/class-wp-members-cli-user.php b/includes/cli/class-wp-members-cli-user.php new file mode 100644 index 00000000..42575c34 --- /dev/null +++ b/includes/cli/class-wp-members-cli-user.php @@ -0,0 +1,14 @@ +display_user_detail( $user->ID, $all ); } + + public function post_status( $args, $assoc_args ) { + if ( true === wpmem_is_hidden( $args[0] ) ) { + $line = 'post ' . $args[0] . ' is hidden'; + } else { + $line = ( wpmem_is_blocked( $args[0] ) ) ? 'post ' . $args[0] . ' is blocked' : 'post ' . $args[0] . ' is not blocked'; + } + WP_CLI::line( $line ); + } + + public function get_block_value( $args ) { + WP_CLI::line( 'post block setting: ' . wpmem_get_block_setting( $args[0] ) ); + } + + public function refresh_hidden_posts() { + wpmem_update_hidden_posts(); + WP_CLI::line( 'hidden posts refreshed' ); + } + + public function get_hidden_posts() { + $posts = implode( ", ", wpmem_get_hidden_posts() ); + WP_CLI::line( 'hidden post IDs: ' . $posts ); + } + + public function set_post_status( $args, $assoc_args ) { + switch( $args[1] ) { + case 'unblock': + case 'unrestrict': + $val = 0; $line = 'unrestricted'; + break; + case 'hide': + $val = 2; $line = 'hidden'; + break; + case 'block': + case 'restrict': + default; + $val = 1; $line = 'restricted'; + break; + } + update_post_meta( $args[0], '_wpmem_block', $val ); + WP_CLI::line( 'Set post id ' . $args[0] . ' as ' . $line ); + } private function display_user_detail( $user_id, $all ) { WP_CLI::line( __( 'User: %s', 'wp-members' ) ); @@ -32,5 +74,4 @@ private function display_user_detail( $user_id, $all ) { } WP_CLI::add_command( 'mem', 'WP_Members_CLI' ); - } \ No newline at end of file From e73297b06076647ce01aea19ee339815460f45ed Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 4 Jun 2020 08:52:49 -0400 Subject: [PATCH 1260/1694] include cli library --- includes/class-wp-members.php | 1 + 1 file changed, 1 insertion(+) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 9c1806e2..dbee7915 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -591,6 +591,7 @@ function load_dependencies() { if ( defined( 'WP_CLI' ) && WP_CLI ) { require_once( $this->path . 'includes/cli/class-wp-members-cli.php' ); + require_once( $this->path . 'includes/cli/class-wp-members-cli-user.php' ); } } From 60be66dc55ff91e35bb61b6a21f3048a6f9ea5b6 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 4 Jun 2020 08:55:09 -0400 Subject: [PATCH 1261/1694] updated captcha for use as static --- includes/class-wp-members-captcha.php | 47 +++++++++++++++++++-------- includes/class-wp-members-forms.php | 33 ++----------------- includes/class-wp-members-user.php | 4 +-- readme.txt | 1 + 4 files changed, 39 insertions(+), 46 deletions(-) diff --git a/includes/class-wp-members-captcha.php b/includes/class-wp-members-captcha.php index 8b377adf..a0f767f9 100644 --- a/includes/class-wp-members-captcha.php +++ b/includes/class-wp-members-captcha.php @@ -29,7 +29,7 @@ static function show( $type, $keys = false ) { if ( 'rs_captcha' == $type ) { return self::rs_captcha(); } else { - return self::recaptcha( $keys ); + return self::recaptcha(); } } @@ -37,11 +37,13 @@ static function show( $type, $keys = false ) { * Create reCAPTCHA form. * * @since 3.3.0 Replaces wpmem_inc_recaptcha(). + * @since 3.3.5 Accepts no arguments. * - * @param array $arr * @return string $str HTML for reCAPTCHA display. */ - static function recaptcha( $arr ) { + static function recaptcha() { + + $wpmem_captcha = get_option( 'wpmembers_captcha' ); // Determine if reCAPTCHA should be another language. $allowed_langs = array( 'nl', 'fr', 'de', 'pt', 'ru', 'es', 'tr' ); @@ -52,9 +54,20 @@ static function recaptcha( $arr ) { $lang = ( $use_the_lang ) ? ' lang : \'' . $use_the_lang . '\'' : ''; global $wpmem; - if ( $wpmem->captcha == 3 ) { + if ( 3 == $wpmem->captcha ) { $str = ' -
    '; +
    '; + } elseif ( 4 == $wpmem->captcha ) { + $str = ''; + $str.= ""; + $str.= ''; } /** @@ -166,11 +179,11 @@ static function validate( $which_captcha = false ) { global $wpmem, $wpmem_themsg; + // Get the captcha settings (api keys). + $wpmem_captcha = get_option( 'wpmembers_captcha' ); + if ( ! $which_captcha ) { - // Get the captcha settings (api keys). - $wpmem_captcha = get_option( 'wpmembers_captcha' ); - /* * @todo reCAPTCHA v1 is deprecated by Google. It is also no longer allowed * to be set for new installs of WP-Members. It is NOT compatible with @@ -215,7 +228,7 @@ static function validate( $which_captcha = false ) { // If CAPTCHA validation fails (incorrect value entered in CAPTCHA field), return an error. if ( ! $wpmem_captcha_correct ) { $wpmem_themsg = __( 'You have entered an incorrect code value. Please try again.', 'wp-members' ); - return "empty"; + return false; } } } else { @@ -230,9 +243,9 @@ static function validate( $which_captcha = false ) { $captcha = wpmem_get( 'g-recaptcha-response', false ); // If there is no captcha value, return error. - if ( ! $captcha ) { + if ( false === $captcha ) { $wpmem_themsg = $wpmem->get_text( 'reg_empty_captcha' ); - return "empty"; + return false; } // Build URL for captcha evaluation. @@ -257,10 +270,16 @@ static function validate( $which_captcha = false ) { $wpmem_themsg.= "Error code: " . $code . "
    "; } } - return "empty"; + return false; } } elseif ( 'recaptcha_v3' == $captcha && $wpmem_captcha['recaptcha'] ) { $captcha = wpmem_get( 'recaptcha_response', false ); + + if ( false === $captcha ) { + $wpmem_themsg = $wpmem->get_text( 'reg_empty_captcha' ); + return false; + } + if ( $_SERVER['REQUEST_METHOD'] === 'POST' && false !== $captcha ) { // Make and decode POST request: @@ -276,10 +295,10 @@ static function validate( $which_captcha = false ) { // Verified - send email } else { $wpmem_themsg = $wpmem->get_text( 'reg_invalid_captcha' ); - return "empty"; + return false; } } else { - return "empty"; + return false; } } } diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index fd5e4547..d0670d0d 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1173,8 +1173,6 @@ function register_form( $mixed = 'new', $redirect_to = null ) { // If captcha is Really Simple CAPTCHA. if ( $wpmem->captcha == 2 && $tag != 'edit' ) { - // Include captcha functions. - require_once( $wpmem->path . 'includes/class-wp-members-captcha.php' ); // Build the captcha. $row = WP_Members_Captcha::rs_captcha(); $rows['captcha'] = array( @@ -1247,36 +1245,11 @@ function register_form( $mixed = 'new', $redirect_to = null ) { // Do recaptcha if enabled. if ( ( 1 == $wpmem->captcha || 3 == $wpmem->captcha || 4 == $wpmem->captcha ) && $tag != 'edit' ) { // don't show on edit page! - - // Include captcha functions. - require_once( $wpmem->path . 'includes/class-wp-members-captcha.php' ); - // Get the captcha options. - $wpmem_captcha = get_option( 'wpmembers_captcha' ); + $row = WP_Members_Captcha::recaptcha(); - if ( 4 == $wpmem->captcha ) { - - $row = ''; - $row.= ""; - $row.= ''; - - } else { - - // Start with a clean row. - $row = ''; - $row = '
    '; - $row.= '
    '; - - $row.= WP_Members_Captcha::recaptcha( $wpmem_captcha['recaptcha'] ); - - $row.= '
    '; + if ( 4 != $wpmem->captcha ) { + $row = '
    ' . $row . '
    '; } // Add the captcha row to the form. diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 2cb4dc37..51cbb0f4 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -347,8 +347,8 @@ function register_validate( $tag ) { // Process CAPTCHA. if ( 0 != $wpmem->captcha ) { $check_captcha = WP_Members_Captcha::validate(); - if ( true != $check_captcha ) { - return $check_captcha; + if ( false === $check_captcha ) { + return "empty"; // @todo Return and/or set error object. For now changed to return original value. } } diff --git a/readme.txt b/readme.txt index b1c5d403..6f7491ea 100644 --- a/readme.txt +++ b/readme.txt @@ -134,6 +134,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.5 is an improvement release. * Added optional new user activation link and password reset link (instead of sending password). This option will become the default setting in 3.4.0. * Updated the default product restricted message to display required membership(s). This eliminates the custom message string "product_restricted" and replaces with two new ones: product_restricted_single and product_restricted_multiple. (Note this only affects the default message if no custom membership message is established in the membership properties). * Added login/logout button to login/logout link api function wpmem_loginout() and shortcode [wpmem_loginout]. It will continue to display a hyperlink by default, but accepts arguments to display as a button. Also added ID and class options for link or button. +* Captcha options now have a static function that can be used to directly call captcha and validation. = 3.3.4 = From 914f4ab408eec2b121fd143b2c8583b13f174224 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 9 Jun 2020 09:02:02 -0400 Subject: [PATCH 1262/1694] added wpmem_update_hidden_posts() api function --- includes/api/api.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/includes/api/api.php b/includes/api/api.php index 08d84d12..5702702c 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -376,6 +376,18 @@ function wpmem_get_hidden_posts() { return $wpmem->get_hidden_posts(); } +/** + * Updates the hiddent posts array. + * + * @since 3.3.5 + * + * @global stdClass $wpmem + */ +function wpmem_update_hidden_posts() { + global $wpmem; + $wpmem->update_hidden_posts(); +} + /** * Conditional if REST request. * From c1579370b0c75e00d6fc10f275da773c73aedd9a Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 9 Jun 2020 09:18:41 -0400 Subject: [PATCH 1263/1694] add membership field type values to fields array --- includes/class-wp-members-forms.php | 3 ++- includes/class-wp-members.php | 7 +++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index d0670d0d..81e8b196 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -162,7 +162,7 @@ function create_form_field( $args ) { $pname = ( 'multiselect' == $type ) ? $name . "[]" : $name; $str = "'; + $value = ( isset( $_POST[ $meta_key ] ) ) ? esc_attr( $_POST[ $meta_key ] ) : ''; + echo ''; break; } From 7a6ae36ea7512a2dc54a28633f4e2bee1cfd3258 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 9 Jun 2020 09:33:42 -0400 Subject: [PATCH 1265/1694] added user api functions wpmem_get_user_id(), wpmem_get_user_obj(), wpmem_get_users_by_meta() --- includes/api/api-users.php | 63 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 3c2c10bd..a5708580 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -783,4 +783,67 @@ function wpmem_export_users( $args, $users = null ) { WP_Members_Export::export_users( $args, $users ); } +/** + * Gets user ID based on request. + * + * @since 3.3.5 + * + * @param mixed $user + * @return mixed + */ +function wpmem_get_user_id( $user ) { + $user_obj = wpmem_get_user_obj( $user ); + return ( is_object( $user_obj ) ) ? $user_obj->ID : false; +} + +/** + * Gets user object based on request. + * + * @since 3.3.5 + * + * @param mixed $user + * @return mixed + */ +function wpmem_get_user_obj( $user ) { + if ( is_numeric( $user ) ) { + $user_obj = get_userdata( $user ); + if ( $user_obj ) { + return $user_obj; + } + } + if ( strpos( $user, '@' ) ) { + $user_obj = get_user_by( 'email', $user ); + if ( $user_obj ) { + return $user_obj; + } + } + if ( is_string( $user ) ) { + $user_obj = get_user_by( 'login', $user ); + if ( $user_obj ) { + return $user_obj; + } + } + return false; +} + +/** + * Get all users by a meta value. + * + * @since 3.5.0 + * + * @param string $meta The meta key to search fo. + * @param string $value The meta value to search for (defaul:false). + * @return array $users An array of user IDs who have the requested meta. + */ +function wpmem_get_users_by_meta( $meta, $value = false ) { + $args = array( 'fields' => array( 'ID' ), 'meta_key' => $meta ); + if ( false === $value ) { + $args['meta_value'] = ''; + $args['meta_compare'] = '>'; + } else { + $args['meta_value'] = $value; + } + return get_users( $args ); +} + // End of file. \ No newline at end of file From 6b20487817b0644a9d6ed994e71a9aa6a3c69500 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 17 Jun 2020 11:20:59 -0400 Subject: [PATCH 1266/1694] fixed bug in really simple captcha if not installed --- includes/class-wp-members-captcha.php | 60 ++++++++++++--------------- readme.txt | 3 ++ 2 files changed, 30 insertions(+), 33 deletions(-) diff --git a/includes/class-wp-members-captcha.php b/includes/class-wp-members-captcha.php index a0f767f9..6c48c1c5 100644 --- a/includes/class-wp-members-captcha.php +++ b/includes/class-wp-members-captcha.php @@ -17,6 +17,28 @@ class WP_Members_Captcha { + /** + * Gets which CAPTCHA is set. + * + * @since 3.3.5 + */ + static function type() { + global $wpmem; + switch ( $wpmem->captcha ) { + case 1: + case 3: + return "recaptcha_v2"; + break; + case 4: + return"recaptcha_v3"; + break; + case 2: + default: + return "rs_captcha"; + break; + } + } + /** * Display a CAPTCHA. * @@ -57,7 +79,7 @@ static function recaptcha() { if ( 3 == $wpmem->captcha ) { $str = '
    '; - } elseif ( 4 == $wpmem->captcha ) { + } else { $str = ''; $str.= "ID, 'wpmem_product_message', true ); $message = ( $product_message ) ? $product_message : ''; + /** + * Fires before membership product message meta box. + * + * @since 3.3.5 + */ + do_action( 'wpmem_membership_product_message_meta_before' ); echo ''; echo ''; + /** + * Fires after membership product messate meta box. + * + * @since 3.3.5 + */ + do_action( 'wpmem_membership_product_message_meta_after' ); } /** diff --git a/readme.txt b/readme.txt index 5c604534..4d0b4378 100644 --- a/readme.txt +++ b/readme.txt @@ -138,6 +138,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.5 is an improvement release. * Fixed an issue where the Really Simple Captcha "not installed" error was returned as a string but evaluated as an array. * Fixed an issue that caused the "membership" field selector/type to display as a text input in Users > Add New instead of a dropdown/select. * Added user api functions wpmem_get_user_id(), wpmem_get_user_obj(), wpmem_get_users_by_meta(). +* Added action hooks to membership product admin screen. = 3.3.4 = From 1409d4bf41514b5db1eecbe04e296259b79f9bd2 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 17 Jun 2020 11:24:17 -0400 Subject: [PATCH 1268/1694] cleanup --- assets/css/admin.css | 1 + includes/class-wp-members-forms.php | 2 +- includes/deprecated.php | 98 ++--------------------------- wp-members.php | 4 +- 4 files changed, 9 insertions(+), 96 deletions(-) diff --git a/assets/css/admin.css b/assets/css/admin.css index 66381e6a..0281b5d9 100644 --- a/assets/css/admin.css +++ b/assets/css/admin.css @@ -117,6 +117,7 @@ color: #fff; } +#wpmem_product_fixed_period_select label, #wpmem_product_fixed_period_select input, #wpmem_product_no_gap, #wpmem_product_fixed_period { diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 4a2d38b2..bfdc5788 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -698,7 +698,7 @@ function login_form( $mixed, $arr = array() ) { * @since 3.2.5 Added $tag parameter. * * @param string The raw link. - * @param string $tag forgot|reg|pwdreset. + * @param string $tag forgot|reg|pwdreset|username. */ $link = apply_filters( "wpmem_{$tag}_link", $value['link'], $tag ); $str = $wpmem->get_text( "{$key}_link_before" ) . '' . $wpmem->get_text( "{$key}_link" ) . ''; diff --git a/includes/deprecated.php b/includes/deprecated.php index edc8bb10..f1869349 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -287,41 +287,14 @@ function wpmem_inc_forgotusername() { * Create reCAPTCHA form. * * @since 2.6.0 - * @deprecated 3.3.0 + * @deprecated 3.3.0 Use WP_Members_Captcha::show( 'captcha_v2' ) instead. * * @param array $arr * @return string $str HTML for reCAPTCHA display. */ function wpmem_inc_recaptcha( $arr ) { wpmem_write_log( "wpmem_inc_recaptcha() is deprecated as of WP-Members 3.3.0." ); - // Determine if reCAPTCHA should be another language. - $allowed_langs = array( 'nl', 'fr', 'de', 'pt', 'ru', 'es', 'tr' ); - /** This filter is documented in wp-includes/l10n.php */ - $locale = apply_filters( 'plugin_locale', get_locale(), 'wp-members' ); - $compare_lang = strtolower( substr( $locale, -2 ) ); - $use_the_lang = ( in_array( $compare_lang, $allowed_langs ) ) ? $compare_lang : false; - $lang = ( $use_the_lang ) ? ' lang : \'' . $use_the_lang . '\'' : ''; - - // Determine if we need ssl. - $http = wpmem_use_ssl(); - - global $wpmem; - if ( $wpmem->captcha == 3 ) { - - $str = ' -
    '; - } - - /** - * Filter the reCAPTCHA HTML. - * - * @since 2.7.4 - * - * @param string $str A string of HTML for the reCAPTCHA. - */ - $str = apply_filters( 'wpmem_recaptcha', $str ); - - return $str; + return WP_Members_Captcha::recaptcha(); } endif; @@ -329,6 +302,7 @@ function wpmem_inc_recaptcha( $arr ) { * Create Really Simple CAPTCHA. * * @since 2.9.5 + * @deprecated 3.3.0 Use WP_Members_Captcha::show( 'rs_captcha' ) instead. * * @global object $wpmem The WP_Members object. * @return array { @@ -340,70 +314,8 @@ function wpmem_inc_recaptcha( $arr ) { * } */ function wpmem_build_rs_captcha() { - - global $wpmem; - - if ( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { - // setup defaults - $defaults = array( - 'characters' => 'ABCDEFGHJKLMNPQRSTUVWXYZ23456789', - 'num_char' => '4', - 'dim_w' => '72', - 'dim_h' => '30', - 'font_color' => '0,0,0', - 'bg_color' => '255,255,255', - 'font_size' => '12', - 'kerning' => '14', - 'img_type' => 'png', - ); - $wpmem_captcha = get_option( 'wpmembers_captcha' ); - - $args = ( isset( $wpmem_captcha['really_simple'] ) && is_array( $wpmem_captcha['really_simple'] ) ) ? $wpmem_captcha['really_simple'] : array(); - $args = wp_parse_args( $args, $defaults ); - - $img_size = array( $args['dim_w'], $args['dim_h'] ); - $fg = explode( ",", $args['font_color'] ); - $bg = explode( ",", $args['bg_color'] ); - - $wpmem_captcha = new ReallySimpleCaptcha(); - $wpmem_captcha->chars = $args['characters']; - $wpmem_captcha->char_length = $args['num_char']; - $wpmem_captcha->img_size = $img_size; - $wpmem_captcha->fg = $fg; - $wpmem_captcha->bg = $bg; - $wpmem_captcha->font_size = $args['font_size']; - $wpmem_captcha->font_char_width = $args['kerning']; - $wpmem_captcha->img_type = $args['img_type']; - - $wpmem_captcha_word = $wpmem_captcha->generate_random_word(); - $wpmem_captcha_prefix = mt_rand(); - $wpmem_captcha_image_name = $wpmem_captcha->generate_image( $wpmem_captcha_prefix, $wpmem_captcha_word ); - - /** - * Filters the default Really Simple Captcha folder location. - * - * @since 3.0 - * - * @param string The default location of RS Captcha. - */ - $wpmem_captcha_image_url = apply_filters( 'wpmem_rs_captcha_folder', get_bloginfo('wpurl') . '/wp-content/plugins/really-simple-captcha/tmp/' ); - - $img_w = $wpmem_captcha->img_size[0]; - $img_h = $wpmem_captcha->img_size[1]; - $src = $wpmem_captcha_image_url . $wpmem_captcha_image_name; - $size = $wpmem_captcha->char_length; - $pre = $wpmem_captcha_prefix; - - return array( - 'label_text' => $wpmem->get_text( 'register_rscaptcha' ), - 'label' => '', - 'field' => ' - - captcha' - ); - } else { - return; - } + wpmem_write_log( "wpmem_build_rs_captcha() is deprecated as of WP-Members 3.3.0." ); + return ( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) ? WP_Members_Captcha::show( 'rs_captcha' ) : ''; } /** diff --git a/wp-members.php b/wp-members.php index 461d00af..d06fdd15 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.3.4.1 +Version: 3.3.5 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -64,7 +64,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.3.4.1' ); +define( 'WPMEM_VERSION', '3.3.5' ); define( 'WPMEM_DB_VERSION', '2.2.0' ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From c98dd76f3bc3f2778e4692023bc15f7af7020160 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 17 Jun 2020 11:25:48 -0400 Subject: [PATCH 1269/1694] display hidden posts as table in cli --- includes/cli/class-wp-members-cli.php | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/includes/cli/class-wp-members-cli.php b/includes/cli/class-wp-members-cli.php index e1363900..cbc115ba 100644 --- a/includes/cli/class-wp-members-cli.php +++ b/includes/cli/class-wp-members-cli.php @@ -32,8 +32,20 @@ public function refresh_hidden_posts() { } public function get_hidden_posts() { - $posts = implode( ", ", wpmem_get_hidden_posts() ); - WP_CLI::line( 'hidden post IDs: ' . $posts ); + + $hidden_posts = wpmem_get_hidden_posts(); + foreach ( $hidden_posts as $post_id ) { + $list[] = array( + 'id' => $post_id, + 'title' => get_the_title( $post_id ), + 'url' => get_permalink( $post_id ), + ); + } + + WP_CLI::line( 'WP-Members hidden posts:' ); + $formatter = new \WP_CLI\Formatter( $assoc_args, array( 'id', 'title', 'url' ) ); + $formatter->display_items( $list ); + } public function set_post_status( $args, $assoc_args ) { From da6228d5b0fe378c9ff56b9bfa1389d2410dcc17 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 17 Jun 2020 14:17:43 -0400 Subject: [PATCH 1270/1694] fixed required label for woocommerce checkout --- includes/api/api-forms.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index d60979c0..0d1a29c5 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -517,11 +517,11 @@ function wpmem_form_field_wc_custom_field_types( $field, $key, $args, $value ) { $field_html = wpmem_form_field( $field_args ); $field_html = str_replace( 'class="' . $wpmem_fields[ $key ]['type'] . '"', 'class="' . $wpmem_fields[ $key ]['type'] . '" style="display:initial;"', $field_html ); $field = '

    - '; + '; $field .= $field_html; $field .= '

    '; } - return $field; + return $field; } \ No newline at end of file From d9799aae56ab280c9bdcef29cda7d66913d87bc8 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 17 Jun 2020 14:20:09 -0400 Subject: [PATCH 1271/1694] fixed tos link issue with woocommerce checkout --- includes/api/api-forms.php | 5 +- includes/class-wp-members-forms.php | 128 +++++++++++------------ includes/class-wp-members-shortcodes.php | 4 +- 3 files changed, 64 insertions(+), 73 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 0d1a29c5..09cbf5b1 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -430,20 +430,19 @@ function wpmem_woo_checkout_fields( $checkout_fields = false ) { * @param array $checkout_fields */ function wpmem_woo_checkout_form( $checkout_fields ) { - + global $wpmem; $fields = wpmem_woo_checkout_fields( $checkout_fields ); foreach ( $fields as $meta_key => $field ) { $checkout_fields['order'][ $meta_key ] = array( 'type' => $fields[ $meta_key ]['type'], - 'label' => $fields[ $meta_key ]['label'], + 'label' => ( 'tos' == $meta_key ) ? $wpmem->forms->get_tos_link( $field, 'woo' ) : $fields[ $meta_key ]['label'], 'required' => $fields[ $meta_key ]['required'], ); if ( isset( $fields[ $meta_key ]['placeholder'] ) ) { $checkout_fields['order'][ $meta_key ]['placeholder'] = $fields[ $meta_key ]['placeholder']; } } - return $checkout_fields; } diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index bfdc5788..2ebc4fcb 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1013,50 +1013,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { ) ); $input = ( $field['required'] ) ? $input . $args['req_mark'] : $input; - // Determine if TOS is a WP page or not. - $tos_content = stripslashes( get_option( 'wpmembers_tos' ) ); - if ( has_shortcode( $tos_content, 'wpmem_tos' ) || has_shortcode( $tos_content, 'wp-members' ) ) { - $tos_link_url = do_shortcode( $tos_content ); - $tos_link_tag = ''; - } else { - $tos_link_url = add_query_arg( 'tos', 'display' ); - $tos_link_tag = ""; - } - - /** - * Filter the TOS link. - * - * @since 3.2.6 - * - * @param string $tos_link_tag - * @param string $tos_link_url - */ - $tos_link_tag = apply_filters( 'wpmem_tos_link_tag', $tos_link_tag, $tos_link_url ); - - /** - * Filter the TOS link text. - * - * @since 2.7.5 - * - * @param string The link text. - * @param string $tag Toggle new registration or profile update. new|edit. - */ - $tos_link_text = apply_filters( 'wpmem_tos_link_txt', $wpmem->get_text( 'register_tos' ), $tag ); - - // If filtered value is not the default label, use that, otherwise use label. - // @note: if default changes, this check must change. - if ( __( 'Please indicate that you agree to the %s Terms of Service %s', 'wp-members' ) == $tos_link_text ) { - if ( __( 'TOS', 'wp-members' ) != $field['label'] && __( 'Terms of Service', 'wp-members' ) != $field['label'] ) { - $tos_link_text = $field['label']; - } - } - - // If tos string does not contain link identifiers (%s), wrap the whole string. - if ( ! strpos( $tos_link_text, '%s' ) ) { - $tos_link_text = '%s' . $tos_link_text . '%s'; - } - - $input .= ' ' . sprintf( $tos_link_text, $tos_link_tag, '' ); + $input .= ' ' . $this->get_tos_link( $field, $tag ); // In previous versions, the div class would end up being the same as the row before. $field_before = ( $args['wrap_inputs'] ) ? '
    ' : ''; @@ -1604,31 +1561,7 @@ function wp_register_form( $process = 'wp' ) { if ( 'checkbox' == $field['type'] ) { if ( 'tos' == $meta_key ) { - $tos_content = stripslashes( get_option( 'wpmembers_tos' ) ); - if ( has_shortcode( $tos_content, 'wpmem_tos' ) || has_shortcode( $tos_content, 'wp-members' ) ) { - $link = do_shortcode( $tos_content ); - $tos_pop = ''; - } else { - $tos_pop = "url . "/wp-members-tos.php','mywindow');\">"; - } - /** This filter is documented in includes/class-wp-members-forms.php */ - $tos_link_text = apply_filters( 'wpmem_tos_link_txt', $wpmem->get_text( 'register_tos' ), 'new' ); - - // If filtered value is not the default label, use that, otherwise use label. - // @note: if default changes, this check must change. - if ( __( 'Please indicate that you agree to the %s Terms of Service %s', 'wp-members' ) == $tos_link_text ) { - if ( __( 'TOS', 'wp-members' ) != $field['label'] && __( 'Terms of Service', 'wp-members' ) != $field['label'] ) { - $tos_link_text = $field['label']; - } - } - - // If tos string does not contain link identifiers (%s), wrap the whole string. - if ( ! strpos( $tos_link_text, '%s' ) ) { - $tos_link_text = '%s' . $tos_link_text . '%s'; - } - - $tos_link_text = ' ' . sprintf( $tos_link_text, $tos_pop, '' ); - + $tos_link_text = $this->get_tos_link( $field, 'woo' ); } $label = ( 'tos' == $meta_key ) ? $tos_link_text : __( $field['label'], 'wp-members' ); @@ -2066,4 +1999,61 @@ function wp_login_form( $args ) { return wp_login_form( $args ); } + + /** + * Generate TOS field with link. + * + * @since 3.3.5 + * + * @param array $field + * @param string $tag + * @return string + */ + function get_tos_link( $field, $tag = 'new' ) { + global $wpmem; + // Determine if TOS is a WP page or not. + $tos_content = stripslashes( get_option( 'wpmembers_tos' ) ); + if ( has_shortcode( $tos_content, 'wpmem_tos' ) || has_shortcode( $tos_content, 'wp-members' ) ) { + $tos_link_url = do_shortcode( $tos_content ); + $tos_link_tag = ''; + } else { + $tos_link_url = add_query_arg( 'tos', 'display' ); + $tos_link_tag = ""; + } + + /** + * Filter the TOS link. + * + * @since 3.2.6 + * + * @param string $tos_link_tag + * @param string $tos_link_url + */ + $tos_link_tag = apply_filters( 'wpmem_tos_link_tag', $tos_link_tag, $tos_link_url ); + + /** + * Filter the TOS link text. + * + * @since 2.7.5 + * + * @param string The link text. + * @param string $tag Toggle new registration or profile update. new|edit. + */ + $tos_link_text = apply_filters( 'wpmem_tos_link_txt', $wpmem->get_text( 'register_tos' ), $tag ); + + // If filtered value is not the default label, use that, otherwise use label. + // @note: if default changes, this check must change. + if ( __( 'Please indicate that you agree to the %s Terms of Service %s', 'wp-members' ) == $tos_link_text ) { + if ( __( 'TOS', 'wp-members' ) != $field['label'] && __( 'Terms of Service', 'wp-members' ) != $field['label'] ) { + $tos_link_text = $field['label']; + } + } + + // If tos string does not contain link identifiers (%s), wrap the whole string. + if ( ! strpos( $tos_link_text, '%s' ) ) { + $tos_link_text = '%s' . $tos_link_text . '%s'; + } + + return sprintf( $tos_link_text, $tos_link_tag, '' ); + } } // End of WP_Members_Forms class. \ No newline at end of file diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index 8a1efca1..a36250b8 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -724,6 +724,7 @@ function logout( $atts, $content, $tag ) { * * @since 3.1.2 * @since 3.2.0 Moved to WP_Members_Shortcodes::tos(). + * @since 3.2.5 Now can use page slug (without full url). * * @param array $atts { * The shortcode attributes. @@ -735,7 +736,8 @@ function logout( $atts, $content, $tag ) { * @retrun string $content */ function tos( $atts, $content, $tag ) { - return esc_url( $atts['url'] ); + $url = ( strpos( $atts['url'], 'http' ) ) ? $atts['url'] : home_url( $atts['url'] ); + return esc_url( $url ); } /** From b4e9c4c1554422e5b24e906f2b4ad7cc6d24f2fa Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 17 Jun 2020 14:25:07 -0400 Subject: [PATCH 1272/1694] user_url was handled as meta, needs to be input via wp_update_user() --- includes/api/api-forms.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 09cbf5b1..f28ca3f8 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -475,7 +475,11 @@ function wpmem_woo_checkout_update_meta( $order_id ) { update_user_meta( $user_id, $meta_key, wpmem_sanitize_array( $_POST[ $meta_key ] ) ); break; default: - update_user_meta( $user_id, $meta_key, sanitize_text_field( $_POST[ $meta_key ] ) ); + if ( 'user_url' == $meta_key ) { + wp_update_user( array( 'ID' => $user_id, 'user_url' => sanitize_text_field( $_POST[ $meta_key ] ) ) ); + } else { + update_user_meta( $user_id, $meta_key, sanitize_text_field( $_POST[ $meta_key ] ) ); + } break; } } From ba4aac85ed3d193c977004c38cb01f2e585554c6 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Jul 2020 14:13:27 -0400 Subject: [PATCH 1273/1694] added wpmem_is_user_activated filter --- includes/admin/class-wp-members-admin-users.php | 7 ++++--- includes/class-wp-members-user.php | 11 ++++++++++- readme.txt | 1 + 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/includes/admin/class-wp-members-admin-users.php b/includes/admin/class-wp-members-admin-users.php index 1f7144e9..5a039958 100644 --- a/includes/admin/class-wp-members-admin-users.php +++ b/includes/admin/class-wp-members-admin-users.php @@ -43,6 +43,7 @@ static function bulk_user_action() { * Function to add activate link to the user row action. * * @since 2.8.2 + * @since 3.3.5 Updated to use wpmem_is_user_activated(). * * @param array $actions * @param $user_object @@ -52,12 +53,12 @@ static function insert_activate_link( $actions, $user_object ) { global $wpmem; if ( 1 == $wpmem->mod_reg && $user_object->ID != get_current_user_id() ) { - $var = get_user_meta( $user_object->ID, 'active', true ); + $is_active = wpmem_is_user_activated( $user_object->ID ); - if ( $var != 1 ) { + if ( false === $is_active ) { $action = 'activate'; $term = __( 'Activate', 'wp-members' ); - } elseif ( 1 == $var ) { + } else { $action = 'deactivate'; $term = __( 'Deactivate', 'wp-members' ); } diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 51cbb0f4..886891d4 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -1091,7 +1091,16 @@ function is_current( $date ) { function is_user_activated( $user_id = false ) { $user_id = ( ! $user_id ) ? get_current_user_id() : $user_id; $active = get_user_meta( $user_id, 'active', true ); - return ( $active != 1 ) ? false : true; + $is_activated = ( 1 == $active ) ? true : false; + /** + * Filter whether the user is active or not. + * + * @since 3.3.5 + * + * @param bool $is_activated + * @param int $user_id + */ + return apply_filters( 'wpmem_is_user_activated', $is_activated, $user_id ); } /** diff --git a/readme.txt b/readme.txt index 4d0b4378..21db5810 100644 --- a/readme.txt +++ b/readme.txt @@ -139,6 +139,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.5 is an improvement release. * Fixed an issue that caused the "membership" field selector/type to display as a text input in Users > Add New instead of a dropdown/select. * Added user api functions wpmem_get_user_id(), wpmem_get_user_obj(), wpmem_get_users_by_meta(). * Added action hooks to membership product admin screen. +* Added wpmem_is_user_activated filter hook. = 3.3.4 = From 9501686ae38c1b6cf1d9779744e29d37eff289b7 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Jul 2020 14:13:50 -0400 Subject: [PATCH 1274/1694] updates to wpmem user cli --- includes/cli/class-wp-members-cli-user.php | 113 ++++++++++++++++++++- 1 file changed, 111 insertions(+), 2 deletions(-) diff --git a/includes/cli/class-wp-members-cli-user.php b/includes/cli/class-wp-members-cli-user.php index 42575c34..8ecdc7a0 100644 --- a/includes/cli/class-wp-members-cli-user.php +++ b/includes/cli/class-wp-members-cli-user.php @@ -2,12 +2,121 @@ class WP_Members_CLI_User { - public function activate( $args ) { + /** + * CLI function to activate users. + * + * @since 3.3.5 + */ + public function activate( $args, $assoc_args ) { + $validation = $this->activate_validation( $assoc_args ); + + if ( true === $validation ) { + + $notify = ( isset( $assoc_args['notify'] ) && 'false' == $assoc_args['notify'] ) ? false : true; + + // Is the user already activated? + if ( false === wpmem_is_user_activated( $assoc_args['id'] ) ) { + + wpmem_activate_user( $assoc_args['id'], $notify ); + WP_CLI::success( __( 'User activated.', 'wp-members' ) ); + if ( $notify ) { + WP_CLI::success( __( 'Email notification sent to user.', 'wp-members' ) ); + } + } else { + WP_CLI::error( __( 'User is already activated.', 'wp-members' ) ); + } + } else { + WP_CLI::error( $validation ); + } + } + + /** + * CLI function to deactivate users. + * + * @since 3.3.5 + */ + public function deactivate( $args, $assoc_args ) { + $validation = $this->activate_validation( $assoc_args ); + if ( true === $validation ) { + wpmem_deactivate_user( $assoc_args['id'] ); + WP_CLI::success( __( 'User deactivated.', 'wp-members' ) ); + } else { + WP_CLI::error( $validation ); + } + } + + /** + * Validates user info for activation. + * + * @since 3.3.5 + */ + private function activate_validation( $assoc_args ) { + global $wpmem; + if ( 1 == $wpmem->mod_reg ) { + $user_id = ( isset( $assoc_args['id'] ) ) ? $assoc_args['id'] : false; + + if ( $user_id ) { + // Is the user ID and actual user? + if ( wpmem_is_user( $user_id ) ) { + return true; + } else { + WP_CLI::error( __( 'Invalid user ID. Please specify a valid user.', 'wp-members' ) ); + } + } else { + WP_CLI::error( __( 'No user id specified. Must specify user id as --id=123', 'wp-members' ) ); + } + } else { + WP_CLI::error( __( 'Moderated registration is not enabled in WP-Members options.', 'wp-members' ) ); + } } - public function deactivate( $args ) { + /** + * Lists users by activation state. + * + * @since 3.3.5 + */ + public function list( $args, $assoc_args ) { + + switch ( $assoc_args['status'] ) { + case 'pending': + $users = wpmem_get_pending_users(); + $status = 'pending'; + break; + case 'activated': + $users = wpmem_get_activated_users(); + $status = 'activated'; + break; + case 'deactivated': + $users = wpmem_get_deactivated_users(); + $status = 'deactivated'; + break; + } + foreach ( $users as $user_id ) { + $user = get_userdata( $user_id ); + $list[] = array( + 'ID' => $user->ID, + 'username' => $user->user_login, + 'email' => $user->user_email, + 'status' => $status, + ); + } + + $formatter = new \WP_CLI\Formatter( $assoc_args, array( 'ID', 'username', 'email', 'status' ) ); + $formatter->display_items( $list ); + } + + public function get_pending() { + $this->list( array(), array( 'status'=>'pending' ) ); + } + + public function get_activated() { + $this->list( array(), array( 'status'=>'activated' ) ); + } + + public function get_deactivated() { + $this->list( array(), array( 'status'=>'deactivated' ) ); } } From b3c6b3711ac8898b0d831a7415b2f622f89366fe Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Jul 2020 14:24:09 -0400 Subject: [PATCH 1275/1694] added wpmem_get_users_by_meta, and get by activation functions --- includes/api/api-users.php | 35 ++++++++++++++++++++++++++++++++--- readme.txt | 1 + 2 files changed, 33 insertions(+), 3 deletions(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index a5708580..a0fc60e6 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -829,21 +829,50 @@ function wpmem_get_user_obj( $user ) { /** * Get all users by a meta value. * - * @since 3.5.0 + * @since 3.3.5 * * @param string $meta The meta key to search fo. * @param string $value The meta value to search for (defaul:false). * @return array $users An array of user IDs who have the requested meta. */ -function wpmem_get_users_by_meta( $meta, $value = false ) { +function wpmem_get_users_by_meta( $meta, $value = "EXISTS" ) { $args = array( 'fields' => array( 'ID' ), 'meta_key' => $meta ); if ( false === $value ) { + $args['meta_value'] = ''; + $args['meta_compare'] = 'NOT EXISTS'; + } elseif ( "EXISTS" === $value ) { $args['meta_value'] = ''; $args['meta_compare'] = '>'; } else { $args['meta_value'] = $value; } - return get_users( $args ); + $results = get_users( $args ); + if ( $results ) { + foreach( $results as $result ) { + $users[] = $result->ID; + } + return $users; + } else { + return false; + } +} + +/** + * Gets a list of all pending users. + * + * @since 3.3.5 + * + */ +function wpmem_get_pending_users() { + return wpmem_get_users_by_meta( 'active', false ); +} + +function wpmem_get_activated_users() { + return wpmem_get_users_by_meta( 'active', 1 ); +} + +function wpmem_get_deactivated_users() { + return wpmem_get_users_by_meta( 'active', 0 ); } // End of file. \ No newline at end of file diff --git a/readme.txt b/readme.txt index 21db5810..2104d8fe 100644 --- a/readme.txt +++ b/readme.txt @@ -140,6 +140,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.5 is an improvement release. * Added user api functions wpmem_get_user_id(), wpmem_get_user_obj(), wpmem_get_users_by_meta(). * Added action hooks to membership product admin screen. * Added wpmem_is_user_activated filter hook. +* Added wpmem_get_users_by_meta(), wpmem_get_pending_users(), wpmem_get_activated_users(), and wpmem_get_deactivated_users(). = 3.3.4 = From f25442401da09a8807560226a88ff97ed3ece224 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Jul 2020 14:26:22 -0400 Subject: [PATCH 1276/1694] breaking out activation/password reset to separate options --- .../class-wp-members-admin-tab-options.php | 26 ++++++++++--------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index 117c0287..a6e451e4 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -159,17 +159,17 @@ static function build_settings() {

      + foreach ( $rows as $row ) { ?>
    • - - {$arr[ $row ][3]} ); ?>   - + + {$row[3]} ); ?>   +
    @@ -178,8 +178,9 @@ static function build_settings() { dropin_dir ); - $arr = array( - array(__('Activation', 'wp-members'),'wpmem_settings_pwd_reset',__('Send initial activation link and password reset link instead of new password. (Requires additional configuration)','wp-members'),'key_link'), + $rows = array( + array(__('Activation Link', 'wp-members'),'wpmem_settings_act_link',__('Send activation link on new registrartion. (Requires additional configuration)','wp-members'),'act_link'), + array(__('Password Reset Link', 'wp-members'),'wpmem_settings_pwd_link',__('Send password reset link instead of new password. (Requires additional configuration)','wp-members'),'pwd_link'), array(__('Enable Products', 'wp-members'),'wpmem_settings_products',__('Enables creation of different membership products','wp-members'),'enable_products'), array(__('Clone menus','wp-members'),'wpmem_settings_menus',__('Enables logged in menus','wp-members'),'clone_menus'), array(__('Notify admin','wp-members'),'wpmem_settings_notify',sprintf(__('Notify %s for each new registration? %s','wp-members'),$admin_email,$chg_email),'notify'), @@ -187,11 +188,11 @@ static function build_settings() { array(__('Ignore warning messages','wp-members'),'wpmem_settings_ignore_warnings',__('Ignores WP-Members warning messages in the admin panel','wp-members'),'warnings'), //array(__('Enable dropins', 'wp-members'),'wpmem_settings_enable_dropins',sprintf(__('Enables dropins in %s', 'wp-members'), $dropin_dir),'dropins'), ); - for ( $row = 0; $row < count( $arr ); $row++ ) { ?> + foreach ( $rows as $row ) { ?>
  • - - {$arr[$row][3]} ); ?>   - + + {$row[3]} ); ?>   +
  • @@ -480,7 +481,8 @@ static function update( $action ) { $wpmem_newsettings = array( 'version' => $wpmem->version, 'db_version' => $wpmem->db_version, - 'key_link' => filter_var( wpmem_get( 'wpmem_settings_pwd_reset', 0 ), FILTER_SANITIZE_NUMBER_INT ), + 'act_link' => filter_var( wpmem_get( 'wpmem_settings_act_link', 0 ), FILTER_SANITIZE_NUMBER_INT ), + 'pwd_link' => filter_var( wpmem_get( 'wpmem_settings_pwd_link', 0 ), FILTER_SANITIZE_NUMBER_INT ), 'enable_products' => filter_var( wpmem_get( 'wpmem_settings_products', 0 ), FILTER_SANITIZE_NUMBER_INT ), 'clone_menus' => filter_var( wpmem_get( 'wpmem_settings_menus', 0 ), FILTER_SANITIZE_NUMBER_INT ), 'notify' => filter_var( wpmem_get( 'wpmem_settings_notify', 0 ), FILTER_SANITIZE_NUMBER_INT ), From f887f45da3ccc70577692ade497f8ff2ede0b813 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Jul 2020 14:27:00 -0400 Subject: [PATCH 1277/1694] identify captcha as only for reg --- includes/admin/tabs/class-wp-members-admin-tab-options.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index a6e451e4..c654bd68 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -201,7 +201,7 @@ static function build_settings() {
  • - + captcha ) { $wpmem->captcha = 3; // reCAPTCHA v1 is fully obsolete. Change it to v2. From b66a96f99479616f5de1dc8e2992374f6751b77d Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Jul 2020 14:28:00 -0400 Subject: [PATCH 1278/1694] add support for handling membership field type in woo registration --- includes/api/api-forms.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index f28ca3f8..f4fe5961 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -474,6 +474,9 @@ function wpmem_woo_checkout_update_meta( $order_id ) { case 'multiselect': update_user_meta( $user_id, $meta_key, wpmem_sanitize_array( $_POST[ $meta_key ] ) ); break; + case 'membership': + wpmem_set_user_product( wpmem_sanitize_array( $_POST[ $meta_key ] ), $user_id ); + break; default: if ( 'user_url' == $meta_key ) { wp_update_user( array( 'ID' => $user_id, 'user_url' => sanitize_text_field( $_POST[ $meta_key ] ) ) ); From 4b82b054d1f696979c5d7fee239c64c5afefa22d Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Jul 2020 14:28:53 -0400 Subject: [PATCH 1279/1694] added "notify" argument to activation --- includes/api/api-users.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index a0fc60e6..57662fbc 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -416,10 +416,12 @@ function wpmem_create_membership_number( $args ) { * @since 3.1.6 Dependencies now loaded by object. * @since 3.2.4 Renamed from wpmem_a_activate_user(). * @since 3.3.0 Moved to user API. + * @since 3.3.5 Added $notify argument. * * @param int $user_id + * @param bool $notify Send notification to user (optional, default: true). */ -function wpmem_activate_user( $user_id ) { +function wpmem_activate_user( $user_id, $notify = true ) { global $wpmem; @@ -441,7 +443,9 @@ function wpmem_activate_user( $user_id ) { } // Generate and send user approved email to user. - wpmem_email_to_user( $user_id, $new_pass, 2 ); + if ( true === $notify ) { + wpmem_email_to_user( $user_id, $new_pass, 2 ); + } // Set the active flag in usermeta. update_user_meta( $user_id, 'active', 1 ); From ba2eb986bafa828bc87152775ee12e10b1c5fbfe Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Jul 2020 14:29:30 -0400 Subject: [PATCH 1280/1694] breaking out activation/password reset to separate options --- includes/class-wp-members.php | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index dfb10fdf..793496b2 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -297,6 +297,17 @@ class WP_Members { * @var boolean */ public $is_rest = false; + + /** + * Temporary setting for activation link. + * Will default to 0 until 3.4.0, then 1 until 3.5.0 + * at which point we'll remove the old process. + * + * @since 3.3.5 + * @access public + * @var string + */ + public $act_link = 0; /** * Temporary setting for password reset. @@ -307,7 +318,7 @@ class WP_Members { * @access public * @var string */ - public $key_link = 0; + public $pwd_link = 0; /** * Plugin initialization function. @@ -368,8 +379,10 @@ function __construct() { if ( $this->clone_menus ) { $this->menus_clone = new WP_Members_Clone_Menus(); // Load clone menus. } - if ( 1 == $this->key_link ) { + if ( 1 == $this->pwd_link ) { $this->pwd_reset = new WP_Members_Pwd_Reset; + } + if ( 1 == $this->act_link ) { $this->act_newreg = new WP_Members_Activation_Link; } From d3354369d2707dd239ada0e87fcda9eea7b534a2 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Jul 2020 14:30:06 -0400 Subject: [PATCH 1281/1694] only check if products are enabled --- includes/class-wp-members-products.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-products.php b/includes/class-wp-members-products.php index 553b337a..d8008bf5 100644 --- a/includes/class-wp-members-products.php +++ b/includes/class-wp-members-products.php @@ -185,7 +185,7 @@ function product_access( $content ) { global $post, $wpmem; // Is the user logged in and is this blocked content? - if ( ! is_admin() && is_user_logged_in() && wpmem_is_blocked() ) { // @todo Should is_admin() check be run on securify in general? + if ( ! is_admin() && is_user_logged_in() && wpmem_is_blocked() && 1 == $wpmem->enable_products ) { // @todo Should is_admin() check be run on securify in general? // Get the post access products. $post_products = $this->get_post_products( $post->ID ); From 3f1e1aba326ca1e81d92e96a965d57cc39a722b8 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 8 Jul 2020 10:24:42 -0400 Subject: [PATCH 1282/1694] add fixed date calculation, moved expiration calcs to product class --- .../admin/class-wp-members-products-admin.php | 39 +++-- includes/class-wp-members-products.php | 133 +++++++++++++++++- includes/class-wp-members-user.php | 45 +----- 3 files changed, 158 insertions(+), 59 deletions(-) diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index 93e899ec..b144f4e0 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -193,7 +193,14 @@ function details_html( $post ) { $periods = array( __( 'Period', 'wp-members' ) . '|', __( 'Day', 'wp-members' ) . '|day', __( 'Week', 'wp-members' ) . '|week', __( 'Month', 'wp-members' ) . '|month', __( 'Year', 'wp-members' ) . '|year' ); $show_role_detail = ( false !== $product_role ) ? 'show' : 'hide'; $show_exp_detail = ( false !== $product_expires ) ? 'show' : 'hide'; - $show_exp_fixed = ( false !== $product_fixed_period ) ? 'show' : 'hide'; ?> + $show_exp_fixed = ( false !== $product_fixed_period ) ? 'show' : 'hide'; + + /** + * Fires before membership product detail meta box. + * + * @since 3.3.5 + */ + do_action( 'wpmem_membership_product_meta_before' ); ?>

    @@ -243,12 +250,12 @@ function details_html( $post ) { 'wpmem_product_fixed_period', 'type'=>'checkbox', 'value'=>'1', 'compare'=>( false != $product_fixed_period ) ? 1 : '' ) ); ?>
    - +
    - +
    +
    +
    -
    - +

    + + - - - - - 'wpmem_product_fixed_period_grace_period', 'type'=>'select', 'value'=>$periods, 'compare'=>( ( isset( $period_grace_per ) ) ? $period_grace_per : '' ) ) ); ?> + + + + + 'wpmem_product_fixed_period_grace_period', 'type'=>'select', 'value'=>$periods, 'compare'=>( ( isset( $period_grace_per ) ) ? $period_grace_per : '' ) ) ); ?> + +

    +
    - - - +

    '; + /** This filter is defined in /includes/class-wp-members-captcha.php */ + return apply_filters( 'wpmem_captcha', $html ); + } + /** * Create reCAPTCHA form. * * @since 3.3.0 Replaces wpmem_inc_recaptcha(). - * @since 3.3.5 Accepts no arguments. + * @since 3.3.5 Accepts API public key for static use. * - * @return string $str HTML for reCAPTCHA display. + * @global stdCalss $wpmem + * @param string $key Your reCAPTCHA public key. + * @return string $html HTML for reCAPTCHA display. */ - static function recaptcha() { + static function recaptcha( $key = false ) { + + if ( false === $keys ) { + $opts = get_option( 'wpmembers_captcha' ); + $key = $opts['recaptcha']['public']; + } - $wpmem_captcha = get_option( 'wpmembers_captcha' ); - - // Determine if reCAPTCHA should be another language. - $allowed_langs = array( 'nl', 'fr', 'de', 'pt', 'ru', 'es', 'tr' ); - /** This filter is documented in wp-includes/l10n.php */ - $locale = apply_filters( 'plugin_locale', get_locale(), 'wp-members' ); - $compare_lang = strtolower( substr( $locale, -2 ) ); - $use_the_lang = ( in_array( $compare_lang, $allowed_langs ) ) ? $compare_lang : false; - $lang = ( $use_the_lang ) ? ' lang : \'' . $use_the_lang . '\'' : ''; - global $wpmem; if ( 3 == $wpmem->captcha ) { - $str = ' -
    '; + $html = ' +
    '; } else { - $str = ''; - $str.= "'; + $html.= ""; - $str.= ''; + $html.= ''; } /** * Filter the reCAPTCHA HTML. * * @since 2.7.4 + * @deprecated 3.3.5 Use wpmem_captcha instead. * - * @param string $str A string of HTML for the reCAPTCHA. + * @param string $html A string of HTML for the reCAPTCHA. */ - $str = apply_filters( 'wpmem_recaptcha', $str ); + $html = apply_filters( 'wpmem_recaptcha', $html ); - return $str; + /** + * Filter the captcha HTML. + * + * @since 3.3.5 + * + * @param string $html A string of HTML for the registration captcha. + */ + return apply_filters( 'wpmem_captcha', $html ); } /** @@ -114,8 +145,8 @@ static function recaptcha() { * @since 3.3.0 Replaces wpmem_build_rs_captcha(). * * @global object $wpmem The WP_Members object. - * @return array { - * HTML Form elements for Really Simple CAPTCHA. + * @return string|array { + * HTML string, OR array of form elements for Really Simple CAPTCHA. * * @type string label_text The raw text used for the label. * @type string label The HTML for the label. @@ -139,28 +170,24 @@ static function rs_captcha( $return = 'string' ) { 'kerning' => '14', 'img_type' => 'png', ); - $wpmem_captcha = get_option( 'wpmembers_captcha' ); + $opts = get_option( 'wpmembers_captcha' ); - $args = ( isset( $wpmem_captcha['really_simple'] ) && is_array( $wpmem_captcha['really_simple'] ) ) ? $wpmem_captcha['really_simple'] : array(); + $args = ( isset( $opts['really_simple'] ) && is_array( $opts['really_simple'] ) ) ? $opts['really_simple'] : array(); $args = wp_parse_args( $args, $defaults ); - $img_size = array( $args['dim_w'], $args['dim_h'] ); - $fg = explode( ",", $args['font_color'] ); - $bg = explode( ",", $args['bg_color'] ); + $rs_captcha = new ReallySimpleCaptcha(); + $rs_captcha->chars = $args['characters']; + $rs_captcha->char_length = $args['num_char']; + $rs_captcha->img_size = array( $args['dim_w'], $args['dim_h'] ); + $rs_captcha->fg = explode( ",", $args['font_color'] ); + $rs_captcha->bg = explode( ",", $args['bg_color'] ); + $rs_captcha->font_size = $args['font_size']; + $rs_captcha->font_char_width = $args['kerning']; + $rs_captcha->img_type = $args['img_type']; - $wpmem_captcha = new ReallySimpleCaptcha(); - $wpmem_captcha->chars = $args['characters']; - $wpmem_captcha->char_length = $args['num_char']; - $wpmem_captcha->img_size = $img_size; - $wpmem_captcha->fg = $fg; - $wpmem_captcha->bg = $bg; - $wpmem_captcha->font_size = $args['font_size']; - $wpmem_captcha->font_char_width = $args['kerning']; - $wpmem_captcha->img_type = $args['img_type']; - - $wpmem_captcha_word = $wpmem_captcha->generate_random_word(); - $wpmem_captcha_prefix = mt_rand(); - $wpmem_captcha_image_name = $wpmem_captcha->generate_image( $wpmem_captcha_prefix, $wpmem_captcha_word ); + $rs_captcha_word = $rs_captcha->generate_random_word(); + $rs_captcha_prefix = mt_rand(); + $rs_captcha_image_name = $rs_captcha->generate_image( $rs_captcha_prefix, $rs_captcha_word ); /** * Filters the default Really Simple Captcha folder location. @@ -169,13 +196,13 @@ static function rs_captcha( $return = 'string' ) { * * @param string The default location of RS Captcha. */ - $wpmem_captcha_image_url = apply_filters( 'wpmem_rs_captcha_folder', get_bloginfo('wpurl') . '/wp-content/plugins/really-simple-captcha/tmp/' ); + $rs_captcha_image_url = apply_filters( 'wpmem_rs_captcha_folder', get_bloginfo( 'wpurl' ) . '/wp-content/plugins/really-simple-captcha/tmp/' ); - $img_w = $wpmem_captcha->img_size[0]; - $img_h = $wpmem_captcha->img_size[1]; - $src = $wpmem_captcha_image_url . $wpmem_captcha_image_name; - $size = $wpmem_captcha->char_length; - $pre = $wpmem_captcha_prefix; + $img_w = $rs_captcha->img_size[0]; + $img_h = $rs_captcha->img_size[1]; + $src = $rs_captcha_image_url . $rs_captcha_image_name; + $size = $rs_captcha->char_length; + $pre = $rs_captcha_prefix; /** * Filter the RS CAPTCHA HTML. @@ -200,7 +227,9 @@ static function rs_captcha( $return = 'string' ) { if ( 'array' == $return ) { return $rows; } else { - return $rows['label'] . $rows['field'] . $rows['hidden'] . $rows['img']; + $html = $rows['label'] . $rows['field'] . $rows['hidden'] . $rows['img']; + /** This filter is defined in /includes/class-wp-members-captcha.php */ + return apply_filters( 'wpmem_captcha', $html ); } } else { return ( 'array' == $return ) ? array( 'label' => '', 'label_text' => '', 'field' => "Really Simple CAPTCHA is not enabled" ) : "Really Simple CAPTCHA is not enabled"; @@ -223,38 +252,69 @@ static function validate( $which_captcha = false ) { global $wpmem, $wpmem_themsg; - // Get the captcha settings (api keys). - $wpmem_captcha = get_option( 'wpmembers_captcha' ); - $captcha = ( ! $which_captcha ) ? self::type() : $which_captcha; if ( 'rs_captcha' == $captcha ) { if ( defined( 'REALLYSIMPLECAPTCHA_VERSION' ) ) { // Validate Really Simple Captcha. - $wpmem_captcha = new ReallySimpleCaptcha(); + $rs_captcha = new ReallySimpleCaptcha(); // This variable holds the CAPTCHA image prefix, which corresponds to the correct answer. - $wpmem_captcha_prefix = ( isset( $_POST['captcha_prefix'] ) ) ? sanitize_text_field( $_POST['captcha_prefix'] ) : ''; + $rs_captcha_prefix = ( isset( $_POST['captcha_prefix'] ) ) ? sanitize_text_field( $_POST['captcha_prefix'] ) : ''; // This variable holds the CAPTCHA response, entered by the user. - $wpmem_captcha_code = ( isset( $_POST['captcha_code'] ) ) ? sanitize_text_field( $_POST['captcha_code'] ) : ''; + $rs_captcha_code = ( isset( $_POST['captcha_code'] ) ) ? sanitize_text_field( $_POST['captcha_code'] ) : ''; // Check CAPTCHA validity. - $wpmem_captcha_correct = ( $wpmem_captcha->check( $wpmem_captcha_prefix, $wpmem_captcha_code ) ) ? true : false; + $rs_captcha_correct = ( $rs_captcha->check( $rs_captcha_prefix, $rs_captcha_code ) ) ? true : false; // Clean up the tmp directory. - $wpmem_captcha->remove( $wpmem_captcha_prefix ); - $wpmem_captcha->cleanup(); + $rs_captcha->remove( $rs_captcha_prefix ); + $rs_captcha->cleanup(); // If CAPTCHA validation fails (incorrect value entered in CAPTCHA field), return an error. - if ( ! $wpmem_captcha_correct ) { + if ( ! $rs_captcha_correct ) { $wpmem_themsg = __( 'You have entered an incorrect code value. Please try again.', 'wp-members' ); return false; } } + + } elseif ( 'hcaptcha' == $captcha ) { + + // Get the captcha settings (api keys). + $opts = get_option( 'wpmembers_captcha' ); + + $captcha = wpmem_get( 'h-captcha-response', false ); + + // If there is no captcha value, return error. + if ( false === $captcha ) { + $wpmem_themsg = $wpmem->get_text( 'reg_empty_captcha' ); + return false; + } + + // Validate the captcha. + $response = wp_remote_post( 'https://hcaptcha.com/siteverify', array( + 'body' => array( + 'secret' => $opts['hcaptcha']['secret'], + 'response' => $captcha, + ) ) ); + + // Decode the json response. + $response = json_decode( wp_remote_retrieve_body( $response, true ) ); + + if ( $response->success ) { + // your success code goes here + } else { + $wpmem_themsg = $wpmem->get_text( 'reg_invalid_captcha' ); + return false; + } + } else { // It is reCAPTCHA. $recaptcha_verify_url = 'https://www.google.com/recaptcha/api/siteverify?'; - $privatekey = $wpmem_captcha['recaptcha']['private']; + // Get the captcha settings (api keys). + $opts = get_option( 'wpmembers_captcha' ); + + $key = $opts['recaptcha']['private']; - if ( 'recaptcha_v2' == $captcha && $wpmem_captcha['recaptcha'] ) { + if ( 'recaptcha_v2' == $captcha && $opts['recaptcha'] ) { $captcha = wpmem_get( 'g-recaptcha-response', false ); @@ -266,7 +326,7 @@ static function validate( $which_captcha = false ) { // Build URL for captcha evaluation. $url = $recaptcha_verify_url . http_build_query([ - 'secret' => $privatekey, + 'secret' => $key, 'response' => $captcha, 'remoteip' => wpmem_get_user_ip(), ]); @@ -288,7 +348,7 @@ static function validate( $which_captcha = false ) { } return false; } - } elseif ( 'recaptcha_v3' == $captcha && $wpmem_captcha['recaptcha'] ) { + } elseif ( 'recaptcha_v3' == $captcha && $opts['recaptcha'] ) { $captcha = wpmem_get( 'recaptcha_response', false ); if ( false === $captcha ) { @@ -300,7 +360,7 @@ static function validate( $which_captcha = false ) { // Make and decode POST request: $url = $recaptcha_verify_url . http_build_query([ - 'secret' => $privatekey, + 'secret' => $key, 'response' => $captcha, ]); $recaptcha = file_get_contents( $url ); diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index ed1ab18e..3664850a 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1220,6 +1220,12 @@ function register_form( $mixed = 'new', $redirect_to = null ) { */ $form.= apply_filters( 'wpmem_register_captcha_row', $args['row_before'] . $row . $args['row_after'], $tag ); } + + if ( 5 == $wpmem->captcha && 'edit' != $tag ) { + $row = WP_Members_Captcha::hcaptcha(); + /** This filter is documented in /includes/class-wp-members-forms.php */ + $form.= apply_filters( 'wpmem_register_captcha_row', $args['row_before'] . $row . $args['row_after'], $tag ); + } // Create hidden fields. $var = ( $tag == 'edit' ) ? 'update' : 'register'; diff --git a/readme.txt b/readme.txt index 9c829a83..6613e397 100644 --- a/readme.txt +++ b/readme.txt @@ -135,7 +135,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.5 is an improvement release. = 3.3.5 = -* Added optional new user activation link and password reset link (instead of sending password). This option will become the default setting in 3.4.0. +* Added optional new user validation link and password reset link (instead of sending password). This option will become the default setting in 3.4.0. * Added optional login error message to fully utilize the WP login error. This option will become the default setting in 3.4.0. * Updated the default product restricted message to display required membership(s). This eliminates the custom message string "product_restricted" and replaces with two new ones: product_restricted_single and product_restricted_multiple. (Note this only affects the default message if no custom membership message is established in the membership properties). * Added login/logout button to login/logout link api function wpmem_loginout() and shortcode [wpmem_loginout]. It will continue to display a hyperlink by default, but accepts arguments to display as a button. Also added ID and class options for link or button. @@ -152,6 +152,8 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.5 is an improvement release. * Added manage_options capability requirement for membership products custom post type. * Updated WooCommerce registration handling. * Added wpmem_is_reg_type(). Can be used withing wpmem_post_register_data to determine which registration type is being triggered. +* Added WP-CLI commands (see release announcement and documentation for more information on specific commands). +* Added support for hCaptcha (https://www.hcaptcha.com/). = 3.3.4 = From 618937c82791ed3aeb5b84da934df880a0efebb7 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 12 Aug 2020 11:03:23 -0400 Subject: [PATCH 1314/1694] change act_link email shortcode to confirm_link --- includes/class-wp-members-validation-link.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-validation-link.php b/includes/class-wp-members-validation-link.php index ba058637..9927c080 100644 --- a/includes/class-wp-members-validation-link.php +++ b/includes/class-wp-members-validation-link.php @@ -125,8 +125,8 @@ public function add_key_to_email( $arr, $wpmem_fields, $field_data ) { $email_type = ( 1 == $wpmem->mod_reg ) ? 'newmod' : 'newreg'; if ( $arr['toggle'] == $email_type ) { // Does email body have the [act_link] shortcode? - if ( strpos( $arr['body'], '[act_link]' ) ) { - $arr['body'] = str_replace( '[act_link]', $link, $arr['body'] ); + if ( strpos( $arr['body'], '[confirm_link]' ) ) { + $arr['body'] = str_replace( '[confirm_link]', $link, $arr['body'] ); } else { // Add text and link to the email body. $arr['body'] = $arr['body'] . "\r\n" From 8b7ca892ae1405e50bc5e4043c2f1180d5201213 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 12 Aug 2020 11:03:35 -0400 Subject: [PATCH 1315/1694] fix issues with captcha --- includes/class-wp-members-captcha.php | 32 +++++++++++++++------------ includes/class-wp-members-forms.php | 2 +- 2 files changed, 19 insertions(+), 15 deletions(-) diff --git a/includes/class-wp-members-captcha.php b/includes/class-wp-members-captcha.php index 31255926..66102d6e 100644 --- a/includes/class-wp-members-captcha.php +++ b/includes/class-wp-members-captcha.php @@ -97,7 +97,7 @@ static function hcaptcha( $key = false ) { */ static function recaptcha( $key = false ) { - if ( false === $keys ) { + if ( false == $keys ) { $opts = get_option( 'wpmembers_captcha' ); $key = $opts['recaptcha']['public']; } @@ -219,7 +219,7 @@ static function rs_captcha( $return = 'string' ) { 'img_w' => esc_attr( $img_w ), 'img_h' => esc_attr( $img_h ), 'label' => '', - 'field' => '', + 'field' => '', 'hidden' => '', 'img' => 'captcha', ) ); @@ -227,7 +227,7 @@ static function rs_captcha( $return = 'string' ) { if ( 'array' == $return ) { return $rows; } else { - $html = $rows['label'] . $rows['field'] . $rows['hidden'] . $rows['img']; + $html = $rows['label'] . $rows['img'] . $rows['hidden'] . $rows['field']; /** This filter is defined in /includes/class-wp-members-captcha.php */ return apply_filters( 'wpmem_captcha', $html ); } @@ -248,7 +248,7 @@ static function rs_captcha( $return = 'string' ) { * @param $which_captcha * @return $string */ - static function validate( $which_captcha = false ) { + static function validate( $which_captcha = false, $secret = false ) { global $wpmem, $wpmem_themsg; @@ -277,8 +277,11 @@ static function validate( $which_captcha = false ) { } elseif ( 'hcaptcha' == $captcha ) { // Get the captcha settings (api keys). - $opts = get_option( 'wpmembers_captcha' ); - + if ( ! $secret ) { + $opts = get_option( 'wpmembers_captcha' ); + $secret = $opts['hcaptcha']['secret']; + } + $captcha = wpmem_get( 'h-captcha-response', false ); // If there is no captcha value, return error. @@ -290,7 +293,7 @@ static function validate( $which_captcha = false ) { // Validate the captcha. $response = wp_remote_post( 'https://hcaptcha.com/siteverify', array( 'body' => array( - 'secret' => $opts['hcaptcha']['secret'], + 'secret' => $secret, 'response' => $captcha, ) ) ); @@ -310,11 +313,12 @@ static function validate( $which_captcha = false ) { $recaptcha_verify_url = 'https://www.google.com/recaptcha/api/siteverify?'; // Get the captcha settings (api keys). - $opts = get_option( 'wpmembers_captcha' ); - - $key = $opts['recaptcha']['private']; + if ( ! $secret ) { + $opts = get_option( 'wpmembers_captcha' ); + $secret = $opts['recaptcha']['private']; + } - if ( 'recaptcha_v2' == $captcha && $opts['recaptcha'] ) { + if ( 'recaptcha_v2' == $captcha ) { $captcha = wpmem_get( 'g-recaptcha-response', false ); @@ -326,7 +330,7 @@ static function validate( $which_captcha = false ) { // Build URL for captcha evaluation. $url = $recaptcha_verify_url . http_build_query([ - 'secret' => $key, + 'secret' => $secret, 'response' => $captcha, 'remoteip' => wpmem_get_user_ip(), ]); @@ -348,7 +352,7 @@ static function validate( $which_captcha = false ) { } return false; } - } elseif ( 'recaptcha_v3' == $captcha && $opts['recaptcha'] ) { + } elseif ( 'recaptcha_v3' == $captcha ) { $captcha = wpmem_get( 'recaptcha_response', false ); if ( false === $captcha ) { @@ -360,7 +364,7 @@ static function validate( $which_captcha = false ) { // Make and decode POST request: $url = $recaptcha_verify_url . http_build_query([ - 'secret' => $key, + 'secret' => $secret, 'response' => $captcha, ]); $recaptcha = file_get_contents( $url ); diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 3664850a..33dfcecc 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1141,7 +1141,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { 'row_before' => $args['row_before'], 'label' => $row['label'], 'field_before' => ( $args['wrap_inputs'] ) ? '
    ' : '', - 'field' => $row['field'], + 'field' => $row['img'] . $row['hidden'] . $row['field'], 'field_after' => ( $args['wrap_inputs'] ) ? '
    ' : '', 'row_after' => $args['row_after'], ); From 00e97b1c15417ede8003816948bca4b25ae2a2ed Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 12 Aug 2020 11:35:36 -0400 Subject: [PATCH 1316/1694] fix variable type --- includes/class-wp-members-captcha.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-captcha.php b/includes/class-wp-members-captcha.php index 66102d6e..eea51418 100644 --- a/includes/class-wp-members-captcha.php +++ b/includes/class-wp-members-captcha.php @@ -97,7 +97,7 @@ static function hcaptcha( $key = false ) { */ static function recaptcha( $key = false ) { - if ( false == $keys ) { + if ( false == $key ) { $opts = get_option( 'wpmembers_captcha' ); $key = $opts['recaptcha']['public']; } From 26e49390de951ab525376855e098aba826e015bf Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 17 Aug 2020 11:13:36 -0400 Subject: [PATCH 1317/1694] add wpmem_update_option() api function --- includes/admin/api.php | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/includes/admin/api.php b/includes/admin/api.php index 144349d5..93e93f21 100644 --- a/includes/admin/api.php +++ b/includes/admin/api.php @@ -95,4 +95,25 @@ function wpmem_admin_form_post_url( $args = false ) { function wpmem_wp_reserved_terms() { global $wpmem; return $wpmem->admin->wp_reserved_terms(); +} + +/** + * Updates a single plugin option. + * + * @since 3.3.6 + * + * @param string $option Name of the option to update. + * @param string $key Which key to update. Update a subkey as primary_key/subkey. + * @param string $value New value. + * @return void + */ +function wpmem_update_option( $option, $key, $value ) { + $settings = get_option( $option ); + if ( strpos( $key, '/' ) ) { + $keys = explode( '/', $key ); + $settings[ $keys[0] ][ $keys[1] ] = $value; + } else { + $settings[ $key ] = $value; + } + update_option( $option, $settings ); } \ No newline at end of file From a765b6ade1bf0a15a18b79e4f26656ef6c4df8e7 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 17 Aug 2020 11:14:22 -0400 Subject: [PATCH 1318/1694] allow default captcha to be called statically --- includes/class-wp-members-captcha.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-captcha.php b/includes/class-wp-members-captcha.php index eea51418..addd0dda 100644 --- a/includes/class-wp-members-captcha.php +++ b/includes/class-wp-members-captcha.php @@ -51,11 +51,15 @@ static function type( $decode = false ) { * Display a CAPTCHA. * * @since 3.3.4 + * @since 3.3.6 $type defaults to false, so captcha defaults to $wpmem setting. * * @param string $type Type of captcha to display. * @param array $keys Google reCAPTCHA keys (if used). */ - static function show( $type, $key = false ) { + static function show( $type = false, $key = false ) { + if ( false === $type ) { + $type = self::type(); + } if ( 'rs_captcha' == $type ) { return self::rs_captcha(); } elseif ( 'hcaptcha' == $type ) { From e961011ad945f35521e93c22cf0b5f333df2f83a Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 17 Aug 2020 11:14:47 -0400 Subject: [PATCH 1319/1694] use wpmem_update_option() api function for updating settings --- .../cli/class-wp-members-cli-settings.php | 30 +++++-------------- 1 file changed, 7 insertions(+), 23 deletions(-) diff --git a/includes/cli/class-wp-members-cli-settings.php b/includes/cli/class-wp-members-cli-settings.php index 595f7282..36223f9a 100644 --- a/includes/cli/class-wp-members-cli-settings.php +++ b/includes/cli/class-wp-members-cli-settings.php @@ -154,13 +154,13 @@ public function post_type( $args, $assoc_args ) { // Handle disable. if ( isset( $assoc_args['disable'] ) ) { unset( $wpmem->post_types[ $assoc_args['disable'] ] ); - $this->update_option( 'post_types', $wpmem->post_types ); + wpmem_update_option( 'wpmembers_settings', 'post_types', $wpmem->post_types ); WP_CLI::success( 'Disabled ' . $assoc_args['disable'] . ' post type.' ); } if ( isset( $assoc_args['enable'] ) ) { $cpt_obj = get_post_type_object( $assoc_args['enable'] ); $new_post_types = array_merge($wpmem->post_types, array( $cpt_obj->name => $cpt_obj->labels->name ) ); - $this->update_option( 'post_types', $new_post_types ); + wpmem_update_option( 'wpmembers_settings', 'post_types', $new_post_types ); WP_CLI::success( 'Enabled ' . $assoc_args['enable'] . ' post type.' ); } } else { @@ -184,7 +184,7 @@ public function enable( $args, $assoc_args ) { global $wpmem; $settings = $wpmem->admin->settings( 'options' ); if ( array_key_exists( $args[0], $settings ) && 'captcha' !== $args[0] ) { - $this->update_option( $args[0], 1 ); + wpmem_update_option( 'wpmembers_settings', $args[0], 1 ); WP_CLI::success( $settings[ $args[0] ] . ' enabled' ); } if ( array_key_exists( $args[0], $settings ) && 'captcha' === $args[0] ) { @@ -199,7 +199,7 @@ public function enable( $args, $assoc_args ) { $which = 4; break; } - $this->update_option( $args[0], $which ); + wpmem_update_option( 'wpmembers_settings', $args[0], $which ); WP_CLI::success( $settings[ $args[0] ] . ' ' . $args[1] . ' enabled' ); } } @@ -220,7 +220,7 @@ public function disable( $args ) { global $wpmem; $settings = $wpmem->admin->settings( 'options' ); if ( array_key_exists( $args[0], $settings ) ) { - $this->update_option( $args[0], 0 ); + wpmem_update_option( 'wpmembers_settings', $args[0], 0 ); WP_CLI::success( $settings[ $args[0] ] . ' disabled' ); } } @@ -272,7 +272,7 @@ public function pages( $args, $assoc_args ) { } foreach ( $assoc_args as $page => $value ) { if ( isset( $assoc_args[ $page ] ) ) { - $this->update_option( 'user_pages/' . $page, '' ); + wpmem_update_option( 'wpmembers_settings', 'user_pages/' . $page, '' ); WP_CLI::success( ucfirst( $page ) . ' page cleared' ); } } @@ -284,7 +284,7 @@ public function pages( $args, $assoc_args ) { } foreach ( $assoc_args as $page => $value ) { if ( isset( $assoc_args[ $page ] ) ) { - $this->update_option( 'user_pages/' . $page, $assoc_args[ $page ] ); + wpmem_update_option( 'wpmembers_settings', 'user_pages/' . $page, $assoc_args[ $page ] ); WP_CLI::success( ucfirst( $page ) . ' page set to ID ' . $assoc_args[ $page ] ); } } @@ -305,22 +305,6 @@ public function pages( $args, $assoc_args ) { $formatter->display_items( $list ); } } - - /** - * Updates a WP-Members option value and saves. - * - * @since 3.3.5 - */ - private function update_option( $key, $value ){ - $current = get_option( 'wpmembers_settings' ); - if ( strpos( $key, '/' ) ) { - $keys = explode( '/', $key ); - $current[ $keys[0] ][ $keys[1] ] = $value; - } else { - $current[ $key ] = $value; - } - update_option( 'wpmembers_settings', $current ); - } } WP_CLI::add_command( 'mem settings', 'WP_Members_CLI_Settings' ); \ No newline at end of file From 85df447a92c57218553ba12f4c94fce57623d1fb Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 17 Aug 2020 11:15:25 -0400 Subject: [PATCH 1320/1694] improve captcha admin tab --- .../class-wp-members-admin-tab-captcha.php | 94 +++++++++---------- readme.txt | 14 +-- 2 files changed, 51 insertions(+), 57 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php index 039fedc2..11775eed 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php @@ -60,7 +60,7 @@ public static function add_tab( $tabs ) { public static function build_settings() { // Global settings. - global $wpmem; + global $wpmem, $updated_captcha_type; $wpmem_captcha = get_option( 'wpmembers_captcha' ); $url = home_url(); @@ -87,42 +87,28 @@ public static function build_settings() {
    - captcha == 1 ) { - $show_update_button = true; - $private_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['private'] : ''; - $public_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['public'] : ''; - $captcha_theme = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['theme'] : ''; - ?> - - - - - + + - - - + - captcha || 4 == $wpmem->captcha ) { + + captcha || 4 == $wpmem->captcha ) { $show_update_button = true; $private_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['private'] : ''; $public_key = ( isset( $wpmem_captcha['recaptcha'] ) ) ? $wpmem_captcha['recaptcha']['public'] : ''; @@ -130,7 +116,9 @@ public static function build_settings() { @@ -144,6 +132,9 @@ public static function build_settings() { @@ -269,47 +260,48 @@ public static function build_settings() { * @return string The captcha option update message. */ public static function update() { - + + global $wpmem; + // Check nonce. check_admin_referer( 'wpmem-update-captcha' ); $settings = get_option( 'wpmembers_captcha' ); $update_type = sanitize_text_field( $_POST['wpmem_recaptcha_type'] ); - $new_settings = array(); + $which = intval( wpmem_get( 'wpmem_settings_captcha', 0 ) ); // If there are no current settings. if ( ! $settings ) { $settings = array(); } + + if ( 0 != $which && $wpmem->captcha != $which ) { + // Changing captcha type. + global $updated_captcha_type; + $updated_captcha_type = true; + $wpmem->captcha = $which; + wpmem_update_option( 'wpmembers_settings', 'captcha', $which ); + } if ( $update_type == 'recaptcha' || $update_type == 'recaptcha2' ) { - if ( array_key_exists( 'really_simple', $settings ) ) { - // Updating recaptcha but need to maintain really_simple. - $new_settings['really_simple'] = $settings['really_simple']; - } - $new_settings['recaptcha'] = array( + $settings['recaptcha'] = array( 'public' => sanitize_text_field( $_POST['wpmem_captcha_publickey'] ), 'private' => sanitize_text_field( $_POST['wpmem_captcha_privatekey'] ), ); if ( $update_type == 'recaptcha' && isset( $_POST['wpmem_captcha_theme'] ) ) { - $new_settings['recaptcha']['theme'] = sanitize_text_field( $_POST['wpmem_captcha_theme'] ); + $settings['recaptcha']['theme'] = sanitize_text_field( $_POST['wpmem_captcha_theme'] ); } } if ( 'hcaptcha' == $update_type ) { - $new_settings = $settings; - $new_settings['hcaptcha']['api_key'] = sanitize_text_field( $_POST['wpmem_captcha_publickey'] ); - $new_settings['hcaptcha']['secret'] = sanitize_text_field( $_POST['wpmem_captcha_privatekey'] ); + $settings['hcaptcha']['api_key'] = sanitize_text_field( $_POST['wpmem_captcha_publickey'] ); + $settings['hcaptcha']['secret'] = sanitize_text_field( $_POST['wpmem_captcha_privatekey'] ); } if ( $update_type == 'really_simple' ) { - if ( array_key_exists( 'recaptcha', $settings ) ) { - // Updating really_simple but need to maintain recaptcha. - $new_settings['recaptcha'] = $settings['recaptcha']; - } $font_color = sanitize_text_field( $_POST['font_color_r'] ) . ',' . sanitize_text_field( $_POST['font_color_g'] ) . ',' . sanitize_text_field( $_POST['font_color_b'] ); $bg_color = sanitize_text_field( $_POST['bg_color_r'] ) . ',' . sanitize_text_field( $_POST['bg_color_g'] ) . ',' . sanitize_text_field( $_POST['bg_color_b'] ); - $new_settings['really_simple'] = array( + $settings['really_simple'] = array( 'characters' => sanitize_text_field( $_POST['characters'] ), 'num_char' => sanitize_text_field( $_POST['num_char'] ), 'dim_w' => sanitize_text_field( $_POST['dim_w'] ), @@ -322,7 +314,7 @@ public static function update() { ); } - update_option( 'wpmembers_captcha', $new_settings ); + update_option( 'wpmembers_captcha', $settings ); return __( 'CAPTCHA was updated for WP-Members', 'wp-members' ); } } \ No newline at end of file diff --git a/readme.txt b/readme.txt index 6613e397..f010dc02 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 5.5 -Stable tag: 3.3.5 +Stable tag: 3.3.6 License: GPLv2 == Description == @@ -14,15 +14,13 @@ The WP-Members membership plugin turns your WordPress site into a membership sit You need a membership site, but you want to focus on your business, not mastering a plugin. WP-Members is simple to use, easy to set up, yet flexible in every way imaginable. -The plugin restricts selected WordPress content to registered site members. WP-Members puts the registration process on the site front end so it is part of your content instead of the native WP login page. WP-Members requires no modifications to your theme while remaining scalable for users who want to customize the look and feel, or want to restrict only some content. It is a great tool for sites offering premium content to subscribers and is adaptable to a variety of applications. - __Simple to install and configure - yet customizable and scalable!__ = Features: = * Restrict or hide posts, pages, and custom post types +* Limit menu items to logged in users * User login, registration, and profile integrated into your theme -* Login widget * Create custom registration and profile fields * Notify admin of new user registrations * Hold new registrations for admin approval @@ -37,7 +35,7 @@ A full Users Guide is [available here](https://rocketgeek.com/plugins/wp-members = Support = -There is (freely available documentation on the plugin's support site)[https://rocketgeek.com/plugins/wp-members/docs/]. Your question may be answered there. If you need assistance configuring the plugin or have questions on how to implement or customize features, [premium support is available](https://rocketgeek.com/product/wp-members-plugin-support/). +There is [freely available documentation on the plugin's support site](https://rocketgeek.com/plugins/wp-members/docs/). Your question may be answered there. If you need assistance configuring the plugin or have questions on how to implement or customize features, [premium support is available](https://rocketgeek.com/product/wp-members-plugin-support/). You can get priority support along with all of the plugin's premium extensions in one [cost saving Pro Bundle!](https://rocketgeek.com/product/wp-members-pro-bundle/) @@ -109,7 +107,7 @@ The FAQs are maintained at https://rocketgeek.com/plugins/wp-members/docs/faqs/ == Upgrade Notice == -WP-Members 3.3.0 is a major update. WP-Members 3.3.5 is an improvement release. See changelog for important details. Minimum WP version is 4.0. +WP-Members 3.3.0 is a major update. WP-Members 3.3.6 is an improvement release. See changelog for important details. Minimum WP version is 4.0. == Screenshots == @@ -133,6 +131,10 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.5 is an improvement release. == Changelog == += 3.3.6 = + +* Improved admin tab for captcha settings. You can now change the captcha type from the captcha tab (previously, you could only do this from the main options tab). + = 3.3.5 = * Added optional new user validation link and password reset link (instead of sending password). This option will become the default setting in 3.4.0. From 6d46ee8258547fc381407a261f0af126bd2ebfe3 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 24 Aug 2020 08:36:57 -0400 Subject: [PATCH 1321/1694] fix bug causing no email when activated from profile --- includes/class-wp-members-user-profile.php | 2 +- includes/deprecated.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-user-profile.php b/includes/class-wp-members-user-profile.php index b78f974b..de2289a0 100644 --- a/includes/class-wp-members-user-profile.php +++ b/includes/class-wp-members-user-profile.php @@ -367,7 +367,7 @@ static function update( $user_id ) { $wpmem_activate_user = ( isset( $_POST['activate_user'] ) == '' ) ? -1 : filter_var( $_POST['activate_user'], FILTER_SANITIZE_NUMBER_INT ); if ( $wpmem_activate_user == 1 ) { - wpmem_activate_user( $user_id, $chk_pass ); + wpmem_activate_user( $user_id ); } elseif ( $wpmem_activate_user == 0 ) { wpmem_deactivate_user( $user_id ); } diff --git a/includes/deprecated.php b/includes/deprecated.php index b6117b6d..bf7cef76 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -207,7 +207,7 @@ function wpmem_check_activated( $user, $username, $password ) { */ function wpmem_a_activate_user( $user_id, $chk_pass = false ) { wpmem_write_log( "wpmem_a_activate_user() is deprecated as of WP-Members 3.2.4. Use wpmem_activate_user instead" ); - wpmem_activate_user( $user_id, $chk_pass ); + wpmem_activate_user( $user_id ); } /** From fc706241bcac8818a3e7fcc7cd70a273e69063a5 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 24 Aug 2020 08:38:22 -0400 Subject: [PATCH 1322/1694] fix undefined variables in expiration set --- includes/class-wp-members-products.php | 11 ++++++++--- includes/class-wp-members-user.php | 4 ++-- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/includes/class-wp-members-products.php b/includes/class-wp-members-products.php index 0e275b4d..9b34235e 100644 --- a/includes/class-wp-members-products.php +++ b/includes/class-wp-members-products.php @@ -417,8 +417,15 @@ function explode_fixed_period( $array ) { * Set an expiration date. * * @since 3.3.5 + * + * @param string $product + * @param int $user_id + * @param mixed $set_date + * @param mixed $pre_value + * @param boolean $renew + * @return mixed $new_value */ - function set_product_expiration( $product, $user_id, $set_date ) { + function set_product_expiration( $product, $user_id, $set_date, $prev_value, $renew ) { // If this is setting a specific date. if ( $set_date ) { $new_value = strtotime( $set_date ); @@ -427,9 +434,7 @@ function set_product_expiration( $product, $user_id, $set_date ) { $raw_add = explode( "|", $this->products[ $product ]['expires'][0] ); $add_period = ( 1 < $raw_add[0] ) ? $raw_add[0] . " " . $raw_add[1] . "s" : $raw_add[0] . " " . $raw_add[1]; - // New single meta version. if ( $prev_value ) { - $renew = true; if ( isset( $this->products[ $product ]['no_gap'] ) && 1 == $this->products[ $product ]['no_gap'] ) { // Add to the user's existing date (no gap). $new_value = strtotime( $add_period, $prev_value ); diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 43e93459..0f12daad 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -973,11 +973,11 @@ function set_user_product( $product, $user_id = false, $set_date = false ) { // Convert date to add. $expiration_period = ( isset( $wpmem->membership->products[ $product ]['expires'] ) ) ? $wpmem->membership->products[ $product ]['expires'] : false; - $renew = false; + $renew = ( $prev_value ) ? true : false; // If membership is an expiration product. if ( is_array( $expiration_period ) ) { - $new_value = $wpmem->membership->set_product_expiration( $product, $user_id, $set_date ); + $new_value = $wpmem->membership->set_product_expiration( $product, $user_id, $set_date, $prev_value, $renew ); } else { $new_value = true; } From 4cfa3942d587b59ea2dc67df566ebde70f454ddd Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 24 Aug 2020 08:38:50 -0400 Subject: [PATCH 1323/1694] only calculate product restricted message if access is false --- .../admin/class-wp-members-products-admin.php | 8 +- includes/class-wp-members-products.php | 113 +++++++++--------- 2 files changed, 61 insertions(+), 60 deletions(-) diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index f9708e13..8f3854f4 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -436,8 +436,12 @@ function save_details( $post_id ) { } $product_message = wpmem_get( 'product_message', false ); - if ( false !== $product_message && '' != $product_message ) { - update_post_meta( $post_id, 'wpmem_product_message', $product_message ); + if ( false !== $product_message ) { + if ( '' != $product_message ) { + update_post_meta( $post_id, 'wpmem_product_message', $product_message ); + } else { + delete_post_meta( $post_id, 'wpmem_product_message' ); + } } } diff --git a/includes/class-wp-members-products.php b/includes/class-wp-members-products.php index 9b34235e..da8c5b15 100644 --- a/includes/class-wp-members-products.php +++ b/includes/class-wp-members-products.php @@ -202,73 +202,70 @@ function product_access( $content ) { // Get the post access products. $post_products = $this->get_post_products( $post->ID ); // If the post is restricted to a product. - if ( $post_products ) { - if ( wpmem_user_has_access( $post_products ) ) { - $access = true; - } else { - // The error message for invalid users. - $access = false; - } + if ( is_array( $post_products ) && ! empty( $post_products ) ) { + $access = ( wpmem_user_has_access( $post_products ) ) ? true : false; } else { - // Content that has no product restriction. $access = true; } - // Handle default membership restricted message. - if ( 1 == count( $post_products ) ) { - $message = $wpmem->get_text( 'product_restricted_single' ) - . "
    " . $this->products[ $post_products[0] ]['title']; - } else { - $message = $wpmem->get_text( 'product_restricted_multiple' ) . "
    "; - foreach ( $post_products as $post_product ) { - $message .= $this->products[ $post_product ]['title'] . "
    "; + // Only produce the product restricted message if access is false. + if ( false === $access ) { + + // Singular message if post only has one membership, otherwise multiple. + if ( 1 == count( $post_products ) ) { + $message = $wpmem->get_text( 'product_restricted_single' ) + . "
    " . $this->products[ $post_products[0] ]['title']; + } else { + $message = $wpmem->get_text( 'product_restricted_multiple' ) . "
    "; + foreach ( $post_products as $post_product ) { + $message .= $this->products[ $post_product ]['title'] . "
    "; + } } - } - /** - * Filter the product restricted message. - * - * @since 3.2.3 - * - * @param string The message. - * @param array $post_products { - * Membership product slugs the post is restricted to. - * - * @type string $slug - * } - */ - $message = apply_filters( 'wpmem_product_restricted_msg', $message, $post_products ); - - /** - * Filter the product restricted message HTML. - * - * @since 3.3.3 - * @since 3.3.4 Added $post_products - * - * @param array $product_restricted { - * $type string $wrapper_before - * $type string $message - * $type string $wrapper_after - * } - * @param array $post_products { - * Membership product slugs the post is restricted to. - * - * @type string $slug - * } - */ - $product_restricted = apply_filters( 'wpmem_product_restricted_args', array( - 'wrapper_before' => '
    ', - 'message' => '

    ' . $message . '

    ', - 'wrapper_after' => '
    ', - ), $post_products ); - - $content = ( $access ) ? $content : $product_restricted['wrapper_before'] . $product_restricted['message'] . $product_restricted['wrapper_after']; + /** + * Filter the product restricted message. + * + * @since 3.2.3 + * + * @param string The message. + * @param array $post_products { + * Membership product slugs the post is restricted to. + * + * @type string $slug + * } + */ + $message = apply_filters( 'wpmem_product_restricted_msg', $message, $post_products ); + + /** + * Filter the product restricted message HTML. + * + * @since 3.3.3 + * @since 3.3.4 Added $post_products + * + * @param array $product_restricted { + * $type string $wrapper_before + * $type string $message + * $type string $wrapper_after + * } + * @param array $post_products { + * Membership product slugs the post is restricted to. + * + * @type string $slug + * } + */ + $product_restricted = apply_filters( 'wpmem_product_restricted_args', array( + 'wrapper_before' => '
    ', + 'message' => '

    ' . $message . '

    ', + 'wrapper_after' => '
    ', + ), $post_products ); + + $content = $product_restricted['wrapper_before'] . $product_restricted['message'] . $product_restricted['wrapper_after']; - // Handle comments. - if ( ! $access ) { + // Handle comments. add_filter( 'wpmem_securify_comments', '__return_false' ); } + } - // Return unfiltered content for all other cases. + return $content; } From 8ea6e16a8ed795f880c066de4fb61820db557e07 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 25 Aug 2020 13:04:02 -0400 Subject: [PATCH 1324/1694] remove pattern from number input type --- assets/js/admin.js | 1 - assets/js/admin.min.js | 2 +- includes/admin/tabs/class-wp-members-admin-tab-fields.php | 4 +++- includes/class-wp-members-forms.php | 2 +- readme.txt | 1 + 5 files changed, 6 insertions(+), 4 deletions(-) diff --git a/assets/js/admin.js b/assets/js/admin.js index b1d646c2..5f52366c 100644 --- a/assets/js/admin.js +++ b/assets/js/admin.js @@ -127,7 +127,6 @@ || $("#wpmem_field_type_select").val() == 'password' || $("#wpmem_field_type_select").val() == 'email' || $("#wpmem_field_type_select").val() == 'url' - || $("#wpmem_field_type_select").val() == 'number' || $("#wpmem_field_type_select").val() == 'date' ) { $("#wpmem_pattern").show(); $("#wpmem_title").show(); diff --git a/assets/js/admin.min.js b/assets/js/admin.min.js index b1dc1c7d..caa6a407 100644 --- a/assets/js/admin.min.js +++ b/assets/js/admin.min.js @@ -1 +1 @@ -jQuery(document).ready(function(e){e("#the-list").sortable({items:".list_item",opacity:.6,cursor:"move",axis:"y",update:function(){var m=e(this).sortable("serialize")+"&action=wpmem_do_field_reorder";e.post(ajaxurl,m,function(e){alert(e)}),e(".list_item").each(function(m){e(this).data("id",m+1),e(this).attr("list_item",m+1)})}})}),function(e){e(document).ready(function(){"use_custom"==e("#wpmem_logpage_select").val()?e("#wpmem_logpage_custom").show():e("#wpmem_logpage_custom").hide(),"use_custom"==e("#wpmem_regpage_select").val()?e("#wpmem_regpage_custom").show():e("#wpmem_regpage_custom").hide(),"use_custom"==e("#wpmem_mspage_select").val()?e("#wpmem_mspage_custom").show():e("#wpmem_mspage_custom").hide(),"use_custom"==e("#wpmem_stylesheet_select").val()?e("#wpmem_stylesheet_custom").show():e("#wpmem_stylesheet_custom").hide(),e("#wpmem_logpage_select").change(function(){"use_custom"==e("#wpmem_logpage_select").val()?e("#wpmem_logpage_custom").show():e("#wpmem_logpage_custom").hide()}),e("#wpmem_regpage_select").change(function(){"use_custom"==e("#wpmem_regpage_select").val()?e("#wpmem_regpage_custom").show():e("#wpmem_regpage_custom").hide()}),e("#wpmem_mspage_select").change(function(){"use_custom"==e("#wpmem_mspage_select").val()?e("#wpmem_mspage_custom").show():e("#wpmem_mspage_custom").hide()}),e("#wpmem_stylesheet_select").change(function(){"use_custom"==e("#wpmem_stylesheet_select").val()?e("#wpmem_stylesheet_custom").show():e("#wpmem_stylesheet_custom").hide()})})}(jQuery),function(e){e(document).ready(function(){e("#wpmem_allowhtml").hide(),e("#wpmem_rows_cols").hide(),e("#wpmem_min_max").hide(),e("#wpmem_checkbox_info").hide(),e("#wpmem_dropdown_info").hide(),e("#wpmem_file_info").hide(),e("#wpmem_delimiter_info").hide(),e("#wpmem_hidden_info").hide()}),e(document).ready(function(){e("#wpmem_field_type_select").change(function(){"text"==e("#wpmem_field_type_select").val()||"password"==e("#wpmem_field_type_select").val()||"email"==e("#wpmem_field_type_select").val()||"url"==e("#wpmem_field_type_select").val()||"number"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()||"textarea"==e("#wpmem_field_type_select").val()?e("#wpmem_placeholder").show():e("#wpmem_placeholder").hide(),"text"==e("#wpmem_field_type_select").val()||"password"==e("#wpmem_field_type_select").val()||"email"==e("#wpmem_field_type_select").val()||"url"==e("#wpmem_field_type_select").val()||"number"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()?(e("#wpmem_pattern").show(),e("#wpmem_title").show()):(e("#wpmem_pattern").hide(),e("#wpmem_title").hide()),"textarea"==e("#wpmem_field_type_select").val()?(e("#wpmem_allowhtml").show(),e("#wpmem_rows_cols").show()):(e("#wpmem_allowhtml").hide(),e("#wpmem_rows_cols").hide()),"number"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()?e("#wpmem_min_max").show():e("#wpmem_min_max").hide(),"checkbox"==e("#wpmem_field_type_select").val()?(e("#wpmem_checkbox_info").show(),e("#add_checked_value").prop("required",!0)):(e("#wpmem_checkbox_info").hide(),e("#add_checked_value").prop("required",!1)),"select"==e("#wpmem_field_type_select").val()||"multiselect"==e("#wpmem_field_type_select").val()||"radio"==e("#wpmem_field_type_select").val()||"multicheckbox"==e("#wpmem_field_type_select").val()?(e("#wpmem_dropdown_info").show(),e("#add_dropdown_value").prop("required",!0)):(e("#wpmem_dropdown_info").hide(),e("#add_dropdown_value").prop("required",!1)),"multiselect"==e("#wpmem_field_type_select").val()||"multicheckbox"==e("#wpmem_field_type_select").val()?e("#wpmem_delimiter_info").show():e("#wpmem_delimiter_info").hide(),"file"==e("#wpmem_field_type_select").val()||"image"==e("#wpmem_field_type_select").val()?e("#wpmem_file_info").show():e("#wpmem_file_info").hide(),"hidden"==e("#wpmem_field_type_select").val()?(e("#wpmem_hidden_info").show(),e("#add_hidden_value").prop("required",!0)):(e("#wpmem_hidden_info").hide(),e("#add_hidden_value").prop("required",!1))})})}(jQuery),function(e){e(document).ready(function(){e("#wpmem_block").hide()}),e(document).ready(function(){e("#wpmem_edit_block_status").click(function(){e("#wpmem_block").show("normal"),e("#wpmem_edit_block_status").hide()}),e("#wpmem_cancel_block_status").click(function(){e("#wpmem_block").hide("normal"),e("#wpmem_edit_block_status").show(),e("#wpmem_post_block_status").text(e("input[name=wpmem_block_original_label]").val()),e("#wpmem_post_block_status_"+e("input[name=wpmem_block_original_value]")).val().prop("checked",!0)}),e("#wpmem_ok_block_status").click(function(){e("#wpmem_block").hide("normal"),e("#wpmem_edit_block_status").show(),e("#wpmem_post_block_status").text(e("input[name=wpmem_block]:checked + label").text()),e("#wpmem_block_status_0").is(":checked")&&(e("#wpmem_post_icon_0").show(),e("#wpmem_post_icon_1").hide(),e("#wpmem_post_icon_2").hide()),e("#wpmem_block_status_1").is(":checked")&&(e("#wpmem_post_icon_0").hide(),e("#wpmem_post_icon_1").show(),e("#wpmem_post_icon_2").hide()),e("#wpmem_block_status_2").is(":checked")&&(e("#wpmem_post_icon_0").hide(),e("#wpmem_post_icon_1").hide(),e("#wpmem_post_icon_2").show())})})}(jQuery); \ No newline at end of file +jQuery(document).ready(function(e){e("#the-list").sortable({items:".list_item",opacity:.6,cursor:"move",axis:"y",update:function(){var m=e(this).sortable("serialize")+"&action=wpmem_do_field_reorder";e.post(ajaxurl,m,function(e){alert(e)}),e(".list_item").each(function(m){e(this).data("id",m+1),e(this).attr("list_item",m+1)})}})}),function(e){e(document).ready(function(){"use_custom"==e("#wpmem_logpage_select").val()?e("#wpmem_logpage_custom").show():e("#wpmem_logpage_custom").hide(),"use_custom"==e("#wpmem_regpage_select").val()?e("#wpmem_regpage_custom").show():e("#wpmem_regpage_custom").hide(),"use_custom"==e("#wpmem_mspage_select").val()?e("#wpmem_mspage_custom").show():e("#wpmem_mspage_custom").hide(),"use_custom"==e("#wpmem_stylesheet_select").val()?e("#wpmem_stylesheet_custom").show():e("#wpmem_stylesheet_custom").hide(),e("#wpmem_logpage_select").change(function(){"use_custom"==e("#wpmem_logpage_select").val()?e("#wpmem_logpage_custom").show():e("#wpmem_logpage_custom").hide()}),e("#wpmem_regpage_select").change(function(){"use_custom"==e("#wpmem_regpage_select").val()?e("#wpmem_regpage_custom").show():e("#wpmem_regpage_custom").hide()}),e("#wpmem_mspage_select").change(function(){"use_custom"==e("#wpmem_mspage_select").val()?e("#wpmem_mspage_custom").show():e("#wpmem_mspage_custom").hide()}),e("#wpmem_stylesheet_select").change(function(){"use_custom"==e("#wpmem_stylesheet_select").val()?e("#wpmem_stylesheet_custom").show():e("#wpmem_stylesheet_custom").hide()})})}(jQuery),function(e){e(document).ready(function(){e("#wpmem_allowhtml").hide(),e("#wpmem_rows_cols").hide(),e("#wpmem_min_max").hide(),e("#wpmem_checkbox_info").hide(),e("#wpmem_dropdown_info").hide(),e("#wpmem_file_info").hide(),e("#wpmem_delimiter_info").hide(),e("#wpmem_hidden_info").hide()}),e(document).ready(function(){e("#wpmem_field_type_select").change(function(){"text"==e("#wpmem_field_type_select").val()||"password"==e("#wpmem_field_type_select").val()||"email"==e("#wpmem_field_type_select").val()||"url"==e("#wpmem_field_type_select").val()||"number"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()||"textarea"==e("#wpmem_field_type_select").val()?e("#wpmem_placeholder").show():e("#wpmem_placeholder").hide(),"text"==e("#wpmem_field_type_select").val()||"password"==e("#wpmem_field_type_select").val()||"email"==e("#wpmem_field_type_select").val()||"url"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()?(e("#wpmem_pattern").show(),e("#wpmem_title").show()):(e("#wpmem_pattern").hide(),e("#wpmem_title").hide()),"textarea"==e("#wpmem_field_type_select").val()?(e("#wpmem_allowhtml").show(),e("#wpmem_rows_cols").show()):(e("#wpmem_allowhtml").hide(),e("#wpmem_rows_cols").hide()),"number"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()?e("#wpmem_min_max").show():e("#wpmem_min_max").hide(),"checkbox"==e("#wpmem_field_type_select").val()?(e("#wpmem_checkbox_info").show(),e("#add_checked_value").prop("required",!0)):(e("#wpmem_checkbox_info").hide(),e("#add_checked_value").prop("required",!1)),"select"==e("#wpmem_field_type_select").val()||"multiselect"==e("#wpmem_field_type_select").val()||"radio"==e("#wpmem_field_type_select").val()||"multicheckbox"==e("#wpmem_field_type_select").val()?(e("#wpmem_dropdown_info").show(),e("#add_dropdown_value").prop("required",!0)):(e("#wpmem_dropdown_info").hide(),e("#add_dropdown_value").prop("required",!1)),"multiselect"==e("#wpmem_field_type_select").val()||"multicheckbox"==e("#wpmem_field_type_select").val()?e("#wpmem_delimiter_info").show():e("#wpmem_delimiter_info").hide(),"file"==e("#wpmem_field_type_select").val()||"image"==e("#wpmem_field_type_select").val()?e("#wpmem_file_info").show():e("#wpmem_file_info").hide(),"hidden"==e("#wpmem_field_type_select").val()?(e("#wpmem_hidden_info").show(),e("#add_hidden_value").prop("required",!0)):(e("#wpmem_hidden_info").hide(),e("#add_hidden_value").prop("required",!1))})})}(jQuery),function(e){e(document).ready(function(){e("#wpmem_block").hide()}),e(document).ready(function(){e("#wpmem_edit_block_status").click(function(){e("#wpmem_block").show("normal"),e("#wpmem_edit_block_status").hide()}),e("#wpmem_cancel_block_status").click(function(){e("#wpmem_block").hide("normal"),e("#wpmem_edit_block_status").show(),e("#wpmem_post_block_status").text(e("input[name=wpmem_block_original_label]").val()),e("#wpmem_post_block_status_"+e("input[name=wpmem_block_original_value]")).val().prop("checked",!0)}),e("#wpmem_ok_block_status").click(function(){e("#wpmem_block").hide("normal"),e("#wpmem_edit_block_status").show(),e("#wpmem_post_block_status").text(e("input[name=wpmem_block]:checked + label").text()),e("#wpmem_block_status_0").is(":checked")&&(e("#wpmem_post_icon_0").show(),e("#wpmem_post_icon_1").hide(),e("#wpmem_post_icon_2").hide()),e("#wpmem_block_status_1").is(":checked")&&(e("#wpmem_post_icon_0").hide(),e("#wpmem_post_icon_1").show(),e("#wpmem_post_icon_2").hide()),e("#wpmem_block_status_2").is(":checked")&&(e("#wpmem_post_icon_0").hide(),e("#wpmem_post_icon_1").hide(),e("#wpmem_post_icon_2").show())})})}(jQuery); \ No newline at end of file diff --git a/includes/admin/tabs/class-wp-members-admin-tab-fields.php b/includes/admin/tabs/class-wp-members-admin-tab-fields.php index d30f2a02..34a05d9b 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-fields.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-fields.php @@ -243,13 +243,15 @@ public static function build_field_edit( $mode, $wpmem_fields, $meta_key ) { ' : ''; ?> - + ' : ''; ?>
  • ' : ''; ?> + + ' : ''; ?>
  • diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 33dfcecc..bb54ccf0 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -102,8 +102,8 @@ function create_form_field( $args ) { } $required = ( $required ) ? ' required' : ''; $placeholder = ( $placeholder ) ? ' placeholder="' . esc_attr( __( $placeholder, 'wp-members' ) ) . '"' : ''; - $pattern = ( $pattern ) ? ' pattern="' . esc_attr( $pattern ) . '"' : ''; $title = ( $title ) ? ' title="' . esc_attr( __( $title, 'wp-members' ) ) . '"' : ''; + $pattern = ( $pattern && 'number' != $type ) ? ' pattern="' . esc_attr( $pattern ) . '"' : ''; $min = ( isset( $args['min'] ) && $args['min'] != '' ) ? ' min="' . esc_attr( $args['min'] ) . '"' : ''; $max = ( isset( $args['max'] ) && $args['max'] != '' ) ? ' max="' . esc_attr( $args['max'] ). '"' : ''; $str = ""; diff --git a/readme.txt b/readme.txt index f010dc02..ca3df399 100644 --- a/readme.txt +++ b/readme.txt @@ -134,6 +134,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.6 is an improvement release. = 3.3.6 = * Improved admin tab for captcha settings. You can now change the captcha type from the captcha tab (previously, you could only do this from the main options tab). +* Removed "pattern" attribute from number field type. HTML5 does not support this attribute for this input type. = 3.3.5 = From 8912e82759a168d95d745e83e217a74763975113 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 5 Sep 2020 22:38:03 -0400 Subject: [PATCH 1325/1694] fix issues with custom fields in admin/user dashboard --- includes/api/api-forms.php | 2 +- includes/class-wp-members-user-profile.php | 24 ++++++++++++++++++++-- includes/class-wp-members-user.php | 4 ++-- includes/class-wp-members.php | 16 ++------------- readme.txt | 1 + 5 files changed, 28 insertions(+), 19 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 8003fdc5..4e1d2465 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -161,7 +161,7 @@ function wpmem_forgot_username_form() { * @global stdClass $wpmem * @param string $process */ -function wpmem_wp_register_form( $process = 'wp' ) { +function wpmem_wp_register_form( $process = 'register_wp' ) { global $wpmem; $wpmem->forms->wp_register_form( $process ); } diff --git a/includes/class-wp-members-user-profile.php b/includes/class-wp-members-user-profile.php index de2289a0..6baaf99f 100644 --- a/includes/class-wp-members-user-profile.php +++ b/includes/class-wp-members-user-profile.php @@ -14,6 +14,26 @@ class WP_Members_User_Profile { + /** + * Remove "admin only" fields if dashboard user profile. + * + * @since 3.3.6 + * + * @param string $tag + * @return array $fields + */ + static function wpmem_fields( $tag ) { + $fields = wpmem_fields( $tag ); + if ( 'profile_dashboard' == $tag && false === current_user_can( 'edit_users' ) ) { + foreach( $fields as $key => $field ) { + if ( false == $field['profile'] ) { + unset( $fields[ $key ] ); + } + } + } + return $fields; + } + /** * Static function to display WP-Members fields on the admin/dashboard user profile. * @@ -52,7 +72,7 @@ static function profile( $user_obj ) {
  • -

    -

    ', '' ); ?>.

    -

    -

    - ", '' ); ?>.
    - :  
    - -
    captcha ) { + $wpmem->captcha = 3; // reCAPTCHA v1 is fully obsolete. Change it to v2. + } + $captcha[] = __( 'reCAPTCHA v2', 'wp-members' ) . '|3'; + $captcha[] = __( 'reCAPTCHA v3', 'wp-members' ) . '|4'; + $captcha[] = __( 'Really Simple CAPTCHA', 'wp-members' ) . '|2'; + $captcha[] = __( 'hCaptcha', 'wp-members' ) . '|5'; + echo wpmem_create_formfield( 'wpmem_settings_captcha', 'select', $captcha, $wpmem->captcha ); ?> +
    - + +
    +

    - ", '' ); ?>.
    +

    ", '' ); + } ?>



    +

    ", '' ); + } ?>



    $field ) { + foreach ( wpmem_fields( 'register_wp' ) as $meta_key => $field ) { $is_error = false; if ( $field['required'] && $meta_key != 'user_email' && ! in_array( $meta_key, $exclude ) ) { if ( ( $field['type'] == 'checkbox' || $field['type'] == 'multicheckbox' || $field['type'] == 'multiselect' || $field['type'] == 'radio' ) && ( ! isset( $_POST[ $meta_key ] ) ) ) { @@ -456,7 +456,7 @@ function register_finalize( $user_id ) { if ( $this->reg_type['is_native'] || $this->reg_type['is_add_new'] || $this->reg_type['is_woo'] ) { // Get any excluded meta fields. $exclude = wpmem_get_excluded_meta( 'wp-register' ); - foreach ( wpmem_fields( 'wp_finalize' ) as $meta_key => $field ) { + foreach ( wpmem_fields( 'register_wp' ) as $meta_key => $field ) { $value = wpmem_get( $meta_key, false ); if ( false !== $value && ! in_array( $meta_key, $exclude ) && 'file' != $field['type'] && 'image' != $field['type'] ) { if ( 'multiselect' == $field['type'] || 'multicheckbox' == $field['type'] ) { diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 2f30afbf..16d01304 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -571,7 +571,7 @@ function load_dropins() { * @since 3.3.0 Deprecated all but exp and trl constants. */ function load_constants() { - ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $this->mod_reg ) : ''; + ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $this->mod_reg ) : ''; ( ! defined( 'WPMEM_USE_EXP' ) ) ? define( 'WPMEM_USE_EXP', $this->use_exp ) : ''; ( ! defined( 'WPMEM_USE_TRL' ) ) ? define( 'WPMEM_USE_TRL', $this->use_trial ) : ''; } @@ -1960,6 +1960,7 @@ function do_excerpt( $content ) { * * @since 3.1.7 * @since 3.2.3 Moved to WP_Members class. + * @since 3.3.0 Removed unnecessary tags. * * @param string $tag * @return string $tag @@ -1973,19 +1974,6 @@ function convert_tag( $tag ) { case 'update': return 'profile'; break; - case 'wp': - case 'wp_validate': - case 'wp_finalize': - return 'register_wp'; - break; - case 'dashboard_profile': - case 'dashboard_profile_update': - return 'profile_dashboard'; - break; - case 'admin_profile': - case 'admin_profile_update': - return 'profile_admin'; - break; default: return $tag; break; diff --git a/readme.txt b/readme.txt index ca3df399..238edf8f 100644 --- a/readme.txt +++ b/readme.txt @@ -135,6 +135,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.6 is an improvement release. * Improved admin tab for captcha settings. You can now change the captcha type from the captcha tab (previously, you could only do this from the main options tab). * Removed "pattern" attribute from number field type. HTML5 does not support this attribute for this input type. +* Fix issues with custom fields in admin/user dashboard profile. This involved a change to how fields were loaded for both display and validation (so that now it is a singular process). = 3.3.5 = From 35b3102e35abd63f838b44d2d3bca857caa9eec4 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 5 Sep 2020 22:39:29 -0400 Subject: [PATCH 1326/1694] fix undefined has_access() call when renewing a membership --- includes/class-wp-members-products.php | 2 +- readme.txt | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-products.php b/includes/class-wp-members-products.php index da8c5b15..8f1e6d2d 100644 --- a/includes/class-wp-members-products.php +++ b/includes/class-wp-members-products.php @@ -437,7 +437,7 @@ function set_product_expiration( $product, $user_id, $set_date, $prev_value, $re $new_value = strtotime( $add_period, $prev_value ); } else { // Add to the user either from end or now (whichever is later; i.e. allow gaps (default)). - if ( $this->has_access( $product, $user_id ) ) { + if ( wpmem_user_has_access( $product, $user_id ) ) { // if not expired, set from when they expire. $new_value = strtotime( $add_period, $prev_value ); } else { diff --git a/readme.txt b/readme.txt index 238edf8f..6f75231f 100644 --- a/readme.txt +++ b/readme.txt @@ -136,6 +136,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.6 is an improvement release. * Improved admin tab for captcha settings. You can now change the captcha type from the captcha tab (previously, you could only do this from the main options tab). * Removed "pattern" attribute from number field type. HTML5 does not support this attribute for this input type. * Fix issues with custom fields in admin/user dashboard profile. This involved a change to how fields were loaded for both display and validation (so that now it is a singular process). +* Fix undefined has_access() (replaced with API function) when renewing a membership. = 3.3.5 = From c969a7e5fd3986fa53fe5a8df75545f47dec44d9 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 5 Sep 2020 22:40:03 -0400 Subject: [PATCH 1327/1694] update form fields function call to api --- includes/class-wp-members-user-profile.php | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-user-profile.php b/includes/class-wp-members-user-profile.php index 6baaf99f..9760801d 100644 --- a/includes/class-wp-members-user-profile.php +++ b/includes/class-wp-members-user-profile.php @@ -151,12 +151,28 @@ static function profile( $user_obj ) { ) ); } else { if ( 'select' == $field['type'] || 'radio' == $field['type'] ) { - $input = wpmem_create_formfield( $meta, $field['type'], $values, $valtochk ); + $input = wpmem_form_field( $meta, $field['type'], $values, $valtochk ); } elseif( 'multicheckbox' == $field['type'] || 'multiselect' == $field['type'] ) { - $input = $wpmem->forms->create_form_field( array( 'name'=>$meta, 'type'=>$field['type'], 'value'=>$values, 'compare'=>$valtochk, 'delimiter'=>$field['delimiter'] ) ); + $input = wpmem_form_field( array( 'name'=>$meta, 'type'=>$field['type'], 'value'=>$values, 'compare'=>$valtochk, 'delimiter'=>$field['delimiter'] ) ); } else { $field['type'] = ( 'hidden' == $field['type'] ) ? 'text' : $field['type']; - $input = wpmem_create_formfield( $meta, $field['type'], $val, $valtochk ); + + $formfield_args = array( + 'name' => $meta, + 'type' => $field['type'], + 'value' => $val, + 'compare' => $valtochk, + 'required' => $field['required'], + 'placeholder' => ( isset( $field['placeholder'] ) ) ? $field['placeholder'] : '', + 'pattern' => ( isset( $field['pattern'] ) ) ? $field['pattern'] : false, + 'title' => ( isset( $field['title'] ) ) ? $field['title'] : false, + 'min' => ( isset( $field['min'] ) ) ? $field['min'] : false, + 'max' => ( isset( $field['max'] ) ) ? $field['max'] : false, + 'rows' => ( isset( $field['rows'] ) ) ? $field['rows'] : false, + 'cols' => ( isset( $field['cols'] ) ) ? $field['cols'] : false, + ); + + $input = wpmem_form_field( $formfield_args ); } } From df1fc81fc00aca0b1789fc33a9d9cb6d997a8853 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 5 Sep 2020 22:42:30 -0400 Subject: [PATCH 1328/1694] cleanup --- includes/class-wp-members-user-profile.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-user-profile.php b/includes/class-wp-members-user-profile.php index 9760801d..353f978b 100644 --- a/includes/class-wp-members-user-profile.php +++ b/includes/class-wp-members-user-profile.php @@ -22,7 +22,7 @@ class WP_Members_User_Profile { * @param string $tag * @return array $fields */ - static function wpmem_fields( $tag ) { + static function get_fields( $tag ) { $fields = wpmem_fields( $tag ); if ( 'profile_dashboard' == $tag && false === current_user_can( 'edit_users' ) ) { foreach( $fields as $key => $field ) { @@ -72,7 +72,7 @@ static function profile( $user_obj ) {
    Date: Sat, 5 Sep 2020 22:43:31 -0400 Subject: [PATCH 1329/1694] working on 3.3.6 --- wp-members.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-members.php b/wp-members.php index d06fdd15..c6173a34 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.3.5 +Version: 3.3.6 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -64,7 +64,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.3.5' ); +define( 'WPMEM_VERSION', '3.3.6' ); define( 'WPMEM_DB_VERSION', '2.2.0' ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 087e2b72fd099d956e121f9114cc0ae0cd1ad925 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 6 Sep 2020 12:52:41 -0400 Subject: [PATCH 1330/1694] woocommerce registration fixes --- includes/api/api-forms.php | 16 +++++++++--- includes/class-wp-members-forms.php | 39 +++++++++++++++++------------ includes/class-wp-members.php | 1 + readme.txt | 1 + 4 files changed, 38 insertions(+), 19 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 4e1d2465..048a59ad 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -386,7 +386,7 @@ function wpmem_woo_checkout_fields( $checkout_fields = false ) { 'account_username', 'account_password', ); - $fields = wpmem_fields();// echo '
    '; print_r( $fields ); echo '
    '; + $fields = wpmem_fields(); if ( ! $checkout_fields ) { $checkout_fields = WC()->checkout()->checkout_fields; @@ -410,6 +410,11 @@ function wpmem_woo_checkout_fields( $checkout_fields = false ) { unset( $fields[ $meta_key ] ); } } + + // @todo For now, remove any unsupported field types. + if ( 'hidden' == $field['type'] || 'image' == $field['type'] || 'file' == $field['type'] || 'membership' == $field['type'] ) { + unset( $fields[ $meta_key ] ); + } } unset( $fields['username'] ); unset( $fields['password'] ); @@ -433,15 +438,18 @@ function wpmem_woo_checkout_form( $checkout_fields ) { global $wpmem; $fields = wpmem_woo_checkout_fields( $checkout_fields ); + $priority = 10; foreach ( $fields as $meta_key => $field ) { $checkout_fields['order'][ $meta_key ] = array( 'type' => $fields[ $meta_key ]['type'], 'label' => ( 'tos' == $meta_key ) ? $wpmem->forms->get_tos_link( $field, 'woo' ) : $fields[ $meta_key ]['label'], - 'required' => $fields[ $meta_key ]['required'], + 'required' => $fields[ $meta_key ]['required'], + 'priority' => $priority, ); if ( isset( $fields[ $meta_key ]['placeholder'] ) ) { $checkout_fields['order'][ $meta_key ]['placeholder'] = $fields[ $meta_key ]['placeholder']; } + $priority = $priority + 10; } return $checkout_fields; } @@ -534,12 +542,14 @@ function wpmem_form_field_wc_custom_field_types( $field, $key, $args, $value ) { function wpmem_woo_reg_validate( $username, $email, $errors ) { - $fields = wpmem_fields(); + $fields = wpmem_woo_checkout_fields(); unset( $fields['username'] ); unset( $fields['password'] ); unset( $fields['confirm_password'] ); unset( $fields['user_email'] ); + unset( $fields['first_name'] ); + unset( $fields['last_name'] ); foreach ( $fields as $key => $field_args ) { if ( 1 == $field_args['required'] && empty( $_POST[ $key ] ) ) { diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index bb54ccf0..3d24aefd 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1609,33 +1609,31 @@ function wp_register_form( $process = 'wp' ) { switch ( $field['type'] ) { - case( 'select' ): - $val = ( isset( $_POST[ $meta_key ] ) ) ? sanitize_text_field( $_POST[ $meta_key ] ) : ''; - $input = wpmem_create_formfield( $meta_key, $field['type'], $field['values'], $val ); - break; - case( 'textarea' ): $input = ''; break; + case( 'select' ): case( 'multiselect' ): case( 'multicheckbox' ): - case( 'radio' ): - $row_before = '

    '; + case( 'radio' ): + case( 'membership' ): + $row_before = ( $is_woo && ( 'select' == $field['type'] || 'multiselect' == $field['type'] || 'membership' == $field['type'] ) ) ? $row_before : '

    '; $valtochk = ( isset( $_POST[ $meta_key ] ) ) ? sanitize_text_field( $_POST[ $meta_key ] ) : ''; $formfield_args = array( 'name' => $meta_key, 'type' => $field['type'], 'value' => $field['values'], 'compare' => $valtochk, - 'required' => ( $field['required'] ) ? true : false, + 'required' => $field['required'], + 'class' => ( $is_woo && ( 'select' == $field['type'] || 'multiselect' == $field['type'] || 'membership' == $field['type'] ) ) ? 'woocommerce-Input woocommerce-Input--text input-text' : $field['type'], ); if ( 'multicheckbox' == $field['type'] || 'multiselect' == $field['type'] ) { $formfield_args['delimiter'] = $field['delimiter']; } - $input = $this->create_form_field( $formfield_args ); + $input = wpmem_form_field( $formfield_args ); break; case( 'file' ): @@ -1646,13 +1644,22 @@ function wp_register_form( $process = 'wp' ) { default: $class = ( $is_woo ) ? 'woocommerce-Input woocommerce-Input--text input-text' : 'input'; //$input = ''; break; diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 16d01304..ca6946d8 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -476,6 +476,7 @@ function load_hooks() { add_action( 'woocommerce_form_field_multicheckbox', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); add_action( 'woocommerce_form_field_multiselect', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); add_action( 'woocommerce_form_field_radio', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); + add_action( 'woocommerce_form_field_select', 'wpmem_form_field_wc_custom_field_types', 10, 4 ); if ( ! is_user_logged_in() ) { add_filter( 'woocommerce_checkout_fields', 'wpmem_woo_checkout_form' ); } diff --git a/readme.txt b/readme.txt index 6f75231f..0c73a1cb 100644 --- a/readme.txt +++ b/readme.txt @@ -137,6 +137,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.6 is an improvement release. * Removed "pattern" attribute from number field type. HTML5 does not support this attribute for this input type. * Fix issues with custom fields in admin/user dashboard profile. This involved a change to how fields were loaded for both display and validation (so that now it is a singular process). * Fix undefined has_access() (replaced with API function) when renewing a membership. +* Fix issues with WooCommerce registration integration. = 3.3.5 = From 510b94bfff43b8a12c6b131bfe61d2e944753a9c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 6 Sep 2020 17:44:09 -0400 Subject: [PATCH 1331/1694] fix undefined array keys if rs_captcha is enabled but not installed --- includes/class-wp-members-captcha.php | 2 +- includes/class-wp-members-forms.php | 2 +- readme.txt | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-captcha.php b/includes/class-wp-members-captcha.php index addd0dda..2a299d6e 100644 --- a/includes/class-wp-members-captcha.php +++ b/includes/class-wp-members-captcha.php @@ -236,7 +236,7 @@ static function rs_captcha( $return = 'string' ) { return apply_filters( 'wpmem_captcha', $html ); } } else { - return ( 'array' == $return ) ? array( 'label' => '', 'label_text' => '', 'field' => "Really Simple CAPTCHA is not enabled" ) : "Really Simple CAPTCHA is not enabled"; + return ( 'array' == $return ) ? array( 'field' => "Really Simple CAPTCHA is not enabled", 'label' => '', 'label_text' => '', 'img' => '', 'hidden' => '' ) : "Really Simple CAPTCHA is not enabled"; } } diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 3d24aefd..92d4aaf7 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1129,7 +1129,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { } // If captcha is Really Simple CAPTCHA. - if ( $wpmem->captcha == 2 && $tag != 'edit' ) { + if ( 2 == $wpmem->captcha && 'edit' != $tag ) { // Build the captcha. $row = WP_Members_Captcha::rs_captcha( 'array' ); $rows['captcha'] = array( diff --git a/readme.txt b/readme.txt index 0c73a1cb..2e7db9b1 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 5.5 -Stable tag: 3.3.6 +Stable tag: 3.3.5.2 License: GPLv2 == Description == @@ -138,6 +138,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.6 is an improvement release. * Fix issues with custom fields in admin/user dashboard profile. This involved a change to how fields were loaded for both display and validation (so that now it is a singular process). * Fix undefined has_access() (replaced with API function) when renewing a membership. * Fix issues with WooCommerce registration integration. +* Fix issue of undefined array keys if Really Simple Captcha is selected, but the plugin is not enabled. = 3.3.5 = From 02ff283246f51e88da27c6758566d8d22d5526a9 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 6 Sep 2020 23:22:57 -0400 Subject: [PATCH 1332/1694] setup default file types for upload if none specified --- includes/api/api-users.php | 2 +- includes/class-wp-members-user.php | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index fba374af..1d3b5f0f 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -529,7 +529,7 @@ function wpmem_set_user_status( $user_id, $status ) { function wpmem_user_register( $tag ) { // Get the globals. - global $user_ID, $wpmem, $wpmem_themsg, $userdata; + global $user_ID, $wpmem, $wpmem_themsg, $userdata; $wpmem->user->register_validate( $tag ); diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index e844f0da..1e8aef23 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -299,6 +299,9 @@ function register_validate( $tag ) { // Validate file field type. if ( 'file' == $field['type'] || 'image' == $field['type'] ) { + if ( '' == $field['file_types'] ) { + $field['file_types'] = ( 'image' == $field['type'] ) ? 'gif|png|jpg|jpeg|bmp' : 'doc|docx|pdf|zip'; + } $allowed_file_types = explode( '|', $field['file_types'] ); $msg_types = implode( ', ', $allowed_file_types ); if ( ! empty( $_FILES[ $meta_key ]['name'] ) ) { @@ -401,7 +404,9 @@ function wp_register_validate( $errors, $sanitized_user_login, $user_email ) { if ( ( $field['type'] != 'checkbox' && $field['type'] != 'multicheckbox' && $field['type'] != 'multiselect' && $field['type'] != 'radio' ) && ( ! $_POST[ $meta_key ] ) ) { $is_error = true; } - if ( $is_error ) { $errors->add( 'wpmem_error', sprintf( $wpmem->get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ) ); } + if ( $is_error ) { + $errors->add( 'wpmem_error', sprintf( $wpmem->get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ) ); + } } } From d0125a36b6345fa6a8f4b4dd3f89842de2b62bea Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 6 Sep 2020 23:23:20 -0400 Subject: [PATCH 1333/1694] add membership field type so it repopulates in error state --- includes/class-wp-members-forms.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 92d4aaf7..56ac4d87 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1032,7 +1032,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { } // For dropdown select. - if ( $field['type'] == 'select' || $field['type'] == 'radio' || $field['type'] == 'multiselect' || $field['type'] == 'multicheckbox' ) { + if ( 'select' == $field['type'] || 'radio' == $field['type'] || 'multiselect' == $field['type'] || 'multicheckbox' == $field['type'] || 'membership' == $field['type'] ) { $valtochk = $val; $val = $field['values']; } From ab1a86e4cc91082b2db8d47394c90a825c5fac45 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 7 Sep 2020 10:36:50 -0400 Subject: [PATCH 1334/1694] fix compatibility with buddypress when mod_reg is used and users are created manually --- includes/admin/class-wp-members-admin-api.php | 1 - includes/admin/class-wp-members-admin-users.php | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/admin/class-wp-members-admin-api.php b/includes/admin/class-wp-members-admin-api.php index 09f7c5ba..d02bf0f4 100644 --- a/includes/admin/class-wp-members-admin-api.php +++ b/includes/admin/class-wp-members-admin-api.php @@ -145,7 +145,6 @@ function load_hooks() { add_filter( 'views_users', array( 'WP_Members_Admin_Users', 'views' ) ); add_filter( 'manage_users_columns', array( 'WP_Members_Admin_Users', 'add_user_column' ) ); add_filter( 'manage_users_custom_column', array( 'WP_Members_Admin_Users', 'add_user_column_content' ), 10, 3 ); - add_action( 'wpmem_post_register_data', array( 'WP_Members_Admin_Users', 'set_new_user_non_active' ) ); add_action( 'wpmem_user_activated', array( 'WP_Members_Admin_Users', 'set_activated_user' ) ); add_action( 'wpmem_user_deactivated', array( 'WP_Members_Admin_Users', 'set_deactivated_user' ) ); add_filter( 'user_row_actions', array( 'WP_Members_Admin_Users', 'insert_activate_link' ), 10, 2 ); diff --git a/includes/admin/class-wp-members-admin-users.php b/includes/admin/class-wp-members-admin-users.php index 5a039958..4fbd3d14 100644 --- a/includes/admin/class-wp-members-admin-users.php +++ b/includes/admin/class-wp-members-admin-users.php @@ -481,6 +481,8 @@ static function pre_user_query( $user_search ) { * Use wpmem_post_register_data to set the user_status field to 2 using wp_update_user. * http://codex.wordpress.org/Function_Reference/wp_update_user * + * @deprecated 3.3.6 No longer used. + * * @uses wpmem_set_user_status * @param $fields */ From 6b74a51461e8e3488c5befe607ef032e023c4796 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 7 Sep 2020 10:37:09 -0400 Subject: [PATCH 1335/1694] fix cli causing error when viewing content settings --- includes/cli/class-wp-members-cli-settings.php | 2 +- readme.txt | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/includes/cli/class-wp-members-cli-settings.php b/includes/cli/class-wp-members-cli-settings.php index 36223f9a..f9a481bf 100644 --- a/includes/cli/class-wp-members-cli-settings.php +++ b/includes/cli/class-wp-members-cli-settings.php @@ -68,7 +68,7 @@ private function list_settings( $args, $assoc_args ) { 'Setting' => $setting . ' ' . $post_type, 'Description' => $description . ' ' . $post_type, 'Value' => $wpmem->{$setting}[ $post_type ], - 'Option' => ( 0 == $value ) ? 'Disabled' : 'Enabled', + 'Option' => ( 0 == $wpmem->{$setting}[ $post_type ] ) ? 'Disabled' : 'Enabled', ); } else { $list[] = array( diff --git a/readme.txt b/readme.txt index 2e7db9b1..46cf777e 100644 --- a/readme.txt +++ b/readme.txt @@ -139,6 +139,8 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.6 is an improvement release. * Fix undefined has_access() (replaced with API function) when renewing a membership. * Fix issues with WooCommerce registration integration. * Fix issue of undefined array keys if Really Simple Captcha is selected, but the plugin is not enabled. +* Fix issue that caused users to not be properly set when moderated registration is used along with BuddyPress and users are created manually. +* Fix issue in WP CLI wpmem settings command that caused error to be displayed when viewing content settings. = 3.3.5 = From df54a34110471a9d7714a4b6369dd2b461b13fed Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 7 Sep 2020 10:39:20 -0400 Subject: [PATCH 1336/1694] add some notes --- includes/api/api-forms.php | 1 + includes/class-wp-members-forms.php | 1 + 2 files changed, 2 insertions(+) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 048a59ad..a1bed486 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -67,6 +67,7 @@ function wpmem_login_form( $args, $arr = false ) { $args = $arr; $args['page'] = $page; } + // @todo Work on making this $wpmem->forms->do_login_form( $args ); return $wpmem->forms->login_form( $args ); } endif; diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 56ac4d87..c5019708 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1437,6 +1437,7 @@ function strip_breaks( $form, $rows ) { * @since 1.8 * @since 3.1.4 Global $wpmem_regchk no longer needed. * @since 3.2.0 Moved to forms class, renamed do_login_form(). + * @todo $show is deprecated, post restricted message ($msg) handled externally. * * @global object $post The WordPress Post object. * @global object $wpmem The WP_Members object. From a425227db1188d4a1f87f99f9e9257929a909fab Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 7 Sep 2020 15:47:03 -0400 Subject: [PATCH 1337/1694] only validate field if it is included in registration --- includes/class-wp-members-user.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 1e8aef23..a6a4fc6d 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -397,7 +397,7 @@ function wp_register_validate( $errors, $sanitized_user_login, $user_email ) { foreach ( wpmem_fields( 'register_wp' ) as $meta_key => $field ) { $is_error = false; - if ( $field['required'] && $meta_key != 'user_email' && ! in_array( $meta_key, $exclude ) ) { + if ( true == $field['required'] && true == $field['register'] && $meta_key != 'user_email' && ! in_array( $meta_key, $exclude ) ) { if ( ( $field['type'] == 'checkbox' || $field['type'] == 'multicheckbox' || $field['type'] == 'multiselect' || $field['type'] == 'radio' ) && ( ! isset( $_POST[ $meta_key ] ) ) ) { $is_error = true; } From b012e35d6a5c8092912151aff5946f5c8e04bd70 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 7 Sep 2020 17:05:45 -0400 Subject: [PATCH 1338/1694] captcha settings keys may possibly be not set --- includes/admin/tabs/class-wp-members-admin-tab-captcha.php | 2 +- readme.txt | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php index 11775eed..3f866186 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php @@ -132,7 +132,7 @@ public static function build_settings() {

    + + + + admin->emails ) ) { foreach( $wpmem->admin->emails as $email ) { @@ -126,11 +130,13 @@ static function update() { check_admin_referer( 'wpmem-update-emails' ); // Update the email address (if applicable). - if ( $wpmem->email->from != $_POST['wp_mail_from'] || $wpmem->email->from_name != $_POST['wp_mail_from_name'] ) { + if ( $wpmem->email->from != $_POST['wp_mail_from'] || $wpmem->email->from_name != $_POST['wp_mail_from_name'] || $wpmem->email->html != wpmem_get( 'wpmem_email_html', 0 ) ) { $wpmem->email->from = sanitize_email( $_POST['wp_mail_from'] ); $wpmem->email->from_name = sanitize_text_field( $_POST['wp_mail_from_name'] ); + $wpmem->email->html = intval( wpmem_get( 'wpmem_email_html', 0 ) ); update_option( 'wpmembers_email_wpfrom', $wpmem->email->from ); update_option( 'wpmembers_email_wpname', $wpmem->email->from_name ); + update_option( 'wpmembers_email_html', $wpmem->email->html ); } // Update the various emails being used. diff --git a/includes/class-wp-members-email.php b/includes/class-wp-members-email.php index b4259ba0..cc17a46f 100644 --- a/includes/class-wp-members-email.php +++ b/includes/class-wp-members-email.php @@ -50,6 +50,15 @@ class WP_Members_Email { */ public $settings; + /** + * Setting for HTML email. + * + * @since 3.4.0 + * @access public + * @var string + */ + public $html = 0; + /** * Load custom from address. * @@ -58,6 +67,7 @@ class WP_Members_Email { function load_from() { $this->from = get_option( 'wpmembers_email_wpfrom', '' ); $this->from_name = get_option( 'wpmembers_email_wpname', '' ); + $this->html = get_option( 'wpmembers_email_html', 0 ); } /** @@ -528,6 +538,17 @@ function from_name( $name ) { global $wpmem; return ( $this->from_name ) ? stripslashes( $this->from_name ) : stripslashes( $name ); } + + /** + * Returns HTML content type for email. + * + * @since 3.4.0 + * + * @return string Always returns "text/html" + */ + function html_content_type() { + return 'text/html'; + } /** * Sends email. @@ -556,6 +577,9 @@ function send( $to ) { // Apply WP's "from" and "from name" email filters. add_filter( 'wp_mail_from', array( $this, 'from' ) ); add_filter( 'wp_mail_from_name', array( $this, 'from_name' ) ); + if ( 1 == $this->html ) { + add_filter( 'wp_mail_content_type', array( $this, 'html_content_type' ) ); + } $result = wp_mail( $args['to'], stripslashes( $args['subject'] ), stripslashes( $args['message'] ), $args['headers'] ); return $result; } From 2a1ad37349137cfa8228f2ce993956e8fed88cd1 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 21:36:01 -0400 Subject: [PATCH 1423/1694] major improvements to export function, can now rely primarily on wpmem_export_fields to filter --- includes/admin/class-wp-members-export.php | 86 +++++++++++++++------- 1 file changed, 60 insertions(+), 26 deletions(-) diff --git a/includes/admin/class-wp-members-export.php b/includes/admin/class-wp-members-export.php index 8cf2f0ac..58b7982c 100644 --- a/includes/admin/class-wp-members-export.php +++ b/includes/admin/class-wp-members-export.php @@ -21,24 +21,30 @@ class WP_Members_Export { * @since 3.2.0 Updated to use fputcsv. * @since 3.2.1 Added user data filters. * @since 3.3.0 Moved to new object class as static method. + * @since 3.4.0 Added $tag to identify what export process is being run. * * @param array $args * @param array $users */ - static function export_users( $args, $users = array() ) { + static function export_users( $args, $users = array(), $tag = 'default' ) { global $wpmem; $wpmem_fields = wpmem_fields(); + // Fields to exclude. + $exclude_fields = array( 'user_pass', 'password', 'confirm_password', 'confirm_email' ); + // Prepare fields, add additional "special" fields. $export_fields = array( - 'ID' => __( 'User ID', 'wp-members' ), - 'username' => __( 'Username', 'wp-members' ), + 'ID' => __( 'User ID', 'wp-members' ), ); foreach( $wpmem_fields as $meta_key => $value ) { - $export_fields[ $meta_key ] = $value['label']; + if ( ! in_array( $meta_key, $exclude_fields ) ) { + $export_fields[ $meta_key ] = $value['label']; + } } + $export_fields['username'] = __( 'Username', 'wp-members' ); if ( 1 == $wpmem->mod_reg ) { $export_fields['active'] = __( 'Activated?', 'wp-members' ); } @@ -48,6 +54,7 @@ static function export_users( $args, $users = array() ) { } $export_fields['user_registered'] = __( 'Registered', 'wp-members' ); $export_fields['wpmem_reg_ip'] = __( 'IP', 'wp-members' ); + $export_fields['role'] = __( 'Role', 'wp-members' ); if ( 1 == $wpmem->enable_products ) { foreach( $wpmem->membership->products as $product_key => $product ) { $export_fields[ $wpmem->membership->post_stem . $product_key ] = $wpmem->membership->products[ $product_key ]['title']; @@ -58,9 +65,10 @@ static function export_users( $args, $users = array() ) { * Filter the export fields. * * @since 3.2.5 + * @since 3.4.0 Added $tag. * * @param array $export_fields { - * The array of export fields is keyed as 'heading value' => 'meta_key'. + * The array of export fields is keyed as 'meta_key' => 'heading value'. * The array will include all fields in the Fields tab, plus the following: * * @type int $ID ID from wp_users @@ -73,9 +81,11 @@ static function export_users( $args, $users = array() ) { * @type string $expires If the PayPal extension is installed MM/DD/YYYY (optional) * @type string $user_registered user_registered * @type string $user_ip The IP of the user when they registered. - } + * @type string $role The user's role (or roles, if multiple). + * } + * @param string $tag */ - $export_fields = apply_filters( 'wpmem_export_fields', $export_fields ); + $export_fields = apply_filters( 'wpmem_export_fields', $export_fields, $tag ); $today = date( "Y-m-d" ); @@ -84,7 +94,6 @@ static function export_users( $args, $users = array() ) { 'export' => 'all', 'filename' => 'wp-members-user-export-' . $today . '.csv', 'export_fields' => $export_fields, - 'exclude_fields' => array( 'password', 'confirm_password', 'confirm_email' ), 'entity_decode' => false, 'date_format' => 'Y-m-d', ); @@ -93,6 +102,9 @@ static function export_users( $args, $users = array() ) { * Filter the default export arguments. * * @since 2.9.7 + * @since 3.4.0 Filter all defaults (like other _args changes), then wp_parse_args() in case any are missing. + * @since 3.4.0 Added $tag. + * @since 3.4.0 Deprecated 'exclude_fields' (unset using wpmem_export_fields instead). * * @param array $args { * Array of defaults for export. @@ -100,12 +112,16 @@ static function export_users( $args, $users = array() ) { * @type string $export * @type string $filename * @type array $export_fields - * @type array $exclude_fields + * @type array $exclude_fields @deprecated 3.4.0 * @type boolean $entity_decode * @type string $date_format * } + * @param string $tag */ - $args = wp_parse_args( apply_filters( 'wpmem_export_args', $args ), $defaults ); + $args = apply_filters( 'wpmem_export_args', $defaults, $tag ); + + // Merge args with default (in case any were missing). + $args = wp_parse_args( $args, $defaults ); // Output needs to be buffered, start the buffer. ob_start(); @@ -124,22 +140,23 @@ static function export_users( $args, $users = array() ) { // Remove excluded fields from $export_fields while setting up $header array. $header = array(); - foreach ( $export_fields as $meta => $field ) { - if ( in_array( $meta, $args['exclude_fields'] ) ) { - unset( $export_fields[ $meta ] ); - } else { - $header[ $meta ] = $field; - } + foreach ( $args['export_fields'] as $meta => $field ) { + $header[ $meta ] = $field; } /** * Filters user export header row before assembly. * + * As of 3.4.0, this really isn't a necessary filter. You can specify the header + * value in wpmem_export_fields instead and just use one filter. + * * @since 3.2.1 + * @since 3.4.0 Added $tag. * - * @param array $header The header column values + * @param array $header The header column values + * @param string $tag */ - $header = apply_filters( 'wpmem_user_export_header', $header ); + $header = apply_filters( 'wpmem_user_export_header', $header, $tag ); fputcsv( $handle, $header ); @@ -149,15 +166,27 @@ static function export_users( $args, $users = array() ) { $user_info = get_userdata( $user ); - $wp_user_fields = [ 'username', 'user_email', 'user_nicename', 'user_url', 'display_name' ]; - foreach ( $export_fields as $meta => $field ) { + $wp_user_fields = array( 'ID', 'user_login', 'user_pass', 'user_nicename', 'user_email', 'user_url', 'user_registered', 'user_activation_key', 'user_status', 'display_name' ); + foreach ( $args['export_fields'] as $meta => $field ) { switch ( $meta ) { case 'ID': - $row[ $meta ] = $user_info->ID; + case 'user_login': + case 'user_pass': + case 'user_nicename': + case 'user_email': + case 'user_url': + case 'user_registered': + case 'user_activation_key': + case 'user_status': + case 'display_name': + $row[ $meta ] = $user_info->{ $meta }; break; case 'username': $row[ $meta ] = $user_info->user_login; break; + case 'password': + $row[ $meta ] = $user_info->user_pass; + break; case 'active': $row[ $meta ] = get_user_meta( $user, 'active', 1 ) ? __( 'Yes' ) : __( 'No' ); break; @@ -167,12 +196,13 @@ static function export_users( $args, $users = array() ) { case 'expires': $row['expires'] = get_user_meta( $user, 'expires', true ); break; - case 'user_registered': - $row['user_registered'] = $user_info->user_registered; - break; case 'wpmem_reg_ip': $row['wpmem_reg_ip'] = get_user_meta( $user, 'wpmem_reg_ip', true ); break; + case 'role': + $role = wpmem_get_user_role( $user, true ); // As of 3.4, wpmem_get_user_role() can get all roles. + $row['role'] = ( is_array( $role ) ) ? implode( ",", $role ) : $role; + break; case ( $wpmem->membership->post_stem === substr( $meta, 0, strlen( $wpmem->membership->post_stem ) ) ): $product = str_replace( $wpmem->membership->post_stem, '', $meta ); $row[ $meta ] = get_user_meta( $user, $meta, true ); @@ -197,10 +227,14 @@ static function export_users( $args, $users = array() ) { * Filter the user data before assembly. * * @since 3.2.1 + * @since 3.4.0 Added user ID (it may not be included in the $row array if the field were filtered out). + * @since 3.4.0 Added $tag. * - * @param array $row The user data row + * @param array $row The user data row. + * @param int $user_id The user ID. + * @param string $tag */ - $row = apply_filters( 'wpmem_user_export_row', $row ); + $row = apply_filters( 'wpmem_user_export_row', $row, $user_info->ID, $tag ); fputcsv( $handle, $row ); From 74f55967ccdda6e63b5b03053efecd3d1be5086a Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 22:34:08 -0400 Subject: [PATCH 1424/1694] added new dialogs object class --- includes/class-wp-members-dialogs.php | 330 ++++++++++++++++++++++++++ includes/class-wp-members.php | 2 + 2 files changed, 332 insertions(+) create mode 100644 includes/class-wp-members-dialogs.php diff --git a/includes/class-wp-members-dialogs.php b/includes/class-wp-members-dialogs.php new file mode 100644 index 00000000..e6bfa40d --- /dev/null +++ b/includes/class-wp-members-dialogs.php @@ -0,0 +1,330 @@ + __( 'First Name', 'wp-members' ), + 'last_name' => __( 'Last Name', 'wp-members' ), + 'addr1' => __( 'Address 1', 'wp-members' ), + 'addr2' => __( 'Address 2', 'wp-members' ), + 'city' => __( 'City', 'wp-members' ), + 'thestate' => __( 'State', 'wp-members' ), + 'zip' => __( 'Zip', 'wp-members' ), + 'country' => __( 'Country', 'wp-members' ), + 'phone1' => __( 'Day Phone', 'wp-members' ), + 'user_email' => __( 'Email', 'wp-members' ), + 'confirm_email' => __( 'Confirm Email', 'wp-members' ), + 'user_url' => __( 'Website', 'wp-members' ), + 'description' => __( 'Biographical Info', 'wp-members' ), + 'password' => __( 'Password', 'wp-members' ), + 'confirm_password' => __( 'Confirm Password', 'wp-members' ), + 'tos' => __( 'TOS', 'wp-members' ), + ); + + /* + * Strings to be added or removed in future versions, included so they will + * be in the translation template. + * @todo Check whether any of these should be removed. + */ + $benign_strings = array( + __( 'No fields selected for deletion', 'wp-members' ), + __( 'You are not logged in.', 'wp-members' ), // Technically removed 3.5 + ); + + $defaults = array( + + // Login form. + 'login_heading' => __( 'Existing Users Log In', 'wp-members' ), + 'login_username' => __( 'Username or Email', 'wp-members' ), + 'login_password' => __( 'Password', 'wp-members' ), + 'login_button' => __( 'Log In', 'wp-members' ), + 'remember_me' => __( 'Remember Me', 'wp-members' ), + 'forgot_link_before' => __( 'Forgot password?', 'wp-members' ) . ' ', + 'forgot_link' => __( 'Click here to reset', 'wp-members' ), + 'register_link_before' => __( 'New User?', 'wp-members' ) . ' ', + 'register_link' => __( 'Click here to register', 'wp-members' ), + + // Password change form. + 'pwdchg_heading' => __( 'Change Password', 'wp-members' ), + 'pwdchg_password1' => __( 'New password', 'wp-members' ), + 'pwdchg_password2' => __( 'Confirm new password', 'wp-members' ), + 'pwdchg_button' => __( 'Update Password', 'wp-members' ), + + // Password reset form. + 'pwdreset_heading' => __( 'Reset Forgotten Password', 'wp-members' ), + 'pwdreset_username' => __( 'Username', 'wp-members' ), + 'pwdreset_email' => __( 'Email', 'wp-members' ), + 'pwdreset_button' => __( 'Reset Password' ), + 'username_link_before' => __( 'Forgot username?', 'wp-members' ) . ' ', + 'username_link' => __( 'Click here', 'wp-members' ), + + // Retrieve username form. + 'username_heading' => __( 'Retrieve username', 'wp-members' ), + 'username_email' => __( 'Email Address', 'wp-members' ), + 'username_button' => __( 'Retrieve username', 'wp-members' ), + + // Register form. + 'register_heading' => __( 'New User Registration', 'wp-members' ), + 'register_username' => __( 'Choose a Username', 'wp-members' ), + 'register_rscaptcha' => __( 'Input the code:', 'wp-members' ), + 'register_tos' => __( 'Please indicate that you agree to the %s Terms of Service %s', 'wp-members' ), // @note: if default changes, default check after wpmem_tos_link_txt must change. + 'register_clear' => __( 'Reset Form', 'wp-members' ), + 'register_submit' => __( 'Register', 'wp-members' ), + 'register_req_mark' => '*', + 'register_required' => '*' . __( 'Required field', 'wp-members' ), + + // User profile update form. + 'profile_heading' => __( 'Edit Your Information', 'wp-members' ), + 'profile_username' => __( 'Username', 'wp-members' ), + 'profile_submit' => __( 'Update Profile', 'wp-members' ), + 'profile_upload' => __( 'Update this file', 'wp-members' ), + + // Error messages and dialogs. + 'login_failed_heading' => __( 'Login Failed!', 'wp-members' ), + 'login_failed' => __( 'You entered an invalid username or password.', 'wp-members' ), + 'login_failed_link' => __( 'Click here to continue.', 'wp-members' ), + 'pwdchangempty' => __( 'Password fields cannot be empty', 'wp-members' ), + 'usernamefailed' => __( 'Sorry, that email address was not found.', 'wp-members' ), + 'usernamesuccess' => __( 'An email was sent to %s with your username.', 'wp-members' ), + 'reg_empty_field' => __( 'Sorry, %s is a required field.', 'wp-members' ), + 'reg_valid_email' => __( 'You must enter a valid email address.', 'wp-members' ), + 'reg_non_alphanumeric' => __( 'The username cannot include non-alphanumeric characters.', 'wp-members' ), + 'reg_empty_username' => __( 'Sorry, username is a required field', 'wp-members' ), + 'reg_password_match' => __( 'Passwords did not match.', 'wp-members' ), + 'reg_email_match' => __( 'Emails did not match.', 'wp-members' ), + 'reg_empty_captcha' => __( 'You must complete the CAPTCHA form.', 'wp-members' ), + 'reg_invalid_captcha' => __( 'CAPTCHA was not valid.', 'wp-members' ), + 'reg_generic' => __( 'There was an error processing the form.', 'wp-members' ), + 'reg_captcha_err' => __( 'There was an error with the CAPTCHA form.', 'wp-members' ), + 'reg_file_type' => __( 'Sorry, you can only upload the following file types for the %s field: %s.', 'wp-members' ), + + // Links. + 'profile_edit' => __( 'Edit My Information', 'wp-members' ), + 'profile_password' => __( 'Change Password', 'wp-members' ), + 'register_status' => __( 'You are logged in as %s', 'wp-members' ), + 'register_logout' => __( 'Log out', 'wp-members' ), + 'register_continue' => ( isset( $wpmem->user_pages['profile'] ) && '' != $wpmem->user_pages['profile'] ) ? __( 'Edit profile', 'wp-members' ) : __( 'Begin using the site.', 'wp-members' ), + 'login_welcome' => __( 'You are logged in as %s', 'wp-members' ), + 'login_logout' => __( 'Click to log out', 'wp-members' ), + 'status_welcome' => __( 'You are logged in as %s', 'wp-members' ), + 'status_logout' => __( 'click to log out', 'wp-members' ), + 'menu_logout' => __( 'Log Out', 'wp-members' ), + + // Widget. + 'sb_status' => __( 'You are logged in as %s', 'wp-members' ), + 'sb_logout' => __( 'click here to log out', 'wp-members' ), + 'sb_login_failed' => __( 'Login Failed!
    You entered an invalid username or password.', 'wp-members' ), + 'sb_not_logged_in' => '', + 'sb_login_username' => __( 'Username or Email', 'wp-members' ), + 'sb_login_password' => __( 'Password', 'wp-members' ), + 'sb_login_button' => __( 'log in', 'wp-members' ), + 'sb_login_forgot' => __( 'Forgot?', 'wp-members' ), + 'sb_login_register' => __( 'Register', 'wp-members' ), + + // Default Dialogs. + 'restricted_msg' => __( "This content is restricted to site members. If you are an existing user, please log in. New users may register below.", 'wp-members' ), + 'success' => __( "Congratulations! Your registration was successful.

    You may now log in using the password that was emailed to you.", 'wp-members' ), + + // @todo Under consideration for removal from the Dialogs tab. + 'user' => __( "Sorry, that username is taken, please try another.", 'wp-members' ), + 'email' => __( "Sorry, that email address already has an account.
    Please try another.", 'wp-members' ), + 'editsuccess' => __( "Your information was updated!", 'wp-members' ), + + // @todo These are defaults and are under consideration for removal from the dialogs tab, possibly as we change the password reset to a link based process. + 'pwdchangerr' => __( "Passwords did not match.

    Please try again.", 'wp-members' ), + 'pwdchangesuccess' => __( "Password successfully changed!", 'wp-members' ), + 'pwdreseterr' => __( "Either the username or email address do not exist in our records.", 'wp-members' ), + 'pwdresetsuccess' => __( "Password successfully reset!

    An email containing a new password has been sent to the email address on file for your account.", 'wp-members' ), + + 'product_restricted_single' => __( "This content requires the following membership: ", 'wp-members' ), + 'product_restricted_multiple' => __( "This content requires one of the following memberships: ", 'wp-members' ), + + ); // End of $defaults array. + + /** + * Filter default terms. + * + * @since 3.1.0 + * @deprecated 3.2.7 Use wpmem_default_text instead. + */ + $text = apply_filters( 'wpmem_default_text_strings', '' ); + + // Merge filtered $terms with $defaults. + $text = wp_parse_args( $text, $defaults ); + + /** + * Filter the default terms. + * + * Replaces 'wpmem_default_text_strings' so that multiple filters could + * be run. This allows for custom filters when also running the Text + * String Editor extension. + * + * @since 3.2.7 + */ + $text = apply_filters( 'wpmem_default_text', $text ); + + // Return the requested text string. + return $text[ $str ]; + } + + function login_failed() { + + // Defaults. + $defaults = array( + 'div_before' => '
    ', + 'div_after' => '
    ', + 'heading_before' => '

    ', + 'heading' => $this->get_text( 'login_failed_heading' ), + 'heading_after' => '

    ', + 'p_before' => '

    ', + 'message' => $this->get_text( 'login_failed' ), // @todo $this->error + 'p_after' => '

    ', + 'link' => '' . $this->get_text( 'login_failed_link' ) . '', + ); + + /** + * Filter the login failed dialog arguments. + * + * @since 2.9.0 + * @since 3.3.3 Should pass defaults to filter. + * + * @param array An array of arguments to merge with defaults. + */ + $args = apply_filters( 'wpmem_login_failed_args', $defaults ); + + // Merge $args with defaults. + $args = wp_parse_args( $args, $defaults ); + + $str = $args['div_before'] + . $args['heading_before'] . $args['heading'] . $args['heading_after'] + . $args['p_before'] . $args['message'] . $args['p_after'] + . $args['p_before'] . $args['link'] . $args['p_after'] + . $args['div_after']; + + /** + * Filter the login failed dialog. + * + * @since 2.7.3 + * + * @param string $str The login failed dialog. + */ + $str = apply_filters( 'wpmem_login_failed', $str ); + + return $str; + } + + function message( $tag, $custom ) { + + // defaults + $defaults = array( + 'div_before' => '
    ', + 'div_after' => '
    ', + 'p_before' => '

    ', + 'p_after' => '

    ', + 'tags' => array( + 'user', + 'email', + 'success', + 'editsuccess', + 'pwdchangerr', + 'pwdchangesuccess', + 'pwdreseterr', + 'pwdresetsuccess', + ), + ); + + /** + * Filter the message arguments. + * + * @since 2.9.0 + * @deprecated 3.3.0 Use wpmem_msg_defaults instead. + * + * @param array An array of arguments to merge with defaults. + */ + $args = apply_filters( 'wpmem_msg_args', '' ); + + /** This filter is documented in /includes/class-wp-members-admin-api.php */ + $dialogs = apply_filters( 'wpmem_dialogs', get_option( 'wpmembers_dialogs' ) ); + + // @todo Temporary(?) workaround for custom dialogs as an array (WP-Members Security). + if ( array_key_exists( $tag, $dialogs ) ) { + if ( is_array( $dialogs[ $tag ] ) ) { + $msg = stripslashes( $dialogs[ $tag ]['value'] ); + } else { + $msg = $this->get_text( $tag ); + $msg = ( $dialogs[ $tag ] == $msg ) ? $msg : __( stripslashes( $dialogs[ $tag ] ), 'wp-members' ); + } + } + $defaults['msg'] = $msg; + + /** + * Filter the message array + * + * @since 2.9.2 + * @since 3.1.1 added $dialogs parameter. + * @deprecated 3.3.0 Use wpmem_msg_defaults instead. + * + * @param array $defaults An array of the defaults. + * @param string $tag The tag that we are on, if any. + * @param array $dialogs + */ + $defaults = apply_filters( 'wpmem_msg_dialog_arr', $defaults, $tag, $dialogs ); + + // Merge $args with defaults. + $args = wp_parse_args( $args, $defaults ); + + // Backwards compatibility for 'toggles'. + if ( isset( $args['toggles'] ) ) { + $args['tags'] = $args['toggles']; + } + + /** + * Filter the message settings. + * + * @since 3.3.0 + * + * @param array $defaults An array of the defaults. + * @param string $tag The tag that we are on, if any. + * @param array $dialogs + */ + $args = apply_filters( 'wpmem_msg_defaults', $defaults, $tag, $dialogs ); + + // @todo Temporary(?) workaround for custom dialogs as an array (WP-Members Security). + $display_msg = ( is_array( $args['msg'] ) ) ? $args['msg']['value'] : $args['msg']; + + $str = $args['div_before'] . $args['p_before'] . stripslashes( $display_msg ) . $args['p_after'] . $args['div_after']; + + /** + * Filter the message. + * + * @since 2.7.4 + * @since 3.1.0 Added tag. + * + * @param string $str The message. + * @param string $tag The tag of the message being displayed. + */ + return apply_filters( 'wpmem_msg_dialog', $str, $tag ); + } +} \ No newline at end of file diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index a5ed05f0..141efd65 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -395,6 +395,7 @@ function __construct() { $this->email = new WP_Members_Email; // Load email functions $this->user = new WP_Members_User( $this ); // Load user functions. $this->menus = new WP_Members_Menus(); + $this->dialogs = new WP_Members_Dialogs(); if ( $this->clone_menus ) { $this->menus_clone = new WP_Members_Clone_Menus(); // Load clone menus. } @@ -622,6 +623,7 @@ function load_dependencies() { require_once( $this->path . 'includes/class-wp-members-api.php' ); require_once( $this->path . 'includes/class-wp-members-clone-menus.php' ); require_once( $this->path . 'includes/class-wp-members-captcha.php' ); + require_once( $this->path . 'includes/class-wp-members-dialogs.php' ); require_once( $this->path . 'includes/class-wp-members-email.php' ); require_once( $this->path . 'includes/class-wp-members-forms.php' ); require_once( $this->path . 'includes/class-wp-members-menus.php' ); From 6cd31d8b4d643fe7a3e1e5f0e87b568375f868b5 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 22:36:50 -0400 Subject: [PATCH 1425/1694] replace get_text() in main class with new methoed in dialogs class --- includes/class-wp-members.php | 168 +--------------------------------- 1 file changed, 1 insertion(+), 167 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 141efd65..f2f3971a 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -1375,174 +1375,8 @@ function set_style() { * @return string $text */ function get_text( $str ) { - global $wpmem; - - // Default Form Fields. - $default_form_fields = array( - 'first_name' => __( 'First Name', 'wp-members' ), - 'last_name' => __( 'Last Name', 'wp-members' ), - 'addr1' => __( 'Address 1', 'wp-members' ), - 'addr2' => __( 'Address 2', 'wp-members' ), - 'city' => __( 'City', 'wp-members' ), - 'thestate' => __( 'State', 'wp-members' ), - 'zip' => __( 'Zip', 'wp-members' ), - 'country' => __( 'Country', 'wp-members' ), - 'phone1' => __( 'Day Phone', 'wp-members' ), - 'user_email' => __( 'Email', 'wp-members' ), - 'confirm_email' => __( 'Confirm Email', 'wp-members' ), - 'user_url' => __( 'Website', 'wp-members' ), - 'description' => __( 'Biographical Info', 'wp-members' ), - 'password' => __( 'Password', 'wp-members' ), - 'confirm_password' => __( 'Confirm Password', 'wp-members' ), - 'tos' => __( 'TOS', 'wp-members' ), - ); - - /* - * Strings to be added or removed in future versions, included so they will - * be in the translation template. - * @todo Check whether any of these should be removed. - */ - $benign_strings = array( - __( 'No fields selected for deletion', 'wp-members' ), - __( 'You are not logged in.', 'wp-members' ), // Technically removed 3.5 - ); - - $defaults = array( - - // Login form. - 'login_heading' => __( 'Existing Users Log In', 'wp-members' ), - 'login_username' => __( 'Username or Email', 'wp-members' ), - 'login_password' => __( 'Password', 'wp-members' ), - 'login_button' => __( 'Log In', 'wp-members' ), - 'remember_me' => __( 'Remember Me', 'wp-members' ), - 'forgot_link_before' => __( 'Forgot password?', 'wp-members' ) . ' ', - 'forgot_link' => __( 'Click here to reset', 'wp-members' ), - 'register_link_before' => __( 'New User?', 'wp-members' ) . ' ', - 'register_link' => __( 'Click here to register', 'wp-members' ), - - // Password change form. - 'pwdchg_heading' => __( 'Change Password', 'wp-members' ), - 'pwdchg_password1' => __( 'New password', 'wp-members' ), - 'pwdchg_password2' => __( 'Confirm new password', 'wp-members' ), - 'pwdchg_button' => __( 'Update Password', 'wp-members' ), - - // Password reset form. - 'pwdreset_heading' => __( 'Reset Forgotten Password', 'wp-members' ), - 'pwdreset_username' => __( 'Username', 'wp-members' ), - 'pwdreset_email' => __( 'Email', 'wp-members' ), - 'pwdreset_button' => __( 'Reset Password' ), - 'username_link_before' => __( 'Forgot username?', 'wp-members' ) . ' ', - 'username_link' => __( 'Click here', 'wp-members' ), - - // Retrieve username form. - 'username_heading' => __( 'Retrieve username', 'wp-members' ), - 'username_email' => __( 'Email Address', 'wp-members' ), - 'username_button' => __( 'Retrieve username', 'wp-members' ), - - // Register form. - 'register_heading' => __( 'New User Registration', 'wp-members' ), - 'register_username' => __( 'Choose a Username', 'wp-members' ), - 'register_rscaptcha' => __( 'Input the code:', 'wp-members' ), - 'register_tos' => __( 'Please indicate that you agree to the %s Terms of Service %s', 'wp-members' ), // @note: if default changes, default check after wpmem_tos_link_txt must change. - 'register_clear' => __( 'Reset Form', 'wp-members' ), - 'register_submit' => __( 'Register', 'wp-members' ), - 'register_req_mark' => '*', - 'register_required' => '*' . __( 'Required field', 'wp-members' ), - - // User profile update form. - 'profile_heading' => __( 'Edit Your Information', 'wp-members' ), - 'profile_username' => __( 'Username', 'wp-members' ), - 'profile_submit' => __( 'Update Profile', 'wp-members' ), - 'profile_upload' => __( 'Update this file', 'wp-members' ), - - // Error messages and dialogs. - 'login_failed_heading' => __( 'Login Failed!', 'wp-members' ), - 'login_failed' => __( 'You entered an invalid username or password.', 'wp-members' ), - 'login_failed_link' => __( 'Click here to continue.', 'wp-members' ), - 'pwdchangempty' => __( 'Password fields cannot be empty', 'wp-members' ), - 'usernamefailed' => __( 'Sorry, that email address was not found.', 'wp-members' ), - 'usernamesuccess' => __( 'An email was sent to %s with your username.', 'wp-members' ), - 'reg_empty_field' => __( 'Sorry, %s is a required field.', 'wp-members' ), - 'reg_valid_email' => __( 'You must enter a valid email address.', 'wp-members' ), - 'reg_non_alphanumeric' => __( 'The username cannot include non-alphanumeric characters.', 'wp-members' ), - 'reg_empty_username' => __( 'Sorry, username is a required field', 'wp-members' ), - 'reg_password_match' => __( 'Passwords did not match.', 'wp-members' ), - 'reg_email_match' => __( 'Emails did not match.', 'wp-members' ), - 'reg_empty_captcha' => __( 'You must complete the CAPTCHA form.', 'wp-members' ), - 'reg_invalid_captcha' => __( 'CAPTCHA was not valid.', 'wp-members' ), - 'reg_generic' => __( 'There was an error processing the form.', 'wp-members' ), - 'reg_captcha_err' => __( 'There was an error with the CAPTCHA form.', 'wp-members' ), - 'reg_file_type' => __( 'Sorry, you can only upload the following file types for the %s field: %s.', 'wp-members' ), - - // Links. - 'profile_edit' => __( 'Edit My Information', 'wp-members' ), - 'profile_password' => __( 'Change Password', 'wp-members' ), - 'register_status' => __( 'You are logged in as %s', 'wp-members' ), - 'register_logout' => __( 'Log out', 'wp-members' ), - 'register_continue' => ( isset( $wpmem->user_pages['profile'] ) && '' != $wpmem->user_pages['profile'] ) ? __( 'Edit profile', 'wp-members' ) : __( 'Begin using the site.', 'wp-members' ), - 'login_welcome' => __( 'You are logged in as %s', 'wp-members' ), - 'login_logout' => __( 'Click to log out', 'wp-members' ), - 'status_welcome' => __( 'You are logged in as %s', 'wp-members' ), - 'status_logout' => __( 'click to log out', 'wp-members' ), - 'menu_logout' => __( 'Log Out', 'wp-members' ), - - // Widget. - 'sb_status' => __( 'You are logged in as %s', 'wp-members' ), - 'sb_logout' => __( 'click here to log out', 'wp-members' ), - 'sb_login_failed' => __( 'Login Failed!
    You entered an invalid username or password.', 'wp-members' ), - 'sb_not_logged_in' => '', - 'sb_login_username' => __( 'Username or Email', 'wp-members' ), - 'sb_login_password' => __( 'Password', 'wp-members' ), - 'sb_login_button' => __( 'log in', 'wp-members' ), - 'sb_login_forgot' => __( 'Forgot?', 'wp-members' ), - 'sb_login_register' => __( 'Register', 'wp-members' ), - - // Default Dialogs. - 'restricted_msg' => __( "This content is restricted to site members. If you are an existing user, please log in. New users may register below.", 'wp-members' ), - 'success' => __( "Congratulations! Your registration was successful.

    You may now log in using the password that was emailed to you.", 'wp-members' ), - - // @todo Under consideration for removal from the Dialogs tab. - 'user' => __( "Sorry, that username is taken, please try another.", 'wp-members' ), - 'email' => __( "Sorry, that email address already has an account.
    Please try another.", 'wp-members' ), - 'editsuccess' => __( "Your information was updated!", 'wp-members' ), - - // @todo These are defaults and are under consideration for removal from the dialogs tab, possibly as we change the password reset to a link based process. - 'pwdchangerr' => __( "Passwords did not match.

    Please try again.", 'wp-members' ), - 'pwdchangesuccess' => __( "Password successfully changed!", 'wp-members' ), - 'pwdreseterr' => __( "Either the username or email address do not exist in our records.", 'wp-members' ), - 'pwdresetsuccess' => __( "Password successfully reset!

    An email containing a new password has been sent to the email address on file for your account.", 'wp-members' ), - - 'product_restricted_single' => __( "This content requires the following membership: ", 'wp-members' ), - 'product_restricted_multiple' => __( "This content requires one of the following memberships: ", 'wp-members' ), - - ); // End of $defaults array. - - /** - * Filter default terms. - * - * @since 3.1.0 - * @deprecated 3.2.7 Use wpmem_default_text instead. - */ - $text = apply_filters( 'wpmem_default_text_strings', '' ); - - // Merge filtered $terms with $defaults. - $text = wp_parse_args( $text, $defaults ); - - /** - * Filter the default terms. - * - * Replaces 'wpmem_default_text_strings' so that multiple filters could - * be run. This allows for custom filters when also running the Text - * String Editor extension. - * - * @since 3.2.7 - */ - $text = apply_filters( 'wpmem_default_text', $text ); - - // Return the requested text string. - return $text[ $str ]; - + return $wpmem->dialogs->get_text( $str ); } // End of get_text(). /** From 40434928ac9d4d0777989de2276778f4a2b10457 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 22:37:43 -0400 Subject: [PATCH 1426/1694] add wpmem_display_message() function, using dialogs->message() --- includes/api/api.php | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/includes/api/api.php b/includes/api/api.php index f21a0b04..cfa69125 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -351,14 +351,22 @@ function wpmem_logout_link() { * Dispalays requested dialog. * * @since 3.2.0 + * @since 3.4.0 Added $custom argument * - * @todo Needs testing and finalization before release. + * @todo What about wpmem_use_custom_dialog()? + * + * @global stdClass $wpmem + * @param string $tag + * @param boolean $echo + * @param string $custom + * @return */ -function wpmem_display_message( $tag, $echo = true ) { +function wpmem_display_message( $tag, $echo = false, $custom = false ) { + global $wpmem; if ( $echo ) { - echo wpmem_inc_regmessage( $tag ); + echo $wpmem->dialogs->message( $tag, $custom ); } else { - return wpmem_inc_regmessage( $tag ); + return $wpmem->dialogs->message( $tag, $custom ); } } From a8939c18d1c034173b779bbe5b5e86cca0372785 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 09:43:25 -0400 Subject: [PATCH 1427/1694] extracted processing for wpmem_login_status() from wpmem_inc_memberlinks() --- includes/api/api.php | 57 +++++++++++++++++++++++++++++++++++++------- 1 file changed, 49 insertions(+), 8 deletions(-) diff --git a/includes/api/api.php b/includes/api/api.php index cfa69125..9ce4a253 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -241,17 +241,58 @@ function wpmem_use_custom_dialog( $defaults, $tag, $dialogs ) { * @since 2.0.0 * @since 3.1.2 Moved to api.php, no longer pluggable. * @since 3.1.6 Dependencies now loaded by object. + * @since 3.4.0 Added $tag for id'ing useage, to be passed through filter. * - * @param boolean $echo Determines whether function should print result or not (default: true). - * @return string $status The user status string produced by wpmem_inc_memberlinks(). + * @global string $user_login + * @param boolean $echo Determines whether function should print result or not (default: true). + * @return string $status The user status string produced by wpmem_inc_memberlinks(). */ -function wpmem_login_status( $echo = true ) { +function wpmem_login_status( $echo = true, $tag = false ) { + if ( is_user_logged_in() ) { + + global $user_login; + + $args = array( + 'wrapper_before' => '

    ', + 'wrapper_after' => '

    ', + 'user_login' => $user_login, + 'welcome' => wpmem_gettext( 'status_welcome' ), + 'logout_text' => wpmem_gettext( 'status_logout' ), + 'logout_link' => '%s', + 'separator' => ' | ', + ); + /** + * Filter the status message parts. + * + * @since 2.9.9 + * @since 3.4.0 Added $tag as a parameter (most often will be false). + * + * @param array $args { + * The components of the links. + * + * @type string $wrapper_before The wrapper opening tag (default:

    ). + * @type string $wrapper_after The wrapper closing tag (default:

    ). + * @type string $user_login + * @type string $welcome + * @type string $logout_text + * @type string $logout_link + * @type string $separator + * } + * @param string $tag + */ + $args = apply_filters( 'wpmem_status_msg_args', $args, $tag ); - if ( is_user_logged_in() ) { - $status = wpmem_inc_memberlinks( 'status' ); - if ( $echo ) { - echo $status; - } + // Assemble the message string. + $status = $args['wrapper_before'] + . sprintf( $args['welcome'], $args['user_login'] ) + . $args['separator'] + . sprintf( $args['logout_link'], $args['logout_text'] ) + . $args['wrapper_after']; + } + + if ( $echo ) { + echo $status; + } else { return $status; } } From dd5060dbfd56fd824b1081fefe9de0443c2bc64f Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 09:49:01 -0400 Subject: [PATCH 1428/1694] implement wpmem_display_message() --- includes/class-wp-members-shortcodes.php | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index faad5c4a..498e7363 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -128,7 +128,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { * If the user is not logged in, return an error message if a login * error state exists, or return the login form. */ - $content = ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to ); + $content = ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) ? $wpmem->dialogs->login_failed() : wpmem_inc_login( 'login', $redirect_to ); } break; @@ -148,11 +148,11 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'register' ); } elseif ( is_user_logged_in() && is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) { $wpmem_themsg = __( "This is a generic message to display the form message dialog in the Customizer.", 'wp-members' ); - $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); $content .= wpmem_register_form( $reg_form_args ); } else { if ( $wpmem->regchk == 'loginfailed' ) { - $content = wpmem_inc_loginfailed() . wpmem_inc_login( 'login', $redirect_to ); + $content = $wpmem->dialogs->login_failed() . wpmem_inc_login( 'login', $redirect_to ); break; } // @todo Can this be moved into another function? Should $wpmem get an error message handler? @@ -160,7 +160,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { global $wpmem_captcha_err; $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; } - $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ) : ''; + $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_display_message( $wpmem->regchk, $wpmem_themsg ) : ''; $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login( 'login', $redirect_to ) : wpmem_register_form( $reg_form_args ); } break; @@ -447,7 +447,7 @@ function user_profile( $atts, $content, $tag ) { } if ( $wpmem->regchk == "loginfailed" ) { - return wpmem_inc_loginfailed(); + return $wpmem->dialogs->login_failed(); } if ( is_user_logged_in() ) { @@ -461,11 +461,11 @@ function user_profile( $atts, $content, $tag ) { case "update": // Determine if there are any errors/empty fields. if ( $wpmem->regchk == "updaterr" || $wpmem->regchk == "email" ) { - $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); $content = $content . wpmem_register_form( 'edit' ); } else { //Case "editsuccess". - $content = $content . wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); $content = $content . wpmem_inc_memberlinks(); } break; @@ -495,12 +495,12 @@ function user_profile( $atts, $content, $tag ) { switch( $wpmem->regchk ) { case "success": - $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); $content = $content . wpmem_inc_login(); break; default: - $content = wpmem_inc_regmessage( $wpmem->regchk, $wpmem_themsg ); + $content = wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); $content = $content . wpmem_register_form(); break; } From 0c05ca790d14eeaa3f24cc44f1439a7649b993e5 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 09:54:57 -0400 Subject: [PATCH 1429/1694] update to use wpmem_display_message() --- includes/class-wp-members-pwd-reset.php | 6 +- includes/class-wp-members-validation-link.php | 2 +- includes/class-wp-members.php | 8 +- includes/deprecated.php | 2 +- includes/legacy/dialogs.php | 153 ++---------------- 5 files changed, 21 insertions(+), 150 deletions(-) diff --git a/includes/class-wp-members-pwd-reset.php b/includes/class-wp-members-pwd-reset.php index a1690b79..56006c7f 100644 --- a/includes/class-wp-members-pwd-reset.php +++ b/includes/class-wp-members-pwd-reset.php @@ -162,7 +162,7 @@ function display_content( $content ) { if ( $pass1 !== $pass2 ) { // Legacy WP-Members error. $result = 'pwdchangerr'; - $msg = wpmem_inc_regmessage( 'pwdchangerr' ); + $msg = wpmem_display_message( 'pwdchangerr' ); // WP Error. $errors->add( 'password_reset_mismatch', __( 'The passwords do not match.' ) ); } @@ -172,7 +172,7 @@ function display_content( $content ) { if ( ( ! $errors->has_errors() ) && isset( $pass1 ) && ! empty( $pass1 ) ) { reset_password( $user, $pass1 ); - $msg = wpmem_inc_regmessage( 'pwdchangesuccess' ) . $wpmem->forms->do_login_form( 'pwdreset' ); + $msg = wpmem_display_message( 'pwdchangesuccess' ) . wpmem_login_form( 'pwdreset' ); $result = 'pwdchangesuccess'; } } @@ -182,7 +182,7 @@ function display_content( $content ) { if ( 'invalid_key' == $user->get_error_code() ) { // If somehow the form was submitted but the key not found. $pwd_reset_link = wpmem_profile_url( 'pwdreset' ); - $msg = wpmem_inc_regmessage( 'invalid_key', $this->form_submitted_key_not_found . '
    Request a new reset key.' ); + $msg = wpmem_display_message( 'invalid_key', $this->form_submitted_key_not_found . '
    Request a new reset key.' ); $form = ''; } else { $form = wpmem_change_password_form(); diff --git a/includes/class-wp-members-validation-link.php b/includes/class-wp-members-validation-link.php index a8d3a319..c28d74b2 100644 --- a/includes/class-wp-members-validation-link.php +++ b/includes/class-wp-members-validation-link.php @@ -253,7 +253,7 @@ public function validation_success( $content ) { $msg = ''; } - $content = wpmem_inc_regmessage( '', $msg ) . $content; + $content = wpmem_display_message( '', $msg ) . $content; } return $content; diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index f2f3971a..40e628d8 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -920,16 +920,16 @@ function do_securify( $content = null ) { switch ( $this->regchk ) { case "loginfailed": - $content = wpmem_inc_loginfailed(); + $content = $this->dialogs->login_failed(); break; case "success": - $content = wpmem_inc_regmessage( $this->regchk, $wpmem_themsg ); + $content = wpmem_display_message( $this->regchk, $wpmem_themsg ); $content = $content . wpmem_inc_login(); break; default: - $content = wpmem_inc_regmessage( $this->regchk, $wpmem_themsg ); + $content = wpmem_display_message( $this->regchk, $wpmem_themsg ); $content = $content . wpmem_register_form(); break; } @@ -1113,7 +1113,7 @@ function reg_securify( $content ) { global $wpmem, $wpmem_themsg; $nonce = wpmem_get( 'reg_nonce', false, 'get' ); if ( $nonce && wp_verify_nonce( $nonce, 'register_redirect' ) ) { - $content = wpmem_inc_regmessage( 'success', $wpmem_themsg ); + $content = wpmem_display_message( 'success', $wpmem_themsg ); $content = $content . wpmem_inc_login(); } return $content; diff --git a/includes/deprecated.php b/includes/deprecated.php index f1b606e3..e066e126 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -134,7 +134,7 @@ function wpmem_reg_securify( $content ) { global $wpmem, $wpmem_themsg; $nonce = wpmem_get( 'reg_nonce', false, 'get' ); if ( $nonce && wp_verify_nonce( $nonce, 'register_redirect' ) ) { - $content = wpmem_inc_regmessage( 'success', $wpmem_themsg ); + $content = wpmem_display_message( 'success', $wpmem_themsg ); $content = $content . wpmem_inc_login(); } return $content; diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index c74a9eb7..1e547cc0 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -97,6 +97,7 @@ function wpmem_inc_loginfailed() { * * @since 1.8 * @since 3.3.0 Changed 'toggles' to 'tags' + * @deprecated 3.4.0 Use $wpmem->dialogs->message() instead. * * @global object $wpmem * @param string $tag Error message tag to look for specific error messages. @@ -104,99 +105,8 @@ function wpmem_inc_loginfailed() { * @return string $str The final HTML for the message. */ function wpmem_inc_regmessage( $tag, $msg = '' ) { - global $wpmem; - - // defaults - $defaults = array( - 'div_before' => '
    ', - 'div_after' => '
    ', - 'p_before' => '

    ', - 'p_after' => '

    ', - 'tags' => array( - 'user', - 'email', - 'success', - 'editsuccess', - 'pwdchangerr', - 'pwdchangesuccess', - 'pwdreseterr', - 'pwdresetsuccess', - ), - ); - - /** - * Filter the message arguments. - * - * @since 2.9.0 - * @deprecated 3.3.0 Use wpmem_msg_defaults instead. - * - * @param array An array of arguments to merge with defaults. - */ - $args = apply_filters( 'wpmem_msg_args', '' ); - - /** This filter is documented in /includes/class-wp-members-admin-api.php */ - $dialogs = apply_filters( 'wpmem_dialogs', get_option( 'wpmembers_dialogs' ) ); - - // @todo Temporary(?) workaround for custom dialogs as an array (WP-Members Security). - if ( array_key_exists( $tag, $dialogs ) ) { - if ( is_array( $dialogs[ $tag ] ) ) { - $msg = stripslashes( $dialogs[ $tag ]['value'] ); - } else { - $msg = $wpmem->get_text( $tag ); - $msg = ( $dialogs[ $tag ] == $msg ) ? $msg : __( stripslashes( $dialogs[ $tag ] ), 'wp-members' ); - } - } - $defaults['msg'] = $msg; - - /** - * Filter the message array - * - * @since 2.9.2 - * @since 3.1.1 added $dialogs parameter. - * @deprecated 3.3.0 Use wpmem_msg_defaults instead. - * - * @param array $defaults An array of the defaults. - * @param string $tag The tag that we are on, if any. - * @param array $dialogs - */ - $defaults = apply_filters( 'wpmem_msg_dialog_arr', $defaults, $tag, $dialogs ); - - // Merge $args with defaults. - $args = wp_parse_args( $args, $defaults ); - - // Backwards compatibility for 'toggles'. - if ( isset( $args['toggles'] ) ) { - $args['tags'] = $args['toggles']; - } - - /** - * Filter the message settings. - * - * @since 3.3.0 - * - * @param array $defaults An array of the defaults. - * @param string $tag The tag that we are on, if any. - * @param array $dialogs - */ - $args = apply_filters( 'wpmem_msg_defaults', $defaults, $tag, $dialogs ); - - // @todo Temporary(?) workaround for custom dialogs as an array (WP-Members Security). - $display_msg = ( is_array( $args['msg'] ) ) ? $args['msg']['value'] : $args['msg']; - - $str = $args['div_before'] . $args['p_before'] . stripslashes( $display_msg ) . $args['p_after'] . $args['div_after']; - - /** - * Filter the message. - * - * @since 2.7.4 - * @since 3.1.0 Added tag. - * - * @param string $str The message. - * @param string $tag The tag of the message being displayed. - */ - return apply_filters( 'wpmem_msg_dialog', $str, $tag ); - + return $wpmem->dialogs->message( $tag, $msg ); } endif; @@ -208,6 +118,7 @@ function wpmem_inc_regmessage( $tag, $msg = '' ) { * Outputs the links used on the members area. * * @since 2.0 + * @since 3.4.0 "status" is technically deprecated. Use wpmem_login_status() instead. * * @gloabl $user_login * @global object $wpmem @@ -218,14 +129,7 @@ function wpmem_inc_memberlinks( $page = 'member' ) { global $user_login, $wpmem; - /** - * Filter the log out link. - * - * @since 2.8.3 - * - * @param string The default logout link. - */ - $logout = apply_filters( 'wpmem_logout_link', add_query_arg( 'a', 'logout' ) ); + $logout = wpmem_logout_link(); switch ( $page ) { @@ -236,7 +140,7 @@ function wpmem_inc_memberlinks( $page = 'member' ) { 'wrapper_before' => '
      ', 'wrapper_after' => '
    ', 'rows' => array( - '
  • ' . $wpmem->get_text( 'profile_edit' ) . '
  • ', + '
  • ' . $wpmem->get_text( 'profile_edit' ) . '
  • ', '
  • ' . $wpmem->get_text( 'profile_password' ) . '
  • ', ), 'after_wrapper' => '', @@ -382,40 +286,7 @@ function wpmem_inc_memberlinks( $page = 'member' ) { break; case 'status': - $args = array( - 'wrapper_before' => '

    ', - 'wrapper_after' => '

    ', - 'user_login' => $user_login, - 'welcome' => $wpmem->get_text( 'status_welcome' ), - 'logout_text' => $wpmem->get_text( 'status_logout' ), - 'logout_link' => '%s', - 'separator' => ' | ', - ); - /** - * Filter the status message parts. - * - * @since 2.9.9 - * - * @param array $args { - * The components of the links. - * - * @type string $wrapper_before The wrapper opening tag (default:

    ). - * @type string $wrapper_after The wrapper closing tag (default:

    ). - * @type string $user_login - * @type string $welcome - * @type string $logout_text - * @type string $logout_link - * @type string $separator - * } - */ - $args = apply_filters( 'wpmem_status_msg_args', $args ); - - // Assemble the message string. - $str = $args['wrapper_before'] - . sprintf( $args['welcome'], $args['user_login'] ) - . $args['separator'] - . sprintf( $args['logout_link'], $args['logout_text'] ) - . $args['wrapper_after']; + $str = wpmem_login_status(); break; } @@ -454,7 +325,7 @@ function wpmem_page_pwd_reset( $wpmem_regchk, $content ) { default: if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { - $content .= wpmem_inc_regmessage( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); + $content .= wpmem_display_message( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); } $content = $content . wpmem_change_password_form(); break; @@ -472,13 +343,13 @@ function wpmem_page_pwd_reset( $wpmem_regchk, $content ) { switch( $wpmem_regchk ) { case "pwdresetsuccess": - $content = $content . wpmem_inc_regmessage( $wpmem_regchk ); + $content = $content . wpmem_display_message( $wpmem_regchk ); $wpmem_regchk = ''; // Clear regchk. break; default: if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { - $content = wpmem_inc_regmessage( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); + $content = wpmem_display_message( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); } $content = $content . wpmem_reset_password_form(); break; @@ -521,7 +392,7 @@ function wpmem_page_user_edit( $wpmem_regchk, $content ) { $heading = apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); if ( $wpmem_a == "update") { - $content.= wpmem_inc_regmessage( $wpmem_regchk, $wpmem_themsg ); + $content.= wpmem_display_message( $wpmem_regchk, $wpmem_themsg ); } $content = $content . wpmem_register_form( 'edit', $heading ); @@ -551,7 +422,7 @@ function wpmem_page_forgot_username( $wpmem_regchk, $content ) { case "usernamefailed": $msg = $wpmem->get_text( 'usernamefailed' ); $content = $content - . wpmem_inc_regmessage( 'usernamefailed', $msg ) + . wpmem_display_message( 'usernamefailed', $msg ) . wpmem_forgot_username_form(); $wpmem->regchk = ''; // Clear regchk. break; @@ -559,7 +430,7 @@ function wpmem_page_forgot_username( $wpmem_regchk, $content ) { case "usernamesuccess": $email = ( isset( $_POST['user_email'] ) ) ? sanitize_email( $_POST['user_email'] ) : ''; $msg = sprintf( $wpmem->get_text( 'usernamesuccess' ), $email ); - $content = $content . wpmem_inc_regmessage( 'usernamesuccess', $msg ); + $content = $content . wpmem_display_message( 'usernamesuccess', $msg ); $wpmem->regchk = ''; // Clear regchk. break; From 030b1dd0cc910a19abf9285d1f169650476f26c8 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 09:55:32 -0400 Subject: [PATCH 1430/1694] wpmem_inc_loginfailed() deprecated --- includes/legacy/dialogs.php | 46 ++----------------------------------- 1 file changed, 2 insertions(+), 44 deletions(-) diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index 1e547cc0..3cb7cdeb 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -35,56 +35,14 @@ * Returns the login failed error message. * * @since 1.8 + * @deprecated 3.4.0 Use $wpmem->dialogs->login_failed(). * * @global object $wpmem The WP_Members object. * @return string $str The generated html for the login failed message. */ function wpmem_inc_loginfailed() { - global $wpmem; - - // Defaults. - $defaults = array( - 'div_before' => '
    ', - 'div_after' => '
    ', - 'heading_before' => '

    ', - 'heading' => $wpmem->get_text( 'login_failed_heading' ), - 'heading_after' => '

    ', - 'p_before' => '

    ', - 'message' => $wpmem->get_text( 'login_failed' ), // @todo $wpmem->error - 'p_after' => '

    ', - 'link' => '' . $wpmem->get_text( 'login_failed_link' ) . '', - ); - - /** - * Filter the login failed dialog arguments. - * - * @since 2.9.0 - * @since 3.3.3 Should pass defaults to filter. - * - * @param array An array of arguments to merge with defaults. - */ - $args = apply_filters( 'wpmem_login_failed_args', $defaults ); - - // Merge $args with defaults. - $args = wp_parse_args( $args, $defaults ); - - $str = $args['div_before'] - . $args['heading_before'] . $args['heading'] . $args['heading_after'] - . $args['p_before'] . $args['message'] . $args['p_after'] - . $args['p_before'] . $args['link'] . $args['p_after'] - . $args['div_after']; - - /** - * Filter the login failed dialog. - * - * @since 2.7.3 - * - * @param string $str The login failed dialog. - */ - $str = apply_filters( 'wpmem_login_failed', $str ); - - return $str; + return $wpmem->dialogs->login_failed(); } endif; From 665ced786598c6ea2b959b796856fbfd332b4ef5 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 10:10:03 -0400 Subject: [PATCH 1431/1694] move wpmem_inc_loginfailed()/wpmem_inc_regmessage() to deprecated functions file --- includes/deprecated.php | 44 +++++++++++++++++++++++++++++++++++++ includes/legacy/dialogs.php | 41 ---------------------------------- 2 files changed, 44 insertions(+), 41 deletions(-) diff --git a/includes/deprecated.php b/includes/deprecated.php index e066e126..ab841e9d 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -437,6 +437,7 @@ function wpmem_get_captcha_err( $wpmem_captcha_err ) { * @return string $str The generated html for the login form. */ function wpmem_inc_login( $page = "page", $redirect_to = null, $show = 'show' ) { + wpmem_write_log( 'wpmem_inc_login() is deprecated as of WP-Members 3.3.0. Use wpmem_login_form() instead.' ); global $wpmem; return $wpmem->forms->do_login_form( $page, $redirect_to, $show ); } @@ -459,8 +460,51 @@ function wpmem_inc_login( $page = "page", $redirect_to = null, $show = 'show' ) * @return string $form The HTML for the entire form as a string. */ function wpmem_inc_registration( $tag = 'new', $heading = '', $redirect_to = null ) { + wpmem_write_log( 'wpmem_inc_registration() is deprecated as of WP-Members 3.3.0. Use wpmem_register_form() instead.' ); global $wpmem; $args = array( 'tag' => $tag, 'heading' => $heading, 'redirect_to' => $redirect_to ); return $wpmem->forms->register_form( $args ); } // End wpmem_inc_registration. +endif; + +if ( ! function_exists( 'wpmem_inc_loginfailed' ) ): +/** + * Login Failed Dialog. + * + * Returns the login failed error message. + * + * @since 1.8 + * @deprecated 3.4.0 Use $wpmem->dialogs->login_failed(). + * + * @global object $wpmem The WP_Members object. + * @return string $str The generated html for the login failed message. + */ +function wpmem_inc_loginfailed() { + wpmem_write_log( 'wpmem_inc_loginfailed() is deprecated as of WP-Members 3.4.0. Use $wpmem->dialogs->login_failed() instead.' ); + global $wpmem; + return $wpmem->dialogs->login_failed(); +} +endif; + + +if ( ! function_exists( 'wpmem_inc_regmessage' ) ): +/** + * Message Dialog. + * + * Returns various dialogs and error messages. + * + * @since 1.8 + * @since 3.3.0 Changed 'toggles' to 'tags' + * @deprecated 3.4.0 Use wpmem_display_message() instead. + * + * @global object $wpmem + * @param string $tag Error message tag to look for specific error messages. + * @param string $msg A message that has no tag that is passed directly to the function. + * @return string $str The final HTML for the message. + */ +function wpmem_inc_regmessage( $tag, $msg = '' ) { + wpmem_write_log( "wpmem_inc_regmessage() is deprecated as of WP-Members 3.4.0. Use wpmem_display_message() instead." ); + global $wpmem; + return $wpmem->dialogs->message( $tag, $msg ); +} endif; \ No newline at end of file diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index 3cb7cdeb..135a6bb2 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -28,47 +28,6 @@ exit(); } -if ( ! function_exists( 'wpmem_inc_loginfailed' ) ): -/** - * Login Failed Dialog. - * - * Returns the login failed error message. - * - * @since 1.8 - * @deprecated 3.4.0 Use $wpmem->dialogs->login_failed(). - * - * @global object $wpmem The WP_Members object. - * @return string $str The generated html for the login failed message. - */ -function wpmem_inc_loginfailed() { - global $wpmem; - return $wpmem->dialogs->login_failed(); -} -endif; - - -if ( ! function_exists( 'wpmem_inc_regmessage' ) ): -/** - * Message Dialog. - * - * Returns various dialogs and error messages. - * - * @since 1.8 - * @since 3.3.0 Changed 'toggles' to 'tags' - * @deprecated 3.4.0 Use $wpmem->dialogs->message() instead. - * - * @global object $wpmem - * @param string $tag Error message tag to look for specific error messages. - * @param string $msg A message that has no tag that is passed directly to the function. - * @return string $str The final HTML for the message. - */ -function wpmem_inc_regmessage( $tag, $msg = '' ) { - global $wpmem; - return $wpmem->dialogs->message( $tag, $msg ); -} -endif; - - if ( ! function_exists( 'wpmem_inc_memberlinks' ) ): /** * Member Links Dialog. From f4979534f518ad1efade1aee78970f54150f4fa1 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 10:10:54 -0400 Subject: [PATCH 1432/1694] move 3.2.x notes into changelog --- changelog.txt | 180 +++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 179 insertions(+), 1 deletion(-) diff --git a/changelog.txt b/changelog.txt index e4fed080..c461bbd7 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,4 +1,182 @@ -= 3.1.9 = += 3.2.9 = + +* Load jQuery UI and Select2 libraries locally (if they have not already been enqueued). +* Use (local) template file for default tos field link (can be customized and saved in theme folder). +* Added new sanitization functions to API: wpmem_sanitize_class() and wpmem_sanitize_array(). +* Review and cleanup of form data sanitization. +* Improved file/image field upload file type validation. +* Fixed issue with loading legacy translation files. +* Added "membership" attribute to [wpmem_logged_in] shortcode (same as "product" attribute, they are interchangeable). +* Added datepicker for setting user expiration (when membership products are used). + += 3.2.8 = + +* Include jQuery UI CSS and Select2 library locally. +* Updated default TOS to a template file. +* Added additional data sanitization. +* Fixed potential security issues to prevent CSRF (Cross Site Request Forgery). + += 3.2.7 = + +* Fix console error from nonce by implementing different nonce names. +* Updated packaged POT file for legacy lanaguage files. Updated legacy language files to use new POT. +* Full removal of legacy language files that are available as language packs from https://translate.wordpress.org/projects/wp-plugins/wp-members/ +* Added jQuery UI stylesheet (fixes issue with main options tab settings modal). +* Added wpmem_default_text filter. +* Deprecated wpmem_default_text_strings filter, use wpmem_default_text instead. +* Added translation capability to field placeholders and title attributes. +* Updated Customizer setting slug to avoid namespace collisions (added "wpmem_" stem). +* Updated instances of wp_redirect() to use wp_safe_redirect(). +* Updated install for multisite to use wp_insert_site (wpmu_new_blog deprecated in WP 5.1). +* Added user screen filter to show activated users. + += 3.2.6 = + +* Update to evaluate required fields as not null (instead of false). +* Added wpmem_tos_link_tag filter. +* Added $button_html parameter to wpmem_register_form_buttons filter. +* Added wpmem_serve_menu filter. +* Added nonce to short form (long form was added in 3.2.5). +* Password change function only can be fired if user is logged in. +* Added "all" argument to wpmem_user_data() to retrieve either all user meta or WP-Members fields only. +* Added $date argument to wpmem_set_user_product(). Allows specific date to be set using API. +* Added wpmem_admin_after_profile_table and wpmem_user_after_profile_table actions. +* get_user_products() returns empty array if no products (previously boolean). +* Rebuild of [wpmem_field] logic for field type. Combined multiple conditions into a single switch. +* Update password reset form - password field should be "text" class. +* Added membership field type for allowing selection of a membership at registration. +* Login form updated from "Username" to "Username or Email". +* Added $arr parameter to wpmem_login_form_rows filter. +* Added file's post ID to post_data array. + += 3.2.5 = + +* Fix user profile (admin/user) issue with tos field not displaying. +* Fix [wpmem_logged_in] shortcode to pass product attribute. +* Fix [wpmem_field] shortcode, checks if field is set to avoid undefined index error. +* Fix do_excerpt() if post object is not set as an object. +* Fix logic for displaying hidden posts based on product access. +* Added message dialog to display in Customizer. +* Added HTML5 "required" attribute to TOS checkbox. +* Added redirect_to attribute to logout link. +* Added $tag parameter to wpmem_{$tag}_link and wpmem_{$tag}_link_str filters. +* Added id parameter to wpmem_register_form_args filter. +* Added wpmem_email_send_args filter. +* Added wpmem_is_user() function to API. +* Added wpmem_do_shortcode() utility function in API. +* Added wpmem_export_fields filter to user export function. +* Added label attribute to field shortcode. +* Added user profile tabs (jquery ui tabs). +* Updated wpmem_form_date() API function. +* Updated check product access to handle product as an array. +* Updated to make a nonce a default for the registration form (reduces possibility of spam registrations). +* Updated form field creation, $value is now optional. +* Moved textdomain to load in main class file. +* Removed possibility of using reCAPTCHA v1 which is totally obsolete. +* Removed widget status message ("you are not logged in") for logged out state. + += 3.2.4 = + +* Added deactivate users both bulk and single in Users > All Users. +* Added id attribute for form labels. +* Added wpmem_format_date() API function. +* Added label tags to multipe checkbox and radio group items. +* Added assigned product(s) column to users and posts screens. +* Updated membership product object structure. +* Updated load priority to run later for jquery loginout script. +* Removed query_vars filter. +* Deprecated wpmem_a_activate_user(), use wpmem_activate_user() instead. +* Deprecated wpmem_a_deactivate_user(), use wpmem_deactivate_user() instead. +* Relocated install file to /inc/ directory. +* Moved methods out of core.php, deprecated file. +* Fixed issue with default stylesheet setting caused by moving install file. + += 3.2.3 = + +* Bug fix in user export that caused usernames to be dropped. +* Bug fix to allow admins to edit their own profile. +* Bug fix for jquery with regards to select2, only load if products are enabled. +* Added email API. +* Added product attribute to [wpmem_logged_in] shortcode. +* Added wpmem_force_ssl() API function. +* Added wpmem_set_as_logged_in() API function. +* Added filters to remove posts marked hidden from previous/next links. +* Updated user login function to use WP script, facilitates login with username OR email, removes wpmem_login_fields filter, changes to wp_safe_redirect(). +* Updated password change for maintaining login state. +* Moved wpmem_fields(), wpmem_form_label(), and wpmem_form_field() to api-forms.php. +* Moved wpmem_user_has_role(), wpmem_user_has_meta(), wpmem_is_user_activated(), wpmem_user_data(), wpmem_update_user_role(), and wpmem_user_has_access() to api-users.php. +* Moved wpmem_do_excerpt(), wpmem_texturize(), wpmem_get_excluded_meta(), wpmem_use_ssl(), wpmem_write_log(), wpmem_load_dropins(), wpmem_array_insert(), and wpmem_get_sub_str() to api-utilities.php. +* Moved wpmem_wp_reserved_terms() to admin API. +* Deprecated wpmem_check_activated() and wpmem_use_ssl(). +* Removed obsolete functions wpmem_enqueue_style(), wpmem_convert_tag(), wpmem_no_reset(), and wpmem_user_profile_multipart(). +* Applied wpmem_force_ssl() to stylesheet in case it needs to load securely (even if the setting is saved as http://). +* Implemented change in the native WP registration form processing to allow values of "0" to be interpreted as string literals. Previously could be interpreted as boolean when being saved. + += 3.2.2 = + +* Fixed bug in 3.2.1/3.2.2 for user activation when user creates password at registration and is activated from the user profile. +* Fixed a 3.2 upgrade issue, verifies username field is properly added to field settings array. +* Fixed issue with user product verification where only expiration products were validated. +* Fixed logic in form field builder so multiselect will accept a custom class. +* Added select2 support for setting product access in the post editor. +* Removed duplicate API function wpmem_current_postid() (use wpmem_current_post_id()). +* Replaced sanitize_html_class() with WP_Members_Forms::sanitize_class() so variables may contain multiple classes. + += 3.2.1 = + +* Fixed duplicate ID in login form. +* Fixed user profile update for excluded fields. +* Fixed native WP registration, excluded WP-Members username field in form validation. +* Fixed update post when block status is not changed. +* Rebuilt user interface for post restriction metabox to make it more intuitive. +* Changed status column in All Posts to show all block statuses, not just those opposite the default. +* Changed "clickable" attribute for field shortcode default to false. +* Added wpmem_user_export_header and wpmem_user_export_row filter for export. + += 3.2.0 = + +* Tested and compatible with Gutenberg. +* Changed default address meta fields to WooCommerce billing meta keys. +* Removed language packs that install from wordpress.org (de_DE, hu_HU, ja, nl_NL, pt_BR, ru_RU, and sv_SE). +* All remaining user facing strings in get_text() added wp-members textdomain. +* Added locale as a parameter for localization filters. +* Added wpmem_register_hidden_rows filter. +* Added "post_to" key for wpmem_register_form_args. +* Rebuild of user export function. User export now uses fputcsv. +* Updates/code improvement for enqueueing styles. +* Updated widget, added widget_title filter before wpmem_widget_title, documented wpmem_widget_id filter, added instance and id_base parameters. +* Updated empty $fields check to not rewrite fields. +* Deprecated wpmem_inc_status(). +* Deprecated wpmem_do_sidebar(). +* Deprecated wpmem_create_formfield(), use wpmem_form_field() instead. +* Deprecated a number of non-user callable functions. +* Eliminated capability-based load for admin files. +* Maintain user login state when password is changed. +* Added wpmem_get_sub_str() string manipulation utility. +* Updated login form redirect_to to account for query vars. +* Fixes issue with login status if logout url is encoded (sprintf() has too few arguments). +* Added Membership Products Custom Post Type. +* Added "Hide Post" option for blocking content (currently only by post meta _wpmem_block). +* Removed several outdated stylesheets from selection (still packaged with download for users who may use them). +* Added wpmem_update_user_role() API function. +* Added wpmem_display_message() API function. +* Added wpmem_user_has_access() API function. +* HTML5 update - form anchor tags changed from "name" to "id". +* HTML5 update - form id tags set default value (can still be filtered). +* HTML5 update - removed "align" attribute (captcha, link-text). +* HTML5 update - added placeholder, pattern, and title attribute support for password fields. +* Improved the add a field dialog to adjust required inputs depending on field type. +* Added placeholder, rows, and cols attribute support for textarea field settings. +* Moved remaining core functions to appropriate object classes, left wrappers for most. +* Added new email class and shortcode class to replace previous functions/files. +* Added link_span_before/link_span_after wrapper for login link text. +* Updated "TOS" text to accept a custom label (priority to filtered label with wpmem_tos_link_txt). +* Updated all processing involving "TOS" to better exclude the field on profile update (if saved value equals the field's checked value). +* Fixed a bug that caused WP native fields to be set as non-native when labels were updated in the fields tab. +* Added Customizer control to display login, register, and widget forms when using the Customizer (easier to work on custom CSS). +* Added login/out menu item. + += 3.1.9 = * Security enhancements. * Improved user search in Users > All Users. From 27e11628a4241a99026bfdc3c85206648588a986 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 10:11:17 -0400 Subject: [PATCH 1433/1694] this is 3.4 from here on --- wp-members.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/wp-members.php b/wp-members.php index 39ffbfb3..91682dd3 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.3.9 +Version: 3.4.0 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -64,8 +64,8 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.3.9' ); -define( 'WPMEM_DB_VERSION', '2.2.1' ); +define( 'WPMEM_VERSION', '3.4.0' ); +define( 'WPMEM_DB_VERSION', '2.3.0' ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); // Initialize the plugin. From b6a07f693cfd2373d500458121583cc83d63f62d Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 10:27:55 -0400 Subject: [PATCH 1434/1694] moved, deprecated "page" handling functions --- includes/class-wp-members-shortcodes.php | 159 ++++++++++++++++++++++- includes/deprecated.php | 73 ++++++++++- includes/legacy/dialogs.php | 149 --------------------- 3 files changed, 228 insertions(+), 153 deletions(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index 498e7363..9f8bf163 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -166,15 +166,15 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { break; case in_array( 'password', $atts ): - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + $content = $this->render_pwd_reset( $wpmem->regchk, $content ); break; case in_array( 'user_edit', $atts ): - $content = wpmem_page_user_edit( $wpmem->regchk, $content, $atts ); + $content = $this->render_user_edit( $wpmem->regchk, $content, $atts ); break; case in_array( 'forgot_username', $atts ): - $content = wpmem_page_forgot_username( $wpmem->regchk, $content ); + $content = $this->render_forgot_username( $wpmem->regchk, $content ); break; case in_array( 'customizer_login', $atts ): @@ -846,6 +846,159 @@ function form_nonce( $atts, $content, $tag ) { $content = wpmem_form_nonce( $nonce, false ); return do_shortcode( $content ); } + + /** + * Password reset forms. + * + * This function creates both password reset and forgotten + * password forms for page=password shortcode. + * + * @since 2.7.6 + * @since 3.2.6 Added nonce validation. + * @since 3.4.0 Moved to shortcodes as private function, renamed from wpmem_page_pwd_reset(). + * + * @global object $wpmem + * @param string $wpmem_regchk + * @param string $content + * @return string $content + */ + function render_pwd_reset( $wpmem_regchk, $content ) { + + global $wpmem; + + if ( is_user_logged_in() ) { + + switch ( $wpmem_regchk ) { + + case "pwdchangesuccess": + $content = $content . wpmem_display_message( $wpmem_regchk ); + break; + + default: + if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { + $content .= wpmem_display_message( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); + } + $content = $content . wpmem_change_password_form(); + break; + } + + } else { + + // If the password shortcode page is set as User Profile page. + if ( 'getusername' == $wpmem->action ) { + + return wpmem_page_forgot_username( $wpmem_regchk, $content ); + + } else { + + switch( $wpmem_regchk ) { + + case "pwdresetsuccess": + $content = $content . wpmem_display_message( $wpmem_regchk ); + $wpmem_regchk = ''; // Clear regchk. + break; + + default: + if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { + $content = wpmem_display_message( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); + } + $content = $content . wpmem_reset_password_form(); + break; + } + + } + + } + + return $content; + + } + + /** + * Creates a user edit page. + * + * @since 2.7.6 + * @since 3.3.9 Added $atts + * @since 3.4.0 Moved to shortcodes as private function, renamed from wpmem_page_user_edit + * + * @global object $wpmem + * @global string $wpmem_a + * @global string $wpmem_themsg + * @param string $wpmem_regchk + * @param string $content + * @return string $content + */ + function render_user_edit( $wpmem_regchk, $content, $atts = false ) { + + global $wpmem, $wpmem_a, $wpmem_themsg; + /** + * Filter the default User Edit heading for shortcode. + * + * @since 2.7.6 + * + * @param string The default edit mode heading. + */ + $heading = apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); + + if ( $wpmem_a == "update") { + $content.= wpmem_display_message( $wpmem_regchk, $wpmem_themsg ); + } + + $args['tag'] = 'edit'; + $args['heading'] = $heading; + if ( false !== $atts && isset( $atts['fields'] ) ) { + $args['fields'] = $atts['fields']; + } + + $content = $content . wpmem_register_form( $args ); + + return $content; + } + + /** + * Forgot username form. + * + * This function creates a form for retrieving a forgotten username. + * + * @since 3.0.8 + * @since 3.4.0 Moved to shortcodes as private function, renamed from wpmem_page_forgot_username(). + * + * @param string $wpmem_regchk + * @param string $content + * @return string $content + */ + function render_forgot_username( $wpmem_regchk, $content ) { + + if ( ! is_user_logged_in() ) { + + global $wpmem; + switch( $wpmem->regchk ) { + + case "usernamefailed": + $msg = $wpmem->get_text( 'usernamefailed' ); + $content = $content + . wpmem_display_message( 'usernamefailed', $msg ) + . wpmem_forgot_username_form(); + $wpmem->regchk = ''; // Clear regchk. + break; + + case "usernamesuccess": + $email = ( isset( $_POST['user_email'] ) ) ? sanitize_email( $_POST['user_email'] ) : ''; + $msg = sprintf( $wpmem->get_text( 'usernamesuccess' ), $email ); + $content = $content . wpmem_display_message( 'usernamesuccess', $msg ); + $wpmem->regchk = ''; // Clear regchk. + break; + + default: + $content = $content . wpmem_forgot_username_form(); + break; + } + + } + + return $content; + + } } // End of file. \ No newline at end of file diff --git a/includes/deprecated.php b/includes/deprecated.php index ab841e9d..95d2a325 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -507,4 +507,75 @@ function wpmem_inc_regmessage( $tag, $msg = '' ) { global $wpmem; return $wpmem->dialogs->message( $tag, $msg ); } -endif; \ No newline at end of file +endif; + + +if ( ! function_exists( 'wpmem_page_pwd_reset' ) ): +/** + * Password reset forms. + * + * This function creates both password reset and forgotten + * password forms for page=password shortcode. + * + * @since 2.7.6 + * @since 3.2.6 Added nonce validation. + * @deprecated 3.4.0 Use $wpmem->shortcodes->render_pwd_reset() instead. + * + * @global object $wpmem + * @param string $wpmem_regchk + * @param string $content + * @return string $content + */ +function wpmem_page_pwd_reset( $wpmem_regchk, $content ) { + wpmem_write_log( "wpmem_page_pwd_reset() is deprecated as of WP-Members 3.4.0." ); + global $wpmem; + $content = $wpmem->shortcodes->render_pwd_reset( $wpmem_regchk, $content ); + return $content; + +} +endif; + + +if ( ! function_exists( 'wpmem_page_user_edit' ) ): +/** + * Creates a user edit page. + * + * @since 2.7.6 + * @since 3.3.9 Added $atts + * @deprecated 3.4.0 Use $wpmem->shortcodes->render_user_edit() instead. + * + * @global object $wpmem + * @global string $wpmem_a + * @global string $wpmem_themsg + * @param string $wpmem_regchk + * @param string $content + * @return string $content + */ +function wpmem_page_user_edit( $wpmem_regchk, $content, $atts = false ) { + wpmem_write_log( "wpmem_page_user_edit() is deprecated as of WP-Members 3.4.0." ); + global $wpmem, $wpmem_a, $wpmem_themsg; + $content = $wpmem->shortcodes->render_user_edit( $wpmem_regchk, $content ); + return $content; +} +endif; + + +/** + * Forgot username form. + * + * This function creates a form for retrieving a forgotten username. + * + * @since 3.0.8 + * @deprecated 3.4.0 Use $wpmem->shortcodes->do_forgot_username() instead. + * + * @param string $wpmem_regchk + * @param string $content + * @return string $content + */ +function wpmem_page_forgot_username( $wpmem_regchk, $content ) { + wpmem_write_log( "wpmem_page_forgot_username() is deprecated as of WP-Members 3.4.0." ); + global $wpmem; + $content = $wpmem->shortcodes->render_forgot_username( $wpmem_regchk, $content ); + return $content; + +} \ No newline at end of file diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index 135a6bb2..bf88cb21 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -213,155 +213,6 @@ function wpmem_inc_memberlinks( $page = 'member' ) { endif; -if ( ! function_exists( 'wpmem_page_pwd_reset' ) ): -/** - * Password reset forms. - * - * This function creates both password reset and forgotten - * password forms for page=password shortcode. - * - * @since 2.7.6 - * @since 3.2.6 Added nonce validation. - * - * @global object $wpmem - * @param string $wpmem_regchk - * @param string $content - * @return string $content - */ -function wpmem_page_pwd_reset( $wpmem_regchk, $content ) { - - global $wpmem; - - if ( is_user_logged_in() ) { - - switch ( $wpmem_regchk ) { - - case "pwdchangesuccess": - $content = $content . wpmem_inc_regmessage( $wpmem_regchk ); - break; - - default: - if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { - $content .= wpmem_display_message( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); - } - $content = $content . wpmem_change_password_form(); - break; - } - - } else { - - // If the password shortcode page is set as User Profile page. - if ( 'getusername' == $wpmem->action ) { - - return wpmem_page_forgot_username( $wpmem_regchk, $content ); - - } else { - - switch( $wpmem_regchk ) { - - case "pwdresetsuccess": - $content = $content . wpmem_display_message( $wpmem_regchk ); - $wpmem_regchk = ''; // Clear regchk. - break; - - default: - if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { - $content = wpmem_display_message( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); - } - $content = $content . wpmem_reset_password_form(); - break; - } - - } - - } - - return $content; - -} -endif; - - -if ( ! function_exists( 'wpmem_page_user_edit' ) ): -/** - * Creates a user edit page. - * - * @since 2.7.6 - * @since 3.3.9 Added $atts - * - * @global object $wpmem - * @global string $wpmem_a - * @global string $wpmem_themsg - * @param string $wpmem_regchk - * @param string $content - * @return string $content - */ -function wpmem_page_user_edit( $wpmem_regchk, $content ) { - - global $wpmem, $wpmem_a, $wpmem_themsg; - /** - * Filter the default User Edit heading for shortcode. - * - * @since 2.7.6 - * - * @param string The default edit mode heading. - */ - $heading = apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); - - if ( $wpmem_a == "update") { - $content.= wpmem_display_message( $wpmem_regchk, $wpmem_themsg ); - } - $content = $content . wpmem_register_form( 'edit', $heading ); - - return $content; -} -endif; - - -/** - * Forgot username form. - * - * This function creates a form for retrieving a forgotten username. - * - * @since 3.0.8 - * - * @param string $wpmem_regchk - * @param string $content - * @return string $content - */ -function wpmem_page_forgot_username( $wpmem_regchk, $content ) { - - if ( ! is_user_logged_in() ) { - - global $wpmem; - switch( $wpmem->regchk ) { - - case "usernamefailed": - $msg = $wpmem->get_text( 'usernamefailed' ); - $content = $content - . wpmem_display_message( 'usernamefailed', $msg ) - . wpmem_forgot_username_form(); - $wpmem->regchk = ''; // Clear regchk. - break; - - case "usernamesuccess": - $email = ( isset( $_POST['user_email'] ) ) ? sanitize_email( $_POST['user_email'] ) : ''; - $msg = sprintf( $wpmem->get_text( 'usernamesuccess' ), $email ); - $content = $content . wpmem_display_message( 'usernamesuccess', $msg ); - $wpmem->regchk = ''; // Clear regchk. - break; - - default: - $content = $content . wpmem_forgot_username_form(); - break; - } - - } - - return $content; - -} - /** * Displays the post restricted message. * From eb4e857765104bbb78785add264f2b311edcb8a3 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 10:47:50 -0400 Subject: [PATCH 1435/1694] deprecated, replaced wpmem_inc_memberlinks() with $wpmem->shortocdes->render_links() --- includes/class-wp-members-shortcodes.php | 192 +++++++++++++++++++++- includes/deprecated.php | 36 ++++- includes/legacy/dialogs.php | 194 ----------------------- 3 files changed, 220 insertions(+), 202 deletions(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index 9f8bf163..eaf63e48 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -122,7 +122,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { * If the user is logged in, return any nested content (if any) * or the default bullet links if no nested content. */ - $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'login' ); + $content = ( $content ) ? $content : $this->render_links( 'login' ); } else { /* * If the user is not logged in, return an error message if a login @@ -145,7 +145,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { * If the user is logged in, return any nested content (if any) * or the default bullet links if no nested content. */ - $content = ( $content ) ? $content : wpmem_inc_memberlinks( 'register' ); + $content = ( $content ) ? $content : $this->render_links( 'register' ); } elseif ( is_user_logged_in() && is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) { $wpmem_themsg = __( "This is a generic message to display the form message dialog in the Customizer.", 'wp-members' ); $content = wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); @@ -466,13 +466,13 @@ function user_profile( $atts, $content, $tag ) { } else { //Case "editsuccess". $content = $content . wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); - $content = $content . wpmem_inc_memberlinks(); + $content = $content . $this->render_links(); } break; case "pwdchange": $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); - $content = ( 'pwdchangesuccess' == $wpmem->regchk ) ? $content . wpmem_inc_memberlinks() : $content; + $content = ( 'pwdchangesuccess' == $wpmem->regchk ) ? $content . $this->render_links() : $content; break; case "renew": @@ -484,7 +484,7 @@ function user_profile( $atts, $content, $tag ) { break; default: - $content = wpmem_inc_memberlinks(); + $content = $this->render_links(); break; } @@ -507,11 +507,11 @@ function user_profile( $atts, $content, $tag ) { } elseif ( $wpmem->action == 'pwdreset' ) { - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + $content = $this->render_pwd_reset( $wpmem->regchk, $content ); } elseif( $wpmem->action == 'getusername' ) { - $content = wpmem_page_forgot_username( $wpmem->regchk, $content ); + $content = $this->render_forgot_username( $wpmem->regchk, $content ); } else { @@ -999,6 +999,184 @@ function render_forgot_username( $wpmem_regchk, $content ) { return $content; } + + /** + * Member Links Dialog. + * + * Outputs the links used on the members area. + * + * @since 2.0 + * @since 3.4.0 Replaces wpmem_inc_memberlinks(). + * + * @gloabl $user_login + * @global object $wpmem + * @param string $page + * @return string $str + */ + function render_links( $page = 'member' ) { + + global $user_login, $wpmem; + + $logout = wpmem_logout_link(); + + switch ( $page ) { + + case 'register': + + $url = ( isset( $wpmem->user_pages['profile'] ) && '' != $wpmem->user_pages['profile'] ) ? $wpmem->user_pages['profile'] : get_option( 'home' ); + + $arr = array( + 'before_wrapper' => '

    ' . sprintf( $wpmem->get_text( 'register_status' ), $user_login ) . '

    ', + 'wrapper_before' => '', + 'rows' => array( + '
  • ' . $wpmem->get_text( 'register_logout' ) . '
  • ', + '
  • ' . $wpmem->get_text( 'register_continue' ) . '
  • ', + ), + 'after_wrapper' => '', + ); + + /** + * Filter the register links array. + * + * @since 3.0.9 + * @since 3.1.0 Added after_wrapper + * + * @param array $arr { + * The components of the links. + * + * @type string $before_wrapper HTML before the wrapper (default: login status). + * @type string $wrapper_before The wrapper opening tag (default:
      ). + * @type string $wrapper_after The wrapper closing tag (default:
    ). + * @type array $rows Row items HTML. + * @type string $after_wrapper Anything that comes after the wrapper. + * } + */ + $arr = apply_filters( "wpmem_{$page}_links_args", $arr ); + + $str = $arr['before_wrapper']; + $str.= $arr['wrapper_before']; + foreach ( $arr['rows'] as $row ) { + $str.= $row; + } + $str.= $arr['wrapper_after']; + $str.= $arr['after_wrapper']; + + /** + * Filter the links displayed on the Register page (logged in state). + * + * @since 2.8.3 + * + * @param string $str The default links. + */ + $str = apply_filters( "wpmem_{$page}_links", $str ); + break; + + case 'login': + + $logout = urldecode( $logout ); // @todo Resolves sprintf issue if url is encoded. + $args = array( + 'wrapper_before' => '', + 'user_login' => $user_login, + 'welcome' => $wpmem->get_text( 'login_welcome' ), + 'logout_text' => $wpmem->get_text( 'login_logout' ), + 'logout_link' => '%s', + 'separator' => '
    ', + ); + /** + * Filter the status message parts. + * + * @since 2.9.9 + * + * @param array $args { + * The components of the links. + * + * @type string $wrapper_before The wrapper opening tag (default:

    ). + * @type string $wrapper_after The wrapper closing tag (default:

    ). + * @type string $user_login + * @type string $welcome + * @type string $logout_text + * @type string $logout_link + * @type string $separator + * } + */ + $args = apply_filters( "wpmem_{$page}_links_args", $args ); + + // Assemble the message string. + $str = $args['wrapper_before'] + . sprintf( $args['welcome'], $args['user_login'] ) + . $args['separator'] + . sprintf( $args['logout_link'], $args['logout_text'] ) + . $args['wrapper_after']; + + /** + * Filter the links displayed on the Log In page (logged in state). + * + * @since 2.8.3 + * + * @param string $str The default links. + */ + $str = apply_filters( "wpmem_{$page}_links", $str ); + break; + + case 'member': + default: + + $arr = array( + 'before_wrapper' => '', + 'wrapper_before' => '
      ', + 'wrapper_after' => '
    ', + 'rows' => array( + '
  • ' . $wpmem->get_text( 'profile_edit' ) . '
  • ', + '
  • ' . $wpmem->get_text( 'profile_password' ) . '
  • ', + ), + 'after_wrapper' => '', + ); + + if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 && function_exists( 'wpmem_user_page_detail' ) ) { + $arr['rows'][] = wpmem_user_page_detail(); + } + + /** + * Filter the member links array. + * + * @since 3.0.9 + * @since 3.1.0 Added after_wrapper + * + * @param array $arr { + * The components of the links. + * + * @type string $before_wrapper Anything that comes before the wrapper. + * @type string $wrapper_before The wrapper opening tag (default:
      ). + * @type string $wrapper_after The wrapper closing tag (default:
    ). + * @type array $rows Row items HTML. + * @type string $after_wrapper Anything that comes after the wrapper. + * } + */ + $arr = apply_filters( "wpmem_{$page}_links_args", $arr ); + + $str = $arr['before_wrapper']; + $str.= $arr['wrapper_before']; + foreach ( $arr['rows'] as $row ) { + $str.= $row; + } + $str.= $arr['wrapper_after']; + $str.= $arr['after_wrapper']; + + /** + * Filter the links displayed on the User Profile page (logged in state). + * + * @since 2.8.3 + * + * @param string $str The default links. + */ + $str = apply_filters( "wpmem_{$page}_links", $str ); + break; + } + + return $str; + } } // End of file. \ No newline at end of file diff --git a/includes/deprecated.php b/includes/deprecated.php index 95d2a325..14bcaa20 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -578,4 +578,38 @@ function wpmem_page_forgot_username( $wpmem_regchk, $content ) { $content = $wpmem->shortcodes->render_forgot_username( $wpmem_regchk, $content ); return $content; -} \ No newline at end of file +} + +if ( ! function_exists( 'wpmem_inc_memberlinks' ) ): +/** + * Member Links Dialog. + * + * Outputs the links used on the members area. + * + * @since 2.0 + * @since 3.4.0 "status" is technically deprecated. Use wpmem_login_status() instead. + * @deprecated 3.4.0 Use $wpmem->shortocdes->render_links() instead. + * + * @gloabl $user_login + * @global object $wpmem + * @param string $page + * @return string $str + */ +function wpmem_inc_memberlinks( $page = 'member' ) { + wpmem_write_log( "wpmem_inc_memberlinks() is deprecated as of WP-Members 3.4.0." ); + global $wpmem; + switch ( $page ) { + + case 'member': + case 'register': + case 'login': + $str = $wpmem->shortcodes->render_links( $page ); + break; + case 'status': + $str = wpmem_login_status(); + break; + + } + return $str; +} +endif; \ No newline at end of file diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index bf88cb21..70be295e 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -12,15 +12,6 @@ * @package WP-Members * @author Chad Butler * @copyright 2006-2021 - * - * Functions Included: - * - wpmem_inc_loginfailed - * - wpmem_inc_regmessage - * - wpmem_inc_memberlinks - * - wpmem_page_pwd_reset - * - wpmem_page_user_edit - * - wpmem_page_forgot_username - * - wpmem_inc_forgotusername */ // Exit if accessed directly. @@ -28,191 +19,6 @@ exit(); } -if ( ! function_exists( 'wpmem_inc_memberlinks' ) ): -/** - * Member Links Dialog. - * - * Outputs the links used on the members area. - * - * @since 2.0 - * @since 3.4.0 "status" is technically deprecated. Use wpmem_login_status() instead. - * - * @gloabl $user_login - * @global object $wpmem - * @param string $page - * @return string $str - */ -function wpmem_inc_memberlinks( $page = 'member' ) { - - global $user_login, $wpmem; - - $logout = wpmem_logout_link(); - - switch ( $page ) { - - case 'member': - - $arr = array( - 'before_wrapper' => '', - 'wrapper_before' => '
      ', - 'wrapper_after' => '
    ', - 'rows' => array( - '
  • ' . $wpmem->get_text( 'profile_edit' ) . '
  • ', - '
  • ' . $wpmem->get_text( 'profile_password' ) . '
  • ', - ), - 'after_wrapper' => '', - ); - - if ( defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 && function_exists( 'wpmem_user_page_detail' ) ) { - $arr['rows'][] = wpmem_user_page_detail(); - } - - /** - * Filter the member links array. - * - * @since 3.0.9 - * @since 3.1.0 Added after_wrapper - * - * @param array $arr { - * The components of the links. - * - * @type string $before_wrapper Anything that comes before the wrapper. - * @type string $wrapper_before The wrapper opening tag (default:
      ). - * @type string $wrapper_after The wrapper closing tag (default:
    ). - * @type array $rows Row items HTML. - * @type string $after_wrapper Anything that comes after the wrapper. - * } - */ - $arr = apply_filters( "wpmem_{$page}_links_args", $arr ); - - $str = $arr['before_wrapper']; - $str.= $arr['wrapper_before']; - foreach ( $arr['rows'] as $row ) { - $str.= $row; - } - $str.= $arr['wrapper_after']; - $str.= $arr['after_wrapper']; - - /** - * Filter the links displayed on the User Profile page (logged in state). - * - * @since 2.8.3 - * - * @param string $str The default links. - */ - $str = apply_filters( "wpmem_{$page}_links", $str ); - break; - - case 'register': - - $url = ( isset( $wpmem->user_pages['profile'] ) && '' != $wpmem->user_pages['profile'] ) ? $wpmem->user_pages['profile'] : get_option( 'home' ); - - $arr = array( - 'before_wrapper' => '

    ' . sprintf( $wpmem->get_text( 'register_status' ), $user_login ) . '

    ', - 'wrapper_before' => '
      ', - 'wrapper_after' => '
    ', - 'rows' => array( - '
  • ' . $wpmem->get_text( 'register_logout' ) . '
  • ', - '
  • ' . $wpmem->get_text( 'register_continue' ) . '
  • ', - ), - 'after_wrapper' => '', - ); - - /** - * Filter the register links array. - * - * @since 3.0.9 - * @since 3.1.0 Added after_wrapper - * - * @param array $arr { - * The components of the links. - * - * @type string $before_wrapper HTML before the wrapper (default: login status). - * @type string $wrapper_before The wrapper opening tag (default:
      ). - * @type string $wrapper_after The wrapper closing tag (default:
    ). - * @type array $rows Row items HTML. - * @type string $after_wrapper Anything that comes after the wrapper. - * } - */ - $arr = apply_filters( "wpmem_{$page}_links_args", $arr ); - - $str = $arr['before_wrapper']; - $str.= $arr['wrapper_before']; - foreach ( $arr['rows'] as $row ) { - $str.= $row; - } - $str.= $arr['wrapper_after']; - $str.= $arr['after_wrapper']; - - /** - * Filter the links displayed on the Register page (logged in state). - * - * @since 2.8.3 - * - * @param string $str The default links. - */ - $str = apply_filters( "wpmem_{$page}_links", $str ); - break; - - case 'login': - - $logout = urldecode( $logout ); // @todo Resolves sprintf issue if url is encoded. - $args = array( - 'wrapper_before' => '

    ', - 'wrapper_after' => '

    ', - 'user_login' => $user_login, - 'welcome' => $wpmem->get_text( 'login_welcome' ), - 'logout_text' => $wpmem->get_text( 'login_logout' ), - 'logout_link' => '%s', - 'separator' => '
    ', - ); - /** - * Filter the status message parts. - * - * @since 2.9.9 - * - * @param array $args { - * The components of the links. - * - * @type string $wrapper_before The wrapper opening tag (default:

    ). - * @type string $wrapper_after The wrapper closing tag (default:

    ). - * @type string $user_login - * @type string $welcome - * @type string $logout_text - * @type string $logout_link - * @type string $separator - * } - */ - $args = apply_filters( "wpmem_{$page}_links_args", $args ); - - // Assemble the message string. - $str = $args['wrapper_before'] - . sprintf( $args['welcome'], $args['user_login'] ) - . $args['separator'] - . sprintf( $args['logout_link'], $args['logout_text'] ) - . $args['wrapper_after']; - - /** - * Filter the links displayed on the Log In page (logged in state). - * - * @since 2.8.3 - * - * @param string $str The default links. - */ - $str = apply_filters( "wpmem_{$page}_links", $str ); - break; - - case 'status': - $str = wpmem_login_status(); - break; - - } - - return $str; -} -endif; - - /** * Displays the post restricted message. * From 399ea58502c4b0a5e578754b9ad2a17e5f6c7d38 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 10:59:40 -0400 Subject: [PATCH 1436/1694] move wpmem_restricted_dialog() to api, dialogs.php now fully deprecated --- includes/api/api.php | 14 ++++++++++++++ includes/class-wp-members.php | 3 ++- includes/legacy/dialogs.php | 12 ------------ 3 files changed, 16 insertions(+), 13 deletions(-) diff --git a/includes/api/api.php b/includes/api/api.php index 9ce4a253..fe8a0a4c 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -485,4 +485,18 @@ function wpmem_is_reg_type( $type ) { return $wpmem->reg_type[ 'is_' . $type ]; } +/** + * Displays the post restricted message. + * + * @todo Evaluate - this doesn't seem to be used yet. + * + * @since 3.3.5 + * + * @return string + */ +function wpmem_restricted_dialog() { + global $wpmem; + return $wpmem->forms->add_restricted_msg(); +} + // End of file. \ No newline at end of file diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 40e628d8..ed672973 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -640,9 +640,10 @@ function load_dependencies() { require_once( $this->path . 'includes/api/api-products.php' ); require_once( $this->path . 'includes/api/api-users.php' ); require_once( $this->path . 'includes/api/api-utilities.php' ); - require_once( $this->path . 'includes/legacy/dialogs.php' ); require_once( $this->path . 'includes/deprecated.php' ); + require_once( $this->path . 'includes/legacy/dialogs.php' ); // File is totally deprecated at this point; eval for removal. + if ( defined( 'WP_CLI' ) && WP_CLI ) { require_once( $this->path . 'includes/cli/class-wp-members-cli.php' ); require_once( $this->path . 'includes/cli/class-wp-members-cli-user.php' ); diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index 70be295e..d03855ab 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -19,16 +19,4 @@ exit(); } -/** - * Displays the post restricted message. - * - * @since 3.3.5 - * - * @return string - */ -function wpmem_restricted_dialog() { - global $wpmem; - return $wpmem->forms->add_restricted_msg(); -} - // End of file. \ No newline at end of file From 2dbe433d77859444b35708c7f9cccd5fbbe8206e Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 27 Jul 2021 15:30:08 -0400 Subject: [PATCH 1437/1694] convert to wpmem_login_form(), deprecated other methods --- includes/api/api-forms.php | 11 +- includes/class-wp-members-forms.php | 160 +++++------------------ includes/class-wp-members-shortcodes.php | 30 ++--- includes/class-wp-members.php | 6 +- includes/deprecated.php | 4 +- 5 files changed, 61 insertions(+), 150 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 62f431fa..4d17b498 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -26,6 +26,7 @@ * @since 2.5.1 * @since 3.1.7 Now a wrapper for $wpmem->forms->login_form() * @since 3.3.0 Added to API. + * @since 3.4.0 Main API function for displaying login form. * * @global object $wpmem * @param array $args { @@ -59,16 +60,22 @@ * } * @return string $form The HTML for the form as a string. */ -function wpmem_login_form( $args, $arr = false ) { +function wpmem_login_form( $args = array(), $arr = false ) { global $wpmem; + + /* // Convert legacy values. - if ( ! is_array( $args ) && is_array( $arr ) ) { + if ( ( ! is_array( $args ) && is_array( $arr ) ) || ( is_array( $args ) && empty( $args ) ) ) { $page = $args; $args = $arr; $args['page'] = $page; } + $args['form'] = ( isset( $args['form'] ) ) ? $args['form'] : 'login'; // @todo Work on making this $wpmem->forms->do_login_form( $args ); return $wpmem->forms->login_form( $args ); + */ + + return $wpmem->forms->do_shortform( 'login' ); } endif; diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index e0444769..64f22dba 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -696,6 +696,8 @@ function file_upload_dir( $param ) { * @return string $form The HTML for the form as a string. */ function login_form( $mixed, $arr = array() ) { + + global $wpmem; // Handle legacy use. if ( is_array( $mixed ) ) { @@ -704,7 +706,8 @@ function login_form( $mixed, $arr = array() ) { } else { $page = $mixed; } - + +$action = ( ! isset( $arr['action'] ) ) ? 'login' : $arr['action']; // Set up redirect_to @todo This could be done in a separate method usable by both login & reg. if ( isset( $_REQUEST['redirect_to'] ) ) { @@ -717,9 +720,8 @@ function login_form( $mixed, $arr = array() ) { } } - global $wpmem; - - // set up default wrappers + // Set up default wrappers. + // NOTE: DO NOT EDIT! There is a filter hook for this -> wpmem_login_form_args. $defaults = array( // wrappers @@ -741,7 +743,7 @@ function login_form( $mixed, $arr = array() ) { 'link_span_after' => '', // classes & ids - 'form_id' => 'wpmem_' . $arr['action'] . '_form', + 'form_id' => 'wpmem_' . $action . '_form', 'form_class' => 'form', 'button_id' => '', 'button_class' => 'buttons', @@ -797,9 +799,9 @@ function login_form( $mixed, $arr = array() ) { * @type string $redirect_to Default: (the $redirec_to argument passed to the function) * @type boolean $login_form_action Default: true (if true, adds the WP login_form action) * } - * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange|getusername. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange|getusername. */ - $args = apply_filters( 'wpmem_login_form_args', $defaults, $arr['action'] ); + $args = apply_filters( 'wpmem_login_form_args', $defaults, $action ); // Merge $args with defaults. $args = wp_parse_args( $args, $defaults ); @@ -835,11 +837,11 @@ function login_form( $mixed, $arr = array() ) { * @since 2.9.0 * @since 3.2.6 Added $arr parameter so all settings are passed. * - * @param array $rows An array containing the form rows. - * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange|getusername. - * @param array $arr An array containing all of the form settings. + * @param array $rows An array containing the form rows. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange|getusername. + * @param array $arr An array containing all of the form settings. */ - $rows = apply_filters( 'wpmem_login_form_rows', $rows, $arr['action'], $arr ); + $rows = apply_filters( 'wpmem_login_form_rows', $rows, $action, $arr ); // Put the rows from the array into $form. $form = ''; @@ -851,7 +853,7 @@ function login_form( $mixed, $arr = array() ) { } // Handle outside elements added to the login form (currently ONLY for login). - if ( 'login' == $arr['action'] && $args['login_form_action'] ) { + if ( 'login' == $action && $args['login_form_action'] ) { ob_start(); /** This action is documented in wp-login.php */ do_action( 'login_form' ); @@ -862,21 +864,21 @@ function login_form( $mixed, $arr = array() ) { // Build hidden fields, filter, and add to the form. $hidden = wpmem_create_formfield( 'redirect_to', 'hidden', esc_url( $args['redirect_to'] ) ) . $args['n']; - $hidden = $hidden . wpmem_create_formfield( 'a', 'hidden', $arr['action'] ) . $args['n']; - $hidden = ( $arr['action'] != 'login' ) ? $hidden . wpmem_create_formfield( 'formsubmit', 'hidden', '1' ) : $hidden; + $hidden = $hidden . wpmem_create_formfield( 'a', 'hidden', $action ) . $args['n']; + $hidden = ( $action != 'login' ) ? $hidden . wpmem_create_formfield( 'formsubmit', 'hidden', '1' ) : $hidden; /** * Filter the hidden field HTML. * * @since 2.9.0 * - * @param string $hidden The generated HTML of hidden fields. - * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange|getusername. + * @param string $hidden The generated HTML of hidden fields. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange|getusername. */ - $form = $form . apply_filters( 'wpmem_login_hidden_fields', $hidden, $arr['action'] ); + $form = $form . apply_filters( 'wpmem_login_hidden_fields', $hidden, $action ); // Build the buttons, filter, and add to the form. - if ( $arr['action'] == 'login' ) { + if ( $action == 'login' ) { $args['remember_check'] = ( $args['remember_check'] ) ? $args['t'] . wpmem_create_formfield( 'rememberme', 'checkbox', 'forever' ) . ' ' . '  ' . $args['n'] : ''; $buttons = $args['remember_check'] . $args['t'] . '' . $args['n']; } else { @@ -890,10 +892,10 @@ function login_form( $mixed, $arr = array() ) { * * @since 2.9.0 * - * @param string $buttons The generated HTML of the form buttons. - * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange|getusername. + * @param string $buttons The generated HTML of the form buttons. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange|getusername. */ - $form = $form . apply_filters( 'wpmem_login_form_buttons', $args['buttons_before'] . $args['n'] . $buttons . $args['buttons_after'] . $args['n'], $arr['action'] ); + $form = $form . apply_filters( 'wpmem_login_form_buttons', $args['buttons_before'] . $args['n'] . $buttons . $args['buttons_after'] . $args['n'], $action ); $links_array = array( 'forgot' => array( @@ -917,7 +919,7 @@ function login_form( $mixed, $arr = array() ) { ); foreach ( $links_array as $key => $value ) { $tag = $value['tag']; - if ( ( $wpmem->user_pages[ $value['page'] ] || 'members' == $page ) && $value['action'] == $arr['action'] ) { + if ( ( $wpmem->user_pages[ $value['page'] ] || 'members' == $page ) && $value['action'] == $action ) { /** * Filters register, forgot password, and forgot username links. * @@ -980,13 +982,13 @@ function login_form( $mixed, $arr = array() ) { $form = $args['fieldset_before'] . $args['n'] . $form . $args['fieldset_after'] . $args['n']; // Apply nonce. - $form = wp_nonce_field( 'wpmem_shortform_nonce', '_wpmem_' . $arr['action'] . '_nonce', true, false ) . $args['n'] . $form; + $form = wp_nonce_field( 'wpmem_shortform_nonce', '_wpmem_' . $action . '_nonce', true, false ) . $args['n'] . $form; // Apply form wrapper. $form = '
    ' . $args['n'] . $form . ''; // Apply anchor. - $form = '' . $args['n'] . $form; + $form = '' . $args['n'] . $form; // Apply main wrapper. $form = $args['main_div_before'] . $args['n'] . $form . $args['n'] . $args['main_div_after']; @@ -1002,10 +1004,10 @@ function login_form( $mixed, $arr = array() ) { * * @since 2.7.4 * - * @param string $form The HTML of the final generated form. - * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange|getusername. + * @param string $form The HTML of the final generated form. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange|getusername. */ - $form = apply_filters( 'wpmem_login_form', $form, $arr['action'] ); + $form = apply_filters( 'wpmem_login_form', $form, $action ); /** * Filter before the form. @@ -1015,10 +1017,10 @@ function login_form( $mixed, $arr = array() ) { * * @since 2.7.4 * - * @param string $str The HTML to add before the form. Default null. - * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange|getusername. + * @param string $str The HTML to add before the form. Default null. + * @param string $action The action being performed by the form. login|pwdreset|pwdchange|getusername. */ - $form = apply_filters( 'wpmem_login_form_before', '', $arr['action'] ) . $form; + $form = apply_filters( 'wpmem_login_form_before', '', $action ) . $form; return $form; } // End login_form. @@ -1690,104 +1692,6 @@ function strip_breaks( $form, $rows ) { } return $form; } - - /** - * Login Dialog. - * - * Loads the login form for user login. - * - * @since 1.8 - * @since 3.1.4 Global $wpmem_regchk no longer needed. - * @since 3.2.0 Moved to forms class, renamed do_login_form(). - * @todo $show is deprecated, post restricted message ($msg) handled externally. - * - * @global object $post The WordPress Post object. - * @global object $wpmem The WP_Members object. - * @param string $page If the form is being displayed in place of blocked content. Default: page. - * @param string $redirect_to Redirect URL. Default: null. - * @param string $show If the form is being displayed in place of blocked content. Default: show. - * @return string $str The generated html for the login form. - */ - function do_login_form( $page = "page", $redirect_to = null, $show = 'show' ) { - - global $post, $wpmem; - - $msg = ''; - - if ( 'page' == $page ) { - $msg = $this->add_restricted_msg(); - } - - // Create the default inputs. - $default_inputs = array( - array( - 'name' => $wpmem->get_text( 'login_username' ), - 'type' => 'text', - 'tag' => 'log', - 'class' => 'username', - 'div' => 'div_text', - ), - array( - 'name' => $wpmem->get_text( 'login_password' ), - 'type' => 'password', - 'tag' => 'pwd', - 'class' => 'password', - 'div' => 'div_text', - ), - ); - - /** - * Filter the array of login form fields. - * - * @since 2.9.0 - * @deprecated 3.3.0 Use wpmem_login_form_defaults instead. - * - * @param array $default_inputs An array matching the elements used by default. - */ - $default_inputs = apply_filters( 'wpmem_inc_login_inputs', $default_inputs ); - - $defaults = array( - 'heading' => $wpmem->get_text( 'login_heading' ), - 'action' => 'login', - 'button_text' => $wpmem->get_text( 'login_button' ), - 'inputs' => $default_inputs, - 'redirect_to' => $redirect_to, - ); - - /** - * Filter the arguments to override login form defaults. - * - * @since 2.9.0 - * @deprecated 3.3.0 Use wpmem_login_form_defaults instead. - * - * @param array $args An array of arguments to use. Default null. - */ - $args = apply_filters( 'wpmem_inc_login_args', '' ); - $arr = wp_parse_args( $args, $defaults ); - - /** - * Filter the arguments to override login form defaults. - * - * @since 3.3.0 - * - * @param array $args { - * @type string $heading - * @type string $action - * @type string $button_text - * @type string $redirect_to - * @type array $inputs { - * @type string $name - * @type string $type - * @type string $tag - * @type string $class - * @type string $div - * } - * } - */ - $arr = apply_filters( 'wpmem_login_form_defaults', $arr ); - - return ( $show == 'show' ) ? $msg . wpmem_login_form( $page, $arr ) : $msg; - } /** * Appends WP-Members registration fields to wp-login.php registration form. diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index eaf63e48..f4605b58 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -118,17 +118,15 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { case in_array( 'login', $atts ): if ( is_user_logged_in() && '1' != $customizer ) { - /* - * If the user is logged in, return any nested content (if any) - * or the default bullet links if no nested content. - */ + // If the user is logged in, return any nested content (if any) or the default bullet links if no nested content. $content = ( $content ) ? $content : $this->render_links( 'login' ); } else { - /* - * If the user is not logged in, return an error message if a login - * error state exists, or return the login form. - */ - $content = ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) ? $wpmem->dialogs->login_failed() : wpmem_inc_login( 'login', $redirect_to ); + $content = ''; + if ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) { + $content = $wpmem->dialogs->login_failed(); + } + $form_args = array( 'form'=>'login', 'redirect_to'=>$atts['redirect_to'], 'form_id'=>$atts['form_id'] ); + $content .= wpmem_login_form( $form_args ); } break; @@ -151,8 +149,9 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { $content = wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); $content .= wpmem_register_form( $reg_form_args ); } else { + $form_args = array( $form=>'login', 'redirect_to'=>$redirect_to, 'form_id'=>$form_id ); if ( $wpmem->regchk == 'loginfailed' ) { - $content = $wpmem->dialogs->login_failed() . wpmem_inc_login( 'login', $redirect_to ); + $content = $wpmem->dialogs->login_failed() . wpmem_login_form( $form_args ); break; } // @todo Can this be moved into another function? Should $wpmem get an error message handler? @@ -161,7 +160,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; } $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_display_message( $wpmem->regchk, $wpmem_themsg ) : ''; - $content .= ( $wpmem->regchk == 'success' ) ? wpmem_inc_login( 'login', $redirect_to ) : wpmem_register_form( $reg_form_args ); + $content .= ( $wpmem->regchk == 'success' ) ? wpmem_login_form( $form_args ) : wpmem_register_form( $reg_form_args ); } break; @@ -178,7 +177,8 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { break; case in_array( 'customizer_login', $atts ): - $content = wpmem_inc_login( 'login', $redirect_to ); + $form_args = array( $form=>'login', 'redirect_to'=>$redirect_to, 'form_id'=>$form_id ); + $content = wpmem_login_form( $form_args ); break; case in_array( 'customizer_register', $atts ): @@ -496,7 +496,7 @@ function user_profile( $atts, $content, $tag ) { case "success": $content = wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); - $content = $content . wpmem_inc_login(); + $content = $content . wpmem_login_form(); break; default: @@ -515,7 +515,7 @@ function user_profile( $atts, $content, $tag ) { } else { - $content = $content . wpmem_inc_login( 'members' ); + $content = $content . wpmem_login_form( 'members' ); $content = ( ! $hide_register ) ? $content . wpmem_register_form() : $content; } } @@ -609,7 +609,7 @@ function fields( $atts, $content = null, $tag ) { global $wpmem; $fields = wpmem_fields(); - $field_type = ( isset( $fields[ $field ]['type'] ) ) ? $fields[ $field ]['type'] : 'native'; // @todo Is this needed? It seems to set the type to "native" if not set. + //$field_type = ( isset( $fields[ $field ]['type'] ) ) ? $fields[ $field ]['type'] : 'native'; // @todo Is this needed? It seems to set the type to "native" if not set. $user_info_field = ( isset( $field ) && is_object( $user_info ) ) ? $user_info->{$field} : ''; $result = false; diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index ed672973..1bb04d15 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -926,7 +926,7 @@ function do_securify( $content = null ) { case "success": $content = wpmem_display_message( $this->regchk, $wpmem_themsg ); - $content = $content . wpmem_inc_login(); + $content = $content . wpmem_login_form(); break; default: @@ -960,7 +960,7 @@ function do_securify( $content = null ) { } - $content = ( isset( $this->show_login[ $post->post_type ] ) && $this->show_login[ $post->post_type ] == 1 ) ? $content . wpmem_inc_login() : $content . wpmem_inc_login( 'page', '', 'hide' ); + $content = ( isset( $this->show_login[ $post->post_type ] ) && $this->show_login[ $post->post_type ] == 1 ) ? $content . wpmem_login_form() : $content . wpmem_login_form( 'page', '', 'hide' ); $content = ( isset( $this->show_reg[ $post->post_type ] ) && $this->show_reg[ $post->post_type ] == 1 ) ? $content . wpmem_register_form() : $content; } @@ -1115,7 +1115,7 @@ function reg_securify( $content ) { $nonce = wpmem_get( 'reg_nonce', false, 'get' ); if ( $nonce && wp_verify_nonce( $nonce, 'register_redirect' ) ) { $content = wpmem_display_message( 'success', $wpmem_themsg ); - $content = $content . wpmem_inc_login(); + $content = $content . wpmem_login_form(); } return $content; } diff --git a/includes/deprecated.php b/includes/deprecated.php index 14bcaa20..24c093c1 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -135,7 +135,7 @@ function wpmem_reg_securify( $content ) { $nonce = wpmem_get( 'reg_nonce', false, 'get' ); if ( $nonce && wp_verify_nonce( $nonce, 'register_redirect' ) ) { $content = wpmem_display_message( 'success', $wpmem_themsg ); - $content = $content . wpmem_inc_login(); + $content = $content . wpmem_login_form(); } return $content; } @@ -439,7 +439,7 @@ function wpmem_get_captcha_err( $wpmem_captcha_err ) { function wpmem_inc_login( $page = "page", $redirect_to = null, $show = 'show' ) { wpmem_write_log( 'wpmem_inc_login() is deprecated as of WP-Members 3.3.0. Use wpmem_login_form() instead.' ); global $wpmem; - return $wpmem->forms->do_login_form( $page, $redirect_to, $show ); + return wpmem_login_form( 'login' ); //$wpmem->forms->do_login_form( $page, $redirect_to, $show ); } endif; From a4d0974e1b70ebdb6b0137c7176e4ac45edb2d5a Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 28 Jul 2021 13:16:37 -0400 Subject: [PATCH 1438/1694] reworking of login form so wpmem_login_form() is now a full api function --- includes/api/api-forms.php | 2 +- includes/api/api-utilities.php | 24 +++++++++++++++++++++++ includes/api/api.php | 2 +- includes/class-wp-members-forms.php | 25 ++++++------------------ includes/class-wp-members-shortcodes.php | 17 ++++++++-------- includes/class-wp-members.php | 20 +++++++++---------- includes/deprecated.php | 2 +- 7 files changed, 52 insertions(+), 40 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 4d17b498..6b93bdce 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -75,7 +75,7 @@ function wpmem_login_form( $args = array(), $arr = false ) { return $wpmem->forms->login_form( $args ); */ - return $wpmem->forms->do_shortform( 'login' ); + return $wpmem->forms->do_shortform( 'login', $args ); } endif; diff --git a/includes/api/api-utilities.php b/includes/api/api-utilities.php index 95c625b5..67a86944 100644 --- a/includes/api/api-utilities.php +++ b/includes/api/api-utilities.php @@ -350,4 +350,28 @@ function wpmem_get_suffix( $echo = false ) { */ function wpmem_is_woo_active() { return ( class_exists( 'woocommerce' ) ) ? true : false; +} + +/** + * A utility to determine a redirect_to param. + * + * @since 3.4.0 + * + * @param array $args + * @return string $redirect_to + */ +function wpmem_get_redirect_to( $args = array() ) { + // redirect_to in the form or URL will override a redirect set in the form args. + if ( isset( $_REQUEST['redirect_to'] ) ) { + $redirect_to = $_REQUEST['redirect_to']; + } else { + if ( isset( $args['redirect_to'] ) ) { + $raw_redirect_to = $args['redirect_to']; + // Is it a URL? + $redirect_to = ( false == filter_var( $raw_redirect_to, FILTER_VALIDATE_URL ) ) ? home_url( $raw_redirect_to ) : $raw_redirect_to; + } else { + $redirect_to = ( isset( $_SERVER['REQUEST_URI'] ) ) ? $_SERVER['REQUEST_URI'] : get_permalink(); + } + } + return $redirect_to; } \ No newline at end of file diff --git a/includes/api/api.php b/includes/api/api.php index fe8a0a4c..ff47ed3b 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -494,7 +494,7 @@ function wpmem_is_reg_type( $type ) { * * @return string */ -function wpmem_restricted_dialog() { +function wpmem_restricted_message() { global $wpmem; return $wpmem->forms->add_restricted_msg(); } diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 64f22dba..15924a41 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -710,15 +710,7 @@ function login_form( $mixed, $arr = array() ) { $action = ( ! isset( $arr['action'] ) ) ? 'login' : $arr['action']; // Set up redirect_to @todo This could be done in a separate method usable by both login & reg. - if ( isset( $_REQUEST['redirect_to'] ) ) { - $redirect_to = $_REQUEST['redirect_to']; - } else { - if ( isset( $arr['redirect_to'] ) ) { - $redirect_to = $arr['redirect_to']; - } else { - $redirect_to = ( isset( $_SERVER['REQUEST_URI'] ) ) ? $_SERVER['REQUEST_URI'] : get_permalink(); - } - } + $redirect_to = wpmem_get_redirect_to( $arr ); // Set up default wrappers. // NOTE: DO NOT EDIT! There is a filter hook for this -> wpmem_login_form_args. @@ -2034,18 +2026,13 @@ function attribution() { * @global stdClass $wpmem * * @param string $form login|changepassword|resetpassword|forgotusername + * @param array $args * @return string $form */ - function do_shortform( $form, $page = "page", $redirect_to = null, $show = 'show' ) { + function do_shortform( $form, $args = array() ) { global $post, $wpmem; - $msg = ''; - - if ( "login" == $form && "page" == $page ) { - $msg = $this->add_restricted_msg(); - } - $input_arrays = array( 'login' => array( array( @@ -2122,7 +2109,7 @@ function do_shortform( $form, $page = "page", $redirect_to = null, $show = 'show 'action' => 'login', 'button_text' => $wpmem->get_text( 'login_button' ), 'inputs' => $default_inputs, - 'redirect_to' => $redirect_to, + 'redirect_to' => $args['redirect_to'], ), 'changepassword' => array( 'heading' => $wpmem->get_text( 'pwdchg_heading' ), @@ -2164,7 +2151,7 @@ function do_shortform( $form, $page = "page", $redirect_to = null, $show = 'show */ $arr = apply_filters( 'wpmem_' . $form . '_form_defaults', $arr ); - return ( $show == 'show' ) ? $msg . $this->login_form( $page, $arr ) : $msg; + return $this->login_form( $page, $arr ); } /** @@ -2176,7 +2163,7 @@ function do_shortform( $form, $page = "page", $redirect_to = null, $show = 'show * * @return string $str The generated message. */ - private function add_restricted_msg() { + public function add_restricted_msg() { global $wpmem; diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index f4605b58..a529d7e7 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -96,9 +96,12 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { global $wpmem, $wpmem_themsg; // Defaults. - $redirect_to = ( isset( $atts['redirect_to'] ) ) ? $atts['redirect_to'] : null; - $texturize = ( isset( $atts['texturize'] ) ) ? $atts['texturize'] : false; - $form_id = ( isset( $atts['form_id'] ) ) ? $atts['form_id'] : null; + $defaults = array( + 'redirect_to' => null, + 'texturize' => false, + 'id' => false, + ); + $atts = wp_parse_args( $atts, $defaults ); $customizer = ( is_customize_preview() ) ? get_theme_mod( 'wpmem_show_logged_out_state', false ) : false; @@ -125,8 +128,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { if ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) { $content = $wpmem->dialogs->login_failed(); } - $form_args = array( 'form'=>'login', 'redirect_to'=>$atts['redirect_to'], 'form_id'=>$atts['form_id'] ); - $content .= wpmem_login_form( $form_args ); + $content .= wpmem_login_form( array( 'redirect_to'=>$atts['redirect_to'], 'form_id'=>$atts['form_id'] ) ); } break; @@ -149,7 +151,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { $content = wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); $content .= wpmem_register_form( $reg_form_args ); } else { - $form_args = array( $form=>'login', 'redirect_to'=>$redirect_to, 'form_id'=>$form_id ); + $form_args = array( 'redirect_to'=>$redirect_to, 'form_id'=>$form_id ); if ( $wpmem->regchk == 'loginfailed' ) { $content = $wpmem->dialogs->login_failed() . wpmem_login_form( $form_args ); break; @@ -177,8 +179,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { break; case in_array( 'customizer_login', $atts ): - $form_args = array( $form=>'login', 'redirect_to'=>$redirect_to, 'form_id'=>$form_id ); - $content = wpmem_login_form( $form_args ); + $content = wpmem_login_form( array( 'redirect_to'=>$redirect_to, 'form_id'=>$form_id ) ); break; case in_array( 'customizer_register', $atts ): diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 1bb04d15..81cf5b58 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -910,7 +910,7 @@ function do_securify( $content = null ) { } // Block/unblock Posts. - if ( ! is_user_logged_in() && $this->is_blocked() == true ) { + if ( ! is_user_logged_in() && true == $this->is_blocked() ) { //Show the login and registration forms. if ( $this->regchk ) { @@ -941,10 +941,10 @@ function do_securify( $content = null ) { global $wp_query; if ( isset( $wp_query->query_vars['page'] ) && $wp_query->query_vars['page'] > 1 ) { - // Shuts down excerpts on multipage posts if not on first page. - $content = ''; + // Shuts down excerpts on multipage posts if not on first page. + $content = ''; - } elseif ( isset( $this->show_excerpt[ $post->post_type ] ) && $this->show_excerpt[ $post->post_type ] == 1 ) { + } elseif ( isset( $this->show_excerpt[ $post->post_type ] ) && 1 == $this->show_excerpt[ $post->post_type ] ) { $len = strpos( $content, 'forms->do_login_form( $page, $redirect_to, $show ); + return wpmem_login_form( 'login', array( 'redirect_to'=>$redirect_to ) ); //$wpmem->forms->do_login_form( $page, $redirect_to, $show ); } endif; From 9f65ae1c2eaaa939db744bd4a08dfa1666816c2f Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 2 Aug 2021 09:41:00 -0400 Subject: [PATCH 1439/1694] move settings dialog js from php to js file --- assets/js/admin.js | 32 ++++++++++++++++++- assets/js/admin.min.js | 2 +- includes/admin/class-wp-members-admin-api.php | 8 ++++- 3 files changed, 39 insertions(+), 3 deletions(-) diff --git a/assets/js/admin.js b/assets/js/admin.js index 935ebd06..5db2b3b5 100644 --- a/assets/js/admin.js +++ b/assets/js/admin.js @@ -224,4 +224,34 @@ } }); }); -})(jQuery); \ No newline at end of file +})(jQuery); + +/** + * Shows the WP-Members settings. + */ +(function($) { + $(document).ready(function($){ + var close_button = wpmem_get_settings_vars.close_btn; + $("#dialog-message" ).dialog({ + autoOpen: false, + modal: true, + height: "auto", + width: 600, + buttons: { + Close : function() { + $( this ).dialog( "close" ); + } + } + }); + $( "#opener" ).on( "click", function() { + $( "#dialog-message" ).dialog( "open" ); + }); + $("#select_all").click(function(){ + $("textarea").select(); + document.execCommand('copy'); + }); + $(window).resize(function() { + $("#dialog-message").dialog("option", "position", {my: "center", at: "center", of: window}); + }); + }); +})(jQuery); diff --git a/assets/js/admin.min.js b/assets/js/admin.min.js index caa6a407..22db8907 100644 --- a/assets/js/admin.min.js +++ b/assets/js/admin.min.js @@ -1 +1 @@ -jQuery(document).ready(function(e){e("#the-list").sortable({items:".list_item",opacity:.6,cursor:"move",axis:"y",update:function(){var m=e(this).sortable("serialize")+"&action=wpmem_do_field_reorder";e.post(ajaxurl,m,function(e){alert(e)}),e(".list_item").each(function(m){e(this).data("id",m+1),e(this).attr("list_item",m+1)})}})}),function(e){e(document).ready(function(){"use_custom"==e("#wpmem_logpage_select").val()?e("#wpmem_logpage_custom").show():e("#wpmem_logpage_custom").hide(),"use_custom"==e("#wpmem_regpage_select").val()?e("#wpmem_regpage_custom").show():e("#wpmem_regpage_custom").hide(),"use_custom"==e("#wpmem_mspage_select").val()?e("#wpmem_mspage_custom").show():e("#wpmem_mspage_custom").hide(),"use_custom"==e("#wpmem_stylesheet_select").val()?e("#wpmem_stylesheet_custom").show():e("#wpmem_stylesheet_custom").hide(),e("#wpmem_logpage_select").change(function(){"use_custom"==e("#wpmem_logpage_select").val()?e("#wpmem_logpage_custom").show():e("#wpmem_logpage_custom").hide()}),e("#wpmem_regpage_select").change(function(){"use_custom"==e("#wpmem_regpage_select").val()?e("#wpmem_regpage_custom").show():e("#wpmem_regpage_custom").hide()}),e("#wpmem_mspage_select").change(function(){"use_custom"==e("#wpmem_mspage_select").val()?e("#wpmem_mspage_custom").show():e("#wpmem_mspage_custom").hide()}),e("#wpmem_stylesheet_select").change(function(){"use_custom"==e("#wpmem_stylesheet_select").val()?e("#wpmem_stylesheet_custom").show():e("#wpmem_stylesheet_custom").hide()})})}(jQuery),function(e){e(document).ready(function(){e("#wpmem_allowhtml").hide(),e("#wpmem_rows_cols").hide(),e("#wpmem_min_max").hide(),e("#wpmem_checkbox_info").hide(),e("#wpmem_dropdown_info").hide(),e("#wpmem_file_info").hide(),e("#wpmem_delimiter_info").hide(),e("#wpmem_hidden_info").hide()}),e(document).ready(function(){e("#wpmem_field_type_select").change(function(){"text"==e("#wpmem_field_type_select").val()||"password"==e("#wpmem_field_type_select").val()||"email"==e("#wpmem_field_type_select").val()||"url"==e("#wpmem_field_type_select").val()||"number"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()||"textarea"==e("#wpmem_field_type_select").val()?e("#wpmem_placeholder").show():e("#wpmem_placeholder").hide(),"text"==e("#wpmem_field_type_select").val()||"password"==e("#wpmem_field_type_select").val()||"email"==e("#wpmem_field_type_select").val()||"url"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()?(e("#wpmem_pattern").show(),e("#wpmem_title").show()):(e("#wpmem_pattern").hide(),e("#wpmem_title").hide()),"textarea"==e("#wpmem_field_type_select").val()?(e("#wpmem_allowhtml").show(),e("#wpmem_rows_cols").show()):(e("#wpmem_allowhtml").hide(),e("#wpmem_rows_cols").hide()),"number"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()?e("#wpmem_min_max").show():e("#wpmem_min_max").hide(),"checkbox"==e("#wpmem_field_type_select").val()?(e("#wpmem_checkbox_info").show(),e("#add_checked_value").prop("required",!0)):(e("#wpmem_checkbox_info").hide(),e("#add_checked_value").prop("required",!1)),"select"==e("#wpmem_field_type_select").val()||"multiselect"==e("#wpmem_field_type_select").val()||"radio"==e("#wpmem_field_type_select").val()||"multicheckbox"==e("#wpmem_field_type_select").val()?(e("#wpmem_dropdown_info").show(),e("#add_dropdown_value").prop("required",!0)):(e("#wpmem_dropdown_info").hide(),e("#add_dropdown_value").prop("required",!1)),"multiselect"==e("#wpmem_field_type_select").val()||"multicheckbox"==e("#wpmem_field_type_select").val()?e("#wpmem_delimiter_info").show():e("#wpmem_delimiter_info").hide(),"file"==e("#wpmem_field_type_select").val()||"image"==e("#wpmem_field_type_select").val()?e("#wpmem_file_info").show():e("#wpmem_file_info").hide(),"hidden"==e("#wpmem_field_type_select").val()?(e("#wpmem_hidden_info").show(),e("#add_hidden_value").prop("required",!0)):(e("#wpmem_hidden_info").hide(),e("#add_hidden_value").prop("required",!1))})})}(jQuery),function(e){e(document).ready(function(){e("#wpmem_block").hide()}),e(document).ready(function(){e("#wpmem_edit_block_status").click(function(){e("#wpmem_block").show("normal"),e("#wpmem_edit_block_status").hide()}),e("#wpmem_cancel_block_status").click(function(){e("#wpmem_block").hide("normal"),e("#wpmem_edit_block_status").show(),e("#wpmem_post_block_status").text(e("input[name=wpmem_block_original_label]").val()),e("#wpmem_post_block_status_"+e("input[name=wpmem_block_original_value]")).val().prop("checked",!0)}),e("#wpmem_ok_block_status").click(function(){e("#wpmem_block").hide("normal"),e("#wpmem_edit_block_status").show(),e("#wpmem_post_block_status").text(e("input[name=wpmem_block]:checked + label").text()),e("#wpmem_block_status_0").is(":checked")&&(e("#wpmem_post_icon_0").show(),e("#wpmem_post_icon_1").hide(),e("#wpmem_post_icon_2").hide()),e("#wpmem_block_status_1").is(":checked")&&(e("#wpmem_post_icon_0").hide(),e("#wpmem_post_icon_1").show(),e("#wpmem_post_icon_2").hide()),e("#wpmem_block_status_2").is(":checked")&&(e("#wpmem_post_icon_0").hide(),e("#wpmem_post_icon_1").hide(),e("#wpmem_post_icon_2").show())})})}(jQuery); \ No newline at end of file +jQuery(document).ready(function(e){e("#the-list").sortable({items:".list_item",opacity:.6,cursor:"move",axis:"y",update:function(){var m=e(this).sortable("serialize")+"&action=wpmem_do_field_reorder";e.post(ajaxurl,m,function(e){alert(e)}),e(".list_item").each(function(m){e(this).data("id",m+1),e(this).attr("list_item",m+1)})}})}),function(e){e(document).ready(function(){"use_custom"==e("#wpmem_logpage_select").val()?e("#wpmem_logpage_custom").show():e("#wpmem_logpage_custom").hide(),"use_custom"==e("#wpmem_regpage_select").val()?e("#wpmem_regpage_custom").show():e("#wpmem_regpage_custom").hide(),"use_custom"==e("#wpmem_mspage_select").val()?e("#wpmem_mspage_custom").show():e("#wpmem_mspage_custom").hide(),"use_custom"==e("#wpmem_stylesheet_select").val()?e("#wpmem_stylesheet_custom").show():e("#wpmem_stylesheet_custom").hide(),e("#wpmem_logpage_select").change(function(){"use_custom"==e("#wpmem_logpage_select").val()?e("#wpmem_logpage_custom").show():e("#wpmem_logpage_custom").hide()}),e("#wpmem_regpage_select").change(function(){"use_custom"==e("#wpmem_regpage_select").val()?e("#wpmem_regpage_custom").show():e("#wpmem_regpage_custom").hide()}),e("#wpmem_mspage_select").change(function(){"use_custom"==e("#wpmem_mspage_select").val()?e("#wpmem_mspage_custom").show():e("#wpmem_mspage_custom").hide()}),e("#wpmem_stylesheet_select").change(function(){"use_custom"==e("#wpmem_stylesheet_select").val()?e("#wpmem_stylesheet_custom").show():e("#wpmem_stylesheet_custom").hide()})})}(jQuery),function(e){e(document).ready(function(){e("#wpmem_allowhtml").hide(),e("#wpmem_rows_cols").hide(),e("#wpmem_min_max").hide(),e("#wpmem_checkbox_info").hide(),e("#wpmem_dropdown_info").hide(),e("#wpmem_file_info").hide(),e("#wpmem_delimiter_info").hide(),e("#wpmem_hidden_info").hide()}),e(document).ready(function(){e("#wpmem_field_type_select").change(function(){"text"==e("#wpmem_field_type_select").val()||"password"==e("#wpmem_field_type_select").val()||"email"==e("#wpmem_field_type_select").val()||"url"==e("#wpmem_field_type_select").val()||"number"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()||"textarea"==e("#wpmem_field_type_select").val()?e("#wpmem_placeholder").show():e("#wpmem_placeholder").hide(),"text"==e("#wpmem_field_type_select").val()||"password"==e("#wpmem_field_type_select").val()||"email"==e("#wpmem_field_type_select").val()||"url"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()?(e("#wpmem_pattern").show(),e("#wpmem_title").show()):(e("#wpmem_pattern").hide(),e("#wpmem_title").hide()),"textarea"==e("#wpmem_field_type_select").val()?(e("#wpmem_allowhtml").show(),e("#wpmem_rows_cols").show()):(e("#wpmem_allowhtml").hide(),e("#wpmem_rows_cols").hide()),"number"==e("#wpmem_field_type_select").val()||"date"==e("#wpmem_field_type_select").val()?e("#wpmem_min_max").show():e("#wpmem_min_max").hide(),"checkbox"==e("#wpmem_field_type_select").val()?(e("#wpmem_checkbox_info").show(),e("#add_checked_value").prop("required",!0)):(e("#wpmem_checkbox_info").hide(),e("#add_checked_value").prop("required",!1)),"select"==e("#wpmem_field_type_select").val()||"multiselect"==e("#wpmem_field_type_select").val()||"radio"==e("#wpmem_field_type_select").val()||"multicheckbox"==e("#wpmem_field_type_select").val()?(e("#wpmem_dropdown_info").show(),e("#add_dropdown_value").prop("required",!0)):(e("#wpmem_dropdown_info").hide(),e("#add_dropdown_value").prop("required",!1)),"multiselect"==e("#wpmem_field_type_select").val()||"multicheckbox"==e("#wpmem_field_type_select").val()?e("#wpmem_delimiter_info").show():e("#wpmem_delimiter_info").hide(),"file"==e("#wpmem_field_type_select").val()||"image"==e("#wpmem_field_type_select").val()?e("#wpmem_file_info").show():e("#wpmem_file_info").hide(),"hidden"==e("#wpmem_field_type_select").val()?(e("#wpmem_hidden_info").show(),e("#add_hidden_value").prop("required",!0)):(e("#wpmem_hidden_info").hide(),e("#add_hidden_value").prop("required",!1))})})}(jQuery),function(e){e(document).ready(function(){e("#wpmem_block").hide()}),e(document).ready(function(){e("#wpmem_edit_block_status").click(function(){e("#wpmem_block").show("normal"),e("#wpmem_edit_block_status").hide()}),e("#wpmem_cancel_block_status").click(function(){e("#wpmem_block").hide("normal"),e("#wpmem_edit_block_status").show(),e("#wpmem_post_block_status").text(e("input[name=wpmem_block_original_label]").val()),e("#wpmem_post_block_status_"+e("input[name=wpmem_block_original_value]")).val().prop("checked",!0)}),e("#wpmem_ok_block_status").click(function(){e("#wpmem_block").hide("normal"),e("#wpmem_edit_block_status").show(),e("#wpmem_post_block_status").text(e("input[name=wpmem_block]:checked + label").text()),e("#wpmem_block_status_0").is(":checked")&&(e("#wpmem_post_icon_0").show(),e("#wpmem_post_icon_1").hide(),e("#wpmem_post_icon_2").hide()),e("#wpmem_block_status_1").is(":checked")&&(e("#wpmem_post_icon_0").hide(),e("#wpmem_post_icon_1").show(),e("#wpmem_post_icon_2").hide()),e("#wpmem_block_status_2").is(":checked")&&(e("#wpmem_post_icon_0").hide(),e("#wpmem_post_icon_1").hide(),e("#wpmem_post_icon_2").show())})})}(jQuery),jQuery(document).ready(function(e){wpmem_get_settings_vars.close_btn,e("#dialog-message").dialog({autoOpen:!1,modal:!0,height:"auto",width:600,buttons:{Close:function(){e(this).dialog("close")}}}),e("#opener").on("click",function(){e("#dialog-message").dialog("open")}),e("#select_all").click(function(){e("textarea").select(),document.execCommand("copy")}),e(window).resize(function(){e("#dialog-message").dialog("option","position",{my:"center",at:"center",of:window})})}); \ No newline at end of file diff --git a/includes/admin/class-wp-members-admin-api.php b/includes/admin/class-wp-members-admin-api.php index 5abc29b7..74185f18 100644 --- a/includes/admin/class-wp-members-admin-api.php +++ b/includes/admin/class-wp-members-admin-api.php @@ -573,7 +573,13 @@ function dashboard_enqueue_scripts( $hook ) { wp_enqueue_style( 'wpmem-admin', $wpmem->url . 'assets/css/admin' . wpmem_get_suffix() . '.css', '', $wpmem->version ); } if ( 'settings_page_wpmem-settings' == $hook || 'post.php' == $hook || 'post-new.php' == $hook ) { - wp_enqueue_script( 'wpmem-admin', $wpmem->url . 'assets/js/admin' . wpmem_get_suffix() . '.js', '', $wpmem->version ); + wp_enqueue_script( 'jquery-ui-dialog' ); // enqueue jQuery UI Dialog dependency + wp_register_script( 'wpmem-admin', $wpmem->url . 'assets/js/admin' . wpmem_get_suffix() . '.js', 'jquery', $wpmem->version, true ); + $translation_array = array( + 'close_btn' => __( 'Close', 'wp-members' ), + ); + wp_localize_script( 'wpmem-admin', 'wpmem_get_settings_vars', $translation_array ); + wp_enqueue_script( 'wpmem-admin' ); } if ( ( 'post.php' == $hook || 'post-new.php' == $hook ) && 1 == $wpmem->enable_products ) { if ( ! wp_script_is( 'select2', 'enqueued' ) ) { From 6eff267ea7853d0dcf1b8d40329257faaec54b6c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 2 Aug 2021 10:04:48 -0400 Subject: [PATCH 1440/1694] update with previous commit --- .../class-wp-members-admin-tab-options.php | 27 ------------------- 1 file changed, 27 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index 5562f39f..1318ab2d 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -324,33 +324,6 @@ static function build_settings() { -

    From 019d6d0cf3a395e756d274c239298ee9a44e5e02 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 3 Aug 2021 11:29:45 -0400 Subject: [PATCH 1441/1694] make membership products hierarchial --- includes/class-wp-members-user.php | 37 +++++++++++++++++++++++++++--- 1 file changed, 34 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 5e94fb49..f9a45792 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -873,13 +873,15 @@ function has_access( $product, $user_id = false ) { // Product must be an array. $product_array = ( ! is_array( $product ) ) ? array( $product ) : $product; + + $product_array = $this->get_product_children( $product_array ); + + // Current user or requested user. + $user_id = ( ! $user_id ) ? get_current_user_id() : $user_id; // Load user memberships array. $memberships = ( false == $user_id ) ? $this->access : wpmem_get_user_products( $user_id ); - // Current user or requested user. - $user_id = ( false === $user_id ) ? get_current_user_id() : $user_id; - // Start by assuming no access. $access = false; @@ -929,6 +931,35 @@ function has_access( $product, $user_id = false ) { } + /** + * Gets product children (if any). + * + * @since 3.4.0 + * + * @global stdClass $wpmem + * @param array $product_array + * $return array $product_array Product array with child products added. + */ + function get_product_children( $product_array ) { + + global $wpmem; + $membership_ids = array_flip( $wpmem->membership->product_by_id ); + foreach ( $product_array as $product ) { + $args = array( + 'post_type' => $wpmem->membership->post_type, + 'post_parent' => $membership_ids[ $product ], // Current post's ID + ); + $children = get_children( $args ); + if ( ! empty( $children ) ) { + foreach ( $children as $child ) { + $product_array[] = $child->post_name; + } + } + } + + return $product_array; + } + /** * Loads anything the user has access to. * From f1af754e73138e41ca1c920d006d08ab2ca0f883 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 3 Aug 2021 11:31:30 -0400 Subject: [PATCH 1442/1694] fixes bug in signon process that ignores rememberme option --- includes/class-wp-members-user.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index f9a45792..bace5f94 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -848,7 +848,7 @@ function set_password( $user_id, $password ) { function set_as_logged_in( $user_id ) { $user = get_user_by( 'id', $user_id ); wp_set_current_user( $user_id, $user->user_login ); - wp_set_auth_cookie( $user_id ); + wp_set_auth_cookie( $user_id, wpmem_get( 'rememberme', false, 'request' ) ); } /** From 5bb93f001eb9ce2635f2e6ba2fc0a3ecd4ace9ff Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 3 Aug 2021 11:32:21 -0400 Subject: [PATCH 1443/1694] adds html email as an option in the emails tab/functions --- includes/class-wp-members-email.php | 43 ++++++++++++++++++----------- 1 file changed, 27 insertions(+), 16 deletions(-) diff --git a/includes/class-wp-members-email.php b/includes/class-wp-members-email.php index cc17a46f..4f6873ef 100644 --- a/includes/class-wp-members-email.php +++ b/includes/class-wp-members-email.php @@ -67,6 +67,14 @@ class WP_Members_Email { function load_from() { $this->from = get_option( 'wpmembers_email_wpfrom', '' ); $this->from_name = get_option( 'wpmembers_email_wpname', '' ); + } + + /** + * Load plugin HTML email setting. + * + * @since 3.4.0 + */ + function load_format() { $this->html = get_option( 'wpmembers_email_html', 0 ); } @@ -97,8 +105,9 @@ function to_user( $user_id, $password, $tag, $wpmem_fields = null, $field_data = global $wpmem; - // Load from address. + // Load settings. $this->load_from(); + $this->load_format(); // Handle backward compatibility for customizations that may call the email function directly. $wpmem_fields = wpmem_fields(); @@ -512,13 +521,10 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { * @since 3.1.0 Converted to use email var in object. * @since 3.2.0 Moved to WP_Members_Email::from(). * - * @global object $wpmem - * * @param string $email * @return string $wpmem_mail_from|$email */ function from( $email ) { - global $wpmem; return ( $this->from ) ? $this->from : $email; } @@ -529,13 +535,10 @@ function from( $email ) { * @since 3.1.0 Converted to use email var in object. * @since 3.2.0 Moved to WP_Members_Email::from_name(). * - * @global object $wpmem - * * @param string $name * @return string $wpmem_mail_from_name|$name */ function from_name( $name ) { - global $wpmem; return ( $this->from_name ) ? stripslashes( $this->from_name ) : stripslashes( $name ); } @@ -546,8 +549,8 @@ function from_name( $name ) { * * @return string Always returns "text/html" */ - function html_content_type() { - return 'text/html'; + function content_type( $content_type ) { + return ( 1 == $this->html ) ? 'text/html' : $content_type; } /** @@ -574,13 +577,21 @@ function send( $to ) { * @param array $this->settings */ $args = apply_filters( 'wpmem_email_send_args', $args, $to, $this->settings ); - // Apply WP's "from" and "from name" email filters. - add_filter( 'wp_mail_from', array( $this, 'from' ) ); - add_filter( 'wp_mail_from_name', array( $this, 'from_name' ) ); - if ( 1 == $this->html ) { - add_filter( 'wp_mail_content_type', array( $this, 'html_content_type' ) ); - } - $result = wp_mail( $args['to'], stripslashes( $args['subject'] ), stripslashes( $args['message'] ), $args['headers'] ); + + // Apply filters. + add_filter( 'wp_mail_from', array( $this, 'from' ) ); + add_filter( 'wp_mail_from_name', array( $this, 'from_name' ) ); + add_filter( 'wp_mail_content_type', array( $this, 'content_type' ) ); + + // Send message. + $result = wp_mail( $args['to'], stripslashes( $args['subject'] ), stripslashes( $args['message'] ) ); + + // Remove customizations. + remove_filter( 'wp_mail_from', array( $this, 'from' ) ); + remove_filter( 'wp_mail_from_name', array( $this, 'from_name' ) ); + remove_filter( 'wp_mail_content_type', array( $this, 'content_type' ) ); + + // Return result (does not necessarily indicate message was sent). return $result; } } \ No newline at end of file From 23d7ea604caec7afe0c5bd09b54f54193b38894b Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 3 Aug 2021 11:34:12 -0400 Subject: [PATCH 1444/1694] remove return link from login failed message. --- includes/class-wp-members-dialogs.php | 28 +++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-dialogs.php b/includes/class-wp-members-dialogs.php index e6bfa40d..3713f1df 100644 --- a/includes/class-wp-members-dialogs.php +++ b/includes/class-wp-members-dialogs.php @@ -20,6 +20,19 @@ function __construct() { } + /** + * Returns a requested text string. + * + * This function manages all of the front-end facing text. + * All defaults can be filtered using wpmem_default_text_strings. + * + * @since 3.1.0 + * + * @global object $wpmem + * + * @param string $str + * @return string $text + */ function get_text( $str ) { global $wpmem; @@ -189,6 +202,17 @@ function get_text( $str ) { return $text[ $str ]; } + /** + * Login Failed Dialog. + * + * Returns the login failed error message. + * + * @since 1.8 + * @since 3.4.0 Removed "continue" (return) link (login form now displays by default under the error message). + * + * @global object $wpmem The WP_Members object. + * @return string $str The generated html for the login failed message. + */ function login_failed() { // Defaults. @@ -201,7 +225,7 @@ function login_failed() { 'p_before' => '

    ', 'message' => $this->get_text( 'login_failed' ), // @todo $this->error 'p_after' => '

    ', - 'link' => '' . $this->get_text( 'login_failed_link' ) . '', + //'link' => '' . $this->get_text( 'login_failed_link' ) . '', ); /** @@ -220,7 +244,7 @@ function login_failed() { $str = $args['div_before'] . $args['heading_before'] . $args['heading'] . $args['heading_after'] . $args['p_before'] . $args['message'] . $args['p_after'] - . $args['p_before'] . $args['link'] . $args['p_after'] + //. $args['p_before'] . $args['link'] . $args['p_after'] . $args['div_after']; /** From 7f297e22540cc3f32ab0cdf49e1673b3aadc2160 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 3 Aug 2021 11:35:02 -0400 Subject: [PATCH 1445/1694] update feature settings to disable in order to use legacy settings --- .../tabs/class-wp-members-admin-tab-options.php | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index 1318ab2d..9448b3dd 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -173,12 +173,14 @@ static function build_settings() { -

    +

    woo[ $row[3] ] : $wpmem->{$row[3]}; ?> -    +    +    + From 36b10b597d31eb0188ee60025320a45294bd46ae Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 3 Aug 2021 11:35:21 -0400 Subject: [PATCH 1446/1694] new default emails reflect default new feature settings --- includes/install.php | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/includes/install.php b/includes/install.php index 8aa1c873..a1f77db6 100644 --- a/includes/install.php +++ b/includes/install.php @@ -238,19 +238,12 @@ function wpmem_append_email() { // Email for a new registration. $subj = 'Your registration info for [blogname]'; - $body = 'Thank you for registering for [blogname] + $body = 'Thank you for registering for [blogname]! -Your registration information is below. -You may wish to retain a copy for your records. - -username: [username] -password: [password] +Please confirm your email address by following the link below: +[confirm_link] -You may log in here: -[reglink] - -You may change your password here: -[user-profile] +Once you have confirmed your email address, you will be able to log in using the credentials you created when you registered. '; $arr = array( @@ -312,11 +305,12 @@ function wpmem_append_email() { // Email for password reset. $subj = 'Your password reset for [blogname]'; - $body = 'Your password for [blogname] has been reset + $body = 'A password reset was requested for [blogname]. -Your new password is included below. You may wish to retain a copy for your records. +Follow the link below to reset your password: +[reset_link] -password: [password] +If you did not request a password reset for [blogname], simply ignore this message and the reset key will expire. '; $arr = array( From 914d4baf04662e4989162b4b5c21fd1a9403474c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 3 Aug 2021 11:42:12 -0400 Subject: [PATCH 1447/1694] replace $wpmem->get_text() / wpmem_gettext() with wpmem_get_text() --- includes/admin/dialogs.php | 2 +- includes/api/api-users.php | 4 +- includes/api/api.php | 9 ++-- includes/class-wp-members-captcha.php | 16 +++--- includes/class-wp-members-dialogs.php | 8 +-- includes/class-wp-members-forms.php | 57 +++++++++++----------- includes/class-wp-members-products.php | 4 +- includes/class-wp-members-pwd-reset.php | 4 +- includes/class-wp-members-shortcodes.php | 33 +++++++------ includes/class-wp-members-user-profile.php | 2 +- includes/class-wp-members-user.php | 20 ++++---- includes/class-wp-members.php | 2 +- includes/deprecated.php | 21 ++++++-- 13 files changed, 100 insertions(+), 82 deletions(-) diff --git a/includes/admin/dialogs.php b/includes/admin/dialogs.php index 6febd447..33ed6ccf 100644 --- a/includes/admin/dialogs.php +++ b/includes/admin/dialogs.php @@ -75,7 +75,7 @@ function wpmem_a_do_warnings( $did_update ) { } // Holding registrations but haven't changed default successful registration message. - if ( $warnings_on && $wpmem->mod_reg == 1 && $dialogs['success'] == $wpmem->get_text( 'success' ) ) { + if ( $warnings_on && $wpmem->mod_reg == 1 && $dialogs['success'] == wpmem_get_text( 'success' ) ) { wpmem_a_warning_msg( 'success' ); $warning_active = true; } diff --git a/includes/api/api-users.php b/includes/api/api-users.php index a9ab448b..0d9e0e07 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -657,7 +657,7 @@ function wpmem_user_register( $tag ) { exit(); } if ( in_array( 'user_email', $wpmem->fields ) && ! is_email( $wpmem->user->post_data['user_email']) ) { - $wpmem_themsg = $wpmem->get_text( 'reg_valid_email' ); + $wpmem_themsg = wpmem_get_text( 'reg_valid_email' ); return "updaterr"; exit(); } @@ -666,7 +666,7 @@ function wpmem_user_register( $tag ) { // If form includes email confirmation, validate that they match. if ( array_key_exists( 'confirm_email', $wpmem->user->post_data ) && $wpmem->user->post_data['confirm_email'] != $wpmem->user->post_data ['user_email'] ) { - $wpmem_themsg = $wpmem->get_text( 'reg_email_match' ); + $wpmem_themsg = wpmem_get_text( 'reg_email_match' ); return "updaterr"; exit(); } diff --git a/includes/api/api.php b/includes/api/api.php index ff47ed3b..c6e64783 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -203,20 +203,19 @@ function wpmem_current_post_id() { /** * Wrapper to return a string from the get_text function. * - * @since 3.1.1 - * @since 3.1.2 Added $echo argument. + * @since 3.4.0 * * @global object $wpmem The WP_Members object. * @param string $str The string to retrieve. * @param bool $echo Print the string (default: false). * @return string $str The localized string. */ -function wpmem_gettext( $str, $echo = false ) { +function wpmem_get_text( $str, $echo = false ) { global $wpmem; if ( $echo ) { - echo $wpmem->get_text( $str ); + echo $wpmem->dialogs->get_text( $str ); } else { - return $wpmem->get_text( $str ); + return $wpmem->dialogs->get_text( $str ); } } diff --git a/includes/class-wp-members-captcha.php b/includes/class-wp-members-captcha.php index 6b9a2497..4476fd06 100644 --- a/includes/class-wp-members-captcha.php +++ b/includes/class-wp-members-captcha.php @@ -216,13 +216,13 @@ static function rs_captcha( $return = 'string' ) { * @param array */ $rows = apply_filters( 'wpmem_rs_captcha_rows', array( - 'label_text' => $wpmem->get_text( 'register_rscaptcha' ), + 'label_text' => wpmem_get_text( 'register_rscaptcha' ), 'code_size' => esc_attr( $size ), 'prefix' => $pre, 'img_src' => esc_url( $src ), 'img_w' => esc_attr( $img_w ), 'img_h' => esc_attr( $img_h ), - 'label' => '', + 'label' => '', 'field' => '', 'hidden' => '', 'img' => 'captcha', @@ -290,7 +290,7 @@ static function validate( $which_captcha = false, $secret = false ) { // If there is no captcha value, return error. if ( false === $captcha ) { - $wpmem_themsg = $wpmem->get_text( 'reg_empty_captcha' ); + $wpmem_themsg = wpmem_get_text( 'reg_empty_captcha' ); return false; } @@ -307,7 +307,7 @@ static function validate( $which_captcha = false, $secret = false ) { if ( $response->success ) { // your success code goes here } else { - $wpmem_themsg = $wpmem->get_text( 'reg_invalid_captcha' ); + $wpmem_themsg = wpmem_get_text( 'reg_invalid_captcha' ); return false; } @@ -328,7 +328,7 @@ static function validate( $which_captcha = false, $secret = false ) { // If there is no captcha value, return error. if ( false === $captcha ) { - $wpmem_themsg = $wpmem->get_text( 'reg_empty_captcha' ); + $wpmem_themsg = wpmem_get_text( 'reg_empty_captcha' ); return false; } @@ -347,7 +347,7 @@ static function validate( $which_captcha = false, $secret = false ) { // If captcha validation was unsuccessful. if ( false == $response['success'] ) { - $wpmem_themsg = $wpmem->get_text( 'reg_invalid_captcha' ); + $wpmem_themsg = wpmem_get_text( 'reg_invalid_captcha' ); if ( WP_DEBUG && isset( $response['error-codes'] ) ) { $wpmem_themsg.= '

    '; foreach( $response['error-codes'] as $code ) { @@ -360,7 +360,7 @@ static function validate( $which_captcha = false, $secret = false ) { $captcha = wpmem_get( 'recaptcha_response', false ); if ( false === $captcha ) { - $wpmem_themsg = $wpmem->get_text( 'reg_empty_captcha' ); + $wpmem_themsg = wpmem_get_text( 'reg_empty_captcha' ); return false; } @@ -387,7 +387,7 @@ static function validate( $which_captcha = false, $secret = false ) { if ( $recaptcha->score >= $score ) { return true; } else { - $wpmem_themsg = $wpmem->get_text( 'reg_invalid_captcha' ); + $wpmem_themsg = wpmem_get_text( 'reg_invalid_captcha' ); return false; } } else { diff --git a/includes/class-wp-members-dialogs.php b/includes/class-wp-members-dialogs.php index 3713f1df..80f17dff 100644 --- a/includes/class-wp-members-dialogs.php +++ b/includes/class-wp-members-dialogs.php @@ -220,12 +220,12 @@ function login_failed() { 'div_before' => '
    ', 'div_after' => '
    ', 'heading_before' => '

    ', - 'heading' => $this->get_text( 'login_failed_heading' ), + 'heading' => wpmem_get_text( 'login_failed_heading' ), 'heading_after' => '

    ', 'p_before' => '

    ', - 'message' => $this->get_text( 'login_failed' ), // @todo $this->error + 'message' => wpmem_get_text( 'login_failed' ), // @todo $this->error 'p_after' => '

    ', - //'link' => '' . $this->get_text( 'login_failed_link' ) . '', + //'link' => '' . wpmem_get_text( 'login_failed_link' ) . '', ); /** @@ -297,7 +297,7 @@ function message( $tag, $custom ) { if ( is_array( $dialogs[ $tag ] ) ) { $msg = stripslashes( $dialogs[ $tag ]['value'] ); } else { - $msg = $this->get_text( $tag ); + $msg = wpmem_get_text( $tag ); $msg = ( $dialogs[ $tag ] == $msg ) ? $msg : __( stripslashes( $dialogs[ $tag ] ), 'wp-members' ); } } diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 15924a41..6a98ef6f 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -446,7 +446,7 @@ function create_form_label( $args ) { $required = ( isset( $args['required'] ) ) ? $args['required'] : false; $req_mark = ( isset( $args['req_mark'] ) ) ? $args['req_mark'] : false; - //$req_mark = ( ! $req_mark ) ? $wpmem->get_text( 'register_req_mark' ) : '*'; + //$req_mark = ( ! $req_mark ) ? wpmem_get_text( 'register_req_mark' ) : '*'; if ( ! $class ) { $class = ( $type == 'password' || $type == 'email' || $type == 'url' ) ? 'text' : $type; @@ -871,7 +871,7 @@ function login_form( $mixed, $arr = array() ) { // Build the buttons, filter, and add to the form. if ( $action == 'login' ) { - $args['remember_check'] = ( $args['remember_check'] ) ? $args['t'] . wpmem_create_formfield( 'rememberme', 'checkbox', 'forever' ) . ' ' . '  ' . $args['n'] : ''; + $args['remember_check'] = ( $args['remember_check'] ) ? $args['t'] . wpmem_create_formfield( 'rememberme', 'checkbox', 'forever' ) . ' ' . '  ' . $args['n'] : ''; $buttons = $args['remember_check'] . $args['t'] . '' . $args['n']; } else { $buttons = '' . $args['n']; @@ -923,7 +923,7 @@ function login_form( $mixed, $arr = array() ) { * @param string $tag forgot|reg|pwdreset|username. */ $link = apply_filters( "wpmem_{$tag}_link", $value['link'], $tag ); - $str = $wpmem->get_text( "{$key}_link_before" ) . '' . $wpmem->get_text( "{$key}_link" ) . ''; + $str = wpmem_get_text( "{$key}_link_before" ) . '' . wpmem_get_text( "{$key}_link" ) . ''; $link_str = $args['link_before']; $link_str.= ( '' != $args['link_span_before'] ) ? sprintf( $args['link_span_before'], $key ) : ''; /** @@ -1081,16 +1081,16 @@ function register_form( $mixed = 'new', $redirect_to = null ) { 'button_class' => 'buttons', // Required field tags and text. - 'req_mark' => $wpmem->get_text( 'register_req_mark' ), - 'req_label' => $wpmem->get_text( 'register_required' ), + 'req_mark' => wpmem_get_text( 'register_req_mark' ), + 'req_label' => wpmem_get_text( 'register_required' ), 'req_label_before' => '
    ', 'req_label_after' => '
    ', // Buttons. 'show_clear_form' => false, - 'clear_form' => $wpmem->get_text( 'register_clear' ), - 'submit_register' => $wpmem->get_text( 'register_submit' ), - 'submit_update' => $wpmem->get_text( 'profile_submit' ), + 'clear_form' => wpmem_get_text( 'register_clear' ), + 'submit_register' => wpmem_get_text( 'register_submit' ), + 'submit_update' => wpmem_get_text( 'profile_submit' ), // Other. 'post_to' => get_permalink(), @@ -1294,7 +1294,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { } else { $input = ( $attachment_url ) ? '' : $empty_file; } - $input.= '
    ' . $wpmem->get_text( 'profile_upload' ) . '
    '; + $input.= '
    ' . wpmem_get_text( 'profile_upload' ) . '
    '; } else { if ( 'image' == $field['type'] ) { $input = ''; @@ -1559,7 +1559,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { * * @param string The default edit mode heading. */ - $heading = ( isset( $heading ) && '' != $heading ) ? $heading : apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); + $heading = ( isset( $heading ) && '' != $heading ) ? $heading : apply_filters( 'wpmem_user_edit_heading', wpmem_get_text( 'profile_heading' ) ); } else { /** * Filter the registration form heading. @@ -1569,7 +1569,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { * @param string $str * @param string $tag Toggle new registration or profile update. new|edit. */ - $heading = ( isset( $heading ) && '' != $heading ) ? $heading : apply_filters( 'wpmem_register_heading', $wpmem->get_text( 'register_heading' ), $tag ); + $heading = ( isset( $heading ) && '' != $heading ) ? $heading : apply_filters( 'wpmem_register_heading', wpmem_get_text( 'register_heading' ), $tag ); } $form = $args['heading_before'] . $heading . $args['heading_after'] . $args['n'] . $form; @@ -2021,6 +2021,7 @@ function attribution() { * the short forms, combined into a single method. * * @since 3.3.0 + * @since 3.4.0 Change inputs. * * @global stdClass $post * @global stdClass $wpmem @@ -2036,14 +2037,14 @@ function do_shortform( $form, $args = array() ) { $input_arrays = array( 'login' => array( array( - 'name' => $wpmem->get_text( 'login_username' ), + 'name' => wpmem_get_text( 'login_username' ), 'type' => 'text', 'tag' => 'log', 'class' => 'username', 'div' => 'div_text', ), array( - 'name' => $wpmem->get_text( 'login_password' ), + 'name' => wpmem_get_text( 'login_password' ), 'type' => 'password', 'tag' => 'pwd', 'class' => 'password', @@ -2052,14 +2053,14 @@ function do_shortform( $form, $args = array() ) { ), 'changepassword' => array( array( - 'name' => $wpmem->get_text( 'pwdchg_password1' ), + 'name' => wpmem_get_text( 'pwdchg_password1' ), 'type' => 'password', 'tag' => 'pass1', 'class' => 'password', 'div' => 'div_text', ), array( - 'name' => $wpmem->get_text( 'pwdchg_password2' ), + 'name' => wpmem_get_text( 'pwdchg_password2' ), 'type' => 'password', 'tag' => 'pass2', 'class' => 'password', @@ -2068,14 +2069,14 @@ function do_shortform( $form, $args = array() ) { ), 'resetpassword' => array( array( - 'name' => $wpmem->get_text( 'pwdreset_username' ), + 'name' => wpmem_get_text( 'pwdreset_username' ), 'type' => 'text', 'tag' => 'user', 'class' => 'username', 'div' => 'div_text', ), array( - 'name' => $wpmem->get_text( 'pwdreset_email' ), + 'name' => wpmem_get_text( 'pwdreset_email' ), 'type' => 'text', 'tag' => 'email', 'class' => 'textbox', @@ -2084,7 +2085,7 @@ function do_shortform( $form, $args = array() ) { ), 'forgotusername' => array( array( - 'name' => $wpmem->get_text( 'username_email' ), + 'name' => wpmem_get_text( 'username_email' ), 'type' => 'text', 'tag' => 'user_email', 'class' => 'username', @@ -2105,28 +2106,28 @@ function do_shortform( $form, $args = array() ) { $form_arrays = array( 'login' => array( - 'heading' => $wpmem->get_text( 'login_heading' ), + 'heading' => wpmem_get_text( 'login_heading' ), 'action' => 'login', - 'button_text' => $wpmem->get_text( 'login_button' ), + 'button_text' => wpmem_get_text( 'login_button' ), 'inputs' => $default_inputs, 'redirect_to' => $args['redirect_to'], ), 'changepassword' => array( - 'heading' => $wpmem->get_text( 'pwdchg_heading' ), + 'heading' => wpmem_get_text( 'pwdchg_heading' ), 'action' => 'pwdchange', - 'button_text' => $wpmem->get_text( 'pwdchg_button' ), + 'button_text' => wpmem_get_text( 'pwdchg_button' ), 'inputs' => $default_inputs, ), 'resetpassword' => array( - 'heading' => $wpmem->get_text( 'pwdreset_heading' ), + 'heading' => wpmem_get_text( 'pwdreset_heading' ), 'action' => 'pwdreset', - 'button_text' => $wpmem->get_text( 'pwdreset_button' ), + 'button_text' => wpmem_get_text( 'pwdreset_button' ), 'inputs' => $default_inputs, ), 'forgotusername' => array( - 'heading' => $wpmem->get_text( 'username_heading' ), + 'heading' => wpmem_get_text( 'username_heading' ), 'action' => 'getusername', - 'button_text' => $wpmem->get_text( 'username_button' ), + 'button_text' => wpmem_get_text( 'username_button' ), 'inputs' => $default_inputs, ), ); @@ -2174,7 +2175,7 @@ public function add_restricted_msg() { $dialogs = get_option( 'wpmembers_dialogs' ); // This shown above blocked content. - $msg = $wpmem->get_text( 'restricted_msg' ); + $msg = wpmem_get_text( 'restricted_msg' ); $msg = ( $dialogs['restricted_msg'] == $msg ) ? $msg : __( stripslashes( $dialogs['restricted_msg'] ), 'wp-members' ); $str = '

    ' . $msg . '

    '; @@ -2244,7 +2245,7 @@ function get_tos_link( $field, $tag = 'new' ) { * @param string The link text. * @param string $tag Toggle new registration or profile update. new|edit. */ - $tos_link_text = apply_filters( 'wpmem_tos_link_txt', $wpmem->get_text( 'register_tos' ), $tag ); + $tos_link_text = apply_filters( 'wpmem_tos_link_txt', wpmem_get_text( 'register_tos' ), $tag ); // If filtered value is not the default label, use that, otherwise use label. // @note: if default changes, this check must change. diff --git a/includes/class-wp-members-products.php b/includes/class-wp-members-products.php index 8f1e6d2d..e78be639 100644 --- a/includes/class-wp-members-products.php +++ b/includes/class-wp-members-products.php @@ -213,10 +213,10 @@ function product_access( $content ) { // Singular message if post only has one membership, otherwise multiple. if ( 1 == count( $post_products ) ) { - $message = $wpmem->get_text( 'product_restricted_single' ) + $message = wpmem_get_text( 'product_restricted_single' ) . "
    " . $this->products[ $post_products[0] ]['title']; } else { - $message = $wpmem->get_text( 'product_restricted_multiple' ) . "
    "; + $message = wpmem_get_text( 'product_restricted_multiple' ) . "
    "; foreach ( $post_products as $post_product ) { $message .= $this->products[ $post_product ]['title'] . "
    "; } diff --git a/includes/class-wp-members-pwd-reset.php b/includes/class-wp-members-pwd-reset.php index 56006c7f..d71eacb9 100644 --- a/includes/class-wp-members-pwd-reset.php +++ b/includes/class-wp-members-pwd-reset.php @@ -155,7 +155,7 @@ function display_content( $content ) { // Verify nonce. if ( ! wp_verify_nonce( $_REQUEST['_wpmem_pwdchange_nonce'], 'wpmem_shortform_nonce' ) ) { - $errors->add( 'reg_generic', $wpmem->get_text( 'reg_generic' ) ); + $errors->add( 'reg_generic', wpmem_get_text( 'reg_generic' ) ); } // Make sure submitted passwords match. @@ -282,7 +282,7 @@ function change_regchk( $regchk, $action ) { */ function reset_password_form( $args ) { global $wpmem; - $args['inputs'][0]['name'] = $wpmem->get_text( 'login_username' ); + $args['inputs'][0]['name'] = wpmem_get_text( 'login_username' ); unset( $args['inputs'][1] ); return $args; } diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index a529d7e7..d76c0af8 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -159,7 +159,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { // @todo Can this be moved into another function? Should $wpmem get an error message handler? if ( $wpmem->regchk == 'captcha' ) { global $wpmem_captcha_err; - $wpmem_themsg = __( 'There was an error with the CAPTCHA form.' ) . '

    ' . $wpmem_captcha_err; + $wpmem_themsg = wpmem_get_text( 'reg_captcha_err' ) . '

    ' . $wpmem_captcha_err; } $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_display_message( $wpmem->regchk, $wpmem_themsg ) : ''; $content .= ( $wpmem->regchk == 'success' ) ? wpmem_login_form( $form_args ) : wpmem_register_form( $reg_form_args ); @@ -324,7 +324,7 @@ function logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) { $do_return = true; $settings = array( 'wrapper_before' => '
    ', - 'msg' => sprintf( $wpmem->get_text( 'product_restricted' ), $wpmem->membership->products[ $membership ]['title'] ), + 'msg' => sprintf( wpmem_get_text( 'product_restricted' ), $wpmem->membership->products[ $membership ]['title'] ), 'wrapper_after' => '
    ', ); /** @@ -444,7 +444,7 @@ function user_profile( $atts, $content, $tag ) { if ( $wpmem->regchk == "captcha" ) { global $wpmem_captcha_err; - $wpmem_themsg = $wpmem->get_text( 'reg_captcha_err' ) . '

    ' . $wpmem_captcha_err; + $wpmem_themsg = wpmem_get_text( 'reg_captcha_err' ) . '

    ' . $wpmem_captcha_err; } if ( $wpmem->regchk == "loginfailed" ) { @@ -877,7 +877,7 @@ function render_pwd_reset( $wpmem_regchk, $content ) { default: if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { - $content .= wpmem_display_message( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); + $content .= wpmem_display_message( $wpmem_regchk, wpmem_get_text( $wpmem_regchk ) ); } $content = $content . wpmem_change_password_form(); break; @@ -901,7 +901,7 @@ function render_pwd_reset( $wpmem_regchk, $content ) { default: if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { - $content = wpmem_display_message( $wpmem_regchk, $wpmem->get_text( $wpmem_regchk ) ); + $content = wpmem_display_message( $wpmem_regchk, wpmem_get_text( $wpmem_regchk ) ); } $content = $content . wpmem_reset_password_form(); break; @@ -939,7 +939,7 @@ function render_user_edit( $wpmem_regchk, $content, $atts = false ) { * * @param string The default edit mode heading. */ - $heading = apply_filters( 'wpmem_user_edit_heading', $wpmem->get_text( 'profile_heading' ) ); + $heading = apply_filters( 'wpmem_user_edit_heading', wpmem_get_text( 'profile_heading' ) ); if ( $wpmem_a == "update") { $content.= wpmem_display_message( $wpmem_regchk, $wpmem_themsg ); @@ -976,7 +976,7 @@ function render_forgot_username( $wpmem_regchk, $content ) { switch( $wpmem->regchk ) { case "usernamefailed": - $msg = $wpmem->get_text( 'usernamefailed' ); + $msg = wpmem_get_text( 'usernamefailed' ); $content = $content . wpmem_display_message( 'usernamefailed', $msg ) . wpmem_forgot_username_form(); @@ -985,7 +985,7 @@ function render_forgot_username( $wpmem_regchk, $content ) { case "usernamesuccess": $email = ( isset( $_POST['user_email'] ) ) ? sanitize_email( $_POST['user_email'] ) : ''; - $msg = sprintf( $wpmem->get_text( 'usernamesuccess' ), $email ); + $msg = sprintf( wpmem_get_text( 'usernamesuccess' ), $email ); $content = $content . wpmem_display_message( 'usernamesuccess', $msg ); $wpmem->regchk = ''; // Clear regchk. break; @@ -1026,13 +1026,14 @@ function render_links( $page = 'member' ) { $url = ( isset( $wpmem->user_pages['profile'] ) && '' != $wpmem->user_pages['profile'] ) ? $wpmem->user_pages['profile'] : get_option( 'home' ); + // NOTE: DO NOT EDIT THESE. Use the filter below. $arr = array( - 'before_wrapper' => '

    ' . sprintf( $wpmem->get_text( 'register_status' ), $user_login ) . '

    ', + 'before_wrapper' => '

    ' . sprintf( wpmem_get_text( 'register_status' ), $user_login ) . '

    ', 'wrapper_before' => '', 'rows' => array( - '
  • ' . $wpmem->get_text( 'register_logout' ) . '
  • ', - '
  • ' . $wpmem->get_text( 'register_continue' ) . '
  • ', + '
  • ' . wpmem_get_text( 'register_logout' ) . '
  • ', + '
  • ' . wpmem_get_text( 'register_continue' ) . '
  • ', ), 'after_wrapper' => '', ); @@ -1076,12 +1077,13 @@ function render_links( $page = 'member' ) { case 'login': $logout = urldecode( $logout ); // @todo Resolves sprintf issue if url is encoded. + // NOTE: DO NOT EDIT. Use the filter below. $args = array( 'wrapper_before' => '', 'user_login' => $user_login, - 'welcome' => $wpmem->get_text( 'login_welcome' ), - 'logout_text' => $wpmem->get_text( 'login_logout' ), + 'welcome' => wpmem_get_text( 'login_welcome' ), + 'logout_text' => wpmem_get_text( 'login_logout' ), 'logout_link' => '%s', 'separator' => '
    ', ); @@ -1124,13 +1126,14 @@ function render_links( $page = 'member' ) { case 'member': default: + // NOTE: DO NOT EDIT. Use the filter below. $arr = array( 'before_wrapper' => '', 'wrapper_before' => '
      ', 'wrapper_after' => '
    ', 'rows' => array( - '
  • ' . $wpmem->get_text( 'profile_edit' ) . '
  • ', - '
  • ' . $wpmem->get_text( 'profile_password' ) . '
  • ', + '
  • ' . wpmem_get_text( 'profile_edit' ) . '
  • ', + '
  • ' . wpmem_get_text( 'profile_password' ) . '
  • ', ), 'after_wrapper' => '', ); diff --git a/includes/class-wp-members-user-profile.php b/includes/class-wp-members-user-profile.php index 353f978b..91246587 100644 --- a/includes/class-wp-members-user-profile.php +++ b/includes/class-wp-members-user-profile.php @@ -142,7 +142,7 @@ static function profile( $user_obj ) { $input = ( $attachment_url ) ? $attachment_url : $empty_file; } } - $input.= '
    ' . $wpmem->get_text( 'profile_upload' ) . '
    '; + $input.= '
    ' . wpmem_get_text( 'profile_upload' ) . '
    '; $input.= wpmem_form_field( array( 'name' => $meta, 'type' => $field['type'], diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index bace5f94..0215c221 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -281,14 +281,14 @@ function register_validate( $tag ) { if ( 'register' == $tag ) { // If the required field is a file type. if ( empty( $_FILES[ $meta_key ]['name'] ) ) { - $wpmem_themsg = sprintf( $wpmem->get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ); + $wpmem_themsg = sprintf( wpmem_get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ); } } } else { // If the required field is any other field type. if ( ( 'register' == $tag && true == $field['register'] ) || ( 'update' == $tag && true == $field['profile'] ) ) { if ( null == $this->post_data[ $meta_key ] ) { - $wpmem_themsg = sprintf( $wpmem->get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ); + $wpmem_themsg = sprintf( wpmem_get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ); } } } @@ -304,7 +304,7 @@ function register_validate( $tag ) { if ( ! empty( $_FILES[ $meta_key ]['name'] ) ) { $extension = pathinfo( $_FILES[ $meta_key ]['name'], PATHINFO_EXTENSION ); if ( ! in_array( $extension, $allowed_file_types ) ) { - $wpmem_themsg = sprintf( $wpmem->get_text( 'reg_file_type' ), __( $field['label'], 'wp-members' ), str_replace( '|', ',', $msg_types ) ); + $wpmem_themsg = sprintf( wpmem_get_text( 'reg_file_type' ), __( $field['label'], 'wp-members' ), str_replace( '|', ',', $msg_types ) ); } } } @@ -325,9 +325,9 @@ function register_validate( $tag ) { // Validate username and email fields. $wpmem_themsg = ( email_exists( $this->post_data['user_email'] ) ) ? "email" : $wpmem_themsg; $wpmem_themsg = ( username_exists( $this->post_data['username'] ) ) ? "user" : $wpmem_themsg; - $wpmem_themsg = ( ! is_email( $this->post_data['user_email']) ) ? $wpmem->get_text( 'reg_valid_email' ) : $wpmem_themsg; - $wpmem_themsg = ( ! validate_username( $this->post_data['username'] ) ) ? $wpmem->get_text( 'reg_non_alphanumeric' ) : $wpmem_themsg; - $wpmem_themsg = ( ! $this->post_data['username'] ) ? $wpmem->get_text( 'reg_empty_username' ) : $wpmem_themsg; + $wpmem_themsg = ( ! is_email( $this->post_data['user_email']) ) ? wpmem_get_text( 'reg_valid_email' ) : $wpmem_themsg; + $wpmem_themsg = ( ! validate_username( $this->post_data['username'] ) ) ? wpmem_get_text( 'reg_non_alphanumeric' ) : $wpmem_themsg; + $wpmem_themsg = ( ! $this->post_data['username'] ) ? wpmem_get_text( 'reg_empty_username' ) : $wpmem_themsg; // If there is an error from username, email, or required field validation, stop registration and return the error. if ( $wpmem_themsg ) { @@ -338,10 +338,10 @@ function register_validate( $tag ) { // If form contains password and email confirmation, validate that they match. if ( array_key_exists( 'confirm_password', $this->post_data ) && $this->post_data['confirm_password'] != $this->post_data ['password'] ) { - $wpmem_themsg = $wpmem->get_text( 'reg_password_match' ); + $wpmem_themsg = wpmem_get_text( 'reg_password_match' ); } if ( array_key_exists( 'confirm_email', $this->post_data ) && $this->post_data['confirm_email'] != $this->post_data ['user_email'] ) { - $wpmem_themsg = $wpmem->get_text( 'reg_email_match' ); + $wpmem_themsg = wpmem_get_text( 'reg_email_match' ); } // Process CAPTCHA. @@ -402,7 +402,7 @@ function wp_register_validate( $errors, $sanitized_user_login, $user_email ) { $is_error = true; } if ( $is_error ) { - $errors->add( 'wpmem_error', sprintf( $wpmem->get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ) ); + $errors->add( 'wpmem_error', sprintf( wpmem_get_text( 'reg_empty_field' ), __( $field['label'], 'wp-members' ) ) ); } } } @@ -411,7 +411,7 @@ function wp_register_validate( $errors, $sanitized_user_login, $user_email ) { if ( $wpmem->captcha > 0 ) { $check_captcha = WP_Members_Captcha::validate(); if ( false === $check_captcha ) { - $errors->add( 'wpmem_captcha_error', sprintf( $wpmem->get_text( 'reg_captcha_err' ), __( $field['label'], 'wp-members' ) ) ); + $errors->add( 'wpmem_captcha_error', sprintf( wpmem_get_text( 'reg_captcha_err' ), __( $field['label'], 'wp-members' ) ) ); } } diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 81cf5b58..2cb76088 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -906,7 +906,7 @@ function do_securify( $content = null ) { if ( $this->regchk == "captcha" ) { global $wpmem_captcha_err; - $wpmem_themsg = $wpmem->get_text( 'reg_captcha_err' ) . '

    ' . $wpmem_captcha_err; + $wpmem_themsg = wpmem_get_text( 'reg_captcha_err' ) . '

    ' . $wpmem_captcha_err; } // Block/unblock Posts. diff --git a/includes/deprecated.php b/includes/deprecated.php index d95107b1..ee3e03b2 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -60,8 +60,8 @@ function wpmem_inc_status() { /** This filter is documented in wp-members/inc/dialogs.php */ $logout = apply_filters( 'wpmem_logout_link', $url . '/?a=logout' ); - $status = '

    ' . sprintf( $wpmem->get_text( 'sb_login_status' ), $user_login ) - . ' | ' . $wpmem->get_text( 'sb_logout_link' ) . '

    '; + $status = '

    ' . sprintf( wpmem_get_text( 'sb_login_status' ), $user_login ) + . ' | ' . wpmem_get_text( 'sb_logout_link' ) . '

    '; return $status; } @@ -612,4 +612,19 @@ function wpmem_inc_memberlinks( $page = 'member' ) { } return $str; } -endif; \ No newline at end of file +endif; + +/** + * Wrapper to return a string from the get_text function. + * + * @since 3.1.1 + * @since 3.1.2 Added $echo argument. + * @depreacted 3.4.0 Use wpmem_get_text() instead. + * + * @param string $str The string to retrieve. + * @param bool $echo Print the string (default: false). + * @return string $str The localized string. + */ +function wpmem_gettext( $str, $echo = false ) { + return wpmem_get_text( $str, $echo ); +} \ No newline at end of file From 012208bb50d078183f42f41a7aa1dc9e94072277 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 14 Aug 2021 09:27:22 -0400 Subject: [PATCH 1448/1694] use wpmem_form_field() instead of deprecated functions --- .../class-wp-members-admin-tab-captcha.php | 2 +- .../class-wp-members-admin-tab-fields.php | 12 ++--- .../class-wp-members-admin-tab-options.php | 18 +++---- includes/class-wp-members-forms.php | 53 +++++++++++-------- includes/class-wp-members-pwd-reset.php | 4 +- 5 files changed, 49 insertions(+), 40 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php index c5354a45..d0e6647f 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php @@ -97,7 +97,7 @@ public static function build_settings() { $captcha[] = __( 'reCAPTCHA v3', 'wp-members' ) . '|4'; $captcha[] = __( 'Really Simple CAPTCHA', 'wp-members' ) . '|2'; $captcha[] = __( 'hCaptcha', 'wp-members' ) . '|5'; - echo wpmem_create_formfield( 'wpmem_settings_captcha', 'select', $captcha, $wpmem->captcha ); ?> + echo wpmem_form_field( 'wpmem_settings_captcha', 'select', $captcha, $wpmem->captcha ); ?> diff --git a/includes/admin/tabs/class-wp-members-admin-tab-fields.php b/includes/admin/tabs/class-wp-members-admin-tab-fields.php index 516f1085..53db11d6 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-fields.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-fields.php @@ -438,11 +438,11 @@ public static function build_field_table() { 'label' => $field[1], 'meta' => $meta, 'type' => $field[3], - 'display' => ( 'user_email' != $meta && 'username' != $meta ) ? wpmem_create_formfield( $meta . "_display", 'checkbox', 'y', $field[4] ) : '', - 'req' => ( 'user_email' != $meta && 'username' != $meta ) ? wpmem_create_formfield( $meta . "_required", 'checkbox', 'y', $field[5] ) : '', - 'profile' => ( 'user_email' != $meta && 'username' != $meta ) ? wpmem_create_formfield( $meta . "_profile", 'checkbox', 'y', $profile ) : '', - 'userscrn' => ( ! in_array( $meta, $wpmem_ut_fields_skip ) ) ? wpmem_create_formfield( 'ut_fields[' . $meta . ']', 'checkbox', $field[1], $ut_checked ) : '', - 'usearch' => ( ! in_array( $meta, $wpmem_us_fields_skip ) ) ? wpmem_create_formfield( 'us_fields[' . $meta . ']', 'checkbox', $field[1], $us_checked ) : '', + 'display' => ( 'user_email' != $meta && 'username' != $meta ) ? wpmem_form_field( $meta . "_display", 'checkbox', 'y', $field[4] ) : '', + 'req' => ( 'user_email' != $meta && 'username' != $meta ) ? wpmem_form_field( $meta . "_required", 'checkbox', 'y', $field[5] ) : '', + 'profile' => ( 'user_email' != $meta && 'username' != $meta ) ? wpmem_form_field( $meta . "_profile", 'checkbox', 'y', $profile ) : '', + 'userscrn' => ( ! in_array( $meta, $wpmem_ut_fields_skip ) ) ? wpmem_form_field( 'ut_fields[' . $meta . ']', 'checkbox', $field[1], $ut_checked ) : '', + 'usearch' => ( ! in_array( $meta, $wpmem_us_fields_skip ) ) ? wpmem_form_field( 'us_fields[' . $meta . ']', 'checkbox', $field[1], $us_checked ) : '', 'edit' => self::do_edit_link( $meta ), 'sort' => '', ); @@ -468,7 +468,7 @@ public static function build_field_table() { || ( 'active' == $key && 1 == $wpmem->mod_reg ) || defined( 'WPMEM_EXP_MODULE' ) && $wpmem->use_exp == 1 && ( 'exp_type' == $key || 'expires' == $key ) ) { $user_screen_items[ $key ] = array( 'label' => __( $item, 'wp-members' ), 'meta' => $key, - 'userscrn' => wpmem_create_formfield( "ut_fields[{$key}]", 'checkbox', $item, $ut_checked ), + 'userscrn' => wpmem_form_field( "ut_fields[{$key}]", 'checkbox', $item, $ut_checked ), ); } } diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index 9448b3dd..efdabed4 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -110,7 +110,7 @@ static function build_settings() { __( 'Block', 'wp-members' ) . '|1', // @todo Future development. __( 'Hide', 'wp-members' ) . '|2', ); - echo wpmem_create_formfield( 'wpmem_block_' . $key, 'select', $values, $block ); ?> + echo wpmem_form_field( 'wpmem_block_' . $key, 'select', $values, $block ); ?>      + echo wpmem_form_field( 'wpmem_' . $item_key . '_' . $key, 'checkbox', '1', $setting ); ?>           {$item_key}[ $key ] ) ) ? $wpmem->{$item_key}[ $key ] : 0; - echo wpmem_create_formfield( 'wpmem_' . $item_key . '_' . $key, 'checkbox', '1', $setting ); ?> + echo wpmem_form_field( 'wpmem_' . $item_key . '_' . $key, 'checkbox', '1', $setting ); ?>
  • - {$row[3]} ); ?>   + {$row[3]} ); ?>  
  • woo[ $row[3] ] : $wpmem->{$row[3]}; ?>    + echo wpmem_form_field( $row[1], 'checkbox', '0', $checkbox_value ); ?>      + echo wpmem_form_field( $row[1], 'checkbox', '1', $checkbox_value ); ?>   @@ -216,13 +216,13 @@ static function build_settings() { foreach ( $rows as $row ) { ?>
  • - {$row[3]} ); ?>   + {$row[3]} ); ?>  
  • - attrib ); ?>   + attrib ); ?>  
  • @@ -235,7 +235,7 @@ static function build_settings() { $captcha[] = __( 'reCAPTCHA v3', 'wp-members' ) . '|4'; $captcha[] = __( 'Really Simple CAPTCHA', 'wp-members' ) . '|2'; $captcha[] = __( 'hCaptcha', 'wp-members' ) . '|5'; - echo wpmem_create_formfield( 'wpmem_settings_captcha', 'select', $captcha, $wpmem->captcha ); ?> + echo wpmem_form_field( 'wpmem_settings_captcha', 'select', $captcha, $wpmem->captcha ); ?>
  • user_pages['login']; diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 6a98ef6f..fced6557 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -871,10 +871,10 @@ function login_form( $mixed, $arr = array() ) { // Build the buttons, filter, and add to the form. if ( $action == 'login' ) { - $args['remember_check'] = ( $args['remember_check'] ) ? $args['t'] . wpmem_create_formfield( 'rememberme', 'checkbox', 'forever' ) . ' ' . '  ' . $args['n'] : ''; - $buttons = $args['remember_check'] . $args['t'] . '' . $args['n']; + $args['remember_check'] = ( $args['remember_check'] ) ? $args['t'] . wpmem_form_field( array( 'name' => 'rememberme', 'type' => 'checkbox', 'value' => 'forever' ) ) . ' ' . '  ' . $args['n'] : ''; + $buttons = $args['remember_check'] . $args['t'] . '' . $args['n']; } else { - $buttons = '' . $args['n']; + $buttons = '' . $args['n']; } /** @@ -1918,49 +1918,58 @@ function wp_newuser_form() { $req = ( $field['required'] ) ? ' ' . __( '(required)' ) . '' : ''; - echo '
    + $class = ( 'radio' == $field['type'] + || 'checkbox' == $field['type'] + || 'date' == $field['type'] ) ? '' : ' class="form-field" '; + echo ' - + '; } diff --git a/includes/class-wp-members-pwd-reset.php b/includes/class-wp-members-pwd-reset.php index d71eacb9..4808dd2c 100644 --- a/includes/class-wp-members-pwd-reset.php +++ b/includes/class-wp-members-pwd-reset.php @@ -207,8 +207,8 @@ function display_content( $content ) { function add_hidden_form_field( $hidden_fields, $action ) { if ( $this->form_action == wpmem_get( 'a', false, 'request' ) ) { $hidden_fields = str_replace( 'pwdchange', $this->form_action, $hidden_fields ); - $hidden_fields.= wpmem_create_formfield( 'key', 'hidden', wpmem_get( 'key', null, 'request' ) ); - $hidden_fields.= wpmem_create_formfield( 'login', 'hidden', wpmem_get( 'login', null, 'request' ) ); + $hidden_fields.= wpmem_form_field( array( 'name' => 'key', 'type' => 'hidden', 'value' => sanitize_text( wpmem_get( 'key', null, 'request' ) ) ) ); + $hidden_fields.= wpmem_form_field( array( 'name' => 'login', 'type' => 'hidden', 'value' => sanitize_user( wpmem_get( 'login', null, 'request' ) ) ) ); } return $hidden_fields; } From bc8c58744e147fb154ec1270a7e22e47119da757 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 14 Aug 2021 09:27:58 -0400 Subject: [PATCH 1449/1694] use wpmem_sanitize_class() via api --- includes/class-wp-members-forms.php | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index fced6557..8aa42503 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -273,7 +273,7 @@ function create_form_field( $args ) { case "email": case "number": case "date": - $class = ( 'textbox' == $class ) ? "textbox" : $this->sanitize_class( $class ); + $class = ( 'textbox' == $class ) ? "textbox" : wpmem_sanitize_class( $class ); switch ( $type ) { case 'url': $value = esc_url( $value ); @@ -295,7 +295,7 @@ function create_form_field( $args ) { break; case "password": - $class = $this->sanitize_class( $class ); + $class = wpmem_sanitize_class( $class ); $placeholder = ( $placeholder ) ? ' placeholder="' . esc_attr( __( $placeholder, 'wp-members' ) ) . '"' : ''; $pattern = ( $pattern ) ? ' pattern="' . esc_attr( $pattern ) . '"' : ''; $title = ( $title ) ? ' title="' . esc_attr( __( $title, 'wp-members' ) ) . '"' : ''; @@ -313,18 +313,18 @@ function create_form_field( $args ) { } else { $accept = ''; } - $class = ( 'textbox' == $class ) ? "file" : $this->sanitize_class( $class ); + $class = ( 'textbox' == $class ) ? "file" : wpmem_sanitize_class( $class ); $str = "'; break; case "checkbox": - $class = ( 'textbox' == $class ) ? "checkbox" : $this->sanitize_class( $class ); + $class = ( 'textbox' == $class ) ? "checkbox" : wpmem_sanitize_class( $class ); $str = ""; break; case "textarea": $value = esc_textarea( stripslashes( $value ) ); // stripslashes( esc_textarea( $value ) ); - $class = ( 'textbox' == $class ) ? "textarea" : $this->sanitize_class( $class ); + $class = ( 'textbox' == $class ) ? "textarea" : wpmem_sanitize_class( $class ); $placeholder = ( $placeholder ) ? ' placeholder="' . esc_attr( __( $placeholder, 'wp-members' ) ) . '"' : ''; $rows = ( isset( $args['rows'] ) && $args['rows'] ) ? esc_attr( $args['rows'] ) : '5'; $cols = ( isset( $args['cols'] ) && $args['cols'] ) ? esc_attr( $args['cols'] ) : '20'; @@ -397,7 +397,7 @@ function create_form_field( $args ) { break; case "radio": - $class = ( 'textbox' == $class ) ? "radio" : $this->sanitize_class( $class ); + $class = ( 'textbox' == $class ) ? "radio" : wpmem_sanitize_class( $class ); $str = ''; $num = 1; foreach ( $value as $option ) { @@ -454,7 +454,7 @@ function create_form_label( $args ) { $id = ( $id ) ? ' id="' . esc_attr( $id ) . '"' : ''; - $label = '
    -

    ", '' ); } ?>


    diff --git a/readme.txt b/readme.txt index 46cf777e..e8fc08f0 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 5.5 -Stable tag: 3.3.5.2 +Stable tag: 3.3.6 License: GPLv2 == Description == @@ -107,7 +107,7 @@ The FAQs are maintained at https://rocketgeek.com/plugins/wp-members/docs/faqs/ == Upgrade Notice == -WP-Members 3.3.0 is a major update. WP-Members 3.3.6 is an improvement release. See changelog for important details. Minimum WP version is 4.0. +WP-Members 3.3.0 is a major update. WP-Members 3.3.6 is a bug fix release. See changelog for important details. Minimum WP version is 4.0. == Screenshots == From 8fdd9eebacbb68b34df17ae0d60e7c118e04483e Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 25 Sep 2020 00:18:10 -0400 Subject: [PATCH 1339/1694] fixes an issue with pre_register_data hook if $wpmem_themsg is inadvertently nulled --- includes/api/api-users.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 1d3b5f0f..af07334e 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -532,7 +532,12 @@ function wpmem_user_register( $tag ) { global $user_ID, $wpmem, $wpmem_themsg, $userdata; $wpmem->user->register_validate( $tag ); - + + // @todo Added as a fix for legacy versions of security extension and any wpmem_pre_register_data action that might null $wpmem_themsg. + if ( $wpmem_themsg ) { + return $wpmem_themsg; + } + switch ( $tag ) { case "register": From a90305e2c330177e1a42a8895ea1a45cccfd23b4 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 29 Sep 2020 11:31:55 -0400 Subject: [PATCH 1340/1694] added "type" argument to sanitize array (default as text) --- includes/api/api-forms.php | 10 ++++++---- includes/class-wp-members-forms.php | 10 ++++++---- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index a1bed486..a3cded42 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -322,15 +322,17 @@ function wpmem_sanitize_class( $class ) { * This is an API wrapper for WP_Members_Forms::sanitize_array(). * * @since 3.2.9 + * @since 3.3.7 Added optional $type * * @global object $wpmem * - * @param array $data - * @return array $data + * @param array $data + * @param string $type The data type integer|int (default: false) + * @return array $data */ -function wpmem_sanitize_array( $data ) { +function wpmem_sanitize_array( $data, $type = false ) { global $wpmem; - return $wpmem->forms->sanitize_array( $data ); + return $wpmem->forms->sanitize_array( $data, $type ); } /** diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index c5019708..7df037a8 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -308,14 +308,16 @@ function sanitize_class( $class ) { * Sanitizes the text in an array. * * @since 3.2.9 + * @since 3.3.7 Added optional $type * - * @param array $data - * @return array $data + * @param array $data + * @param string $type The data type integer|int (default: false) + * @return array $data */ - function sanitize_array( $data ) { + function sanitize_array( $data, $type = false ) { if ( is_array( $data ) ) { foreach( $data as $key => $val ) { - $data[ $key ] = sanitize_text_field( $val ); + $data[ $key ] = ( 'integer' == $type || 'int' == $type ) ? intval( $val ) : sanitize_text_field( $val ); } } return $data; From c7c0b282df5ec4bf48bef91cf3f7eca6680e06ed Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 29 Sep 2020 11:35:11 -0400 Subject: [PATCH 1341/1694] changed date format for default export filename to yyyy-mm-dd --- includes/admin/class-wp-members-admin-users.php | 6 +++--- includes/admin/class-wp-members-export.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/includes/admin/class-wp-members-admin-users.php b/includes/admin/class-wp-members-admin-users.php index 4fbd3d14..babac147 100644 --- a/includes/admin/class-wp-members-admin-users.php +++ b/includes/admin/class-wp-members-admin-users.php @@ -86,9 +86,9 @@ static function page_load() { } // If exporting all users, do it, then exit. - if ( isset( $_REQUEST['export_all'] ) && $_REQUEST['export_all'] == __( 'Export All Users', 'wp-members' ) ) { - $today = date( "m-d-y" ); - wpmem_export_users( array( 'export'=>'all', 'filename'=>'user-export-' . $today . '.csv' ), '' ); + if ( __( 'Export All Users', 'wp-members' ) == wpmem_get( 'export_all', false ) ) { + $today = date( "Y-m-d" ); + wpmem_export_users( array( 'export'=>'all', 'filename'=>'user-export-' . $today . '.csv' ) ); exit(); } diff --git a/includes/admin/class-wp-members-export.php b/includes/admin/class-wp-members-export.php index 9e9bf68f..f1ffdadc 100644 --- a/includes/admin/class-wp-members-export.php +++ b/includes/admin/class-wp-members-export.php @@ -29,7 +29,7 @@ static function export_users( $args, $users = null ) { global $wpmem; - $today = date( "m-d-y" ); + $today = date( "Y-m-d" ); // Setup defaults. $defaults = array( From 69c4358e2a69e884f3a3a792188a779e3a53e0f4 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 29 Sep 2020 13:45:34 -0400 Subject: [PATCH 1342/1694] export default set to empty array (instead of boolean/null) to avoid error if no users selected --- includes/admin/class-wp-members-admin-users.php | 8 ++------ includes/api/api-users.php | 2 +- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/includes/admin/class-wp-members-admin-users.php b/includes/admin/class-wp-members-admin-users.php index babac147..08862cfa 100644 --- a/includes/admin/class-wp-members-admin-users.php +++ b/includes/admin/class-wp-members-admin-users.php @@ -172,12 +172,8 @@ static function page_load() { case 'export': - $users = wpmem_get( 'users', false, 'request' ); - $sanitized_users = array(); - foreach ( $users as $user ) { - $sanitized_users[] = filter_var( $user, FILTER_VALIDATE_INT ); - } - wpmem_export_users( array( 'export'=>'selected' ), $sanitized_users ); + $users = wpmem_get( 'users', array(), 'request' ); + wpmem_export_users( array( 'export'=>'selected' ), wpmem_sanitize_array( $users, 'integer' ) ); return; break; diff --git a/includes/api/api-users.php b/includes/api/api-users.php index af07334e..6c39d740 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -786,7 +786,7 @@ function wpmem_get_user_ip() { * @param array $args * @param array $users */ -function wpmem_export_users( $args, $users = null ) { +function wpmem_export_users( $args, $users = array() ) { global $wpmem; include_once( $wpmem->path . 'includes/admin/class-wp-members-export.php' ); WP_Members_Export::export_users( $args, $users ); From ebc31c50e7a44abb81e6ba4daa63a823c14854df Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 29 Sep 2020 13:46:21 -0400 Subject: [PATCH 1343/1694] added "export all" to top bulk group --- includes/admin/class-wp-members-admin-users.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/admin/class-wp-members-admin-users.php b/includes/admin/class-wp-members-admin-users.php index 08862cfa..521f8ca5 100644 --- a/includes/admin/class-wp-members-admin-users.php +++ b/includes/admin/class-wp-members-admin-users.php @@ -29,6 +29,7 @@ static function bulk_user_action() { $j('

    @@ -267,7 +268,7 @@ public static function update() { check_admin_referer( 'wpmem-update-captcha' ); $settings = get_option( 'wpmembers_captcha' ); - $update_type = sanitize_text_field( $_POST['wpmem_recaptcha_type'] ); + $update_type = sanitize_text_field( wpmem_get( 'wpmem_recaptcha_type', '' ) ); $which = intval( wpmem_get( 'wpmem_settings_captcha', 0 ) ); // If there are no current settings. @@ -285,32 +286,32 @@ public static function update() { if ( $update_type == 'recaptcha' || $update_type == 'recaptcha2' ) { $settings['recaptcha'] = array( - 'public' => sanitize_text_field( $_POST['wpmem_captcha_publickey'] ), - 'private' => sanitize_text_field( $_POST['wpmem_captcha_privatekey'] ), + 'public' => sanitize_text_field( wpmem_get( 'wpmem_captcha_publickey', '' ) ), + 'private' => sanitize_text_field( wpmem_get( 'wpmem_captcha_privatekey', '' ) ), ); - if ( $update_type == 'recaptcha' && isset( $_POST['wpmem_captcha_theme'] ) ) { - $settings['recaptcha']['theme'] = sanitize_text_field( $_POST['wpmem_captcha_theme'] ); + if ( 'recaptcha' == wpmem_get( 'wpmem_captcha_theme', false ) ) { + $settings['recaptcha']['theme'] = sanitize_text_field( wpmem_get( 'wpmem_captcha_theme', '' ) ); } } if ( 'hcaptcha' == $update_type ) { - $settings['hcaptcha']['api_key'] = sanitize_text_field( $_POST['wpmem_captcha_publickey'] ); - $settings['hcaptcha']['secret'] = sanitize_text_field( $_POST['wpmem_captcha_privatekey'] ); + $settings['hcaptcha']['api_key'] = sanitize_text_field( wpmem_get( 'wpmem_captcha_publickey', '' ) ); + $settings['hcaptcha']['secret'] = sanitize_text_field( wpmem_get( 'wpmem_captcha_privatekey', '' ) ); } if ( $update_type == 'really_simple' ) { - $font_color = sanitize_text_field( $_POST['font_color_r'] ) . ',' . sanitize_text_field( $_POST['font_color_g'] ) . ',' . sanitize_text_field( $_POST['font_color_b'] ); - $bg_color = sanitize_text_field( $_POST['bg_color_r'] ) . ',' . sanitize_text_field( $_POST['bg_color_g'] ) . ',' . sanitize_text_field( $_POST['bg_color_b'] ); + $font_color = sanitize_text_field( wpmem_get( 'font_color_r', '' ) ) . ',' . sanitize_text_field( wpmem_get( 'font_color_g', '' ) ) . ',' . sanitize_text_field( wpmem_get( 'font_color_b', '' ) ); + $bg_color = sanitize_text_field( wpmem_get( 'bg_color_r', '' ) ) . ',' . sanitize_text_field( wpmem_get( 'bg_color_g', '' ) ) . ',' . sanitize_text_field( wpmem_get( 'bg_color_b', '' ) ); $settings['really_simple'] = array( - 'characters' => sanitize_text_field( $_POST['characters'] ), - 'num_char' => sanitize_text_field( $_POST['num_char'] ), - 'dim_w' => sanitize_text_field( $_POST['dim_w'] ), - 'dim_h' => sanitize_text_field( $_POST['dim_h'] ), + 'characters' => sanitize_text_field( wpmem_get( 'characters', '' ) ), + 'num_char' => sanitize_text_field( wpmem_get( 'num_char', '' ) ), + 'dim_w' => sanitize_text_field( wpmem_get( 'dim_w', '' ) ), + 'dim_h' => sanitize_text_field( wpmem_get( 'dim_h', '' ) ), 'font_color' => $font_color, 'bg_color' => $bg_color, - 'font_size' => sanitize_text_field( $_POST['font_size'] ), - 'kerning' => sanitize_text_field( $_POST['kerning'] ), - 'img_type' => sanitize_text_field( $_POST['img_type'] ), + 'font_size' => sanitize_text_field( wpmem_get( 'font_size', '' ) ), + 'kerning' => sanitize_text_field( wpmem_get( 'kerning', '' ) ), + 'img_type' => sanitize_text_field( wpmem_get( 'img_type', '' ) ), ); } From 7b6a0fb846c10d179fd2fb038e079780fadd4b72 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 25 Mar 2021 16:56:26 -0400 Subject: [PATCH 1385/1694] move tos req_mark to match other checkboxes --- includes/class-wp-members-forms.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 3dcbfcec..4ae8f514 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1023,9 +1023,10 @@ function register_form( $mixed = 'new', $redirect_to = null ) { 'compare' => $val, 'required' => $field['required'], ) ); - $input = ( $field['required'] ) ? $input . $args['req_mark'] : $input; $input .= ' ' . $this->get_tos_link( $field, $tag ); + + $input = ( $field['required'] ) ? $input . $args['req_mark'] : $input; // In previous versions, the div class would end up being the same as the row before. $field_before = ( $args['wrap_inputs'] ) ? '
    ' : ''; From 3a376a3e89dba76aa5a61f3f39919f6f238c3a24 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 25 Mar 2021 16:57:21 -0400 Subject: [PATCH 1386/1694] form html cleanup of closing label tags --- includes/class-wp-members-forms.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 4ae8f514..f7a065e1 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1604,9 +1604,9 @@ function wp_register_form( $process = 'wp' ) { $val = ( ! $_POST && $field['checked_default'] ) ? $field['checked_value'] : $val; $row_before = '

    '; - $label = '

    '; + $row_after = '

    '; } elseif ( 'hidden' == $field['type'] ) { @@ -1625,7 +1625,8 @@ function wp_register_form( $process = 'wp' ) { } else { $row_before = ( $is_woo ) ? '

    ' : '

    '; - $label = '

    '; + $row_after = '

    '; } From 9adc490e09476c94c4eb4b806c1e088eb3840363 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 25 Mar 2021 16:58:21 -0400 Subject: [PATCH 1387/1694] make sure $captcha var is defined --- includes/class-wp-members-forms.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index f7a065e1..306f4651 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1704,11 +1704,12 @@ function wp_register_form( $process = 'wp' ) { } // Do recaptcha if enabled. - if ( ! $is_woo && isset( $wpmem->captcha ) && $wpmem->captcha > 0 ) { + if ( ! $is_woo && isset( $wpmem->captcha ) && $wpmem->captcha != 0 ) { $row_before = '

    '; $row_after = '

    '; $label = ''; + $captcha = ''; if ( in_array( $wpmem->captcha, array( 1, 3, 4 ) ) ) { $captcha = WP_Members_Captcha::recaptcha(); From 9a52a9af0a9207d602f6f2ac6303263649c896c8 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 25 Mar 2021 16:58:51 -0400 Subject: [PATCH 1388/1694] added 'membership' field type support to wpmem_field shortcode --- includes/class-wp-members-shortcodes.php | 1 + 1 file changed, 1 insertion(+) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index 72fa2ec7..5d6e7797 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -616,6 +616,7 @@ function fields( $atts, $content = null, $tag ) { // Select and radio groups have single selections. case 'select': case 'radio': + case 'membership': $result = ( isset( $atts['display'] ) && 'raw' == $atts['display'] ) ? $user_info_field : $fields[ $field ]['options'][ $user_info_field ]; break; From 4c6bc7fc1d20e52b79842cc77eced5851b8a6249 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 25 Mar 2021 16:59:59 -0400 Subject: [PATCH 1389/1694] added wpmem_user_set_as_confirmed and _unconfirmed action hooks --- includes/class-wp-members-validation-link.php | 29 +++++++++++++++---- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/includes/class-wp-members-validation-link.php b/includes/class-wp-members-validation-link.php index 75596fca..30d78f5e 100644 --- a/includes/class-wp-members-validation-link.php +++ b/includes/class-wp-members-validation-link.php @@ -114,10 +114,10 @@ public function add_key_to_email( $arr, $wpmem_fields, $field_data ) { if ( strpos( $arr['body'], '[confirm_link]' ) ) { $arr['body'] = str_replace( '[confirm_link]', $link, $arr['body'] ); } else { - // Add text and link to the email body. - $arr['body'] = $arr['body'] . "\r\n" - . $this->email_text - . $link; + // Add text and link to the email body. + $arr['body'] = $arr['body'] . "\r\n" + . $this->email_text + . $link; } } @@ -338,6 +338,15 @@ public function set_validation_key( $user ) { */ public function set_as_confirmed( $user_id ) { update_user_meta( $user_id, $this->validation_confirm, time() ); + /** + * Fires when user is set as confirmed (either manually or by user). + * + * @since 3.3.9 + * + * @param int $user_id + * @param string time() + */ + do_action( 'wpmem_user_set_as_confirmed', $user_id, time() ); } /** @@ -349,6 +358,16 @@ public function set_as_confirmed( $user_id ) { */ public function set_as_unconfirmed( $user_id ) { delete_user_meta( $user_id, $this->validation_confirm ); - $this->set_validation_key( $user_id ); + $validation_key = $this->set_validation_key( $user_id ); + /** + * Fires when user is set as confirmed (either manually or by user). + * + * @since 3.3.9 + * + * @param int $user_id + * @param string time() + * @param string $key + */ + do_action( 'wpmem_user_set_as_unconfirmed', $user_id, time(), $key ); } } \ No newline at end of file From d6947662356e972495a25158dbb805ccc5f8a9a1 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 7 May 2021 15:33:40 -0400 Subject: [PATCH 1390/1694] moved fields related methods to forms object class --- includes/class-wp-members-forms.php | 180 ++++++++++++++++++++++++++++ includes/class-wp-members.php | 155 +----------------------- 2 files changed, 184 insertions(+), 151 deletions(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 306f4651..8c61b25e 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -22,6 +22,186 @@ class WP_Members_Forms { function __construct() { } + + /** + * Sets the registration fields. + * + * @since 3.0.0 + * @since 3.1.5 Added $form argument. + * @since 3.3.0 Added $tag argument. + * + * @param string $form The form being generated. + */ + function load_fields( $tag = 'new', $form = 'default' ) { + + // Get stored fields settings. + $fields = get_option( 'wpmembers_fields' ); + + // Validate fields settings. + if ( ! isset( $fields ) || empty( $fields ) ) { + // Update settings. + $fields = array( array( 10, 'Email', 'user_email', 'email', 'y', 'y', 'y', 'profile'=>true ) ); + } + + // Add new field array keys + foreach ( $fields as $key => $val ) { + + // Key fields with meta key. + $meta_key = $val[2]; + + // Old format, new key. + foreach ( $val as $subkey => $subval ) { + $this->fields[ $meta_key ][ $subkey ] = $subval; + } + + // Setup field properties. + $this->fields[ $meta_key ]['label'] = $val[1]; + $this->fields[ $meta_key ]['type'] = $val[3]; + $this->fields[ $meta_key ]['register'] = ( 'y' == $val[4] ) ? true : false; + $this->fields[ $meta_key ]['required'] = ( 'y' == $val[5] ) ? true : false; + $this->fields[ $meta_key ]['profile'] = ( 'y' == $val[4] ) ? true : false;// ( isset( $val['profile'] ) ) ? $val['profile'] : true ; // // @todo Wait for profile fix + $this->fields[ $meta_key ]['native'] = ( 'y' == $val[6] ) ? true : false; + + // Certain field types have additional properties. + switch ( $val[3] ) { + + case 'checkbox': + $this->fields[ $meta_key ]['checked_value'] = $val[7]; + $this->fields[ $meta_key ]['checked_default'] = ( 'y' == $val[8] ) ? true : false; + break; + + case 'select': + case 'multiselect': + case 'multicheckbox': + case 'radio': + case 'membership': + if ( 'membership' == $val[3] ) { + $val[7] = array( __( 'Choose membership', 'wp-members' ) . '|' ); + foreach( $this->membership->products as $membership_key => $membership_value ) { + $val[7][] = $membership_value['title'] . '|' . $membership_key; + } + } + // Correct a malformed value (if last value is empty due to a trailing comma). + if ( '' == end( $val[7] ) ) { + array_pop( $val[7] ); + $this->fields[ $meta_key ][7] = $val[7]; + } + $this->fields[ $meta_key ]['values'] = $val[7]; + $this->fields[ $meta_key ]['delimiter'] = ( isset( $val[8] ) ) ? $val[8] : '|'; + $this->fields[ $meta_key ]['options'] = array(); + foreach ( $val[7] as $value ) { + $pieces = explode( '|', trim( $value ) ); + if ( isset( $pieces[1] ) && $pieces[1] != '' ) { + $this->fields[ $meta_key ]['options'][ $pieces[1] ] = $pieces[0]; + } + } + break; + + case 'file': + case 'image': + $this->fields[ $meta_key ]['file_types'] = $val[7]; + break; + + case 'hidden': + $this->fields[ $meta_key ]['value'] = $val[7]; + break; + + } + } + } + + /** + * Filter custom fields for localization. + * + * @since 3.3.9 + * + * @param array $fields + */ + function localize_fields( $fields ) { + if ( function_exists( 'wpmem_custom_translation_strings' ) ) { + $string_map = wpmem_custom_translation_strings( get_locale() ); + foreach ( $string_map as $meta_key => $value ) { + if ( is_array( $value ) ) { + if ( isset( $fields[ $meta_key ]['placeholder'] ) && isset( $value['placeholder'] ) ) { + $fields[ $meta_key ]['placeholder'] = $string_map[ $meta_key ]['placeholder']; + } + if ( isset( $fields[ $meta_key ]['title'] ) && isset( $value['title'] ) ) { + $fields[ $meta_key ]['title'] = $string_map[ $meta_key ]['title']; + } + if ( isset( $fields[ $meta_key ]['label'] ) && isset( $value['label'] ) ) { + $fields[ $meta_key ]['label'] = $string_map[ $meta_key ]['label']; + } + } else { + $fields[ $meta_key ]['label'] = $string_map[ $meta_key ]; + } + } + } + return $fields; + } + + /** + * Get excluded meta fields. + * + * @since 3.0.0 + * @since 3.3.3 Update $tag to match wpmem_fields() tags. + * + * @param string $tag A tag so we know where the function is being used. + * @return array The excluded fields. + */ + function excluded_fields( $tag ) { + + // Default excluded fields. + $excluded_fields = array( 'password', 'confirm_password', 'confirm_email', 'password_confirm', 'email_confirm' ); + + if ( 'update' == $tag || 'admin-profile' == $tag || 'user-profile' == $tag || 'wp-register' == $tag ) { + $excluded_fields[] = 'username'; + } + + if ( 'admin-profile' == $tag || 'user-profile' == $tag ) { + array_push( $excluded_fields, 'first_name', 'last_name', 'nickname', 'display_name', 'user_email', 'description', 'user_url' ); + + // If WooCommerce is used, remove these meta - WC already adds them in their own section. + if ( class_exists( 'woocommerce' ) ) { + array_push( $excluded_fields, + 'billing_first_name', + 'billing_last_name', + 'billing_company', + 'billing_address_1', + 'billing_address_2', + 'billing_city', + 'billing_postcode', + 'billing_country', + 'billing_state', + 'billing_email', + 'billing_phone', + 'shipping_first_name', + 'shipping_last_name', + 'shipping_company', + 'shipping_address_1', + 'shipping_address_2', + 'shipping_city', + 'shipping_postcode', + 'shipping_country', + 'shipping_state' + ); + } + } + + /** + * Filter excluded meta fields. + * + * @since 2.9.3 + * @since 3.0.0 Moved to new method in WP_Members Class. + * @since 3.3.3 Update $tag to match wpmem_fields() tags. + * + * @param array An array of the field meta names to exclude. + * @param string $tag A tag so we know where the function is being used. + */ + $excluded_fields = apply_filters( 'wpmem_exclude_fields', $excluded_fields, $tag ); + + // Return excluded fields. + return $excluded_fields; + } /** * Creates form fields diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 2f970045..f2163f34 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -524,6 +524,10 @@ function load_hooks() { add_filter( 'wpmem_login_failed_args', array( $this, 'login_error' ) ); add_filter( 'lostpassword_url', array( $this, 'lost_pwd_url' ), 10, 2 ); } + + if ( function_exists( 'wpmem_custom_translation_strings' ) ) { + add_filter( 'wpmem_fields', array( $this->forms, 'localize_fields' ), 9 ); + } /** * Fires after action and filter hooks load. * @@ -1321,157 +1325,6 @@ function filter_get_adjacent_post_where( $where ) { } return $where; } - - /** - * Sets the registration fields. - * - * @since 3.0.0 - * @since 3.1.5 Added $form argument. - * @since 3.3.0 Added $tag argument. - * - * @param string $form The form being generated. - */ - function load_fields( $tag = 'new', $form = 'default' ) { - - // Get stored fields settings. - $fields = get_option( 'wpmembers_fields' ); - - // Validate fields settings. - if ( ! isset( $fields ) || empty( $fields ) ) { - // Update settings. - $fields = array( array( 10, 'Email', 'user_email', 'email', 'y', 'y', 'y', 'profile'=>true ) ); - } - - // Add new field array keys - foreach ( $fields as $key => $val ) { - - // Key fields with meta key. - $meta_key = $val[2]; - - // Old format, new key. - foreach ( $val as $subkey => $subval ) { - $this->fields[ $meta_key ][ $subkey ] = $subval; - } - - // Setup field properties. - $this->fields[ $meta_key ]['label'] = $val[1]; - $this->fields[ $meta_key ]['type'] = $val[3]; - $this->fields[ $meta_key ]['register'] = ( 'y' == $val[4] ) ? true : false; - $this->fields[ $meta_key ]['required'] = ( 'y' == $val[5] ) ? true : false; - $this->fields[ $meta_key ]['profile'] = ( 'y' == $val[4] ) ? true : false;// ( isset( $val['profile'] ) ) ? $val['profile'] : true ; // // @todo Wait for profile fix - $this->fields[ $meta_key ]['native'] = ( 'y' == $val[6] ) ? true : false; - - // Certain field types have additional properties. - switch ( $val[3] ) { - - case 'checkbox': - $this->fields[ $meta_key ]['checked_value'] = $val[7]; - $this->fields[ $meta_key ]['checked_default'] = ( 'y' == $val[8] ) ? true : false; - break; - - case 'select': - case 'multiselect': - case 'multicheckbox': - case 'radio': - case 'membership': - if ( 'membership' == $val[3] ) { - $val[7] = array( __( 'Choose membership', 'wp-members' ) . '|' ); - foreach( $this->membership->products as $membership_key => $membership_value ) { - $val[7][] = $membership_value['title'] . '|' . $membership_key; - } - } - // Correct a malformed value (if last value is empty due to a trailing comma). - if ( '' == end( $val[7] ) ) { - array_pop( $val[7] ); - $this->fields[ $meta_key ][7] = $val[7]; - } - $this->fields[ $meta_key ]['values'] = $val[7]; - $this->fields[ $meta_key ]['delimiter'] = ( isset( $val[8] ) ) ? $val[8] : '|'; - $this->fields[ $meta_key ]['options'] = array(); - foreach ( $val[7] as $value ) { - $pieces = explode( '|', trim( $value ) ); - if ( isset( $pieces[1] ) && $pieces[1] != '' ) { - $this->fields[ $meta_key ]['options'][ $pieces[1] ] = $pieces[0]; - } - } - break; - - case 'file': - case 'image': - $this->fields[ $meta_key ]['file_types'] = $val[7]; - break; - - case 'hidden': - $this->fields[ $meta_key ]['value'] = $val[7]; - break; - - } - } - } - - /** - * Get excluded meta fields. - * - * @since 3.0.0 - * @since 3.3.3 Update $tag to match wpmem_fields() tags. - * - * @param string $tag A tag so we know where the function is being used. - * @return array The excluded fields. - */ - function excluded_fields( $tag ) { - - // Default excluded fields. - $excluded_fields = array( 'password', 'confirm_password', 'confirm_email', 'password_confirm', 'email_confirm' ); - - if ( 'update' == $tag || 'admin-profile' == $tag || 'user-profile' == $tag || 'wp-register' == $tag ) { - $excluded_fields[] = 'username'; - } - - if ( 'admin-profile' == $tag || 'user-profile' == $tag ) { - array_push( $excluded_fields, 'first_name', 'last_name', 'nickname', 'display_name', 'user_email', 'description', 'user_url' ); - - // If WooCommerce is used, remove these meta - WC already adds them in their own section. - if ( class_exists( 'woocommerce' ) ) { - array_push( $excluded_fields, - 'billing_first_name', - 'billing_last_name', - 'billing_company', - 'billing_address_1', - 'billing_address_2', - 'billing_city', - 'billing_postcode', - 'billing_country', - 'billing_state', - 'billing_email', - 'billing_phone', - 'shipping_first_name', - 'shipping_last_name', - 'shipping_company', - 'shipping_address_1', - 'shipping_address_2', - 'shipping_city', - 'shipping_postcode', - 'shipping_country', - 'shipping_state' - ); - } - } - - /** - * Filter excluded meta fields. - * - * @since 2.9.3 - * @since 3.0.0 Moved to new method in WP_Members Class. - * @since 3.3.3 Update $tag to match wpmem_fields() tags. - * - * @param array An array of the field meta names to exclude. - * @param string $tag A tag so we know where the function is being used. - */ - $excluded_fields = apply_filters( 'wpmem_exclude_fields', $excluded_fields, $tag ); - - // Return excluded fields. - return $excluded_fields; - } /** * Set page locations. From 860bd2a537f1395e89f40f8c148e0893ebd45988 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 7 May 2021 15:35:24 -0400 Subject: [PATCH 1391/1694] handle user_nicename, display_name, and nickname separately --- includes/class-wp-members-user.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 0bc76500..e3bc1673 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -370,9 +370,9 @@ function register_validate( $tag ) { * are added, use the $_POST value - otherwise, default to username. * Value can be filtered with wpmem_register_data. */ - foreach( array( 'user_nicename', 'display_name', 'nickname' ) as $user_names ) { - $this->post_data[ $user_names ] = sanitize_text_field( wpmem_get( $user_names, $this->post_data['username'] ) ); - } + $this->post_data['user_nicename'] = sanitize_title( wpmem_get( 'user_nicename', $this->post_data['username'] ) ); + $this->post_data['display_name'] = sanitize_text_field( wpmem_get( 'display_name', $this->post_data['username'] ) ); + $this->post_data['nickname'] = sanitize_text_field( wpmem_get( 'nickname', $this->post_data['username'] ) ); } } From b5949f81ab8c4f92ca7beebab58bd3e32adedecd Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 7 May 2021 15:35:46 -0400 Subject: [PATCH 1392/1694] wpmem_auto_excerpt_args should pass $defaults --- includes/class-wp-members.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index f2163f34..b36395d3 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -1773,7 +1773,7 @@ function do_excerpt( $content ) { * @param string $post->ID The post ID. * @param string $post->post_type The content's post type. */ - $args = apply_filters( 'wpmem_auto_excerpt_args', '', $post->ID, $post->post_type ); + $args = apply_filters( 'wpmem_auto_excerpt_args', $defaults, $post->ID, $post->post_type ); // Merge settings. $args = wp_parse_args( $args, $defaults ); From b5bb8b7c876daad3d24a028ed0a3b56fddfb0626 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 7 May 2021 15:36:27 -0400 Subject: [PATCH 1393/1694] added wpmem_validation_link filter --- includes/class-wp-members-validation-link.php | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-validation-link.php b/includes/class-wp-members-validation-link.php index 30d78f5e..6595e749 100644 --- a/includes/class-wp-members-validation-link.php +++ b/includes/class-wp-members-validation-link.php @@ -109,6 +109,17 @@ public function add_key_to_email( $arr, $wpmem_fields, $field_data ) { $query_args = array_map( 'rawurlencode', $query_args ); $link = add_query_arg( $query_args, trailingslashit( $url ) ); + + /** + * Filter the confirmation link. + * + * @since 3.3.9 + * + * @param string $link + * @param string $url + * @param array $query_args + */ + $link = apply_filters( 'wpmem_validation_link', $link, $url, $query_args ); // Does email body have the [confirm_link] shortcode? if ( strpos( $arr['body'], '[confirm_link]' ) ) { @@ -116,8 +127,7 @@ public function add_key_to_email( $arr, $wpmem_fields, $field_data ) { } else { // Add text and link to the email body. $arr['body'] = $arr['body'] . "\r\n" - . $this->email_text - . $link; + . $this->email_text . ' ' . $link; } } From 2d9e3283cc4b64243be39e128387128bc11c1f77 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 7 May 2021 15:37:23 -0400 Subject: [PATCH 1394/1694] improve invalid key error handling in password reset --- includes/class-wp-members-pwd-reset.php | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-pwd-reset.php b/includes/class-wp-members-pwd-reset.php index 82f26417..e15070a9 100644 --- a/includes/class-wp-members-pwd-reset.php +++ b/includes/class-wp-members-pwd-reset.php @@ -145,6 +145,10 @@ function display_content( $content ) { * @return WP_User|WP_Error WP_User object on success, WP_Error object for invalid or expired keys (invalid_key|expired_key). */ $user = check_password_reset_key( $key, $user_login ); + + if ( $user->has_errors() ) { + $errors->add( 'user_not_found', $this->form_load_key_not_found ); + } // Validate if ( 1 == wpmem_get( 'formsubmit' ) && false !== wpmem_get( 'a', false, $this->form_action ) ) { @@ -177,11 +181,13 @@ function display_content( $content ) { if ( 'invalid_key' == $user->get_error_code() ) { // If somehow the form was submitted but the key not found. - $msg = wpmem_inc_regmessage( 'invalid_key', $this->form_submitted_key_not_found ); + $pwd_reset_link = wpmem_profile_url( 'pwdreset' ); + $msg = wpmem_inc_regmessage( 'invalid_key', $this->form_submitted_key_not_found . '
    Request a new reset key.' ); + $form = ''; + } else { + $form = wpmem_change_password_form(); } - $form = wpmem_change_password_form(); - } $content = $msg . $form; @@ -236,6 +242,7 @@ function get_wpmem_action() { $new_pass = ''; wpmem_email_to_user( $user->ID, $new_pass, 3 ); + /** This action is documented in /includes/class-wp-members-user.php */ do_action( 'wpmem_pwd_reset', $user->ID, $new_pass ); $wpmem->action = 'pwdreset_link'; global $wpmem_regchk; From 1df20e6397bf4531ae2f008f801c822d1dc1cfd9 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 7 May 2021 15:41:41 -0400 Subject: [PATCH 1395/1694] use methods previously moved to forms object class --- includes/admin/tabs/class-wp-members-admin-tab-fields.php | 5 +++-- includes/api/api-utilities.php | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-fields.php b/includes/admin/tabs/class-wp-members-admin-tab-fields.php index 6f78397c..6b2681af 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-fields.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-fields.php @@ -528,6 +528,7 @@ public static function bulk_actions() { * * @since 3.1.8 * @since 3.3.0 Changed from wpmem_admin_fields_update() to update(). + * @since 3.3.9 load_fields() moved to forms object class. * * @global object $wpmem * @global string $did_update @@ -581,7 +582,7 @@ public static function update() { } } update_option( 'wpmembers_fields', $wpmem_fields ); - $wpmem->load_fields(); + $wpmem->forms->load_fields(); $did_update = __( 'WP-Members fields were updated', 'wp-members' ); return $did_update; @@ -718,7 +719,7 @@ public static function update() { $wpmem_newfields = $wpmem_fields; update_option( 'wpmembers_fields', $wpmem_newfields ); - $wpmem->load_fields(); + $wpmem->forms->load_fields(); return $did_update; } } diff --git a/includes/api/api-utilities.php b/includes/api/api-utilities.php index ffa39cb1..1a53e039 100644 --- a/includes/api/api-utilities.php +++ b/includes/api/api-utilities.php @@ -44,13 +44,14 @@ function wpmem_securify( $content = null ) { * * @since 2.9.3 * @since Unknown Now a wrapper for get_excluded_fields(). + * @since 3.3.9 excluded_fields() moved to forms object class. * * @param string $tag A tag so we know where the function is being used. * @return array Array of fields to be excluded from the registration form. */ function wpmem_get_excluded_meta( $tag ) { global $wpmem; - return $wpmem->excluded_fields( $tag ); + return $wpmem->forms->excluded_fields( $tag ); } /** From 8e893a8b1639520d0198109d669607a2e637017a Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 7 May 2021 15:42:35 -0400 Subject: [PATCH 1396/1694] update nonce validation --- includes/admin/class-wp-members-admin-users.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/admin/class-wp-members-admin-users.php b/includes/admin/class-wp-members-admin-users.php index a7aeba1f..91e798fe 100644 --- a/includes/admin/class-wp-members-admin-users.php +++ b/includes/admin/class-wp-members-admin-users.php @@ -186,7 +186,7 @@ static function page_load() { case 'unconfirm-single': // Validate nonce. - check_admin_referer( 'activate-user' ); + check_admin_referer( 'confirm-user' ); // Get the users. $user_id = filter_var( $_REQUEST['user'], FILTER_VALIDATE_INT ); From 89687559773ee79f51d676da35c05c3ee947997e Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 7 May 2021 15:43:25 -0400 Subject: [PATCH 1397/1694] added user object to notifcation email filter --- includes/class-wp-members-email.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-email.php b/includes/class-wp-members-email.php index 5e1f5906..1c21e112 100644 --- a/includes/class-wp-members-email.php +++ b/includes/class-wp-members-email.php @@ -375,6 +375,7 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { * data from the register function. * * @since 2.9.8 + * @since 3.3.9 Added $user param. * * @param array $this->settings P * An array containing email body, subject, user id, and additional settings. @@ -398,10 +399,11 @@ function notify_admin( $user_id, $wpmem_fields = null, $field_data = null ) { * @type string $headers * @type string $admin_email * } - * @param array $wpmem_fields An array of the WP-Members fields. - * @param array $field_data An array of the posted registration data. + * @param array $wpmem_fields An array of the WP-Members fields. + * @param array $field_data An array of the posted registration data. + * @param stdClass $user WP user object for the specific user. */ - $this->settings = apply_filters( 'wpmem_notify_filter', $this->settings, $wpmem_fields, $field_data ); + $this->settings = apply_filters( 'wpmem_notify_filter', $this->settings, $wpmem_fields, $field_data, $user ); // If emails are not disabled, continue the email process. if ( ! $this->settings['disable'] ) { From 47d67f0b361468e917231cdaea752bc607e8c72c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 7 May 2021 15:44:08 -0400 Subject: [PATCH 1398/1694] return error for pwd reset if nonce doesn't validate --- includes/class-wp-members-pwd-reset.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/includes/class-wp-members-pwd-reset.php b/includes/class-wp-members-pwd-reset.php index e15070a9..a1690b79 100644 --- a/includes/class-wp-members-pwd-reset.php +++ b/includes/class-wp-members-pwd-reset.php @@ -221,6 +221,10 @@ function add_hidden_form_field( $hidden_fields, $action ) { function get_wpmem_action() { global $wpmem; if ( 'pwdreset' == $wpmem->action && isset( $_POST['formsubmit'] ) ) { + + if ( ! wp_verify_nonce( $_REQUEST['_wpmem_pwdreset_nonce'], 'wpmem_shortform_nonce' ) ) { + return "reg_generic"; + } $user_to_check = wpmem_get( 'user', false ); $user_to_check = ( strpos( $user_to_check, '@' ) ) ? sanitize_email( $user_to_check ) : sanitize_user( $user_to_check ); From f2ad06e6e4ed858bd449dfcd566507853727e195 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 May 2021 12:17:47 -0400 Subject: [PATCH 1399/1694] debug moving form methods to forms object --- includes/api/api-forms.php | 3 ++- includes/class-wp-members-forms.php | 41 ++++++++++++++++------------- 2 files changed, 25 insertions(+), 19 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index fb204831..2c11204b 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -267,6 +267,7 @@ function wpmem_form_label( $args ) { * @since 3.1.1 * @since 3.1.5 Checks if fields array is set or empty before returning. * @since 3.1.7 Added wpmem_form_fields filter. + * @since 3.3.9 load_fields() moved to forms object class. * * @global object $wpmem The WP_Members object. * @param string $tag The action being used (default: null). @@ -277,7 +278,7 @@ function wpmem_fields( $tag = '', $form = 'default' ) { global $wpmem; // Load fields if none are loaded. if ( ! isset( $wpmem->fields ) || empty( $wpmem->fields ) ) { - $wpmem->load_fields( $form ); + $wpmem->forms->load_fields( $form ); } // @todo Review for removal. diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 8c61b25e..7a97002a 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -30,10 +30,14 @@ function __construct() { * @since 3.1.5 Added $form argument. * @since 3.3.0 Added $tag argument. * - * @param string $form The form being generated. + * @global stdClass $wpmem + * @param string $tag + * @param string $form The form being generated. */ function load_fields( $tag = 'new', $form = 'default' ) { + global $wpmem; + // Get stored fields settings. $fields = get_option( 'wpmembers_fields' ); @@ -51,23 +55,24 @@ function load_fields( $tag = 'new', $form = 'default' ) { // Old format, new key. foreach ( $val as $subkey => $subval ) { - $this->fields[ $meta_key ][ $subkey ] = $subval; + $wpmem->fields[ $meta_key ][ $subkey ] = $subval; } // Setup field properties. - $this->fields[ $meta_key ]['label'] = $val[1]; - $this->fields[ $meta_key ]['type'] = $val[3]; - $this->fields[ $meta_key ]['register'] = ( 'y' == $val[4] ) ? true : false; - $this->fields[ $meta_key ]['required'] = ( 'y' == $val[5] ) ? true : false; - $this->fields[ $meta_key ]['profile'] = ( 'y' == $val[4] ) ? true : false;// ( isset( $val['profile'] ) ) ? $val['profile'] : true ; // // @todo Wait for profile fix - $this->fields[ $meta_key ]['native'] = ( 'y' == $val[6] ) ? true : false; + $wpmem->fields[ $meta_key ]['label'] = $val[1]; + $wpmem->fields[ $meta_key ]['type'] = $val[3]; + $wpmem->fields[ $meta_key ]['register'] = ( 'y' == $val[4] ) ? true : false; + $wpmem->fields[ $meta_key ]['required'] = ( 'y' == $val[5] ) ? true : false; + $wpmem->fields[ $meta_key ]['profile'] = ( 'y' == $val[4] ) ? true : false;// ( isset( $val['profile'] ) ) ? $val['profile'] : true ; // // @todo Wait for profile fix + $wpmem->fields[ $meta_key ]['native'] = ( 'y' == $val[6] ) ? true : false; // Certain field types have additional properties. switch ( $val[3] ) { case 'checkbox': - $this->fields[ $meta_key ]['checked_value'] = $val[7]; - $this->fields[ $meta_key ]['checked_default'] = ( 'y' == $val[8] ) ? true : false; + $wpmem->fields[ $meta_key ]['checked_value'] = $val[7]; + $wpmem->fields[ $meta_key ]['checked_default'] = ( 'y' == $val[8] ) ? true : false; + $wpmem->fields[ $meta_key ]['checkbox_label'] = ( isset( $val['checkbox_label'] ) ) ? $val['checkbox_label'] : 0; break; case 'select': @@ -77,33 +82,33 @@ function load_fields( $tag = 'new', $form = 'default' ) { case 'membership': if ( 'membership' == $val[3] ) { $val[7] = array( __( 'Choose membership', 'wp-members' ) . '|' ); - foreach( $this->membership->products as $membership_key => $membership_value ) { + foreach( $wpmem->membership->products as $membership_key => $membership_value ) { $val[7][] = $membership_value['title'] . '|' . $membership_key; } } // Correct a malformed value (if last value is empty due to a trailing comma). if ( '' == end( $val[7] ) ) { array_pop( $val[7] ); - $this->fields[ $meta_key ][7] = $val[7]; + $wpmem->fields[ $meta_key ][7] = $val[7]; } - $this->fields[ $meta_key ]['values'] = $val[7]; - $this->fields[ $meta_key ]['delimiter'] = ( isset( $val[8] ) ) ? $val[8] : '|'; - $this->fields[ $meta_key ]['options'] = array(); + $wpmem->fields[ $meta_key ]['values'] = $val[7]; + $wpmem->fields[ $meta_key ]['delimiter'] = ( isset( $val[8] ) ) ? $val[8] : '|'; + $wpmem->fields[ $meta_key ]['options'] = array(); foreach ( $val[7] as $value ) { $pieces = explode( '|', trim( $value ) ); if ( isset( $pieces[1] ) && $pieces[1] != '' ) { - $this->fields[ $meta_key ]['options'][ $pieces[1] ] = $pieces[0]; + $wpmem->fields[ $meta_key ]['options'][ $pieces[1] ] = $pieces[0]; } } break; case 'file': case 'image': - $this->fields[ $meta_key ]['file_types'] = $val[7]; + $wpmem->fields[ $meta_key ]['file_types'] = $val[7]; break; case 'hidden': - $this->fields[ $meta_key ]['value'] = $val[7]; + $wpmem->fields[ $meta_key ]['value'] = $val[7]; break; } From 730b2a54e913fa078e292e9703c8a30e4e3f44cb Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 May 2021 12:18:22 -0400 Subject: [PATCH 1400/1694] allow new option for where checkbox label is located (before or after) --- includes/admin/tabs/class-wp-members-admin-tab-fields.php | 8 ++++++++ includes/class-wp-members-forms.php | 5 +++++ 2 files changed, 13 insertions(+) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-fields.php b/includes/admin/tabs/class-wp-members-admin-tab-fields.php index 6b2681af..99c44b2b 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-fields.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-fields.php @@ -302,6 +302,13 @@ public static function build_field_edit( $mode, $wpmem_fields, $meta_key ) { /> +
  • + + +
  • @@ -664,6 +671,7 @@ public static function update() { $add_field_err_msg = ( ! $_POST['add_checked_value'] ) ? __( 'Checked value is required for checkboxes. Nothing was updated.', 'wp-members' ) : $add_field_err_msg; $arr[7] = sanitize_text_field( wpmem_get( 'add_checked_value', false ) ); $arr[8] = ( 'y' == wpmem_get( 'add_checked_default', 'n' ) ) ? 'y' : 'n'; + $arr['checkbox_label'] = intval( wpmem_get( 'add_checkbox_label', 0 ) ); } if ( $type == 'select' diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 7a97002a..1829dc9d 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1297,6 +1297,11 @@ function register_form( $mixed = 'new', $redirect_to = null ) { } $input = wpmem_form_field( $formfield_args ); + // If checkbox label option is enabled. + if ( 'checkbox' == $field['type'] && 1 == $field['checkbox_label'] ) { + $input = $input . ' '; + $fields[ $meta_key ]['label'] = $field['label'] = $label = ''; + } } // Determine input wrappers. From c0499eebcdb475d3ff8a1cb1d584bf51a42fd7f3 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 3 Jun 2021 10:53:23 -0400 Subject: [PATCH 1401/1694] register_form is an action, not a filter --- includes/class-wp-members.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index b36395d3..9e4b7919 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -475,7 +475,7 @@ function load_hooks() { add_action( 'wpmem_pwd_change', array( $this->user, 'set_as_logged_in' ), 10 ); } - add_filter( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration + add_action( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration if ( wpmem_is_woo_active() ) { From d7a3b2a8a18363b54af5d5a2300a4346de6c1396 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 3 Jun 2021 10:57:25 -0400 Subject: [PATCH 1402/1694] adds register_form action to register form (similar to how login form works) --- includes/class-wp-members-forms.php | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 1829dc9d..0117c56d 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1011,6 +1011,13 @@ function login_form( $mixed, $arr = array() ) { */ function register_form( $mixed = 'new', $redirect_to = null ) { + /* + * Removes the action to load form elements for the WP registration + * form. Otherwise, when the register_form action is fired in this + * form, we'd get a duplication of all custom fields. + */ + remove_action( 'register_form', 'wpmem_wp_register_form' ); + // Handle legacy use. if ( is_array( $mixed ) ) { $id = ( isset( $mixed['id'] ) ) ? $mixed['id'] : ''; @@ -1065,6 +1072,8 @@ function register_form( $mixed = 'new', $redirect_to = null ) { 'wrap_inputs' => true, 'n' => "\n", 't' => "\t", + + 'register_form_action' => true, ); @@ -1089,7 +1098,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { // Get fields. $wpmem_fields = wpmem_fields( $tag ); - + // Fields to skip for user profile update. if ( 'edit' == $tag ) { @@ -1410,6 +1419,16 @@ function register_form( $mixed = 'new', $redirect_to = null ) { $row .= ( $row_item['row_after'] != '' ) ? $row_item['row_after'] . $args['n'] : ''; $form.= $row; } + + // Handle outside elements added to the register form with register_form. + if ( 'new' == $tag && $args['register_form_action'] ) { + ob_start(); + /** This action is documented in wp-login.php */ + do_action( 'register_form' ); + $add_to_form = ob_get_contents(); + ob_end_clean(); + $form.= $add_to_form; + } // Do recaptcha if enabled. if ( ( 1 == $wpmem->captcha || 3 == $wpmem->captcha || 4 == $wpmem->captcha ) && $tag != 'edit' ) { // don't show on edit page! From 5e07b6831f1fd647ea9b17f06078a7d6325936e0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 3 Jun 2021 10:58:06 -0400 Subject: [PATCH 1403/1694] shortcode object class cleanup (mostly inline docs) --- includes/class-wp-members-shortcodes.php | 89 ++++++++++++------------ 1 file changed, 46 insertions(+), 43 deletions(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index 5d6e7797..b9c2a1c2 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -57,7 +57,7 @@ function __construct() { } /** - * Function for forms called by shortcode. + * Renders forms called by [wpmem_form] shortcode. * * @since 3.0.0 * @since 3.1.3 Added forgot_username shortcode. @@ -75,20 +75,21 @@ function __construct() { * Possible shortcode attributes (some vary by form). * * @type string $id An ID for the form. - * @type string $login Idenifies login form. - * @type string $password Idenifies reset/change password form (login state dependent). - * @type string $user_edit Idenifies user profile edit form. - * @type string $forgot_username Idenifies forgot username form. - * @type string $register Idenifies register form. - * @type string $redirect_to URL to redirect to on form submit. - * @type string $texturize Add/fix texturization for the from HTML. - * @type string $exclude_fields Fields to exclude (register/user_edit forms only). - * @type string $include_fields Fields to include (register/user_edit forms only). + * @type string $login Renders a login form. + * @type string $password Renders a reset/change password form (login state dependent). + * @type string $user_edit Renders a user profile edit form. + * @type string $forgot_username Renders a forgot username form. + * @type string $register Renders a register form. + * @type string $wp_login Renders the WP login form. + * @type string $redirect_to URL to redirect to on form submit (used for login and register forms). + * @type string $texturize Add/fix texturization for the from HTML (usually not necessary). + * @type string $exclude_fields Fields to exclude as comma separated meta keys (register/user_edit forms only). + * @type string $include_fields Fields to include as comma separated meta keys (register/user_edit forms only). * @type string $product Register for specific product (if products are enabled). * } - * @param string $content - * @param string $tag - * @return string $content + * @param string $content Nested content displayed if the shortcode is in the logged in state (optional). + * @param string $tag The shortcode's tag (wpmem_form). + * @return string The form HTML (or nested content, if used and the user is logged in). */ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { @@ -126,7 +127,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { * If the user is not logged in, return an error message if a login * error state exists, or return the login form. */ - $content = ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to ); + $content = ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to, $form_id ); } break; @@ -168,7 +169,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { break; case in_array( 'user_edit', $atts ): - $content = wpmem_page_user_edit( $wpmem->regchk, $content ); + $content = wpmem_page_user_edit( $wpmem->regchk, $content, $atts ); break; case in_array( 'forgot_username', $atts ): @@ -206,7 +207,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { } /** - * Handles the logged in status shortcodes [wpmem_logged_in]. + * Restricts content to logged in users using the shortcode [wpmem_logged_in]. * * There are several attributes that can be used with the shortcode: * in|out, sub for subscription only info, id, and role. IDs and roles @@ -221,20 +222,21 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { * @global object $wpmem The WP_Members object. * * @param array $atts { - * The shortcode attributes. - * - * @type string $status - * @type int $id - * @type string $role - * @type string $sub - * @type string $meta_key - * @type string $meta_value - * @type string $product - * @type string $membership + * Attributes of the wpmem_logged_in shortcode. + * + * @type string $status User status to check (in|out) (optional). + * @type int $id The user's ID. Restricts to a specified user by ID (optional). + * @type string $role The user's role. Restrictes to a specific role (optional). + * @type string $sub If the user is a current subscriber (for use with the PayPal extension) (optional). + * @type string $meta_key If the user has a specified meta key (use with meta_value) (optional). + * @type string $meta_value If the user has a specific meta key value (use with meta_key) (optional). + * @tryp string $compare Can specify a comparison operator when using meta_key/meta_value (optional). + * @type string $product If the user has a specific product/membership (optional). + * @type string $membership If the user has a specific product/membership (optional). * } - * @param string $content - * @param string $tag - * @return string $content + * @param string $content Shortcode content. + * @param string $tag The shortcode's tag (wpmem_logged_in). + * @return string|void The restricted content to display if the user meets the criteria. */ function logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) { @@ -350,22 +352,22 @@ function logged_in( $atts, $content = null, $tag = 'wpmem_logged_in' ) { } /** - * Handles the [wpmem_logged_out] shortcode. + * Renders the [wpmem_logged_out] shortcode. * * @since 3.0.0 * @since 3.2.0 Moved to WP_Members_Shortcodes::logged_out(). * - * @param array $atts - * @param string $content - * @param string $tag - * @return string $content + * @param array $atts There are no attributes for this shortcode. + * @param string $content Conent to display if user is logged out. + * @param string $tag The shortcode tab (wpmem_logged_out). + * @return string $content The content, if the user is logged out, otherwise an empty string. */ function logged_out( $atts, $content = null, $tag ) { return ( ! is_user_logged_in() ) ? do_shortcode( $content ) : ''; } /** - * User count shortcode [wpmem_show_count]. + * Displays the user count shortcode [wpmem_show_count]. * * User count displays a total user count or a count of users by specific * role (role="some_role"). It also accepts attributes for counting users @@ -380,15 +382,16 @@ function logged_out( $atts, $content = null, $tag ) { * @param array $atts { * The shortcode attributes. * - * @type string $key - * @type string $value - * @type string $role - * @type string $label + * @type string $key The user meta key, if displaying count by meta key. + * @type string $value The user meta value, if displaying count by meta key. + * @type string $role The user role, if displaying count by role. + * @type string $label Label to display with the count (optional). * } - * @param string $content The shortcode content. - * @return string $content + * @param string $content Does not accept nested content. + * @param string $tag The shortcode's tag (wpmem_show_count). + * @return string $content The user count. */ - function user_count( $atts, $content = null ) { + function user_count( $atts, $content = null, $tag ) { if ( isset( $atts['key'] ) && isset( $atts['value'] ) ) { // If by meta key. global $wpdb; @@ -609,7 +612,7 @@ function fields( $atts, $content = null, $tag ) { $user_info_field = ( isset( $field ) && is_object( $user_info ) ) ? $user_info->{$field} : ''; $result = false; - + // Handle each field type. switch ( $field_type ) { From 89599124ae4a4206fbe8750eede83fd3d836c489 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 3 Jun 2021 11:00:03 -0400 Subject: [PATCH 1404/1694] adds user object as a param in wpmem_validation_link_return_url filter --- includes/class-wp-members-validation-link.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-validation-link.php b/includes/class-wp-members-validation-link.php index 6595e749..a8d3a319 100644 --- a/includes/class-wp-members-validation-link.php +++ b/includes/class-wp-members-validation-link.php @@ -97,8 +97,12 @@ public function add_key_to_email( $arr, $wpmem_fields, $field_data ) { * Filter the return url * * @since 3.3.5 + * @since 3.3.9 Added $user object + * + * @param string The link URL (trailing slash recommended). + * @param object $user */ - $url = apply_filters( 'wpmem_validation_link_return_url', trailingslashit( wpmem_profile_url() ) ); + $url = apply_filters( 'wpmem_validation_link_return_url', trailingslashit( wpmem_profile_url() ), $user ); $query_args = array( 'a' => 'confirm', 'key' => $key, From 5ae5534f12eb76513ce6eb6cb20a50a2c5359dbd Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 3 Jun 2021 11:01:06 -0400 Subject: [PATCH 1405/1694] updated readme for 3.3.9 --- readme.txt | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/readme.txt b/readme.txt index 69273855..52dc1a48 100644 --- a/readme.txt +++ b/readme.txt @@ -2,8 +2,8 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 -Tested up to: 5.6 -Stable tag: 3.3.8 +Tested up to: 5.7 +Stable tag: 3.3.9 License: GPLv2 == Description == @@ -136,8 +136,19 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.8 is an improvement release. * Fixed issue with WooCommerce My Account registration form that caused the last WP-Members field to duplicate the form label. * Fixed issue that caused blanking of unused native WP fields when updating the WP-Members user profile. * Fixed issue in both user email confirmation and password reset links when username contains a space (space was not url encoded). -* Fixed lower bulk menu "add field" item for adding a custom field in the Fields tab. - +* Fixed lower bulk menu "add field" item for adding a custom field in the Fields tab. +* Fixed issue where update settings button may not show on RS Captcha settings tab if plugin not installed (so couldn't change captcha type without going back to main options tab). +* Fixed issue in password reset link if user login value is truncated, causing the user ID to not be found. +* Add "membership" field type to [wpmem_field] accepted field types. +* Changes the "required" field indicator in the default terms checkbox to display next to the label instead of the input. +* Added filter for reCAPTCHA v3 validation score. Default value is 0.5, wpmem_recaptcha_score can filter this value. +* Added additional user views for the Users > All Users screen, can now screen by membership and email confirmed/not confirmed. +* Added additional actions for the Users > All Users screen. +* Added wpmem_user_set_as_confirmed action when user has confirmed their email or the admin has manually confirmed. +* Added wpmem_user_set_as_unconfirmed action when admin has manually unconfirmed a user. +* Added wpmem_validation_link filter. +* Added $defaults to be passed to wpmem_auto_excerpt_args filter. +* Removed jabber, aim, and yim fields from default WP fields for wp_insert_user(). They haven't been native for WP for awhile, and if needed, they can be added as a custom field using the same meta. = 3.3.8 = @@ -154,7 +165,6 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.8 is an improvement release. * Fixes issue with attachment URLs in user profile view when used in multisite. * Added new feature settings for turning on/off WP-Members fields in WooCommerce My Account page registration and checkout registration. * Added captcha support to native WP registration form. -* Removed jabber, aim, and yim fields from default WP fields for wp_insert_user(). They haven't been native for WP for awhile, and if needed, they can be added as a custom field using the same meta. = 3.3.7 = From 3861fef22ad2b91065a679c615f3c84c3e652463 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 7 Jun 2021 17:18:52 -0400 Subject: [PATCH 1406/1694] fix undefined index if "select" option has no pipe, include option for checkbox label --- includes/class-wp-members-forms.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 0117c56d..68cada8f 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -366,6 +366,7 @@ function create_form_field( $args ) { } else { $chk = 'not selected'; } + $pieces[1] = ( isset( $pieces[1] ) ) ? $pieces[1] : ''; // If someone skipped a pipe, treat it as empty. $str = $str . "\n"; } $str = $str . ""; @@ -1024,6 +1025,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { $tag = ( isset( $mixed['tag'] ) ) ? $mixed['tag'] : 'new'; $heading = ( isset( $mixed['heading'] ) ) ? $mixed['heading'] : ''; $redirect_to = ( isset( $mixed['redirect_to'] ) ) ? $mixed['redirect_to'] : ''; + $fields = ( isset( $mixed['fields'] ) ) ? $mixed['fields'] : false; } else { $id = 'default'; $tag = $mixed; @@ -1308,7 +1310,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { // If checkbox label option is enabled. if ( 'checkbox' == $field['type'] && 1 == $field['checkbox_label'] ) { - $input = $input . ' '; + $input = $input . ' '; $fields[ $meta_key ]['label'] = $field['label'] = $label = ''; } } From 58ea84d9dc3dab50d0d4956e4962b41d1e851eca Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 7 Jun 2021 17:19:17 -0400 Subject: [PATCH 1407/1694] tos shortcode check for both https & http --- includes/class-wp-members-shortcodes.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index b9c2a1c2..f0e4cbc1 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -747,7 +747,7 @@ function logout( $atts, $content, $tag ) { * @retrun string $content */ function tos( $atts, $content, $tag ) { - $url = ( strpos( $atts['url'], 'http' ) ) ? $atts['url'] : home_url( $atts['url'] ); + $url = ( strpos( $atts['url'], 'http://' ) || strpos( $atts['url'], 'https://' ) ) ? $atts['url'] : home_url( $atts['url'] ); return esc_url( $url ); } From 78504e7ff069b8966647162c679ab4d9e0392d38 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 7 Jun 2021 17:19:58 -0400 Subject: [PATCH 1408/1694] add wpmem_set_as_logged_in() to sign on process --- includes/class-wp-members-user.php | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index e3bc1673..2957d884 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -75,21 +75,13 @@ function __construct( $settings ) { * @since 3.2.3 Removed wpmem_login_fields filter. * @since 3.2.3 Replaced form collection with WP script to facilitate login with username OR email. * @since 3.2.3 Changed to wp_safe_redirect(). + * @since 3.3.9 Added wpmem_set_as_logged_in() to make sure user is set. * * @return string Returns "loginfailed" if failed login. */ function login() { global $wpmem; - - if ( ! empty( $_POST['log'] ) && ! force_ssl_admin() ) { - $user_name = sanitize_user( $_POST['log'] ); - $user = get_user_by( 'login', $user_name ); - - if ( ! $user && strpos( $user_name, '@' ) ) { - $user = get_user_by( 'email', $user_name ); - } - } $user = wp_signon( array(), is_ssl() ); @@ -97,6 +89,10 @@ function login() { $wpmem->error = $user->get_error_message(); return "loginfailed"; } else { + + // Make sure current user is set. + wpmem_set_as_logged_in( $user->ID ); + $redirect_to = wpmem_get( 'redirect_to', false ); $redirect_to = ( $redirect_to ) ? esc_url_raw( trim( $redirect_to ) ) : esc_url_raw( wpmem_current_url() ); /** This filter defined in wp-login.php */ From 1835722be73fbb8d8fece1f4937ca33a64dd2407 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 9 Jun 2021 20:29:17 -0400 Subject: [PATCH 1409/1694] set version 3.3.9 --- wp-members.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-members.php b/wp-members.php index 2b0362b3..b45fb410 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.3.8 +Version: 3.3.9 Author: Chad Butler Author URI: http://butlerblog.com/ Text Domain: wp-members @@ -64,7 +64,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.3.8' ); +define( 'WPMEM_VERSION', '3.3.9' ); define( 'WPMEM_DB_VERSION', '2.2.1' ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From ec147a81bab9bd254e668d825c13dd0427a09e96 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 9 Jun 2021 20:30:01 -0400 Subject: [PATCH 1410/1694] bug fix for login form shortcode in 3.3.9 --- includes/class-wp-members-shortcodes.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index f0e4cbc1..a0a740d7 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -98,6 +98,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { // Defaults. $redirect_to = ( isset( $atts['redirect_to'] ) ) ? $atts['redirect_to'] : null; $texturize = ( isset( $atts['texturize'] ) ) ? $atts['texturize'] : false; + $form_id = ( isset( $atts['form_id'] ) ) ? $atts['form_id'] : null; $customizer = ( is_customize_preview() ) ? get_theme_mod( 'wpmem_show_logged_out_state', false ) : false; @@ -115,7 +116,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { $content = wpmem_wp_login_form( $atts ); break; - case in_array( 'login', $atts ): + case in_array( 'login', $atts ): if ( is_user_logged_in() && '1' != $customizer ) { /* * If the user is logged in, return any nested content (if any) @@ -127,7 +128,7 @@ function forms( $atts, $content = null, $tag = 'wpmem_form' ) { * If the user is not logged in, return an error message if a login * error state exists, or return the login form. */ - $content = ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to, $form_id ); + $content = ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) ? wpmem_inc_loginfailed() : wpmem_inc_login( 'login', $redirect_to ); } break; From 487f8a52ab85c68dbfa5e806e601436b50f94438 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 9 Jun 2021 20:30:39 -0400 Subject: [PATCH 1411/1694] bug fix for admin manual confirm user nonce in 3.3.9 --- includes/admin/class-wp-members-admin-users.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/includes/admin/class-wp-members-admin-users.php b/includes/admin/class-wp-members-admin-users.php index 91e798fe..dd330cfb 100644 --- a/includes/admin/class-wp-members-admin-users.php +++ b/includes/admin/class-wp-members-admin-users.php @@ -65,8 +65,11 @@ static function insert_hover_links( $actions, $user_object ) { $term = __( 'Unconfirm', 'wp-members' ); } $url = add_query_arg( array( 'action' => $action . '-single', 'user' => $user_object->ID ), "users.php" ); - $url = wp_nonce_url( $url, 'activate-user' ); + $url = wp_nonce_url( $url, 'confirm-user' ); $actions[ $action ] = '' . $term . ''; + + // Resend welcome email (will contain confirmation link if enabled). + //$actions['resend_welcome'] = '' . __( 'Resend welcome email', 'wp-members' ) . ''; } if ( 1 == $wpmem->mod_reg ) { From a537b6435cf73e9b8b5246e770d0d0e4fd362456 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 24 Jul 2021 15:38:37 -0400 Subject: [PATCH 1412/1694] added background color for dropdown in default css --- assets/css/forms/generic-no-float.css | 1 + assets/css/forms/generic-no-float.min.css | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/assets/css/forms/generic-no-float.css b/assets/css/forms/generic-no-float.css index 5e36dafc..06956445 100644 --- a/assets/css/forms/generic-no-float.css +++ b/assets/css/forms/generic-no-float.css @@ -135,6 +135,7 @@ see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ border-radius: 2px; color: rgb(43, 43, 43); margin: 5px 0; + background: none repeat scroll 0% 0% #fff; } #wpmem_reg fieldset, diff --git a/assets/css/forms/generic-no-float.min.css b/assets/css/forms/generic-no-float.min.css index 10c80224..2a2764bd 100644 --- a/assets/css/forms/generic-no-float.min.css +++ b/assets/css/forms/generic-no-float.min.css @@ -1 +1 @@ -#wpmem_msg,.wpmem_msg{background:#f9f9f9;border:1px solid #d3d3d3;border-radius:3px;padding:20px 0 0 0}#wpmem_msg{width:100%}.wpmem_msg{width:74%}#wp-members{width:100%}#wp-members fieldset{border:none;padding:0}#wp-members input{font-family:inherit}#wp-members input[type=password],#wp-members input[type=text]{margin:0 0 4px 0}#wp-members input[type=submit]{padding:5px 6px 4px;margin:0 4px 0 0}#wp-members .button_div{margin-top:4px}#wp-members .err{width:100%;padding:5px;font-family:inherit;border:1px solid #ccc;border-radius:3px}#wpmem_login,#wpmem_reg{color:#2b2b2b;font-family:Arial,sans-serif;font-size:16px;font-weight:400;line-height:1.5}#wpmem_login label,#wpmem_reg label{display:initial}#wpmem_login input[type=password],#wpmem_login input[type=text],#wpmem_reg input[type=date],#wpmem_reg input[type=email],#wpmem_reg input[type=number],#wpmem_reg input[type=password],#wpmem_reg input[type=text],#wpmem_reg input[type=url],#wpmem_reg textarea{border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;padding:8px 10px 8px;background:none repeat scroll 0 0 #fff}#wpmem_login button,#wpmem_login input,#wpmem_reg button,#wpmem_reg input,#wpmem_reg select,#wpmem_reg textarea{-moz-box-sizing:border-box;font-size:100%;margin:0;max-width:100%;vertical-align:baseline}#wpmem_login input:focus,#wpmem_reg input:focus,#wpmem_reg textarea:focus{border:1px solid rgba(0,0,0,.3);outline:0 none}#wpmem_reg select{width:100%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0}#wpmem_login fieldset,#wpmem_reg fieldset{border:none;padding:0;margin:40px 0}#wpmem_login legend,#wpmem_reg legend{font-size:24px;line-height:1;font-weight:700;margin-bottom:10px;width:100%}#wpmem_login .form,#wpmem_reg .form{margin:0;padding:0}#wpmem_login .clear,#wpmem_reg .clear{clear:both}#wpmem_login .holder,#wpmem_reg .holder{background-color:#fff}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_date,#wpmem_reg .div_file,#wpmem_reg .div_image,#wpmem_reg .div_multicheckbox,#wpmem_reg .div_multiselect,#wpmem_reg .div_number,#wpmem_reg .div_radio,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg .div_url{width:74%;margin:0 0 14px 0}#wpmem_login input[type=checkbox]{margin:12px 2px}#wpmem_login .password,#wpmem_login .textbox,#wpmem_login .username,#wpmem_reg .div_textarea textarea,#wpmem_reg .file,#wpmem_reg .image,#wpmem_reg .password,#wpmem_reg .textbox,#wpmem_reg .username{width:100%}#wpmem_reg textarea{height:185px}#wpmem_reg .req{color:#bd3500;font-size:22px;line-height:50%}#wpmem_reg .req-text{margin:20px 0 0 5px}#wpmem_reg .noinput{width:93%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0}#wpmem_reg .captcha{width:74%;margin:5px 0}#wpmem_reg .captcha table{line-height:0}#wpmem_login .link-text{padding:4px 0;width:74%;text-align:right}#tos{margin-right:5px}#wpmem_login .button_div,#wpmem_reg .button_div{width:74%;padding:6px 0;text-align:right}@media screen and (max-width:720px){#wpmem_login .button_div,#wpmem_login .div_text,#wpmem_login label,#wpmem_reg .button_div,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{float:none}#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{width:90%;padding:5px 0 0 0}#wpmem_reg label.textarea{height:26px}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea{width:98%}#wpmem_msg,.wpmem_msg{width:100%}#wpmem_login .button_div,#wpmem_login .link-text,#wpmem_reg .button_div{width:98%}} \ No newline at end of file +#wpmem_msg,.wpmem_msg{background:#f9f9f9;border:1px solid #d3d3d3;border-radius:3px;padding:20px 0 0 0}#wpmem_msg{width:100%}.wpmem_msg{width:74%}#wp-members{width:100%}#wp-members fieldset{border:none;padding:0}#wp-members input{font-family:inherit}#wp-members input[type=password],#wp-members input[type=text]{margin:0 0 4px 0}#wp-members input[type=submit]{padding:5px 6px 4px;margin:0 4px 0 0}#wp-members .button_div{margin-top:4px}#wp-members .err{width:100%;padding:5px;font-family:inherit;border:1px solid #ccc;border-radius:3px}#wpmem_login,#wpmem_reg{color:#2b2b2b;font-family:Arial,sans-serif;font-size:16px;font-weight:400;line-height:1.5}#wpmem_login label,#wpmem_reg label{display:initial}#wpmem_login input[type=password],#wpmem_login input[type=text],#wpmem_reg input[type=date],#wpmem_reg input[type=email],#wpmem_reg input[type=number],#wpmem_reg input[type=password],#wpmem_reg input[type=text],#wpmem_reg input[type=url],#wpmem_reg textarea{border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;padding:8px 10px 8px;background:none repeat scroll 0 0 #fff}#wpmem_login button,#wpmem_login input,#wpmem_reg button,#wpmem_reg input,#wpmem_reg select,#wpmem_reg textarea{-moz-box-sizing:border-box;font-size:100%;margin:0;max-width:100%;vertical-align:baseline}#wpmem_login input:focus,#wpmem_reg input:focus,#wpmem_reg textarea:focus{border:1px solid rgba(0,0,0,.3);outline:0 none}#wpmem_reg select{width:100%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0;background: none repeat scroll 0% 0% #fff;}#wpmem_login fieldset,#wpmem_reg fieldset{border:none;padding:0;margin:40px 0}#wpmem_login legend,#wpmem_reg legend{font-size:24px;line-height:1;font-weight:700;margin-bottom:10px;width:100%}#wpmem_login .form,#wpmem_reg .form{margin:0;padding:0}#wpmem_login .clear,#wpmem_reg .clear{clear:both}#wpmem_login .holder,#wpmem_reg .holder{background-color:#fff}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_date,#wpmem_reg .div_file,#wpmem_reg .div_image,#wpmem_reg .div_multicheckbox,#wpmem_reg .div_multiselect,#wpmem_reg .div_number,#wpmem_reg .div_radio,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg .div_url{width:74%;margin:0 0 14px 0}#wpmem_login input[type=checkbox]{margin:12px 2px}#wpmem_login .password,#wpmem_login .textbox,#wpmem_login .username,#wpmem_reg .div_textarea textarea,#wpmem_reg .file,#wpmem_reg .image,#wpmem_reg .password,#wpmem_reg .textbox,#wpmem_reg .username{width:100%}#wpmem_reg textarea{height:185px}#wpmem_reg .req{color:#bd3500;font-size:22px;line-height:50%}#wpmem_reg .req-text{margin:20px 0 0 5px}#wpmem_reg .noinput{width:93%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0}#wpmem_reg .captcha{width:74%;margin:5px 0}#wpmem_reg .captcha table{line-height:0}#wpmem_login .link-text{padding:4px 0;width:74%;text-align:right}#tos{margin-right:5px}#wpmem_login .button_div,#wpmem_reg .button_div{width:74%;padding:6px 0;text-align:right}@media screen and (max-width:720px){#wpmem_login .button_div,#wpmem_login .div_text,#wpmem_login label,#wpmem_reg .button_div,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{float:none}#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{width:90%;padding:5px 0 0 0}#wpmem_reg label.textarea{height:26px}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea{width:98%}#wpmem_msg,.wpmem_msg{width:100%}#wpmem_login .button_div,#wpmem_login .link-text,#wpmem_reg .button_div{width:98%}} \ No newline at end of file From f791b845375f68e19eca0313d81027eb222c4171 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 16:11:17 -0400 Subject: [PATCH 1413/1694] updated dates --- assets/css/admin.css | 4 ++-- assets/css/forms/generic-no-float.css | 4 ++-- assets/css/forms/generic-rigid.css | 4 ++-- assets/css/forms/wp-members-styles.css | 4 ++-- assets/js/admin.js | 4 ++-- includes/admin/admin.php | 4 ++-- includes/admin/api.php | 4 ++-- includes/admin/dialogs.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-captcha.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-dialogs.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-dropins.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-emails.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-fields.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-options.php | 4 ++-- includes/admin/tabs/class-wp-members-dropins-table.php | 4 ++-- includes/admin/tabs/class-wp-members-fields-table.php | 4 ++-- includes/api/api-email.php | 4 ++-- includes/api/api-forms.php | 4 ++-- includes/api/api-products.php | 4 ++-- includes/api/api-users.php | 4 ++-- includes/api/api-utilities.php | 4 ++-- includes/api/api.php | 4 ++-- includes/class-wp-members-email.php | 4 ++-- includes/class-wp-members-shortcodes.php | 4 ++-- includes/deprecated.php | 4 ++-- includes/install.php | 4 ++-- includes/legacy/dialogs.php | 4 ++-- templates/tos.php | 4 ++-- uninstall.php | 4 ++-- wp-members.php | 2 +- 30 files changed, 59 insertions(+), 59 deletions(-) diff --git a/assets/css/admin.css b/assets/css/admin.css index fde539ee..72ec25c9 100644 --- a/assets/css/admin.css +++ b/assets/css/admin.css @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ diff --git a/assets/css/forms/generic-no-float.css b/assets/css/forms/generic-no-float.css index 06956445..91531667 100644 --- a/assets/css/forms/generic-no-float.css +++ b/assets/css/forms/generic-no-float.css @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ /* diff --git a/assets/css/forms/generic-rigid.css b/assets/css/forms/generic-rigid.css index f146c729..12fa7439 100644 --- a/assets/css/forms/generic-rigid.css +++ b/assets/css/forms/generic-rigid.css @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ /* diff --git a/assets/css/forms/wp-members-styles.css b/assets/css/forms/wp-members-styles.css index a8366720..8ea79c99 100644 --- a/assets/css/forms/wp-members-styles.css +++ b/assets/css/forms/wp-members-styles.css @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ /* diff --git a/assets/js/admin.js b/assets/js/admin.js index 5f52366c..935ebd06 100644 --- a/assets/js/admin.js +++ b/assets/js/admin.js @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ diff --git a/includes/admin/admin.php b/includes/admin/admin.php index c503b698..840eb33c 100644 --- a/includes/admin/admin.php +++ b/includes/admin/admin.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 * * Functions included: * - wpmem_admin diff --git a/includes/admin/api.php b/includes/admin/api.php index 93e93f21..09e39a17 100644 --- a/includes/admin/api.php +++ b/includes/admin/api.php @@ -4,12 +4,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 * * Functions included: * - wpmem_add_custom_email diff --git a/includes/admin/dialogs.php b/includes/admin/dialogs.php index 8d02c11d..6febd447 100644 --- a/includes/admin/dialogs.php +++ b/includes/admin/dialogs.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 * * Functions included: * - wpmem_a_do_warnings diff --git a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php index bfcf7ad3..c5354a45 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-dialogs.php b/includes/admin/tabs/class-wp-members-admin-tab-dialogs.php index a0ce8323..2284ceb3 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-dialogs.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-dialogs.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-dropins.php b/includes/admin/tabs/class-wp-members-admin-tab-dropins.php index a74f59b2..59aa3810 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-dropins.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-dropins.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-emails.php b/includes/admin/tabs/class-wp-members-admin-tab-emails.php index c7589d65..b5eda513 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-emails.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-emails.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-fields.php b/includes/admin/tabs/class-wp-members-admin-tab-fields.php index 99c44b2b..516f1085 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-fields.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-fields.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index 3335d31d..5562f39f 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-dropins-table.php b/includes/admin/tabs/class-wp-members-dropins-table.php index ba56cfd3..ed3c126b 100644 --- a/includes/admin/tabs/class-wp-members-dropins-table.php +++ b/includes/admin/tabs/class-wp-members-dropins-table.php @@ -4,12 +4,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-fields-table.php b/includes/admin/tabs/class-wp-members-fields-table.php index 395b4ea6..a2c06ac1 100644 --- a/includes/admin/tabs/class-wp-members-fields-table.php +++ b/includes/admin/tabs/class-wp-members-fields-table.php @@ -4,12 +4,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/api/api-email.php b/includes/api/api-email.php index de4eed78..5efbe0c3 100644 --- a/includes/api/api-email.php +++ b/includes/api/api-email.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ /** diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 2c11204b..62f431fa 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ if ( ! function_exists( 'wpmem_login_form' ) ): diff --git a/includes/api/api-products.php b/includes/api/api-products.php index 9ce8bdfe..718e0e29 100644 --- a/includes/api/api-products.php +++ b/includes/api/api-products.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ /** diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 19107f39..35222d2f 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ /** diff --git a/includes/api/api-utilities.php b/includes/api/api-utilities.php index 1a53e039..95c625b5 100644 --- a/includes/api/api-utilities.php +++ b/includes/api/api-utilities.php @@ -7,13 +7,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members Utility Functions * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ if ( ! function_exists( 'wpmem_securify' ) ): diff --git a/includes/api/api.php b/includes/api/api.php index 150978de..316d42cc 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 * * Functions included: * - wpmem_redirect_to_login diff --git a/includes/class-wp-members-email.php b/includes/class-wp-members-email.php index 1c21e112..b4259ba0 100644 --- a/includes/class-wp-members-email.php +++ b/includes/class-wp-members-email.php @@ -7,13 +7,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP_Members_Shortcodes * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index a0a740d7..faad5c4a 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -7,13 +7,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP_Members_Shortcodes * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/deprecated.php b/includes/deprecated.php index bf7cef76..f1b606e3 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -8,12 +8,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/install.php b/includes/install.php index 1acff2bb..8aa1c873 100644 --- a/includes/install.php +++ b/includes/install.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index da98af8e..8c087be4 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 * * Functions Included: * - wpmem_inc_loginfailed diff --git a/templates/tos.php b/templates/tos.php index ed1754e6..c5705af6 100644 --- a/templates/tos.php +++ b/templates/tos.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ ?> diff --git a/uninstall.php b/uninstall.php index b34749e3..f1d5a754 100644 --- a/uninstall.php +++ b/uninstall.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2020 Chad Butler + * Copyright (c) 2006-2021 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2020 + * @copyright 2006-2021 */ // Exit if accessed directly. diff --git a/wp-members.php b/wp-members.php index b45fb410..39ffbfb3 100644 --- a/wp-members.php +++ b/wp-members.php @@ -12,7 +12,7 @@ */ /* - Copyright (c) 2006-2020 Chad Butler + Copyright (c) 2006-2021 Chad Butler The name WP-Members(tm) is a trademark of butlerblog.com From f0d325c9a07ae83067d09b3ccb336baa2d0276bf Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 16:20:30 -0400 Subject: [PATCH 1414/1694] check if woo values are set before checking value (avoids errors in new installs) --- includes/class-wp-members.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 9e4b7919..a5ed05f0 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -480,12 +480,12 @@ function load_hooks() { if ( wpmem_is_woo_active() ) { // Handle "My Account" page registration. - if ( 1 == $this->woo['add_my_account_fields'] ) { + if ( isset( $this->woo['add_my_account_fields'] ) && 1 == $this->woo['add_my_account_fields'] ) { add_action( 'woocommerce_register_form', 'wpmem_woo_register_form' ); add_action( 'woocommerce_register_post', 'wpmem_woo_reg_validate', 10, 3 ); } // Handle Registration checkout - if ( 1 == $this->woo['add_checkout_fields'] && ! is_user_logged_in() ) { + if ( isset( $this->woo['add_checkout_fields'] ) && 1 == $this->woo['add_checkout_fields'] && ! is_user_logged_in() ) { add_filter( 'woocommerce_checkout_fields', 'wpmem_woo_checkout_form' ); add_action( 'woocommerce_checkout_update_order_meta', 'wpmem_woo_checkout_update_meta' ); //add_action( 'woocommerce_save_account_details_errors', 'wpmem_woo_reg_validate' ); From d4702be55e9d3e45221361f33a2c6df2d1f0b0f3 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 16:22:02 -0400 Subject: [PATCH 1415/1694] add inline documentation --- includes/class-wp-members-forms.php | 32 ++++++++++++++++++++++++++++- includes/legacy/dialogs.php | 1 + 2 files changed, 32 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 68cada8f..e0444769 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -766,7 +766,37 @@ function login_form( $mixed, $arr = array() ) { * @since 2.9.0 * @since 3.3.0 Passes $defaults as an argument. * - * @param array $args An array of arguments to merge with defaults. + * @param array $args { + * An array of arguments to merge with defaults. + * + * @type string $heading_before Default: '' + * @type string $heading_after Default: '' + * @type string $fieldset_before Default: '
    ' + * @type string $fieldset_after Default: '
    ' + * @type string $main_div_before Default: '
    ' + * @type string $main_div_after Default: '
    ' + * @type string $txt_before Default: '' (considered deprecated) + * @type string $txt_after Default: '' (considered deprecated) + * @type string $row_before Default: '' + * @type string $row_after Default: '' + * @type string $buttons_before Default: '
    ' + * @type string $buttons_after Default: '
    ' + * @type string $link_before Default: '' + * @type string $link_span_before Default: '' + * @type string $link_span_after Default: '' + * @type string $form_id Default: 'wpmem_' . $action . '_form' (for example, wpmem_login_form or wpmem_pwdreset_form) + * @type string $form_class Default: 'form' + * @type string $button_id Default: '' + * @type string $button_class Default: buttons' + * @type boolean $strip_breaks Default: true (if true, strips all line breaks from the generated HTML) + * @type boolean $wrap_inputs Default: true (if true, includes main_div_before/after wrappers around input tags) + * @type boolean $remember_check Default: true + * @type string $n Default: "\n" (the new line character if breaks are not stripped (see $strip_breaks)) + * @type string $t Default: "\t" (the line indent character if breaks are not stripped (see $strip_breaks)) + * @type string $redirect_to Default: (the $redirec_to argument passed to the function) + * @type boolean $login_form_action Default: true (if true, adds the WP login_form action) + * } * @param string $arr['action'] The action being performed by the form. login|pwdreset|pwdchange|getusername. */ $args = apply_filters( 'wpmem_login_form_args', $defaults, $arr['action'] ); diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index 8c087be4..c74a9eb7 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -499,6 +499,7 @@ function wpmem_page_pwd_reset( $wpmem_regchk, $content ) { * Creates a user edit page. * * @since 2.7.6 + * @since 3.3.9 Added $atts * * @global object $wpmem * @global string $wpmem_a From 38766e21af75b923bac34278d55fa14a00ef4458 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 16:22:29 -0400 Subject: [PATCH 1416/1694] cli updates, add get_role --- includes/cli/class-wp-members-cli-user.php | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/includes/cli/class-wp-members-cli-user.php b/includes/cli/class-wp-members-cli-user.php index cba95482..a070caf4 100644 --- a/includes/cli/class-wp-members-cli-user.php +++ b/includes/cli/class-wp-members-cli-user.php @@ -193,16 +193,19 @@ public function detail( $args, $assoc_args ) { WP_CLI::error( 'User does not exist. Try wp user list' ); } $all = ( $assoc_args['all'] ) ? true : false; - $this->display_user_detail( $user->ID, $all ); + $this->display_user_detail( $user, $all ); } /** * Handles user detail display. * * @since 3.3.5 + * + * @param object $user + * @param $all */ - private function display_user_detail( $user_id, $all ) { - WP_CLI::line( __( 'User: %s', 'wp-members' ) ); + private function display_user_detail( $user, $all ) { + WP_CLI::line( sprintf( __( 'User: %s', 'wp-members' ), $user->user_login ); $values = wpmem_user_data( $user_id, $all ); foreach ( $values as $key => $meta ) { @@ -235,6 +238,16 @@ public function confirm( $args, $assoc_args ) { WP_CLI::success( 'User confirmed' ); } } + + public function get_role( $args, $assoc_args ) { + $all = ( isset( $assoc_args['all'] ) ) ? true : false; + $role = wpmem_get_user_role( $assoc_args['id'], $all ); + if ( is_array( $role ) ) { + + } else { + WP_CLI::line( __( 'User role: %s', 'wp-members' ), $role ); + } + } } } WP_CLI::add_command( 'mem user', 'WP_Members_CLI_User' ); \ No newline at end of file From fd45e6476deb55c8d9e659024b99787be2f8778c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 16:23:07 -0400 Subject: [PATCH 1417/1694] check for false explicitly --- includes/class-wp-members-user.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 2957d884..5e94fb49 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -861,7 +861,7 @@ function set_as_logged_in( $user_id ) { * product). Maybe add role checking to the expiration block if both exist. * * @global object $wpmem - * @param mixed $product + * @param mixed $product Accepts a single membership slug/meta, or an array of multiple memberships. * @param int $user_id (optional) * @return bool $access */ @@ -878,7 +878,7 @@ function has_access( $product, $user_id = false ) { $memberships = ( false == $user_id ) ? $this->access : wpmem_get_user_products( $user_id ); // Current user or requested user. - $user_id = ( ! $user_id ) ? get_current_user_id() : $user_id; + $user_id = ( false === $user_id ) ? get_current_user_id() : $user_id; // Start by assuming no access. $access = false; From 164a3db76c89826943a713dc00cceceec98017b8 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 16:24:05 -0400 Subject: [PATCH 1418/1694] wpmem_get_user_role() to check all roles (array) or just current role (string) --- includes/api/api-users.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 35222d2f..8183f970 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -37,11 +37,13 @@ function wpmem_is_user( $user_id ) { * @since 3.3.0 * * @param int $user_id + * @param boolean $all If true, all roles as an array; if false, just the current role. * @return mixed If the user is set and has roles, the current user role, otherwise false. */ -function wpmem_get_user_role( $user_id = false ) { +function wpmem_get_user_role( $user_id = false, $all = false ) { $user = ( $user_id ) ? get_userdata( $user_id ) : wp_get_current_user(); - return ( $user ) ? current( $user->roles ) : false; + $role = ( ! $all ) ? current( $user->roles ) : $user->roles; + return ( $user ) ? $role : false; } /** From 27ae96e00fcb6f7b4c3e39825c5f191fd6e25aa7 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 16:24:48 -0400 Subject: [PATCH 1419/1694] updates to user api functions --- includes/api/api-users.php | 28 ++++++++++++++++++++++++---- 1 file changed, 24 insertions(+), 4 deletions(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 8183f970..a9ab448b 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -221,15 +221,33 @@ function wpmem_update_user_role( $user_id, $role, $action = 'set' ) { * @since 3.2.0 * @since 3.2.3 Reversed order of arguments. * - * @param mixed $product + * @param mixed $product Accepts a single membership slug/meta, or an array of multiple memberships. * @param integer $user_id User ID (optional|default: false). - * @return boolean $access If user has access. + * @return boolean $access True if user has access, otherwise false. */ function wpmem_user_has_access( $product, $user_id = false ) { global $wpmem; return $wpmem->user->has_access( $product, $user_id ); } +/** + * Checks if user expiration is current. + * + * Similar to wpmem_user_has_access(), but specifically checks the + * expiration date for a specified product (must be expiration product). + * + * @since 3.3.9 + * + * @param mixed $product + * @param integer $user_id + * @return boolean + */ +function wpmem_user_is_current( $product, $user_id = false ) { + global $wpmem; + // @todo Finish this. + return; +} + /** * Sets product access for a user. * @@ -269,6 +287,7 @@ function wpmem_remove_user_product( $product, $user_id = false ) { * * @global stdClass $wpmem * @param int $user_id + * @return array */ function wpmem_get_user_products( $user_id = false ) { global $wpmem; @@ -419,11 +438,12 @@ function wpmem_create_membership_number( $args ) { * @since 3.2.4 Renamed from wpmem_a_activate_user(). * @since 3.3.0 Moved to user API. * @since 3.3.5 Added $notify argument. + * @since 3.4.0 Added $set_pwd argument. * * @param int $user_id * @param bool $notify Send notification to user (optional, default: true). */ -function wpmem_activate_user( $user_id, $notify = true ) { +function wpmem_activate_user( $user_id, $notify = true, $set_pwd = false ) { global $wpmem; @@ -431,7 +451,7 @@ function wpmem_activate_user( $user_id, $notify = true ) { $new_pass = ''; // If passwords are user defined skip this. - if ( ! wpmem_user_sets_password() ) { + if ( true == $set_pwd || ! wpmem_user_sets_password() ) { $new_pass = wp_generate_password(); wp_set_password( $new_pass, $user_id ); } From 8e9aec153931abb1499aa0caf9eb3a6c994431a0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 16:25:32 -0400 Subject: [PATCH 1420/1694] add logout link function wpmem_logout_link() --- includes/api/api.php | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/includes/api/api.php b/includes/api/api.php index 316d42cc..176fd864 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -326,6 +326,24 @@ function wpmem_loginout( $args = array(), $echo = false ) { return $wpmem->loginout_args( $args ); } +/** + * Gets a logout link. + * + * @since 3.4.0 + * + * @return string Logout link. + */ +function wpmem_logout_link() { + /** + * Filter the log out link. + * + * @since 2.8.3 + * + * @param string The default logout link. + */ + return apply_filters( 'wpmem_logout_link', add_query_arg( 'a', 'logout' ) ); +} + /** * Dispalays requested dialog. * From 68092f5edaa8fba66b07b30c07bb436c8e7ef4a3 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 16:25:58 -0400 Subject: [PATCH 1421/1694] if no login page is set, return wp login url --- includes/api/api.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/includes/api/api.php b/includes/api/api.php index 176fd864..f21a0b04 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -101,6 +101,7 @@ function wpmem_get_block_setting( $post_id ) { * * @since 3.1.1 * @since 3.1.2 Added redirect_to parameter. + * @since 3.4.0 If no login page is set, return the wp_login_url(). * * @global object $wpmem The WP_Members object. * @param string $redirect_to URL to return to (optional). @@ -108,10 +109,12 @@ function wpmem_get_block_setting( $post_id ) { */ function wpmem_login_url( $redirect_to = false ) { global $wpmem; + // If no login page is set, get WP login url. + $login_url = ( isset( $wpmem->user_pages['login'] ) ) ? $wpmem->user_pages['login'] : wp_login_url(); if ( $redirect_to ) { - $url = add_query_arg( 'redirect_to', urlencode( $redirect_to ), $wpmem->user_pages['login'] ); + $url = add_query_arg( 'redirect_to', urlencode( $redirect_to ), $login_url ); } else { - $url = $wpmem->user_pages['login']; + $url = $login_url; } return $url; } From 9774f74abfda02ab3f3759bcaa38016c2a746372 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 26 Jul 2021 20:20:28 -0400 Subject: [PATCH 1422/1694] added setting option for html email support --- .../class-wp-members-admin-tab-emails.php | 8 ++++++- includes/class-wp-members-email.php | 24 +++++++++++++++++++ 2 files changed, 31 insertions(+), 1 deletion(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-emails.php b/includes/admin/tabs/class-wp-members-admin-tab-emails.php index b5eda513..59540cf8 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-emails.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-emails.php @@ -73,6 +73,10 @@ static function build_settings() {
  •   John Smith
    email->html, 1, true ); ?> />

    '; // determine the field type and generate accordingly. + + // All fields use the following: + $args['name'] = $meta_key; + $args['type'] = $field['type']; + $args['required'] = $field['required']; + + $args['placeholder'] = ( isset( $field['placeholder'] ) ) ? $field['placeholder'] : ''; + $args['pattern'] = ( isset( $field['pattern'] ) ) ? $field['pattern'] : ''; + $args['title'] = ( isset( $field['title'] ) ) ? $field['title'] : ''; switch ( $field['type'] ) { case( 'select' ): $val = ( isset( $_POST[ $meta_key ] ) ) ? sanitize_text_field( $_POST[ $meta_key ] ) : ''; - echo wpmem_create_formfield( $meta_key, $field['type'], $field['values'], $val ); + $args['value'] = $field['values']; + $args['compare'] = $val; + echo wpmem_form_field( $args ); break; case( 'textarea' ): - echo ''; + $args['value'] = ( isset( $_POST[ $meta_key ] ) ) ? esc_textarea( $_POST[ $meta_key ] ) : ''; + echo wpmem_form_field( $args ); break; case( 'checkbox' ): $val = ( isset( $_POST[ $meta_key ] ) ) ? sanitize_text_field( $_POST[ $meta_key ] ) : ''; $val = ( ! $_POST && $field['checked_default'] ) ? $field['checked_value'] : $val; - echo wpmem_create_formfield( $meta_key, $field['type'], $field['checked_value'], $val ); + $args['value'] = $field['checked_value']; + $args['compare'] = $val; + echo wpmem_form_field( $args ); break; case( 'multiselect' ): case( 'multicheckbox' ): case( 'radio' ): case( 'membership' ); - $valtochk = ( isset( $_POST[ $meta_key ] ) ) ? sanitize_text_field( $_POST[ $meta_key ] ) : ''; - $formfield_args = array( - 'name' => $meta_key, - 'type' => $field['type'], - 'value' => $field['values'], - 'compare' => $valtochk, - 'required' => $field['required'], - ); + $args['value'] = $field['values']; + $args['compare'] = ( isset( $_POST[ $meta_key ] ) ) ? sanitize_text_field( $_POST[ $meta_key ] ) : ''; if ( 'multicheckbox' == $field['type'] || 'multiselect' == $field['type'] ) { - $formfield_args['delimiter'] = $field['delimiter']; + $args['delimiter'] = $field['delimiter']; } - echo $this->create_form_field( $formfield_args ); + echo wpmem_form_field( $args ); break; case( 'file' ): @@ -1968,8 +1977,8 @@ function wp_newuser_form() { break; default: - $value = ( isset( $_POST[ $meta_key ] ) ) ? esc_attr( $_POST[ $meta_key ] ) : ''; - echo ''; + $args['value'] = ( isset( $_POST[ $meta_key ] ) ) ? esc_attr( $_POST[ $meta_key ] ) : ''; + echo wpmem_form_field( $args ); break; } @@ -1985,7 +1994,7 @@ function wp_newuser_form() { ' . $this->create_form_field( array( 'name' => 'activate_user', 'type' => 'checkbox', 'value' => 1, 'compare' => '' ) ) . '' . wpmem_form_field( array( 'name' => 'activate_user', 'type' => 'checkbox', 'value' => 1, 'compare' => '' ) ) . '
    - - - - - - '; ?> - membership->products as $key => $value ) { - $checked = ( $user_products && array_key_exists( $key, $user_products ) ) ? "checked" : ""; - echo ""; - echo ''; - - // If user has date, display that; otherwise placeholder - $date_value = ( isset( $user_products[ $key ] ) && 1 != $user_products[ $key ] && 0 != $user_products[ $key ] && '' != $user_products[ $key ] ) ? date( 'Y-m-d', $user_products[ $key ] ) : ""; - $placeholder = ( ! isset( $user_products[ $key ] ) ) ? 'placeholder="' . __( 'Expiration date (optional)', 'wp-members' ) . '" ' : ''; - $product_date_field = ' '; - - if ( isset( $user_products[ $key ] ) ) { - echo ''; - if ( $user_products[ $key ] != 1 ) { - echo ''; - } else { - echo ''; - } - } else { - if ( isset( $value['expires'] ) && ! empty( $value['expires'] ) ) { - echo ''; - echo ''; + echo '

    ' . __( 'Membership Access', 'wp-members' ) . '

    '; + if ( ! empty( $wpmem->membership->products ) ) { + echo '
    ' . __( 'Status', 'wp-members' ) . '' . __( 'Membership', 'wp-members' ) . '' . __( 'Enabled?', 'wp-members' ) . '' . __( 'Expires', 'wp-members' ) . '
    - ' . $value['title'] . '' . $product_date_field . ' ' . $product_date_field . '
    + + + + + + '; ?> + membership->products as $key => $value ) { + $checked = ( $user_products && array_key_exists( $key, $user_products ) ) ? "checked" : ""; + echo ""; + echo ''; + + // If user has date, display that; otherwise placeholder + $date_value = ( isset( $user_products[ $key ] ) && 1 != $user_products[ $key ] && 0 != $user_products[ $key ] && '' != $user_products[ $key ] ) ? date( 'Y-m-d', $user_products[ $key ] ) : ""; + $placeholder = ( ! isset( $user_products[ $key ] ) ) ? 'placeholder="' . __( 'Expiration date (optional)', 'wp-members' ) . '" ' : ''; + $product_date_field = ' '; + + if ( isset( $user_products[ $key ] ) ) { + echo ''; + if ( $user_products[ $key ] != 1 ) { + echo ''; + } else { + echo ''; + } } else { - echo ''; - } - } - echo ''; - } + if ( isset( $value['expires'] ) && ! empty( $value['expires'] ) ) { + echo ''; + echo ''; + } else { + echo ''; + } + } + echo ''; + } - ?>
    ' . __( 'Status', 'wp-members' ) . '' . __( 'Membership', 'wp-members' ) . '' . __( 'Enabled?', 'wp-members' ) . '' . __( 'Expires', 'wp-members' ) . '
    + ' . $value['title'] . '' . $product_date_field . '  
    ' . $product_date_field . ' 
    - - + ' . sprintf( __( 'No memberships have been created. %sCreate new memberships here%s', 'wp-members' ), '', '' ); + } } } From 5410171289c0f186aae424bf1c4a7f0c17f83aa4 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 27 Aug 2021 08:52:18 -0400 Subject: [PATCH 1458/1694] added rocketgeek utility library --- .../libraries/rocketgeek-utilities/arrays.php | 58 +++++++ .../libraries/rocketgeek-utilities/dates.php | 38 +++++ .../libraries/rocketgeek-utilities/forms.php | 137 ++++++++++++++++ .../libraries/rocketgeek-utilities/loader.php | 7 + .../rocketgeek-utilities/strings.php | 50 ++++++ .../rocketgeek-utilities/utilities.php | 153 ++++++++++++++++++ 6 files changed, 443 insertions(+) create mode 100644 includes/libraries/rocketgeek-utilities/arrays.php create mode 100644 includes/libraries/rocketgeek-utilities/dates.php create mode 100644 includes/libraries/rocketgeek-utilities/forms.php create mode 100644 includes/libraries/rocketgeek-utilities/loader.php create mode 100644 includes/libraries/rocketgeek-utilities/strings.php create mode 100644 includes/libraries/rocketgeek-utilities/utilities.php diff --git a/includes/libraries/rocketgeek-utilities/arrays.php b/includes/libraries/rocketgeek-utilities/arrays.php new file mode 100644 index 00000000..3c659f51 --- /dev/null +++ b/includes/libraries/rocketgeek-utilities/arrays.php @@ -0,0 +1,58 @@ + $b_value ) { + + // check that expected value exists in the array + if ( ! in_array( $b_value, $a, true ) ) { + return false; + } + + // check that expected value occurs the same amount of times in both arrays + if ( count( array_keys( $a, $b_value, true ) ) !== count( array_keys( $b, $b_value, true ) ) ) { + return false; + } + + } + + return true; +} +endif; + +if ( ! function_exists( 'rktgk_array_insert' ) ): +/** + * Inserts array items at a specific point in an array. + * + * @since 1.0.0 + * + * @param array $array Original array. + * @param array $new Array of new items to insert into $array. + * @param string $key Array key to insert new items before or after. + * @param string $loc Location to insert relative to $key (before|after) default:after. + * @return array Original array with new items inserted. + */ +function rktgk_array_insert( array $array, array $new, $key, $loc = 'after' ) { + $keys = array_keys( $array ); + if ( 'before' == $loc ) { + $pos = (int) array_search( $key, $keys ); + } else { + $index = array_search( $key, $keys ); + $pos = ( false === $index ) ? count( $array ) : $index + 1; + } + return array_merge( array_slice( $array, 0, $pos ), $new, array_slice( $array, $pos ) ); +} +endif; diff --git a/includes/libraries/rocketgeek-utilities/dates.php b/includes/libraries/rocketgeek-utilities/dates.php new file mode 100644 index 00000000..9bbc2429 --- /dev/null +++ b/includes/libraries/rocketgeek-utilities/dates.php @@ -0,0 +1,38 @@ + $args ); + } + + $defaults = array( + 'date_format' => get_option( 'date_format' ), + 'time_format' => get_option( 'time_format' ), + 'localize' => true, + 'timestamp' => false, + ); + + $args = wp_parse_args( $args, $defaults ); + + /** + * Filter the date display and format settings. + * + * @since 1.0.0 + * + * @param arrag $args + */ + $args = apply_filters( 'rktgk_format_date_args', $args ); + $date = ( true === $args['timestamp'] ) ? $args['date'] : strtotime( $args['date'] ); + $date = ( true === $args['localize'] ) ? date_i18n( $args['date_format'], $date ) : date( $args['date_format'], $date ); + return $date; +} +endif; \ No newline at end of file diff --git a/includes/libraries/rocketgeek-utilities/forms.php b/includes/libraries/rocketgeek-utilities/forms.php new file mode 100644 index 00000000..2a790071 --- /dev/null +++ b/includes/libraries/rocketgeek-utilities/forms.php @@ -0,0 +1,137 @@ + $val ) { + $data[ $key ] = ( 'integer' == $type || 'int' == $type ) ? intval( $val ) : sanitize_text_field( $val ); + } + } + return $data; +} +endif; + +if ( ! function_exists( 'rktgk_sanitize_field' ) ): +/** + * Sanitizes field based on field type. + * + * Obviously, this isn't an all inclusive function of every WordPress + * sanitization function. It is intended to handle sanitization of + * WP-Members form input and therefore includes the necessary methods + * that would relate to the WP-Members custom field types and can thus + * be used by looping through form data when the WP-Members fields are + * handled and validated. + * + * @since 1.0.0 + * + * @param string $data + * @param string $type + * @return string $sanitized_data + */ +function rktgk_sanitize_field( $data, $type = '' ) { + + switch ( $type ) { + + case 'multiselect': + case 'multicheckbox': + case 'multipleselect': + case 'multiplecheckbox': + $sanitized_data = rktgk_sanitize_array( $data ); + break; + + case 'textarea': + $sanitized_data = sanitize_textarea_field( $data ); + break; + + case 'email': + $sanitized_data = sanitize_email( $data ); + break; + + case 'file': + case 'image': + $sanitized_data = sanitize_file_name( $data ); + break; + + case 'int': + case 'integer': + case 'number': + $sanitized_data = intval( $data ); + break; + + default: + $sanitized_data = sanitize_text_field( $data ); + break; + } + + return $sanitized_data; +} +endif; \ No newline at end of file diff --git a/includes/libraries/rocketgeek-utilities/loader.php b/includes/libraries/rocketgeek-utilities/loader.php new file mode 100644 index 00000000..4bd036e0 --- /dev/null +++ b/includes/libraries/rocketgeek-utilities/loader.php @@ -0,0 +1,7 @@ + $before, + 'after' => $after, + 'needle' => $needle, + ); + } + } + return $new; +} +endif; \ No newline at end of file diff --git a/includes/libraries/rocketgeek-utilities/utilities.php b/includes/libraries/rocketgeek-utilities/utilities.php new file mode 100644 index 00000000..e29afe79 --- /dev/null +++ b/includes/libraries/rocketgeek-utilities/utilities.php @@ -0,0 +1,153 @@ + Date: Fri, 27 Aug 2021 08:55:27 -0400 Subject: [PATCH 1459/1694] use rocketgeek utilities library --- includes/api/api-forms.php | 8 +-- includes/api/api-users.php | 12 +--- includes/api/api-utilities.php | 105 ++++++---------------------- includes/api/api.php | 13 +--- includes/class-wp-members-forms.php | 48 ------------- includes/class-wp-members.php | 2 + includes/deprecated.php | 13 ++++ 7 files changed, 44 insertions(+), 157 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 7fec3bd0..3eba044c 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -313,6 +313,7 @@ function wpmem_fields( $tag = '', $form = 'default' ) { * This is an API wrapper for WP_Members_Forms::sanitize_class(). * * @since 3.2.9 + * @since 3.4.0 Now an alias for rktgk_sanitize_class(). * * @global object $wpmem * @@ -320,8 +321,7 @@ function wpmem_fields( $tag = '', $form = 'default' ) { * @return string sanitized_class */ function wpmem_sanitize_class( $class ) { - global $wpmem; - return $wpmem->forms->sanitize_class( $class ); + return rktgk_sanitize_class( $class ); } /** @@ -331,6 +331,7 @@ function wpmem_sanitize_class( $class ) { * * @since 3.2.9 * @since 3.3.7 Added optional $type + * @since 3.4.0 Now an alias for rktgk_sanitize_array(). * * @global object $wpmem * @@ -339,8 +340,7 @@ function wpmem_sanitize_class( $class ) { * @return array $data */ function wpmem_sanitize_array( $data, $type = false ) { - global $wpmem; - return $wpmem->forms->sanitize_array( $data, $type ); + return rktgk_sanitize_array( $data, $type ); } /** diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 0d9e0e07..0b17dbb3 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -769,19 +769,11 @@ function wpmem_user_register( $tag ) { * @link https://gist.github.com/pippinsplugins/9641841 * * @since 3.3.0 + * @since 3.4.0 Now an alias for rktgk_get_user_ip(); * * @return string $ip. */ function wpmem_get_user_ip() { - if ( ! empty( $_SERVER['HTTP_CLIENT_IP'] ) ) { - //check ip from share internet - $ip = $_SERVER['HTTP_CLIENT_IP']; - } elseif ( ! empty( $_SERVER['HTTP_X_FORWARDED_FOR'] ) ) { - //to check ip is pass from proxy - $ip = $_SERVER['HTTP_X_FORWARDED_FOR']; - } else { - $ip = $_SERVER['REMOTE_ADDR']; - } /** * Filter the IP result. * @@ -789,7 +781,7 @@ function wpmem_get_user_ip() { * * @param string $ip */ - return apply_filters( 'wpmem_get_ip', $ip ); + return apply_filters( 'wpmem_get_ip', rktgk_get_user_ip( $ip ) ); } /** diff --git a/includes/api/api-utilities.php b/includes/api/api-utilities.php index 67a86944..b97250a0 100644 --- a/includes/api/api-utilities.php +++ b/includes/api/api-utilities.php @@ -54,43 +54,29 @@ function wpmem_get_excluded_meta( $tag ) { return $wpmem->forms->excluded_fields( $tag ); } -/** - * Returns http:// or https:// depending on ssl. - * - * @since 2.9.8 - * @deprecated 3.2.3 Use wpmem_force_ssl() instead. - * - * @return string https://|http:// depending on whether ssl is being used. - */ -function wpmem_use_ssl() { - return ( is_ssl() ) ? 'https://' : 'http://'; -} - /** * Forces a URL to be secure (ssl). * * @since 3.2.3 + * @since 3.4.0 Now an alias for rktgk_force_ssl() * * @param string $url URL to be make secure. * @return string The secure URL. */ function wpmem_force_ssl( $url ) { - return ( is_ssl() ) ? preg_replace( "/^http:/i", "https:", $url ) : $url; + return rktgk_force_ssl( $url ); } /** * Log debugging errors. * * @since 3.1.2 + * @since 3.4.0 Now an alias for rktgk_write_log(). * * @param mixed (string|array|object) $log Information to write in the WP debug file. */ -function wpmem_write_log ( $log ) { - if ( is_array( $log ) || is_object( $log ) ) { - error_log( print_r( $log, true ) ); - } else { - error_log( $log ); - } +function wpmem_write_log( $log ) { + rktgk_write_log( $log ); } /** @@ -103,6 +89,7 @@ function wpmem_write_log ( $log ) { * the parts before, after, and the "needle" are returned. * * @since 3.2.0 + * @since 3.4.0 Now an alias for rktgk_get_sub_str(). * * @param string $needle * @param string $haystack @@ -117,27 +104,7 @@ function wpmem_write_log ( $log ) { * } */ function wpmem_get_sub_str( $needle, $haystack, $position = 'after', $keep_needle = true ) { - $pos = strpos( $haystack, $needle ); - if ( false === $pos ) { - return $haystack; - } else { - if ( 'before' == $position ) { - $new = ( substr( $haystack, 0, $pos ) ); - $new = ( $keep_needle ) ? $string . $needle : $new; - } elseif ( 'after' == $position ) { - $new = ( substr( $haystack, $pos+strlen( $needle ) ) ); - $new = ( $keep_needle ) ? $needle . $string : $new; - } elseif ( 'split' == $position ) { - $before = ( substr( $haystack, 0, $pos ) ); - $after = ( substr( $haystack, $pos+strlen( $needle ) ) ); - $new = array( - 'before' => $before, - 'after' => $after, - 'needle' => $needle, - ); - } - } - return $new; + return rktgk_get_sub_str( $needle, $haystack, $position, $keep_needle ); } if ( ! function_exists( 'wpmem_do_excerpt' ) ): @@ -185,6 +152,7 @@ function wpmem_texturize( $content ) { * * @since 3.1.6 * @since 3.2.3 Moved to utilities api. + * @since 3.4.0 Now an alias for rktgk_array_insert() * * @param array $array Original array. * @param array $new Array of new items to insert into $array. @@ -193,14 +161,7 @@ function wpmem_texturize( $content ) { * @return array Original array with new items inserted. */ function wpmem_array_insert( array $array, array $new, $key, $loc = 'after' ) { - $keys = array_keys( $array ); - if ( 'before' == $loc ) { - $pos = (int) array_search( $key, $keys ); - } else { - $index = array_search( $key, $keys ); - $pos = ( false === $index ) ? count( $array ) : $index + 1; - } - return array_merge( array_slice( $array, 0, $pos ), $new, array_slice( $array, $pos ) ); + return rktgk_array_insert( $array, $new, $key, $loc ); } /** @@ -220,34 +181,22 @@ function wpmem_load_dropins() { * Display a localized date based on the WP date format setting. * * @since 3.2.4 + * @since 3.4.0 Now an alias for rktgk_format_date(). * * @param mixed $args * @return date $date */ function wpmem_format_date( $args ) { - if ( ! is_array( $args ) ) { - $args = array( 'date' => $args ); - } - - $defaults = array( - 'date_format' => get_option( 'date_format' ), - 'localize' => true, - 'timestamp' => false, - ); - - $args = wp_parse_args( $args, $deafults ); - /** * Filter the date display and format settings. * * @since 3.2.4 + * @deprecated 3.4.0 Use rktgk_format_date instead. * * @param arrag $args */ $args = apply_filters( 'wpmem_format_date_args', $args ); - $date = ( true === $args['timestamp'] ) ? $args['date'] : strtotime( $args['date'] ); - $date = ( true === $args['localize'] ) ? date_i18n( $args['date_format'], $date ) : date( $args['date_format'], $date ); - return $date; + return rktgk_format_date( $args ); } /** @@ -266,6 +215,7 @@ function wpmem_format_date( $args ) { * @link https://codesymphony.co/dont-do_shortcode/ * * @since 3.2.5 + * @since 3.4.0 Now an alias for rktgk_do_shortcode(). * * @param string $tag The shortcode whose function to call. * @param array $atts The attributes to pass to the shortcode function. Optional. @@ -273,15 +223,8 @@ function wpmem_format_date( $args ) { * * @return string|bool False on failure, the result of the shortcode on success. */ -function wpmem_do_shortcode( $tag, array $atts = array(), $content = null ) { - - global $shortcode_tags; - - if ( ! isset( $shortcode_tags[ $tag ] ) ) { - return false; - } - - return call_user_func( $shortcode_tags[ $tag ], $atts, $content, $tag ); +function rktgk_do_shortcode( $tag, array $atts = array(), $content = null ) { + return rktgk_do_shortcode( $tag, $atts, $content ); } /** @@ -313,43 +256,37 @@ function wpmem_user_sets_password() { * sanitizes each individual array element. * * @since 3.3.0 + * @since 3.4.0 Now an alias for rktgk_maybe_unserialize(). * * @param mixed $original * @return mixed $original */ function wpmem_maybe_unserialize( $original ) { - if ( is_serialized( $original ) ) { // don't attempt to unserialize data that wasn't serialized going in - $original = unserialize( $original ); - } - return ( is_array( $original ) ) ? wpmem_sanitize_array( $original ) : $original; + return rktgk_maybe_unserialize( $original ); } /** * Determines whether to use a .min suffix for a script/style file. * * @since 3.3.0 + * @since 3.4.0 Now an alias for rktgk_get_suffix(). * * @param boolean $echo */ function wpmem_get_suffix( $echo = false ) { - $suffix = ( defined( 'SCRIPT_DEBUG' ) && true === SCRIPT_DEBUG ) ? '' : '.min'; - if ( true === $echo ) { - echo $suffix; - return; - } else { - return $suffix; - } + return rktgk_get_suffix( $echo ); } /** * Checks if WooCommerce is active. * * @since 3.3.7 + * @since 3.4.0 Now an alias for rktgk_is_woo_active(). * * @return boolean */ function wpmem_is_woo_active() { - return ( class_exists( 'woocommerce' ) ) ? true : false; + return rktgk_is_woo_active(); } /** diff --git a/includes/api/api.php b/includes/api/api.php index c6e64783..3e718c62 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -303,6 +303,7 @@ function wpmem_login_status( $echo = true, $tag = false ) { * sanitized or escaped depending on how it is used. * * @since 3.1.3 + * @since 3.4.0 Now an alias for rktgk_get(). * * @param string $tag The form field or query string. * @param string $default The default value (optional). @@ -310,17 +311,7 @@ function wpmem_login_status( $echo = true, $tag = false ) { * @return string */ function wpmem_get( $tag, $default = '', $type = 'post' ) { - switch ( $type ) { - case 'get': - return ( isset( $_GET[ $tag ] ) ) ? $_GET[ $tag ] : $default; - break; - case 'request': - return ( isset( $_REQUEST[ $tag ] ) ) ? $_REQUEST[ $tag ] : $default; - break; - default: // case 'post': - return ( isset( $_POST[ $tag ] ) ) ? $_POST[ $tag ] : $default; - break; - } + return rktgk_get( $tag, $default, $type ); } /** diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 6bda30ca..9c0af66f 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -461,54 +461,6 @@ function create_form_label( $args ) { return $label; } - /** - * Sanitizes classes passed to the WP-Members form building functions. - * - * This generally uses just sanitize_html_class() but allows for - * whitespace so multiple classes can be passed (such as "regular-text code"). - * - * @since 3.2.0 - * - * @param string $class - * @return string sanitized_class - */ - function sanitize_class( $class ) { - // If no whitespace, just return WP sanitized class. - if ( ! strpos( $class, ' ' ) ) { - return sanitize_html_class( $class ); - } else { - // Break string by whitespace, sanitize individual class names. - $class_array = explode( ' ', $class ); - $len = count( $class_array ); $i = 0; - $sanitized_class = ''; - foreach ( $class_array as $single_class ) { - $sanitized_class .= sanitize_html_class( $single_class ); - $sanitized_class .= ( $i == $len - 1 ) ? '' : ' '; - $i++; - } - return $sanitized_class; - } - } - - /** - * Sanitizes the text in an array. - * - * @since 3.2.9 - * @since 3.3.7 Added optional $type - * - * @param array $data - * @param string $type The data type integer|int (default: false) - * @return array $data - */ - function sanitize_array( $data, $type = false ) { - if ( is_array( $data ) ) { - foreach( $data as $key => $val ) { - $data[ $key ] = ( 'integer' == $type || 'int' == $type ) ? intval( $val ) : sanitize_text_field( $val ); - } - } - return $data; - } - /** * Sanitizes field based on field type. * diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index e4104fec..bd349f1f 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -649,6 +649,8 @@ function load_dependencies() { require_once( $this->path . 'includes/cli/class-wp-members-cli-user.php' ); require_once( $this->path . 'includes/cli/class-wp-members-cli-settings.php' ); } + + require_once( $this->path . 'includes/libraries/rocketgeek-utilities/loader.php' ); } /** diff --git a/includes/deprecated.php b/includes/deprecated.php index ee3e03b2..6de620c4 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -627,4 +627,17 @@ function wpmem_inc_memberlinks( $page = 'member' ) { */ function wpmem_gettext( $str, $echo = false ) { return wpmem_get_text( $str, $echo ); +} + +/** + * Returns http:// or https:// depending on ssl. + * + * @since 2.9.8 + * @deprecated 3.2.3 Use wpmem_force_ssl() instead. + * + * @return string https://|http:// depending on whether ssl is being used. + */ +function wpmem_use_ssl() { + wpmem_write_log( 'wpmem_use_ssl() is deprecated. Use wpmem_force_ssl() instead' ); + return ( is_ssl() ) ? 'https://' : 'http://'; } \ No newline at end of file From f156ea383b44bcf695a592113038080f7ced1f99 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 6 Sep 2021 11:37:56 -0400 Subject: [PATCH 1460/1694] bug fix and api alias updates --- includes/admin/class-wp-members-products-admin.php | 2 +- includes/api/api-utilities.php | 2 +- includes/class-wp-members-forms.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index 44b3d72c..76e64da7 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -675,7 +675,7 @@ public function user_profile_tab_content( $key ) { * logged in when checking profiles. */ $user_id = ( 'profile' == $pagenow && current_user_can( 'edit_users' ) ) ? get_current_user_id() : sanitize_text_field( wpmem_get( 'user_id', false, 'get' ) ); - $user_products = $wpmem->user->get_user_products( $user_id ); + $user_products = wpmem_get_user_products( $user_id ); echo '

    ' . __( 'Membership Access', 'wp-members' ) . '

    '; if ( ! empty( $wpmem->membership->products ) ) { echo ' diff --git a/includes/api/api-utilities.php b/includes/api/api-utilities.php index b97250a0..2df9797e 100644 --- a/includes/api/api-utilities.php +++ b/includes/api/api-utilities.php @@ -223,7 +223,7 @@ function wpmem_format_date( $args ) { * * @return string|bool False on failure, the result of the shortcode on success. */ -function rktgk_do_shortcode( $tag, array $atts = array(), $content = null ) { +function wpmem_do_shortcode( $tag, array $atts = array(), $content = null ) { return rktgk_do_shortcode( $tag, $atts, $content ); } diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 9c0af66f..72a3852a 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -484,7 +484,7 @@ function sanitize_field( $data, $type ) { case 'multiselect': case 'multicheckbox': - $sanitized_data = $this->sanitize_array( $data ); + $sanitized_data = wpmem_sanitize_array( $data ); break; case 'textarea': From 4874bb8840672062eaf9052409661653bdf2a2d2 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 6 Sep 2021 11:38:22 -0400 Subject: [PATCH 1461/1694] add wpmem_is_reg_form_showing() --- includes/api/api-forms.php | 5 +++++ includes/class-wp-members-forms.php | 2 ++ 2 files changed, 7 insertions(+) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 3eba044c..05dce4cb 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -587,4 +587,9 @@ function wpmem_woo_reg_validate( $username, $email, $errors ) { } } return $errors; +} + +function wpmem_is_reg_form_showing() { + global $wpmem; + return ( true === $wpmem->reg_form_showing ) ? true : false; } \ No newline at end of file diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 72a3852a..9bb733a4 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -1605,6 +1605,8 @@ function register_form( $mixed = 'new', $redirect_to = null ) { */ $form = apply_filters( 'wpmem_register_form_before', '', $tag ) . $form; + $wpmem->reg_form_showing = true; + // Return the generated form. return $form; } // End register_form(). From a92f8b10d864db8aa25c93215b61783fb9f90fbe Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 6 Sep 2021 11:38:43 -0400 Subject: [PATCH 1462/1694] add invisible captcha (if enabled) to all pages --- includes/class-wp-members.php | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index bd349f1f..635d556e 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -470,6 +470,7 @@ function load_hooks() { add_action( 'pre_get_posts', array( $this, 'do_hide_posts' ), 20 ); add_action( 'customize_register', array( $this, 'customizer_settings' ) ); add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu + add_action( 'wp_footer', array( $this, 'invisible_captcha' ) ); if ( is_user_logged_in() ) { add_action( 'wpmem_pwd_change', array( $this->user, 'set_password' ), 9, 2 ); @@ -1820,4 +1821,16 @@ function login_error( $args = array() ) { } return $args; } + + /** + * Google recaptcha v3 (invisible) gives more accurate user scores + * if it is loaded on all pages. + * + * @since 3.4.0 + */ + function invisible_captcha() { + if ( 4 == $this->captcha && true !== wpmem_is_reg_form_showing() ) { + echo WP_Members_Captcha::show(); + } + } } // End of WP_Members class. \ No newline at end of file From ed04c86c53e748533c0ad99464ab72f55cceb169 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Wed, 6 Oct 2021 15:25:29 -0400 Subject: [PATCH 1463/1694] cleanup, mostly inline docs w/ some formatting --- .../tabs/class-wp-members-admin-tab-fields.php | 2 +- .../tabs/class-wp-members-admin-tab-options.php | 2 +- includes/api/api-forms.php | 2 +- includes/api/api-users.php | 14 +++++++------- includes/api/api-utilities.php | 10 +++++----- includes/api/api.php | 4 +--- includes/class-wp-members-pwd-reset.php | 2 +- includes/class-wp-members-widget.php | 4 ++-- includes/class-wp-members.php | 3 ++- includes/deprecated.php | 10 +++++----- wp-members.php | 2 +- 11 files changed, 27 insertions(+), 28 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-fields.php b/includes/admin/tabs/class-wp-members-admin-tab-fields.php index 53db11d6..73b8104a 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-fields.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-fields.php @@ -87,7 +87,7 @@ public static function build_settings() { if ( 'delete' == $delete_action ) { - $delete_fields = wpmem_get( 'delete' ); ?> + $delete_fields = wpmem_sanitize_array( wpmem_get( 'delete' ) );?>

    diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index efdabed4..f2338ebd 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -203,7 +203,7 @@ static function build_settings() {

      dropin_dir ); $rows = array( array(__('Enable Products', 'wp-members'),'wpmem_settings_products',__('Enables creation of different membership products','wp-members'),'enable_products'), diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 05dce4cb..580fb977 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -24,7 +24,7 @@ * to the current function documentation. * * @since 2.5.1 - * @since 3.1.7 Now a wrapper for $wpmem->forms->login_form() + * @since 3.1.7 Now an alias for $wpmem->forms->login_form() * @since 3.3.0 Added to API. * @since 3.4.0 Main API function for displaying login form. * diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 0b17dbb3..6e04da61 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -166,7 +166,7 @@ function wpmem_user_has_meta( $meta, $value = false, $user_id = false ) { * Checks if a user is activated. * * @since 3.1.7 - * @since 3.2.3 Now a wrapper for WP_Members_Users::is_user_activated(). + * @since 3.2.3 Now an alias for WP_Members_Users::is_user_activated(). * * @global object $wpmem * @param int $user_id @@ -199,7 +199,7 @@ function wpmem_user_data( $user_id = false, $all = false ) { /** * Updates a user's role. * - * This is a wrapper for $wpmem->update_user_role(). It can add a role to a + * This is an alias for $wpmem->update_user_role(). It can add a role to a * user, change or remove the user's role. If no action is specified it will * change the role. * @@ -319,7 +319,7 @@ function wpmem_set_as_logged_in( $user_id ) { * @since 2.5.2 Now uses wp_signon(). * @since 2.7.7 Sets cookie using wp_set_auth_cookie(). * @since 3.0.0 Removed wp_set_auth_cookie(), this already happens in wp_signon(). - * @since 3.1.7 Now a wrapper for login() in WP_Members_Users Class. + * @since 3.1.7 Now an alias for login() in WP_Members_Users Class. * @since 3.2.4 Moved to user API (could be deprecated). * * @global object $wpmem @@ -337,7 +337,7 @@ function wpmem_login() { * * @since 2.0.0 * @since 3.1.6 Added wp_destroy_current_session(), removed nocache_headers(). - * @since 3.1.7 Now a wrapper for logout() in WP_Members_Users Class. + * @since 3.1.7 Now an alias for logout() in WP_Members_Users Class. * @since 3.2.4 Moved to user API (could be deprecated). * * @global object $wpmem @@ -354,7 +354,7 @@ function wpmem_logout( $redirect_to = false ) { * Handles user password change (not reset). * * @since 2.1.0 - * @since 3.1.7 Now a wrapper for password_update() in WP_Members_Users Class. + * @since 3.1.7 Now an alias for password_update() in WP_Members_Users Class. * @since 3.2.4 Moved to user API (could be deprecated). * * @global int $user_ID The WordPress user ID. @@ -372,7 +372,7 @@ function wpmem_change_password() { * Resets a forgotten password. * * @since 2.1.0 - * @since 3.1.7 Now a wrapper for password_update() in WP_Members_Users Class. + * @since 3.1.7 Now an alias for password_update() in WP_Members_Users Class. * @since 3.2.4 Moved to user API (could be deprecated). * * @global object $wpmem The WP-Members object class. @@ -390,7 +390,7 @@ function wpmem_reset_password() { * * @since 3.0.8 * @since 3.1.6 Dependencies now loaded by object. - * @since 3.1.8 Now a wrapper for $wpmem->retrieve_username() in WP_Members_Users Class. + * @since 3.1.8 Now an alias for $wpmem->retrieve_username() in WP_Members_Users Class. * @since 3.2.4 Moved to user API (could be deprecated). * * @global object $wpmem The WP-Members object class. diff --git a/includes/api/api-utilities.php b/includes/api/api-utilities.php index 2df9797e..b0f7fd3d 100644 --- a/includes/api/api-utilities.php +++ b/includes/api/api-utilities.php @@ -22,10 +22,10 @@ * * This is the primary function that picks up where wpmem() leaves off. * Determines whether content is shown or hidden for both post and pages. - * Since 3.0, this function is a wrapper for $wpmem->do_securify(). + * Since 3.0, this function is an alias for $wpmem->do_securify(). * * @since 2.0.0 - * @since 3.0.0 Now a wrapper for $wpmem->do_securify(). + * @since 3.0.0 Now an alias for $wpmem->do_securify(). * @since 3.2.4 Moved to utility API (could be deprecated). * * @global object $wpmem The WP-Members object class. @@ -43,7 +43,7 @@ function wpmem_securify( $content = null ) { * Sets an array of user meta fields to be excluded from update/insert. * * @since 2.9.3 - * @since Unknown Now a wrapper for get_excluded_fields(). + * @since Unknown Now an alias for get_excluded_fields(). * @since 3.3.9 excluded_fields() moved to forms object class. * * @param string $tag A tag so we know where the function is being used. @@ -112,7 +112,7 @@ function wpmem_get_sub_str( $needle, $haystack, $position = 'after', $keep_needl * Creates an excerpt on the fly if there is no 'more' tag. * * @since 2.6 - * @since 3.2.3 Now a wrapper for WP_Members::do_excerpt(). + * @since 3.2.3 Now an alias for WP_Members::do_excerpt(). * * @global object $wpmem The WP_Members object. * @@ -133,7 +133,7 @@ function wpmem_do_excerpt( $content ) { * Currently only used for the login form to remove the
      tag that WP puts in after the "Remember Me". * * @since 2.6.4 - * @since 3.2.3 Now a wrapper for WP_Members::texturize(). + * @since 3.2.3 Now an alias for WP_Members::texturize(). * * @todo Possibly deprecate or severely alter this process as its need may be obsolete. * diff --git a/includes/api/api.php b/includes/api/api.php index 3e718c62..9edd0b31 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -478,9 +478,7 @@ function wpmem_is_reg_type( $type ) { /** * Displays the post restricted message. * - * @todo Evaluate - this doesn't seem to be used yet. - * - * @since 3.3.5 + * @since 3.4.0 * * @return string */ diff --git a/includes/class-wp-members-pwd-reset.php b/includes/class-wp-members-pwd-reset.php index 4808dd2c..987c9a4c 100644 --- a/includes/class-wp-members-pwd-reset.php +++ b/includes/class-wp-members-pwd-reset.php @@ -290,7 +290,7 @@ function reset_password_form( $args ) { /** * Sets and gets the password reset key. * - * This function is a wrapper for the WP function get_password_reset_key(). + * This function is an alias for the WP function get_password_reset_key(). * * @since 3.3.8 * diff --git a/includes/class-wp-members-widget.php b/includes/class-wp-members-widget.php index bc79b469..89146647 100644 --- a/includes/class-wp-members-widget.php +++ b/includes/class-wp-members-widget.php @@ -34,14 +34,14 @@ function __construct() { */ function form( $instance ) { - /* Default widget settings. */ + // Default widget settings. $defaults = array( 'title' => __( 'Login Status', 'wp-members' ), 'redirect_to' => '', ); $instance = wp_parse_args( ( array ) $instance, $defaults ); - /* Title input */ ?> + // Title input. ?>

      diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 635d556e..53552adc 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -1430,6 +1430,7 @@ public function loginout_script() { */ public function do_loginout_script() { global $wpmem; + /** This filter is defined in /includes/api/api.php */ $logout = apply_filters( 'wpmem_logout_link', add_query_arg( 'a', 'logout' ) ); ?> Date: Fri, 3 Dec 2021 09:41:38 -0500 Subject: [PATCH 1512/1694] forward/backward compatibility for wpmem_mail_content_type() --- includes/api/api-email.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/includes/api/api-email.php b/includes/api/api-email.php index a186c243..611ea173 100644 --- a/includes/api/api-email.php +++ b/includes/api/api-email.php @@ -48,11 +48,17 @@ function wpmem_mail_from_name() { * * @global object $wpmem * @return string $wpmem_mail_content_type + * + * @note Currently checks for existing function. Advanced Options set up for + * backward compatibility could potentially load first if wp-members directory + * is named something other than "wp-members". */ +if ( ! function_exists( 'wpmem_mail_content_type' ) ): function wpmem_mail_content_type() { global $wpmem; return $wpmem->email->content_type(); } +endif; /** * Builds emails for the user. From 83513aa552317c7ebc1f7905bd424163b6ff3fd8 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 3 Dec 2021 09:42:24 -0500 Subject: [PATCH 1513/1694] clean up and update readme --- includes/class-wp-members.php | 6 ++++-- readme.txt | 12 ++++++++---- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 8cfbb102..4b7c8d03 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -960,9 +960,10 @@ function do_securify( $content = null ) { // Protects comments if expiration module is used and user is expired. } elseif ( is_user_logged_in() && true == $this->is_blocked() ) { - + + // Allows for a view of the forms in the Customizer. if ( is_customize_preview() ) { - + if ( get_theme_mod( 'wpmem_show_logged_out_state', false ) ) { $content = ''; if ( get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) { @@ -975,6 +976,7 @@ function do_securify( $content = null ) { } } else { + // @todo Test with expired membership. if ( 1 == $this->use_exp && function_exists( 'wpmem_do_expmessage' ) ) { /** * Filters the user expired message used by the PayPal extension. diff --git a/readme.txt b/readme.txt index cc097b0f..73675460 100644 --- a/readme.txt +++ b/readme.txt @@ -2,8 +2,8 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 -Tested up to: 5.7 -Stable tag: 3.4.0 +Tested up to: 5.8 +Stable tag: 3.3.9.3 License: GPLv2 @@ -110,7 +110,7 @@ The FAQs are maintained at https://rocketgeek.com/plugins/wp-members/docs/faqs/ == Upgrade Notice == -WP-Members 3.3.0 is a major update. WP-Members 3.3.8 is an improvement release. See changelog for important details. Minimum WP version is 4.0. +WP-Members 3.4.0 is a major update. Backup prior to upgrading is recommended. See changelog for important details. Minimum WP version is 4.0. == Screenshots == @@ -136,7 +136,7 @@ WP-Members 3.3.0 is a major update. WP-Members 3.3.8 is an improvement release. = 3.4.0 = -* Rebuilds the lgoin widget functions so there are filter hooks that more closely mimic the main body login filters. Every attempt was made to provide an HTML result that is the same as previous versions, as well as providing support for legacy dialog tags. +* Rebuilds the login widget functions so there are filter hooks that more closely mimic the main body login filters. Every attempt was made to provide an HTML result that is the same as previous versions, as well as providing support for legacy dialog tags. * Rebuilt and revised user export functionality. Now includes an api function that can be used to customize user exports for a variety of uses. New Feature Settings: @@ -162,6 +162,8 @@ New Feature Settings: - deprecated 'export_fields', use 'fields' instead. * Clone menus is deprecated. The setting remains in place for users who have it enabled. But if it is not enabled, the setting is no longer available. + +* Expands Customizer functionality so logged out forms show on blocked content (not just shortcodes). New API functions: * wpmem_is_reg_form_showing() @@ -175,10 +177,12 @@ Deprecated functions: * wpmem_page_forgot_username() * wpmem_inc_memberlinks() * wpmem_gettext() - use wpmem_get_text() instead. +* $wpmem->texturize() Bug fixes: * Fixes a bug in the signon process that causes the "rememberme" option to be ignored. * Fixes a bug in wpmem_is_blocked() that returns false when checking a specific post ID. +* Fixes a bug in the autoexcerpt function that caused a double "read more" link when excerpt length was set to zero. = 3.3.9 = From 9c08a604186dd3318c8e839e06ca7c555c1651c0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 3 Dec 2021 17:39:42 -0500 Subject: [PATCH 1514/1694] fix jquery tabs on user profile --- includes/admin/class-wp-members-admin-api.php | 9 ++++++--- includes/class-wp-members-user-profile.php | 15 ++++++++------- 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/includes/admin/class-wp-members-admin-api.php b/includes/admin/class-wp-members-admin-api.php index 638095e3..51b5b04e 100644 --- a/includes/admin/class-wp-members-admin-api.php +++ b/includes/admin/class-wp-members-admin-api.php @@ -549,21 +549,24 @@ function dashboard_enqueue_scripts( $hook ) { || ( 'user-edit' == $current_screen->id || 'profile' == $current_screen->id ) || ( 'settings_page_wpmem-settings' == $hook ) ) { wp_enqueue_script( 'jquery' ); - wp_enqueue_script( 'jquery-ui-core' );// enqueue jQuery UI Core + wp_enqueue_script( 'jquery-ui-core' ); // enqueue jQuery UI Core wp_enqueue_script( 'jquery-ui-datepicker' ); // enqueue jQuery UI Datepicker if ( ! wp_style_is( 'jquery-ui-style', 'enqueued' ) ) { wp_register_style( 'jquery-ui-style', $wpmem->url . 'assets/css/jquery-ui' . wpmem_get_suffix() . '.css' ); } wp_enqueue_style( 'jquery-ui-style' ); } - //if ( ( 'post.php' == $hook || 'post-new.php' == $hook ) && 1 == $wpmem->enable_products ) { + if ( ( 'post.php' == $hook || 'post-new.php' == $hook ) && 1 == $wpmem->enable_products ) { if ( ! wp_script_is( 'select2', 'enqueued' ) ) { wp_register_style( 'select2-style', $wpmem->url . 'assets/css/select2' . wpmem_get_suffix() . '.css', false, '4.0.5', 'all' ); wp_register_script( 'select2', $wpmem->url . 'assets/js/select2' . wpmem_get_suffix() . '.js', array( 'jquery' ), '4.0.5', true ); wp_enqueue_style( 'select2-style' ); wp_enqueue_script( 'select2' ); } - //} + } + if ( 'user-edit' == $current_screen->id || 'profile' == $current_screen->id ) { + wp_enqueue_script( 'jquery-ui-tabs' ); // enqueue jQuery UI Tabs + } } /** diff --git a/includes/class-wp-members-user-profile.php b/includes/class-wp-members-user-profile.php index 1502d175..6ae8e95b 100644 --- a/includes/class-wp-members-user-profile.php +++ b/includes/class-wp-members-user-profile.php @@ -585,13 +585,14 @@ static function _profile_tabs( $user_id ) { */ $tabs = apply_filters( 'wpmem_user_profile_tabs', array() ); - if ( ! empty( $tabs ) ) { ?> - - + +'; echo '

        '; foreach ( $tabs as $key => $value ) { From 3fc53c55c6a8d5d52a96cd5b9dc278871b93bb7c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 3 Dec 2021 17:42:21 -0500 Subject: [PATCH 1515/1694] user screen count transient 5 minutes (instead of 30 seconds) --- includes/admin/class-wp-members-admin-users.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/admin/class-wp-members-admin-users.php b/includes/admin/class-wp-members-admin-users.php index 09672682..c7ebed66 100644 --- a/includes/admin/class-wp-members-admin-users.php +++ b/includes/admin/class-wp-members-admin-users.php @@ -286,8 +286,8 @@ static function views( $views ) { // check to see if data was successfully retrieved from the cache if ( false === $user_counts ) { - // @todo For now, 30 seconds. We'll see how things go. - $transient_expires = 30; // Value in seconds, 1 day: ( 60 * 60 * 24 ); + // @todo For now, 5 minutes. We'll see how things go. + $transient_expires = 300; // Value in seconds, 1 day: ( 60 * 60 * 24 ); global $wpdb; From 64c159fdf12ddba98cc0e515589cf88ce3448572 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 3 Dec 2021 17:43:01 -0500 Subject: [PATCH 1516/1694] updates to user profile membership section --- includes/admin/class-wp-members-products-admin.php | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index 1a761c8a..cb280aa4 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -698,12 +698,16 @@ public function user_profile_tab_content( $key ) { $user_products = wpmem_get_user_products( $user_id ); echo '

        ' . __( 'Membership Access', 'wp-members' ) . '

        '; if ( ! empty( $wpmem->membership->products ) ) { + $expires_heading = " "; + foreach( $wpmem->membership->products as $key => $value ) { + $expires_heading = ( ! empty( $value['expires'] ) ) ? __( 'Expires', 'wp-members' ) : $expires_heading; + } echo '
    - + - + '; ?> '; // If user has date, display that; otherwise placeholder From 454bf1b39c8aa4302d67e4edfb1338a80537b9a5 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 3 Dec 2021 17:43:23 -0500 Subject: [PATCH 1517/1694] update license to gpl v3 --- license.txt | 899 +++++++++++++++++++++++++++++++++---------------- readme.txt | 4 +- wp-members.php | 10 +- 3 files changed, 625 insertions(+), 288 deletions(-) diff --git a/license.txt b/license.txt index 89e08fb0..871ce8e6 100644 --- a/license.txt +++ b/license.txt @@ -1,281 +1,622 @@ GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 + Version 3, 29 June 2007 - Copyright (C) 1989, 1991 Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Copyright (C) 2007 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. - To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - - We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - - Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - - Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. The precise terms and conditions for copying, distribution and modification follow. - GNU GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - - 1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - - 2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) You must cause the modified files to carry prominent notices - stating that you changed the files and the date of any change. - - b) You must cause any work that you distribute or publish, that in - whole or in part contains or is derived from the Program or any - part thereof, to be licensed as a whole at no charge to all third - parties under the terms of this License. - - c) If the modified program normally reads commands interactively - when run, you must cause it, when started running for such - interactive use in the most ordinary way, to print or display an - announcement including an appropriate copyright notice and a - notice that there is no warranty (or else, saying that you provide - a warranty) and that users may redistribute the program under - these conditions, and telling the user how to view a copy of this - License. (Exception: if the Program itself is interactive but - does not normally print such an announcement, your work based on - the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - - a) Accompany it with the complete corresponding machine-readable - source code, which must be distributed under the terms of Sections - 1 and 2 above on a medium customarily used for software interchange; or, - - b) Accompany it with a written offer, valid for at least three - years, to give any third party, for a charge no more than your - cost of physically performing source distribution, a complete - machine-readable copy of the corresponding source code, to be - distributed under the terms of Sections 1 and 2 above on a medium - customarily used for software interchange; or, - - c) Accompany it with the information you received as to the offer - to distribute corresponding source code. (This alternative is - allowed only for noncommercial distribution and only if you - received the program in object code or executable form with such - an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - - 4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - - 5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - - 6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of this License. - 7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - - 9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - - 10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - - 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - - 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. END OF TERMS AND CONDITIONS @@ -287,15 +628,15 @@ free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least +state the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) - This program is free software; you can redistribute it and/or modify + This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or + the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, @@ -303,37 +644,31 @@ the "copyright" line and a pointer to where the full notice is found. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. - You should have received a copy of the GNU General Public License along - with this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + You should have received a copy of the GNU General Public License + along with this program. If not, see . Also add information on how to contact you by electronic and paper mail. -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: - Gnomovision version 69, Copyright (C) year name of author - Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the program - `Gnomovision' (which makes passes at compilers) written by James Hacker. - - , 1 April 1989 - Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. \ No newline at end of file diff --git a/readme.txt b/readme.txt index 73675460..eccddf64 100644 --- a/readme.txt +++ b/readme.txt @@ -5,7 +5,7 @@ Requires at least: 4.0 Tested up to: 5.8 Stable tag: 3.3.9.3 -License: GPLv2 +License: GPLv3 == Description == @@ -150,6 +150,8 @@ New Feature Settings: * Improved redirect_to handling in login and register forms. Can now specify a page by slug alone in the shortcode param for portability. * Improved Google reCAPTCHA v3 ("invisible captcha") to optionally display on all pages (recommended by Google to improve user "score"). * Improved forms display in Customizer, now can view forms on blocked content (not just shortcode pages). +* Improved functionality of hidden posts. Now saved in WP settings (options) instead of as a transient. +* Improved user count transient. Now expires in 5 minutes instead of 30 seconds (will result in fewer loads of the query). * Membership products now support hierarchy. This can be used for "levels" or for multiple expiration periods yet still only have to assign one membership to content for all child memberships. diff --git a/wp-members.php b/wp-members.php index 6dc205a5..dc3aa723 100644 --- a/wp-members.php +++ b/wp-members.php @@ -5,10 +5,10 @@ Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. Version: 3.4.0 Author: Chad Butler -Author URI: http://butlerblog.com/ +Author URI: https://butlerblog.com/ Text Domain: wp-members Domain Path: /i18n/languages/ -License: GPLv2 +License: GPLv3 */ /* @@ -17,7 +17,7 @@ The name WP-Members(tm) is a trademark of butlerblog.com This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License, version 2, as + it under the terms of the GNU General Public License, version 3, as published by the Free Software Foundation. This program is distributed in the hope that it will be useful, @@ -36,13 +36,13 @@ /* A NOTE ABOUT LICENSE: - While this plugin is freely available and open-source under the GPL2 + While this plugin is freely available and open-source under the GPL3 license, that does not mean it is "public domain." You are free to modify and redistribute as long as you comply with the license. Any derivative work MUST be GPL licensed and available as open source. You also MUST give proper attribution to the original author, copyright holder, and trademark owner. This means you cannot change two lines of code and claim copyright - of the entire work as your own. The GPL2 license requires that if you + of the entire work as your own. The GPL3 license requires that if you modify this code, you must clearly indicate what section(s) you have modified and you may only claim copyright of your modifications and not the body of work. If you are unsure or have questions about how a From 13fe97353bb3a5600133fe5b5eecc80c6df36456 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 4 Dec 2021 17:16:36 -0500 Subject: [PATCH 1518/1694] update utilities library --- .../libraries/rocketgeek-utilities/LICENSE | 201 ++++++++++++++++++ .../libraries/rocketgeek-utilities/README.md | 2 + .../libraries/rocketgeek-utilities/dates.php | 38 ---- .../{ => includes}/arrays.php | 30 +++ .../rocketgeek-utilities/includes/dates.php | 108 ++++++++++ .../rocketgeek-utilities/includes/debug.php | 105 +++++++++ .../{ => includes}/forms.php | 30 +++ .../{ => includes}/strings.php | 30 +++ .../{ => includes}/utilities.php | 104 +++++++-- .../libraries/rocketgeek-utilities/loader.php | 45 +++- 10 files changed, 632 insertions(+), 61 deletions(-) create mode 100644 includes/libraries/rocketgeek-utilities/LICENSE create mode 100644 includes/libraries/rocketgeek-utilities/README.md delete mode 100644 includes/libraries/rocketgeek-utilities/dates.php rename includes/libraries/rocketgeek-utilities/{ => includes}/arrays.php (58%) create mode 100644 includes/libraries/rocketgeek-utilities/includes/dates.php create mode 100644 includes/libraries/rocketgeek-utilities/includes/debug.php rename includes/libraries/rocketgeek-utilities/{ => includes}/forms.php (75%) rename includes/libraries/rocketgeek-utilities/{ => includes}/strings.php (58%) rename includes/libraries/rocketgeek-utilities/{ => includes}/utilities.php (58%) diff --git a/includes/libraries/rocketgeek-utilities/LICENSE b/includes/libraries/rocketgeek-utilities/LICENSE new file mode 100644 index 00000000..261eeb9e --- /dev/null +++ b/includes/libraries/rocketgeek-utilities/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/includes/libraries/rocketgeek-utilities/README.md b/includes/libraries/rocketgeek-utilities/README.md new file mode 100644 index 00000000..d50aff08 --- /dev/null +++ b/includes/libraries/rocketgeek-utilities/README.md @@ -0,0 +1,2 @@ +# rocketgeek-utilities +A library of utilities for building plugins diff --git a/includes/libraries/rocketgeek-utilities/dates.php b/includes/libraries/rocketgeek-utilities/dates.php deleted file mode 100644 index 9bbc2429..00000000 --- a/includes/libraries/rocketgeek-utilities/dates.php +++ /dev/null @@ -1,38 +0,0 @@ - $args ); - } - - $defaults = array( - 'date_format' => get_option( 'date_format' ), - 'time_format' => get_option( 'time_format' ), - 'localize' => true, - 'timestamp' => false, - ); - - $args = wp_parse_args( $args, $defaults ); - - /** - * Filter the date display and format settings. - * - * @since 1.0.0 - * - * @param arrag $args - */ - $args = apply_filters( 'rktgk_format_date_args', $args ); - $date = ( true === $args['timestamp'] ) ? $args['date'] : strtotime( $args['date'] ); - $date = ( true === $args['localize'] ) ? date_i18n( $args['date_format'], $date ) : date( $args['date_format'], $date ); - return $date; -} -endif; \ No newline at end of file diff --git a/includes/libraries/rocketgeek-utilities/arrays.php b/includes/libraries/rocketgeek-utilities/includes/arrays.php similarity index 58% rename from includes/libraries/rocketgeek-utilities/arrays.php rename to includes/libraries/rocketgeek-utilities/includes/arrays.php index 3c659f51..2c1b33a1 100644 --- a/includes/libraries/rocketgeek-utilities/arrays.php +++ b/includes/libraries/rocketgeek-utilities/includes/arrays.php @@ -1,4 +1,34 @@ + * @author RocketGeek + * @copyright Copyright (c) 2021 Chad Butler + * @license Apache-2.0 + * + * Copyright [2021] Chad Butler, RocketGeek + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ if ( ! function_exists( 'rktgk_compare_array_values' ) ): /** * Compares two arrays, disregarding order. diff --git a/includes/libraries/rocketgeek-utilities/includes/dates.php b/includes/libraries/rocketgeek-utilities/includes/dates.php new file mode 100644 index 00000000..0a3de7c4 --- /dev/null +++ b/includes/libraries/rocketgeek-utilities/includes/dates.php @@ -0,0 +1,108 @@ + + * @author RocketGeek + * @copyright Copyright (c) 2021 Chad Butler + * @license Apache-2.0 + * + * Copyright [2021] Chad Butler, RocketGeek + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +if ( ! function_exists( 'rktgk_format_date' ) ): +/** + * Display a localized date based on the WP date format setting. + * + * @since 1.0.0 + * + * @param mixed $args + * @return date $date + */ +function rktgk_format_date( $args ) { + if ( ! is_array( $args ) ) { + $args = array( 'date' => $args ); + } + + $defaults = array( + 'date_format' => get_option( 'date_format' ), + 'time_format' => get_option( 'time_format' ), + 'localize' => true, + 'timestamp' => true, + 'date_only' => true, + ); + + $args = wp_parse_args( $args, $defaults ); + + /** + * Filter the date display and format settings. + * + * @since 1.0.0 + * + * @param arrag $args + */ + $args = apply_filters( 'rktgk_format_date_args', $args ); + + $date_format = ( true === $args['date_only'] ) ? $args['date_format'] : $args['date_format'] . ' ' . $args['time_format']; + + $date = ( true === $args['timestamp'] ) ? $args['date'] : strtotime( $args['date'] ); + $date = ( true === $args['localize'] ) ? date_i18n( $date_format, $date ) : date( $date_format, $date ); + + return $date; +} +endif; + +if ( ! function_exists( 'rktgk_date_format_map' ) ): +/** + * Returns a conversion map array for various date formats. + * + * @since 1.0.0 + */ +function rktgk_date_format_map() { + return array( + 'YYYY-MM-DD' => 'Y-m-d', + 'EUROPEAN' => 'j F Y', + 'AMERICAN' => 'F j, Y', + 'MM/DD/YYYY' => 'm/d/Y', + 'DD/MM/YYYY' => 'd/m/Y', + ); +} +endif; + +if ( ! function_exists( 'rktgk_date_format' ) ): +/** + * Converts certain date formats to PHP. + * + * If no format is matched, it returns the original format. + * + * @since 1.0.0 + * + * @param string $format + * @return string + */ +function rktgk_date_format( $format ) { + $format = strtoupper( $format ); + $convert = rktgk_date_format_map(); + return ( ! isset( $convert[ $format ] ) ) ? $format : $convert[ $format ]; +} +endif; \ No newline at end of file diff --git a/includes/libraries/rocketgeek-utilities/includes/debug.php b/includes/libraries/rocketgeek-utilities/includes/debug.php new file mode 100644 index 00000000..9c0172ac --- /dev/null +++ b/includes/libraries/rocketgeek-utilities/includes/debug.php @@ -0,0 +1,105 @@ + + * @author RocketGeek + * @copyright Copyright (c) 2021 Chad Butler + * @license Apache-2.0 + * + * Copyright [2021] Chad Butler, RocketGeek + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/** + + Changelog + + 1.0.0 Initial version. + 1.0.1 Added test for what_is() if $var is empty. + + **/ + +if ( ! function_exists('rktgk_break_point')): +function rktgk_break_point( $print = 'you are here' ) { + if ( false == $print ) { + exit(); + } + echo $print; + exit(); +} +endif; + +if ( ! function_exists('rktgk_write_log')): +function rktgk_write_log( $log ) { + if ( is_array( $log ) || is_object( $log ) ) { + error_log( print_r( $log, true ) ); + } else { + error_log( $log ); + } +} +endif; + +if ( ! function_exists('rktgk_what_is')): +function rktgk_what_is( $var, $exit = false, $output = true, $title = true ) { + + $is_obj = false; + + switch( $var ) { + + case empty( $var ) : + echo '$var is empty'; + break; + + case is_string( $var ) : + echo ( true === $title ) ? '$var is a string' : ''; + echo ( true === $title && true === $output ) ? ": " : ""; + echo ( true === $output ) ? $var : ''; + break; + + case is_object( $var ) : + echo ( true === $title ) ? '$var is an object' : ''; + $is_obj = true; + + case is_array( $var ) : + echo ( true === $title && false === $is_obj ) ? '$var is an array' : ''; + + echo ( true === $title && true === $output ) ? ": " : ""; + + if ( true === $output ) { + echo '
    ';
    +				print_r( $var );
    +				echo '
    '; + } + break; + } + if ( 'exit' == $exit || true == $exit ) { + exit(); + } +} +endif; + +if ( ! function_exists( 'rktgk_write_line' ) ): +function rktgk_write_line( $line ) { + echo $line . "
    "; +} +endif; \ No newline at end of file diff --git a/includes/libraries/rocketgeek-utilities/forms.php b/includes/libraries/rocketgeek-utilities/includes/forms.php similarity index 75% rename from includes/libraries/rocketgeek-utilities/forms.php rename to includes/libraries/rocketgeek-utilities/includes/forms.php index 2a790071..f16e3233 100644 --- a/includes/libraries/rocketgeek-utilities/forms.php +++ b/includes/libraries/rocketgeek-utilities/includes/forms.php @@ -1,4 +1,34 @@ + * @author RocketGeek + * @copyright Copyright (c) 2021 Chad Butler + * @license Apache-2.0 + * + * Copyright [2021] Chad Butler, RocketGeek + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ if ( ! function_exists( 'rktgk_get' ) ): /** diff --git a/includes/libraries/rocketgeek-utilities/strings.php b/includes/libraries/rocketgeek-utilities/includes/strings.php similarity index 58% rename from includes/libraries/rocketgeek-utilities/strings.php rename to includes/libraries/rocketgeek-utilities/includes/strings.php index c8695df0..bb07f0ad 100644 --- a/includes/libraries/rocketgeek-utilities/strings.php +++ b/includes/libraries/rocketgeek-utilities/includes/strings.php @@ -1,4 +1,34 @@ + * @author RocketGeek + * @copyright Copyright (c) 2021 Chad Butler + * @license Apache-2.0 + * + * Copyright [2021] Chad Butler, RocketGeek + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ if ( ! function_exists( 'rktgk_get_sub_str' ) ): /** diff --git a/includes/libraries/rocketgeek-utilities/utilities.php b/includes/libraries/rocketgeek-utilities/includes/utilities.php similarity index 58% rename from includes/libraries/rocketgeek-utilities/utilities.php rename to includes/libraries/rocketgeek-utilities/includes/utilities.php index e29afe79..945131b6 100644 --- a/includes/libraries/rocketgeek-utilities/utilities.php +++ b/includes/libraries/rocketgeek-utilities/includes/utilities.php @@ -1,4 +1,34 @@ + * @author RocketGeek + * @copyright Copyright (c) 2021 Chad Butler + * @license Apache-2.0 + * + * Copyright [2021] Chad Butler, RocketGeek + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ if ( ! function_exists( 'rktgk_force_ssl' ) ): /** @@ -54,6 +84,61 @@ function rktgk_maybe_unserialize( $original ) { } endif; +if ( ! function_exists( 'rktgk_maybe_wpautop' ) ): +/** + * Run wpautop on content. Defaults to true. + * + * Useful for shortcodes that don't autop on their own. + * Toggle boolean can be passed as a string without pre-filtering + * since it runs rktgk_str_to_bool(). + * + * @since 1.0.0 + * + * @param string $content + * @param mixed $do_autop + * @return string $content either autop'ed or not. + */ +function rktgk_maybe_wpautop( $content, $do_autop = true ) { + return ( true === rktgk_str_to_bool( $do_autop ) ) ? wpautop( $content ) : $content; +} +endif; + +if ( ! function_exists( 'rktgk_string_to_boolean' ) ): +function rktgk_string_to_boolean( $str ) { + return rktgk_str_to_bool( $str ); +} +endif; + +if ( ! function_exists( 'rktgk_str_to_bool' ) ): +/** + * Converts a true/false string to a boolean. + * Useful for shortcodes that receive args as strings + * but need a true/false or 1/0 boolean. + */ +function rktgk_str_to_bool( $str ) { + switch ( $str ) { + case ( is_bool( $str ) ): + // If the value is already cast as a boolean. + return $str; + break; + case ( "true" == $str ): + case ( 1 == $str ): + // If the value is "true" or 1 as a string or integer. + return true; + break; + case ( "false" == $str ): + case ( 0 == $str ): + // If the value is "false" or 0 as a string or integer. + return false; + break; + default: + // If it doesn't fit anything, return false. + return false; + break; + } +} +endif; + if ( ! function_exists( 'rktgk_do_shortcode' ) ): /** * Call a shortcode function by tag name. @@ -103,23 +188,6 @@ function rktgk_is_woo_active() { } endif; -if ( ! function_exists( 'rktgk_write_log' ) ): -/** - * Log debugging errors. - * - * @since 3.1.2 - * - * @param mixed (string|array|object) $log Information to write in the WP debug file. - */ -function rktgk_write_log( $log ) { - if ( is_array( $log ) || is_object( $log ) ) { - error_log( print_r( $log, true ) ); - } else { - error_log( $log ); - } -} -endif; - if ( ! function_exists( 'rktgk_get_user_ip' ) ): /** * Get user IP address. @@ -144,7 +212,7 @@ function rktgk_get_user_ip() { /** * Filter the IP result. * - * @since 3.3.0 + * @since 1.0.0 * * @param string $ip */ diff --git a/includes/libraries/rocketgeek-utilities/loader.php b/includes/libraries/rocketgeek-utilities/loader.php index 4bd036e0..72f4be25 100644 --- a/includes/libraries/rocketgeek-utilities/loader.php +++ b/includes/libraries/rocketgeek-utilities/loader.php @@ -1,7 +1,42 @@ + * @author RocketGeek + * @copyright Copyright (c) 2021 Chad Butler + * @license Apache-2.0 + * + * Copyright [2021] Chad Butler, RocketGeek + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ -require_once( 'utilities.php' ); -require_once( 'arrays.php' ); -require_once( 'dates.php' ); -require_once( 'forms.php' ); -require_once( 'strings.php' ); \ No newline at end of file +require_once( 'includes/utilities.php' ); +require_once( 'includes/arrays.php' ); +require_once( 'includes/dates.php' ); +require_once( 'includes/forms.php' ); +require_once( 'includes/strings.php' ); + +// @todo Change to load only if debug is set +require_once( 'includes/debug.php' ); \ No newline at end of file From 2eb8d73cbba0ba53fef5ca1e45d14845d5f3c4d0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 4 Dec 2021 17:17:31 -0500 Subject: [PATCH 1519/1694] reposition loading of utilities library --- includes/class-wp-members.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 4b7c8d03..8f9b4328 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -621,6 +621,7 @@ function load_dependencies() { include( $wpmem_pluggable ); } + require_once( $this->path . 'includes/libraries/rocketgeek-utilities/loader.php' ); require_once( $this->path . 'includes/class-wp-members-api.php' ); require_once( $this->path . 'includes/class-wp-members-clone-menus.php' ); require_once( $this->path . 'includes/class-wp-members-captcha.php' ); @@ -650,8 +651,6 @@ function load_dependencies() { require_once( $this->path . 'includes/cli/class-wp-members-cli-user.php' ); require_once( $this->path . 'includes/cli/class-wp-members-cli-settings.php' ); } - - require_once( $this->path . 'includes/libraries/rocketgeek-utilities/loader.php' ); } /** From f79d460a0a1d677b7d8f574c6678ebf185fdb2cf Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sat, 4 Dec 2021 17:17:47 -0500 Subject: [PATCH 1520/1694] debug dialogs --- includes/class-wp-members-dialogs.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-dialogs.php b/includes/class-wp-members-dialogs.php index dc998430..d17bb616 100644 --- a/includes/class-wp-members-dialogs.php +++ b/includes/class-wp-members-dialogs.php @@ -321,8 +321,11 @@ function message( $tag, $custom ) { } } elseif ( 'loginfailed' == $tag ) { $msg = $this->login_failed(); + } else { + // It must be a custom message ("custom" in that it is not included in the dialogs array). + $msg = $tag; } - + $defaults['msg'] = $msg; /** From 279a1a09e8940c0ce52440e88f432a6212c5ccf3 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 5 Dec 2021 14:18:44 -0500 Subject: [PATCH 1521/1694] style adjments for wpmem_msg --- assets/css/forms/generic-no-float.css | 3 ++- assets/css/forms/generic-no-float.min.css | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/assets/css/forms/generic-no-float.css b/assets/css/forms/generic-no-float.css index 1b733d42..85491a82 100644 --- a/assets/css/forms/generic-no-float.css +++ b/assets/css/forms/generic-no-float.css @@ -35,7 +35,8 @@ see https://rocketgeek.com/tips-and-tricks/load-a-custom-stylesheet/ background: #F9F9F9; border:1px solid lightGrey; border-radius: 3px; - padding: 20px 0 0 0; + padding: 20px 0; + margin: 15px 0; } /* Messages and forms should (ideally) be the same width */ diff --git a/assets/css/forms/generic-no-float.min.css b/assets/css/forms/generic-no-float.min.css index 098745a6..d8f610d9 100644 --- a/assets/css/forms/generic-no-float.min.css +++ b/assets/css/forms/generic-no-float.min.css @@ -1 +1 @@ -#wpmem_msg,.wpmem_msg{text-align:center;background:#f9f9f9;border:1px solid #d3d3d3;border-radius:3px;padding:20px 0 0 0}#wpmem_login,#wpmem_msg,#wpmem_reg,.wpmem_msg{width:75%}#wp-members{width:100%}#wp-members fieldset{border:none;padding:0}#wp-members input{font-family:inherit}#wp-members input[type=password],#wp-members input[type=text]{margin:0 0 4px 0}#wp-members input[type=submit]{padding:5px 6px 4px;margin:0 4px 0 0}#wp-members .button_div{margin-top:4px}#wp-members .err{width:100%;padding:5px;font-family:inherit;border:1px solid #ccc;border-radius:3px}#wpmem_login,#wpmem_reg{color:#2b2b2b;font-family:Arial,sans-serif;font-size:16px;font-weight:400;line-height:1.5}#wpmem_login label,#wpmem_reg label{display:initial}#wpmem_login input[type=password],#wpmem_login input[type=text],#wpmem_reg input[type=date],#wpmem_reg input[type=email],#wpmem_reg input[type=number],#wpmem_reg input[type=password],#wpmem_reg input[type=text],#wpmem_reg input[type=url],#wpmem_reg textarea{border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;padding:8px 10px 8px;background:none repeat scroll 0 0 #fff}#wpmem_login button,#wpmem_login input,#wpmem_reg button,#wpmem_reg input,#wpmem_reg select,#wpmem_reg textarea{-moz-box-sizing:border-box;font-size:100%;margin:0;max-width:100%;vertical-align:baseline}#wpmem_login input:focus,#wpmem_reg input:focus,#wpmem_reg textarea:focus{border:1px solid rgba(0,0,0,.3);outline:0 none}#wpmem_reg select{width:100%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0;background:none repeat scroll 0 0 #fff}#wpmem_login fieldset,#wpmem_reg fieldset{border:none;padding:0;margin:40px 0}#wpmem_login legend,#wpmem_reg legend{font-size:24px;line-height:1;font-weight:700;margin-bottom:10px;width:100%}#wpmem_login .form,#wpmem_reg .form{margin:0;padding:0}#wpmem_login .clear,#wpmem_reg .clear{clear:both}#wpmem_login .holder,#wpmem_reg .holder{background-color:#fff}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_date,#wpmem_reg .div_file,#wpmem_reg .div_image,#wpmem_reg .div_membership,#wpmem_reg .div_multicheckbox,#wpmem_reg .div_multiselect,#wpmem_reg .div_number,#wpmem_reg .div_radio,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg .div_url{margin:0 0 14px 0}#wpmem_login input[type=checkbox]{margin:12px 2px}#wpmem_login .password,#wpmem_login .textbox,#wpmem_login .username,#wpmem_reg .div_textarea textarea,#wpmem_reg .file,#wpmem_reg .image,#wpmem_reg .password,#wpmem_reg .textbox,#wpmem_reg .username{width:100%}#wpmem_reg textarea{height:185px}#wpmem_reg .req{color:#bd3500;font-size:22px;line-height:50%}#wpmem_reg .req-text{margin:20px 0 0 5px}#wpmem_reg .noinput{width:93%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0}#wpmem_reg .captcha{margin:5px 0}#wpmem_reg .captcha table{line-height:0}#wpmem_login .link-text{padding:4px 0;text-align:right}#tos{margin-right:5px}#wpmem_login .button_div,#wpmem_reg .button_div{padding:6px 0;text-align:right}@media screen and (max-width:720px){#wpmem_login .button_div,#wpmem_login .div_text,#wpmem_login label,#wpmem_reg .button_div,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{float:none}#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{width:90%;padding:5px 0 0 0}#wpmem_reg label.textarea{height:26px}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea{width:98%}#wpmem_msg,.wpmem_msg{width:100%}#wpmem_login .button_div,#wpmem_login .link-text,#wpmem_reg .button_div{width:98%}} \ No newline at end of file +#wpmem_msg,.wpmem_msg{text-align:center;background:#f9f9f9;border:1px solid #d3d3d3;border-radius:3px;padding:20px 0;margin:15px 0;}#wpmem_login,#wpmem_msg,#wpmem_reg,.wpmem_msg{width:75%}#wp-members{width:100%}#wp-members fieldset{border:none;padding:0}#wp-members input{font-family:inherit}#wp-members input[type=password],#wp-members input[type=text]{margin:0 0 4px 0}#wp-members input[type=submit]{padding:5px 6px 4px;margin:0 4px 0 0}#wp-members .button_div{margin-top:4px}#wp-members .err{width:100%;padding:5px;font-family:inherit;border:1px solid #ccc;border-radius:3px}#wpmem_login,#wpmem_reg{color:#2b2b2b;font-family:Arial,sans-serif;font-size:16px;font-weight:400;line-height:1.5}#wpmem_login label,#wpmem_reg label{display:initial}#wpmem_login input[type=password],#wpmem_login input[type=text],#wpmem_reg input[type=date],#wpmem_reg input[type=email],#wpmem_reg input[type=number],#wpmem_reg input[type=password],#wpmem_reg input[type=text],#wpmem_reg input[type=url],#wpmem_reg textarea{border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;padding:8px 10px 8px;background:none repeat scroll 0 0 #fff}#wpmem_login button,#wpmem_login input,#wpmem_reg button,#wpmem_reg input,#wpmem_reg select,#wpmem_reg textarea{-moz-box-sizing:border-box;font-size:100%;margin:0;max-width:100%;vertical-align:baseline}#wpmem_login input:focus,#wpmem_reg input:focus,#wpmem_reg textarea:focus{border:1px solid rgba(0,0,0,.3);outline:0 none}#wpmem_reg select{width:100%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0;background:none repeat scroll 0 0 #fff}#wpmem_login fieldset,#wpmem_reg fieldset{border:none;padding:0;margin:40px 0}#wpmem_login legend,#wpmem_reg legend{font-size:24px;line-height:1;font-weight:700;margin-bottom:10px;width:100%}#wpmem_login .form,#wpmem_reg .form{margin:0;padding:0}#wpmem_login .clear,#wpmem_reg .clear{clear:both}#wpmem_login .holder,#wpmem_reg .holder{background-color:#fff}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_date,#wpmem_reg .div_file,#wpmem_reg .div_image,#wpmem_reg .div_membership,#wpmem_reg .div_multicheckbox,#wpmem_reg .div_multiselect,#wpmem_reg .div_number,#wpmem_reg .div_radio,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg .div_url{margin:0 0 14px 0}#wpmem_login input[type=checkbox]{margin:12px 2px}#wpmem_login .password,#wpmem_login .textbox,#wpmem_login .username,#wpmem_reg .div_textarea textarea,#wpmem_reg .file,#wpmem_reg .image,#wpmem_reg .password,#wpmem_reg .textbox,#wpmem_reg .username{width:100%}#wpmem_reg textarea{height:185px}#wpmem_reg .req{color:#bd3500;font-size:22px;line-height:50%}#wpmem_reg .req-text{margin:20px 0 0 5px}#wpmem_reg .noinput{width:93%;padding:8px 10px 7px;border:1px solid rgba(0,0,0,.1);border-radius:2px;color:#2b2b2b;margin:5px 0}#wpmem_reg .captcha{margin:5px 0}#wpmem_reg .captcha table{line-height:0}#wpmem_login .link-text{padding:4px 0;text-align:right}#tos{margin-right:5px}#wpmem_login .button_div,#wpmem_reg .button_div{padding:6px 0;text-align:right}@media screen and (max-width:720px){#wpmem_login .button_div,#wpmem_login .div_text,#wpmem_login label,#wpmem_reg .button_div,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea,#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{float:none}#wpmem_reg label.checkbox,#wpmem_reg label.select,#wpmem_reg label.text,#wpmem_reg label.textarea{width:90%;padding:5px 0 0 0}#wpmem_reg label.textarea{height:26px}#wpmem_login .div_text,#wpmem_reg .div_checkbox,#wpmem_reg .div_select,#wpmem_reg .div_text,#wpmem_reg .div_textarea{width:98%}#wpmem_msg,.wpmem_msg{width:100%}#wpmem_login .button_div,#wpmem_login .link-text,#wpmem_reg .button_div{width:98%}} \ No newline at end of file From 6c8e16496b153a17dedcb2acc84304522783bdf7 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Sun, 5 Dec 2021 14:19:26 -0500 Subject: [PATCH 1522/1694] add wpmem_get_display_message() and debug --- includes/api/api.php | 35 ++++++++++++++----- includes/class-wp-members-dialogs.php | 22 ++++++++++-- includes/class-wp-members-pwd-reset.php | 6 ++-- includes/class-wp-members-shortcodes.php | 26 +++++++------- includes/class-wp-members-validation-link.php | 2 +- includes/class-wp-members.php | 23 +++--------- includes/deprecated.php | 8 ++--- 7 files changed, 71 insertions(+), 51 deletions(-) diff --git a/includes/api/api.php b/includes/api/api.php index ab52ba3e..cf45b22c 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -362,27 +362,44 @@ function wpmem_logout_link() { return apply_filters( 'wpmem_logout_link', add_query_arg( 'a', 'logout' ) ); } +/** + * Gets requested dialog. + * + * @since 3.4.0 + * + * @note It is being relased now as tentative. + * There may be some changes to how this is applied. + * + * @todo What about wpmem_use_custom_dialog()? + * + * @global stdClass $wpmem + * @param string $tag + * @param string $custom + * @return + */ +function wpmem_get_display_message( $tag, $custom = false ) { + global $wpmem; + return $wpmem->dialogs->get_message( $tag, $custom ); +} + /** * Dispalays requested dialog. + * + * @note It is being relased now as tentative. + * There may be some changes to how this is applied. * * @since 3.2.0 - * @since 3.4.0 Added $custom argument + * @since 3.4.0 Now echos the message. Added $custom argument * * @todo What about wpmem_use_custom_dialog()? * * @global stdClass $wpmem * @param string $tag - * @param boolean $echo * @param string $custom * @return */ -function wpmem_display_message( $tag, $echo = false, $custom = false ) { - global $wpmem; - if ( $echo ) { - echo $wpmem->dialogs->message( $tag, $custom ); - } else { - return $wpmem->dialogs->message( $tag, $custom ); - } +function wpmem_display_message( $tag, $custom = false ) { + echo wpmem_get_display_message( $tag, $custom ); } /** diff --git a/includes/class-wp-members-dialogs.php b/includes/class-wp-members-dialogs.php index d17bb616..8c8091b6 100644 --- a/includes/class-wp-members-dialogs.php +++ b/includes/class-wp-members-dialogs.php @@ -231,6 +231,8 @@ function get_text( $str ) { */ function login_failed() { + global $wpmem; + // Defaults. $defaults = array( 'div_before' => '', @@ -239,7 +241,7 @@ function login_failed() { 'heading' => '', //wpmem_get_text( 'login_failed_heading' ), 'heading_after' => '', 'p_before' => '', - 'message' => wpmem_get_text( 'login_failed' ), // @todo $this->error + 'message' => ( $wpmem->error ) ? $wpmem->error : wpmem_get_text( 'login_failed' ), // @todo $this->error 'p_after' => '', //'link' => '' . wpmem_get_text( 'login_failed_link' ) . '', ); @@ -275,8 +277,20 @@ function login_failed() { return $str; } - - function message( $tag, $custom ) { + + /** + * Gets the message to display. + * + * @since 3.4.0 + * + * @todo This replaces some other functions and usage seems to be inconsistent. + * Review and replace useage as needed. + * + * @param $tag string + * @param $custom string + * @return $message string + */ + function get_message( $tag, $custom = false ) { // defaults $defaults = array( @@ -321,6 +335,8 @@ function message( $tag, $custom ) { } } elseif ( 'loginfailed' == $tag ) { $msg = $this->login_failed(); + } elseif ( $custom ) { + $msg = $custom; } else { // It must be a custom message ("custom" in that it is not included in the dialogs array). $msg = $tag; diff --git a/includes/class-wp-members-pwd-reset.php b/includes/class-wp-members-pwd-reset.php index c362dc9a..ff116fb0 100644 --- a/includes/class-wp-members-pwd-reset.php +++ b/includes/class-wp-members-pwd-reset.php @@ -162,7 +162,7 @@ function display_content( $content ) { if ( $pass1 !== $pass2 ) { // Legacy WP-Members error. $result = 'pwdchangerr'; - $msg = wpmem_display_message( 'pwdchangerr' ); + $msg = wpmem_get_display_message( 'pwdchangerr' ); // WP Error. $errors->add( 'password_reset_mismatch', __( 'The passwords do not match.' ) ); } @@ -172,7 +172,7 @@ function display_content( $content ) { if ( ( ! $errors->has_errors() ) && isset( $pass1 ) && ! empty( $pass1 ) ) { reset_password( $user, $pass1 ); - $msg = wpmem_display_message( 'pwdchangesuccess' ) . wpmem_login_form( 'pwdreset' ); + $msg = wpmem_get_display_message( 'pwdchangesuccess' ) . wpmem_login_form( 'pwdreset' ); $result = 'pwdchangesuccess'; } } @@ -182,7 +182,7 @@ function display_content( $content ) { if ( 'invalid_key' == $user->get_error_code() ) { // If somehow the form was submitted but the key not found. $pwd_reset_link = wpmem_profile_url( 'pwdreset' ); - $msg = wpmem_display_message( 'invalid_key', $this->form_submitted_key_not_found . '
    Request a new reset key.' ); + $msg = wpmem_get_display_message( 'invalid_key', $this->form_submitted_key_not_found . '
    Request a new reset key.' ); $form = ''; } else { $form = wpmem_change_password_form(); diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index 94d4baec..e1a380d2 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -132,7 +132,7 @@ function forms( $atts, $content, $tag ) { $content = ( $content ) ? $content : $this->render_links( 'register' ); } elseif ( is_user_logged_in() && is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) { $wpmem_themsg = __( "This is a generic message to display the form message dialog in the Customizer.", 'wp-members' ); - $content = wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); + $content = wpmem_get_display_message( $wpmem->regchk, $wpmem_themsg ); $content .= wpmem_register_form( $reg_form_args ); } else { if ( $wpmem->regchk == 'loginfailed' ) { @@ -144,7 +144,7 @@ function forms( $atts, $content, $tag ) { global $wpmem_captcha_err; $wpmem_themsg = wpmem_get_text( 'reg_captcha_err' ) . '

    ' . $wpmem_captcha_err; } - $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_display_message( $wpmem->regchk, $wpmem_themsg ) : ''; + $content = ( $wpmem_themsg || $wpmem->regchk == 'success' ) ? wpmem_get_display_message( $wpmem->regchk, $wpmem_themsg ) : ''; $content .= ( $wpmem->regchk == 'success' ) ? wpmem_login_form() : wpmem_register_form( $reg_form_args ); } break; @@ -179,7 +179,7 @@ function forms( $atts, $content, $tag ) { } else { $content = ''; if ( $wpmem->regchk == 'loginfailed' || ( is_customize_preview() && get_theme_mod( 'wpmem_show_form_message_dialog', false ) ) ) { - $content = $wpmem->dialogs->login_failed(); + $content = wpmem_get_display_message( 'loginfailed' ); } $form_id = ( $atts['form_id'] ) ? $atts['form_id'] : 'wpmem_login_form'; $content .= wpmem_login_form( array( 'redirect_to'=>$atts['redirect_to'], 'form_id'=>$form_id ) ); @@ -441,11 +441,11 @@ function user_profile( $atts, $content, $tag ) { case "update": // Determine if there are any errors/empty fields. if ( $wpmem->regchk == "updaterr" || $wpmem->regchk == "email" ) { - $content = $content . wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_get_display_message( $wpmem->regchk, $wpmem_themsg ); $content = $content . wpmem_register_form( 'edit' ); } else { //Case "editsuccess". - $content = $content . wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); + $content = $content . wpmem_get_display_message( $wpmem->regchk, $wpmem_themsg ); $content = $content . $this->render_links(); } break; @@ -472,7 +472,7 @@ function user_profile( $atts, $content, $tag ) { if ( ( 'login' == $wpmem->action ) || ( 'register' == $wpmem->action && ! $hide_register ) ) { - $content = wpmem_display_message( $wpmem->regchk, $wpmem_themsg ); + $content = wpmem_get_display_message( $wpmem->regchk, $wpmem_themsg ); $content.= ( 'loginfailed' == $wpmem->regchk || 'success' == $wpmem->regchk ) ? wpmem_login_form() : wpmem_register_form(); } elseif ( $wpmem->action == 'pwdreset' ) { @@ -841,12 +841,12 @@ function render_pwd_reset( $wpmem_regchk, $content ) { switch ( $wpmem_regchk ) { case "pwdchangesuccess": - $content = $content . wpmem_display_message( $wpmem_regchk ); + $content = $content . wpmem_get_display_message( $wpmem_regchk ); break; default: if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { - $content .= wpmem_display_message( $wpmem_regchk, wpmem_get_text( $wpmem_regchk ) ); + $content .= wpmem_get_display_message( $wpmem_regchk, wpmem_get_text( $wpmem_regchk ) ); } $content = $content . wpmem_change_password_form(); break; @@ -864,13 +864,13 @@ function render_pwd_reset( $wpmem_regchk, $content ) { switch( $wpmem_regchk ) { case "pwdresetsuccess": - $content = $content . wpmem_display_message( $wpmem_regchk ); + $content = $content . wpmem_get_display_message( $wpmem_regchk ); $wpmem_regchk = ''; // Clear regchk. break; default: if ( isset( $wpmem_regchk ) && '' != $wpmem_regchk ) { - $content = wpmem_display_message( $wpmem_regchk, wpmem_get_text( $wpmem_regchk ) ); + $content = wpmem_get_display_message( $wpmem_regchk, wpmem_get_text( $wpmem_regchk ) ); } $content = $content . wpmem_reset_password_form(); break; @@ -911,7 +911,7 @@ function render_user_edit( $wpmem_regchk, $content, $atts = false ) { $heading = apply_filters( 'wpmem_user_edit_heading', wpmem_get_text( 'profile_heading' ) ); if ( $wpmem_a == "update") { - $content.= wpmem_display_message( $wpmem_regchk, $wpmem_themsg ); + $content.= wpmem_get_display_message( $wpmem_regchk, $wpmem_themsg ); } $args['tag'] = 'edit'; @@ -947,7 +947,7 @@ function render_forgot_username( $wpmem_regchk, $content ) { case "usernamefailed": $msg = wpmem_get_text( 'usernamefailed' ); $content = $content - . wpmem_display_message( 'usernamefailed', $msg ) + . wpmem_get_display_message( 'usernamefailed', $msg ) . wpmem_forgot_username_form(); $wpmem->regchk = ''; // Clear regchk. break; @@ -955,7 +955,7 @@ function render_forgot_username( $wpmem_regchk, $content ) { case "usernamesuccess": $email = ( isset( $_POST['user_email'] ) ) ? sanitize_email( $_POST['user_email'] ) : ''; $msg = sprintf( wpmem_get_text( 'usernamesuccess' ), $email ); - $content = $content . wpmem_display_message( 'usernamesuccess', $msg ); + $content = $content . wpmem_get_display_message( 'usernamesuccess', $msg ); $wpmem->regchk = ''; // Clear regchk. break; diff --git a/includes/class-wp-members-validation-link.php b/includes/class-wp-members-validation-link.php index c28d74b2..04775476 100644 --- a/includes/class-wp-members-validation-link.php +++ b/includes/class-wp-members-validation-link.php @@ -253,7 +253,7 @@ public function validation_success( $content ) { $msg = ''; } - $content = wpmem_display_message( '', $msg ) . $content; + $content = wpmem_get_display_message( 'custom', $msg ) . $content; } return $content; diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 8f9b4328..9ef7d1b4 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -523,7 +523,9 @@ function load_hooks() { // Replace login error object. if ( 1 == $this->login_error ) { - add_filter( 'wpmem_login_failed_args', array( $this, 'login_error' ) ); + // @todo I think we can do this without the filter now that + // the main messaging function has been updated. + // add_filter( 'wpmem_login_failed_args', array( $this->dialogs, 'login_error' ) ); add_filter( 'lostpassword_url', array( $this, 'lost_pwd_url' ), 10, 2 ); } @@ -922,7 +924,7 @@ function do_securify( $content = null ) { // If there is a regchk action, show the login and/or registration forms. if ( $this->regchk ) { - $content = wpmem_display_message( $this->regchk, $wpmem_themsg ); + $content = wpmem_get_display_message( $this->regchk, $wpmem_themsg ); $content .= ( 'loginfailed' == $this->regchk || 'success' == $this->regchk ) ? wpmem_login_form() : wpmem_register_form(); } else { @@ -1119,7 +1121,7 @@ function reg_securify( $content ) { global $wpmem, $wpmem_themsg; $nonce = wpmem_get( 'reg_nonce', false, 'get' ); if ( $nonce && wp_verify_nonce( $nonce, 'register_redirect' ) ) { - $content = wpmem_display_message( 'success', $wpmem_themsg ); + $content = wpmem_get_display_message( 'success', $wpmem_themsg ); $content = $content . wpmem_login_form(); } return $content; @@ -1777,21 +1779,6 @@ function lost_pwd_url( $lostpwd_url, $redirect ) { return wpmem_profile_url( 'pwdreset' ); } - /** - * Filters the login error message to display the WP login error. - * - * @since 3.3.5 - */ - function login_error( $args = array() ) { - if ( $this->error ) { - $args['heading_before'] = ''; - $args['heading'] = ''; - $args['heading_after'] = ''; - $args['message'] = $this->error; - } - return $args; - } - /** * Google recaptcha v3 (invisible) gives more accurate user scores * if it is loaded on all pages. diff --git a/includes/deprecated.php b/includes/deprecated.php index f7573170..294727c6 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -134,7 +134,7 @@ function wpmem_reg_securify( $content ) { global $wpmem, $wpmem_themsg; $nonce = wpmem_get( 'reg_nonce', false, 'get' ); if ( $nonce && wp_verify_nonce( $nonce, 'register_redirect' ) ) { - $content = wpmem_display_message( 'success', $wpmem_themsg ); + $content = wpmem_get_display_message( 'success', $wpmem_themsg ); $content = $content . wpmem_login_form(); } return $content; @@ -495,7 +495,7 @@ function wpmem_inc_loginfailed() { * * @since 1.8 * @since 3.3.0 Changed 'toggles' to 'tags' - * @deprecated 3.4.0 Use wpmem_display_message() instead. + * @deprecated 3.4.0 Use wpmem_get_display_message() instead. * * @global object $wpmem * @param string $tag Error message tag to look for specific error messages. @@ -503,9 +503,9 @@ function wpmem_inc_loginfailed() { * @return string $str The final HTML for the message. */ function wpmem_inc_regmessage( $tag, $msg = '' ) { - wpmem_write_log( "wpmem_inc_regmessage() is deprecated as of WP-Members 3.4.0. Use wpmem_display_message() instead." ); + wpmem_write_log( "wpmem_inc_regmessage() is deprecated as of WP-Members 3.4.0. Use wpmem_get_display_message() instead." ); global $wpmem; - return $wpmem->dialogs->message( $tag, $msg ); + return $wpmem->dialogs->get_message( $tag, $msg ); } endif; From ff0533c79ac5d027c98bbf0d43a152c3e390d826 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 6 Dec 2021 09:02:51 -0500 Subject: [PATCH 1523/1694] update wpmem_sanitize_field() as an alias for rktgk_sanitize_field() --- includes/api/api-forms.php | 3 +-- includes/libraries/rocketgeek-utilities/includes/forms.php | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index 6c82f65e..ceae10ea 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -355,8 +355,7 @@ function wpmem_sanitize_array( $data, $type = false ) { * @return string $sanitized_data */ function wpmem_sanitize_field( $data, $type = 'text' ) { - global $wpmem; - return $wpmem->forms->sanitize_field( $data, $type ); + return rktgk_sanitize_field( $data, $type ); } /** diff --git a/includes/libraries/rocketgeek-utilities/includes/forms.php b/includes/libraries/rocketgeek-utilities/includes/forms.php index f16e3233..06c90b04 100644 --- a/includes/libraries/rocketgeek-utilities/includes/forms.php +++ b/includes/libraries/rocketgeek-utilities/includes/forms.php @@ -124,7 +124,7 @@ function rktgk_sanitize_array( $data, $type = false ) { * @since 1.0.0 * * @param string $data - * @param string $type + * @param string $type (multiselect|multicheckbox|textarea|email|file|image|int|integer|number) * @return string $sanitized_data */ function rktgk_sanitize_field( $data, $type = '' ) { From dfffe1108c634f5d1246e13eb22716d807416f9f Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 6 Dec 2021 09:04:07 -0500 Subject: [PATCH 1524/1694] use wpmem_sanitize_field() --- .../class-wp-members-admin-tab-options.php | 46 +++++++-------- includes/class-wp-members-forms.php | 57 +------------------ 2 files changed, 25 insertions(+), 78 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index c8eaec67..c7e30a45 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -459,7 +459,7 @@ static function update( $action ) { check_admin_referer( 'wpmem-update-settings' ); $wpmem_settings_msurl = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? esc_url( $_POST['wpmem_settings_msurl'] ) : ''; - $wpmem_settings_mspage = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? '' : filter_var( $_POST['wpmem_settings_mspage'], FILTER_SANITIZE_NUMBER_INT ); + $wpmem_settings_mspage = ( $_POST['wpmem_settings_mspage'] == 'use_custom' ) ? '' : wpmem_sanitize_field( $_POST['wpmem_settings_mspage'], 'int' ); if ( $wpmem_settings_msurl != wpmem_use_ssl() && $wpmem_settings_msurl != 'use_custom' && ! $wpmem_settings_mspage ) { $msurl = trim( $wpmem_settings_msurl ); } else { @@ -467,7 +467,7 @@ static function update( $action ) { } $wpmem_settings_regurl = ( $_POST['wpmem_settings_regpage'] == 'use_custom' ) ? esc_url( $_POST['wpmem_settings_regurl'] ) : ''; - $wpmem_settings_regpage = ( $_POST['wpmem_settings_regpage'] == 'use_custom' ) ? '' : filter_var( $_POST['wpmem_settings_regpage'], FILTER_SANITIZE_NUMBER_INT ); + $wpmem_settings_regpage = ( $_POST['wpmem_settings_regpage'] == 'use_custom' ) ? '' : wpmem_sanitize_field( $_POST['wpmem_settings_regpage'], 'int' ); if ( $wpmem_settings_regurl != wpmem_use_ssl() && $wpmem_settings_regurl != 'use_custom' && ! $wpmem_settings_regpage ) { $regurl = trim( $wpmem_settings_regurl ); } else { @@ -475,7 +475,7 @@ static function update( $action ) { } $wpmem_settings_logurl = ( $_POST['wpmem_settings_logpage'] == 'use_custom' ) ? esc_url( $_POST['wpmem_settings_logurl'] ) : ''; - $wpmem_settings_logpage = ( $_POST['wpmem_settings_logpage'] == 'use_custom' ) ? '' : filter_var( $_POST['wpmem_settings_logpage'], FILTER_SANITIZE_NUMBER_INT ); + $wpmem_settings_logpage = ( $_POST['wpmem_settings_logpage'] == 'use_custom' ) ? '' : wpmem_sanitize_field( $_POST['wpmem_settings_logpage'], 'int' ); if ( $wpmem_settings_logurl != wpmem_use_ssl() && $wpmem_settings_logurl != 'use_custom' && ! $wpmem_settings_logpage ) { $logurl = trim( $wpmem_settings_logurl ); } else { @@ -489,31 +489,31 @@ static function update( $action ) { $wpmem_newsettings = array( 'version' => $wpmem->version, - 'db_version' => $wpmem->db_version, - 'act_link' => filter_var( wpmem_get( 'wpmem_settings_act_link', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'pwd_link' => filter_var( wpmem_get( 'wpmem_settings_pwd_link', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'login_error' => filter_var( wpmem_get( 'wpmem_settings_login_error', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'enable_products' => filter_var( wpmem_get( 'wpmem_settings_products', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'clone_menus' => filter_var( wpmem_get( 'wpmem_settings_menus', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'notify' => filter_var( wpmem_get( 'wpmem_settings_notify', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'mod_reg' => filter_var( wpmem_get( 'wpmem_settings_moderate', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'captcha' => filter_var( wpmem_get( 'wpmem_settings_captcha', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'use_exp' => filter_var( wpmem_get( 'wpmem_settings_time_exp', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'use_trial' => filter_var( wpmem_get( 'wpmem_settings_trial', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'warnings' => filter_var( wpmem_get( 'wpmem_settings_ignore_warnings', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'dropins' => filter_var( wpmem_get( 'wpmem_settings_enable_dropins', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'user_pages' => array( + 'db_version' => $wpmem->db_version, + 'act_link' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_act_link', 0 ), 'int' ), + 'pwd_link' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_pwd_link', 1 ), 'int' ), + 'login_error' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_login_error', 1 ), 'int' ), + 'enable_products' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_products', 0 ), 'int' ), + 'clone_menus' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_menus', 0 ), 'int' ), + 'notify' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_notify', 0 ), 'int' ), + 'mod_reg' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_moderate', 0 ), 'int' ), + 'captcha' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_captcha', 0 ), 'int' ), + 'use_exp' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_time_exp', 0 ), 'int' ), + 'use_trial' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_trial', 0 ), 'int' ), + 'warnings' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_ignore_warnings', 0 ), 'int' ), + 'dropins' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_enable_dropins', 0 ), 'int' ), + 'user_pages' => array( 'profile' => ( $msurl ) ? $msurl : '', 'register' => ( $regurl ) ? $regurl : '', 'login' => ( $logurl ) ? $logurl : '', ), 'woo' => array( - 'add_my_account_fields' => filter_var( wpmem_get( 'wpmem_settings_add_my_account_fields', 0 ), FILTER_SANITIZE_NUMBER_INT ), - 'add_checkout_fields' => filter_var( wpmem_get( 'wpmem_settings_add_checkout_fields', 0 ), FILTER_SANITIZE_NUMBER_INT ), + 'add_my_account_fields' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_add_my_account_fields', 0 ), 'int' ), + 'add_checkout_fields' => wpmem_sanitize_field( wpmem_get( 'wpmem_settings_add_checkout_fields', 0 ), 'int' ), ), 'cssurl' => ( $cssurl ) ? $cssurl : '', 'select_style' => $wpmem_settings_style, - 'attrib' => filter_var( wpmem_get( 'attribution', 0 ), FILTER_SANITIZE_NUMBER_INT ), + 'attrib' => wpmem_sanitize_field( wpmem_get( 'attribution', 0 ), 'int' ), ); // Build an array of post types @@ -543,12 +543,12 @@ static function update( $action ) { $post_var = 'wpmem_' . $option_group_item . '_' . $post_type; if ( $option_group_item == 'autoex' ) { // Auto excerpt is an array. - $arr[ $post_type ]['enabled'] = ( isset( $_POST[ $post_var ] ) ) ? filter_var( $_POST[ $post_var ], FILTER_SANITIZE_NUMBER_INT ) : 0; - $arr[ $post_type ]['length'] = ( isset( $_POST[ $post_var . '_len' ] ) ) ? ( ( $_POST[ $post_var . '_len' ] == '' ) ? 0 : filter_var( $_POST[ $post_var . '_len' ], FILTER_SANITIZE_NUMBER_INT ) ) : ''; + $arr[ $post_type ]['enabled'] = ( isset( $_POST[ $post_var ] ) ) ? wpmem_sanitize_field( $_POST[ $post_var ], 'int' ) : 0; + $arr[ $post_type ]['length'] = ( isset( $_POST[ $post_var . '_len' ] ) ) ? ( ( $_POST[ $post_var . '_len' ] == '' ) ? 0 : wpmem_sanitize_field( $_POST[ $post_var . '_len' ], 'int' ) ) : ''; $arr[ $post_type ]['text'] = ( isset( $_POST[ $post_var . '_text' ] ) ) ? sanitize_text_field( $_POST[ $post_var . '_text' ] ) : ''; } else { // All other settings are 0|1. - $arr[ $post_type ] = ( isset( $_POST[ $post_var ] ) ) ? filter_var( $_POST[ $post_var ], FILTER_SANITIZE_NUMBER_INT ) : 0; + $arr[ $post_type ] = ( isset( $_POST[ $post_var ] ) ) ? wpmem_sanitize_field( $_POST[ $post_var ], 'int' ) : 0; } } $wpmem_newsettings[ $option_group_item ] = $arr; diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 1133a81a..8e7d0496 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -461,59 +461,6 @@ function create_form_label( $args ) { return $label; } - /** - * Sanitizes field based on field type. - * - * Obviously, this isn't an all inclusive function of every WordPress - * sanitization function. It is intended to handle sanitization of - * WP-Members form input and therefore includes the necessary methods - * that would relate to the WP-Members custom field types and can thus - * be used by looping through form data when the WP-Members fields are - * handled and validated. - * - * @since 3.2.9 - * @since 3.3.0 Added email, file, and image. - * - * @param string $data - * @param string $type - * @return string $sanitized_data - */ - function sanitize_field( $data, $type ) { - - switch ( $type ) { - - case 'multiselect': - case 'multicheckbox': - $sanitized_data = wpmem_sanitize_array( $data ); - break; - - case 'textarea': - $sanitized_data = sanitize_textarea_field( $data ); - break; - - case 'email': - $sanitized_data = sanitize_email( $data ); - break; - - case 'file': - case 'image': - $sanitized_data = sanitize_file_name( $data ); - break; - - case 'int': - case 'integer': - case 'number': - $sanitized_data = intval( $data ); - break; - - default: - $sanitized_data = sanitize_text_field( $data ); - break; - } - - return $sanitized_data; - } - /** * Uploads file from the user. * @@ -1184,7 +1131,7 @@ function register_form( $mixed = 'new', $redirect_to = null ) { if ( 'file' == $field['type'] ) { $val = ( isset( $_FILES[ $meta_key ]['name'] ) ) ? sanitize_file_name( $_FILES[ $meta_key ]['name'] ) : '' ; } else { - $val = ( isset( $_POST[ $meta_key ] ) ) ? $this->sanitize_field( $_POST[ $meta_key ], $field['type'] ) : ''; + $val = ( isset( $_POST[ $meta_key ] ) ) ? wpmem_sanitize_field( $_POST[ $meta_key ], $field['type'] ) : ''; } } @@ -1762,7 +1709,7 @@ function wp_register_form( $process = 'wp' ) { $formfield_args = array( 'name' => $meta_key, 'type' => $field['type'], - 'value' => $this->sanitize_field( wpmem_get( $meta_key, '' ), $field['type'] ), + 'value' => wpmem_sanitize_field( wpmem_get( $meta_key, '' ), $field['type'] ), 'compare' => ( isset( $field['compare'] ) ) ? $field['compare'] : '', 'required' => $field['required'], 'class' => $class, From 35c51d38050d42ff5186d34ea73b93e515a16457 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 6 Dec 2021 09:05:22 -0500 Subject: [PATCH 1525/1694] fix logic for using default login error vs wp native --- includes/class-wp-members-dialogs.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-dialogs.php b/includes/class-wp-members-dialogs.php index 8c8091b6..e8836ba5 100644 --- a/includes/class-wp-members-dialogs.php +++ b/includes/class-wp-members-dialogs.php @@ -241,7 +241,7 @@ function login_failed() { 'heading' => '', //wpmem_get_text( 'login_failed_heading' ), 'heading_after' => '', 'p_before' => '', - 'message' => ( $wpmem->error ) ? $wpmem->error : wpmem_get_text( 'login_failed' ), // @todo $this->error + 'message' => ( $wpmem->error && 1 == $wpmem->login_error ) ? $wpmem->error : wpmem_get_text( 'login_failed' ), // @todo $this->error 'p_after' => '', //'link' => '' . wpmem_get_text( 'login_failed_link' ) . '', ); From d6ee063b89fd2bb770c931a5e70241faa0f46c17 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 6 Dec 2021 14:10:34 -0500 Subject: [PATCH 1526/1694] updates for swapping default settings --- includes/class-wp-members.php | 6 ++---- includes/install.php | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 9ef7d1b4..e115b27d 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -318,7 +318,7 @@ class WP_Members { * @access public * @var string */ - public $pwd_link = 0; + public $pwd_link = 1; /** * Temporary settings for login errors. @@ -328,7 +328,7 @@ class WP_Members { * @access public * @var string */ - public $login_error = 0; + public $login_error = 1; /** * Default file upload directory. @@ -1673,8 +1673,6 @@ function convert_tag( $tag ) { */ function load_textdomain() { - // @see: https://ulrich.pogson.ch/load-theme-plugin-translations for notes on changes. - // Plugin textdomain. $domain = 'wp-members'; diff --git a/includes/install.php b/includes/install.php index 89143ca9..f7393086 100644 --- a/includes/install.php +++ b/includes/install.php @@ -585,7 +585,7 @@ function wpmem_install_dialogs() { 'pwdchangerr' => "Passwords did not match.

    Please try again.", 'pwdchangesuccess' => "Password successfully changed!", 'pwdreseterr' => "Either the username or email address do not exist in our records.", - 'pwdresetsuccess' => "Password successfully reset!

    An email containing a new password has been sent to the email address on file for your account.", + 'pwdresetsuccess' => "An email with instructions to update your password has been sent to the email address on file for your account.", ); // Insert TOS dialog placeholder. $dummy_tos = "Put your TOS (Terms of Service) text here. You can use HTML markup."; From 2ddc0aae9fb47abf8a09a959cfcbe3ea0da5ff0d Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 6 Dec 2021 14:11:03 -0500 Subject: [PATCH 1527/1694] incorrect sanitize function name --- includes/class-wp-members-pwd-reset.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-pwd-reset.php b/includes/class-wp-members-pwd-reset.php index ff116fb0..2ea27bb3 100644 --- a/includes/class-wp-members-pwd-reset.php +++ b/includes/class-wp-members-pwd-reset.php @@ -207,7 +207,7 @@ function display_content( $content ) { function add_hidden_form_field( $hidden_fields, $action ) { if ( $this->form_action == wpmem_get( 'a', false, 'request' ) ) { $hidden_fields = str_replace( 'pwdchange', $this->form_action, $hidden_fields ); - $hidden_fields.= wpmem_form_field( array( 'name' => 'key', 'type' => 'hidden', 'value' => sanitize_text( wpmem_get( 'key', null, 'request' ) ) ) ); + $hidden_fields.= wpmem_form_field( array( 'name' => 'key', 'type' => 'hidden', 'value' => sanitize_text_field( wpmem_get( 'key', null, 'request' ) ) ) ); $hidden_fields.= wpmem_form_field( array( 'name' => 'login', 'type' => 'hidden', 'value' => sanitize_user( wpmem_get( 'login', null, 'request' ) ) ) ); } return $hidden_fields; From 74e888cd0b3201fe31e371d1343abf38420aa39b Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Dec 2021 09:29:48 -0500 Subject: [PATCH 1528/1694] improve membership display in user screen --- assets/css/admin.css | 4 ++++ assets/css/admin.min.css | 2 +- includes/admin/class-wp-members-admin-api.php | 8 +++++++- includes/admin/class-wp-members-products-admin.php | 6 +++--- 4 files changed, 15 insertions(+), 5 deletions(-) diff --git a/assets/css/admin.css b/assets/css/admin.css index 336b667a..e488c27a 100644 --- a/assets/css/admin.css +++ b/assets/css/admin.css @@ -134,4 +134,8 @@ updatesettings a:hover { #createuser .form-field input[type="checkbox"] { width: initial; +} + +.wpmem-user-table-membership { + border-bottom:1px solid #999; } \ No newline at end of file diff --git a/assets/css/admin.min.css b/assets/css/admin.min.css index 402ab1ad..6fa9bc34 100644 --- a/assets/css/admin.min.css +++ b/assets/css/admin.min.css @@ -1 +1 @@ -.wpmem_tbl_drag{background:#fffbcc;font-weight:700;border:1px solid #900}.column-wpmem_block{width:80px}#addfieldform li,#editfieldform li,#updatesettings li{padding:5px 0}#addfieldform label,#editfieldform label,#updatesettings label{float:left;width:166px;clear:both;display:block}#addfieldform .add-field-indent,#editfieldform .add-field-indent{margin-left:165px}#add_field_postbox,#fields_postbox{min-width:950px}.req{color:red}#the-list{cursor:move}#edit,#sort{width:30px}#wpmem_block input{vertical-align:-webkit-baseline-middle;margin:0 0 8px 0}#wpmem_block label{margin:0 0 0 8px}#wpmem_ok_block_status{margin:5px 0 0 0}#wpmem_post_block_status{font-weight:600}#wpmem_post_icon_0{color:red}#wpmem_post_icon_1{color:green}#wpmem_post_icon_2{color:#000}#wpmem_product_enabled{color:green}#_wpmem_products,#s2id__wpmem_products,.select2-search-field{width:100%}#wpmem_user_profile_tabs{padding:0;background:0 0;border-width:0}#wpmem_user_profile_tabs .ui-tabs-nav{padding-left:0;background:0 0;border-width:0 0 1px 0;-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}#wpmem_user_profile_tabs .ui-tabs-panel{background:#fff;border-width:0 1px 1px 1px}#wpmem_user_profile_tabs .ui-state-active{border:1px solid #006799;background:#008ec2}#wpmem_user_profile_tabs .ui-state-active a{color:#fff}#wpmem_product_fixed_period,#wpmem_product_fixed_period_select input,#wpmem_product_fixed_period_select label,#wpmem_product_no_gap{margin-top:10px;margin-left:24px}#updatesettings a{text-decoration:none}updatesettings a:hover{color:#000}#createuser .form-field input[type="checkbox"]{width: initial;} \ No newline at end of file +.wpmem_tbl_drag{background:#fffbcc;font-weight:700;border:1px solid #900}.column-wpmem_block{width:80px}#addfieldform li,#editfieldform li,#updatesettings li{padding:5px 0}#addfieldform label,#editfieldform label,#updatesettings label{float:left;width:166px;clear:both;display:block}#addfieldform .add-field-indent,#editfieldform .add-field-indent{margin-left:165px}#add_field_postbox,#fields_postbox{min-width:950px}.req{color:red}#the-list{cursor:move}#edit,#sort{width:30px}#wpmem_block input{vertical-align:-webkit-baseline-middle;margin:0 0 8px 0}#wpmem_block label{margin:0 0 0 8px}#wpmem_ok_block_status{margin:5px 0 0 0}#wpmem_post_block_status{font-weight:600}#wpmem_post_icon_0{color:red}#wpmem_post_icon_1{color:green}#wpmem_post_icon_2{color:#000}#wpmem_product_enabled{color:green}#_wpmem_products,#s2id__wpmem_products,.select2-search-field{width:100%}#wpmem_user_profile_tabs{padding:0;background:0 0;border-width:0}#wpmem_user_profile_tabs .ui-tabs-nav{padding-left:0;background:0 0;border-width:0 0 1px 0;-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}#wpmem_user_profile_tabs .ui-tabs-panel{background:#fff;border-width:0 1px 1px 1px}#wpmem_user_profile_tabs .ui-state-active{border:1px solid #006799;background:#008ec2}#wpmem_user_profile_tabs .ui-state-active a{color:#fff}#wpmem_product_fixed_period,#wpmem_product_fixed_period_select input,#wpmem_product_fixed_period_select label,#wpmem_product_no_gap{margin-top:10px;margin-left:24px}#updatesettings a{text-decoration:none}updatesettings a:hover{color:#000}#createuser .form-field input[type="checkbox"]{width: initial;}.wpmem-user-table-membership {border-bottom:1px solid #999;} \ No newline at end of file diff --git a/includes/admin/class-wp-members-admin-api.php b/includes/admin/class-wp-members-admin-api.php index 51b5b04e..91c4f005 100644 --- a/includes/admin/class-wp-members-admin-api.php +++ b/includes/admin/class-wp-members-admin-api.php @@ -532,7 +532,13 @@ function form_post_url( $args = false ) { */ function dashboard_enqueue_scripts( $hook ) { global $current_screen, $wpmem; - if ( 'edit.php' == $hook || 'settings_page_wpmem-settings' == $hook || 'post.php' == $hook || 'post-new.php' == $hook || 'user-edit.php' == $hook || 'profile.php' == $hook ) { + if ( 'edit.php' == $hook + || 'settings_page_wpmem-settings' == $hook + || 'post.php' == $hook + || 'post-new.php' == $hook + || 'user-edit.php' == $hook + || 'profile.php' == $hook + || 'users.php' ) { wp_enqueue_style( 'wpmem-admin', $wpmem->url . 'assets/css/admin' . wpmem_get_suffix() . '.css', '', $wpmem->version ); } if ( 'settings_page_wpmem-settings' == $hook || 'post.php' == $hook || 'post-new.php' == $hook ) { diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index cb280aa4..80e9107e 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -640,8 +640,8 @@ function user_columns_content( $val, $column_name, $user_id ) { if ( $user_products ) { foreach ( $user_products as $meta => $value ) { if ( isset( $wpmem->membership->products[ $meta ]['title'] ) ) { - $expires = ( $user_products[ $meta ] > 1 ) ? ' expires: ' . date_i18n( get_option( 'date_format' ), $user_products[ $meta ] ) : ''; - $display[] = $wpmem->membership->products[ $meta ]['title'] . $expires; + $expires = ( $user_products[ $meta ] > 1 ) ? '
    expires: ' . date_i18n( get_option( 'date_format' ), $user_products[ $meta ] ) : ''; + $display[] = '
    ' . $wpmem->membership->products[ $meta ]['title'] . $expires . '
    '; } } } @@ -655,7 +655,7 @@ function user_columns_content( $val, $column_name, $user_id ) { * @param int $user_id * @param array $user_products */ - return apply_filters( 'wpmem_user_columns_membership_value', implode( "
    ", $display ), $display, $user_id, $user_products ); + return apply_filters( 'wpmem_user_columns_membership_value', implode( " ", $display ), $display, $user_id, $user_products ); } return $val; } From e4a35f89f4b18814fcd1402e3a745be2bfb1c129 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 7 Dec 2021 12:57:05 -0500 Subject: [PATCH 1529/1694] added filter for all users screen membership column html --- .../admin/class-wp-members-products-admin.php | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index 80e9107e..9f56eb49 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -633,6 +633,20 @@ function user_columns( $columns ) { * @return array $display */ function user_columns_content( $val, $column_name, $user_id ) { + /** + * Filter the users > all users screen membership column default html. + * + * @since 3.4.0 + * + * @param array $defaults + * @param array $val + * @param array $column_name + * @param array $user_id + */ + $defaults = apply_filters( 'wpmem_user_columns_membership_defaults', array( + 'item_wrap_before' => '
    ', + 'item_wrap_after' => '
    ', + ), $val, $column_name, $user_id ); if ( 'wpmem_product' == $column_name ) { global $wpmem; $display = array(); @@ -640,8 +654,8 @@ function user_columns_content( $val, $column_name, $user_id ) { if ( $user_products ) { foreach ( $user_products as $meta => $value ) { if ( isset( $wpmem->membership->products[ $meta ]['title'] ) ) { - $expires = ( $user_products[ $meta ] > 1 ) ? '
    expires: ' . date_i18n( get_option( 'date_format' ), $user_products[ $meta ] ) : ''; - $display[] = '
    ' . $wpmem->membership->products[ $meta ]['title'] . $expires . '
    '; + $expires = ( $user_products[ $meta ] > 1 ) ? '
    ' . __( 'expires:', 'wp-members' ) . ' ' . date_i18n( get_option( 'date_format' ), $user_products[ $meta ] ) : ''; + $display[] = $defaults['item_wrap_before'] . $wpmem->membership->products[ $meta ]['title'] . $expires . $defaults['item_wrap_after']; } } } From 3108b325ef9aad34dff77d717783e0a25d725485 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 10 Dec 2021 08:36:49 -0500 Subject: [PATCH 1530/1694] debug if screen loads with no $post (i.e. 404) --- includes/class-wp-members-validation-link.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/includes/class-wp-members-validation-link.php b/includes/class-wp-members-validation-link.php index 04775476..4bec64b4 100644 --- a/includes/class-wp-members-validation-link.php +++ b/includes/class-wp-members-validation-link.php @@ -280,8 +280,7 @@ function check_validated( $user, $username, $password ) { } // Validation flag must be confirmed. - $validated = get_user_meta( $user->ID, $this->validation_confirm, true ); // @todo Update to use wpmem_is_user_confirmed(). - if ( false == $validated ) { + if ( false == wpmem_is_user_confirmed( $user->ID ) ) { return new WP_Error( 'authentication_failed', __( 'ERROR: User has not confirmed their account.', 'wp-members' ) ); } From 0d7d4df309e4eafe36e4d339fa188d9837703bbd Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 13 Dec 2021 10:37:34 -0500 Subject: [PATCH 1531/1694] comment updates --- .../rocketgeek-utilities/includes/arrays.php | 4 +- .../rocketgeek-utilities/includes/dates.php | 13 +++--- .../rocketgeek-utilities/includes/debug.php | 4 +- .../rocketgeek-utilities/includes/forms.php | 4 +- .../rocketgeek-utilities/includes/strings.php | 41 ++++++++++++++++++- .../includes/utilities.php | 40 +----------------- .../libraries/rocketgeek-utilities/loader.php | 4 +- wp-members.php | 6 --- 8 files changed, 57 insertions(+), 59 deletions(-) diff --git a/includes/libraries/rocketgeek-utilities/includes/arrays.php b/includes/libraries/rocketgeek-utilities/includes/arrays.php index 2c1b33a1..53fad0e7 100644 --- a/includes/libraries/rocketgeek-utilities/includes/arrays.php +++ b/includes/libraries/rocketgeek-utilities/includes/arrays.php @@ -2,8 +2,8 @@ /** * This file is part of the RocketGeek Utility Functions library. * - * This library is open source and Apache-2.0 licensed. I hope you find it useful - * for your project(s). Attribution is appreciated ;-) + * This library is open source and Apache-2.0 licensed. I hope you find it + * useful for your project(s). Attribution is appreciated ;-) * * @package RocketGeek_Utilities * @subpackage RocketGeek_Utilities_Arrays diff --git a/includes/libraries/rocketgeek-utilities/includes/dates.php b/includes/libraries/rocketgeek-utilities/includes/dates.php index 0a3de7c4..3b6c19ef 100644 --- a/includes/libraries/rocketgeek-utilities/includes/dates.php +++ b/includes/libraries/rocketgeek-utilities/includes/dates.php @@ -2,8 +2,8 @@ /** * This file is part of the RocketGeek Utility Functions library. * - * This library is open source and Apache-2.0 licensed. I hope you find it useful - * for your project(s). Attribution is appreciated ;-) + * This library is open source and Apache-2.0 licensed. I hope you find it + * useful for your project(s). Attribution is appreciated ;-) * * @package RocketGeek_Utilities * @subpackage RocketGeek_Utilities_Dates @@ -84,7 +84,8 @@ function rktgk_date_format_map() { 'EUROPEAN' => 'j F Y', 'AMERICAN' => 'F j, Y', 'MM/DD/YYYY' => 'm/d/Y', - 'DD/MM/YYYY' => 'd/m/Y', + 'DD-MM-YYYY' => 'd-m-Y', + 'MYSQL' => 'Y-m-d H:i:s', ); } endif; @@ -95,14 +96,16 @@ function rktgk_date_format_map() { * * If no format is matched, it returns the original format. * + * @see https://www.php.net/manual/en/datetime.format.php#refsect1-datetime.format-parameters + * * @since 1.0.0 * * @param string $format * @return string */ function rktgk_date_format( $format ) { - $format = strtoupper( $format ); $convert = rktgk_date_format_map(); - return ( ! isset( $convert[ $format ] ) ) ? $format : $convert[ $format ]; + $format_upper = strtoupper( $format ); + return ( isset( $convert[ $format_upper ] ) ) ? $convert[ $format ] : $format; } endif; \ No newline at end of file diff --git a/includes/libraries/rocketgeek-utilities/includes/debug.php b/includes/libraries/rocketgeek-utilities/includes/debug.php index 9c0172ac..a12033d4 100644 --- a/includes/libraries/rocketgeek-utilities/includes/debug.php +++ b/includes/libraries/rocketgeek-utilities/includes/debug.php @@ -2,8 +2,8 @@ /** * This file is part of the RocketGeek Utility Functions library. * - * This library is open source and Apache-2.0 licensed. I hope you find it useful - * for your project(s). Attribution is appreciated ;-) + * This library is open source and Apache-2.0 licensed. I hope you find it + * useful for your project(s). Attribution is appreciated ;-) * * @package RocketGeek_Utilities * @subpackage RocketGeek_Utilities_Debug diff --git a/includes/libraries/rocketgeek-utilities/includes/forms.php b/includes/libraries/rocketgeek-utilities/includes/forms.php index 06c90b04..40bb35e6 100644 --- a/includes/libraries/rocketgeek-utilities/includes/forms.php +++ b/includes/libraries/rocketgeek-utilities/includes/forms.php @@ -2,8 +2,8 @@ /** * This file is part of the RocketGeek Utility Functions library. * - * This library is open source and Apache-2.0 licensed. I hope you find it useful - * for your project(s). Attribution is appreciated ;-) + * This library is open source and Apache-2.0 licensed. I hope you find it + * useful for your project(s). Attribution is appreciated ;-) * * @package RocketGeek_Utilities * @subpackage RocketGeek_Utilities_Forms diff --git a/includes/libraries/rocketgeek-utilities/includes/strings.php b/includes/libraries/rocketgeek-utilities/includes/strings.php index bb07f0ad..0b8ae5b3 100644 --- a/includes/libraries/rocketgeek-utilities/includes/strings.php +++ b/includes/libraries/rocketgeek-utilities/includes/strings.php @@ -2,8 +2,8 @@ /** * This file is part of the RocketGeek Utility Functions library. * - * This library is open source and Apache-2.0 licensed. I hope you find it useful - * for your project(s). Attribution is appreciated ;-) + * This library is open source and Apache-2.0 licensed. I hope you find it + * useful for your project(s). Attribution is appreciated ;-) * * @package RocketGeek_Utilities * @subpackage RocketGeek_Utilities_Strings @@ -30,6 +30,43 @@ * limitations under the License. */ + +if ( ! function_exists( 'rktgk_string_to_boolean' ) ): +function rktgk_string_to_boolean( $str, $return_string = true ) { + return rktgk_str_to_bool( $str, $return_string ); +} +endif; + +if ( ! function_exists( 'rktgk_str_to_bool' ) ): +/** + * Converts a true/false string to a boolean. + * Useful for shortcodes that receive args as strings + * but need a true/false or 1/0 boolean. + */ +function rktgk_str_to_bool( $str, $return_string = true ) { + switch ( $str ) { + case ( is_bool( $str ) ): + // If the value is already cast as a boolean. + return (bool)$str; + break; + case ( is_string( $str ) && 'true' === $str ): + case ( 1 === $str ): + // If the value is "true" or 1 as a string or integer. + return true; + break; + case ( is_string( $str ) && 'false' === $str ): + case ( 0 === $str ): + // If the value is "false" or 0 as a string or integer. + return false; + break; + default: + // If it doesn't fit anything, return false. + return ( true === $return_string ) ? $str : false; + break; + } +} +endif; + if ( ! function_exists( 'rktgk_get_sub_str' ) ): /** * String manipulation utility. diff --git a/includes/libraries/rocketgeek-utilities/includes/utilities.php b/includes/libraries/rocketgeek-utilities/includes/utilities.php index 945131b6..667e60f7 100644 --- a/includes/libraries/rocketgeek-utilities/includes/utilities.php +++ b/includes/libraries/rocketgeek-utilities/includes/utilities.php @@ -2,8 +2,8 @@ /** * This file is part of the RocketGeek Utility Functions library. * - * This library is open source and Apache-2.0 licensed. I hope you find it useful - * for your project(s). Attribution is appreciated ;-) + * This library is open source and Apache-2.0 licensed. I hope you find it + * useful for your project(s). Attribution is appreciated ;-) * * @package RocketGeek_Utilities * @subpackage RocketGeek_Utilities_Utilities @@ -103,42 +103,6 @@ function rktgk_maybe_wpautop( $content, $do_autop = true ) { } endif; -if ( ! function_exists( 'rktgk_string_to_boolean' ) ): -function rktgk_string_to_boolean( $str ) { - return rktgk_str_to_bool( $str ); -} -endif; - -if ( ! function_exists( 'rktgk_str_to_bool' ) ): -/** - * Converts a true/false string to a boolean. - * Useful for shortcodes that receive args as strings - * but need a true/false or 1/0 boolean. - */ -function rktgk_str_to_bool( $str ) { - switch ( $str ) { - case ( is_bool( $str ) ): - // If the value is already cast as a boolean. - return $str; - break; - case ( "true" == $str ): - case ( 1 == $str ): - // If the value is "true" or 1 as a string or integer. - return true; - break; - case ( "false" == $str ): - case ( 0 == $str ): - // If the value is "false" or 0 as a string or integer. - return false; - break; - default: - // If it doesn't fit anything, return false. - return false; - break; - } -} -endif; - if ( ! function_exists( 'rktgk_do_shortcode' ) ): /** * Call a shortcode function by tag name. diff --git a/includes/libraries/rocketgeek-utilities/loader.php b/includes/libraries/rocketgeek-utilities/loader.php index 72f4be25..3efe6355 100644 --- a/includes/libraries/rocketgeek-utilities/loader.php +++ b/includes/libraries/rocketgeek-utilities/loader.php @@ -5,8 +5,8 @@ * plugins, but useage is not limited to those plugins. They are useful in any * WordPress application. * - * This library is open source and Apache-2.0 licensed. I hope you find it useful - * for your project(s). Attribution is appreciated ;-) + * This library is open source and Apache-2.0 licensed. I hope you find it + * useful for your project(s). Attribution is appreciated ;-) * * @package RocketGeek_Utilities * @version 1.0.0 diff --git a/wp-members.php b/wp-members.php index dc3aa723..92306633 100644 --- a/wp-members.php +++ b/wp-members.php @@ -50,12 +50,6 @@ trademark, or if you do not understand the difference between open source and public domain, contact the original author at: https://rocketgeek.com/contact/. - - - INSTALLATION PROCEDURE: - - For complete installation and usage instructions, - visit https://rocketgeek.com */ // Exit if accessed directly. From bc9ea557862b9980f083ba0235a559aa6f068b40 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 13 Dec 2021 10:38:19 -0500 Subject: [PATCH 1532/1694] additional backward compatibility for dialogs (if legacy key is requested) --- includes/class-wp-members-dialogs.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/includes/class-wp-members-dialogs.php b/includes/class-wp-members-dialogs.php index e8836ba5..49ed9413 100644 --- a/includes/class-wp-members-dialogs.php +++ b/includes/class-wp-members-dialogs.php @@ -204,7 +204,9 @@ function get_text( $str ) { */ $text = apply_filters( 'wpmem_default_text', $text ); - // Manage legacy keys (i.e. sb_ to widget_ ). + // Manage legacy keys (i.e. sb_ to widget_ ). + // @todo Legacy keys to be obsolete by 3.5.0 + $str = ( false !== strpos( $str, 'sb_' ) ) ? str_replace( 'sb_', 'widget_', $str ) : $str; foreach ( $text as $key => $value ) { if ( false !== strpos( $key, 'sb_' ) ) { $new_key = str_replace( 'sb_', 'widget_', $key ); From 33018aa6a4b99506c77408b9ab59ff41ced21c6e Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 13 Dec 2021 10:39:08 -0500 Subject: [PATCH 1533/1694] code consolidation --- includes/admin/class-wp-members-admin-users.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/includes/admin/class-wp-members-admin-users.php b/includes/admin/class-wp-members-admin-users.php index c7ebed66..7de718ba 100644 --- a/includes/admin/class-wp-members-admin-users.php +++ b/includes/admin/class-wp-members-admin-users.php @@ -56,8 +56,7 @@ static function insert_hover_links( $actions, $user_object ) { if ( $user_object->ID != get_current_user_id() ) { if ( 1 == $wpmem->act_link ) { - $is_user_confirmed = wpmem_is_user_confirmed( $user_object->ID ); - if ( false === $is_user_confirmed ) { + if ( false === wpmem_is_user_confirmed( $user_object->ID ) ) { $action = 'confirm'; $term = __( 'Confirm', 'wp-members' ); } else { From efafd06d70c1b883cb2c3d68ee4ca9e43602c49c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 14 Dec 2021 09:32:10 -0500 Subject: [PATCH 1534/1694] fix bug in hidden posts upgrade routine --- includes/install.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/includes/install.php b/includes/install.php index f7393086..bb53af82 100644 --- a/includes/install.php +++ b/includes/install.php @@ -761,6 +761,9 @@ function wpmem_upgrade_woo_reg() { } function wpmem_upgrade_hidden_transient() { + if ( ! class_exists( 'WP_Members' ) ) { + require_once( 'class-wp-members.php' ); + } $temp_obj = new WP_Members; $temp_obj->update_hidden_posts(); delete_transient( '_wpmem_hidden_posts' ); From b60764633c05a51ae3aed7fd72eda737fb57619b Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 14 Dec 2021 09:38:34 -0500 Subject: [PATCH 1535/1694] complete integration of registration_errors filter --- includes/api/api-users.php | 2 +- includes/class-wp-members-user.php | 13 ++++++++++++- readme.txt | 2 ++ 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index c553065d..6768ad0a 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -545,7 +545,7 @@ function wpmem_set_user_status( $user_id, $status ) { * @global string $wpmem_themsg * @global array $userdata * - * @param string $tag Identifies 'register' or 'update'. + * @param string $tag Identifies 'register' or 'update'. * @return string $wpmem_themsg|success|editsuccess */ function wpmem_user_register( $tag ) { diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index ccb4c34f..56a48eb8 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -55,7 +55,7 @@ function __construct( $settings ) { add_action( 'wpmem_register_redirect', array( $this, 'register_redirect' ), 20 ); // Adds a nonce to the redirect if there is a "redirect_to" attribute in the reg form. - add_filter( 'registration_errors', array( $this, 'wp_register_validate' ), 10, 3 ); // native registration validation + add_filter( 'registration_errors', array( $this, 'wp_register_validate' ), 10, 3 ); // native registration validation // Load anything the user as access to. if ( 1 == $settings->enable_products ) { @@ -282,6 +282,17 @@ function register_validate( $tag ) { */ $this->post_data = apply_filters( 'wpmem_pre_validate_form', $this->post_data, $tag ); + // Adds integration for custom error codes triggered by "register_post" or contained in "registration_errors" + // @todo This will move towards integrating all WP-Members registration errors into the "registration_errors" filter + // and allow for more standardized custom validation. + $errors = new WP_Error(); + do_action( 'register_post', $sanitized_user_login, $user_email, $errors ); + $errors = apply_filters( 'registration_errors', $errors, $this->post_data['username'], $this->post_data['user_email'] ); + if ( count( $errors->get_error_messages() ) > 0 ) { + $wpmem_themsg = $errors->get_error_message(); + return; + } + if ( 'update' == $tag ) { $pass_arr = array( 'username', 'password', 'confirm_password', 'password_confirm' ); foreach ( $pass_arr as $pass ) { diff --git a/readme.txt b/readme.txt index eccddf64..4c9120f1 100644 --- a/readme.txt +++ b/readme.txt @@ -166,6 +166,8 @@ New Feature Settings: * Clone menus is deprecated. The setting remains in place for users who have it enabled. But if it is not enabled, the setting is no longer available. * Expands Customizer functionality so logged out forms show on blocked content (not just shortcodes). + +* Adds integration for WP's "registration_errors" filter hook, allowing for standarized custom validation and integration with other plugins. New API functions: * wpmem_is_reg_form_showing() From fc322a3203d6988e058f185e8cc06b0675811366 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 14 Dec 2021 15:45:41 -0500 Subject: [PATCH 1536/1694] one last (hopefully) change, moving confirmation link to general settings, adding doc links --- .../tabs/class-wp-members-admin-tab-options.php | 12 +++++++++--- readme.txt | 4 +++- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index c7e30a45..8e536438 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -175,10 +175,11 @@ static function build_settings() { }?>

    '; + $reset_link_end = ''; $rows = array( - array(__('Confirmation Link', 'wp-members'),'wpmem_settings_act_link',__('Send email confirmation link on new registration. (Requires additional configuration)','wp-members'),'act_link'), //array(__('Password Reset Link', 'wp-members'),'wpmem_settings_pwd_link',__('Send password reset link instead of new password. (Requires additional configuration)','wp-members'),'pwd_link'), - array(__('Legacy Password Reset', 'wp-members'),'wpmem_settings_pwd_link',__('Use legacy password reset. (Requires additional configuration)','wp-members'),'pwd_link'), + array(__('Legacy Password Reset', 'wp-members'),'wpmem_settings_pwd_link',sprintf(__('Use legacy password reset. %s(Requires additional configuration)%s','wp-members'),$reset_link_start,$reset_link_end),'pwd_link'), //array(__('Enable WP Login Error', 'wp-members' ),'wpmem_settings_login_error',__('Use WP login error object instead of WP-Members default login error','wp-members'),'login_error'), array(__('Legacy Login Error', 'wp-members' ),'wpmem_settings_login_error',__('Use legacy WP-Members login error instead of WP error object.','wp-members'),'login_error'), ); @@ -205,11 +206,16 @@ static function build_settings() { dropin_dir ); + $mem_link_start = ''; + $mem_link_end = ''; + $conf_link_start = ''; + $conf_link_end = ''; $rows = array( - array(__('Enable Products', 'wp-members'),'wpmem_settings_products',__('Enables creation of different membership products','wp-members'),'enable_products'), + array(__('Enable Products', 'wp-members'),'wpmem_settings_products',sprintf(__('Enables creation of different %s membership products %s','wp-members'),$mem_link_start,$mem_link_end),'enable_products'), array(__('Clone menus','wp-members'),'wpmem_settings_menus',__('Enables logged in menus','wp-members'),'clone_menus'), array(__('Notify admin','wp-members'),'wpmem_settings_notify',sprintf(__('Notify %s for each new registration? %s','wp-members'),$admin_email,$chg_email),'notify'), array(__('Moderate registration','wp-members'),'wpmem_settings_moderate',__('Holds new registrations for admin approval','wp-members'),'mod_reg'), + array(__('Confirmation Link', 'wp-members'),'wpmem_settings_act_link',sprintf(__('Send email confirmation link on new registration. %s(Requires additional configuration)%s','wp-members'),$conf_link_start,$conf_link_end),'act_link'), array(__('Ignore warning messages','wp-members'),'wpmem_settings_ignore_warnings',__('Ignores WP-Members warning messages in the admin panel','wp-members'),'warnings'), //array(__('Enable dropins', 'wp-members'),'wpmem_settings_enable_dropins',sprintf(__('Enables dropins in %s', 'wp-members'), $dropin_dir),'dropins'), ); diff --git a/readme.txt b/readme.txt index 4c9120f1..b36dc852 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 5.8 -Stable tag: 3.3.9.3 +Stable tag: 3.4.0 License: GPLv3 @@ -136,6 +136,8 @@ WP-Members 3.4.0 is a major update. Backup prior to upgrading is recommended. Se = 3.4.0 = +Here is a list of changes in 3.4.0, but for a more detailed look at the impact of some of these items, be sure to review https://rocketgeek.com/release-announcements/wp-members-3-4-0-wow/ + * Rebuilds the login widget functions so there are filter hooks that more closely mimic the main body login filters. Every attempt was made to provide an HTML result that is the same as previous versions, as well as providing support for legacy dialog tags. * Rebuilt and revised user export functionality. Now includes an api function that can be used to customize user exports for a variety of uses. From 9c6c62c58c2a9e9f88362496986afb00db133d94 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 14 Dec 2021 18:34:27 -0500 Subject: [PATCH 1537/1694] adjustment to array keys based on settings move --- includes/admin/tabs/class-wp-members-admin-tab-options.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index 8e536438..63512c24 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -191,8 +191,8 @@ static function build_settings() { foreach ( $rows as $key => $row ) { ?>
  • - woo[ $row[3] ] : $wpmem->{$row[3]}; ?> - woo[ $row[3] ] : $wpmem->{$row[3]}; ?> +       From 5a1e65bd4274e84fd20a90db4a9d9214125cf84c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 24 Dec 2021 12:15:36 -0500 Subject: [PATCH 1538/1694] bug fix (3.4.0.1) to avoid captcha validation being run twice --- includes/class-wp-members-user.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 56a48eb8..00abf197 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -251,6 +251,9 @@ function register_validate( $tag ) { case 'textarea': $this->post_data[ $meta_key ] = sanitize_textarea_field( $_POST[ $meta_key ] ); break; + case 'email': + $this->post_data[ $meta_key ] = sanitize_email( $_POST[ $meta_key ] ); + break; default: $this->post_data[ $meta_key ] = sanitize_text_field( $_POST[ $meta_key ] ); break; @@ -261,7 +264,7 @@ function register_validate( $tag ) { } else { // We do have password as part of the registration form. if ( isset( $_POST['password'] ) ) { - $this->post_data['password'] = $_POST['password']; + $this->post_data['password'] = $_POST['password']; // wp_insert_user() hashes this, so sanitizing is unnessary (and undesirable). } if ( isset( $_POST['confirm_password'] ) ) { $this->post_data['confirm_password'] = $_POST['confirm_password']; @@ -285,13 +288,13 @@ function register_validate( $tag ) { // Adds integration for custom error codes triggered by "register_post" or contained in "registration_errors" // @todo This will move towards integrating all WP-Members registration errors into the "registration_errors" filter // and allow for more standardized custom validation. - $errors = new WP_Error(); + /* $errors = new WP_Error(); do_action( 'register_post', $sanitized_user_login, $user_email, $errors ); $errors = apply_filters( 'registration_errors', $errors, $this->post_data['username'], $this->post_data['user_email'] ); if ( count( $errors->get_error_messages() ) > 0 ) { $wpmem_themsg = $errors->get_error_message(); return; - } + } */ if ( 'update' == $tag ) { $pass_arr = array( 'username', 'password', 'confirm_password', 'password_confirm' ); From d182f10387ae1933493137be66d87dee69003386 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Fri, 24 Dec 2021 12:17:03 -0500 Subject: [PATCH 1539/1694] bug fix (3.4.0.2) to fix error in user export --- .../admin/class-wp-members-user-export.php | 27 ++++++++++++------- includes/api/api.php | 13 +++++++++ 2 files changed, 30 insertions(+), 10 deletions(-) diff --git a/includes/admin/class-wp-members-user-export.php b/includes/admin/class-wp-members-user-export.php index e45cb318..21c9cad3 100644 --- a/includes/admin/class-wp-members-user-export.php +++ b/includes/admin/class-wp-members-user-export.php @@ -14,6 +14,14 @@ class WP_Members_User_Export { + /** + * Used instead of getting global. + * + * @since 3.4.1 + * @todo May change how this is used. (Currently just replaces minor use of $wpmem global object for this one thing.) + */ + public static $membership_product_stem = "_wpmem_products_"; + /** * New export function to export all or selected users * @@ -51,9 +59,7 @@ class WP_Members_User_Export { * @param array $users Array of user IDs to export. * @param string $tag */ - static function export_users( $args = array(), $users = array(), $tag = 'default' ) { - - global $wpmem; + public static function export_users( $args = array(), $users = array(), $tag = 'default' ) { $export_fields = ( ! isset( $args['fields'] ) ) ? self::get_export_fields() : $args['fields']; @@ -208,8 +214,8 @@ static function export_users( $args = array(), $users = array(), $tag = 'default $role = wpmem_get_user_role( $user, true ); // As of 3.4, wpmem_get_user_role() can get all roles. $row['role'] = ( is_array( $role ) ) ? implode( ",", $role ) : $role; break; - case ( $wpmem->membership->post_stem === substr( $meta, 0, strlen( $wpmem->membership->post_stem ) ) ): - $product = str_replace( $wpmem->membership->post_stem, '', $meta ); + case ( self::$membership_product_stem === substr( $meta, 0, strlen( self::$membership_product_stem ) ) ): + $product = str_replace( self::$membership_product_stem, '', $meta ); $row[ $meta ] = wpmem_get_user_meta( $user, $meta ); // If value is a date and false is not the format_date option... if ( false !== $args['date_format'] && '' != $row[ $meta ] && $row[ $meta ] > 2 ) { @@ -276,19 +282,20 @@ private static function get_export_fields() { } } $export_fields['username'] = __( 'Username', 'wp-members' ); - if ( 1 == $wpmem->mod_reg ) { + if ( wpmem_is_enabled( 'mod_reg' ) ) { $export_fields['active'] = __( 'Activated?', 'wp-members' ); } - if ( defined( 'WPMEM_EXP_MODULE' ) && 1 == $wpmem->use_exp ) { + if ( defined( 'WPMEM_EXP_MODULE' ) && wpmem_is_enabled( 'use_exp' ) ) { $export_fields['exp_type'] = __( 'Subscription', 'wp-members' ); $export_fields['expires'] = __( 'Expires', 'wp-members' ); } $export_fields['user_registered'] = __( 'Registered', 'wp-members' ); $export_fields['wpmem_reg_ip'] = __( 'IP', 'wp-members' ); $export_fields['role'] = __( 'Role', 'wp-members' ); - if ( 1 == $wpmem->enable_products ) { - foreach( $wpmem->membership->products as $product_key => $product ) { - $export_fields[ $wpmem->membership->post_stem . $product_key ] = $wpmem->membership->products[ $product_key ]['title']; + if ( wpmem_is_enabled( 'enable_products' ) ) { + $membership_products = wpmem_get_memberships(); + foreach( $membership_products as $product_key => $product ) { + $export_fields[ self::$membership_product_stem . $product_key ] = $membership_products[ $product_key ]['title']; } } diff --git a/includes/api/api.php b/includes/api/api.php index cf45b22c..8b5dec4d 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -488,4 +488,17 @@ function wpmem_restricted_message() { return $wpmem->forms->add_restricted_msg(); } +/** + * Checks if requested setting is enabled. + * + * @since 3.4.1 + * + * @param string $option + * @return boolean + */ +function wpmem_is_enabled( $option ) { + global $wpmem; + return ( 1 == $wpmem->{$option} ) ? true : false; +} + // End of file. \ No newline at end of file From 8ac45fa91a9c15e78d2420079519b8b10cf77155 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 09:07:54 -0500 Subject: [PATCH 1540/1694] fix bug in wpmem_get_ip() --- includes/api/api-users.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 6768ad0a..f3375825 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -781,7 +781,7 @@ function wpmem_get_user_ip() { * * @param string $ip */ - return apply_filters( 'wpmem_get_ip', rktgk_get_user_ip( $ip ) ); + return apply_filters( 'wpmem_get_ip', rktgk_get_user_ip() ); } /** From 4dbd202b13d5409b79f31601a23df6fb84fb2f07 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 09:08:20 -0500 Subject: [PATCH 1541/1694] api functions to get plugin version and url --- includes/api/api.php | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/includes/api/api.php b/includes/api/api.php index 8b5dec4d..d9aec24c 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -501,4 +501,29 @@ function wpmem_is_enabled( $option ) { return ( 1 == $wpmem->{$option} ) ? true : false; } +/** + * Gets plugin url. + * + * @since 3.4.1 + * + * @global stdClass $wpmem + * @return string $wpmem->url + */ +function wpmem_get_plugin_url() { + global $wpmem; + return $wpmem->url; +} + +/** + * Gets plugin version. + * + * @since 3.4.1 + * + * @global stdClass $wpmem + * @return string $wpmem->version + */ +function wpmem_get_plugin_version() { + global $wpmem; + return $wpmem->version; +} // End of file. \ No newline at end of file From fa0a16ef6ff98779e68e22d26440aa95fd352117 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 09:09:52 -0500 Subject: [PATCH 1542/1694] cleanup --- includes/class-wp-members.php | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index e115b27d..81cb43ab 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -458,18 +458,20 @@ function load_hooks() { // Add actions. - add_action( 'init', array( $this, 'load_textdomain' ) ); //add_action( 'plugins_loaded', 'wpmem_load_textdomain' ); + add_action( 'init', array( $this, 'load_textdomain' ) ); add_action( 'init', array( $this->membership, 'add_cpt' ), 0 ); // Adds membership plans custom post type. - add_action( 'widgets_init', array( $this, 'widget_init' ) ); // initializes the widget - add_action( 'admin_init', array( $this, 'load_admin' ) ); // check user role to load correct dashboard + add_action( 'widgets_init', array( $this, 'widget_init' ) ); // initializes the widget + add_action( 'admin_init', array( $this, 'load_admin' ) ); // check user role to load correct dashboard add_action( 'rest_api_init', array( $this, 'rest_init' ) ); add_action( 'template_redirect', array( $this, 'get_action' ) ); + add_action( 'login_enqueue_scripts', array( $this, 'enqueue_style_wp_login' ) ); // styles the native registration - add_action( 'wp_enqueue_scripts', array( $this, 'enqueue_style' ) ); // Enqueues the stylesheet. + add_action( 'wp_enqueue_scripts', array( $this, 'enqueue_style' ) ); // Enqueues the stylesheet. add_action( 'wp_enqueue_scripts', array( $this, 'loginout_script' ) ); + add_action( 'pre_get_posts', array( $this, 'do_hide_posts' ), 20 ); add_action( 'customize_register', array( $this, 'customizer_settings' ) ); - add_action( 'admin_menu', 'wpmem_admin_options' ); // adds admin menu + add_action( 'admin_menu', 'wpmem_admin_options' ); // Adds admin menu add_action( 'wp_footer', array( $this, 'invisible_captcha' ) ); if ( is_user_logged_in() ) { @@ -477,7 +479,7 @@ function load_hooks() { add_action( 'wpmem_pwd_change', array( $this->user, 'set_as_logged_in' ), 10 ); } - add_action( 'register_form', 'wpmem_wp_register_form' ); // adds fields to the default wp registration + add_action( 'register_form', 'wpmem_wp_register_form' ); // Adds fields to the default wp registration if ( wpmem_is_woo_active() ) { @@ -526,7 +528,7 @@ function load_hooks() { // @todo I think we can do this without the filter now that // the main messaging function has been updated. // add_filter( 'wpmem_login_failed_args', array( $this->dialogs, 'login_error' ) ); - add_filter( 'lostpassword_url', array( $this, 'lost_pwd_url' ), 10, 2 ); + add_filter( 'lostpassword_url', array( $this, 'lost_pwd_url' ), 10, 2 ); } if ( function_exists( 'wpmem_custom_translation_strings' ) ) { From 44377171ca2f5bb7cec38ded4991a39c7dc80c7f Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 09:10:26 -0500 Subject: [PATCH 1543/1694] check load_textdomain() explicitly --- includes/class-wp-members.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 81cb43ab..831c1f9a 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -1699,7 +1699,7 @@ function load_textdomain() { $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . 'plugins/' . $domain . '-' . $locale . '.mo', $locale ); $loaded = load_textdomain( $domain, $file ); - if ( $loaded ) { + if ( true === $loaded ) { return $loaded; } else { /** From 08f58b65cc45533a1980291dde3fd64c72d39a97 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 09:11:55 -0500 Subject: [PATCH 1544/1694] change "libraries" to "vendor", move external assets to vendor --- includes/admin/class-wp-members-admin-api.php | 29 +++++++++---------- includes/class-wp-members.php | 2 +- .../vendor/jquery-ui}/css/jquery-ui.css | 0 .../vendor/jquery-ui}/css/jquery-ui.min.css | 0 .../rocketgeek-utilities/LICENSE | 0 .../rocketgeek-utilities/README.md | 0 .../rocketgeek-utilities/includes/arrays.php | 0 .../rocketgeek-utilities/includes/dates.php | 0 .../rocketgeek-utilities/includes/debug.php | 0 .../rocketgeek-utilities/includes/forms.php | 0 .../rocketgeek-utilities/includes/strings.php | 0 .../includes/utilities.php | 0 .../rocketgeek-utilities/loader.php | 0 .../vendor/select2}/css/select2.css | 0 .../vendor/select2}/css/select2.min.css | 0 .../vendor/select2}/js/select2.js | 0 .../vendor/select2}/js/select2.min.js | 0 17 files changed, 15 insertions(+), 16 deletions(-) rename {assets => includes/vendor/jquery-ui}/css/jquery-ui.css (100%) rename {assets => includes/vendor/jquery-ui}/css/jquery-ui.min.css (100%) rename includes/{libraries => vendor}/rocketgeek-utilities/LICENSE (100%) rename includes/{libraries => vendor}/rocketgeek-utilities/README.md (100%) rename includes/{libraries => vendor}/rocketgeek-utilities/includes/arrays.php (100%) rename includes/{libraries => vendor}/rocketgeek-utilities/includes/dates.php (100%) rename includes/{libraries => vendor}/rocketgeek-utilities/includes/debug.php (100%) rename includes/{libraries => vendor}/rocketgeek-utilities/includes/forms.php (100%) rename includes/{libraries => vendor}/rocketgeek-utilities/includes/strings.php (100%) rename includes/{libraries => vendor}/rocketgeek-utilities/includes/utilities.php (100%) rename includes/{libraries => vendor}/rocketgeek-utilities/loader.php (100%) rename {assets => includes/vendor/select2}/css/select2.css (100%) rename {assets => includes/vendor/select2}/css/select2.min.css (100%) rename {assets => includes/vendor/select2}/js/select2.js (100%) rename {assets => includes/vendor/select2}/js/select2.min.js (100%) diff --git a/includes/admin/class-wp-members-admin-api.php b/includes/admin/class-wp-members-admin-api.php index 91c4f005..4fd74417 100644 --- a/includes/admin/class-wp-members-admin-api.php +++ b/includes/admin/class-wp-members-admin-api.php @@ -527,30 +527,29 @@ function form_post_url( $args = false ) { * @since 3.3.0 Everything loads from /assets/ folder. * * @global object $current_screen - * @global object $wpmem * @param string $hook The admin screen hook being loaded. */ function dashboard_enqueue_scripts( $hook ) { - global $current_screen, $wpmem; - if ( 'edit.php' == $hook - || 'settings_page_wpmem-settings' == $hook - || 'post.php' == $hook - || 'post-new.php' == $hook + global $current_screen; + if ( 'edit.php' == $hook + || 'post.php' == $hook + || 'post-new.php' == $hook || 'user-edit.php' == $hook - || 'profile.php' == $hook - || 'users.php' ) { - wp_enqueue_style( 'wpmem-admin', $wpmem->url . 'assets/css/admin' . wpmem_get_suffix() . '.css', '', $wpmem->version ); + || 'profile.php' == $hook + || 'users.php' == $hook + || 'settings_page_wpmem-settings' == $hook ) { + wp_enqueue_style( 'wpmem-admin', wpmem_get_plugin_url() . 'assets/css/admin' . wpmem_get_suffix() . '.css', '', wpmem_get_plugin_version() ); } if ( 'settings_page_wpmem-settings' == $hook || 'post.php' == $hook || 'post-new.php' == $hook ) { wp_enqueue_script( 'jquery-ui-dialog' ); // enqueue jQuery UI Dialog dependency - wp_register_script( 'wpmem-admin', $wpmem->url . 'assets/js/admin' . wpmem_get_suffix() . '.js', 'jquery', $wpmem->version, true ); + wp_register_script( 'wpmem-admin', wpmem_get_plugin_url() . 'assets/js/admin' . wpmem_get_suffix() . '.js', 'jquery', wpmem_get_plugin_version(), true ); $translation_array = array( 'close_btn' => __( 'Close', 'wp-members' ), ); wp_localize_script( 'wpmem-admin', 'wpmem_get_settings_vars', $translation_array ); wp_enqueue_script( 'wpmem-admin' ); } - if ( ( ( 'post.php' == $hook || 'post-new.php' == $hook ) && 1 == $wpmem->enable_products ) + if ( ( ( 'post.php' == $hook || 'post-new.php' == $hook ) && wpmem_is_enabled( 'enable_products' ) ) || ( 'wpmem_product' == get_post_type() ) || ( 'user-edit' == $current_screen->id || 'profile' == $current_screen->id ) || ( 'settings_page_wpmem-settings' == $hook ) ) { @@ -558,14 +557,14 @@ function dashboard_enqueue_scripts( $hook ) { wp_enqueue_script( 'jquery-ui-core' ); // enqueue jQuery UI Core wp_enqueue_script( 'jquery-ui-datepicker' ); // enqueue jQuery UI Datepicker if ( ! wp_style_is( 'jquery-ui-style', 'enqueued' ) ) { - wp_register_style( 'jquery-ui-style', $wpmem->url . 'assets/css/jquery-ui' . wpmem_get_suffix() . '.css' ); + wp_register_style( 'jquery-ui-style', wpmem_get_plugin_url() . 'includes/vendor/jquery-ui/css/jquery-ui' . wpmem_get_suffix() . '.css' ); } wp_enqueue_style( 'jquery-ui-style' ); } - if ( ( 'post.php' == $hook || 'post-new.php' == $hook ) && 1 == $wpmem->enable_products ) { + if ( ( 'post.php' == $hook || 'post-new.php' == $hook ) && wpmem_is_enabled( 'enable_products' ) ) { if ( ! wp_script_is( 'select2', 'enqueued' ) ) { - wp_register_style( 'select2-style', $wpmem->url . 'assets/css/select2' . wpmem_get_suffix() . '.css', false, '4.0.5', 'all' ); - wp_register_script( 'select2', $wpmem->url . 'assets/js/select2' . wpmem_get_suffix() . '.js', array( 'jquery' ), '4.0.5', true ); + wp_register_style( 'select2-style', wpmem_get_plugin_url() . 'includes/vendor/select2/css/select2' . wpmem_get_suffix() . '.css', false, '4.0.5', 'all' ); + wp_register_script( 'select2', wpmem_get_plugin_url() . 'includes/vendor/select2/js/select2' . wpmem_get_suffix() . '.js', array( 'jquery' ), '4.0.5', true ); wp_enqueue_style( 'select2-style' ); wp_enqueue_script( 'select2' ); } diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 831c1f9a..0191ddbc 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -625,7 +625,7 @@ function load_dependencies() { include( $wpmem_pluggable ); } - require_once( $this->path . 'includes/libraries/rocketgeek-utilities/loader.php' ); + require_once( $this->path . 'includes/vendor/rocketgeek-utilities/loader.php' ); require_once( $this->path . 'includes/class-wp-members-api.php' ); require_once( $this->path . 'includes/class-wp-members-clone-menus.php' ); require_once( $this->path . 'includes/class-wp-members-captcha.php' ); diff --git a/assets/css/jquery-ui.css b/includes/vendor/jquery-ui/css/jquery-ui.css similarity index 100% rename from assets/css/jquery-ui.css rename to includes/vendor/jquery-ui/css/jquery-ui.css diff --git a/assets/css/jquery-ui.min.css b/includes/vendor/jquery-ui/css/jquery-ui.min.css similarity index 100% rename from assets/css/jquery-ui.min.css rename to includes/vendor/jquery-ui/css/jquery-ui.min.css diff --git a/includes/libraries/rocketgeek-utilities/LICENSE b/includes/vendor/rocketgeek-utilities/LICENSE similarity index 100% rename from includes/libraries/rocketgeek-utilities/LICENSE rename to includes/vendor/rocketgeek-utilities/LICENSE diff --git a/includes/libraries/rocketgeek-utilities/README.md b/includes/vendor/rocketgeek-utilities/README.md similarity index 100% rename from includes/libraries/rocketgeek-utilities/README.md rename to includes/vendor/rocketgeek-utilities/README.md diff --git a/includes/libraries/rocketgeek-utilities/includes/arrays.php b/includes/vendor/rocketgeek-utilities/includes/arrays.php similarity index 100% rename from includes/libraries/rocketgeek-utilities/includes/arrays.php rename to includes/vendor/rocketgeek-utilities/includes/arrays.php diff --git a/includes/libraries/rocketgeek-utilities/includes/dates.php b/includes/vendor/rocketgeek-utilities/includes/dates.php similarity index 100% rename from includes/libraries/rocketgeek-utilities/includes/dates.php rename to includes/vendor/rocketgeek-utilities/includes/dates.php diff --git a/includes/libraries/rocketgeek-utilities/includes/debug.php b/includes/vendor/rocketgeek-utilities/includes/debug.php similarity index 100% rename from includes/libraries/rocketgeek-utilities/includes/debug.php rename to includes/vendor/rocketgeek-utilities/includes/debug.php diff --git a/includes/libraries/rocketgeek-utilities/includes/forms.php b/includes/vendor/rocketgeek-utilities/includes/forms.php similarity index 100% rename from includes/libraries/rocketgeek-utilities/includes/forms.php rename to includes/vendor/rocketgeek-utilities/includes/forms.php diff --git a/includes/libraries/rocketgeek-utilities/includes/strings.php b/includes/vendor/rocketgeek-utilities/includes/strings.php similarity index 100% rename from includes/libraries/rocketgeek-utilities/includes/strings.php rename to includes/vendor/rocketgeek-utilities/includes/strings.php diff --git a/includes/libraries/rocketgeek-utilities/includes/utilities.php b/includes/vendor/rocketgeek-utilities/includes/utilities.php similarity index 100% rename from includes/libraries/rocketgeek-utilities/includes/utilities.php rename to includes/vendor/rocketgeek-utilities/includes/utilities.php diff --git a/includes/libraries/rocketgeek-utilities/loader.php b/includes/vendor/rocketgeek-utilities/loader.php similarity index 100% rename from includes/libraries/rocketgeek-utilities/loader.php rename to includes/vendor/rocketgeek-utilities/loader.php diff --git a/assets/css/select2.css b/includes/vendor/select2/css/select2.css similarity index 100% rename from assets/css/select2.css rename to includes/vendor/select2/css/select2.css diff --git a/assets/css/select2.min.css b/includes/vendor/select2/css/select2.min.css similarity index 100% rename from assets/css/select2.min.css rename to includes/vendor/select2/css/select2.min.css diff --git a/assets/js/select2.js b/includes/vendor/select2/js/select2.js similarity index 100% rename from assets/js/select2.js rename to includes/vendor/select2/js/select2.js diff --git a/assets/js/select2.min.js b/includes/vendor/select2/js/select2.min.js similarity index 100% rename from assets/js/select2.min.js rename to includes/vendor/select2/js/select2.min.js From c232b38c4ffd52212a8c4720a01cfcdae7600194 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 09:12:11 -0500 Subject: [PATCH 1545/1694] new tab color --- assets/css/admin.css | 4 ++-- assets/css/admin.min.css | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/assets/css/admin.css b/assets/css/admin.css index e488c27a..49512705 100644 --- a/assets/css/admin.css +++ b/assets/css/admin.css @@ -52,7 +52,7 @@ .req { color: #f00; } - +/** This needs to change where it loads - it should only load on the fields table for drag/drop */ #the-list { cursor: move; } @@ -111,7 +111,7 @@ } #wpmem_user_profile_tabs .ui-state-active { border: 1px solid #006799; - background: #008ec2; + background: #135e96; } #wpmem_user_profile_tabs .ui-state-active a { color: #fff; diff --git a/assets/css/admin.min.css b/assets/css/admin.min.css index 6fa9bc34..7bfabcca 100644 --- a/assets/css/admin.min.css +++ b/assets/css/admin.min.css @@ -1 +1 @@ -.wpmem_tbl_drag{background:#fffbcc;font-weight:700;border:1px solid #900}.column-wpmem_block{width:80px}#addfieldform li,#editfieldform li,#updatesettings li{padding:5px 0}#addfieldform label,#editfieldform label,#updatesettings label{float:left;width:166px;clear:both;display:block}#addfieldform .add-field-indent,#editfieldform .add-field-indent{margin-left:165px}#add_field_postbox,#fields_postbox{min-width:950px}.req{color:red}#the-list{cursor:move}#edit,#sort{width:30px}#wpmem_block input{vertical-align:-webkit-baseline-middle;margin:0 0 8px 0}#wpmem_block label{margin:0 0 0 8px}#wpmem_ok_block_status{margin:5px 0 0 0}#wpmem_post_block_status{font-weight:600}#wpmem_post_icon_0{color:red}#wpmem_post_icon_1{color:green}#wpmem_post_icon_2{color:#000}#wpmem_product_enabled{color:green}#_wpmem_products,#s2id__wpmem_products,.select2-search-field{width:100%}#wpmem_user_profile_tabs{padding:0;background:0 0;border-width:0}#wpmem_user_profile_tabs .ui-tabs-nav{padding-left:0;background:0 0;border-width:0 0 1px 0;-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}#wpmem_user_profile_tabs .ui-tabs-panel{background:#fff;border-width:0 1px 1px 1px}#wpmem_user_profile_tabs .ui-state-active{border:1px solid #006799;background:#008ec2}#wpmem_user_profile_tabs .ui-state-active a{color:#fff}#wpmem_product_fixed_period,#wpmem_product_fixed_period_select input,#wpmem_product_fixed_period_select label,#wpmem_product_no_gap{margin-top:10px;margin-left:24px}#updatesettings a{text-decoration:none}updatesettings a:hover{color:#000}#createuser .form-field input[type="checkbox"]{width: initial;}.wpmem-user-table-membership {border-bottom:1px solid #999;} \ No newline at end of file +.wpmem_tbl_drag{background:#fffbcc;font-weight:700;border:1px solid #900}.column-wpmem_block{width:80px}#addfieldform li,#editfieldform li,#updatesettings li{padding:5px 0}#addfieldform label,#editfieldform label,#updatesettings label{float:left;width:166px;clear:both;display:block}#addfieldform .add-field-indent,#editfieldform .add-field-indent{margin-left:165px}#add_field_postbox,#fields_postbox{min-width:950px}.req{color:red}#the-list{cursor:move}#edit,#sort{width:30px}#wpmem_block input{vertical-align:-webkit-baseline-middle;margin:0 0 8px 0}#wpmem_block label{margin:0 0 0 8px}#wpmem_ok_block_status{margin:5px 0 0 0}#wpmem_post_block_status{font-weight:600}#wpmem_post_icon_0{color:red}#wpmem_post_icon_1{color:green}#wpmem_post_icon_2{color:#000}#wpmem_product_enabled{color:green}#_wpmem_products,#s2id__wpmem_products,.select2-search-field{width:100%}#wpmem_user_profile_tabs{padding:0;background:0 0;border-width:0}#wpmem_user_profile_tabs .ui-tabs-nav{padding-left:0;background:0 0;border-width:0 0 1px 0;-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}#wpmem_user_profile_tabs .ui-tabs-panel{background:#fff;border-width:0 1px 1px 1px}#wpmem_user_profile_tabs .ui-state-active{border:1px solid #006799;background:#2271b1}#wpmem_user_profile_tabs .ui-state-active a{color:#fff}#wpmem_product_fixed_period,#wpmem_product_fixed_period_select input,#wpmem_product_fixed_period_select label,#wpmem_product_no_gap{margin-top:10px;margin-left:24px}#updatesettings a{text-decoration:none}updatesettings a:hover{color:#000}#createuser .form-field input[type="checkbox"]{width: initial;}.wpmem-user-table-membership {border-bottom:1px solid #999;} \ No newline at end of file From 0c511ba8750fce14b533bc379b398bb35d737b99 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 09:13:49 -0500 Subject: [PATCH 1546/1694] prepare for 3.4.1 --- readme.txt | 9 ++++++++- wp-members.php | 4 ++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/readme.txt b/readme.txt index b36dc852..c64dec56 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 5.8 -Stable tag: 3.4.0 +Stable tag: 3.4.1 License: GPLv3 @@ -134,6 +134,13 @@ WP-Members 3.4.0 is a major update. Backup prior to upgrading is recommended. Se == Changelog == += 3.4.1 = + +* Fixes a bug in the user api for undefined variable when checking the user ip. +* Fixes a bug in 3.4.0 that causes an error in user export. +* Sanitize email as email, not text. +* Fixes a bug in 3.4.0 that causes the captcha validation to be run twice, resulting in failed captcha during registration. + = 3.4.0 = Here is a list of changes in 3.4.0, but for a more detailed look at the impact of some of these items, be sure to review https://rocketgeek.com/release-announcements/wp-members-3-4-0-wow/ diff --git a/wp-members.php b/wp-members.php index 92306633..6e79df34 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.4.0 +Version: 3.4.1 Author: Chad Butler Author URI: https://butlerblog.com/ Text Domain: wp-members @@ -58,7 +58,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.4.0' ); +define( 'WPMEM_VERSION', '3.4.1' ); define( 'WPMEM_DB_VERSION', '2.3.0' ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 83792df97575b7bf1cb812a15a5b5961fe90c6f8 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 12:03:02 -0500 Subject: [PATCH 1547/1694] cleanup --- includes/class-wp-members-forms.php | 2 +- includes/class-wp-members-user.php | 2 +- includes/class-wp-members.php | 3 --- includes/deprecated.php | 12 ------------ readme.txt | 1 + 5 files changed, 3 insertions(+), 17 deletions(-) diff --git a/includes/class-wp-members-forms.php b/includes/class-wp-members-forms.php index 8e7d0496..07472158 100644 --- a/includes/class-wp-members-forms.php +++ b/includes/class-wp-members-forms.php @@ -608,7 +608,7 @@ function login_form( $mixed, $arr = array() ) { $action = ( ! isset( $arr['action'] ) ) ? 'login' : $arr['action']; - // Set up redirect_to @todo This could be done in a separate method usable by both login & reg. + // Set up redirect_to $redirect_to = wpmem_get_redirect_to( $arr ); // Set up default wrappers. diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 00abf197..978e5b3f 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -1025,7 +1025,7 @@ function get_user_products( $user_id = false, $obj = false ) { * @since 3.2.0 * @since 3.2.6 Added $date to set a specific expiration date. * @since 3.3.0 Updated to new single meta, keeps legacy array for rollback. - * @since 3.3.1 Added no gap renewal option, @todo Needs some possible condensing. + * @since 3.3.1 Added no gap renewal option. * * @param string $product * @param int $user_id diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 0191ddbc..6cbb6bc1 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -525,9 +525,6 @@ function load_hooks() { // Replace login error object. if ( 1 == $this->login_error ) { - // @todo I think we can do this without the filter now that - // the main messaging function has been updated. - // add_filter( 'wpmem_login_failed_args', array( $this->dialogs, 'login_error' ) ); add_filter( 'lostpassword_url', array( $this, 'lost_pwd_url' ), 10, 2 ); } diff --git a/includes/deprecated.php b/includes/deprecated.php index 294727c6..1bcf1f2a 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -326,18 +326,6 @@ function wpmem_build_rs_captcha() { add_action( 'wpmem_after_init', 'wpmem_load_deprecated_constants' ); function wpmem_load_deprecated_constants() { global $wpmem; -/* ( ! defined( 'WPMEM_BLOCK_POSTS' ) ) ? define( 'WPMEM_BLOCK_POSTS', $wpmem->block['post'] ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_BLOCK_PAGES' ) ) ? define( 'WPMEM_BLOCK_PAGES', $wpmem->block['page'] ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_SHOW_EXCERPT' ) ) ? define( 'WPMEM_SHOW_EXCERPT', $wpmem->show_excerpt['post'] ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_NOTIFY_ADMIN' ) ) ? define( 'WPMEM_NOTIFY_ADMIN', $wpmem->notify ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_MOD_REG' ) ) ? define( 'WPMEM_MOD_REG', $wpmem->mod_reg ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_CAPTCHA' ) ) ? define( 'WPMEM_CAPTCHA', $wpmem->captcha ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_NO_REG' ) ) ? define( 'WPMEM_NO_REG', ( -1 * $wpmem->show_reg['post'] ) ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_IGNORE_WARN' ) ) ? define( 'WPMEM_IGNORE_WARN', $wpmem->warnings ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_MSURL' ) ) ? define( 'WPMEM_MSURL', $wpmem->user_pages['profile'] ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_REGURL' ) ) ? define( 'WPMEM_REGURL', $wpmem->user_pages['register'] ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_LOGURL' ) ) ? define( 'WPMEM_LOGURL', $wpmem->user_pages['login'] ) : ''; // @todo Can deprecate? Probably 3.3 - ( ! defined( 'WPMEM_DROPIN_DIR' ) ) ? define( 'WPMEM_DROPIN_DIR', WP_PLUGIN_DIR . '/wp-members-dropins/' ) : '';*/ ( ! defined( 'WPMEM_CSSURL' ) ) ? define( 'WPMEM_CSSURL', $wpmem->cssurl ) : ''; } diff --git a/readme.txt b/readme.txt index c64dec56..8b72b4e0 100644 --- a/readme.txt +++ b/readme.txt @@ -136,6 +136,7 @@ WP-Members 3.4.0 is a major update. Backup prior to upgrading is recommended. Se = 3.4.1 = +* Moves external libraries to "vendor" directory. * Fixes a bug in the user api for undefined variable when checking the user ip. * Fixes a bug in 3.4.0 that causes an error in user export. * Sanitize email as email, not text. From 6e68dc8c0870e287fc3000ab0243ad2a4121f9ad Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 12:03:24 -0500 Subject: [PATCH 1548/1694] added attachments to email functions --- includes/class-wp-members-email.php | 24 +++++++++++++++++++----- readme.txt | 1 + 2 files changed, 20 insertions(+), 5 deletions(-) diff --git a/includes/class-wp-members-email.php b/includes/class-wp-members-email.php index 556555c4..99525ce1 100644 --- a/includes/class-wp-members-email.php +++ b/includes/class-wp-members-email.php @@ -177,6 +177,16 @@ public function to_user( $user_id, $password, $tag, $wpmem_fields = null, $field */ $this->settings['headers'] = apply_filters( 'wpmem_email_headers', $default_header, $this->settings['tag'] ); + /** + * Filters attachments. + * + * @since 3.4.1 + * + * @param mixed $attachments Any file attachments as a string or array. (default per wp_mail() documentation is empty array). + * @param string $this->settings['tag'] Tag to determine what email is being generated (newreg|newmod|appmod|repass|admin). + */ + $this->settings['attachments'] = apply_filters( 'wpmem_email_attachments', array(), $this->settings['tag'] ); + /** * Filter the email. * @@ -380,6 +390,9 @@ public function notify_admin( $user_id, $wpmem_fields = null, $field_data = null /** This filter is documented in class-wp-members-email.php */ $this->settings['headers'] = apply_filters( 'wpmem_email_headers', $default_header, 'admin' ); + /** This filter is documented in class-wp-members-email.php */ + $this->settings['attachments'] = apply_filters( 'wpmem_email_attachments', array(), 'admin' ); + /** * Filters the address the admin notification is sent to. * @@ -560,10 +573,11 @@ public function content_type( $content_type ) { */ private function send( $to ) { $args['to'] = ( 'user' == $to ) ? $this->settings['user_email'] : $this->settings['admin_email']; - $args['subject'] = $this->settings['subj']; - $args['message'] = $this->settings['body']; - $args['headers'] = $this->settings['headers']; - // @todo Add attachments to arguments and email send (and probably in the original function). + $args['subject'] = $this->settings['subj']; + $args['message'] = $this->settings['body']; + $args['headers'] = $this->settings['headers']; + $args['attachments'] = $this->settings['attachments']; + /** * Filter email send arguments. * @@ -581,7 +595,7 @@ private function send( $to ) { add_filter( 'wp_mail_content_type', array( $this, 'content_type' ) ); // Send message. - $result = wp_mail( $args['to'], stripslashes( $args['subject'] ), stripslashes( $args['message'] ) ); + $result = wp_mail( $args['to'], stripslashes( $args['subject'] ), stripslashes( $args['message'] ), $args['headers'], $args['attachments'] ); // Remove customizations. remove_filter( 'wp_mail_from', array( $this, 'from' ) ); diff --git a/readme.txt b/readme.txt index 8b72b4e0..5ad407b9 100644 --- a/readme.txt +++ b/readme.txt @@ -136,6 +136,7 @@ WP-Members 3.4.0 is a major update. Backup prior to upgrading is recommended. Se = 3.4.1 = +* Added attachements to email function. * Moves external libraries to "vendor" directory. * Fixes a bug in the user api for undefined variable when checking the user ip. * Fixes a bug in 3.4.0 that causes an error in user export. From 970c00c97f91aec0a201355af4425acca2aaadb2 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 27 Dec 2021 12:06:22 -0500 Subject: [PATCH 1549/1694] added wpmem_is_user_current() api function --- includes/api/api-users.php | 7 ++++--- readme.txt | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index f3375825..ad22ec72 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -242,10 +242,11 @@ function wpmem_user_has_access( $product, $user_id = false ) { * @param integer $user_id * @return boolean */ -function wpmem_user_is_current( $product, $user_id = false ) { +function wpmem_is_user_current( $product, $user_id = false ) { global $wpmem; - // @todo Finish this. - return; + $user_id = ( false === $user_id ) ? get_current_user_id() : $user_id; + $memberships = wpmem_get_user_products( $user_id ); + return ( $wpmem->user->is_current( $memberships[ $product ] ) ) ? true : false; } /** diff --git a/readme.txt b/readme.txt index 5ad407b9..70bffb0d 100644 --- a/readme.txt +++ b/readme.txt @@ -136,6 +136,7 @@ WP-Members 3.4.0 is a major update. Backup prior to upgrading is recommended. Se = 3.4.1 = +* Added wpmem_is_user_current() api function. * Added attachements to email function. * Moves external libraries to "vendor" directory. * Fixes a bug in the user api for undefined variable when checking the user ip. From ed7c9c05dcbb2fea5495744100c5d3f53ac11097 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 6 Jan 2022 10:18:20 -0500 Subject: [PATCH 1550/1694] remove use of wpmem_page_pwd_reset(), deprecated as of 3.4.0. --- includes/class-wp-members-shortcodes.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index e1a380d2..cf028b2d 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -451,7 +451,7 @@ function user_profile( $atts, $content, $tag ) { break; case "pwdchange": - $content = wpmem_page_pwd_reset( $wpmem->regchk, $content ); + $content = $this->render_pwd_reset()( $wpmem->regchk, $content ); $content = ( 'pwdchangesuccess' == $wpmem->regchk ) ? $content . $this->render_links() : $content; break; From e8e94fb75a28171fef179b5d598925d81ac313b0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 6 Jan 2022 10:19:26 -0500 Subject: [PATCH 1551/1694] fix list table cursor issue to only change on fields tab screen (not all posts) --- assets/css/admin.css | 4 ++-- assets/css/admin.min.css | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/assets/css/admin.css b/assets/css/admin.css index 49512705..4fbf8fcc 100644 --- a/assets/css/admin.css +++ b/assets/css/admin.css @@ -52,8 +52,8 @@ .req { color: #f00; } -/** This needs to change where it loads - it should only load on the fields table for drag/drop */ -#the-list { + +.settings_page_wpmem-settings #the-list { cursor: move; } #sort, #edit { diff --git a/assets/css/admin.min.css b/assets/css/admin.min.css index 7bfabcca..dfd8132d 100644 --- a/assets/css/admin.min.css +++ b/assets/css/admin.min.css @@ -1 +1 @@ -.wpmem_tbl_drag{background:#fffbcc;font-weight:700;border:1px solid #900}.column-wpmem_block{width:80px}#addfieldform li,#editfieldform li,#updatesettings li{padding:5px 0}#addfieldform label,#editfieldform label,#updatesettings label{float:left;width:166px;clear:both;display:block}#addfieldform .add-field-indent,#editfieldform .add-field-indent{margin-left:165px}#add_field_postbox,#fields_postbox{min-width:950px}.req{color:red}#the-list{cursor:move}#edit,#sort{width:30px}#wpmem_block input{vertical-align:-webkit-baseline-middle;margin:0 0 8px 0}#wpmem_block label{margin:0 0 0 8px}#wpmem_ok_block_status{margin:5px 0 0 0}#wpmem_post_block_status{font-weight:600}#wpmem_post_icon_0{color:red}#wpmem_post_icon_1{color:green}#wpmem_post_icon_2{color:#000}#wpmem_product_enabled{color:green}#_wpmem_products,#s2id__wpmem_products,.select2-search-field{width:100%}#wpmem_user_profile_tabs{padding:0;background:0 0;border-width:0}#wpmem_user_profile_tabs .ui-tabs-nav{padding-left:0;background:0 0;border-width:0 0 1px 0;-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}#wpmem_user_profile_tabs .ui-tabs-panel{background:#fff;border-width:0 1px 1px 1px}#wpmem_user_profile_tabs .ui-state-active{border:1px solid #006799;background:#2271b1}#wpmem_user_profile_tabs .ui-state-active a{color:#fff}#wpmem_product_fixed_period,#wpmem_product_fixed_period_select input,#wpmem_product_fixed_period_select label,#wpmem_product_no_gap{margin-top:10px;margin-left:24px}#updatesettings a{text-decoration:none}updatesettings a:hover{color:#000}#createuser .form-field input[type="checkbox"]{width: initial;}.wpmem-user-table-membership {border-bottom:1px solid #999;} \ No newline at end of file +.wpmem_tbl_drag{background:#fffbcc;font-weight:700;border:1px solid #900}.column-wpmem_block{width:80px}#addfieldform li,#editfieldform li,#updatesettings li{padding:5px 0}#addfieldform label,#editfieldform label,#updatesettings label{float:left;width:166px;clear:both;display:block}#addfieldform .add-field-indent,#editfieldform .add-field-indent{margin-left:165px}#add_field_postbox,#fields_postbox{min-width:950px}.req{color:red}.settings_page_wpmem-settings #the-list{cursor:move}#edit,#sort{width:30px}#wpmem_block input{vertical-align:-webkit-baseline-middle;margin:0 0 8px 0}#wpmem_block label{margin:0 0 0 8px}#wpmem_ok_block_status{margin:5px 0 0 0}#wpmem_post_block_status{font-weight:600}#wpmem_post_icon_0{color:red}#wpmem_post_icon_1{color:green}#wpmem_post_icon_2{color:#000}#wpmem_product_enabled{color:green}#_wpmem_products,#s2id__wpmem_products,.select2-search-field{width:100%}#wpmem_user_profile_tabs{padding:0;background:0 0;border-width:0}#wpmem_user_profile_tabs .ui-tabs-nav{padding-left:0;background:0 0;border-width:0 0 1px 0;-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}#wpmem_user_profile_tabs .ui-tabs-panel{background:#fff;border-width:0 1px 1px 1px}#wpmem_user_profile_tabs .ui-state-active{border:1px solid #006799;background:#008ec2}#wpmem_user_profile_tabs .ui-state-active a{color:#fff}#wpmem_product_fixed_period,#wpmem_product_fixed_period_select input,#wpmem_product_fixed_period_select label,#wpmem_product_no_gap{margin-top:10px;margin-left:24px}#updatesettings a{text-decoration:none}updatesettings a:hover{color:#000}#createuser .form-field input[type="checkbox"]{width: initial;}.wpmem-user-table-membership {border-bottom:1px solid #999;} \ No newline at end of file From c788a6fba15226a2bc1b0e44d0384eea1de75da0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 6 Jan 2022 10:21:06 -0500 Subject: [PATCH 1552/1694] fix scalable logic issue with child membership products --- includes/api/api-users.php | 3 ++- includes/class-wp-members-user.php | 28 +++++++++++++--------------- 2 files changed, 15 insertions(+), 16 deletions(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index ad22ec72..bfba625c 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -226,7 +226,8 @@ function wpmem_update_user_role( $user_id, $role, $action = 'set' ) { * @return boolean $access True if user has access, otherwise false. */ function wpmem_user_has_access( $product, $user_id = false ) { - global $wpmem; + global $wpmem; + $user_id = ( false == $user_id ) ? get_current_user_id() : $user_id; return $wpmem->user->has_access( $product, $user_id ); } diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 978e5b3f..7e270ff4 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -896,15 +896,15 @@ function set_as_logged_in( $user_id ) { */ function has_access( $product, $user_id = false ) { global $wpmem; - if ( false === $user_id && ! is_user_logged_in() ) { + if ( ! is_user_logged_in() ) { return false; } // Product must be an array. $product_array = ( ! is_array( $product ) ) ? array( $product ) : $product; - $product_array = $this->get_product_children( $product_array ); - + $product_array = $this->get_product_ancestors( $product_array ); + // Current user or requested user. $user_id = ( ! $user_id ) ? get_current_user_id() : $user_id; @@ -961,32 +961,30 @@ function has_access( $product, $user_id = false ) { } /** - * Gets product children (if any). + * Gets product ancestors (if any). * - * @since 3.4.0 + * Replaces original get_product_children() from 3.4.0 which was not as scalable. + * + * @since 3.4.1 * * @global stdClass $wpmem * @param array $product_array * $return array $product_array Product array with child products added. */ - function get_product_children( $product_array ) { + function get_product_ancestors( $product_array ) { global $wpmem; $membership_ids = array_flip( $wpmem->membership->product_by_id ); foreach ( $product_array as $product ) { - $args = array( - 'post_type' => $wpmem->membership->post_type, - 'post_parent' => $membership_ids[ $product ], // Current post's ID - ); - $children = get_children( $args ); - if ( ! empty( $children ) ) { - foreach ( $children as $child ) { - $product_array[] = $child->post_name; + $ancestors = get_post_ancestors( $membership_ids[ $product ] ); + if ( ! empty( $ancestors ) ) { + foreach ( $ancestors as $ancestor ) { + $product_array[] = get_post_field( 'post_name', $ancestor );; } } } - return $product_array; + return $product_array; } /** From edf23353b935218e8c8f502a20ceecbeb35cc4df Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 6 Jan 2022 10:21:22 -0500 Subject: [PATCH 1553/1694] cleanup --- includes/class-wp-members.php | 2 +- .../vendor/rocketgeek-utilities/includes/dates.php | 13 +++++++++++-- readme.txt | 8 ++++++-- 3 files changed, 18 insertions(+), 5 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 6cbb6bc1..1202bbac 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -1696,7 +1696,7 @@ function load_textdomain() { $file = apply_filters( 'wpmem_localization_file', trailingslashit( WP_LANG_DIR ) . 'plugins/' . $domain . '-' . $locale . '.mo', $locale ); $loaded = load_textdomain( $domain, $file ); - if ( true === $loaded ) { + if ( true == $loaded ) { return $loaded; } else { /** diff --git a/includes/vendor/rocketgeek-utilities/includes/dates.php b/includes/vendor/rocketgeek-utilities/includes/dates.php index 3b6c19ef..f56c567b 100644 --- a/includes/vendor/rocketgeek-utilities/includes/dates.php +++ b/includes/vendor/rocketgeek-utilities/includes/dates.php @@ -90,7 +90,7 @@ function rktgk_date_format_map() { } endif; -if ( ! function_exists( 'rktgk_date_format' ) ): +if ( ! function_exists( 'rktgk_get_php_date_format' ) ): /** * Converts certain date formats to PHP. * @@ -103,9 +103,18 @@ function rktgk_date_format_map() { * @param string $format * @return string */ -function rktgk_date_format( $format ) { +function rktgk_get_php_date_format( $format ) { $convert = rktgk_date_format_map(); $format_upper = strtoupper( $format ); return ( isset( $convert[ $format_upper ] ) ) ? $convert[ $format ] : $format; } +endif; + +if ( ! function_exists( 'rktgk_date_format' ) ): +/** + * Replaced by rktgk_get_php_date_format() + */ +function rktgk_date_format( $format ) { + return rktgk_get_php_date_format( $format ); +} endif; \ No newline at end of file diff --git a/readme.txt b/readme.txt index 70bffb0d..1919af8e 100644 --- a/readme.txt +++ b/readme.txt @@ -110,7 +110,7 @@ The FAQs are maintained at https://rocketgeek.com/plugins/wp-members/docs/faqs/ == Upgrade Notice == -WP-Members 3.4.0 is a major update. Backup prior to upgrading is recommended. See changelog for important details. Minimum WP version is 4.0. +WP-Members 3.4.1 is a minor update. Backup prior to upgrading is recommended. See changelog for important details. Minimum WP version is 4.0. == Screenshots == @@ -136,13 +136,17 @@ WP-Members 3.4.0 is a major update. Backup prior to upgrading is recommended. Se = 3.4.1 = +* * Added wpmem_is_user_current() api function. * Added attachements to email function. * Moves external libraries to "vendor" directory. +* Removes a overlooked use of wpmem_page_pwd_reset() which was deprecated as of 3.4.0. +* Sanitize email as email, not text. * Fixes a bug in the user api for undefined variable when checking the user ip. * Fixes a bug in 3.4.0 that causes an error in user export. -* Sanitize email as email, not text. * Fixes a bug in 3.4.0 that causes the captcha validation to be run twice, resulting in failed captcha during registration. +* Fixes css issue that caused cursor change on all list table screens for drag-and-drop; should only show on Fields tab. + = 3.4.0 = From 63e4ee842ba52b686bf0a511826eb1f6381e638c Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 6 Jan 2022 14:39:19 -0500 Subject: [PATCH 1554/1694] revise membership hierarchy validation --- .../admin/class-wp-members-products-admin.php | 23 +++++++++++++++++ includes/api/api-products.php | 5 ++++ includes/class-wp-members-user.php | 25 +++++++++++++++---- 3 files changed, 48 insertions(+), 5 deletions(-) diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index 9f56eb49..ebd49630 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -27,6 +27,7 @@ function __construct() { add_filter( 'manage_wpmem_product_posts_columns', array( $this, 'columns_heading' ) ); add_action( 'manage_wpmem_product_posts_custom_column', array( $this, 'columns_content' ), 10, 2 ); add_action( 'add_meta_boxes', array( $this, 'meta_boxes' ) ); + add_action( 'page_attributes_misc_attributes', array( $this, 'membership_attributes' ) ); add_action( 'save_post', array( $this, 'save_details' ) ); add_action( 'wpmem_admin_after_block_meta', array( $this, 'add_product_to_post' ), 10, 2 ); add_action( 'wpmem_admin_block_meta_save', array( $this, 'save_product_to_post' ), 10, 3 ); @@ -154,6 +155,21 @@ function meta_boxes() { 'wpmem_product' ); } + + /** + * Adds child membership access option to Membership Attributes meta box. + * + * @since 3.4.1 + */ + function membership_attributes( $post ) { + if ( 'wpmem_product' == $post->post_type ) { + $checked = get_post_meta( $post->ID, 'wpmem_product_child_access', true ); + echo '

    + +
    +

    '; + } + } /** * Gets an array of post types. @@ -455,6 +471,13 @@ function save_details( $post_id ) { delete_post_meta( $post_id, 'wpmem_product_message' ); } } + + $child_access = intval( wpmem_get( 'wpmem_product_child_access', 0 ) ); + if ( 1 == $child_access ) { + update_post_meta( $post_id, 'wpmem_product_child_access', $child_access ); + } else { + delete_post_meta( $post_id, 'wpmem_product_child_access' ); + } } /** diff --git a/includes/api/api-products.php b/includes/api/api-products.php index 038b826c..8476085c 100644 --- a/includes/api/api-products.php +++ b/includes/api/api-products.php @@ -62,4 +62,9 @@ function wpmem_get_products() { function wpmem_get_memberships() { global $wpmem; return ( ! empty( $wpmem->membership->products ) ) ? $wpmem->membership->products : false; +} + +function wpmem_get_memberships_ids() { + global $wpmem; + return array_flip( $wpmem->membership->product_by_id ); } \ No newline at end of file diff --git a/includes/class-wp-members-user.php b/includes/class-wp-members-user.php index 7e270ff4..c6638987 100644 --- a/includes/class-wp-members-user.php +++ b/includes/class-wp-members-user.php @@ -903,7 +903,7 @@ function has_access( $product, $user_id = false ) { // Product must be an array. $product_array = ( ! is_array( $product ) ) ? array( $product ) : $product; - $product_array = $this->get_product_ancestors( $product_array ); + $product_array = $this->get_membership_stack( $product_array ); // Current user or requested user. $user_id = ( ! $user_id ) ? get_current_user_id() : $user_id; @@ -913,7 +913,7 @@ function has_access( $product, $user_id = false ) { // Start by assuming no access. $access = false; - + foreach ( $product_array as $prod ) { $expiration_product = false; $role_product = false; @@ -961,7 +961,7 @@ function has_access( $product, $user_id = false ) { } /** - * Gets product ancestors (if any). + * Gets membership hierarchy (if any). * * Replaces original get_product_children() from 3.4.0 which was not as scalable. * @@ -971,11 +971,26 @@ function has_access( $product, $user_id = false ) { * @param array $product_array * $return array $product_array Product array with child products added. */ - function get_product_ancestors( $product_array ) { + function get_membership_stack( $product_array ) { global $wpmem; - $membership_ids = array_flip( $wpmem->membership->product_by_id ); + $membership_ids = wpmem_get_memberships_ids(); foreach ( $product_array as $product ) { + // Do we need child access? + $child_access = get_post_meta( $membership_ids[ $product ], 'wpmem_product_child_access', true ); + if ( 1 == $child_access ) { + $args = array( + 'post_type' => $wpmem->membership->post_type, + 'post_parent' => $membership_ids[ $product ], // Current post's ID + ); + $children = get_children( $args ); + if ( ! empty( $children ) ) { + foreach ( $children as $child ) { + $product_array[] = $child->post_name; + } + } + } + // Ancestor access is by default. $ancestors = get_post_ancestors( $membership_ids[ $product ] ); if ( ! empty( $ancestors ) ) { foreach ( $ancestors as $ancestor ) { From 260d006a318aaaf72511a5fcf1909fff15bafd30 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 6 Jan 2022 14:40:25 -0500 Subject: [PATCH 1555/1694] change "product" to "membership" and "block" to "restricted" --- includes/admin/class-wp-members-admin-api.php | 2 +- .../admin/class-wp-members-admin-posts.php | 30 +++++++++---------- .../admin/class-wp-members-products-admin.php | 2 +- .../class-wp-members-admin-tab-options.php | 6 ++-- includes/class-wp-members-products.php | 5 ++-- 5 files changed, 23 insertions(+), 22 deletions(-) diff --git a/includes/admin/class-wp-members-admin-api.php b/includes/admin/class-wp-members-admin-api.php index 4fd74417..13daf98b 100644 --- a/includes/admin/class-wp-members-admin-api.php +++ b/includes/admin/class-wp-members-admin-api.php @@ -625,7 +625,7 @@ function wp_reserved_terms() { function settings( $which ) { switch ( $which ) { case 'content': - return array( 'block' => 'Content Blocking', 'show_excerpt' => 'Show Excerpts', 'show_login' => 'Show Login Form', 'show_reg' => 'Show Registration Form', 'autoex' => 'Auto Excerpt' ); + return array( 'block' => 'Content Restriction', 'show_excerpt' => 'Show Excerpts', 'show_login' => 'Show Login Form', 'show_reg' => 'Show Registration Form', 'autoex' => 'Auto Excerpt' ); break; case 'options': return array( 'notify' => 'Notify admin', 'mod_reg' => 'Moderate registration', 'captcha' => 'Enable registration CAPTCHA', 'warnings' => 'Ignore warning messages', 'dropins' => 'Enable dropins', 'enable_products' => 'Enable membership products', 'clone_menus' => 'Clone menus' ); diff --git a/includes/admin/class-wp-members-admin-posts.php b/includes/admin/class-wp-members-admin-posts.php index f1595888..b93a5862 100644 --- a/includes/admin/class-wp-members-admin-posts.php +++ b/includes/admin/class-wp-members-admin-posts.php @@ -27,12 +27,12 @@ static function bulk_action() { if ( ( isset( $_GET['post_type'] ) && ( 'page' == $_GET['post_type'] || 'post' == $_GET['post_type'] || array_key_exists( $_GET['post_type'], $wpmem->post_types ) ) ) || ! isset( $_GET['post_type'] ) ) { ?>

    ' . esc_html( $_REQUEST['n'] ) . ' ' . esc_html( $msg ) . '

    '; } } @@ -192,9 +192,9 @@ static function block_meta() { $post_meta_value = get_post_meta( $post->ID, '_wpmem_block', true ); $post_meta_value = ( null == $post_meta_value ) ? $wpmem->block[ $post->post_type ] : $post_meta_value; $post_meta_settings = array( - '0' => array( 'text' => __( 'Unblocked', 'wp-members' ), 'icon' => '' ), - '1' => array( 'text' => __( 'Blocked', 'wp-members' ), 'icon' => '' ), - '2' => array( 'text' => __( 'Hidden', 'wp-members' ), 'icon' => '' ), + '0' => array( 'text' => __( 'Unrestricted', 'wp-members' ), 'icon' => '' ), + '1' => array( 'text' => __( 'Restricted', 'wp-members' ), 'icon' => '' ), + '2' => array( 'text' => __( 'Hidden', 'wp-members' ), 'icon' => '' ), ); ?>

    $value ) { @@ -336,17 +336,17 @@ static function columns_content( $column_name, $post_ID ) { } if ( $wpmem->block[ $post_type ] == 1 ) { - $block_span = array( 'lock', 'green', 'Blocked' ); + $block_span = array( 'lock', 'green', __( 'Restricted', 'wp-members' ) ); } if ( $wpmem->block[ $post_type ] == 0 ) { - $block_span = array( 'unlock', 'red', 'Unblocked' ); + $block_span = array( 'unlock', 'red', __( 'Unrestricted', 'wp-members' ) ); } if ( $wpmem->block[ $post_type ] == 1 && $block_meta == '0' ) { - $block_span = array( 'unlock', 'red', 'Unblocked' ); + $block_span = array( 'unlock', 'red', __( 'Unrestricted', 'wp-members' ) ); } elseif ( $wpmem->block[ $post_type ] == 0 && $block_meta == '1' ) { - $block_span = array( 'lock', 'green', 'Blocked' ); + $block_span = array( 'lock', 'green', __( 'Restricted', 'wp-members' ) ); } elseif ( 2 == $block_meta ) { - $block_span = array( 'hidden', '', 'Hidden' ); + $block_span = array( 'hidden', '', __( 'Hidden', 'wp-members' ) ); } echo ''; } diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index ebd49630..1cddc24c 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -514,7 +514,7 @@ function add_product_to_post( $post, $block ) { echo wpmem_form_label( array( 'meta_key'=>$wpmem->membership->post_meta, - 'label'=>__( 'Limit access to:', 'wp-members' ), + 'label'=>__( 'Restrict access by membership:', 'wp-members' ), 'type'=> 'multiselect' ) ); echo "
    "; diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index 63512c24..b36db465 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -102,12 +102,12 @@ static function build_settings() { if ( $key == 'post' || $key == 'page' || ( isset( $wpmem->post_types ) && array_key_exists( $key, $wpmem->post_types ) ) ) { ?> > - + block[ $key ] ) ) ? $wpmem->block[ $key ] : ''; $values = array( - __( 'Do not block', 'wp-members' ) . '|0', - __( 'Block', 'wp-members' ) . '|1', + __( 'Do not restrict', 'wp-members' ) . '|0', + __( 'Restrict', 'wp-members' ) . '|1', // @todo Future development. __( 'Hide', 'wp-members' ) . '|2', ); echo wpmem_form_field( 'wpmem_block_' . $key, 'select', $values, $block ); ?> diff --git a/includes/class-wp-members-products.php b/includes/class-wp-members-products.php index e077ea5f..25eb2d3c 100644 --- a/includes/class-wp-members-products.php +++ b/includes/class-wp-members-products.php @@ -332,8 +332,8 @@ function add_cpt() { */ $args = apply_filters( 'wpmem_membership_cpt_args', $args ); - $singular = __( 'Product', 'wp-members' ); - $plural = __( 'Products', 'wp-members' ); + $singular = __( 'Membership', 'wp-members' ); + $plural = __( 'Memberships', 'wp-members' ); $labels = array( 'name' => $plural, @@ -352,6 +352,7 @@ function add_cpt() { 'not_found_in_trash' => __( 'Not found in Trash', 'wp-members' ), 'insert_into_item' => __( 'Insert into item', 'wp-members' ), 'publish' => sprintf( __( 'Save %s Details', 'wp-members' ), $singular ), + 'attributes' => __( 'Membership Attributes', 'wp-members' ), ); $args = array( 'label' => __( 'Membership Product', 'wp-members' ), From 629ec62655dad970b34b04942d47c4cc328976f6 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 6 Jan 2022 14:40:52 -0500 Subject: [PATCH 1556/1694] sanitize membership product screen vars --- includes/admin/class-wp-members-products-admin.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/includes/admin/class-wp-members-products-admin.php b/includes/admin/class-wp-members-products-admin.php index 1cddc24c..d572a80c 100644 --- a/includes/admin/class-wp-members-products-admin.php +++ b/includes/admin/class-wp-members-products-admin.php @@ -439,12 +439,12 @@ function save_details( $post_id ) { if ( $fixed_period ) { // Start and end. - $period_start = wpmem_get( 'wpmem_product_fixed_period_start' ); - $period_end = wpmem_get( 'wpmem_product_fixed_period_end' ); + $period_start = sanitize_text_field( wpmem_get( 'wpmem_product_fixed_period_start' ) ); + $period_end = sanitize_text_field( wpmem_get( 'wpmem_product_fixed_period_end' ) ); // Is there an entry grace period? - $grace_number = wpmem_get( 'wpmem_product_fixed_period_grace_number', false ); - $grace_period = wpmem_get( 'wpmem_product_fixed_period_grace_period', false ); + $grace_number = sanitize_text_field( wpmem_get( 'wpmem_product_fixed_period_grace_number', false ) ); + $grace_period = sanitize_text_field( wpmem_get( 'wpmem_product_fixed_period_grace_period', false ) ); $save_fixed_period = $period_start . '-' . $period_end; if ( $grace_number && $grace_period ) { $save_fixed_period .= '-' . $grace_number . '-' . $grace_period; @@ -463,7 +463,7 @@ function save_details( $post_id ) { } } - $product_message = wpmem_get( 'product_message', false ); + $product_message = wp_kses_post( wpmem_get( 'product_message', false ) ); if ( false !== $product_message ) { if ( '' != $product_message ) { update_post_meta( $post_id, 'wpmem_product_message', $product_message ); @@ -537,7 +537,7 @@ function add_product_to_post( $post, $block ) { */ function save_product_to_post( $post ) { global $wpmem; - $products = wpmem_get( $wpmem->membership->post_meta ); + $products = wpmem_sanitize_array( wpmem_get( $wpmem->membership->post_meta ) ); $products = ( $products ) ? $products : array(); if ( empty( $products ) || ( 1 == count( $products ) && '' == $products[0] ) ) { delete_post_meta( $post->ID, $wpmem->membership->post_meta ); From e23e819963968bcaa089c812c45aef7901d78d66 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Thu, 6 Jan 2022 14:41:02 -0500 Subject: [PATCH 1557/1694] cleanup --- includes/admin/tabs/class-wp-members-admin-tab-options.php | 2 +- readme.txt | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index b36db465..0c164242 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -211,7 +211,7 @@ static function build_settings() { $conf_link_start = ''; $conf_link_end = ''; $rows = array( - array(__('Enable Products', 'wp-members'),'wpmem_settings_products',sprintf(__('Enables creation of different %s membership products %s','wp-members'),$mem_link_start,$mem_link_end),'enable_products'), + array(__('Enable memberships', 'wp-members'),'wpmem_settings_products',sprintf(__('Enables creation of different %s membership products %s','wp-members'),$mem_link_start,$mem_link_end),'enable_products'), array(__('Clone menus','wp-members'),'wpmem_settings_menus',__('Enables logged in menus','wp-members'),'clone_menus'), array(__('Notify admin','wp-members'),'wpmem_settings_notify',sprintf(__('Notify %s for each new registration? %s','wp-members'),$admin_email,$chg_email),'notify'), array(__('Moderate registration','wp-members'),'wpmem_settings_moderate',__('Holds new registrations for admin approval','wp-members'),'mod_reg'), diff --git a/readme.txt b/readme.txt index 1919af8e..7a67d16b 100644 --- a/readme.txt +++ b/readme.txt @@ -136,7 +136,9 @@ WP-Members 3.4.1 is a minor update. Backup prior to upgrading is recommended. Se = 3.4.1 = -* +* Revise the membership hierarchy logic (see release announcement for details). +* Changing "Product" text to "Membership" for clarity (was planned for 3.4.0). +* Changing "Block" text to "Restricted" for clarity (was planned for 3.4.0). * Added wpmem_is_user_current() api function. * Added attachements to email function. * Moves external libraries to "vendor" directory. @@ -147,7 +149,6 @@ WP-Members 3.4.1 is a minor update. Backup prior to upgrading is recommended. Se * Fixes a bug in 3.4.0 that causes the captcha validation to be run twice, resulting in failed captcha during registration. * Fixes css issue that caused cursor change on all list table screens for drag-and-drop; should only show on Fields tab. - = 3.4.0 = Here is a list of changes in 3.4.0, but for a more detailed look at the impact of some of these items, be sure to review https://rocketgeek.com/release-announcements/wp-members-3-4-0-wow/ From a22f841e607852dafc350f867418169a617d2e1a Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 Jan 2022 11:52:57 -0500 Subject: [PATCH 1558/1694] update translation files --- i18n/languages/wp-members-ca_CA.mo | Bin 18668 -> 16664 bytes i18n/languages/wp-members-ca_CA.po | 1677 ++++++++++-------- i18n/languages/wp-members-da_DK.mo | Bin 18170 -> 16239 bytes i18n/languages/wp-members-da_DK.po | 1679 ++++++++++-------- i18n/languages/wp-members-fi.mo | Bin 15636 -> 13631 bytes i18n/languages/wp-members-fi.po | 1679 ++++++++++-------- i18n/languages/wp-members-he_IL.mo | Bin 27821 -> 25366 bytes i18n/languages/wp-members-he_IL.po | 1697 ++++++++++-------- i18n/languages/wp-members-hi_IN.mo | Bin 24980 -> 21956 bytes i18n/languages/wp-members-hi_IN.po | 1696 ++++++++++-------- i18n/languages/wp-members-ko_KR.mo | Bin 22395 -> 20410 bytes i18n/languages/wp-members-ko_KR.po | 1736 +++++++++++-------- i18n/languages/wp-members-nb_NO.mo | Bin 14954 -> 0 bytes i18n/languages/wp-members-nb_NO.po | 2572 ---------------------------- i18n/languages/wp-members-pl_PL.mo | Bin 12140 -> 10169 bytes i18n/languages/wp-members-pl_PL.po | 1704 ++++++++++-------- i18n/languages/wp-members-pt_PT.mo | Bin 10802 -> 9849 bytes i18n/languages/wp-members-pt_PT.po | 1701 ++++++++++-------- i18n/languages/wp-members-sk_SK.mo | Bin 16360 -> 14367 bytes i18n/languages/wp-members-sk_SK.po | 1694 ++++++++++-------- i18n/languages/wp-members-sr_RS.mo | Bin 15826 -> 13999 bytes i18n/languages/wp-members-sr_RS.po | 1693 ++++++++++-------- i18n/languages/wp-members-tr_TR.mo | Bin 17779 -> 15993 bytes i18n/languages/wp-members-tr_TR.po | 1699 ++++++++++-------- i18n/languages/wp-members.pot | 1526 ++++++++++------- 25 files changed, 11621 insertions(+), 11132 deletions(-) delete mode 100644 i18n/languages/wp-members-nb_NO.mo delete mode 100644 i18n/languages/wp-members-nb_NO.po diff --git a/i18n/languages/wp-members-ca_CA.mo b/i18n/languages/wp-members-ca_CA.mo index fdfa43082b6b26fb187c99915fd95ba32cb29470..b20c7ff274f7fd1e58d09aff47c15f397d2715e1 100644 GIT binary patch delta 3920 zcmYk;4Rp^{9LMqdpLy7*J$YDb_|Imu&1^O!78{dlBSw-uuKA1DJWVXtUqdBovw!lC zhY+Pj@vlyY%0ovXDu<4oB&Tzn(*q^y&^e;_=l8oh?%DVEy7&Hm|KIQ4@4det7nXZg z)p-18qeE91%61~2Sk%~uab}TdeP4H`;qJ1utO?#zwf;bw>TZ z2R6sP*cu19{eCmSUQmJ2oS2Ju;ZnRCx8NPPA6wzq7=`CC6t7|jypH^t_L1%YGO-Ws zLe%v&sOw+BHnwiF!Vy>VD7{V-dJ{p_we3MK?7iL%sQ4biY3$PS5ut}&CR-qoW*q*Pm?UlB@ z33dH8)O~hi8Xmw9yoij&TtdH65yEh~V;t(nC8!yX#vM2jwFIqN8k3KS*aFK?{nJr1 zdMn0jP0*R4R{&G;v2}H z`GkXhcLFtmpHMTrh)VfQ)TWEzpuLrhdR{?m@~COX5$J>#6!pnWiFuZdl@z1<}{Rn7(bOpRJ^DeCn3);xu_ctMBQi# z=3y-=gUMZ4cPVla4Z~1?rqLExe250_7 zWu#SGcWskUDa=Oo_p|L1WdE2_)TXRNrF;PnzN`A$XRsbOu|AqikqJ z#@VP$?#ED`Z@#e?e2YJLj5&+ij31LXy;=@4ZLsb_e|tI(QqiaOJZhJFI=MfLNA;(pQhz@x1LKfOO&Mx4Ek#~wvk?d4 zho}cOVkb7iIAkB11l0ZVkbP@Lq>_J@)l8?O0c%mOOCAf~4Ev%+Tx8p0P@8C?Z7;-d z+RIP_Ux|9qF4Sf`iptDcd;WLSfWp{djL}4N$0`-@l5A*6J{74bP!c{5NXNqchzR zr&)_pZ_8BF($!-a?nLeSJ*b%;we3^ZpV3SIKNx{=jEVvJO&S%Q=#Co52pokKn1@F& z2b*+tm!KE&f|v)eKbB)L?n15U4b%WqvfU3&Hfl+SqB1lJBXJT&=>4y<9ZN8Q6Kha6 z`WW?TJ&&x0X~!rEuo$&=%aBiiIf-Q7T*cMck#};I$C$m?7IV70nJVew?y>0@#dUKq zQSbi}Ds6DPJ#i4V_NOo!|3tkmp^Qc!qP7@=d8pTSFb>9PsG06Xo^1}H*8E@81n%nT zeo+S?`_jxnKg(g(QQ=!+j$sP^g}PCEFLz)aQES#4%Wx1@<4zopnXFSktiw_~f!xC6 z-s`rfVLt8S$m*D=-fm_Kdz1fhbj+ut9M7O0P}IjA=?>KEa~hB7Jl5gc+)V?_D{xcW z-&%%R;~Hx%4yU~qmC4H(ijDiadnvrHpRXMq+ISkF%1lBVif1|HC60-NGNiJCSWK)X zUL&-Y8hj<8*=zGXLM$L=5Vy(@Dm>09Y!zpTosM^G=TKy?ID0`|TC-;fr7Ve1d60OK zxP!Qp;1zOGzY5tV&bML=K1pa#+$!}{n6y*YbJVh{_*-%qNRWBw%cid&%WCEkFAxdD zY@&$p5h_}OWyCb1Eir|tA+&c`dgp&Y&*SUFXyW$LpT-E=!M^mHDjK71yCRbM%eS>3 zr(Qs;BQl5%gvu;JAEH6TRHA~=u78?nPpE7so*_CB4TQ>O7w0(l{{^A>fIXq__EuZp zgpU%fh%DQeZVkbQZCyM^OeRW*`v{eZ1e@L|!#OS_#u9fEuM%O}5QT)wN*8B`^7S?-&ZVAe)U8WSaCcf)PvA=W z<-m>34S|m`+5}H#GjrC9Hze z8IOQ9un7)^o74N(LY6c)L#=Z=)YA9BA;y%=!|9D@Q@#QR@xa?~7(4(+z(;tq5 zN5gu^&n)Jm1=qq#xB>Qp?Qje%LTonMpbWbQo(7+Q{rJB5oDM(Jhp+0z;ZO@52akc( z5KGOePz$Vp*koGa7FdG4;b%}DehFn@A0F2HC^#IBg?(THR0Pk0gZaK$Nk=buumP6g z0Qe-7lYc@PqNjR-Ay5kshq^x=DiYJ7wrC;52D1t(Y4cD9T?zGG z7nB1}L4M{BT(r)6Wjc*?K7vY;dfw*SW+_y%cyJU9;8}1hoC@E7$HRfVq-322weU=+ zh%AGO&^MtRXn~4I8P$3>f&8bXg!5OdwHNP8wBtipUyB4wOwB9fh!z-ncp)Z-Z2lxd&=%9)}9~ zGjJh%4Jty`Qd)34)B)B6xn=TD9$uGnC*)_I<)W?G4=1SphmKA{HXkaKi(tG3P@(eR zdGI1wfN#LHa51OL9Jm9nhVR3Pu#s@if&r94yPzVxk4rWD04{+?oq(}?-(=}5g^xg@ zXL|EgPgo6q3&+D7;D=BiUxK?z&TF9d^iFsf+zoYq4_pMFf(rEj_HAJWYeS!LcAPO6 z!k1uKC*C=1s9szS-{iqHurK3T#7T9!04iITr92<1YFgoRcstYI(k6`=> zlp+6xis%5sq^+%%P>y_&j;kgmdp`{7emztK=Ri4j7Swm#GMxrGqO$u*I1s)B_29cu27U?IE>k%< z+4DN61?E8AUk&x4b?LkZwce$$KfDRb;JcwBbuW}b7yxMhT7YYpw9fUQ<4YA zL(6zNJRPot1K@2?d%hF?2tEvD*wU#SKClhSk*A>?dj}4JA43YJYSH9A`Ch}#zG}oBdmf;phCAU9k-?20xk2`L3w&Vlmov?=l4Mw`aV1l_Nd1= z)&E*L7;kQcGUR#4QDEMH3t+{`Nj)!w%7Gi840s%>YMzGL`@cd(@Ixp={{v-6f6i}> zN5avt4r-kySVpGAg~~Cz;avDOREX@%WYB-E>+o@^&U(Uo(Cbq$m@F6%Dz5wOnyKo8Y$-hYQbU9>~ z%o?bi*b3#qE;s?c4moQ~ zTr`*chQEjN;DiPigLz0W%nRwbFE@F`v_T5N?0^K*ya_LWL+0}i?0{PTFJ(Hi_zX6> z2MpnJdH`Mz7c?f8z5+)vek>r@J&|0J@-Hy&e2ixehlY_S%oPxRL#6|%U4iaLI*7DwThOIwIl|$%)o^_T zJ%rdL^F#C#6rqss$L(US>yxh83LiuqP;t{fUWPU%L-RmNoo-9f6R0=(K04SGY62U# zBG-q}naMEz>&c;i0-BtDKfOgw()$KF6;ZzCMsyWYYfEtGy5mqU`S07$8TUj=NYX0) zbB+rAT2s|@Z{8{W)kiI%wRF>0g67k=o(NMfK=<)V+;kZ~?k5o%}A`gbqV% z(7otjv--qEjGECpq?S)$Ho$G@D0B;2fYdHT-$Tmsqmi0QSM59KF|K|SJLav2P6Kz-5iNGF)u-RKVV3k}jX3Er3XTjA=o zKN1G$aWoG#D#Yg^wXx`1=qB`2v>n}pdZAjh6U{&#Dj~H;(KMv9pb{-X!_gkJ3f+nN zqeZ9>T8vIam!mA|zmkjEwYqd(H(*C)Ch|Jm&ia8*Rpp#an>{_}grS+2D`eU_KO5Lt zxuVt0yPX$T4e#kXe%H3DH5GHcsMQTD7h4S7z<2VlEdsDLR^shxE<6>MTc zm~njH&D!-rA#WYqTqv~Zx%QyY!DFpXq^Mv-;BvRMn0Nd-yQ0+#ZHF6p>phoMzxI${ zCPt18+nszfy-lqiF>!KX0Yd`96?uM39B8K)74RE3WI|{Q>un*IjSUFv?DB#w6^gdS zjciWA*LoAJ<7eY{F`Y-b8CoZkDF(zPS0b7%UgVW8#2dN6DvcOfYA$3;c9Z9aqwPXA zHS0#~YB7_j7cNWtSnRrs%C+kvT&ra~Gn%p4oMtuBWLCrYv=^kTFcL__ucLL>#EwpDC zP+Z--?E0d%P|>+)lI`EU$d-3*oHk-OrWDC{yvsVWi^1NGmguY`lT1*ZUF{|APoTBW@$KK(R#alh* zQ3jk66e=5}!gKTzA+;e>am|s-4c_LxyVI)6IJT_&ej$D&C{Sv#!*N!T>g-L2=SQ_f z(#D0hcRQ8FvF1m~O1o@W<0zvr-3#_^x7;cvWoA8_-+M3CZFbo6sF;fpn_sYZfvUN5Tvq{Vk8I~LY+6H+_nowAAYU=B8Y_jTL&Ht-7H*mep-8Qbq z^@(G96gzS#DQqcDmZfA%oo&)#*RIVEYDw01Vt|vvSHX?bAWR(D`#|J|)nT29+|7~M MyFGB@y^cr!0}RLKe*gdg diff --git a/i18n/languages/wp-members-ca_CA.po b/i18n/languages/wp-members-ca_CA.po index 7322c401..043c0993 100644 --- a/i18n/languages/wp-members-ca_CA.po +++ b/i18n/languages/wp-members-ca_CA.po @@ -4,8 +4,8 @@ msgid "" msgstr "" "Project-Id-Version: WP-Members 3.2.6\n" "Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2020-05-22 17:48-0400\n" -"PO-Revision-Date: 2020-05-22 17:49-0400\n" +"POT-Creation-Date: 2022-01-06 15:20-0500\n" +"PO-Revision-Date: 2022-01-06 15:21-0500\n" "Last-Translator: \n" "Language-Team: \n" "Language: ca_CA\n" @@ -14,122 +14,131 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "X-Poedit-KeywordsList: __;_e\n" "X-Poedit-Basepath: .\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-SearchPath-0: /home/aure/raid/www/wordpress_31RC2_coitcv/wp-content/" "plugins/wp-members\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "Assumpte" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "Cos" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "Opcions" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "Camps" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "Diàlegs" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "Emails" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "Nou registre" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "Registre complet" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "El seu registre ha estat aprovat" -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "Contrasenya reiniciada" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "Notificació de l'administrador" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Les entrades (o pàgines) bloquejades mostren sempre el formulari " "d'identificació/registre" -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "El nom d'usuari ja està en ús" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "L'email ja està registrat" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "Registre complet" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "Actualitza l'usuari" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "Les contrasenyes no coincideixen" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "Canvi de contrasenya" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "L'usuari o email no existeixen quan intentem restablir la contrasenya " "oblidada " -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "Contrasenya restablerta" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "Preferències" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -msgid "Block" -msgstr "Bloquejar" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -138,12 +147,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -152,14 +161,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -184,266 +198,286 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "Exportar" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 msgid "Export All Users" msgstr "Exportar tots els usuaris" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "Subscripció" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" -msgstr "" - -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" msgstr "" -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "Activa?" - -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "Expira" - -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "Registrat" - -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "IP" - -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "Expira" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 msgid "Pages" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -451,57 +485,107 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "Activa?" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "Registrat" + +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "IP" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -682,147 +766,132 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "Gestionar les opcions de reCAPTCHA" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA és un servei gratuit i accessible que ajuda als registres digitals " -"mentre bloqueja el spam del seu blog." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" -msgstr "" -"reCAPTCHA pregunta als usuaris una clau de dues paraules mostrades en una " -"imatge com a prova de que som humans. Això verifica que no som robots de " -"spam inscrivint-nos automàticament. Així s'aconseguirà menys spam i més " -"exactitud en els registres. Tothom hi guanya! Per a més informació, visiteu " -"el %s lloc web de reCAPTCHA %s" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "Claus de reCAPTCHA" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"reCAPTCHA requereix una clau d'encriptació pública y privada. Pot apuntar-se " -"per %s per aconseguir claus gratuïtes%s." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "Clau pública" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "Clau privada" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "Escull el tema" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "Vermell" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "Blanc" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "Negre cristall" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "Clar" +msgid "reCAPTCHA Keys" +msgstr "Claus de reCAPTCHA" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 -msgid "Characters for image" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 -msgid "Number of characters" +msgid "Characters for image" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +msgid "Number of characters" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 msgid "Image type" msgstr "Tipus d'Imatge" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 msgid "Update CAPTCHA Settings" msgstr "Actualizar configuració de CAPTCHA" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 msgid "CAPTCHA was updated for WP-Members" msgstr "CAPTCHA s'ha actualitzat per WP-Members" @@ -888,8 +957,8 @@ msgstr "Configureu una adreça de correu electrònic personalitzada" #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "(opcional)" @@ -897,20 +966,24 @@ msgstr "(opcional)" msgid "Set a custom email name" msgstr "Establiu un nom de correu electrònic personalitzat" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "Signatura email" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "Actualizar emails" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "Els emails de WP-Members s'han actualitzat" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -926,252 +999,269 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "(requerit)" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Edit Field" msgstr "Edita Camp" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Add a Field" msgstr "Afegir un camp" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "Etiqueta del camp" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Tipus de camp" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "text" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "àrea de text" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "checkbox" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "Contrasenya " -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Mostrar?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "Obligatori?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 msgid "Checked by default?" msgstr "Marcada per defecte?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 msgid "Stored value if checked:" msgstr "Valor emmagatzemat si s'activa:" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "Les opcions han de ser Option Name|option_value," -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "Per a més informació visita la pàgina del plugin " -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 msgid "Add Field" msgstr "afegir camp" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 msgid "Registration Date" msgstr "Data de Registre" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -msgid "Active" -msgstr "Activar" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 msgid "Registration IP" msgstr "Adreça IP" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "Gestionar camps" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "Els camps dels WP-Members s'han actualitzat" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2216,9 +2406,78 @@ msgid "Chad Butler" msgstr "" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" +msgid "https://butlerblog.com/" msgstr "" +#~ msgid "Block" +#~ msgstr "Bloquejar" + +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "Gestionar les opcions de reCAPTCHA" + +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "" +#~ "reCAPTCHA és un servei gratuit i accessible que ajuda als registres " +#~ "digitals mentre bloqueja el spam del seu blog." + +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA pregunta als usuaris una clau de dues paraules mostrades en una " +#~ "imatge com a prova de que som humans. Això verifica que no som robots de " +#~ "spam inscrivint-nos automàticament. Així s'aconseguirà menys spam i més " +#~ "exactitud en els registres. Tothom hi guanya! Per a més informació, " +#~ "visiteu el %s lloc web de reCAPTCHA %s" + +#, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "reCAPTCHA requereix una clau d'encriptació pública y privada. Pot apuntar-" +#~ "se per %s per aconseguir claus gratuïtes%s." + +#~ msgid "Public Key" +#~ msgstr "Clau pública" + +#~ msgid "Private Key" +#~ msgstr "Clau privada" + +#~ msgid "Choose Theme" +#~ msgstr "Escull el tema" + +#~ msgid "Red" +#~ msgstr "Vermell" + +#~ msgid "White" +#~ msgstr "Blanc" + +#~ msgid "Black Glass" +#~ msgstr "Negre cristall" + +#~ msgid "Clean" +#~ msgstr "Clar" + +#~ msgid "Active" +#~ msgstr "Activar" + +#~ msgid "Enable CAPTCHA" +#~ msgstr "Permetre CAPTCHA" + +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "" +#~ "Les contrasenyes no coincideixen

    Siusplau intenta-ho de nou." + +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "El nom d'usuari o email no existeixen en la nostra base de dades." + #~ msgid "Click to log out." #~ msgstr "Prem aquí per desconnectar-te" diff --git a/i18n/languages/wp-members-da_DK.mo b/i18n/languages/wp-members-da_DK.mo index b88b35c00f1011ae7023ec246d6aa623cb4fccd6..46fc10798d7ec4f36be7557098876c753f59339c 100644 GIT binary patch delta 4095 zcmY+_2~bs40LJn25D?s0R6tyMnk$F`Dw3$Ufhk3jOKwS^Pel!tO)>MjWR?piPfaDQ zY_X^?dD&RjWVTG{G^N&5Q(0z>){LW8GZs_U|9kgX(;dF|JLj%vyO*Xdp3AG8v$3H& z4BKJSiM$(T%vD^}k{`CzC}Scq&6XhJn4l$|=Bh>6$@)$?Jf2j!yfn}<5T z5E)!ki5kKCFpB4!jTCg^9t_6@)CGsFCs7YNXOI7cYUmZzEP1$CQ_&iAeS)puWa~+& z^V3lG8HGtW9-R;hl@#cdS&kZ-jhKP^Q9b?=8}K~p0k!SiDcOzL)DK`QykPhLhU#Gm zy--JD_)!CT*?K1GzWMDLe>Gq#J9^;^)Q#4mTKWhk<1W2m`1Fe1y8-4^+z|xVvr~ zi`t)zIXDEhSXZOgL=Ez1p65poejB^s2^^05gf z)#G}kE#@fdhNn^2U&SnJPwO?J1*o^68Z+^T-G3GPP|dSkAa44 zT4#687o!?dg|ykML-o84)#G~92p+NfKd|-Bk#%Y=pcZQrY9zvGHEYf>Q5167(G_)I zKK8_=sHxe7`Y=6(n&V^0pZU)EH+rde;h?4}8@0L@qDF8hYUK8z8onPja}E#evF*bIMTPiS_8!tnIKnUPV3deN;ofLCw+c zs0YXPcOTRVTT)L(jlf`}4Q3qb`emrsv&J5O0b5gl6E#IAF$&LNo>t9O3R=a(Qr!zYc9E-zg0KWyj!`oU1zlPYjJ;e!^ObM1amKWrNM8=KaR z7TZ9wh#VlXq>}U_+8!r+$#`-r36Q7A!$h0@{{-jh0V+&saAQrGEkv)5=8U&8_(AH5 zAtaw{AhXCw(vdV0ZOw?@m=)w6Qb-;nOn>l=fd6d^HII6ym)PB7v4)HzJqYX2j3C-x zAe(|E_d_+xmc?D(ochb{0X8$X#uHjcn*X*GN=QpGg*->rk%Od+ zOeFV`dZKMIi4K-E!im~jEt|pI=TvBcr?>-c?Z6(i;2=X-1 zHioPZmfR1Nim#Abl0>$XH6+r%Cc4(27}MxK8?!B{$UC{*S5{hdug{Dwsi+QYi!Jf^ zhqjv%c(Pq?NMrm+kH01%AyA(%ATn^i>nCCUANs6~PEScqOG(Y}rVSdBPGL}>Dk;~~ zY+%0u{?t+V|}GX3oA;hd}TiG p9A9av&s$tpInP&?9hf`tugJjs;RWH*lY9%yD@^cru5VF=`3L^bs0#o9 delta 6038 zcmeI#X?RrC9mnyL5LQ7#kOWr_VMh`I$i61X4iXjxL<=`Fm&tV|bHmIeF-RFVTq?K_ zx7xb2QdFua1Qn`Pk)kcMPwi8wZPh-H*eduuwmjB8T3SoLzqvPnFZ!l$+xz&R&pCHH z=lst(H~5zgCpPD0|4>wLpW!$_TtHmf!I+MD#w5DxtTDG08q*nX4{gD-sXvTe@afPO zaS-*_u@ioRJ@K#M^^QG^;nk)HJL0)mY)sblrJx4Jg;rq^_4#-%uEO)N8N1=BBiJ3=^HO!F7f!(;*p>E8Ed}l|4X6iiMZIVfmf#kor)E3q z1^bXenZvjqKSGTt!bOTEjvCMgR7Y<^U4I16!)>Sx?ZX1vHwP*3pZO&}df-E>#J{6D zGVz=s<&~(BRHN=+jY??-_1tx+sktYtKZa`f1=M}7pgMj4m9gJoR&#hHyx~(+{qwMX z67@g_-mVvw;85&?`8XGqxdo_9t->+bgv!7U+<|*g9f*-eO<@wJ;`(CpuXXlvc;RQL z5xj%F@gw9}a}w2&UbLe6KvV;hP#u|xgK!S&eQQx2-hdb5EvQWHLZyBWs-1l$=k-HGjRE2@DfQ4Q=w-S--5>JA}eG4G-l z_h(rO>S0%EdSD!CWV4VI+l8k|AB8I{6UQH$vpsE!^*HLQ~tL1&zcgK;FLu^(;kS=TRei9hH&aqegrTmBKH=^BrwaFGg*Gr|OLzcZ#VxpzVJic@nKv!kzL?cqkEPH7XQOUdi1TncY6`aE z%sgXSF-iTzU}M&y#{?JPA5qU8!>_pSGwewHIO)=qe2IEb0i%;WQBz$yjQo=wGn^B8 zU=gZkD^T0U56`a)>o=lOx*65r*3f5A19<`229hwhN@A(S#-cDt~nz#r%Q?Do^ z{~GxOPUyx;RI2A=H>?lOZ@{_KZ^y3qHtG}n0qO(vH&n{ML^b?RWaF6Lwf{Gv|C8!4ahV`MSlwX3H%X#7XWvI+KsE*g78m`B)u`#^9 z5w(~%p)&O*szV2n3}wxG6sB?F3)Gy98)3{FScR&09vRGSPt*sdKWeJ3#v-gmrTV(i z`%xp^iR$~+{)Oe5jQmkSk4KVx%R zcwK*)x=}Ae&8bCoa174FnOKNhun#_tS~L4Gs|VksFcd#QJy8wx}s&f_1}Wtj8$6 z%?IT$PQmT0q+Xmq#@p1Plc)i7m=t_+&q0lJ7%G#KQJI(@)~`Z69}m4@67#PVKfno% z=qc=pyYVvoDQY*AOb-6qS=4>Au{SP3iwV?-H-|or{iz>9mVr5rB*pZf60D__s7yw( z6tpdBu>|9&RNjQ@z(aU19zzc|ObxcvQCvd3-!#5r*o2qjlXyOUihTA>=gMFzhoeLN zN?e35V>M>at_p5kg-Yp0JcOI@`?!31kjj6cM%;x~&cS}DMLQ0)JF0LM&PAnuJL+%7 zUQANg-{5uNqjuFN$n#lqoC5cm9}^c5I&_25rQ=CrYp%rC4!=dD2xcyKXu*~fD~Vl1 zn$VZ8?bt*?BmGWzLZkm-SkArW6)Kh(NNBEGi5m!|`#xd@@icMfaXA(3;m5<1*C1;+ zx4ksl?ZksbgwVlG%^f#}iZ1%mD3oR$B;wR@+o@9Uj|HVvD_I9?$$XROKxnluBQzCl zho<9IVl|<~cR$f~tf6oZ!NxqR#6QS*^1zAsANjy(HLX0CWCW?rwh#kabLkc!^j}==g4cc@%#@+(Hx(XAy13Pbl0?lqvr%g%#nIsi9ZnO+-ytZ^jFW zEyT;j?ZgOTIPnm1=5aHXJBT5~G-3`>N%+JI#EZlM;sRni?dOhCes_jt@i1{|Sbri^ z>?2+$idEq#A$kyli1~z$b;Rae>GaRD6kCWrL_6X+;tC?Wm!C;QPvU!ojt2sA|E~Ww z<;RHG#J$8SqJd~T`cv57R>AQ^oVYGLmk50d^{Lj;i&#sXAN(IW|1&}58Db;x8WAJ5 z5gUjJEkn9*X&=dWjc&`{?z;;UP9$z;C7g8HR3-dKyd_@PQo6L(t#i%vTHjB**0GnT z-Bi-i886dprYBq{+1jm#mp9GJ)Ve9lk8KEVv3|p4Jn&)BYrBHE^o;cE$^0eY7(xUURk|#`s~WqgGICRyE{oI=5klt$xglI<+YR+ zmnhpH{?5Xywla8lt#ILJ!lNmRawi%z!WSZ-FzR9;u>bp%x zoMh6C+BGS^jvUqaeq8s}r~F1W<7AW(_2dX33Ic z)AdeW4W*`9kE}R}v`FWHk3IUFTLVrmYi+G^9vLqS;2hn3wUg>llrO!CPj~$>thA+H9M=WV)}N z$+Sk@4D*^EW*fb&rVFXgUn@K|;X*j850v2nL~82L-4 zS$uk!TsgM1KDRVVb6HU}ST&bmzxK)BnI4E zSW#9nx@_b~J7VmF(Id(#F4;A3W?s8d~=P)ezIBYfPG|W|nHQb>)zzyoskzTQ`wl@6FI&D|2#N z&9!b^19eke@ZxdTdN%50oEmmXvb^P2LzfjTXh?Xm*#12%%C@~V=;G`1&#R2qc}X7C zlc#6z3MUb3-Bz|ZFFMbUx~zIPNgLt2-DLXfyD_zYPowo>H1(hM;Vd`l1nF>DP3#_9 zlN%;`asQrZYmebybuO6Q=tWz*jbGg1|J(6@dppkfFScXaEM*I1g5Nc6B4hpyFN^_Z diff --git a/i18n/languages/wp-members-da_DK.po b/i18n/languages/wp-members-da_DK.po index d0fab864..76a1ed41 100644 --- a/i18n/languages/wp-members-da_DK.po +++ b/i18n/languages/wp-members-da_DK.po @@ -4,8 +4,8 @@ msgid "" msgstr "" "Project-Id-Version: WP-Members 3.2.6\n" "Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2020-05-22 17:48-0400\n" -"PO-Revision-Date: 2020-05-22 17:51-0400\n" +"POT-Creation-Date: 2022-01-06 15:20-0500\n" +"PO-Revision-Date: 2022-01-06 15:21-0500\n" "Last-Translator: Chad Butler \n" "Language-Team: mikael.boldt@mail.dk\n" "Language: da_DK\n" @@ -15,118 +15,127 @@ msgstr "" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-KeywordsList: __;_e;_c\n" "X-Poedit-Basepath: D:/downloads/wp-members\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" "X-Poedit-SearchPath-0: D:/downloads/wp-members\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "Emne" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "Brødtekst" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "Valg" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "Felter" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "Dialog" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "Email" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "Ny Bruger Registrering" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "Registrering fuldført" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "Din registrering er godkendt" -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "Kodeord Nulstillet" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "Admin Meddelelse" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Vises over Log på / Registrering på Post eller Side med begrænset adgang" -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "Brugernavn er taget" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "Email er registreret" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "Registrering fuldført - afventer godkendelse" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "Bruger opdatering" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "Kodeordene er ikke ens" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "Ændret Kodeord" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "Brugernavn eller Email eksisterer ikke når glemt Kodeord forsøges nulstillet" -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "Nulstil Kodeord" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "Indstillinger" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -msgid "Block" -msgstr "Bloker" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -135,12 +144,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -149,14 +158,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -181,266 +195,286 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "Aktiver" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "Eksporter" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 msgid "Export All Users" msgstr "Eksporter Alle Brugere" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "Abonnement" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" -msgstr "Nej" - -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" -msgstr "Brugernavn" - -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "Aktiveret?" - -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "Udløber" - -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "Registreret" - -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "IP" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" +msgstr "" -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" -msgstr "Ja" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" +msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "Udløber" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "Ja" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 msgid "Pages" msgstr "Sider" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -448,57 +482,107 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "Nej" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "Brugernavn" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "Aktiveret?" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "Registreret" + +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "IP" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -681,147 +765,132 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "Administrer reCAPTCHA Valg" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" -msgstr "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "reCAPTCHA Keys" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "Public Key" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "Private Key" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "Choose Theme" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "Rød" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "Hvid" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "Sort Glas" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "Ren" +msgid "reCAPTCHA Keys" +msgstr "reCAPTCHA Keys" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 -msgid "Characters for image" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 -msgid "Number of characters" +msgid "Characters for image" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +msgid "Number of characters" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 msgid "Image type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 msgid "Update CAPTCHA Settings" msgstr "Update CAPTCHA Settings" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 msgid "CAPTCHA was updated for WP-Members" msgstr "CAPTCHA er opdateret for WP-Members" @@ -887,8 +956,8 @@ msgstr "Indsæt en gyldig Email-adresse" #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "(obligatorisk)" @@ -896,20 +965,24 @@ msgstr "(obligatorisk)" msgid "Set a custom email name" msgstr "Skriv dit email navn her" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "Email underskrift" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "Opdater Emails" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "WP-Members emails er opdateret" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -925,252 +998,269 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "(påkrævet)" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Edit Field" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Add a Field" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "Felt Etiket" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Felt Type" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "Tekst" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "Tekstfelt" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "Markeringsboks" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "Kodeord" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Vis?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "Obligatorisk?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 msgid "Checked by default?" msgstr "Markering?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 msgid "Stored value if checked:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "Valg skal skrives Valg Navn|valg_værdi," -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "Besøg Plugin Site for mere information" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 msgid "Add Field" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 msgid "Registration Date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -msgid "Active" -msgstr "Aktiver" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 msgid "Registration IP" msgstr "IP @ registration" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "Administrer Felter" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "WP-Members felter er opdateret" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2211,9 +2402,77 @@ msgid "Chad Butler" msgstr "" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" +msgid "https://butlerblog.com/" msgstr "" +#~ msgid "Block" +#~ msgstr "Bloker" + +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "Administrer reCAPTCHA Valg" + +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." + +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" + +#, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" + +#~ msgid "Public Key" +#~ msgstr "Public Key" + +#~ msgid "Private Key" +#~ msgstr "Private Key" + +#~ msgid "Choose Theme" +#~ msgstr "Choose Theme" + +#~ msgid "Red" +#~ msgstr "Rød" + +#~ msgid "White" +#~ msgstr "Hvid" + +#~ msgid "Black Glass" +#~ msgstr "Sort Glas" + +#~ msgid "Clean" +#~ msgstr "Ren" + +#~ msgid "Active" +#~ msgstr "Aktiver" + +#~ msgid "Enable CAPTCHA" +#~ msgstr "Muliggøre CAPTCHA" + +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "Kodeordene er ikke ens.

    Prøv igen." + +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "Brugernavn eller Email-adresse eksisterer ikke i databasen." + #~ msgid "Click to log out." #~ msgstr "Klik for at logge ud." diff --git a/i18n/languages/wp-members-fi.mo b/i18n/languages/wp-members-fi.mo index a9b21c92feb81d4022c65cd5aaf575857bc1ed29..77a991c4c33b1b9a2fb481ca8acf80dd50931905 100644 GIT binary patch delta 3463 zcmZA32~d_r9LMo}K?PBH0U-}OP!Ld#IK%{RO+rz?Oi|M`QVA9BBMp5O1&{KGN6Z;1 zEvHGHQFGp=GHX0KG#g8k#w@QXZFJIcrm;M7roO-TU1pee{J)=l_IciYcK^Hk;?`wH zXLzneG^sU|?L-ISQWIm&V_kDTC^uUg6N0y__b{02f3Y}7tr5z8f#%O#C`DYIE5rro)94}*6yo>5MBGec+cEbLcih8abnS=3Q z8(f1LKpkqpUJS#NSi$?vPgFGGG4!SxOhUc56xF^Q+hY}K=DScG?L|HJIX1=fw*8`Q zzhe#LZR)2THp4Ec0VML#g7=$jDoXKC)B{EKy4YTqApcAmAL?is_P|OE!2PJ1e}J0t z3G9VGqb3y2%>x*X>i;y7L~{;31E^f3!g89Wkx1nJGcCY06P+xg7Pq zt*C+QMtyI;ZT}jFa{VK!pXf;T3C7`Y9D*6RDU$rhQaMh8*6;>u27h26K0v+jF{*>s zq(jeVU>_Wdnt2Us6Ml-l@ga7{48FVsC*o3gvncYQJ&pg0f3}L6LeH1El6Hv!`8Y<@tDtBlJPyv!5>gBZq?DBu^!ls>jEsqg;=EX|0R`C zG(<5hs-_h6!Yb5E)}vBYgW5cMP#HUH?;pc_uD?NLEQ)FB{Kuib-yKJi@(k4GUK!)h z^d=0_`QJf>NtoTJlpRIA=rpQ>U+ndDRO(Y#URJ+NAHG zW_SoSfMeEEs3kj#TFMKke(uDP|3oT((-452*&&)ySER}0U=~hBeW4cj;@hYJ<;D9q z*92rUnH8uBe2=>StMwjgpv^d|T9PhEl1)|u>#qlkY0v=5@M)ZdTGKm ze+{){e_bYJ!_lKUnX3sHmf3sI@+aTBFOTls>}Q7{afK z2C@{Hj9HC3M*DCeKCZqEeTMY;=>4O8soqT5dy4;1gsn<`R-T6O``Ha2hHjgHY{x zI85h%p0C1REqsw1O*8x%Da9PF>rk8V0_ug2QJXR@)0pRQ0*=FjScJi(Qv)53EpQ$N z<8sshtL^=LYUlmtgni&!%;mZs!!eq-Xv8TPf<2Lp`-%ptb$yf2vnnwJtKl2eB5WuV zsBEzpjNLaVo&UasXC)sFv5Xi&s7xa^5K7Y=qM`Jo5=hkA2F+4y+)!3g8AWK{%&?8x zWQ|KP7dj!&6AQHd>+Rh>*4C&$DD#LYVk5zE_Z6j2ry-1(N-QSWCT1bAooGU+RQvJ$ zf!a)cvb|O|^NERsj$g9Yzc&>!?klhJx!TtC6TFQWLJTF?t-iv(@|C%K4k99mazdM~ zq0F?EH>@={ns}C&PmCc{)@c2;%bODeiN+<8i)_Me8z1Jx2<>tmv1f>N#7Lr)c!ek(4re*gC_5IWN{`QGoGbI5Du)8J7!2$~_roC*fRQ{V)s1LwkOcwRbo zA%A8UKa1fWI1v6AYTsel6TS(t(Hw=NOu?8x(vfDBL(3LbLHQU#^Rv~;`#>io@6itHGH|0mOFU_uA( zgVOjOC|5oRb?`x`gPw+C;fv|~`%nga26gdJ+&2eKf%4SlP@c)c9B&XE6gz-*`u8{s){H{IUOhh+Rq=Xc@ zgHRVg2|2<%4`tx1P=*(drk%e+xvVFTfGisdl_XVg1w1>Q&q2BLO30tNfggqB0F)tJ zDc^>cam5+zh1F0=xDG1Bd5C8UW)B^?;8gfaxDfswa)+7C z?eg3PI1wiBB6uHM4?ln#;3A8=;cZa&Jr4V-{-2~HmpucOWG_R-<_MGvKZWwhzu_9# zXI$BZ8{vuyW9nhR{6Su$b~qYs^w1Qc_T2+7WZgqhRrKcx<&gXf_ThfhAGPtm83yIr zI;iAZ0Hx3}sDn18<4d7J6+o?Thl=s_Q0LqM<;f=?cbFF-m1#bJdSU+ql>=3i@V^eI zp(EGMf;xBy)Wtr$1YQlL`LCf4cnfOX=TM6EAyXBKp->mrrsIpD6ba$|@J84JPN*s8 zKurz)S4^fep@Y^z9kd0?q8L)zW>3ny;e5uALEa{F6zalHA?aXFr!;ioIZ(;F5%z^H z)WreRQ=Nm#{#&Quf4SlTCi=j~Q+^-zX8c2_+~|Tj=yk|l=544KYyc^(3kO3fG6~Ls zYoONefd}EuPzudHyPT{mppvt>Ku4B52esg(lt-XE@iCOfLx_)Jcornz%wnkZJD?QF z!Si7Pl>^Vhe(*IYMUFtNe;+EepF^Ty3Il6X&7dw?k)&A8$dq{4+Qf_9roRz_Xyv*$4Zp{)=?v zy8Vzh#2kW(&FfIHu9#c4U_2y`%t}}Tb8slU56Xj&LwV*<`u%x$0poX5PM>Ft!?+!y zlleU?ETnS^fmZgeg}Qhb+yq~STj7KS<*dCLO5vBFV*4(XhdzdK_2=pLu^c{< z@jR&S>r!rkD;V!si2voHN0^w4%b$VQG5+Wr{!xUU7bT9(mjVPgRN3KDXWLuE#?I8wZ zkyXeTnWSzV&q|@9yt%0hp4Hh z6J)6dX*(ZYfqWBjkPuPxkZTc@=~c)+-Tw_bD-pFvkStO}mLYA(#YhezsZ0N0^njBP zRmOt|4_>LvM#GDc3CRDp`h|EontXD(qwYkMfgI*kPp6@hd?MmN?qT+{xZs@hC$!&3q{@^h^Tqo$< zJ9tCI5-)CYbCw^QL~br{T3j3EtlQ#vzI8I0oEt?p6WSn*t$T$R#nuaKnB;8EZ3uIj zsIK_RkeP!5r`~t%vZd=cEnBs;vvTOF${|kRG`g%hHo0V2RYh^h@X_-Z)#vQA#pU1i zzUxG;jdOYHG&){TXV&MuHYaxN8aHp&C-uJ9Q0iXnW;(YH@7uR>OH=3e(=P2XvMG*R z7fzd2pTxeKtM|jkx`wc2TJh;K{lf7(trKM<%Y2I)#BMIKafm{3zLgtyhjzF0w^4%= z1a8Le%!Mu1vGrk?)wl^LBbJr=GMZDBvl_ zMy*auJ-yvc9-eXhC`6GQPK&*uvE*(iiNh8r#z3hM*>I-~{Y*)LsLpN-Z9YtFqZ?aa zA<%hKtrKKQdr_UGe2lEq(2(Ttn4h;9uhEOWLOa&T3{F{&lKJ{DlefFQAR1>^5Za6z z6WeI2ZSx|pWSyNDod}fO?bb8zPK?Y6M`Esnhg=sG8XC~Y>lSZI-n4lQskfR6uHRa6 zby=Nux2#O+2}0G7l?!B$4Fg%3v!wubyD#VNN<2~zgYDAw7uc+upNjv2hy>JTeC62c z)>3{{m%O53Idx`LYk8gBhWl`=jl9OdCarcSwmULac676s#S@FwW3L-Jy>|MX+L<%$ zjCl*^%&MI}yLf2q&w9+Nn^F9-UE6PImZA#1I4Qnp-|c^462*?Cti0kA;|}(UUFxN{ zu6lCs^+{94i#l`F`zuDS>FUVGaaTukS4W%#L1|0u6u&oR#Ne3Su4nzOL-|a;t~g}E z)=?KRl`Zc$)O9F0UQ9bDJXm?!D#!P|m`XVj66z*SvXR%>b8=Ww+*&hcWnK5m+LrUU z+9pZHMOBj4Y-4ep_X0PtP8+pmRwq7@I6hpT1kAcYXRhYuzWp{kel{!(m&~~K|CZZN zW_K^Q)_k5jxiwoZxzKC&Fv`m{4hIHJVKcXvOi-t+r`*oh(93XB!5%B*NE3B- zZQ@!ta9disI)alcD;vg?TwCH}-bv*pbI`05jP$*<5$})hC)8j4sN$!uzfjG(j7z4^S=Yvwkd1%wE=-M1!BTw~Ks|4ZEOz+NycrZz9b+a;t z5X4Tk#ZT3F9C0~0rKzqC3bC|}&vkY)A-A#TJJ_ns^?Aj-vXv2fob=+Px5+25n6ch diff --git a/i18n/languages/wp-members-fi.po b/i18n/languages/wp-members-fi.po index 5ad7879b..7fa1b0fa 100644 --- a/i18n/languages/wp-members-fi.po +++ b/i18n/languages/wp-members-fi.po @@ -4,126 +4,135 @@ msgid "" msgstr "" "Project-Id-Version: WP-Members 3.2.6\n" "Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2020-05-22 17:48-0400\n" -"PO-Revision-Date: 2020-05-22 17:53-0400\n" +"POT-Creation-Date: 2022-01-06 15:20-0500\n" +"PO-Revision-Date: 2022-01-06 15:21-0500\n" "Last-Translator: \n" "Language-Team: Suomentaja \n" "Language: fi_FI\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "Asetukset" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "Kentät" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "Dialogit" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "Uusi rekisteröinti" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "Salasanan nollaus" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "Ilmoita pääkäyttäjälle" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Suojattu sisältö (artikkeli tai sivu), näkyy sisäänkirjautumis ja " "rekisteröitymislomakkeen yläpuolella." -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "Käyttäjätunnus on jo varattu" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "Sähköpostiosoite on jo käytössä" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "Rekisteröinti on valmis" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "Käyttäjän päivitys" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "Salasanat eivät täsmää" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "Salasana vaihtuu" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "Unohtunutta salasanaa yritettiin nollata väärällä käyttäjätunnuksella tai " "sähköpostilla" -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "Salasanan nollaus" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "Asetukset" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -msgid "Block" +msgid "Restrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 @@ -133,12 +142,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -147,14 +156,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -180,267 +194,287 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "Aktivoi" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "Vie" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 msgid "Export All Users" msgstr "viedä kaikki käyttäjät" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "Tilaus" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" -msgstr "Ei" - -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" -msgstr "Käyttäjätunnus" - -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "Aktivoitu?" - -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "Vanhenee" - -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "Rekisteröity" - -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "IP" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" +msgstr "" -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" -msgstr "Kyllä" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" +msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "Vanhenee" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "Kyllä" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 #, fuzzy msgid "Pages" msgstr "Estä sivujen näkyvyys oletusarvoisesti" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -448,57 +482,107 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "Ei" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "Käyttäjätunnus" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "Aktivoitu?" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "Rekisteröity" + +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "IP" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -667,146 +751,132 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "Hallitse reCAPTCHA asetuksia" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA on ilmainen CAPTCHA sovellus, joka auttaa kirjojen digitoinnissa " -"samalla kun se estää roskapostitusten pääsyn blogiisi" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" -msgstr "" -"reCAPTCHA pyytää kommentoijia kirjoittamaan kaksi sanaa, jotka on skannattu " -"kirjasta todistaakseen että kysessä on ihminen. Tällä varmistetaan että " -"roskapostitusohjelmat eivät pääse kommentoimaan ja samalla vanhojen kirjojen " -"skannauksia voidaan automatisoida. Lue enemmän %s reCAPTCHA kotisivulta %s" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "reCAPTCHA avaimet" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"reCAPTCHA vaatii API-avaimen, joka koostuu \"julkisesta\" ja \"yksityisestä" -"\" avaimesta. Voit tilata itsellesi ilmaisen %s reCAPTCHA avaimen %s" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "Julkinen avain" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "Yksityinen avain" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "Valitse teema" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "Punainen" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "Valkoinen" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "Musta lasi" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "Puhdista" +msgid "reCAPTCHA Keys" +msgstr "reCAPTCHA avaimet" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 -msgid "Characters for image" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 -msgid "Number of characters" +msgid "Characters for image" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +msgid "Number of characters" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 msgid "Image type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 msgid "Update CAPTCHA Settings" msgstr "Päivitä CAPTCHA asetukset" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 msgid "CAPTCHA was updated for WP-Members" msgstr "CAPTCHA on päivitetty WP-Members:iä varten" @@ -872,8 +942,8 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "(valinnainen)" @@ -881,20 +951,24 @@ msgstr "(valinnainen)" msgid "Set a custom email name" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "WP-Members sähköpostit on päivitetty" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -910,252 +984,269 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "(rakollinen)" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Edit Field" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Add a Field" msgstr "Lisätä Kentän" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "Kentän otsikko" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Kentän tyyppi" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "teksti" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "Tekstialue" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "rastitus" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "Salasana" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Näkyvissä?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "Pakollinen?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 msgid "Checked by default?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 msgid "Stored value if checked:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 msgid "Add Field" msgstr "Lisätä Kentän" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 msgid "Registration Date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -msgid "Active" -msgstr "Aktivoitu" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 msgid "Registration IP" msgstr "IP @ rekisteröinnissä" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "Hallitse kenttiä" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "WP-Members kentät on päivitetty" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2197,8 +2389,77 @@ msgid "Chad Butler" msgstr "Chad Butler" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" -msgstr "http://butlerblog.com/" +msgid "https://butlerblog.com/" +msgstr "" + +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "Hallitse reCAPTCHA asetuksia" + +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "" +#~ "reCAPTCHA on ilmainen CAPTCHA sovellus, joka auttaa kirjojen " +#~ "digitoinnissa samalla kun se estää roskapostitusten pääsyn blogiisi" + +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA pyytää kommentoijia kirjoittamaan kaksi sanaa, jotka on " +#~ "skannattu kirjasta todistaakseen että kysessä on ihminen. Tällä " +#~ "varmistetaan että roskapostitusohjelmat eivät pääse kommentoimaan ja " +#~ "samalla vanhojen kirjojen skannauksia voidaan automatisoida. Lue enemmän " +#~ "%s reCAPTCHA kotisivulta %s" + +#, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "reCAPTCHA vaatii API-avaimen, joka koostuu \"julkisesta\" ja " +#~ "\"yksityisestä\" avaimesta. Voit tilata itsellesi ilmaisen %s reCAPTCHA " +#~ "avaimen %s" + +#~ msgid "Public Key" +#~ msgstr "Julkinen avain" + +#~ msgid "Private Key" +#~ msgstr "Yksityinen avain" + +#~ msgid "Choose Theme" +#~ msgstr "Valitse teema" + +#~ msgid "Red" +#~ msgstr "Punainen" + +#~ msgid "White" +#~ msgstr "Valkoinen" + +#~ msgid "Black Glass" +#~ msgstr "Musta lasi" + +#~ msgid "Clean" +#~ msgstr "Puhdista" + +#~ msgid "Active" +#~ msgstr "Aktivoitu" + +#~ msgid "Enable CAPTCHA" +#~ msgstr "Ota käyttöön CAPTCHA" + +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "Salasanat eivät täsmää.

    Yritä uudestaan." + +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "Käyttäjätunnusta tai sähköpostiosoitetta ei löydy." + +#~ msgid "http://butlerblog.com/" +#~ msgstr "http://butlerblog.com/" #~ msgid "Click to log out." #~ msgstr "Ilmoittaa lähtevänsä." diff --git a/i18n/languages/wp-members-he_IL.mo b/i18n/languages/wp-members-he_IL.mo index 597e8ec876d38171df14ae219de8108b0469b037..f55cedcf134dda6331d4ecb38ec07dc657933ef7 100644 GIT binary patch delta 5802 zcmYk=30PKD9>?+Xf*^{!B!Z#{iXx(*qJk^pzTpxjnT)uUYnqy6i?^99ZJKd=#TLs- zO~+g+-^|LI94AwBN+>I|G_k@`QHRD%r*ghO&Uv3_?&FWoIrn|>!_H6L{;#n%`!6_u#;){zO^j)a z-H=_T0DI#?jKbZ>r95+pMq_rApicB1>Oz+>60alwOjxwt-`tsmjo6=tF_?qRa3ZGQ zV$|`k;1GNR>*5X6_amBWV4g7vG#av_2kJt@FaZluCs>O0aTRLhFQEp!2m4?#>i7uG zS_5NIH_{ThmT8YVZ+~Y#>iBusfa{y3G&Hgz?Z8c_3%!XCV=>mmL9xap;V9Gv??Y8! z8LDE>p-R0O_5F8|f93!`D786-I=%um(7Ke%(?}c9(1_wtCrHOI9E=*+NYombfU3ky z)b}66a9n{puE@C^HGqG(&x=tvR)V^4IjXW1&8WWyQ02b(8>(M}m8cWfN2+U@pzg2} zW?&|E#JQ*wZ*abby6}F~@rO|tJcjM@IELU&R0TugsK4eYDvp(k9Z)Bnf*Qy|)E#@M z0jxyL<+IM$aTonVs0%J?VJr3s_ND(6>Q0Yh9sJUL{vE2KRUQqM&ezgjFd8+01l0a6 zs0$B8onRd54kn@QYznr;>F)DYsI~I~QcSZOb*G=8Dsu)?@CVcsdr|Rram1oVl!zKY zXXHC32ep3+GFCGmRk78mso93QzyZ{NkE1?6k6Lsgt?coUsEWp-zTXC^tY^B@P)P?P z3*8i;M)&}#bemBFcpX)V4^S5_MxF4i`@9kd(*G58f&K~BTT$P;3$>W1 zj)q3M+kIglYR-#M13Te9zk(a-Uq@Bq`9$6oxDVT5cx$SLoseB-GOB`4ph~?3HSis% z0Ug9TT;G(?2*p#V(wCzyT!p$&tv2?A?XV~P5jYi>V-{AT)hJYRCAZs-mc<7IF0^D)S?TZ7S(>#+V`5=FREb}i4##3pOHfSHCOZ5F$kBUE_l>^p$r+cDaYCv(ZT+bYK$sv8mdC0 zopUjs{tDy}^BOWX^A*;_@Kie$^-xn0l}i0p`c!u4&eBn(ABq!j63)f(867*mW|3l+#Lnc8W_Z&2k8&Q zH5kdtQpq-;rfMrT!1pl>KfxM!9K-R1+keLOE3hH^E3rP_M4iv8-^I>JQyk8Y)~Gq0 zhgvKi>cDHL3)Jdr53Gl(Tr{o^;bnt$>F@1kk3WbS;BnMr`#ow3FFS8wFHUd5y4%&- zA2p{B;W%86TD_N12S&4`dGbsG>VyMP1Iu+5Iv1e6|2WpcRTzygppM^zS~F#ssptP1 z4IPl4$;$zIpFaC1 z-wd@DvM?Qoqi*bxzSLifW-~jq8h2w0+=n{hNz{d_P^&h)pZ#7F)M9LjDtT+vlw_g4 zUw|WUK5B|Sz-H*96OVDIHPk2DvnL$F4&BKZ9D)U?fo(;Veh+HIC76%bP!}H4-(K); z)SW+s8fXz}Dqlff9i|k^@g}OG5Dr564VWN>u9KSJ1_xDP;>PYs)RKLxyqnM zUVu7qhSS3i^ov~o0P3+V!z46=t!*)$?kH4c<|0$#ne{Yu;=QO7A3&{zGSo=RQ5Cq3 zDseRPBh!(Wm>G_$#1d5LSE1(iCDaYQiaPJd&Tlb~{&kGi^PfA^mT)HOM9WZ%=vmYW zcDm0?P-~(&*@kj zpT@Sh5mkXB7=dR|cX9zWK;KB)zXf&T6x4a{MwXRXhwJeqvOLV9QTFlMhquwML~kOE z0Sre6Zp1EFiZ5f>Xk#w=cnWYOu4Sd_j$7Yq-xE3b1pQppK)*mOvP+nPsnl8TmweO| z&O?1~1*(Eu@~FRd>}Q8oaT#hcUUgrLVVL#lr(-M3##uN8b=)yjWzJy+UO}BW>2~`^ zXg};u|31{fc49ZYh`Q0l@zh^$q}#{a-`h`OIQc986+<7T{XE z4{1A0xrB3f84V~y)=OxstzmBQc zywH9=3|r98Lk(mhHo^0F2z`_7amA<$Ttq!hSFs+}oWgf7xb>sKEZD#QwDSS-5y>VO zhz{1)i#$q-NgmO5g|sKl)nU_`(DZyoSi99v!*8fL{ww*O>?GR$ZE-*K{IOBB>aCog zw~&DCR{zv|YD)T(EhLm^dx?Y)okELr6-gl5$z$YwQbDv0Ag8KZ_Qwydy+{YIcAY);{VrTe?jP>93`E} zpGg@BZqEf9IG7wGbI1{rNVMsh{)Ajs$89Zx4dmf4H;A49ZGRz8k%5}L!!#O@dr2rI z*EW)*ka46I*-wJo-)USTF9vsDIN_yN{YT8dur6svmXl6o1JTo?Z7g}7d_nFA-v3!T z-AN?*l%$jCMBCfspX5Cm}WjBF(b$z1XwNhPhwMiSiaq45^^fV|*#dN0$c z={iAvagEc?Y0le%U%;Qpa59zbAaSG*nL#EIZ5_!7vVc5DhLH0_?~fJaNj*G6X=wYF zY$C%*6EcQqYfPf5Tl~L4{2RGO9wvH~2Djs`@d&<7a!3T3M~X;avY3n~d&phnK=s2* zV=qZ2!7ZLf8?rLE1AVNGdiXTClguaDmRQU?SV~?YX(WS;BHxfN$wMTcTqGyR@1(j^ zui~5Pxa}mKBOzSyYrIMdNfK#FW|D>ECh0)_L_Q|bq>^YmWHJ8fsl@wA%X0)(lCE=w{8CAJ(B#%nOhokPEAWsP3sn)o{`m=Muz{J%-=)1cI*;3 zlXX5M@LBIOzBPGKf%AP^`TVW2n+0;RD?b2J8zQ8JHOs$R2)ch=1^?{{GTY kxq;-|HFX1}cWwv`ESeM@5!gJvh0niwX5+y2Ss}jv0nag=0{{R3 delta 7843 zcmZ|Td3+RQp2zX0frR@EL>R6j93qf}009Ot+~HI}PC<_Dq>{8G-J!cl2q-->xahEm zgieqnL}6Ht=;%PJB_{YB4j-}Xe`>(HduaNXcBrW>AaX3T2Jo7=0^m=!k|(+0iR9LrtTy6yL13)*9@ z^*D_BVZ0IF!%mpm*_fNL8+OFS$WT!eq>x6#8dOJ{F%=&~4OovY@erot6K?yfu5V%o z+RtGZ{2aStD=GuAKkE5;I2Bi5Ydnly7~lM!f--y^HR(U29=MDtnDR4c;Fg#{Jp=Xm zWNeFbP&4wPCQ^ZUxCvX~NmRdQunAs3^?MOpFuu7&fmJeBQ8P>@eVK{sa1yq|MX1dE zZoLvU@O^j}?!l(`Gxo6`W}pV1hFYN|s1*&MCcFltdSD9$#x~oLJuyd69UMc=;C)o) zpP;tr5-PE)sE#^xH)cHcN6qX`RHEgmv$GzxQum{t+k@KTBi&hlb?~%%<7=q;yQsu2 zxi@}`T7gDAoJ7)4ThJMmP#;u>*=~KfTOW@c2Qw8lb1&xNO3cE&Jy?Hre2ND7K5F34 zQ5}ARnz^T^F#|9a8(|J=X@{YEGE_gcsKgGSW_|>f!1JiBebx1YD22ypxQrU` zkmW4h<2aW3anww&pthoUFX!`g)YA4r&2T7crEPzVjZe(s|i`)JfvZ&@b z-mCZjECnrLVQ*(9ccJ#E7B%x%Q8P-Q68Hc$(=V_ww&>$L-v*UHKU4zQsOR!9`4*tI zVhL&sR$}t~{}lzzqz*OU%cu@cqn7ML)DmArb(q@M`Mf<&rf#7IC~{qcx^ENeEvQAk zUB5w1^aLu=Gx|JA;T#2Jb`h1?759dY{fya1y*p~jp2O*Q4*TN(_G<{vMHa(sL@jj# zrr;~6#806T`Uti6U!YdbLnl$~Q3?eOoQ@hO6V>5N9F65zh>zkZY=4t;R%T)z^$3o{ zxZD0Q^2c->U`!?EVU@?2r?58;9^`D{yiE2#l^gENg8kWyatv^x&Nn4BSQHSd?s>4-3cM{lu>hC_(M5=Lj zBlaA1W^%?j{f@#JYR|t%4cLjN)!|^& zUXMo2Z~_j%d8kC9Zv7GLNBs=y`7783J5ON!mFbWP&Wxwy2I^&~jz2?n^fhXLJ`ba)*PQU%46qHFGD#P1QH~O#% zu0$<;IrhelsQVjmCZ0f6)3lu8{F=T6E$V*MA>4%OuLd=tJvbE`P>Dq^QP7@vXzhpH z@OGSt8h8(Cz&L6JUP2}MK5A<|!%XZxjW(Qt+M3Mi&Ntjhyp8%CR6qMsEBdrkkD5~y zy3=qTc_U0CHcU5;!wxtPwfDuSrLA(?x1;Vmj9RJVn2IkTFNQgZ8mJk|q={Il6&#K_ zGmA0#{@+c3KV}O*TH!m`0xzH*yyV*a7U!$BC#roW-iSWjgqu(+*y&csG05(i0@MT= zP|rPs7QTT4Ie+F7g=W}uma~WbQ3*^!JunOPxs94p0JUNpQCqU#^#t;DZ{9);*pe^! zw%8qY7BW#YAA#z3F-BD=r!XHkqRzru)KY(i>Zs!!XQ}(4Iv9oed?{+h)}j)*7j?S# zx;}?W;2b`MpW;n;fCI4{Pu<4*uisjO=Q_WYN-_CWi&?aPiCT$1^PHv5MySc zixf4Rea0N5;Q}gwtp!eoFCnXJzC(35ztA}wLDXw^2+QykhB41389a*Jv44?scJeXT z!xs?N(tdBTb5^>SXyu~Jl7deCT-0d}U^86jdJk%^?nfQQ{jQIr-iBkCiSN4YE&a}! zNJk}q32eaj)Hh=rtVbqdP7}I*OQg~8 zE`CLPL;M$Uj`*5*i}(*hm-=a?huy0+zDPt*xeb5AM%?fUKJK5DyU_ z5%&_Bgs!uMPPeX>^tA`?Pu83j=|Ee6x_%#|5C`<=YZQ7CWkfE~l$$1?t`7(uLS4@~ z{P2@iO#a*8S_6yo!}XY3I*&Spx>D))9c)L0h&19+rCv?pWuh-Jjra|rt2d!nPuE(4 zFT>P-^$gLNfv;Wrt`+bu;yx|i?}_IKT^!!zVT>nh z&W~1Z`9tjEmKWpOZn?QT!2eL+O^heT5i^LR#I@@nh5p17#B{fD&R7-bKnL*u-Nr9) zGqKUF>;DEHp9msjCdef;@@7e*W0DV{?x8X^iOWf3#hM%7H++t>v7jc zu6N>9BIwrJlR-L>Lg;#us37WyPP9$IF@!E&?&Q_Xz4w^T?!VJ?ffz(gBKSfx7LiR< z5~~PZZ#bB?JbW|d9YkZ|Q{oEIhFD58A#~kCM2I28NFhlnELBC&}WrL$W=;Y~u< zt;7~$KJjy+BZGa8^~5qlS6heV&yoC`L;RZfmt@P2KN1u(i2cM)w|O$YM|5!O^B6z* ztD_K`5iN;!40;50{j)>zp9CsCP2A+Redqdb_&Xv@{3o%F(ACu;`AfGAeO|kIQMjF$ zNJJO8tsmo;L^-jGc$oN>c%Aqsq9f6XxOSyeXhEkVaJ1X#p`J?lS43yG?SFBoTV9AK zh~PpBbRM$T_`?y)AFzU} zLsrNx2!;y7S+V@CMXdu~U#V?P96x*B#Hr)s4P6&CZtD$ri*4?@*7$Xgy`I=wt4)+1 z?MSaNzL1rj=lmQWaK|eM1|nX6z#k}P3IV&)Drb_F3}cme!V z1_M@+pDc<rV00r-NxVhonUwUBNThsJcD8SI zq|^@aadB2buq-=vZb(Da8(tZ90Np?5w`wACHVxY5Qom`-aUA$H-#3URKDqNui*CeEdH-d7O?=g}=aEtrEMm zJh{?^{wyaQCmVMqlKZD6(1a{bPx80a?>-CGxb^-<<5DCy)ZO479Dz~ z-Qdi@xtT+TSUDp``c_fR*dWz_l1OP$3l#*ReB2VyzlW3R`m4nE$4pm zS&UfCQXbYu)KI9SYgY9zdF|AP>=D7P>`ktx7M-=Pr%KM6cue={S?ByDSA^}NhveF4 zS&8jh-+C6R-r3HY#B6P^yLvmdxmL1s&3A`J+Rx3&gK$voYz}W8DSOK!1ts3=Uby7A zTeZPyLmyjBJ0>;a28F+S--fi9K1{e7%<(&>AOpDMe@P$IqUoQ>x>4 th`Xx!B;$t\n" "Language-Team: Ahrale | Atar4U.com\n" "Language: he_IL\n" @@ -10,7 +10,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" "X-Poedit-Basepath: ..\n" "X-Poedit-WPHeader: wp-members.php\n" "X-Poedit-SourceCharset: UTF-8\n" @@ -20,113 +20,122 @@ msgstr "" "X-Poedit-SearchPath-0: .\n" "X-Poedit-SearchPathExcluded-0: *.js\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "×פשרויות" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "שדות" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "תיבות דו-שיח" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "×ימיילי×" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "×¨×™×©×•× ×—×“×©" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "ההרשמה מסוננת" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "ההרשמה מסוננת, המשתמש מ×ושר" -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "×יפוס סיסמה" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "שחזור ×©× ×ž×©×ª×ž×©" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "הודעה להנהלה" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "פוסט מוגבלת (×ו עמוד), מוצג מעל טופס כניסה/הרשמה" -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "×©× ×”×ž×©×ª×ž×© כבר תפוס" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "×”×ימייל כבר רשו×" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "ההרשמה הושלמה" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "עדכון המשתמש" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "הסיסמ×ות ×ינן תו×מות" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "החלפת סיסמה" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "×©× ×”×ž×©×ª×ž×© ×ו ×”×ימייל ××™× × ×§×™×™×ž×™×, ×›×שר ×ž× ×¡×™× ×œ×פס ×ת הסיסמה" -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "×יפוס סיסמה" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "הגדרות" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" -msgstr "ביטול חסימה" +msgid "Unrestrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -msgid "Block" -msgstr "לחסו×" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -135,12 +144,12 @@ msgstr "להסתיר" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -149,14 +158,19 @@ msgid "%s Restriction" msgstr "הגבלת %s" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -181,266 +195,286 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "הפעלה" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "יצו×" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 msgid "Export All Users" msgstr "×™×¦×•× ×›×œ המשתמשי×" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "מנוי" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" -msgstr "ל×" - -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" -msgstr "×©× ×ž×©×ª×ž×©" - -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "פעיל?" - -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "פג תוקף" - -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "רשו×" - -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "כתובת IP" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" +msgstr "" -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" -msgstr "כן" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" +msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "פג תוקף" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "כן" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 msgid "Pages" msgstr "עמודי×" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -448,57 +482,107 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "לל×" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "ל×" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "×©× ×ž×©×ª×ž×©" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "פעיל?" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "רשו×" + +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "כתובת IP" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -667,77 +751,51 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "צריך עזרה?" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "ניהול ×פשרויות קוד ×ימות של reCAPTCHA" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." -msgstr "reCAPTCHA ×”×•× ×§×•×“ ×ימות חינמי, לחסימת ספ×× ×‘×תר שלכ×." - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA מבקש להקליד שתי ×ž×™×œ×™× ×¡×¨×•×§×•×ª מספר כדי להוכיח ×נושיות. ×–×” מ×מת " -"שהשולח ×ינו רובוט ספ×× ×‘×§×¨×• ב %sreCaptcha%s" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "מפתחות reCAPTCHA" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"קוד ×ימות של reCAPTCHA צריך מפתח API המורכב מ\"מפתח ציבורי\" ו\"מפתח פרטי\". " -"×פשר ×œ×”×™×¨×©× ×œ×§×‘×œ×ª %sמפתח reCAPTCHA ×œ×œ× ×ª×©×œ×•× %s" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "מפתח ציבורי" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "מפתח פרטי" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "בחירת תבנית" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "×דו×" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "לבן" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "זכוכית שחורה" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "× ×§×™" +msgid "reCAPTCHA Keys" +msgstr "מפתחות reCAPTCHA" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " @@ -746,55 +804,71 @@ msgstr "" "קוד ×ימות של reCAPTCHA דורש מפתח API, המורכב מ \"מפתח ×תר\" ו \"מפתח סודי\". " "ב×פשרותך ×œ×”×™×¨×©× ×œ×§×‘×œ×ª %sמפתחות reCAPTCHA ×œ×œ× ×ª×©×œ×•×%s" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "מפתח ×תר" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "מפתח סודי" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 msgid "Characters for image" msgstr "×ª×•×•×™× ×¢×‘×•×¨ התמונה" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 msgid "Number of characters" msgstr "מספר התווי×" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "גודל התמונה" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "רוחב" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "גובה" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "צבע הגופן של התווי×" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "צבע הרקע של התמונה" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "גודל הגופן" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "המרווח בין התווי×" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 msgid "Image type" msgstr "סוג התמונה" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." @@ -802,11 +876,11 @@ msgstr "" "כדי להשתמש בקוד ×ימות פשוט ב×מת, חובה להתקין ולהפעיל ×ת התוסף Really Simple " "CAPTCHA." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 msgid "Update CAPTCHA Settings" msgstr "עדכון הגדרות קוד ×”×ימות" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 msgid "CAPTCHA was updated for WP-Members" msgstr "קוד ×”×ימות עבור וורדפרס-×—×‘×¨×™× ×¢×•×“×›×Ÿ" @@ -872,8 +946,8 @@ msgstr "הגדרת כתובת ×ימייל" #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "(רשות)" @@ -881,20 +955,24 @@ msgstr "(רשות)" msgid "Set a custom email name" msgstr "קביעת ×©× ×ימייל" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "חתימת ×”×ימייל" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "עדכון ×”×ימיילי×" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "×”××™×ž×™×™×œ×™× ×©×œ וורדפרס-×—×‘×¨×™× ×¢×•×“×›× ×•" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -910,37 +988,36 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "(חובה)" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Edit Field" msgstr "עריכת השדה" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Add a Field" msgstr "הוספת שדה" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "תווית השדה" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "×”×©× ×©×œ השדה כפי ×©×”×•× ×™×•×¦×’ בפני המשתמש." -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." @@ -948,216 +1025,234 @@ msgstr "" "ערך תי×ור meta עבור השדה. ×”×•× ×—×™×™×‘ להיות ייחודי, ×œ×œ× ×¨×•×•×—×™× (×פשר להשתמש " "×‘×ž×§×¤×™× ×ª×—×ª×•× ×™×)." -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "סוג השדה" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "טקסט" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "×ימייל" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "×זור טקסט" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "תיבת סימון" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "תיבות סימון מרובות" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "בחירה מרשימה נפתחת" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "בחירה מרובה ברשימה נפתחת" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "קבוצת לחצני רדיו" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "סיסמה" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "תמונה" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "קובץ" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "כתובת URL" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "נסתר" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "להציג?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "חובה?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "סוגי ×”×§×‘×¦×™× ×”×ž×§×•×‘×œ×™×:" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "×ת סוגי ×”×§×‘×¦×™× ×”×ž×§×•×‘×œ×™× ×™×© להגדיר כך:jpg|jpeg|png|gif" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 msgid "Checked by default?" msgstr "לסמן כברירת מחדל?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 msgid "Stored value if checked:" msgstr "הערך המ×וחסן ×× ×ž×¡×•×ži:" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "×”×פשרויות צריכות להיות ×©× ×פשרות | option_value," -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "× × ×œ×‘×§×¨ ב×תר התוסף למידע נוסף" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 msgid "Add Field" msgstr "הוספת שדה" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 msgid "Registration Date" msgstr "ת×ריך ההרשמה" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -msgid "Active" -msgstr "פעיל" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 msgid "Registration IP" msgstr "כתובת ×” IP בהרשמה" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "ניהול שדות" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "השדות של וורדפרס-×—×‘×¨×™× ×¢×•×“×›× ×•" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a מונח שמור. השדה ×œ× " "התווסף." -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:659 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:673 msgid "Checked value is required for checkboxes. Nothing was updated." msgstr "ערך מסומן ×”×•× ×—×•×‘×” עבור תיבות סימון. ×©×•× ×“×‘×¨ ×œ× ×¢×•×“×›×Ÿ." -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:690 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:705 msgid "A value is required for hidden fields. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:697 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:712 #, php-format msgid "%s was added" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:710 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:725 #, php-format msgid "%s was updated" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:753 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:768 msgid "Form field order updated." msgstr "" @@ -1209,12 +1304,12 @@ msgid "Content" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-options.php:105 -msgid "Content Blocking" +msgid "Content Restriction" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-options.php:109 -msgid "Do not block" -msgstr "×œ× ×œ×—×¡×•×" +msgid "Do not restrict" +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-options.php:123 msgid "Show Excerpts" @@ -1261,132 +1356,160 @@ msgid "Subscription Settings" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-options.php:176 -msgid "Other Settings" +msgid "New Feature Settings" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-options.php:182 -msgid "Activation" +msgid "Legacy Password Reset" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-options.php:182 -msgid "" -"Send initial activation link and password reset link instead of new " -"password. (Requires additional configuration)" +#, php-format +msgid "Use legacy password reset. %s(Requires additional configuration)%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:183 -msgid "Enable Products" +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:184 +msgid "Legacy Login Error" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:183 -msgid "Enables creation of different membership products" +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:184 +msgid "Use legacy WP-Members login error instead of WP error object." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:184 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:187 +msgid "WooCommerce My Account" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:187 +msgid "Add WP-Members fields to WooCommerce My Account registration" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:188 +msgid "WooCommerce Checkout" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:188 +msgid "Add WP-Members fields to WooCommerce registration during checkout" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 +msgid "Other Settings" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:214 +msgid "Enable memberships" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:214 +#, php-format +msgid "Enables creation of different %s membership products %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:223 msgid "Clone menus" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:184 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:215 msgid "Enables logged in menus" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:216 msgid "Notify admin" msgstr "להודיע למנהל" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:185 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:216 #, php-format msgid "Notify %s for each new registration? %s" msgstr "להודיע ל %s מנהל על כל הרשמה חדשה? %s" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:217 msgid "Moderate registration" msgstr "בקרת הרשמה" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:217 msgid "Holds new registrations for admin approval" msgstr "עוצר הרשמת ×ž×©×ª×ž×©×™× ×—×“×©×™× ×¢×“ ל×ישור מנהל" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:218 +msgid "Confirmation Link" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:218 +#, php-format +msgid "" +"Send email confirmation link on new registration. %s(Requires additional " +"configuration)%s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:219 msgid "Ignore warning messages" msgstr "×œ×”×ª×¢×œ× ×ž×”×•×“×¢×•×ª ×זהרה" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:219 msgid "Ignores WP-Members warning messages in the admin panel" msgstr "×œ×”×ª×¢×œ× ×ž×”×•×“×¢×•×ª ×זהרה של וורדפרס-×—×‘×¨×™× ×‘×œ×•×— הבקרה" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:233 msgid "Attribution" msgstr "ייחוס" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:235 msgid "" "Attribution is appreciated! Display \"powered by\" link on register form?" msgstr "ייחוס תתקבל בברכה! להציג \"מופעל על ידי\" על הקישור בטופס ההרשמה?" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:203 -msgid "Enable CAPTCHA" -msgstr "הפעלת קוד ×ימות" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:208 -msgid "reCAPTCHA v2" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:209 -msgid "reCAPTCHA v3" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:210 -msgid "Really Simple CAPTCHA" +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:238 +msgid "Enable CAPTCHA for Registration" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:217 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:253 msgid "Login Page:" msgstr "עמוד כניסה" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:220 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:256 msgid "Specify a login page (optional)" msgstr "× × ×œ×¦×™×™×Ÿ עמוד כניסה (רשות)" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:229 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:265 msgid "Register Page:" msgstr "עמוד ההרשמה" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:232 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:268 msgid "For creating a register link in the login form" msgstr "כדי ליצור קישור להרשמה בטופס הכניסה" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:277 msgid "User Profile Page:" msgstr "עמוד פרופיל המשתמש:" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:280 msgid "For creating a forgot password link in the login form" msgstr "כדי ליצור קישור ל×יפוס סיסמה בטופס הכניסה" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:250 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:252 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:286 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:288 msgid "Stylesheet" msgstr "גיליון עיצוב" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:261 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:297 msgid "Custom Stylesheet:" msgstr "גיליון עיצוב מות×× ×ישית:" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:266 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:302 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:329 msgid "Update Settings" msgstr "עדכן ההגדרות" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:274 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:310 msgid "Custom Post Types" msgstr "סוגי פוסט" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:316 msgid "Add to WP-Members Settings" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:296 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:332 msgid "" "Please keep in mind that Custom Post Types are \"custom\" and therefore, not " "all of them will function exactly the same way. WP-Members will certainly " @@ -1395,38 +1518,34 @@ msgid "" "way you expect." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:315 -msgid "Close" +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:342 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:343 +msgid "WP-Members Settings" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:333 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:334 -msgid "WP-Members Settings" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:335 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:344 msgid "" "The following is your WP-Members settings information if needed for support." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:362 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:378 msgid "Click to Copy" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:442 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:458 msgid "Custom Post Type settings were updated" msgstr "הגדרות סוגי פוסט עודכנו" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:551 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:579 msgid "WP-Members settings were updated" msgstr "הגדרות וורדפרס-×—×‘×¨×™× ×¢×•×“×›× ×•" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:623 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:654 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:651 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:682 msgid "USE CUSTOM URL BELOW" msgstr "להשתמש בכתובת URL מות×מת ×ישית להלן" -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:643 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:671 msgid "Select a page" msgstr "בחירת עמוד" @@ -1484,524 +1603,355 @@ msgstr "" msgid "Delete Selected" msgstr "" -#: includes/api/api.php:328 includes/class-wp-members.php:1588 -msgid "log in" -msgstr "כניסה" - -#: includes/api/api.php:329 -msgid "log out" -msgstr "" - -#: includes/class-wp-members-activation-link.php:21 -msgid "Click to activate your account: " -msgstr "" - -#: includes/class-wp-members-activation-link.php:22 -msgid "Thank you for activating your account." -msgstr "" - -#: includes/class-wp-members-activation-link.php:23 -msgid "Activation key was expired or invalid" +#: includes/api/api-forms.php:584 +#, php-format +msgid "%s is a required field." msgstr "" -#: includes/class-wp-members-captcha.php:217 includes/deprecated - Copy.php:500 -#: includes/deprecated.php:501 +#: includes/class-wp-members-captcha.php:276 includes/deprecated.php:401 msgid "You have entered an incorrect code value. Please try again." msgstr "הזנת ערך קוד שגוי. × × × ×¡×” שוב." -#: includes/class-wp-members-forms.php:1048 -#: includes/class-wp-members-forms.php:1646 includes/class-wp-members.php:1538 -#, php-format -msgid "Please indicate that you agree to the %s Terms of Service %s" -msgstr "" - -#: includes/class-wp-members-forms.php:1049 -#: includes/class-wp-members-forms.php:1647 includes/class-wp-members.php:1489 -msgid "TOS" -msgstr "תנ××™ השימוש" - -#: includes/class-wp-members-forms.php:1049 -#: includes/class-wp-members-forms.php:1647 templates/tos.php:20 -msgid "Terms of Service" -msgstr "תנ××™ שימוש" - -#: includes/class-wp-members-forms.php:1868 -#: includes/class-wp-members-user-profile.php:473 -msgid "Activate this user?" -msgstr "ל×שר ×ת המשתמש ×”×–×”?" - -#: includes/class-wp-members-menus.php:131 -msgid "Display" -msgstr "" - -#: includes/class-wp-members-menus.php:139 -msgid "Logged In Users" -msgstr "" - -#: includes/class-wp-members-menus.php:146 -msgid "Logged Out Users" -msgstr "" - -#: includes/class-wp-members-menus.php:153 -msgid "All Users" -msgstr "" - -#: includes/class-wp-members-menus.php:167 -#, php-format -msgid "%sAdd membership products%s to restrict menu to a membership" -msgstr "" - -#: includes/class-wp-members-menus.php:169 -msgid "Restrict menu item to a membership product" -msgstr "" - -#: includes/class-wp-members-products.php:302 -msgid "Product" -msgstr "" - -#: includes/class-wp-members-products.php:303 -msgid "Products" -msgstr "" - -#: includes/class-wp-members-products.php:309 -#, php-format -msgid "All %s" -msgstr "" - -#: includes/class-wp-members-products.php:310 -#, php-format -msgid "Add New %s" -msgstr "" - -#: includes/class-wp-members-products.php:311 -msgid "Add New" -msgstr "" - -#: includes/class-wp-members-products.php:312 -#, php-format -msgid "New %s" -msgstr "" - -#: includes/class-wp-members-products.php:313 -#, php-format -msgid "Edit %s" -msgstr "" - -#: includes/class-wp-members-products.php:314 -#, php-format -msgid "Update %s" -msgstr "" - -#: includes/class-wp-members-products.php:315 -#: includes/class-wp-members-products.php:316 -#, php-format -msgid "View %s" -msgstr "" - -#: includes/class-wp-members-products.php:317 -#, php-format -msgid "Search %s" -msgstr "" - -#: includes/class-wp-members-products.php:318 -msgid "Not found" -msgstr "" - -#: includes/class-wp-members-products.php:319 -msgid "Not found in Trash" -msgstr "" - -#: includes/class-wp-members-products.php:320 -msgid "Insert into item" -msgstr "" - -#: includes/class-wp-members-products.php:321 -#, php-format -msgid "Save %s Details" -msgstr "" - -#: includes/class-wp-members-products.php:324 -msgid "Membership Product" -msgstr "" - -#: includes/class-wp-members-products.php:325 -msgid "WP-Members Membership Products" -msgstr "" - -#: includes/class-wp-members-pwd-reset.php:31 -#: includes/class-wp-members-pwd-reset.php:32 -msgid "" -"Sorry, no password reset key was found. Please check your email and try " -"again." -msgstr "" - -#: includes/class-wp-members-pwd-reset.php:33 -msgid "Sorry, the password reset key is expired." -msgstr "" - -#: includes/class-wp-members-shortcodes.php:147 -msgid "" -"This is a generic message to display the form message dialog in the " -"Customizer." -msgstr "" - -#: includes/class-wp-members-shortcodes.php:158 -#: includes/class-wp-members.php:1566 includes/deprecated - Copy.php:695 -msgid "There was an error with the CAPTCHA form." -msgstr "היתה שגי××” בטופס קוד ×”×ימות." - -#: includes/class-wp-members-shortcodes.php:717 -msgid "Click here to log out." -msgstr "× × ×œ×œ×—×•×¥ ×›×ן כדי להתנתק." - -#: includes/class-wp-members-shortcodes.php:786 -#: includes/class-wp-members-user.php:172 includes/class-wp-members.php:1540 -#: includes/class-wp-members.php:1590 -msgid "Register" -msgstr "הרשמה" - -#: includes/class-wp-members-shortcodes.php:789 -#: includes/class-wp-members.php:1508 -msgid "Log In" -msgstr "כניסה" - -#: includes/class-wp-members-user-profile.php:38 -msgid "WP-Members Additional Fields" -msgstr "שדות × ×•×¡×¤×™× ×©×œ וורדפרס-חברי×" - -#: includes/class-wp-members-user-profile.php:38 -msgid "Additional Information" -msgstr "מידע נוסף" - -#: includes/class-wp-members-user-profile.php:463 -msgid "Reactivate this user?" -msgstr "ל×שר מחדש ×ת המשתמש ×”×–×”?" - -#: includes/class-wp-members-user-profile.php:468 -msgid "Deactivate this user?" -msgstr "לבטל ×ת המשתמש ×”×–×”?" - -#: includes/class-wp-members-user-profile.php:522 -msgid "IP @ registration" -msgstr "כתובת IP והרשמה" - -#: includes/class-wp-members-user.php:199 includes/class-wp-members.php:1565 -msgid "There was an error processing the form." -msgstr "×ירעה שגי××” בעיבוד הטופס." - -#: includes/class-wp-members-user.php:1118 -msgid "ERROR: User has not been activated." -msgstr "שגי××”: המשתמש ×ינו פעיל." - -#: includes/class-wp-members-widget.php:24 -msgid "Displays the WP-Members sidebar login." -msgstr "מציג ×ת הכניסה של וורדפרס-×—×‘×¨×™× ×‘×¡×¨×’×œ הצד" - -#: includes/class-wp-members-widget.php:39 -#: includes/class-wp-members-widget.php:82 -msgid "Login Status" -msgstr "מצב ההתחברות" - -#: includes/class-wp-members-widget.php:46 -msgid "Title:" -msgstr "כותרת:" - -#: includes/class-wp-members-widget.php:50 -msgid "Redirect to (optional):" -msgstr "להפנות ל (רשות):" - -#: includes/class-wp-members.php:1028 includes/class-wp-members.php:1038 -msgid "You must be logged in to view this content." -msgstr "" - -#: includes/class-wp-members.php:1044 -msgid "The page you are looking for does not exist" -msgstr "" - -#: includes/class-wp-members.php:1436 -#, php-format -msgid "" -"You have a linked page in the WP-Members page settings that corresponds to a " -"post ID that no longer exists. Please %s review and update the %s page " -"settings %s." -msgstr "" - -#: includes/class-wp-members.php:1474 +#: includes/class-wp-members-dialogs.php:41 msgid "First Name" msgstr "ש×" -#: includes/class-wp-members.php:1475 +#: includes/class-wp-members-dialogs.php:42 msgid "Last Name" msgstr "×©× ×ž×©×¤×—×”" -#: includes/class-wp-members.php:1476 +#: includes/class-wp-members-dialogs.php:43 msgid "Address 1" msgstr "כתובת" -#: includes/class-wp-members.php:1477 +#: includes/class-wp-members-dialogs.php:44 msgid "Address 2" msgstr "כתובת 2" -#: includes/class-wp-members.php:1478 +#: includes/class-wp-members-dialogs.php:45 msgid "City" msgstr "יישוב" -#: includes/class-wp-members.php:1479 +#: includes/class-wp-members-dialogs.php:46 msgid "State" msgstr "מדינה" -#: includes/class-wp-members.php:1480 +#: includes/class-wp-members-dialogs.php:47 msgid "Zip" msgstr "מיקוד" -#: includes/class-wp-members.php:1481 +#: includes/class-wp-members-dialogs.php:48 msgid "Country" msgstr "×רץ" -#: includes/class-wp-members.php:1482 +#: includes/class-wp-members-dialogs.php:49 msgid "Day Phone" msgstr "טלפון" -#: includes/class-wp-members.php:1483 includes/class-wp-members.php:1524 +#: includes/class-wp-members-dialogs.php:50 +#: includes/class-wp-members-dialogs.php:92 msgid "Email" msgstr "×ימייל" -#: includes/class-wp-members.php:1484 +#: includes/class-wp-members-dialogs.php:51 msgid "Confirm Email" msgstr "×ישור ×”×ימייל" -#: includes/class-wp-members.php:1485 +#: includes/class-wp-members-dialogs.php:52 msgid "Website" msgstr "×תר" -#: includes/class-wp-members.php:1486 +#: includes/class-wp-members-dialogs.php:53 msgid "Biographical Info" msgstr "מידע ביוגרפי" -#: includes/class-wp-members.php:1487 includes/class-wp-members.php:1507 -#: includes/class-wp-members.php:1587 +#: includes/class-wp-members-dialogs.php:54 +#: includes/class-wp-members-dialogs.php:74 +#: includes/class-wp-members-dialogs.php:159 msgid "Password" msgstr "סיסמה" -#: includes/class-wp-members.php:1488 +#: includes/class-wp-members-dialogs.php:55 msgid "Confirm Password" msgstr "×ישור הסיסמה" -#: includes/class-wp-members.php:1499 +#: includes/class-wp-members-dialogs.php:56 +#: includes/class-wp-members-forms.php:2165 +msgid "TOS" +msgstr "תנ××™ השימוש" + +#: includes/class-wp-members-dialogs.php:66 msgid "You are not logged in." msgstr "עוד ×œ× × ×›× ×¡×ª." -#: includes/class-wp-members.php:1505 +#: includes/class-wp-members-dialogs.php:72 msgid "Existing Users Log In" msgstr "כניסת ×ž×©×ª×ž×©×™× ×¨×©×•×ž×™×" -#: includes/class-wp-members.php:1506 includes/class-wp-members.php:1586 +#: includes/class-wp-members-dialogs.php:73 +#: includes/class-wp-members-dialogs.php:158 msgid "Username or Email" msgstr "" -#: includes/class-wp-members.php:1509 +#: includes/class-wp-members-dialogs.php:75 +#: includes/class-wp-members-shortcodes.php:773 +msgid "Log In" +msgstr "כניסה" + +#: includes/class-wp-members-dialogs.php:76 msgid "Remember Me" msgstr "זכור ×ותי" -#: includes/class-wp-members.php:1510 +#: includes/class-wp-members-dialogs.php:77 msgid "Forgot password?" msgstr "ל×פס ×ת הסיסמה?" -#: includes/class-wp-members.php:1511 +#: includes/class-wp-members-dialogs.php:78 msgid "Click here to reset" msgstr "× × ×œ×œ×—×•×¥ ×›×ן כדי ל×פס" -#: includes/class-wp-members.php:1512 +#: includes/class-wp-members-dialogs.php:79 msgid "New User?" msgstr "משתמש חדש?" -#: includes/class-wp-members.php:1513 +#: includes/class-wp-members-dialogs.php:80 msgid "Click here to register" msgstr "× × ×œ×œ×—×•×¥ ×›×ן כדי להירש×" -#: includes/class-wp-members.php:1516 includes/class-wp-members.php:1571 +#: includes/class-wp-members-dialogs.php:83 +#: includes/class-wp-members-dialogs.php:142 msgid "Change Password" msgstr "החלפת סיסמה" -#: includes/class-wp-members.php:1517 +#: includes/class-wp-members-dialogs.php:84 msgid "New password" msgstr "סיסמה חדשה" -#: includes/class-wp-members.php:1518 +#: includes/class-wp-members-dialogs.php:85 msgid "Confirm new password" msgstr "×ישור הסיסמה החדשה" -#: includes/class-wp-members.php:1519 +#: includes/class-wp-members-dialogs.php:86 msgid "Update Password" msgstr "עדכון הסיסמה" -#: includes/class-wp-members.php:1522 +#: includes/class-wp-members-dialogs.php:87 +msgid "Password successfully changed!" +msgstr "הסיסמה הוחלפה בהצלחה!" + +#: includes/class-wp-members-dialogs.php:90 msgid "Reset Forgotten Password" msgstr "×יפוס סיסמה שנשכחה" -#: includes/class-wp-members.php:1525 +#: includes/class-wp-members-dialogs.php:93 msgid "Reset Password" msgstr "×יפוס סיסמה" -#: includes/class-wp-members.php:1526 +#: includes/class-wp-members-dialogs.php:94 msgid "Forgot username?" msgstr "שכחת ×ת ×©× ×”×ž×©×ª×ž×©?" -#: includes/class-wp-members.php:1527 +#: includes/class-wp-members-dialogs.php:95 msgid "Click here" msgstr "ללחוץ ×›×ן" -#: includes/class-wp-members.php:1530 includes/class-wp-members.php:1532 +#: includes/class-wp-members-dialogs.php:98 +#: includes/class-wp-members-dialogs.php:100 msgid "Retrieve username" msgstr "שחזור ×©× ×”×ž×©×ª×ž×©" -#: includes/class-wp-members.php:1531 +#: includes/class-wp-members-dialogs.php:99 msgid "Email Address" msgstr "כתובת ×ימייל" -#: includes/class-wp-members.php:1535 +#: includes/class-wp-members-dialogs.php:103 msgid "New User Registration" msgstr "×¨×™×©×•× ×ž×©×ª×ž×© חדש" -#: includes/class-wp-members.php:1536 +#: includes/class-wp-members-dialogs.php:104 msgid "Choose a Username" msgstr "בחירת ×©× ×ž×©×ª×ž×©" -#: includes/class-wp-members.php:1537 +#: includes/class-wp-members-dialogs.php:105 msgid "Input the code:" msgstr "להזין ×ת הקוד:" -#: includes/class-wp-members.php:1539 +#: includes/class-wp-members-dialogs.php:106 +#: includes/class-wp-members-forms.php:2164 +#, php-format +msgid "Please indicate that you agree to the %s Terms of Service %s" +msgstr "" + +#: includes/class-wp-members-dialogs.php:107 msgid "Reset Form" msgstr "×יפוס הטופס" -#: includes/class-wp-members.php:1542 +#: includes/class-wp-members-dialogs.php:108 +#: includes/class-wp-members-dialogs.php:162 +#: includes/class-wp-members-shortcodes.php:770 +#: includes/class-wp-members-user.php:186 +msgid "Register" +msgstr "הרשמה" + +#: includes/class-wp-members-dialogs.php:110 msgid "Required field" msgstr "שדה חובה" -#: includes/class-wp-members.php:1545 includes/deprecated - Copy.php:741 +#: includes/class-wp-members-dialogs.php:113 msgid "Edit Your Information" msgstr "עריכת ×”×¤×¨×˜×™× ×©×œ×š" -#: includes/class-wp-members.php:1547 +#: includes/class-wp-members-dialogs.php:115 msgid "Update Profile" msgstr "עדכון הפרופיל" -#: includes/class-wp-members.php:1548 +#: includes/class-wp-members-dialogs.php:116 msgid "Update this file" msgstr "עדכון הקובץ ×”×–×”" -#: includes/class-wp-members.php:1551 +#: includes/class-wp-members-dialogs.php:119 msgid "Login Failed!" msgstr "הכניסה נכשלה!" -#: includes/class-wp-members.php:1552 +#: includes/class-wp-members-dialogs.php:120 msgid "You entered an invalid username or password." msgstr "הזנת ×©× ×ž×©×ª×ž×© ×ו סיסמה שגויי×." -#: includes/class-wp-members.php:1553 +#: includes/class-wp-members-dialogs.php:121 msgid "Click here to continue." msgstr "× × ×œ×œ×—×•×¥ ×›×ן כדי להמשיך" -#: includes/class-wp-members.php:1554 +#: includes/class-wp-members-dialogs.php:122 msgid "Password fields cannot be empty" msgstr "שדות הסיסמה ×”× ×©×“×•×ª חובה" -#: includes/class-wp-members.php:1555 +#: includes/class-wp-members-dialogs.php:123 msgid "Sorry, that email address was not found." msgstr "מצטערי×, כתובת ×”×ימייל הזו ××™× × ×”" -#: includes/class-wp-members.php:1556 +#: includes/class-wp-members-dialogs.php:124 #, php-format msgid "An email was sent to %s with your username." msgstr "×ימייל ×¢× ×©× ×”×ž×©×ª×ž×© שלך נשלח ל %s" -#: includes/class-wp-members.php:1557 +#: includes/class-wp-members-dialogs.php:125 #, php-format msgid "Sorry, %s is a required field." msgstr "מצטערי×, %s ×”×•× ×©×“×” חובה" -#: includes/class-wp-members.php:1558 +#: includes/class-wp-members-dialogs.php:126 msgid "You must enter a valid email address." msgstr "חובה להזין ×ימייל תקף" -#: includes/class-wp-members.php:1559 +#: includes/class-wp-members-dialogs.php:127 msgid "The username cannot include non-alphanumeric characters." msgstr "×©× ×”×ž×©×ª×ž×© ×ינו יכול לכלול ×ª×•×•×™× ×©××™× × ×לפ×-נומריי×." -#: includes/class-wp-members.php:1560 +#: includes/class-wp-members-dialogs.php:128 msgid "Sorry, username is a required field" msgstr "מצטערי×, ×©× ×”×ž×©×ª×ž×© ×”×•× ×©×“×” חובה" -#: includes/class-wp-members.php:1561 +#: includes/class-wp-members-dialogs.php:129 +msgid "Sorry, that username is taken, Please try another." +msgstr "" + +#: includes/class-wp-members-dialogs.php:130 +msgid "Sorry, that email address already has an account. Please try another." +msgstr "" + +#: includes/class-wp-members-dialogs.php:131 +#: includes/class-wp-members-dialogs.php:174 msgid "Passwords did not match." msgstr "הסיסמ×ות ×ינן תו×מות" -#: includes/class-wp-members.php:1562 +#: includes/class-wp-members-dialogs.php:132 msgid "Emails did not match." msgstr "כתובות ×”×ימייל ×ינן תו×מות" -#: includes/class-wp-members.php:1563 +#: includes/class-wp-members-dialogs.php:133 msgid "You must complete the CAPTCHA form." msgstr "חובה ×œ×”×©×œ×™× ×ת טופס קוד ×”×ימות." -#: includes/class-wp-members.php:1564 +#: includes/class-wp-members-dialogs.php:134 msgid "CAPTCHA was not valid." msgstr "קוד ×”×ימות ×ינו תקף" -#: includes/class-wp-members.php:1567 +#: includes/class-wp-members-dialogs.php:135 +msgid "There was an error processing the form." +msgstr "×ירעה שגי××” בעיבוד הטופס." + +#: includes/class-wp-members-dialogs.php:136 +msgid "There was an error with the CAPTCHA form." +msgstr "היתה שגי××” בטופס קוד ×”×ימות." + +#: includes/class-wp-members-dialogs.php:137 #, php-format msgid "" "Sorry, you can only upload the following file types for the %s field: %s." msgstr "" -#: includes/class-wp-members.php:1570 +#: includes/class-wp-members-dialogs.php:138 +#: includes/class-wp-members-dialogs.php:171 +msgid "Your information was updated!" +msgstr "המידע שלך עודכן!" + +#: includes/class-wp-members-dialogs.php:141 msgid "Edit My Information" msgstr "עריכת ×”×¤×¨×˜×™× ×©×œ×š" -#: includes/class-wp-members.php:1572 includes/class-wp-members.php:1575 -#: includes/class-wp-members.php:1577 includes/class-wp-members.php:1582 +#: includes/class-wp-members-dialogs.php:143 +#: includes/class-wp-members-dialogs.php:146 +#: includes/class-wp-members-dialogs.php:148 +#: includes/class-wp-members-dialogs.php:153 #, php-format msgid "You are logged in as %s" msgstr "×תה מחובר ×›- %s." -#: includes/class-wp-members.php:1573 +#: includes/class-wp-members-dialogs.php:144 msgid "Log out" msgstr "" -#: includes/class-wp-members.php:1574 +#: includes/class-wp-members-dialogs.php:145 msgid "Edit profile" msgstr "" -#: includes/class-wp-members.php:1574 +#: includes/class-wp-members-dialogs.php:145 msgid "Begin using the site." msgstr "×פשר להתחיל להשתמש ב×תר" -#: includes/class-wp-members.php:1576 +#: includes/class-wp-members-dialogs.php:147 msgid "Click to log out" msgstr "ללחוץ כדי לצ×ת" -#: includes/class-wp-members.php:1578 +#: includes/class-wp-members-dialogs.php:149 msgid "click to log out" msgstr "ללחוץ כדי לצ×ת" -#: includes/class-wp-members.php:1579 +#: includes/class-wp-members-dialogs.php:150 msgid "Log Out" msgstr "" -#: includes/class-wp-members.php:1583 +#: includes/class-wp-members-dialogs.php:154 msgid "click here to log out" msgstr "ללחוץ ×›×ן כדי לצ×ת" -#: includes/class-wp-members.php:1584 +#: includes/class-wp-members-dialogs.php:155 msgid "Login Failed!
    You entered an invalid username or password." msgstr "הכניסה נכשלה!
    הזנת ×©× ×ž×©×ª×ž×© ×ו סיסמה שגויי×." -#: includes/class-wp-members.php:1589 +#: includes/class-wp-members-dialogs.php:156 +msgid "Invalid username or password." +msgstr "" + +#: includes/class-wp-members-dialogs.php:160 includes/class-wp-members.php:1745 +msgid "log in" +msgstr "כניסה" + +#: includes/class-wp-members-dialogs.php:161 msgid "Forgot?" msgstr "שכחת?" -#: includes/class-wp-members.php:1593 +#: includes/class-wp-members-dialogs.php:165 msgid "" "This content is restricted to site members. If you are an existing user, " "please log in. New users may register below." @@ -2009,97 +1959,341 @@ msgstr "" "תוכן ×–×” מוגבל לחברי ×”×תר. ×× ×תה משתמש ×§×™×™×, × × ×œ×”×™×›× ×¡. ×ž×©×ª×ž×©×™× ×—×“×©×™× " "×™×›×•×œ×™× ×œ×”×™×¨×©× ×œ×”×œ×Ÿ." -#: includes/class-wp-members.php:1594 +#: includes/class-wp-members-dialogs.php:166 msgid "" "Congratulations! Your registration was successful.

    You may now " "log in using the password that was emailed to you." msgstr "" "יופי! ההרשמה הצליחה

    ×פשר להתחבר כעת ×¢× ×”×¡×™×¡×ž×” שנשלחה ×ליך ב×ימייל." -#: includes/class-wp-members.php:1597 +#: includes/class-wp-members-dialogs.php:169 msgid "Sorry, that username is taken, please try another." msgstr "מצטערי×, ×©× ×”×ž×©×ª×ž×© ×”×–×” תפוס, × × ×œ× ×¡×•×ª ×©× ×חר." -#: includes/class-wp-members.php:1598 +#: includes/class-wp-members-dialogs.php:170 msgid "" "Sorry, that email address already has an account.
    Please try another." msgstr "מצטערי×, כבר יש חשבון ×¢× ×”×ימייל ×”×–×”.
    × × ×œ× ×¡×•×ª ×חר." -#: includes/class-wp-members.php:1599 -msgid "Your information was updated!" -msgstr "המידע שלך עודכן!" - -#: includes/class-wp-members.php:1602 -msgid "Passwords did not match.

    Please try again." -msgstr "הסיסמ×ות ×ינן תו×מות.

    × × ×œ× ×¡×•×ª שוב." +#: includes/class-wp-members-dialogs.php:175 +msgid "Password successfully changed." +msgstr "" -#: includes/class-wp-members.php:1603 -msgid "Password successfully changed!" -msgstr "הסיסמה הוחלפה בהצלחה!" +#: includes/class-wp-members-dialogs.php:176 +msgid "Invalid username or email address." +msgstr "" -#: includes/class-wp-members.php:1604 -msgid "Either the username or email address do not exist in our records." -msgstr "×©× ×”×ž×©×ª×ž×© ×ו כתובת ×”×ימייל ×œ× ×§×™×™×ž×™× ×‘×¨×©×•×ž×•×ª שלנו." +#: includes/class-wp-members-dialogs.php:177 +msgid "" +"Password successfully reset! An email containing a new password has been " +"sent to the email address on file for your account." +msgstr "" -#: includes/class-wp-members.php:1605 +#: includes/class-wp-members-dialogs.php:178 msgid "" -"Password successfully reset!

    An email containing a new password " -"has been sent to the email address on file for your account." +"Reset request received. An email with instructions to complete the password " +"reset has been sent." msgstr "" -"הסיסמה ×ופסה בהצלחה!

    ×ימייל ×¢× ×”×¡×™×¡×ž×” החדשה נשלח ×ל כתובת ×”×ימייל " -"שלך." -#: includes/class-wp-members.php:1607 +#: includes/class-wp-members-dialogs.php:180 msgid "This content requires the following membership: " msgstr "" -#: includes/class-wp-members.php:1608 +#: includes/class-wp-members-dialogs.php:181 msgid "This content requires one of the following memberships: " msgstr "" -#: includes/class-wp-members.php:1721 +#: includes/class-wp-members-forms.php:84 +#: includes/class-wp-members-forms.php:350 +msgid "Choose membership" +msgstr "" + +#: includes/class-wp-members-forms.php:1898 +#: includes/class-wp-members-user-profile.php:510 +msgid "Activate this user?" +msgstr "ל×שר ×ת המשתמש ×”×–×”?" + +#: includes/class-wp-members-forms.php:2165 templates/tos.php:20 +msgid "Terms of Service" +msgstr "תנ××™ שימוש" + +#: includes/class-wp-members-menus.php:131 +msgid "Display" +msgstr "" + +#: includes/class-wp-members-menus.php:139 +msgid "Logged In Users" +msgstr "" + +#: includes/class-wp-members-menus.php:146 +msgid "Logged Out Users" +msgstr "" + +#: includes/class-wp-members-menus.php:153 +msgid "All Users" +msgstr "" + +#: includes/class-wp-members-menus.php:167 +#, php-format +msgid "%sAdd membership products%s to restrict menu to a membership" +msgstr "" + +#: includes/class-wp-members-menus.php:169 +msgid "Restrict menu item to a membership product" +msgstr "" + +#: includes/class-wp-members-products.php:342 +#, php-format +msgid "All %s" +msgstr "" + +#: includes/class-wp-members-products.php:343 +#, php-format +msgid "Add New %s" +msgstr "" + +#: includes/class-wp-members-products.php:344 +msgid "Add New" +msgstr "" + +#: includes/class-wp-members-products.php:345 +#, php-format +msgid "New %s" +msgstr "" + +#: includes/class-wp-members-products.php:346 +#, php-format +msgid "Edit %s" +msgstr "" + +#: includes/class-wp-members-products.php:347 +#, php-format +msgid "Update %s" +msgstr "" + +#: includes/class-wp-members-products.php:348 +#: includes/class-wp-members-products.php:349 +#, php-format +msgid "View %s" +msgstr "" + +#: includes/class-wp-members-products.php:350 +#, php-format +msgid "Search %s" +msgstr "" + +#: includes/class-wp-members-products.php:351 +msgid "Not found" +msgstr "" + +#: includes/class-wp-members-products.php:352 +msgid "Not found in Trash" +msgstr "" + +#: includes/class-wp-members-products.php:353 +msgid "Insert into item" +msgstr "" + +#: includes/class-wp-members-products.php:354 +#, php-format +msgid "Save %s Details" +msgstr "" + +#: includes/class-wp-members-products.php:355 +msgid "Membership Attributes" +msgstr "" + +#: includes/class-wp-members-products.php:358 +msgid "Membership Product" +msgstr "" + +#: includes/class-wp-members-products.php:359 +msgid "WP-Members Membership Products" +msgstr "" + +#: includes/class-wp-members-pwd-reset.php:35 +#: includes/class-wp-members-pwd-reset.php:36 +msgid "" +"Sorry, no password reset key was found. Please check your email and try " +"again." +msgstr "" + +#: includes/class-wp-members-pwd-reset.php:37 +msgid "Sorry, the password reset key is expired." +msgstr "" + +#: includes/class-wp-members-pwd-reset.php:167 +msgid "The passwords do not match." +msgstr "" + +#: includes/class-wp-members-shortcodes.php:134 +msgid "" +"This is a generic message to display the form message dialog in the " +"Customizer." +msgstr "" + +#: includes/class-wp-members-shortcodes.php:699 +msgid "Click here to log out." +msgstr "× × ×œ×œ×—×•×¥ ×›×ן כדי להתנתק." + +#: includes/class-wp-members-user-profile.php:58 +msgid "WP-Members Additional Fields" +msgstr "שדות × ×•×¡×¤×™× ×©×œ וורדפרס-חברי×" + +#: includes/class-wp-members-user-profile.php:58 +msgid "Additional Information" +msgstr "מידע נוסף" + +#: includes/class-wp-members-user-profile.php:500 +msgid "Reactivate this user?" +msgstr "ל×שר מחדש ×ת המשתמש ×”×–×”?" + +#: includes/class-wp-members-user-profile.php:505 +msgid "Deactivate this user?" +msgstr "לבטל ×ת המשתמש ×”×–×”?" + +#: includes/class-wp-members-user-profile.php:559 +msgid "IP @ registration" +msgstr "כתובת IP והרשמה" + +#: includes/class-wp-members-user.php:1171 +msgid "ERROR: User has not been activated." +msgstr "שגי××”: המשתמש ×ינו פעיל." + +#: includes/class-wp-members-validation-link.php:32 +msgid "Click to validate your account: " +msgstr "" + +#: includes/class-wp-members-validation-link.php:33 +msgid "Thank you for validating your account." +msgstr "" + +#: includes/class-wp-members-validation-link.php:34 +msgid "Validation key was expired or invalid" +msgstr "" + +#: includes/class-wp-members-validation-link.php:35 +msgid "Your account is now pending approval" +msgstr "" + +#: includes/class-wp-members-validation-link.php:284 +msgid "ERROR: User has not confirmed their account." +msgstr "" + +#: includes/class-wp-members-widget.php:24 +msgid "Displays the WP-Members sidebar login." +msgstr "מציג ×ת הכניסה של וורדפרס-×—×‘×¨×™× ×‘×¡×¨×’×œ הצד" + +#: includes/class-wp-members-widget.php:39 +#: includes/class-wp-members-widget.php:82 +msgid "Login Status" +msgstr "מצב ההתחברות" + +#: includes/class-wp-members-widget.php:46 +msgid "Title:" +msgstr "כותרת:" + +#: includes/class-wp-members-widget.php:50 +msgid "Redirect to (optional):" +msgstr "להפנות ל (רשות):" + +#: includes/class-wp-members.php:1087 includes/class-wp-members.php:1098 +msgid "You must be logged in to view this content." +msgstr "" + +#: includes/class-wp-members.php:1104 +msgid "The page you are looking for does not exist" +msgstr "" + +#: includes/class-wp-members.php:1352 +#, php-format +msgid "" +"You have a linked page in the WP-Members page settings that corresponds to a " +"post ID that no longer exists. Please %s review and update the %s page " +"settings %s." +msgstr "" + +#: includes/class-wp-members.php:1472 msgid "Show forms as logged out" msgstr "" -#: includes/class-wp-members.php:1730 +#: includes/class-wp-members.php:1481 msgid "Show form message dialog" msgstr "" -#: includes/class-wp-members.php:1838 +#: includes/class-wp-members.php:1558 msgid "(more…)" msgstr "עוד..." -#: includes/cli/class-wp-members-cli.php:17 +#: includes/class-wp-members.php:1746 +msgid "log out" +msgstr "" + +#: includes/cli/class-wp-members-cli-user.php:24 +#: includes/cli/class-wp-members-cli-user.php:62 +msgid "Moderated registration is not enabled in WP-Members options." +msgstr "" + +#: includes/cli/class-wp-members-cli-user.php:35 +msgid "User activated." +msgstr "" + +#: includes/cli/class-wp-members-cli-user.php:37 +msgid "Email notification sent to user." +msgstr "" + +#: includes/cli/class-wp-members-cli-user.php:40 +msgid "User is already activated." +msgstr "" + +#: includes/cli/class-wp-members-cli-user.php:67 +msgid "User deactivated." +msgstr "" + +#: includes/cli/class-wp-members-cli-user.php:88 +msgid "Invalid user ID. Please specify a valid user. Try `wp user list`." +msgstr "" + +#: includes/cli/class-wp-members-cli-user.php:91 +msgid "No user id specified. Must specify user id as --id=123" +msgstr "" + +#: includes/cli/class-wp-members-cli-user.php:208 #, php-format msgid "User: %s" msgstr "" -#: includes/deprecated - Copy.php:472 includes/deprecated.php:473 +#: includes/cli/class-wp-members-cli-user.php:248 +#, php-format +msgid "User role: %s" +msgstr "" + +#: includes/deprecated.php:373 msgid "We were unable to validate the public key." msgstr "×œ× ×”×¦×œ×—× ×• ל×מת ×ת המפתח הציבורי." -#: includes/deprecated - Copy.php:476 includes/deprecated.php:477 +#: includes/deprecated.php:377 msgid "We were unable to validate the private key." msgstr "הצלחנו ל×מת ×ת המפתח הפרטי." -#: includes/deprecated - Copy.php:480 includes/deprecated.php:481 +#: includes/deprecated.php:381 msgid "The challenge parameter of the verify script was incorrect." msgstr "הפרמטר המ×תגר של קוד ×”×ימות ×”×™×” שגוי." -#: includes/deprecated - Copy.php:484 includes/deprecated.php:485 +#: includes/deprecated.php:385 msgid "The CAPTCHA solution was incorrect." msgstr "פתרון קוד ×”×ימות ×”×™×” שגוי" -#: includes/deprecated - Copy.php:488 includes/deprecated.php:489 +#: includes/deprecated.php:389 msgid "The parameters to verify were incorrect" msgstr "×”×¤×¨×ž×˜×¨×™× ×œ×ימות היו שגויי×" -#: includes/deprecated - Copy.php:492 includes/deprecated.php:493 +#: includes/deprecated.php:393 msgid "" "reCAPTCHA API keys are tied to a specific domain name for security reasons." msgstr "מפתחות קוד ×”×ימות של-API reCAPTCHA קשורות לדומיין ספציפי מסיבות ×בטחה." -#: includes/deprecated - Copy.php:496 includes/deprecated.php:497 +#: includes/deprecated.php:397 msgid "The reCAPTCHA server was not reached. Please try to resubmit." msgstr "השרת של קוד ×”×ימות reCAPTCHA ×ינו נגיש. × × ×œ× ×¡×•×ª שוב." @@ -2187,10 +2381,10 @@ msgstr "" #. Description of the plugin/theme msgid "" "WP access restriction and user registration. For more information on plugin " -"features, refer to the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2198,8 +2392,87 @@ msgid "Chad Butler" msgstr "Chad Butler" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" -msgstr "http://butlerblog.com/" +msgid "https://butlerblog.com/" +msgstr "" + +#~ msgid "Unblock" +#~ msgstr "ביטול חסימה" + +#~ msgid "Block" +#~ msgstr "לחסו×" + +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "ניהול ×פשרויות קוד ×ימות של reCAPTCHA" + +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "reCAPTCHA ×”×•× ×§×•×“ ×ימות חינמי, לחסימת ספ×× ×‘×תר שלכ×." + +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA מבקש להקליד שתי ×ž×™×œ×™× ×¡×¨×•×§×•×ª מספר כדי להוכיח ×נושיות. ×–×” מ×מת " +#~ "שהשולח ×ינו רובוט ספ×× ×‘×§×¨×• ב %sreCaptcha%s" + +#, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "קוד ×ימות של reCAPTCHA צריך מפתח API המורכב מ\"מפתח ציבורי\" ו\"מפתח פרטי" +#~ "\". ×פשר ×œ×”×™×¨×©× ×œ×§×‘×œ×ª %sמפתח reCAPTCHA ×œ×œ× ×ª×©×œ×•× %s" + +#~ msgid "Public Key" +#~ msgstr "מפתח ציבורי" + +#~ msgid "Private Key" +#~ msgstr "מפתח פרטי" + +#~ msgid "Choose Theme" +#~ msgstr "בחירת תבנית" + +#~ msgid "Red" +#~ msgstr "×דו×" + +#~ msgid "White" +#~ msgstr "לבן" + +#~ msgid "Black Glass" +#~ msgstr "זכוכית שחורה" + +#~ msgid "Clean" +#~ msgstr "× ×§×™" + +#~ msgid "Active" +#~ msgstr "פעיל" + +#~ msgid "Do not block" +#~ msgstr "×œ× ×œ×—×¡×•×" + +#~ msgid "Enable CAPTCHA" +#~ msgstr "הפעלת קוד ×ימות" + +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "הסיסמ×ות ×ינן תו×מות.

    × × ×œ× ×¡×•×ª שוב." + +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "×©× ×”×ž×©×ª×ž×© ×ו כתובת ×”×ימייל ×œ× ×§×™×™×ž×™× ×‘×¨×©×•×ž×•×ª שלנו." + +#~ msgid "" +#~ "Password successfully reset!

    An email containing a new " +#~ "password has been sent to the email address on file for your account." +#~ msgstr "" +#~ "הסיסמה ×ופסה בהצלחה!

    ×ימייל ×¢× ×”×¡×™×¡×ž×” החדשה נשלח ×ל כתובת " +#~ "×”×ימייל שלך." + +#~ msgid "http://butlerblog.com/" +#~ msgstr "http://butlerblog.com/" #~ msgid "Click to log out." #~ msgstr "יצי××”" diff --git a/i18n/languages/wp-members-hi_IN.mo b/i18n/languages/wp-members-hi_IN.mo index a680691908d4d4dba975811d057094d34f74e689..0b5a0244924d0a60099aed7c5ce59ecf84d15a05 100644 GIT binary patch delta 3322 zcmX}ud2miw7{~GF&0+~jWJ9d6B}5X5EcP{)kXS303X)3H(nM=*P%oMWMT@s|8B?W9 zbu7hebXudOD4k9h?Nq6;%owef(W-xHs@3oB-m7Qw+|Rk^zVE%~Jm;MI=CxD4(|djX ztFd8Qj1nMP5J$qy&R|h}4wTY{W~!EX&cO)I7kaM19M0Ea3ZB3?yyabgi28orNY@yQ z<-9p2n)xk*N^=?tFagUk2A3dxvGv#%H(@j$@vfitu3x|=v|q-?cpue)h$tS4txz3E zM%_QtYafEmc)pFKQjZI>P+y#f`d}^cXWKaF!Fy5Hk6|7B2K9go-uYE*!1+y7hVFUo z554nHZldo+VIxeyx;)>Ksia~ChTtSr21-yPtHM02MUCV*9>BB6U~Lh1>xVT+w(T^k z{XFt)yM`LjUF6TgxVi3=fPQ_UH5H8{4Lf5F>WihQFU-Z(xWa3H2i36;P&Yn{8u1m> z6x>4Q)*hkmm&ky=b(``V0fB>X2>jAN6+r4HBx{i$Hw`o452auHRAo4j7QN) zDQa8ZLQO$9c~wR_cn-oO&ZnbNU4vRn2T>WhjLO6fR0n^-$@mE8qJJ`ZpGxIR)FMh{ zFHXYQn1-jZC*DJKB#nboI1D>rC62-Xj>a1}26I}P@n^Lh)PY^7_sSmJj8%++0sGCz zu$0mWR7#UjnMlDx%tWPh8R~to&bz)5m#|&lL@la#UJ|kuYAtodB+SQ!SdNqNCmex! zj3Q3^zlMtDqr$?pLpUDKpcYLFR%Q=O!)%;^gYhlwj@OZFTVh8>i+LRMplPU% ztwpBUwxTk85E;CEj`YQTML#>sqWP9S*w(W*a&H@tTBXZTi)AB*pjMa`Sty6$n1S1| z8g-vUR^kJ8OEzi^q^Fx5#zIsF{>2PzlR^IZjE&|@Jz9pXaVOF_`wW$`+o+Cabm4W4 z15lseh+MLxI0$BrA*j&!nN82Ho&0Ov3v(1mnB% zzQ@Tp2%9hux?u^jBW(|k!;|eVg91Au;{1ACDM3%1v4fLr7KJe{PSGoekvVS+x5a&nsGjRJ^uico z6H!To5-Jrg&hZtmz6iBfTWS)ksLUri6Pm<2geG+sp^`?t?9|xxIFab@owxT~iv>i0 z(59|SFg?!d0-H@#6Iy)@3DRrp3FlK$PQ~mw&nCzMaW>&{WPdvUrfLG$5bS4X62Vpy z;Y2^3P-+Nm0Tzt2gtfZ#L!eSlyg)cB3sZII6J{9@f>T3IYe7x0I`(tzr4GHXsy%;*SqAbuRDlT|Eu1>w+o#uPO z183T;YScA7Gb=qaFDWaxXIJXE!3pgz`9gCtvV+;lk)eSpoi+r*Qili2Qu~Gkz8xAF lEKVO+CwM2jLr7p=N_rr%TkGJ!Zlwvq!$sxMft6)({{apqUb6rI delta 5752 zcmZ9P3shBA8pk(aNfaOgX69pqA(n7O5iKH&DfNjkjUS%J(v`XZKJM~oP+lEzc?!;=e+Cx9 zZ(%mn8P2>}P`+R2av2;=e>J>Bsi>-_aVY~^VJ_@}S?~nB5WWFNz~91r_#VuJ-@=Pv zDjk`h3uRs*BnDLkFNQPW7+49#F$0c-t?&Z&S6gVv#@pQ&d*L|xy)YHN2Ia$FLYemw zTnxW~_@K&0ISyS5WnK+DA2veSDCqXvp#*dn6a{z5IQy$^cc4cG=syMdPaWk)7I+n2 z0pEhj@M|a${|iclBk9bBlb}ew79NEgA=yxw=)Dk5fTGwfP{wbEQHfv^jj?b$ln4(% z)>h9!S@10=AN~%CLm$Iw@G~gik0xxHp9d$wnNY^7p*U#3GS~q{fn!h$lDgNRZ2TdV6n+CI!tY@vyp&C6 z!unkFpG@O%2Bc_Sh7#c!C=tH{#j*FHM0gg8V}FP8-3U7K;8a)$y>J110A2~-ftSM( zc+-)jlm||ReR$0h>fI>eNzOlovfZrFk!BE%-qbXg^Pot%9Fk_W4pu-P zl!*J`6nGkn)Nv@s`wJ*3O6ACjBGIXC<2tArsE3ll?{|Ke%N+&3_9)@8N{1u!F{|lKCRb{v#QdYwP*ala@9#{pxgg3yeahq?{ zZYT~Mfp5a&@L|}loygPj9BH$mD0?{+MM~gucoh_7?}rshQKk0K2r%#=w@W9i#2dLt z-h}eu+pv>!_Xj9NcRjiaZ-l6+YN3W(U@P1QMUfl|VkK;W)UkR6O3Hrk@?$uM{nh6* zZi4w!ok+L9rSyLTMUk;o5K^fHP-UzQ>IJE_eL{CF;>`OQaj-KU2 zHWSMG4N#=r2d{_6q0E9DWWZC9~%^ zQZ0f6qt-&4R@-1BJPl>xeDa{-Qdj|f@I}}UuZ4bgm35E9vG5021IKU%pNG*V8vAHW zo=2s^*I_0so$utX9Olxmf-+tYDR9*WNxRw$@makMJ7Ch)$PG8cBk(Njg}WA@1}vdM zujF`bgL6{I|EuNBKOp{t``Jt=y3WbXBFML@4$4Lcp%m4xAu6hGU3!+X5PdJi2h{^b zfe+vq*u6}t26z}s%5o?ad{Kq4lKoXZ4c1b};cEDu%a!Qnr+*M`h8ZgyC3Znk;sBIX z^}|*01^5F@TdCB|6kRHXF$S8ve46n)xy?R;Q@G8#;D~B2F7{Us(U9CuX7_b)Ev$t{ z;Xhy&2@@uv-!I@-@J9H;S|>%>eDpONX}AMsuXl3Y!=q-KGF+o)n#z0ryAZo|0=yCB2%BgOV8_9S*chT3W`#$NW{g{e@~yb}|3 z8!>rAF=|ugVE4)WFAB&b)hcIFZl*d+B9zC(vN3|SpDXx%#BC>H9-SH3J=i2Hh*9k7 z7OWXdd=OkchW$h?WI2xrpmMFOi?XBbv_e=i_Txv&W-La6hn|VFI6`VShW_e7Y$vt_ zljmVf ztuK`&PnQGdestSU!08xAM%{*O#^hPg{zK1JS{;}Vn~zPwyx3*f4VXOJ9Hj|~Yy#GVEym=@#9FX%gPHfxDaPbkGjPjAB}r+1qpnF`=QqM(t1Ep` zeodpZa8p><1)H1AK*S7%btK5%k&YG?Zx8BraZHEnj6lHj z>iSTynfPmi!6up45(>64t70z-#e zjOJQe?TtP^U;4vA90{RD#209=bu?Nd!Db^uEaE~~2kUjv@3kEWd-Up{?g+N(1~a1l zqOGh~q>X^r{ubAn%FD1e>grlUh~w|jUSESR;)`|?jfBA}OK`HIHt6lp?Y=-bPgjsL zuNfg};UeAU3;XQobU}DHC%WCNW!x+Xt6?Dt*FYiD#D%&#{PEQim77IPLA3emT(ugb zroY9O+Ht4TbewUOsPzZynnVH#NCyKFWk@sH;7QmoWZu#0qoxR0FRogqo6L?P^b3Tk zEcqC%44vO%mqNa+igcYSDb1JZ9=#s<5LSnM4FTQSqU(v>kWeL#gm{@;VC|fA->8z} zlCt8NGxdx)bIVGLOJ)sB&>tkFlzL_ie3zG=GOjxwdnFz_5%1lu2 z1rKHQ#(THMV@G-SM7;Ozc&yLbRj_*0DSO^Ydyo&Fv{uy=4E(QPeDa0I_?F4BcyE`L zSv|=*T%2Q-lwMqXnnmno`<>9&UlO=7CFdgM|l~K-D6!^UTAeqO&chf zy6*h6>cMlRt;N%GEz>h5ovHXOOEG(3vu8@O_3-rUbT*~WOZ?kzb(Z88^=|cO=lBi6 z-t^vh?3sAX_4OGiu({UZS(jNWSC30l)@w_qS^G*>r8-KSP*&c8+!Hfa=BA&D$DWPH zUa~hnG*DU5keM@FPQypiG8W~nVBLGrM#Qi+IUVoafp3TK5;(g$LNcM-_1cEWf7li% zMxXDxtcBGRqmF=m@z_acbjMJz$cL2l`*`!5d@PE}PRT%KC;_Bcn5RdiPjxs|gCRBw}Q?i9b;4DhYiK~x-8X6i7 zKfzU7Ea%N|P)D54Mv?&Z*lKN^pA#iE@my-n0re@BiaP>l3HC-8=_4Qh5O_j9iWuKR zB>~iu`nD&zmEms2%Y*iCk9`=B+CUE%obcqkzvUeKp2J-b`noH1hSK4BOa4l za28}%!o)nws2XoY%P$NTopXVab~{@X27a+P8}4U@y`D%aPTOjbdeJ)J;)%!Xyom-9 zBn~hqCcz^T1Bh}&TVJinjnZe`lYGugw_@G&{FCp16&63X+hY^x-2JaD2H-nB{u6|\n" "Language: hi_IN\n" @@ -16,139 +16,147 @@ msgstr "" "_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n" "X-Textdomain-Support: yes\n" "X-Poedit-Basepath: .\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" "X-Poedit-SearchPath-0: .\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "विषय" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "शरीर" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "विकलà¥à¤ª" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "फ़ीलà¥à¤¡" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "संवाद" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "ईमेल" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "नया पंजीकरण" +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "पंजीकरण संचालित है" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "पंजीकरण संचालित है, उपयोगकरà¥à¤¤à¤¾ सà¥à¤µà¥€à¤•ृत" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "पासवरà¥à¤¡ रीसेट" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "वà¥à¤¯à¤µà¤¸à¥à¤¥à¤¾à¤ªà¤• अधिसूचना" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "रतिबंधित पोसà¥à¤Ÿ, (या पृषà¥à¤ ) पà¥à¤°à¤ªà¤¤à¥à¤° लॉग इन / पंजीकरण ऊपर पà¥à¤°à¤¦à¤°à¥à¤¶à¤¿à¤¤ करता है" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "उपयोगकरà¥à¤¤à¤¾ नाम लिया है" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "ईमेल पंजीकृत है" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "पंजीकरण पूरा किया" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "नवीनीकरण उपयोगकरà¥à¤¤à¤¾" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "कूटशबà¥à¤¦ मेल नहीं खाता" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "पासवरà¥à¤¡ परिवरà¥à¤¤à¤¨" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "उपयोगकरà¥à¤¤à¤¾ नाम या ईमेल जब भूल पासवरà¥à¤¡ रीसेट करने की कोशिश मौजूद नहीं है" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "पासवरà¥à¤¡ रीसेट" +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + # @ default # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "सेटिंगà¥à¤¸" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -#, fuzzy -msgid "Block" -msgstr "डिफ़ॉलà¥à¤Ÿ रूप से बà¥à¤²à¥‰à¤• पोसà¥à¤Ÿ" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -157,12 +165,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -171,14 +179,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -204,329 +217,397 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" # @ wp-members #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "निरà¥à¤¯à¤¾à¤¤" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 #, fuzzy msgid "Export All Users" msgstr "निरà¥à¤¯à¤¾à¤¤" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" # @ wp-members -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "सदसà¥à¤¯à¤¤à¤¾" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" msgstr "" -#: includes/admin/class-wp-members-export.php:65 includes/class-wp-members.php:1523 -#: includes/class-wp-members.php:1546 -msgid "Username" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" msgstr "" -# @ wp-members -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "सकà¥à¤°à¤¿à¤¯?" - -# @ wp-members -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "समापà¥à¤¤ हो" - -# @ wp-members -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "पंजीकृत" - -# @ wp-members -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "IP" - -# @ wp-members -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" -msgstr "हां" - -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +# @ wp-members +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "समापà¥à¤¤ हो" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +# @ wp-members +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "हां" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 #, fuzzy msgid "Pages" msgstr "डिफ़ॉलà¥à¤Ÿ रूप से बà¥à¤²à¥‰à¤• पनà¥à¤¨à¥‡" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time period. For " "example, if user who register August 1st would be part of the following year's Sept 1 - Aug " "31 membership, set this at 1 Month. Leave blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "Restricted Message (displays when a user does not have access to a membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "" + +# @ wp-members +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "सकà¥à¤°à¤¿à¤¯?" + +# @ wp-members +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "पंजीकृत" + +# @ wp-members +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "IP" + # @ wp-members #: includes/admin/dialogs.php:117 msgid "Your WP settings allow anyone to register - this is not the recommended setting." @@ -706,164 +787,138 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" -# @ wp-members #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "ReCAPTCHA विकलà¥à¤ª पà¥à¤°à¤¬à¤‚धित करें" - -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books while blocking " -"spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA à¤à¤• मà¥à¤•à¥à¤¤, सà¥à¤²à¤­ कॅपà¥à¤šà¤¾ सेवा है कि पà¥à¤¸à¥à¤¤à¤•ों को डिजिटाइज़ करने में मदद करता है जबकि अपने बà¥à¤²à¥‰à¤— पर सà¥à¤ªà¥ˆà¤® " -"अवरà¥à¤¦à¥à¤§ है." -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove that they are a " -"human. This verifies that they are not a spambot while also correcting the automatic scans " -"of old books. So you get less spam, and the world gets accurately digitized books. Everybody " -"wins! For details, visit the %s reCAPTCHA website%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" msgstr "" -"reCAPTCHA commenters करने के लिठपूछता है दो पà¥à¤¸à¥à¤¤à¤• से साबित होता है कि वे मानव हैं सà¥à¤•ैन शबà¥à¤¦à¥‹à¤‚ को पà¥à¤¨: " -"लिखें. यह पà¥à¤·à¥à¤Ÿà¤¿ करता है कि वे à¤à¤• spambot जबकि सà¥à¤µà¤šà¤¾à¤²à¤¿à¤¤ पà¥à¤°à¤¾à¤¨à¥€ पà¥à¤¸à¥à¤¤à¤•ों का सà¥à¤•ैन भी सही नहीं हैं. तो तà¥à¤® कम " -"सà¥à¤ªà¥ˆà¤® मिलता है, और दà¥à¤¨à¤¿à¤¯à¤¾ सही डिजीटल किताबें हो जाता है. हर कोई जीतता है! जानकारी के लिà¤,%s reCAPTCHA " -"वेबसाइट%s की यातà¥à¤°à¤¾" - -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "reCAPTCHA कà¥à¤‚जी" -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" key. You can " -"sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"reCAPTCHA à¤à¤• à¤à¤ªà¥€à¤†à¤ˆ कà¥à¤‚जी की आवशà¥à¤¯à¤•ता है, \"सारà¥à¤µà¤œà¤¨à¤¿à¤• \" और \"निजी \" कà¥à¤‚जी शामिल है. आप%s मà¥à¤•à¥à¤¤ " -"reCAPTCHA कà¥à¤‚जी%s के लिठसाइन अप कर सकते हैं" -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "सारà¥à¤µà¤œà¤¨à¤¿à¤• कà¥à¤‚जी" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "निजी कà¥à¤‚जी" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "थीम चà¥à¤¨à¥‡à¤‚" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "लाल" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for the new CAPTCHA " +"type." +msgstr "" # @ wp-members #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "सफ़ेद" - -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "काले गà¥à¤²à¤¾à¤¸" - -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "सà¥à¤µà¤šà¥à¤›" +msgid "reCAPTCHA Keys" +msgstr "reCAPTCHA कà¥à¤‚जी" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" key. You can sign " "up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "hCaptcha requires an API key. You can sign up for %s an hCaptcha API key here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 #, fuzzy msgid "Characters for image" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 #, fuzzy msgid "Number of characters" msgstr "कà¥à¤› अंशः दिखाà¤à¤" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 #, fuzzy msgid "Image dimensions" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 #, fuzzy msgid "Background color of image" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 #, fuzzy msgid "Image type" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin installed and " "activated." msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 msgid "Update CAPTCHA Settings" msgstr "अपडेट करें CAPTCHA सेटिंगà¥à¤¸" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 msgid "CAPTCHA was updated for WP-Members" msgstr "CAPTCHA WP-सदसà¥à¤¯ के लिठअपडेट किया गया था" @@ -936,8 +991,8 @@ msgstr "à¤à¤• कसà¥à¤Ÿà¤® ईमेल पता सेट करें" # @ wp-members #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "(वैकलà¥à¤ªà¤¿à¤•)" @@ -946,23 +1001,27 @@ msgstr "(वैकलà¥à¤ªà¤¿à¤•)" msgid "Set a custom email name" msgstr "à¤à¤• कसà¥à¤Ÿà¤® ईमेल का नाम सेट करें" +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "ईमेल हसà¥à¤¤à¤¾à¤•à¥à¤·à¤°" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "ईमेल अपडेट करें" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "WP-सदसà¥à¤¯ ईमेल अपडेट की गई थीं" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -979,279 +1038,292 @@ msgid "Field Manager Documentation" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "आवशà¥à¤¯à¤•ता है?" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Edit Field" msgstr "जानकारी संपादित करें" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Add a Field" msgstr "जोड़ना" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "कà¥à¤·à¥‡à¤¤à¥à¤° लेबल" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no spaces (underscores " "are ok)." msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "फ़ीलà¥à¤¡ पà¥à¤°à¤•ार" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "पाठ" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "textarea" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "चेकबॉकà¥à¤¸" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "पासवरà¥à¤¡" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "पà¥à¤°à¤¦à¤°à¥à¤¶à¤¿à¤¤ करते हैं?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "आवशà¥à¤¯à¤•ता है?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 #, fuzzy msgid "Checked by default?" msgstr "जाà¤à¤š की?" +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "Selecting \"after\" will generally display the label to the right of the checkbox" +msgstr "" + # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 #, fuzzy msgid "Stored value if checked:" msgstr "चेकबॉकà¥à¤¸ के लिà¤, मान संगà¥à¤°à¤¹à¥€à¤¤ यदि जांचा जाता है:" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "विकलà¥à¤ª का नाम होना चाहिà¤, option_value" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "अधिक जानकारी के लिठपà¥à¤²à¤—इन साइट पर जाà¤à¤" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 #, fuzzy msgid "Add Field" msgstr "जोड़ना" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 #, fuzzy msgid "Registration Date" msgstr "पंजीकरण पूरा किया" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -#, fuzzy -msgid "Active" -msgstr "सकà¥à¤°à¤¿à¤¯" - -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 #, fuzzy msgid "Registration IP" msgstr "आईपी ​​@ पंजीकरण" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "फीलà¥à¤¡à¥à¤¸ पà¥à¤°à¤¬à¤‚धित" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "WP-सदसà¥à¤¯ फ़ीलà¥à¤¡à¥à¤¸ अपडेट की गई थीं" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users " -"Guide. A Quick " -"Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com." +"to the online Users Guide. A " +"Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2382,9 +2536,93 @@ msgid "Chad Butler" msgstr "" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" +msgid "https://butlerblog.com/" msgstr "" +#, fuzzy +#~ msgid "Block" +#~ msgstr "डिफ़ॉलà¥à¤Ÿ रूप से बà¥à¤²à¥‰à¤• पोसà¥à¤Ÿ" + +# @ wp-members +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "ReCAPTCHA विकलà¥à¤ª पà¥à¤°à¤¬à¤‚धित करें" + +# @ wp-members +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books while " +#~ "blocking spam on your blog." +#~ msgstr "" +#~ "reCAPTCHA à¤à¤• मà¥à¤•à¥à¤¤, सà¥à¤²à¤­ कॅपà¥à¤šà¤¾ सेवा है कि पà¥à¤¸à¥à¤¤à¤•ों को डिजिटाइज़ करने में मदद करता है जबकि अपने बà¥à¤²à¥‰à¤— पर " +#~ "सà¥à¤ªà¥ˆà¤® अवरà¥à¤¦à¥à¤§ है." + +# @ wp-members +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to prove that they are " +#~ "a human. This verifies that they are not a spambot while also correcting the automatic " +#~ "scans of old books. So you get less spam, and the world gets accurately digitized books. " +#~ "Everybody wins! For details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA commenters करने के लिठपूछता है दो पà¥à¤¸à¥à¤¤à¤• से साबित होता है कि वे मानव हैं सà¥à¤•ैन शबà¥à¤¦à¥‹à¤‚ को पà¥à¤¨: " +#~ "लिखें. यह पà¥à¤·à¥à¤Ÿà¤¿ करता है कि वे à¤à¤• spambot जबकि सà¥à¤µà¤šà¤¾à¤²à¤¿à¤¤ पà¥à¤°à¤¾à¤¨à¥€ पà¥à¤¸à¥à¤¤à¤•ों का सà¥à¤•ैन भी सही नहीं हैं. तो तà¥à¤® " +#~ "कम सà¥à¤ªà¥ˆà¤® मिलता है, और दà¥à¤¨à¤¿à¤¯à¤¾ सही डिजीटल किताबें हो जाता है. हर कोई जीतता है! जानकारी के लिà¤,%s " +#~ "reCAPTCHA वेबसाइट%s की यातà¥à¤°à¤¾" + +# @ wp-members +#, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" key. You can " +#~ "sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "reCAPTCHA à¤à¤• à¤à¤ªà¥€à¤†à¤ˆ कà¥à¤‚जी की आवशà¥à¤¯à¤•ता है, \"सारà¥à¤µà¤œà¤¨à¤¿à¤• \" और \"निजी \" कà¥à¤‚जी शामिल है. आप%s मà¥à¤•à¥à¤¤ " +#~ "reCAPTCHA कà¥à¤‚जी%s के लिठसाइन अप कर सकते हैं" + +# @ wp-members +#~ msgid "Public Key" +#~ msgstr "सारà¥à¤µà¤œà¤¨à¤¿à¤• कà¥à¤‚जी" + +# @ wp-members +#~ msgid "Private Key" +#~ msgstr "निजी कà¥à¤‚जी" + +# @ wp-members +#~ msgid "Choose Theme" +#~ msgstr "थीम चà¥à¤¨à¥‡à¤‚" + +# @ wp-members +#~ msgid "Red" +#~ msgstr "लाल" + +# @ wp-members +#~ msgid "White" +#~ msgstr "सफ़ेद" + +# @ wp-members +#~ msgid "Black Glass" +#~ msgstr "काले गà¥à¤²à¤¾à¤¸" + +# @ wp-members +#~ msgid "Clean" +#~ msgstr "सà¥à¤µà¤šà¥à¤›" + +# @ wp-members +#, fuzzy +#~ msgid "Active" +#~ msgstr "सकà¥à¤°à¤¿à¤¯" + +# @ wp-members +#, fuzzy +#~ msgid "Enable CAPTCHA" +#~ msgstr "CAPTCHA का पà¥à¤°à¤¯à¥‹à¤— करें" + +# @ wp-members +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "पासवरà¥à¤¡à¥‹à¤‚ से मेल नहीं खाती.

    कृपया पà¥à¤¨: पà¥à¤°à¤¯à¤¾à¤¸ करें." + +# @ wp-members +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "या तो उपयोगकरà¥à¤¤à¤¾ नाम या ईमेल पता हमारे रिकॉरà¥à¤¡ में मौजूद नहीं है" + # @ wp-members #, fuzzy #~ msgid "Click to log out." diff --git a/i18n/languages/wp-members-ko_KR.mo b/i18n/languages/wp-members-ko_KR.mo index b83d8677a373528ca4fb292e1b5c55f7e1e73280..c031b64251f4ec1519691b6316388c7b9aef8fbf 100644 GIT binary patch delta 4830 zcmYk;dtBGm9mnzW6G0U41}LHk-Vnjd4-gb*kTda0lBVHYDib27$udKI`Kl42w?XVShX^$zW3y0z`9E%#`denJuqdGo; zt?)B!jCI%M2$uq|#yMrsZt_b}(MCH@^XfV;LG zOz%`p8=Q|R*aUZ=CiEUE10NuN<_sTA=-*tW5{ox56hr7O5nG^Amx=0l5bDBl*c_*$ zW>jInUyiJvsY0Firu8stAfMXrFQF!I8GV}REhdfoezDc09(=PDITl z2QzRu_C_D-#=ERXQ5}DR$@mv+ghAXynGT5|{~R+h9LPj3>INmKj>}OqT!`w>kBrf5 zu;tS7R4Eg~3>dy8pMR%!F}~G8l(&B;Amb7 z(R%)8(~CCGGAzbQ)CljO);OrEJM$P+>b$7T3}mGW$K_7p0! zGjSp=!I}6s^i85NhCJrr9-M%;uqTd8a#LT9O8Gw2z-}VRG2!HwzKs`0<9N)+ZTJY@ zMV8$RXLLbWf+ul0zKW?S!YHzIgQTahPvP;X5k&wyWh(wb>oLnn{qN1 zVi`8Y3#b%d#&Eo5y=A}u9<>yqJfkf!5p`c*KPuWJBe4>vqLX^;M7th!!?<+!O_z-N zKG(MMP??y9Ox`?=n#g8sg}X5lk6CL`1GtWCZlAeFMKg%)>+b%psF{vLb@T*k0HvrI zRG?=1Thxu#qdMG)I{&csIO@J1VHDP&&i@By;CHC~XZp~JEBfLb7!~~HNx#U84uWY z46ilKu!prDYQRHKnVNvQuFSRh9*VgWXJA#d6NOfl*lWkUR5v*q-(l zRH~1lmhv37!|S%~3mW2{5Q`o8qBrWqJk;}Fgu2lZoPb+UDZY>Zz(Kt(BCh+4}^)Bvh50r%rC@d9qdLBrUPcm)e_8hNb1 zYGk=h?g;lElIJm>_8E-Fj{Iv|fpueNeS>MZ z2fIA%{)p6K9PQ7o_feZPcC>q4S8FQ%jN{p;3BHaxZ##z4zu7~Dr8R#hR30I8{B`1w zgbLYqUN#4v7XQuQbYiS+zmMufDOY)(SVinmgAzi_A~ew+gi02new@Oxn3stJVk7Ys zq1n$M_7bs#%7=tTzfBDa`^eexJ)M^OKOmdmDING!#wy*W`8}Q?^ipa>kT9R~yw9ca zYvN6!q3EgD+0eju2(7n@_6MuxY{ad2l+fC%%p+JS!-Ha;AygIyO{KU4`;LnLJL??S}8kP~giM94v17Wr@Uioir z8_lr=@tkdoB}6=NRt-uOv5*KRl8N1fik@+m4Ma7;`^mRDR{+{J-!g>dlBjgx;VkFA(WOKGBQVPc)SCR35X9 zrON-K#9?B!J@^*BL98H75dDdU(wNF#HVVv7N(%AUdKb1#>*Y=D<;_e;%@~lD z-piZee=_yUpuWA+17p%IdIH|QeLeoU8DB=!tzJ~OVc(5at4!UB^#NbzzdZix{&NCj zvhD>1iXN!<_>bqL1^$!cZ5GHJ@y|wqwOUhQq~?|;t0(0e{S^L^hl=bZO_ zpZ9&wgy;69eSIt~dZBm6dW+)|;!5K7%PcE5&9c7JU1u$8P9MwajB`B~V;Ac8dlut3 z>R}v-NAO$tCi2hvgb!W+6?VdmzV7q7;uV$^wfa%$#}`ArFK+aliM=^L9|z*MaWGaR zH(EPz4j#mAm_S|kKd27$;iDIhLS26oX5eh>i1TqM?OTf|^x#A}a<8=s)$=_#1&?7@ zOrak573u+9>9ro%3;Sb#)Ii4Yq5EfHPh5`b;A*d4g=%Lreuwt0eH6&LbtO;Hh=-w4 zJ`rilnvVMZ9vp-#@N%ri5x5bR;%86|pG4jFDo)1_P_sE?fIHA^)OFJ^sySIgK{wos zx^RtGUyo{d2kN@Ls1ZGd%D@j$seK;RfuEqRd&{f8>(xI-{#gk=G_a1$(|GJYko;#+ zxP=pXaM-g3)o?vtkB!&?e~Oxd*O5V4@8bmg0(E~T=}|`}qo#BYs==j5lC6BtDm+HL zb`bejkEgP-)Zi@CT-||F@jletH+bipQ5iag8qq7L%zc1r_zP4=w3T$e7pemzaU|xT zp0^CO23AHXaF4YPHL{(kjx^&9cmg%o@1q+21l7P7cnx;C$~`{R|L`3h5NiqZ;}E)zD|C8~%p6p~KZ~O8cTxISk3VbrY(iccB`37a4z*tiW0 zL1iuvmEswwfh|B~Y%!|ig{bGQ!)vww_fWWr6E9*Reua6sVu(9udvFT%b2tgphPvnT za1`}?ti-KYmB#9(ch}-W!`u`f9PX~MR-`s5xGT8bBQ?)kpDO{1FE68q)OuZpW$k$5G^e8HKFt z*}M1{YAQ~mrr^)04rbE2=6o)aJ*yNKUk-u4H{r{81fRgbXg33C zS?<(y$s+$+9EKB}Fb6fVNq9Ls*%ZQv5peXteP&>Pqn zKSdw@9rc_CCb;i|64caGAZsUTRa5B7iS?e_P%n->sJU!HjpQ7vpWk)zJO86xVq5*H9g~fZ8pe zqdMAyG>pK3sQag(GO-BNa4D)o5!8SlMrB|h_N0C55CwIh1$DzY&sR|myopNbd#Db4 zj%3x@A}oAsLY~{QH)+p6~fMW>S9%M_~%PVt?i_gZ8aq6f}bCQ9Yi71{dHeEW>?x9v{VZ zcet$gbXtt%J0zlueuscpsK_zvp5@ei!Vad)z{%PBldp%jNNa$guR zR1eSMpYRPlfiEm}f3<>3+(o(8a|d?j`xexFFM7U?%c;ME-7xnqvdYv>$A_rjcQ^Up zO5yz7?gNVNaT^FB*Et6-Dd+fiJ}-D>q10=^{e*ap_&)IqqA#K2dg2Mi zicy2r&+jqKe-8>hiSvZAaq;*mg-t{z!J2dyTLtR)88O}|@z)NXCNu>)j=NYt_sqxN zc;zP4cGvpS(Wv?VmQ!R0ct$)!o=>9Yj}2lyN1PtH)22WA~A$mLcC3^ zBYsHeXeM4Db`S+bka(ZCn%F?p6LSdX|NrP5Z+Z5^mBfw28^lvY5uxK%7w6~r70Q#n z`Z+vA1iZR_Gp_K;>~3fKmf=gp4~U(_heUKbA3By2k2odw?d27nUn!LzBCaGJCvG5g zoFZC@WyAqOM=mkjDY+l}U>i|M9lT znCX<F9wdHD{EE==Cb5SYq>6WJ#*V}@n&e>=HWHnQrwJWXiG#$o z#CHiDzavHvj}m^uM~ov@5DyRoiG_rYu`bqc@fNRa#s0U~4>JlP{t7#Orgu(S&k|q3 zYBRgU7YkmhaKVX98ArrC-f}z52R%}(jMco3v{1V&DoW5|$ z%sJEJ&-I&=-oqF071>;M@#L2SYtv%E!2`zKoF6h{rnsLAOKe}*Hjz-3@fG>}fh=ob z$Y0@$*k+zxWi2evFYymx(9O&1CZ=#T%B88)nx3V(r@t>UO%Qs$)E?M}7rcE-zu zGhIr724sQ(jWT37TaX|({d;I9JV@=M)yz#lC zv&Y50%KS7vH!COp@#tTtW$bQ9)|`l+9y1}W_l!$+Q}Xzc#FitmKW2Y6B(-U4;_zc8 zS+hU2vC&G_*CZQT5_NS}a!Z3XlcgPqf0Xmrv=JMQCigTa_tqw!*<=#CY7?95j4o`h zOE#V{$wOz7k8Eu_zCPxg(kDH+vo`kOt%K6CV!zC-?B(qplXAL}+FcjFZQR%CUD{_U zK5=c#r8YEO+*+v(v77TIq%X1y<7@JA zx^#2L=G?cxA%5VN&pTw?Q_RwcZ=XHj^7d_}5hS+8+FI8$D!Oix8;&OSZcR3}CJ$42 zx{;Bl>UXuZ9yiH`8hT-pCpIy(WKDxfZf;6GSEqA{$7@a7@rGpMF7lb&(UN$IZ0y~X z*#8vwCbrik4m27%-gfe6s=hg~<*_KE%2MXqzP~ZqNIRRGQd?US2O1JBk8;+K|HPK9 z>OpFEJ$=zrnva{r;qSIzoouWziQ~;&}|QL4VdBsR2Ys(ARnY>?!Wrx{_C zMpBzwhlkZs9+Eh!CN5_8n@Mq!bF?LKh-)xw~ z@$KJim!XCgpeD&IE4=*~8g#\n" "Language: ko_KR\n" @@ -11,7 +11,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;" "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n" @@ -19,135 +19,144 @@ msgstr "" "X-Poedit-Basepath: ..\n" "X-Poedit-SearchPath-0: .\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "제목" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "바디" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "옵션" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "필드" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "대화" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "ì´ë©”ì¼" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "새 회ì›ê°€ìž…" +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "회ì›ê°€ìž…ì´ ê²€í† ë습니다" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "회ì›ê°€ìž…ì´ ê²€í† ë으며 ì‚¬ìš©ìž ìŠ¹ì¸ë습니다" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "비밀번호 초기화" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "ê´€ë¦¬ìž ì•Œë¦¼" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "ì œí•œëœ ê¸€ (ë˜ëŠ” 페ì´ì§€), 로그ì¸/회ì›ê°€ìž… í¼ ìœ„ì— í‘œì‹œë¨" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "ì•„ì´ë””ê°€ 사용 중입니다." # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "ì´ë©”ì¼ì´ 등ë¡ë습니다" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "회ì›ê°€ìž… 완료" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "ì‚¬ìš©ìž ì—…ë°ì´íЏ" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "비밀번호가 ì¼ì¹˜í•˜ì§€ 않습니다" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "비밀번호 변경" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "분실 비밀번호 초기화 시 ì•„ì´ë”” ë˜ëŠ” ì´ë©”ì¼ì´ 존재하지 않습니다" # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "비밀번호 초기화" +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + # @ default # @ wp-members -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "설정" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" -msgstr "차단 í•´ì œ" +msgid "Unrestrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -msgid "Block" -msgstr "차단" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -156,12 +165,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -170,14 +179,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -202,272 +216,289 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" # @ default #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "내보내기" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 msgid "Export All Users" msgstr "모든 ì‚¬ìš©ìž ë‚´ë³´ë‚´ê¸°" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" # @ wp-members -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "구ë…" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" -msgstr "" - -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" msgstr "" -# @ wp-members -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "활성화?" - -# @ wp-members -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "만료" - -# @ wp-members -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "등ë¡ë¨" - -# @ wp-members -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "IP" - -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +# @ wp-members +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "만료" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 msgid "Pages" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -475,57 +506,110 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "" + +# @ wp-members +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "활성화?" + +# @ wp-members +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "등ë¡ë¨" + +# @ wp-members +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "IP" + # @ wp-members #: includes/admin/dialogs.php:117 msgid "" @@ -725,147 +809,123 @@ msgstr "" # @ wp-members #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "ë„ì›€ì´ í•„ìš”í•˜ì„¸ìš”?" -# @ wp-members #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "reCAPTCHA 옵션 관리" - -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA는 무료ì´ë©° ì ‘ê·¼ 가능한 CAPTCHA 서비스로 블로그ì—서 ìŠ¤íŒ¸ì„ ë°©ì§€í•˜ëŠ”" -"ë° ë„ì›€ì´ ë©ë‹ˆë‹¤." -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" msgstr "" -"reCAPTCHA는 댓글ìžê°€ 사람ì¸ì§€ ì¦ëª…하기 위해 ì±…ì—서 스캔해 ë‘ ê°œì˜ë‹¨ì–´ë¥¼ ìž…ë ¥" -"하ë„ë¡ ìš”êµ¬í•©ë‹ˆë‹¤. ì´ê²ƒì€ ìŠ¤íŒ¸ë¡œë´‡ì´ ì•„ë‹Œì§€ 확ì¸í•˜ë©° ë§Žì€ ìŠ¤íŒ¸ì„ ë°©ì§€í•©ë‹ˆë‹¤. " -"ìƒì„¸í•œ ë‚´ìš©ì€ %s reCAPTCHA 웹사ì´íЏ%s를 방문하세요." - -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "reCAPTCHA 키" -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"reCAPTCHA는 API 키가 필요합니다. \"public\" ë° \"private\" 키로 구성ë©ë‹ˆë‹¤. " -"%s 무료 reCAPTCHA 키%s를 위해 가입하세요." -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "Public 키" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "Private 키" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "테마 ì„ íƒ" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "Red" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." +msgstr "" # @ wp-members #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "White" - -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "Black Glass" - -# @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "Clean" +msgid "reCAPTCHA Keys" +msgstr "reCAPTCHA 키" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 msgid "Characters for image" msgstr "ì´ë¯¸ì§€ì— 대한 글ìž" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 msgid "Number of characters" msgstr "ê¸€ìž ìˆ˜" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "ì´ë¯¸ì§€ í¬ê¸°" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "ê¸€ìž í°íЏ 색ìƒ" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "ì´ë¯¸ì§€ ë°°ê²½ 색ìƒ" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "í°íЏ 사ì´ì¦ˆ" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "글ìžê°„ í­" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 msgid "Image type" msgstr "ì´ë¯¸ì§€ 타입" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." @@ -874,12 +934,12 @@ msgstr "" "ê³  활성화 해야 합니다." # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 msgid "Update CAPTCHA Settings" msgstr "CAPTCHA 설정 ì—…ë°ì´íЏ" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 msgid "CAPTCHA was updated for WP-Members" msgstr "CAPTCHAê°€ WP-Members를 위해 ì—…ë°ì´íЏ ë습니다" @@ -955,8 +1015,8 @@ msgstr "ì‚¬ìš©ìž ì •ì˜ ì´ë©”ì¼ ì£¼ì†Œ 설정" # @ wp-members #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "(ì„ íƒì )" @@ -965,23 +1025,27 @@ msgstr "(ì„ íƒì )" msgid "Set a custom email name" msgstr "ì‚¬ìš©ìž ì •ì˜ ì´ë©”ì¼ ì´ë¦„ 설정" +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "ì´ë©”ì¼ ì„œëª…" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "ì´ë©”ì¼ ì—…ë°ì´íЏ" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "WP-Members ì´ë©”ì¼ì´ ì—…ë°ì´íЏ ë습니다" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -998,42 +1062,41 @@ msgid "Field Manager Documentation" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "(필수)" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Edit Field" msgstr "필드 편집" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Add a Field" msgstr "필드 추가" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "필드 ë ˆì´ë¸”" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "사용ìžì—게 표시ë˜ëŠ” 필드 ì´ë¦„" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." @@ -1042,232 +1105,249 @@ msgstr "" "가능)" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "필드 타입" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "í…스트" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "textarea" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "checkbox" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "비밀번호" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "표시?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "필수?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 msgid "Checked by default?" msgstr "기본으로 ì²´í¬?" +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 msgid "Stored value if checked:" msgstr "ì²´í¬ëœ 경우 ì €ìž¥ëœ ê°’:" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "ì˜µì…˜ì€ Option Name|option_valueì´ì–´ì•¼ 합니다," # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "ë” ë§Žì€ ì •ë³´ëŠ” í”ŒëŸ¬ê·¸ì¸ ì‚¬ì´íŠ¸ë¥¼ 방문하세요" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 msgid "Add Field" msgstr "필드 추가" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 msgid "Registration Date" msgstr "회ì›ê°€ìž… ì¼ìž" -# @ default -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -msgid "Active" -msgstr "활성" - # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 msgid "Registration IP" msgstr "회ì›ê°€ìž… IP" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "필드 관리" # @ wp-members -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "WP-Members 필드가 ì—…ë°ì´íЏ ë습니다" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a
    the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2385,9 +2563,93 @@ msgid "Chad Butler" msgstr "" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" +msgid "https://butlerblog.com/" msgstr "" +#~ msgid "Unblock" +#~ msgstr "차단 í•´ì œ" + +#~ msgid "Block" +#~ msgstr "차단" + +# @ wp-members +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "reCAPTCHA 옵션 관리" + +# @ wp-members +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "" +#~ "reCAPTCHA는 무료ì´ë©° ì ‘ê·¼ 가능한 CAPTCHA 서비스로 블로그ì—서 ìŠ¤íŒ¸ì„ ë°©ì§€í•˜" +#~ "ëŠ”ë° ë„ì›€ì´ ë©ë‹ˆë‹¤." + +# @ wp-members +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA는 댓글ìžê°€ 사람ì¸ì§€ ì¦ëª…하기 위해 ì±…ì—서 스캔해 ë‘ ê°œì˜ë‹¨ì–´ë¥¼ ìž…" +#~ "력하ë„ë¡ ìš”êµ¬í•©ë‹ˆë‹¤. ì´ê²ƒì€ ìŠ¤íŒ¸ë¡œë´‡ì´ ì•„ë‹Œì§€ 확ì¸í•˜ë©° ë§Žì€ ìŠ¤íŒ¸ì„ ë°©ì§€í•©" +#~ "니다. ìƒì„¸í•œ ë‚´ìš©ì€ %s reCAPTCHA 웹사ì´íЏ%s를 방문하세요." + +# @ wp-members +#, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "reCAPTCHA는 API 키가 필요합니다. \"public\" ë° \"private\" 키로 구성ë©ë‹ˆ" +#~ "다. %s 무료 reCAPTCHA 키%s를 위해 가입하세요." + +# @ wp-members +#~ msgid "Public Key" +#~ msgstr "Public 키" + +# @ wp-members +#~ msgid "Private Key" +#~ msgstr "Private 키" + +# @ wp-members +#~ msgid "Choose Theme" +#~ msgstr "테마 ì„ íƒ" + +# @ wp-members +#~ msgid "Red" +#~ msgstr "Red" + +# @ wp-members +#~ msgid "White" +#~ msgstr "White" + +# @ wp-members +#~ msgid "Black Glass" +#~ msgstr "Black Glass" + +# @ wp-members +#~ msgid "Clean" +#~ msgstr "Clean" + +# @ default +#~ msgid "Active" +#~ msgstr "활성" + +# @ wp-members +#~ msgid "Enable CAPTCHA" +#~ msgstr "CAPTCHA 활성화" + +# @ wp-members +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "비밀번호가 ì¼ì¹˜í•˜ì§€ 않습니다.

    다시 해주세요." + +# @ wp-members +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "사용ìžëª… ë˜ëŠ” ì´ë©”ì¼ ì£¼ì†Œê°€ ë°ì´í„°ë² ì´ìŠ¤ì— ì¡´ìž¬í•˜ì§€ 않습니다." + # @ wp-members #~ msgid "Click to log out." #~ msgstr "로그아웃 하려면 í´ë¦­" diff --git a/i18n/languages/wp-members-nb_NO.mo b/i18n/languages/wp-members-nb_NO.mo deleted file mode 100644 index d541c86b75acaaaa94f6ced21077c56afc75f978..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 14954 zcmeI2d#oH+ea8m~2{91DD-Gdwe1nUf++9CNAY3PL{J4%Czb?Ml&Vv>+yE}L9cz0)( znb~`@Dd8QS4XXU?4SJHPk&t^f5I7n};XK2Cd{+7pA|Vc|OdaDC{hL2xm6pT|D} z_3BT-7lUWOCxMTE&jf$y-~ST4i03C=;=aGs;}zgD=zkIT9Pnk}bHP`D&jx$o)4?}` zPXtPeg9?g0N9 z6u%w^)75_oDEglVUJhOjitariQv`Q_ny&+D-2tfY?*v8HJ>b>gy`cE@MNsoS2-!%MlSJ>+!E3=yp!jhD6hAuP6ToFq^WEk9-waBA?*^qOr$MdzSD@DWF=+P< zY9ALo%k@7WoaK2Mlw31V>)#7%{?p(Kz|VlUfL{lP?*>KZ zJ3;O9-Jt0E7^v^Q0B#4r1-=-(jF&fpH-guJcY~Y2FMz|x1;HcWmEau^&nLm_*rfF6 z1EAKsAJjfS2}*8%0is&LSAG9O{`q^L`1w;%`_rbSCl`Zz!RLbNZ-BoEc0lp{{h;jq zBcSB$-t@%azISAt&xQ}8ktc@_9p zQ2O|N@OE&+^N|twdT<8(6HxU002DtjfS3*7M(_xD7@Pw?3cdpT3CPf3C&X+06W~|D zCis4ElX3h0vd6E22k8HMP<*{&J^X?Ho4|zU{*?1G4};>@_rUM){@?ubKfK7v<(r_s z|31j4!B0W)<1&bqd|m)bFYBQAd>yFyc6&SsN}k6+L>4qbSQXq2N)PS>QH|iUpuYbb zkKX|G-M2x_|056+3w{bd9=r(QiVy2R&3B2%t32)nFQC5xirzMOA((=qV;R)@_kx=D zl<)r}xP|8j!3)9v0JZ;LfTH(elwJFKAtJ@{qT<0`Q2Pi$$!`U`7_impdM(f{wD0Uw94 zsDBE?MFrP@()WF!#tr=Yw}6`WgW$#B{op$AG*|~e2TC6v24x>V14ZXEF-q<8N>FyU z71VnB!NcGyLFwnGK+*p-P~*P?YX3h0Zw5t_*4YPYo)u91e-CKs0@v|;KPY~D0u&!V z;sBwP=eh$0(HuwSMNKf<2+8|pGz6gqMKLn-M8(0jN6YK5Ev1{0ot{Bmc9ci@brhpz^C9lV2fGi{cp>+Q7t zw2#t$i*^}Jd|jZup0JNRDO@6z5t({+m0puI~ET$1e{*t^jm`Muw#iT{%IGibU{K^rTVz-QCCv=7px zw@;=?4?aZG)uipFNv5x&>H4_+>;CkCW&bR_md=e|nSa>eap+Mtcol6g?MB+~(GJkI z(JrD%$EAO7q}@l8Ej)#GIZfBQ9atMW>F@6c>$F3(koG#7u2(v+f8WgC*U~z)?Y1Wf z7D3rWd983G9X&#eedou(U9>0AuAqIGb_?wzwBMm^q?H#YQeB6+!!)bw>D3*+hkMK| zXwmMZy_2R(b~K<}t%tGe829(m*3<5$y_I$;?HbziXg%6ZG+j@ly@vK2J#f`%)AlY1 zjte*B&2E}U8*=XYS)3HyZA|+`oF-v+Q?S!?&1yVoEGt7+zdrQ zu(R7uS8}tMW+pU67KdHakFq#zO}uF~HC2(C=+1teMZvD9%|wGdPTG(WnLI8aaaWwS zv#`I!++DLjSxkdn-LTm)H+RE44|b)kVX%8COxlr|qhlq_T0E!l#w;vFy{LQ$%`rBW zgzAY4zUf9`!rz#w#0$~UOp_u`1}r++pFvn&MA=#0c~k_u(?L>X!(dN1G;>R75(RtM zZ`#gFG-1**vsnf+4zb~|9qCox?}o!2!E7ro%%P#(Sk`mgvwgRxgKV-lh9{Y2jKrgz z7^aMRNYsR0F0IrgX#qneeVD09vZx7D@_I0kt&)hrT*IG3A) zX&Zv*m9X@-k7fmXc*;WH9Mcr4|=^Y8}f0q%qQ4~3^L5!l#5XWlU8C@ zPm}IY*1ckK|B2|S2Z)L7>_ya3YyITY^^MGIz7fqb%#6;rP)+s@OXHTc`BJG$>6Ek0 z7hy5TgF|70_8Kel>gkAeI@Mzq?cO=JuzTN5Q@z0XAk1h|TzC_6)Y_F3bf69?+K%9G z%0Ilx&hX4$8z^~4wr*l!daNG9mYvLn9Hp9H3uRV z8Z>Z5_Vy??=y-$ADQ~Ji$1ilM*Y8GXmmlG~QIs--zZieS)mweUtUu=yxv4yuPqS<|Z8o@2hrW&Ps9wGu-TMT_re<&8v@4(Pfk^NW4Kv_ohX?$2&R(snoq_@higa-WM@$@KWLo9 zZwT{d7F)dz7LLpZ3sKg~71ZaWY&mX5XLXp34BHeez~9me^RzoqOvdTKmV{71Jitw8 z3^vg1Mhcz%FvCaV6EwTTvrM?g0NwiM`nLMQMsPoTMS-+h#I7;&2iP{l>|C-NINn@} zT6JT_7;OD#K4|n}Ph!O`Zlax789gi!8MAWQNnYSjt8CQpg_O>`@thB|2Pk#*z) zatH}c%u;kCY-~;xDW*+hfQOPbx_91n4iZ>T;$x?9j+5yZ6=RG~A)J47BRqqq?Rx|P zvu%Qfv|<-^Ssl-IR$Lt3TTbk;5I1fV{oy?4X>%pjLv$7O1J(`(Wf6G1o6D~P6 zD~#36o~R!sEio0bDJD*`a>PX!J6lq9vQ|j;lWV+Z&N+7O*ZyDUQQV7a4W!+2DY8os z7viED%>)bMY4x#wOA)rrJpH51?ef4sRgSuR&eBDagz|MMn&22(WCnIZdvATLI&F4P zI=SlAC<&cNK4B~dlnrfeqpS!e(t&{FPeG(#=IX~$S=`f1a6Bg8$8!#pz9{v#$A_MB zx|poLOpZsQ3`Vzxb4l#ZK4o??_Oj*jabvxc+gNM-V;c*w8##@0y!MH~`CfbDSo=My zW#>!mX$yU}S(bz(OXbL>W0&bf!+LP*V~ll)fgjosYl2&s^!N5C4{rB910U5!Pv9MX zeuL|msS*sw720}6`Wi#mE%8k4)j0xhj9C?Nlf$8AG0HWkZH74|mpA1z)B2QM^Rec} zy;#w+*+zONc|EzZW|1P{wutY_u|_s*Pf4Rqj2ysYuh$FhQuzS+iMbQ&?R1H`$SoI} zQr_cTAkL%Oj!Qb?yWA`~4B~&vfasMZR~O8)LbSSizVGen0KFyovByEXK^Kh5vq{~| z$4cVNzJ)^v?eScP38aXCqN3?$WmPG)^@N8Aq- zp@*gDv|VSeExYYjv=|P$gm8D7wJve$=-9Ez>@JT1Q>e6}?bMj)eLS$LH(7zGPZ=Yj zog?OzYoRxsFML4mBnS#YxX@b$+ww$SKYJIY+U}g&FE5vq=V?8AbX9JGm6DN#rtiF) zY9!-M(U=9KUMiXU3f}mG1Y7N@c2w$_UqlMy6GY6~ra1V5po%q>PMeY{n@AKf< ztfWTuDKbvnk?d?S;3FA5N?xJ}@_%gWPEG7E{r230vko#g9vZZxD@lq1MSmu-yKYRG@k0*RomaHm08KSAAL!ETm7Z$jz%hb)ehzDxK-OVXy>(sbjGZkJ5oCuX?vVY z_Q0AMvu(?^EwwGz*0yakTVFPF?KQP6*KFCcPGzOqLKY@@H!RYOFAq|?9B@poEkt2& z#`NM&7!L#48tT!@ z*%o;pkNFMTwkrkX_J)m#S$~7sx@kMJ-W(+=A&Fm(JhQF-lKR%sdh=13HJ9dCv9{&> zYX%$g?x52_&o<&d1q6g%6WvxCD4p&=N-Z?r!JL>shW3m&dW+P zjcm}d1#{P5?4V>t{jMlXGNe3C?wd!dnA@AOVBVwL1mA;#Vjc=Z21Zt#t)5xtD5Fw2 zHF;NBl>c!iARjTRl@D>5tEb)KB+RWS@wIZ)u!A4uyIz=|q#RFOq$um$PFtOm5u5CCGGEL>Urb$7 zJGUSC+Bs_0T9&iu=9sD7x3*?a_!Fo2a@c4TEVRY*U>0R?R3FEHP!X#hw&abx%ep!0 zXWB7=fqDl*A$7z6If<8gMfiybEf`QE$~!~mgpUZ!=CQFXg+#2TQIyb~9;>LX6$V8s z3!N04f-c2Y&xt`&(}T7;E~Sc!vO4acjH}WfYY*+#$MoN8j`9e2?lbKbsi%;G%5@jvBZ(HWKY;mwI(5LQoH3qvEtl;Fr% z@W37`cC^Rsb*$fOkz5(_A>qpmO4&Aj)OE9|cBKudOP(d-wR2wcxOp3z8c`eXf^i}K zHW@@PZ{ry@BI~d!%s29Mwa~>KKLQU~xKpNK{pGf{XRy-M}9b)VK~c)thIo4z<3xR00#O#~tlT7^$Ej{mukk{WT4%kdJ1 zHSy9W?X{8Kc;-F+4K-Mb0?-Dj*q$`r z%p#$q(npwwlQ4@X30xRgm@!`FfbuRgSn?_36RK?XkzOfqSx1Pv$nm>T1e%hS)7Doq zYMHc(vlu`9x-hD+2DLuYiu#zG(gij-a}Muhp12Nv)sU3S37ufAu8ehJ=_f_I*k)<8 zLh;*I^zD@AP*sJx%kWm)cck0-m9@xhA8l77BKT=bF`(KPEBxyFDt~=nv#W*k6}dTI z&Tu9h&xpzFROilop&S2I^|-Wdyr*=u)exU6R?icJc%LI>wM(D@V{T~dwsKtzE5`aK z)5|IY^xh?rN>79Yi7F?=p`@eedz^{^8T$+Y0Q_yrL-iLPAj5-ghJoP!8pouSn|r>kfWNeK~+TmlQK z>OVg4`?&E~U!`Swz>k71W6+0XI0#VeBDf_C_VAw`GX3hT@`hX*Kc$%s{7;;LRp|{x zzEPgY3+u%g=6Y?3d3TB*lCz_%+8^S^_&}%mp|wJem#;ni1JefhCd?2 ztum;sT?Zd#-EkG6i0R8dfq*Qw+ak+HIi1Votk0pTB(nP09#9!BkLYyvtfQdvezHSX zI(I`kMvKpBzRb4m;bHCB&$|SwKi&zF)!7V06j16gIW|2Wc|-uSR{OSTl2H_{j#pNN z?6=+3(|j%6s*-%otI>-?u}}g#M;u-|1eGWgID5XV8)c*sbgeNksB@(Qdx(;5DG5YW z&g+K?O*PNyac4J5dcveZg}Ey|`4v{MJM&q$0!rJ?uFS4F8TbiFVl?BUkZfz}I<(=c zR?qYvgHBd1XLb`iUv6ba{teqJceXy5BkN7Fz{Ywf)={j6M+Fs!kTZ`z;#w0bYw9-g z+f%ANIGn$x4rkXECsa~L+%}mgeThvT{85?$65FV96U-jlP|8DDXhOrR{W5fnqN$GqS)3YQWRV6WW(HM)wvv-ExYTCIj5~;)aT>MOl&>A^4@yY lNp$L`4vql=)Zwpmem_dropin_folder filter." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:57 -msgid "Email Messages" -msgstr "E-post melding" - -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:60 -msgid "You can customize the content of the emails sent by the plugin." -msgstr "Du kan tilpasse innholdet av e-poster sendt fra denne plugin" - -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:62 -msgid "A list of shortcodes is available here." -msgstr "liste med shortcodes kan ses her." - -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:69 -msgid "Set a custom email address" -msgstr "Skriv inn en gyldig epost-adresse" - -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 -msgid "(optional)" -msgstr "(obligatorisk)" - -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:73 -msgid "Set a custom email name" -msgstr "Skriv din e-post her" - -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -msgid "Email Signature" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 -msgid "Update Emails" -msgstr "Oppdater e-poster" - -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 -msgid "WP-Members emails were updated" -msgstr "WP-Members e-poster er oppdatert" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 -msgid "No fields selected for deletion" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:95 -msgid "Are you sure you want to delete the following fields?" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:122 -msgid "Fields deleted" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:136 -msgid "Field Manager Documentation" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 -msgid "(required)" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -msgid "Edit Field" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -msgid "Add a Field" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 -msgid "Field Label" -msgstr "Felt Etikett" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 -msgid "The name of the field as it will be displayed to the user." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 -#: includes/admin/tabs/class-wp-members-fields-table.php:58 -msgid "Meta Key" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 -msgid "" -"The database meta value for the field. It must be unique and contain no " -"spaces (underscores are ok)." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 -#: includes/admin/tabs/class-wp-members-fields-table.php:59 -msgid "Field Type" -msgstr "Felt Type" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 -msgid "text" -msgstr "Tekst" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 -msgid "email" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 -msgid "textarea" -msgstr "Tekstfelt" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 -msgid "checkbox" -msgstr "Avkryssningsboks" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 -msgid "multiple checkbox" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 -msgid "select (dropdown)" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 -msgid "multiple select" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 -msgid "radio group" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 -msgid "password" -msgstr "passord" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 -msgid "image" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 -msgid "file" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 -msgid "url" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 -msgid "number" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 -msgid "date" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 -msgid "hidden" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 -msgid "membership" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 -#: includes/admin/tabs/class-wp-members-fields-table.php:60 -msgid "Display?" -msgstr "Vis?" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 -msgid "This field is always displayed" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 -msgid "Required?" -msgstr "Obligatorisk?" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 -msgid "This field is always required" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 -msgid "Allow HTML?" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 -msgid "Placeholder" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 -msgid "Pattern" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 -msgid "Title" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 -msgid "Minimum Value" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 -msgid "Maximum Value" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 -msgid "Rows" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 -msgid "Columns" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 -msgid "Accepted file types:" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 -msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 -msgid "Checked by default?" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -msgid "Stored value if checked:" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 -msgid "Stored values delimiter:" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 -msgid "Values (Displayed|Stored):" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 -msgid "Options should be Option Name|option_value," -msgstr "Valg skal skrives Valg Navn|valg_værdi," - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 -msgid "Visit plugin site for more information" -msgstr "Besøk Plugin side for mer informasjon" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 -msgid "Value" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 -msgid "Add Field" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 -msgid "Return to Fields Table" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 -msgid "Drag and drop to reorder fields" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 -msgid "Registration Date" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -msgid "Active" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 -msgid "Registration IP" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 -msgid "Subscription Type" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 -msgid "Manage Fields" -msgstr "Administrer Felter" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 -msgid "WP-Members fields were updated" -msgstr "WP-Members felter er oppdatert" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 -msgid "Field Label is required. Nothing was updated." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 -msgid "Meta Key is required. Nothing was updated." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 -msgid "Meta Key must contain only letters, numbers, and underscores" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 -msgid "A field with that meta key already exists" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 -#, php-format -msgid "" -"Sorry, \"%s\" is a reserved term. " -"Field was not added." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:659 -msgid "Checked value is required for checkboxes. Nothing was updated." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:690 -msgid "A value is required for hidden fields. Nothing was updated." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:697 -#, php-format -msgid "%s was added" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:710 -#, php-format -msgid "%s was updated" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:753 -msgid "Form field order updated." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:56 -#, php-format -msgid "%sChange%s or %sFilter%s this address" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:57 -#, php-format -msgid "See the %sUsers Guide on plugin options%s." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:90 -msgid "Manage Options" -msgstr "Administrer valg" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:94 -msgid "Content" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:105 -msgid "Content Blocking" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:109 -msgid "Do not block" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:123 -msgid "Show Excerpts" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:124 -msgid "Show Login Form" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:125 -msgid "Show Registration Form" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:126 -msgid "Auto Excerpt:" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:148 -msgid "Number of words in excerpt:" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:149 -msgid "Custom read more link (optional):" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:163 -msgid "Time-based expiration" -msgstr "Time-based expiration" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:163 -msgid "Allows for access to expire" -msgstr "Allows for access to expire" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:164 -msgid "Trial period" -msgstr "Prøveperiode" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:164 -msgid "Allows for a trial period" -msgstr "tillater en prøveperiode" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:166 -msgid "Subscription Settings" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:176 -msgid "Other Settings" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:182 -msgid "Activation" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:182 -msgid "" -"Send initial activation link and password reset link instead of new " -"password. (Requires additional configuration)" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:183 -msgid "Enable Products" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:183 -msgid "Enables creation of different membership products" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:184 -msgid "Clone menus" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:184 -msgid "Enables logged in menus" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:185 -msgid "Notify admin" -msgstr "Gi beskjed til admin" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:185 -#, php-format -msgid "Notify %s for each new registration? %s" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:186 -msgid "Moderate registration" -msgstr "Redigere registrering" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:186 -msgid "Holds new registrations for admin approval" -msgstr "Nye registreringer krever godkjennelse fra admin" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:187 -msgid "Ignore warning messages" -msgstr "Ignorer advarsels-meldinger" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:187 -msgid "Ignores WP-Members warning messages in the admin panel" -msgstr "Ignorer WP-Members advarsel-meldinger i admin" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:198 -msgid "Attribution" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:200 -msgid "" -"Attribution is appreciated! Display \"powered by\" link on register form?" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:203 -msgid "Enable CAPTCHA" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:208 -msgid "reCAPTCHA v2" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:209 -msgid "reCAPTCHA v3" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:210 -msgid "Really Simple CAPTCHA" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:217 -msgid "Login Page:" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:220 -msgid "Specify a login page (optional)" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:229 -msgid "Register Page:" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:232 -msgid "For creating a register link in the login form" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:241 -msgid "User Profile Page:" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 -msgid "For creating a forgot password link in the login form" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:250 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:252 -msgid "Stylesheet" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:261 -msgid "Custom Stylesheet:" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:266 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:293 -msgid "Update Settings" -msgstr "Oppdater innstillinger" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:274 -msgid "Custom Post Types" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:280 -msgid "Add to WP-Members Settings" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:296 -msgid "" -"Please keep in mind that Custom Post Types are \"custom\" and therefore, not " -"all of them will function exactly the same way. WP-Members will certainly " -"work with any post type that operate like a post or a page; but you will " -"need to review any custom post type added to determine that it functions the " -"way you expect." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:315 -msgid "Close" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:333 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:334 -msgid "WP-Members Settings" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:335 -msgid "" -"The following is your WP-Members settings information if needed for support." -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:362 -msgid "Click to Copy" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:442 -msgid "Custom Post Type settings were updated" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:551 -msgid "WP-Members settings were updated" -msgstr "WP-Member innstillinger er oppdatert" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:623 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:654 -msgid "USE CUSTOM URL BELOW" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:643 -msgid "Select a page" -msgstr "" - -#: includes/admin/tabs/class-wp-members-dropins-table.php:70 -msgid "Name" -msgstr "" - -#: includes/admin/tabs/class-wp-members-dropins-table.php:71 -msgid "Enabled" -msgstr "" - -#: includes/admin/tabs/class-wp-members-dropins-table.php:72 -msgid "File" -msgstr "" - -#: includes/admin/tabs/class-wp-members-dropins-table.php:73 -msgid "Version" -msgstr "" - -#: includes/admin/tabs/class-wp-members-dropins-table.php:74 -#: includes/walkers/class-wp-members-walker-nav-menu.php:186 -msgid "Description" -msgstr "" - -#: includes/admin/tabs/class-wp-members-dropins-table.php:117 -#: includes/admin/tabs/class-wp-members-fields-table.php:108 -msgid "Save Settings" -msgstr "" - -#: includes/admin/tabs/class-wp-members-fields-table.php:43 -msgid "delete" -msgstr "" - -#: includes/admin/tabs/class-wp-members-fields-table.php:57 -msgid "Display Label" -msgstr "" - -#: includes/admin/tabs/class-wp-members-fields-table.php:61 -msgid "Required" -msgstr "" - -#: includes/admin/tabs/class-wp-members-fields-table.php:63 -msgid "Users Screen" -msgstr "" - -#: includes/admin/tabs/class-wp-members-fields-table.php:64 -msgid "Users Search" -msgstr "" - -#: includes/admin/tabs/class-wp-members-fields-table.php:66 -msgid "Sort" -msgstr "" - -#: includes/admin/tabs/class-wp-members-fields-table.php:107 -msgid "Delete Selected" -msgstr "" - -#: includes/api/api.php:328 includes/class-wp-members.php:1588 -msgid "log in" -msgstr "" - -#: includes/api/api.php:329 -msgid "log out" -msgstr "" - -#: includes/class-wp-members-activation-link.php:21 -msgid "Click to activate your account: " -msgstr "" - -#: includes/class-wp-members-activation-link.php:22 -msgid "Thank you for activating your account." -msgstr "" - -#: includes/class-wp-members-activation-link.php:23 -msgid "Activation key was expired or invalid" -msgstr "" - -#: includes/class-wp-members-captcha.php:217 includes/deprecated - Copy.php:500 -#: includes/deprecated.php:501 -msgid "You have entered an incorrect code value. Please try again." -msgstr "" - -#: includes/class-wp-members-forms.php:1048 -#: includes/class-wp-members-forms.php:1646 includes/class-wp-members.php:1538 -#, php-format -msgid "Please indicate that you agree to the %s Terms of Service %s" -msgstr "" - -#: includes/class-wp-members-forms.php:1049 -#: includes/class-wp-members-forms.php:1647 includes/class-wp-members.php:1489 -msgid "TOS" -msgstr "VfD" - -#: includes/class-wp-members-forms.php:1049 -#: includes/class-wp-members-forms.php:1647 templates/tos.php:20 -msgid "Terms of Service" -msgstr "Nettsidens vilkÃ¥r" - -#: includes/class-wp-members-forms.php:1868 -#: includes/class-wp-members-user-profile.php:473 -msgid "Activate this user?" -msgstr "Aktiver bruker?" - -#: includes/class-wp-members-menus.php:131 -msgid "Display" -msgstr "" - -#: includes/class-wp-members-menus.php:139 -msgid "Logged In Users" -msgstr "" - -#: includes/class-wp-members-menus.php:146 -msgid "Logged Out Users" -msgstr "" - -#: includes/class-wp-members-menus.php:153 -msgid "All Users" -msgstr "" - -#: includes/class-wp-members-menus.php:167 -#, php-format -msgid "%sAdd membership products%s to restrict menu to a membership" -msgstr "" - -#: includes/class-wp-members-menus.php:169 -msgid "Restrict menu item to a membership product" -msgstr "" - -#: includes/class-wp-members-products.php:302 -msgid "Product" -msgstr "" - -#: includes/class-wp-members-products.php:303 -msgid "Products" -msgstr "" - -#: includes/class-wp-members-products.php:309 -#, php-format -msgid "All %s" -msgstr "" - -#: includes/class-wp-members-products.php:310 -#, php-format -msgid "Add New %s" -msgstr "" - -#: includes/class-wp-members-products.php:311 -msgid "Add New" -msgstr "Opprett ny" - -#: includes/class-wp-members-products.php:312 -#, php-format -msgid "New %s" -msgstr "" - -#: includes/class-wp-members-products.php:313 -#, php-format -msgid "Edit %s" -msgstr "" - -#: includes/class-wp-members-products.php:314 -#, php-format -msgid "Update %s" -msgstr "" - -#: includes/class-wp-members-products.php:315 -#: includes/class-wp-members-products.php:316 -#, php-format -msgid "View %s" -msgstr "" - -#: includes/class-wp-members-products.php:317 -#, php-format -msgid "Search %s" -msgstr "" - -#: includes/class-wp-members-products.php:318 -msgid "Not found" -msgstr "" - -#: includes/class-wp-members-products.php:319 -msgid "Not found in Trash" -msgstr "" - -#: includes/class-wp-members-products.php:320 -msgid "Insert into item" -msgstr "" - -#: includes/class-wp-members-products.php:321 -#, php-format -msgid "Save %s Details" -msgstr "" - -#: includes/class-wp-members-products.php:324 -msgid "Membership Product" -msgstr "" - -#: includes/class-wp-members-products.php:325 -msgid "WP-Members Membership Products" -msgstr "" - -#: includes/class-wp-members-pwd-reset.php:31 -#: includes/class-wp-members-pwd-reset.php:32 -msgid "" -"Sorry, no password reset key was found. Please check your email and try " -"again." -msgstr "" - -#: includes/class-wp-members-pwd-reset.php:33 -msgid "Sorry, the password reset key is expired." -msgstr "" - -#: includes/class-wp-members-shortcodes.php:147 -msgid "" -"This is a generic message to display the form message dialog in the " -"Customizer." -msgstr "" - -#: includes/class-wp-members-shortcodes.php:158 -#: includes/class-wp-members.php:1566 includes/deprecated - Copy.php:695 -msgid "There was an error with the CAPTCHA form." -msgstr "Der oppstod en feil i CAPTCHA skjemaet." - -#: includes/class-wp-members-shortcodes.php:717 -msgid "Click here to log out." -msgstr "" - -#: includes/class-wp-members-shortcodes.php:786 -#: includes/class-wp-members-user.php:172 includes/class-wp-members.php:1540 -#: includes/class-wp-members.php:1590 -msgid "Register" -msgstr "Registrer" - -#: includes/class-wp-members-shortcodes.php:789 -#: includes/class-wp-members.php:1508 -msgid "Log In" -msgstr "" - -#: includes/class-wp-members-user-profile.php:38 -msgid "WP-Members Additional Fields" -msgstr "WP-Members Ekstra Felter" - -#: includes/class-wp-members-user-profile.php:38 -msgid "Additional Information" -msgstr "" - -#: includes/class-wp-members-user-profile.php:463 -msgid "Reactivate this user?" -msgstr "" - -#: includes/class-wp-members-user-profile.php:468 -msgid "Deactivate this user?" -msgstr "" - -#: includes/class-wp-members-user-profile.php:522 -msgid "IP @ registration" -msgstr "IP @ registrering" - -#: includes/class-wp-members-user.php:199 includes/class-wp-members.php:1565 -msgid "There was an error processing the form." -msgstr "" - -#: includes/class-wp-members-user.php:1118 -msgid "ERROR: User has not been activated." -msgstr "" - -#: includes/class-wp-members-widget.php:24 -msgid "Displays the WP-Members sidebar login." -msgstr "" - -#: includes/class-wp-members-widget.php:39 -#: includes/class-wp-members-widget.php:82 -msgid "Login Status" -msgstr "Loginstatus" - -#: includes/class-wp-members-widget.php:46 -msgid "Title:" -msgstr "Tittel:" - -#: includes/class-wp-members-widget.php:50 -msgid "Redirect to (optional):" -msgstr "" - -#: includes/class-wp-members.php:1028 includes/class-wp-members.php:1038 -msgid "You must be logged in to view this content." -msgstr "" - -#: includes/class-wp-members.php:1044 -msgid "The page you are looking for does not exist" -msgstr "" - -#: includes/class-wp-members.php:1436 -#, php-format -msgid "" -"You have a linked page in the WP-Members page settings that corresponds to a " -"post ID that no longer exists. Please %s review and update the %s page " -"settings %s." -msgstr "" - -#: includes/class-wp-members.php:1474 -msgid "First Name" -msgstr "Fornavn" - -#: includes/class-wp-members.php:1475 -msgid "Last Name" -msgstr "Etternavn" - -#: includes/class-wp-members.php:1476 -msgid "Address 1" -msgstr "Adresse1" - -#: includes/class-wp-members.php:1477 -msgid "Address 2" -msgstr "Adresse2" - -#: includes/class-wp-members.php:1478 -msgid "City" -msgstr "By" - -#: includes/class-wp-members.php:1479 -msgid "State" -msgstr "Region" - -#: includes/class-wp-members.php:1480 -msgid "Zip" -msgstr "Postnr" - -#: includes/class-wp-members.php:1481 -msgid "Country" -msgstr "Land" - -#: includes/class-wp-members.php:1482 -msgid "Day Phone" -msgstr "Telefon" - -#: includes/class-wp-members.php:1483 includes/class-wp-members.php:1524 -msgid "Email" -msgstr "E-post" - -#: includes/class-wp-members.php:1484 -msgid "Confirm Email" -msgstr "" - -#: includes/class-wp-members.php:1485 -msgid "Website" -msgstr "Nettside" - -#: includes/class-wp-members.php:1486 -msgid "Biographical Info" -msgstr "Biogravisk informasjon" - -#: includes/class-wp-members.php:1487 includes/class-wp-members.php:1507 -#: includes/class-wp-members.php:1587 -msgid "Password" -msgstr "Passord" - -#: includes/class-wp-members.php:1488 -msgid "Confirm Password" -msgstr "" - -#: includes/class-wp-members.php:1499 -msgid "You are not logged in." -msgstr "" - -#: includes/class-wp-members.php:1505 -msgid "Existing Users Log In" -msgstr "Innlogging for eksisterende brukere" - -#: includes/class-wp-members.php:1506 includes/class-wp-members.php:1586 -msgid "Username or Email" -msgstr "" - -#: includes/class-wp-members.php:1509 -msgid "Remember Me" -msgstr "" - -#: includes/class-wp-members.php:1510 -msgid "Forgot password?" -msgstr "Glemt passord?" - -#: includes/class-wp-members.php:1511 -msgid "Click here to reset" -msgstr "Klikk her for Ã¥ nullstille" - -#: includes/class-wp-members.php:1512 -msgid "New User?" -msgstr "Ny bruker" - -#: includes/class-wp-members.php:1513 -msgid "Click here to register" -msgstr "Klikk her for Ã¥ registrere" - -#: includes/class-wp-members.php:1516 includes/class-wp-members.php:1571 -msgid "Change Password" -msgstr "Endre passord" - -#: includes/class-wp-members.php:1517 -msgid "New password" -msgstr "" - -#: includes/class-wp-members.php:1518 -msgid "Confirm new password" -msgstr "" - -#: includes/class-wp-members.php:1519 -msgid "Update Password" -msgstr "Oppdater passord" - -#: includes/class-wp-members.php:1522 -msgid "Reset Forgotten Password" -msgstr "Nullstill glemt passord" - -#: includes/class-wp-members.php:1525 -msgid "Reset Password" -msgstr "Nullstill passord" - -#: includes/class-wp-members.php:1526 -msgid "Forgot username?" -msgstr "" - -#: includes/class-wp-members.php:1527 -msgid "Click here" -msgstr "" - -#: includes/class-wp-members.php:1530 includes/class-wp-members.php:1532 -msgid "Retrieve username" -msgstr "" - -#: includes/class-wp-members.php:1531 -msgid "Email Address" -msgstr "" - -#: includes/class-wp-members.php:1535 -msgid "New User Registration" -msgstr "" - -#: includes/class-wp-members.php:1536 -msgid "Choose a Username" -msgstr "Velg et brukernavn" - -#: includes/class-wp-members.php:1537 -msgid "Input the code:" -msgstr "" - -#: includes/class-wp-members.php:1539 -msgid "Reset Form" -msgstr "" - -#: includes/class-wp-members.php:1542 -msgid "Required field" -msgstr "PÃ¥krevede felt" - -#: includes/class-wp-members.php:1545 includes/deprecated - Copy.php:741 -msgid "Edit Your Information" -msgstr "Rediger dine Opplysninger" - -#: includes/class-wp-members.php:1547 -msgid "Update Profile" -msgstr "Oppdater profil" - -#: includes/class-wp-members.php:1548 -msgid "Update this file" -msgstr "" - -#: includes/class-wp-members.php:1551 -msgid "Login Failed!" -msgstr "Login feilet!" - -#: includes/class-wp-members.php:1552 -msgid "You entered an invalid username or password." -msgstr "Ditt brukernavn eller passord ble ikke godtatt." - -#: includes/class-wp-members.php:1553 -msgid "Click here to continue." -msgstr "Klikk her for Ã¥ fortsette." - -#: includes/class-wp-members.php:1554 -msgid "Password fields cannot be empty" -msgstr "Kodeordsfelt kan ikke være tomt" - -#: includes/class-wp-members.php:1555 -msgid "Sorry, that email address was not found." -msgstr "" - -#: includes/class-wp-members.php:1556 -#, php-format -msgid "An email was sent to %s with your username." -msgstr "" - -#: includes/class-wp-members.php:1557 -#, php-format -msgid "Sorry, %s is a required field." -msgstr "%s er pÃ¥krevet." - -#: includes/class-wp-members.php:1558 -msgid "You must enter a valid email address." -msgstr "Du mÃ¥ fylle inn en gyldig e-post. " - -#: includes/class-wp-members.php:1559 -msgid "The username cannot include non-alphanumeric characters." -msgstr "Brukernavn mÃ¥ kun innholde vanlige bokstaver." - -#: includes/class-wp-members.php:1560 -msgid "Sorry, username is a required field" -msgstr "Brukernavn er pÃ¥krevet" - -#: includes/class-wp-members.php:1561 -msgid "Passwords did not match." -msgstr "" - -#: includes/class-wp-members.php:1562 -msgid "Emails did not match." -msgstr "" - -#: includes/class-wp-members.php:1563 -msgid "You must complete the CAPTCHA form." -msgstr "Du mÃ¥ fylle inn CAPTCHA skjemaet." - -#: includes/class-wp-members.php:1564 -msgid "CAPTCHA was not valid." -msgstr "" - -#: includes/class-wp-members.php:1567 -#, php-format -msgid "" -"Sorry, you can only upload the following file types for the %s field: %s." -msgstr "" - -#: includes/class-wp-members.php:1570 -msgid "Edit My Information" -msgstr "Rediger min profil" - -#: includes/class-wp-members.php:1572 includes/class-wp-members.php:1575 -#: includes/class-wp-members.php:1577 includes/class-wp-members.php:1582 -#, php-format -msgid "You are logged in as %s" -msgstr "Du er logget pÃ¥ som %s" - -#: includes/class-wp-members.php:1573 -msgid "Log out" -msgstr "" - -#: includes/class-wp-members.php:1574 -msgid "Edit profile" -msgstr "" - -#: includes/class-wp-members.php:1574 -msgid "Begin using the site." -msgstr "Begynd Ã¥ bruke siden" - -#: includes/class-wp-members.php:1576 -msgid "Click to log out" -msgstr "" - -#: includes/class-wp-members.php:1578 -msgid "click to log out" -msgstr "" - -#: includes/class-wp-members.php:1579 -msgid "Log Out" -msgstr "" - -#: includes/class-wp-members.php:1583 -msgid "click here to log out" -msgstr "" - -#: includes/class-wp-members.php:1584 -msgid "Login Failed!
    You entered an invalid username or password." -msgstr "Login feilet!
    Ugylding brukernavn eller passord." - -#: includes/class-wp-members.php:1589 -msgid "Forgot?" -msgstr "Glemt?" - -#: includes/class-wp-members.php:1593 -msgid "" -"This content is restricted to site members. If you are an existing user, " -"please log in. New users may register below." -msgstr "" - -#: includes/class-wp-members.php:1594 -msgid "" -"Congratulations! Your registration was successful.

    You may now " -"log in using the password that was emailed to you." -msgstr "" - -#: includes/class-wp-members.php:1597 -msgid "Sorry, that username is taken, please try another." -msgstr "Dette brukernavnet er opptatt. Prøv et annet." - -#: includes/class-wp-members.php:1598 -msgid "" -"Sorry, that email address already has an account.
    Please try another." -msgstr "Denne e-post adressen finnes allerede i systemet.
    Prøv en annen." - -#: includes/class-wp-members.php:1599 -msgid "Your information was updated!" -msgstr "Din profil har blitt oppdatert!" - -#: includes/class-wp-members.php:1602 -msgid "Passwords did not match.

    Please try again." -msgstr "Passordene er ulike.

    Prøv igjen." - -#: includes/class-wp-members.php:1603 -msgid "Password successfully changed!" -msgstr "" - -#: includes/class-wp-members.php:1604 -msgid "Either the username or email address do not exist in our records." -msgstr "Brukernavn eller e-post finnes ikke i databasen." - -#: includes/class-wp-members.php:1605 -msgid "" -"Password successfully reset!

    An email containing a new password " -"has been sent to the email address on file for your account." -msgstr "" - -#: includes/class-wp-members.php:1607 -msgid "This content requires the following membership: " -msgstr "" - -#: includes/class-wp-members.php:1608 -msgid "This content requires one of the following memberships: " -msgstr "" - -#: includes/class-wp-members.php:1721 -msgid "Show forms as logged out" -msgstr "" - -#: includes/class-wp-members.php:1730 -msgid "Show form message dialog" -msgstr "" - -#: includes/class-wp-members.php:1838 -msgid "(more…)" -msgstr "" - -#: includes/cli/class-wp-members-cli.php:17 -#, php-format -msgid "User: %s" -msgstr "" - -#: includes/deprecated - Copy.php:472 includes/deprecated.php:473 -msgid "We were unable to validate the public key." -msgstr "Det var ikke mulig Ã¥ validere den offentlige nøkkelen." - -#: includes/deprecated - Copy.php:476 includes/deprecated.php:477 -msgid "We were unable to validate the private key." -msgstr "Det var ikke mulig Ã¥ validere den private nøkkelen." - -#: includes/deprecated - Copy.php:480 includes/deprecated.php:481 -msgid "The challenge parameter of the verify script was incorrect." -msgstr "The challenge parameter of the verify script was incorrect." - -#: includes/deprecated - Copy.php:484 includes/deprecated.php:485 -msgid "The CAPTCHA solution was incorrect." -msgstr "CAPTCHA løsningen er ikke fullstendig." - -#: includes/deprecated - Copy.php:488 includes/deprecated.php:489 -msgid "The parameters to verify were incorrect" -msgstr "Parameterene var ugyldige" - -#: includes/deprecated - Copy.php:492 includes/deprecated.php:493 -msgid "" -"reCAPTCHA API keys are tied to a specific domain name for security reasons." -msgstr "" -"PÃ¥ grunn av sikkerhet er reCAPTCHA API nøkkelen er knyttet til et domene-" -"navn." - -#: includes/deprecated - Copy.php:496 includes/deprecated.php:497 -msgid "The reCAPTCHA server was not reached. Please try to resubmit." -msgstr "reCAPTCHA serveren kunne ikke kontaktes. Prøv igjen." - -#. translators: %s: title of menu item which is invalid -#: includes/walkers/class-wp-members-walker-nav-menu.php:92 -#, php-format -msgid "%s (Invalid)" -msgstr "" - -#. translators: %s: title of menu item in draft status -#: includes/walkers/class-wp-members-walker-nav-menu.php:96 -#, php-format -msgid "%s (Pending)" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:123 -msgid "Move up" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:136 -msgid "Move down" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:138 -msgid "Edit Menu Item" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:149 -msgid "URL" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:156 -msgid "Navigation Label" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:162 -msgid "Title Attribute" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:169 -msgid "Open link in a new window/tab" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:174 -msgid "CSS Classes (optional)" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:180 -msgid "Link Relationship (XFN)" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:188 -msgid "" -"The description will be displayed in the menu if the current theme supports " -"it." -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:210 -#, php-format -msgid "Original: %s" -msgstr "" - -#: includes/walkers/class-wp-members-walker-nav-menu.php:223 -msgid "Remove" -msgstr "" - -#: templates/tos.php:32 -#, php-format -msgid "%sclose%s" -msgstr "%slukk%s" - -#: templates/tos.php:34 -#, php-format -msgid "%sprint%s" -msgstr "%sskriv ut%s" - -#. Plugin Name of the plugin/theme -msgid "WP-Members" -msgstr "WP-Members" - -#. Plugin URI of the plugin/theme -msgid "https://rocketgeek.com" -msgstr "" - -#. Description of the plugin/theme -msgid "" -"WP access restriction and user registration. For more information on plugin " -"features, refer to the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." -msgstr "" - -#. Author of the plugin/theme -msgid "Chad Butler" -msgstr "" - -#. Author URI of the plugin/theme -msgid "http://butlerblog.com/" -msgstr "" - -#~ msgid "reCAPTCHA" -#~ msgstr "reCAPTCHA" - -#~ msgid "You have set WP-Members to turn off the registration process" -#~ msgstr "Du har satt WP-Members til Ã¥ slÃ¥ av brukerregistrering" - -#~ msgid "" -#~ "but you also set to moderate and/or email admin new registrations. You " -#~ "will need to set up a registration page for users to register." -#~ msgstr "" -#~ "men du er ogsÃ¥ satt til Ã¥ moderere og / eller e-post admin for nye " -#~ "registreringer. Du mÃ¥ opprette en registreringsside for brukere." - -#~ msgid "Field Label is required for adding a new field. Nothing was updated." -#~ msgstr "" -#~ "Felt-etikett er nødvendig for Ã¥ legge til et nytt felt. Ingenting ble " -#~ "oppdatert." - -#~ msgid "Option Name is required for adding a new field. Nothing was updated." -#~ msgstr "" -#~ "Valget Navn er nødvendigt for at for Ã¥ legge til et nytt felt. Ingenting " -#~ "ble oppdatert." - -#~ msgid "Option Name" -#~ msgstr "Valgt Navn" - -#~ msgid "For dropdown, array of values:" -#~ msgstr "Til Dropdown, liste med valg:" - -#~ msgid "" -#~ "Determine which fields will display and which are required. This " -#~ "includes all fields, both native WP fields and WP-Members custom fields." -#~ msgstr "" -#~ "Velg hvilke felter som skal vises og hvilke som er obligatoriske. Dette " -#~ "inkluderer bÃ¥de vanlige WP felter og WP-Member felter" - -#~ msgid "Add/Delete" -#~ msgstr "Legg til/Slett" - -#~ msgid "Checked?" -#~ msgstr "Markering?" - -#~ msgid "Delete" -#~ msgstr "Slett" - -#~ msgid "(Email cannot be removed)" -#~ msgstr "(E-post kan ikke slettes)" - -#~ msgid "Update Fields" -#~ msgstr "Oppdater Felter" - -#~ msgid "Please indicate that you agree to the %s TOS %s" -#~ msgstr "Kryss av for at du godtar %snettsidens vilkÃ¥r %s" - -#~ msgid "Block Posts by default" -#~ msgstr "Bloker Innlegg som standard" - -#~ msgid "" -#~ "Note: Posts can still be individually blocked or unblocked at the article " -#~ "level" -#~ msgstr "" -#~ "NB: Innlegg kan fortsatt blokeres eller Ã¥pnes individuelt under redigering" - -#~ msgid "Block Pages by default" -#~ msgstr "Bloker Sider som standard" - -#~ msgid "" -#~ "Note: Pages can still be individually blocked or unblocked at the article " -#~ "level" -#~ msgstr "" -#~ "NB: Sider kan forsatt blokeres eller Ã¥pnes individuelt under redigering" - -#~ msgid "Show excerpts" -#~ msgstr "Vis Utdrag" - -#~ msgid "" -#~ "Shows excerpted content above the login/registration on both Posts and " -#~ "Pages" -#~ msgstr "Vis utdrag før pÃ¥logging / registrering pÃ¥ innlegg og sider" - -#~ msgid "Sends email to admin for each new registration?" -#~ msgstr "Send e-post til admin for hver ny registrering?" - -#~ msgid "Use reCAPTCHA" -#~ msgstr "Bruk reCAPTCHA" - -#~ msgid "Turns on CAPTCHA for registration" -#~ msgstr "SlÃ¥r pÃ¥ CAPTCHA under registrering" - -#~ msgid "Turn off registration" -#~ msgstr "Avbryt registrering" - -#~ msgid "Turns off the registration process, only allows login" -#~ msgstr "Avbryt registrering, tilat kun login" - -#~ msgid "Legacy forms" -#~ msgstr "Legacy forms" - -#~ msgid "" -#~ "Uses the pre-2.5.1 table-based forms (leave off to use CSS table-less " -#~ "forms)" -#~ msgstr "" -#~ "Uses the pre-2.5.1 table-based forms (leave off to use CSS table-less " -#~ "forms)" - -#~ msgid "Members Area URL:" -#~ msgstr "Members Area URL:" - -#~ msgid "Optional" -#~ msgstr "Valgfrit" - -#~ msgid "Register Page URL:" -#~ msgstr "Register Page URL:" - -#~ msgid "Custom CSS:" -#~ msgstr "Custom CSS:" - -#~ msgid "(Note: Email is always mandatory. and cannot be changed.)" -#~ msgstr "(Merk: E-post er alltid obligatorisk - og kan ikke endres.)" - -#~ msgid "WP Native?" -#~ msgstr "WP Felt?" - -#~ msgid "Add" -#~ msgstr "Legg til" - -#~ msgid "dropdown" -#~ msgstr "Nedtrekksliste" - -#~ msgid "For checkbox, stored value if checked:" -#~ msgstr "Hvilken verdi lagres, nÃ¥r markerings-boksen avkrysses:" - -#~ msgid "reCAPTCHA was updated for WP-Members" -#~ msgstr "reCAPTCHA er oppdatert for WP-Members" - -#~ msgid "WP-Members expiration periods were updated" -#~ msgstr "WP-Members prøveperiode er oppdatert" - -#~ msgid "" -#~ "Settings were saved, but you have required fields that are not set to " -#~ "display!" -#~ msgstr "" -#~ "innstillingene er lagret, men der er obligatoriske felter, som ikke er " -#~ "satt til Ã¥ bli vist!" - -#~ msgid "" -#~ "Note: This will not cause an error for the end user, as only displayed " -#~ "fields are validated. However, you should still check that your " -#~ "displayed and required fields match up. Mismatched fields are " -#~ "highlighted below." -#~ msgstr "" -#~ "NB: Dette vil ikke medføre en feil for slutbrukeren, da kun viste felter " -#~ "er valideret. Du bør sjekke, at dine viste, og pÃ¥krevde felter passer " -#~ "sammen. Feil felter er fremhevet nedenfor." - -#~ msgid "If you find this plugin useful, please consider making a donation" -#~ msgstr "If you find this plugin useful, please consider making a donation" - -#~ msgid "Subscriptions" -#~ msgstr "Abonnement" - -#~ msgid "PayPal Settings" -#~ msgstr "PayPal innstillinger" - -#~ msgid "Thank you for using WP-Members! You are using version %s" -#~ msgstr "Thank you for using WP-Members! You are using version %s" - -#~ msgid "If you find this plugin useful, please consider a %s donation %s" -#~ msgstr "If you find this plugin useful, please consider a %s donation %s" - -#~ msgid "" -#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" -#~ "\" key. You can segn up for a %s free reCAPTCHA key%s" -#~ msgstr "" -#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" -#~ "\" key. You can segn up for a %s free reCAPTCHA key%s" - -#~ msgid "Custom" -#~ msgstr "Custom" - -#~ msgid "Update reCAPTCHA Settings" -#~ msgstr "Oppdater reCAPTCHA innstillinger" - -#~ msgid "%d users were activated." -#~ msgstr "%d brukerre er aktivert." - -#~ msgid "" -#~ "Users ready to export, %s click here %s to generate and download a CSV." -#~ msgstr "" -#~ "Brukere er klar til eksport %s Klikk her %s for at generere og laste ned " -#~ "CSV." - -#~ msgid "WP-Members Users" -#~ msgstr "WP-Members brukere" - -#~ msgid "No users matched your criteria" -#~ msgstr "Ingen brugere matchede dine kriterier" - -#~ msgid "Bulk Actions" -#~ msgstr "Gruppe handling" - -#~ msgid "Apply" -#~ msgstr "Søke" - -#~ msgid "Email segnature" -#~ msgstr "E-post underskrift" - -#~ msgid "Additional Info" -#~ msgstr "Ekstra Opplysninger" - -#~ msgid "Indicates a required field" -#~ msgstr "Et obligatorisk felt" - -#~ msgid "Existing users Login" -#~ msgstr "Login for eksistrerende brukere" - -#~ msgid "Login" -#~ msgstr "Log pÃ¥" - -#~ msgid "New Password" -#~ msgstr "Nytt passord" - -#~ msgid "Repeat Password" -#~ msgstr "Gjenta passord" - -#~ msgid "Remember me" -#~ msgstr "Husk meg" - -#~ msgid "New Users Registration" -#~ msgstr "Ny bruker registrering" - -#~ msgid "Submit" -#~ msgstr "Send inn" - -#~ msgid "Clear Form" -#~ msgstr "Tøm skjema" - -#~ msgid "Click here to logout." -#~ msgstr "Klikk her for Ã¥ logge ut." - -#~ msgid "click here to logout" -#~ msgstr "Klikk her for Ã¥ logge ut" - -#~ msgid "Cheatin’ uh?" -#~ msgstr "Jukser du?" - -#~ msgid "there was an error and no users were exported" -#~ msgstr "der oppstod en feil og ingen brukere ble eksportert" - -#~ msgid "AIM" -#~ msgstr "AIM" - -#~ msgid "Yahoo IM" -#~ msgstr "Yahoo IM" - -#~ msgid "Jabber/Google Talk" -#~ msgstr "Jabber/Google Talk" - -#~ msgid "" -#~ "This content is restricted to site members. If you are an existing user, " -#~ "please login. New users may register below." -#~ msgstr "" -#~ "Dette er en lukket brukerside. Hvis du er registreret bruker mÃ¥ du logge " -#~ "pÃ¥ eller registrere deg." - -#~ msgid "" -#~ "Congratulations! Your registration was successful.

    You may now " -#~ "login using the password that was emailed to you." -#~ msgstr "" -#~ "Din registrering ble godkjent.

    Du kan nå logge på med det " -#~ "passordet som har blitt sendt til deg." - -#~ msgid "" -#~ "Password successfully changed!

    You will need to re-login with " -#~ "your new password." -#~ msgstr "" -#~ "Passordet er endret!

    Du må logge på med ditt nye passord." - -#~ msgid "" -#~ "Password successfully reset!

    An email containing a new " -#~ "password has been sent to the email address on file for your account. You " -#~ "may change this random password then re-login with your new password." -#~ msgstr "" -#~ "Passordet er nullstilt!

    En e-post med nytt passord har blitt " -#~ "sendt til deg. Du kan endre det til et personlig passord når du har " -#~ "logget deg på." - -#~ msgid "You are not currently logged in." -#~ msgstr "Du er ikke logget på." - -#~ msgid "login" -#~ msgstr "logg på" - -#~ msgid "" -#~ "Please indicate that you have read and agree to the %s Terms of Service %s" -#~ msgstr "Vennligs bekreft at du godtar %s nettsidens vilkår %s" - -#~ msgid "You may change your password here: %s" -#~ msgstr "Du kan endre passord her: %s" - -#~ msgid "Your registration info for %s" -#~ msgstr "Dine registreringsinformasjon for %s" - -#~ msgid "Thank you for registering for %s" -#~ msgstr "Takk for din registrering på %s" - -#~ msgid "Your registration information is below." -#~ msgstr "Dine Opplysninger er vist nedenfor." - -#~ msgid "You may wish to retain a copy for your records." -#~ msgstr "Ta vare på opplysningene." - -#~ msgid "username: %s" -#~ msgstr "Brukernavn: %s" - -#~ msgid "password: %s" -#~ msgstr "Passord: %s" - -#~ msgid "You may login here:" -#~ msgstr "Logg på her:" - -#~ msgid "" -#~ "Thank you for registering for %s. Your registration has been received and " -#~ "is pending approval." -#~ msgstr "" -#~ "Takk for din registrering på %s. Din registreing er mottatt og avventer " -#~ "godkjennelse." - -#~ msgid "You will receive login instructions upon approval of your account" -#~ msgstr "" -#~ "Du vil motta instruksjon om pålogging når din registrering er godkjent." - -#~ msgid "Your registration for %s has been approved." -#~ msgstr "Din registrering på %s er godkjent." - -#~ msgid "You may login at: %s" -#~ msgstr "Du kan nå logge på %s" - -#~ msgid "You originally registered at:" -#~ msgstr "Du er opprinnelig registreret på:" - -#~ msgid "Password reset for %s" -#~ msgstr "Passordet er nullstilt for %s" - -#~ msgid "Your password for %s has been reset" -#~ msgstr "Ditt passord for %s er nullstilt" - -#~ msgid "" -#~ "Your new password is included below. You may wish to retain a copy for " -#~ "your records." -#~ msgstr "Ditt nye passord står nedenfor. Ta vare på opplysningene." - -#~ msgid "This is an automated message from %s" -#~ msgstr "Dette er en automatisk beskjed fra %s" - -#~ msgid "Please do not reply to this address" -#~ msgstr "Ikke svar på denne e-posten" - -#~ msgid "New user registration for %s" -#~ msgstr "Ny bruker registrering for %s" - -#~ msgid "The following user registered for %s" -#~ msgstr "Følgende bruker er registreret på %s" - -#~ msgid "and is pending admin approval" -#~ msgstr "og må godkjennes av admin" diff --git a/i18n/languages/wp-members-pl_PL.mo b/i18n/languages/wp-members-pl_PL.mo index 77a05d14d53cb4fcd821309a3a7e633c1694d584..499964b9df92cb000f33b62afcbf0210d110ffbb 100644 GIT binary patch delta 2563 zcmYM!4NR3)9LMp)i=ezKsmKMogb4^&F7Iz91&N9Zp+RYhV4{+|7%+)ZUEh*6*2ear zV{N@mYw230-R71rZMe0Jtu;4S)*?51SvlCsURJ9{-{0j(XZ-n`bDn#jbI$*qb0?cV zsPlcZAoQ4_bP-9!NQg1&hzjQ)rFot)5!hmF$GNooFdh%s{t?tyUPb=Qo7S_qkoE

    6yCHt*Mk*u2IsEM9H zZNXbujhAeHCo86aA=_9zlKX46?iCBD&BwPDK;=0hizuDplb$ zlgO%-b8+fXathf3`bD&=3H7IM=*pTcz7 zb2%`@=tZ^nU=|Lik$+vMi*)G4KVb;|gBrjr}2tUU?7=7=|#P%bLG{g8L zzH3cfMiyy5kNV*WW^`pR+gh4V{=@00reh1%qW16(CwESu_W!@FRGWwg z2rft9)_}Q>$R{{=fuG+7RMFY0A|CBmHCtRhO2v>!oACPs#Dk755DQ+j) z2sfd#@-U&YV}`(QM7vuY&UXnroIY1?T%O09>+u%3a|_Gz z@;%-{=Wo{=Aq6Y)os&sNo#NzFr#0E-3@5+s97sv@pGsL5?1ZI0=l?bJV7PxEvnIs( HI=kmT@eK2M delta 4525 zcmaKud8`%H8Nd(kA;?y!QWiH3n^1uZB1-{9c$8h`$y&5(&z*bTy>pkD%go$&opHH< z)uvjLHa9j!n`+t^m&S#>G?n_g2``PUCf1f1P21Q6)27n6wP}nr?eCjAApFsu+;4v8 zoH=vOx1RToY&&^t>rWR9e@M~pMlM0d4p-_KcxogM+Vi88;-?O09E9gH{uR6szLw3O zfbz+Ea1{Jk#$jWW`W)jike`~KaRD5!R7`cL61RM{{tunJP*YKFF;Z3myn-&oriex&u}UH7`DX1 zg#9EbOoA55Mt4GS{R2=GdMKNJ7OrRfQz!~_bNXd)EZhR;!Nss2 z&V)}*!2c49SD6qCeg{Q?x1k((B3t+gT*Y`A{+t7EhO6N{@bmB`7!OnGB%BHR2)u;w z{)ruhzXj1rJ(lr#D2D%HBK{XmUtxl8)p581{sqc>4nK=$mP4tI9ykr&2F0=#)bM+7 z9{f3!9C#N>C?;Wr7YAA)kg0OV}-W5`zORVbb~0k^_;p@eYxR1C#atqpWMCLW}A5_k$O;6?M| zj*A{g3yJk%C>Fg4<$$A5T=*sw3*X83E)>cMP7$;&|6SE^iDP&#bU91B9xHMgFWyXD2ncfaxdHm z$4UJ^Oh*oW5{jkIWjq4qz@tzuq*tJ9@Y`(u4R`_Lx8V}_5tMSAOM;NEY93qxuZFTu zKm0XpK`~&9Mv)es?R0K{eNYtn5yWe15E5qfCL|x#2ibVU^iHfVgM?GffTGwcDBrJz z;^IwE6xDuFF9)7rq6@wcC1xMNx$wMMox0CK8JFSB zuni?=-h;b`q4aEW1m-XAxc0!D&OTp<;)zGH@l#N8>P0A?IX(yfi);SMgoL1*Q%1t= zP%OC#%6ki0qV~h(@X2iaHk`-!d~P8r-z88sHc&zl!ESg5lzm#zz=z?N;3=6{MrRlP zD#33+(eR&;d{X1ty$o|155YSb59c&KRR^HB@`o8;fRg<~Pz?D4+zU@Y3F+zuo$}rW z?_%7#E2mVQ&LfO7}WM;xA3S zBTc+X61G&64$7r}I2tgI^dn-$CIk1?T znk3%ob_<;?>45l)8`oxUu7+;bKaET2NDQT|Lgeze9wDjEX}iuDeL9fROpx8kN<_jT zjT~1SrT%Y|5iRT>jr*7BOXi-Bj6!Zjq-{ld5W=UXBhn-vq)9xbeFeD#ky)ILOV zYcwKl8L|SAu(uo@9wOPf8S#-KvJRoD(roR5LK}FdX0;z^TQhD|n?fP5 zVW@Q#7uZ zQ@w%PZz8L=+F12A@>SPKyW4GHVA{CjBf9pK2HwB$nXXBtD5|eqxG>*{sy4`1{bJ7X zYYW@oo#eF6sG&_*2{rRI>!Ew7BOe{3xXy`9Uw4!X9pibnp!)*9rj5?~enr;R1HYeT zB@>AkQ7^E(Ej4P!%jumZT+(j?x6ifgdd?!Rg-?wR>!y~c*DSd>%Tz-jMFQL#xn401 zjA=wZ9>G9SA=G}K_N#?dfiS0c_&W9*x@aR^m0-z!^R@8`>9?rPQeKAII8GzLW7QZx z7v0EhC0HY7u*-UsjPrgW)=k$7r|S(QLBU3ZHk_~f-Ox>~)3YVOS?qMv=9#y%L-pw# z<{CU?Eh;z;`nYGMfF{HGT_^Kasb#D6)YTnz65CNG^8}%CD&hh$Nc)~x8R#^CXPp<= zeGQi+#bCX*ceAe8cs~B~LXuEE##ctqsHgccBlU_5JE?Qk3|XGjdvPC*)uCJTbfd2O zu-%BMV#itbvUqm;-;??$ELyN=>4L?J^_9z4E?u%<(USH(lOONCDtBdj-jw^sCMNK# z4wK5zLBIXnl$pcBD6Y0&o-%9v^{(gEOcl*yC-LI;$tlnF++dQX(T$Fh3M12W zt>>CgO=zFGxYg?Q`O@l=35O2y?&!eKpywXD7xRxDI=AKmKXhv`0bo(yZ<=FY({%@#(l6yJ52hTXVhVyj| z+skQ6Hpp;2^hndC@RK;KNQ5X{lTbk{XH}+wtq{2;w@TU7PR#AmwB?-MYK8`-+Tx;k zaJt@+IEgJ1jDx)Ak`)zA%VE=+KQw4LI`K@^4*dl6y)-*n32L%g z0}nNd?&iZTLS1 F{}%#vdUXH* diff --git a/i18n/languages/wp-members-pl_PL.po b/i18n/languages/wp-members-pl_PL.po index ca49edf8..10ef5e17 100644 --- a/i18n/languages/wp-members-pl_PL.po +++ b/i18n/languages/wp-members-pl_PL.po @@ -4,134 +4,142 @@ msgid "" msgstr "" "Project-Id-Version: WP-Members 3.2.6\n" "Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2020-05-22 17:48-0400\n" -"PO-Revision-Date: 2020-05-22 17:54-0400\n" +"POT-Creation-Date: 2022-01-06 15:20-0500\n" +"PO-Revision-Date: 2022-01-06 15:23-0500\n" "Last-Translator: \n" "Language-Team: \n" "Language: pl_PL\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 #, fuzzy msgid "Subject" msgstr "Wyślij" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "Opcje" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "Pola" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "Komunikaty" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 #, fuzzy msgid "Emails" msgstr "Email" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 #, fuzzy msgid "New Registration" msgstr "Nowe hasło" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 #, fuzzy msgid "Registration is Moderated" msgstr "Zakończona rejestracja" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 #, fuzzy msgid "Registration is Moderated, User is Approved" msgstr "Twoje zgłoszenie w %s zostało zaakceptowane" -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 #, fuzzy msgid "Password Reset" msgstr "Resetowanie hasła" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 #, fuzzy msgid "Admin Notification" msgstr "Powiadomienia dla admina" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Tekst wyświetlany we wpisie lub stronie nad formularzem do logowania / " "rejestracji" -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "Zajęta nazwa użytkownika" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "Zajęty adres email" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "Zakończona rejestracja" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "Aktualizacja użytkownika" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "Niezgadzające się hasła" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "Zmiana hasła" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "Nie istniejące w bazie loginy lub emaile podane przy akcji resetowania hasła" -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "Resetowanie hasła" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "Ustawienia" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -#, fuzzy -msgid "Block" -msgstr "Domyślnie blokuj posty" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -140,12 +148,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -154,14 +162,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -187,268 +200,288 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "Aktywuj" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "Eksportuj" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 #, fuzzy msgid "Export All Users" msgstr "Eksportuj" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "Subskrypcja" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" -msgstr "Nie" - -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" -msgstr "Nazwa użytkownika" - -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "Aktywowany?" - -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "Wygasa" - -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "Rejestracja" - -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "IP" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" +msgstr "" -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" -msgstr "Tak" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" +msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "Wygasa" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "Tak" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 #, fuzzy msgid "Pages" msgstr "Domyślnie blokuj strony" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -456,57 +489,107 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "Nie" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "Nazwa użytkownika" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "Aktywowany?" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "Rejestracja" + +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "IP" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -683,148 +766,134 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "Ustawienia reCAPTCHA" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA to darmowe usługi CAPTCHA, które pomagają w digitalizacji książek " -"jednocześnie blokując spam na Twoim blogu." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" -msgstr "" -"reCAPTCHA wymaga przepisania dwóch słów zeskanowanych z książki aby " -"zabezpieczyć formularze przed botami rozsyłającymi spam. Więc masz mniej " -"spamu, a świat zyskuje coraz więcej książek w wersji cyfrowej. Każdy " -"wygrywa! Szczegółowe informacje możesz znaleźć na %s stronie reCAPTCHA%s" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "Klucze reCAPTCHA" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"reCAPTCHA wymaga kluczy API, publicznego oraz prywatnego. Możesz je uzyskać " -"za darmo na %s stronie reCAPTCHA%s" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "Klucz publiczny" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "Klucz prywatny" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "Wybierz styl" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "Czerwony" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "Biały" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "Czarne szkło" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "Minimalistyczny" +msgid "reCAPTCHA Keys" +msgstr "Klucze reCAPTCHA" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 -msgid "Characters for image" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 -msgid "Number of characters" +msgid "Characters for image" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +msgid "Number of characters" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 #, fuzzy msgid "Image type" msgstr "Typ pola" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 #, fuzzy msgid "Update CAPTCHA Settings" msgstr "Zapisz ustawienia reCAPTCHA" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 #, fuzzy msgid "CAPTCHA was updated for WP-Members" msgstr "Ustawienia reCAPTCHA zostały zapisane" @@ -893,8 +962,8 @@ msgstr "Podano nieprawidłową nazwę użytkownika lub hasło." #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "Opcjonalnie" @@ -902,23 +971,27 @@ msgstr "Opcjonalnie" msgid "Set a custom email name" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 #, fuzzy msgid "Email Signature" msgstr "Email" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 #, fuzzy msgid "Update Emails" msgstr "Aktualizacja użytkownika" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 #, fuzzy msgid "WP-Members emails were updated" msgstr "Ustawienia pól formularza WP-Members zostały zapisane" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -934,264 +1007,280 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "Wymagane?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Edit Field" msgstr "Edytuj swoje dane" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Add a Field" msgstr "Dodaj/Usuń" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "Opis pola" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Typ pola" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 #, fuzzy msgid "text" msgstr "" "Twoje ustawienia WP umożliwiają wyświetlanie pełnych treści wpisów poprzez " "RSS - nie jest to rekomendowane ustawienie." -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 #, fuzzy msgid "checkbox" msgstr "pole wyboru" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 #, fuzzy msgid "password" msgstr "Hasło" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Wyświetl?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "Wymagane?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 #, fuzzy msgid "Checked by default?" msgstr "Zaznaczone?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 #, fuzzy msgid "Stored value if checked:" msgstr "Zaznaczone?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 #, fuzzy msgid "Add Field" msgstr "Dodaj/Usuń" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 #, fuzzy msgid "Registration Date" msgstr "Zakończona rejestracja" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -#, fuzzy -msgid "Active" -msgstr "Aktywuj" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 msgid "Registration IP" msgstr "IP z rejestracji" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "Zarządzaj polami formularza" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "Ustawienia pól formularza WP-Members zostały zapisane" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2274,8 +2464,80 @@ msgid "Chad Butler" msgstr "Chad Butler" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" -msgstr "http://butlerblog.com/" +msgid "https://butlerblog.com/" +msgstr "" + +#, fuzzy +#~ msgid "Block" +#~ msgstr "Domyślnie blokuj posty" + +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "Ustawienia reCAPTCHA" + +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "" +#~ "reCAPTCHA to darmowe usługi CAPTCHA, które pomagają w digitalizacji " +#~ "książek jednocześnie blokując spam na Twoim blogu." + +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA wymaga przepisania dwóch słów zeskanowanych z książki aby " +#~ "zabezpieczyć formularze przed botami rozsyłającymi spam. Więc masz mniej " +#~ "spamu, a świat zyskuje coraz więcej książek w wersji cyfrowej. Każdy " +#~ "wygrywa! Szczegółowe informacje możesz znaleźć na %s stronie reCAPTCHA%s" + +#, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "reCAPTCHA wymaga kluczy API, publicznego oraz prywatnego. Możesz je " +#~ "uzyskać za darmo na %s stronie reCAPTCHA%s" + +#~ msgid "Public Key" +#~ msgstr "Klucz publiczny" + +#~ msgid "Private Key" +#~ msgstr "Klucz prywatny" + +#~ msgid "Choose Theme" +#~ msgstr "Wybierz styl" + +#~ msgid "Red" +#~ msgstr "Czerwony" + +#~ msgid "White" +#~ msgstr "Biały" + +#~ msgid "Black Glass" +#~ msgstr "Czarne szkło" + +#~ msgid "Clean" +#~ msgstr "Minimalistyczny" + +#, fuzzy +#~ msgid "Active" +#~ msgstr "Aktywuj" + +#~ msgid "Enable CAPTCHA" +#~ msgstr "Użyj CAPTCHA" + +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "Podane hasła różnią się.

    Prosimy spróbować ponownie." + +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "Nazwa użytkownika lub email nie występuje w naszej bazie danych." + +#~ msgid "http://butlerblog.com/" +#~ msgstr "http://butlerblog.com/" #, fuzzy #~ msgid "Click to log out." diff --git a/i18n/languages/wp-members-pt_PT.mo b/i18n/languages/wp-members-pt_PT.mo index 91beda8746c4f6eb9d57184096bab2448cf6707b..99bc7585bd2858e2418fab260b5fc350b8f02d15 100644 GIT binary patch delta 2326 zcmYk+e@xVM9LMqZ@yqVuK!N0kaFIudn0CQ+X>;1V4 zZU3%IOys5w7$r`W5UWznUdP=T94N={G7I3F$j?r5$ipG;`Uv_t|J3s6c1f`b}fiyB!g>cwrS7oPRbUqW^0FzSPYsOLwJ zzSw2dOpc+J;ySt=Ky^GwuL`jM6S@(hvKs49A3B81cnquY2Ml8t4{K^8$hRzpy55LO zu?OejAg;hK@qmv`u?}H8$SBm|vm}6);Nw}$zdkg|1)jBW)SCT>%$EIu>d++evy5D` zCM-l<-+>zOE>!aN;sQL5Rd@+Cqc`w=yopP&goL;cx8yPZ8>qa@g%%vcjTp)|E5*IY zhOlF(o}WN9d=}T@c~r+I@hBtA;vseDZRTGM522RseRM~RT7ps30KZO9xtGdStiVa{ zMmYro$QMs2H&s1ff$?S?l{OEZLe{#{guhjA``f$GrjsNL{4DhCpNj(Tw} zYQ&YO2b#R=9jJzPBKy^Pyz|}2psm-lAD46f4ywVcs2RG0YPgw9{1!JM>0}l3x?1}` zN=0klgBtORsI2Wrt@#=6`mpCH@=d#f8tF~Xe=y3qkLh^;W2o;ujheAO4m@I~QB!{r z{o4PZP*KBUs3n*{^2E}aU#(>!YO2E=bbTeR$5vFw&)^ey0asxr)2JnFLCxGgRFWUS zN_-9V+y_{r{r{JDp)y48Q&>~%BAK2qn`&U3uW1T@LXGG*ya&^mXLYC?mt!re!~2mm zvOe5}Cs8w{y{h|u)cg6EsG<_3vH*9W8aj++=%7Y6?A;HRo4vsKV$XB9pYt$#sSHn{ zcEd-=nCx>@!#7ax-9qJ7oN4yqI<5aUDvuD;MN6QfZ8BZ-XTt2d8NC_RsfP$nYaPLN z-5Gca=MzdiHN1>iN@y80u$2Uf@BTMvo2z}dFr#kP>O?)%^rR9>sQ(vI!<}+nQ*!Q9 zg_1Ibd#v>8%Bh83UF+RMG!hRJT1J(C+JBHxM(Q6bop_v3(NyNUHM6a#>{VGbg>6A4 zAgf?&h)smbdSW#(k9drzAzBEPS|UPhCmM)^wn`U~Ml=)CWyy5Kvm3Q<%Lpaclf1WJfccoZ!ObFZoA&PXFxgxs8KK4ibT0+qBIR^l}Z%~Mg2ds zW2ZMA`JLZ6v$HerIqx~^>$_gGid zekZwp0r@jOP5c$!N&gBi!oT5dSi?hPJep3!88{K7zMkFD}H#Z~=~> zUi@`bZfB5Zn-_6Dp2xeej7sz!)cqeMpMQ!S^lv8%J--j<@P4zOhHmtbKXa5*4L*Z> z$DB<1XYh0MUqB@=fh+M1RHE>p9!;Vcdi5_#8Ij?@=ZA zMDwo^T~9u!A^lDCSKc!j1S>T#lCM+>PDX zgWtwI_yI1#4NRwIdH}g(4isrj`%zl9pfRrK-ic!H51prESVhs?VY`WG@O z<_2meW>F`VW*%zfOK};l#Jh1ezLEGGDv|T32fmIP@nzJ0E~94XUDS5F zk$k?8j=r}9HL|<05jUd}eH@u}GlW_*U&ChY|5G&df*+%%=;x>#uO`?3iAv<(sNaX1 zNq-vIFze>l#0GqT{{5&Ihp3r6jY{A>d>cPRHiWs%DB89Ee?voy( z8&Hd8KkD=0#3QJYoIs8IrNkfL{q!$k8-9#>-jb!28C;KB>Gxs0|4-3StzSR}XD*-~ z_*+yB|A?yTd#D6HLe=sHvJp%ZS!zwJLzSijb^Rbdile9jzKM_F75pOJYngv74xfgm z_#|o@J&X6?S=5bh;To*xX7#(Vs+u)}gH_A`n_4gUM{{MWwG}ktTI5}(5tUFUK7e~s z373{L|150tT`pwsB5LGI8J=!ffqFnYuEbtkg-1~}eHm-;0$RL;8sVQ%_qDGuCc=Y> zZ)1V}c1CCMXZI8yu1ZgZIb(G}LY-Se)_UaMsARkhaHH_%+0#q^-K9h{uT$LO-jT@&Q8I z?_r{bm_dA=m^{8rV>Ib#QS1H2BQ$DXo#fbs`;xX+u_ZPVw-AHGeZ*G?ZLz(Cj{QWI z*h=X5QiZ9re)%>eJ(Y>07%!a0N+&*R#ZMkCjf2DvVtsN^d$*flsl@-!GpKE-h1pMN zfjvT~oDUISAas0{(C%Rgm|=nnvd9^~7Rqd*i&#yh2^M$!k0-zuf`uJ#!A+<`+jI-D zTOE#e;y~Q0oH{`}hIMFq2`y%A%{ro%(6NV@tIV~sb!;P+#V!7MlupzhyR9?pq=xOb ztdq}|X3cDF?9aG4*K}oqAn#ho?#;WQ@92sbjhn8l>-eRuGvC*s zbB>p_PC6aB`MgaB)(;}-jb)gf?_jL72|BPF$Zkzj}`2J3}tlx;lFLyS8_f zrq_M%P!E|rp?hrFOUDn$IZ-Opx_L0PZ4Xw?J>)@pQ8;d$A;lTDC6bhWVe`JH$8EwZhcMlKxX2j`pZ=dGEp?Lv8`>e5M|wPFdGcD zrh;5s>D)ZGIF+2`>yAAXx^9bgQYi-L4Q5@Nq;8poF)u|<87HzCH#?HIQNR#}yvTdX zwSz%0oVQP8JifvUQp27%_7Qw$%Dun5baW~)TYlLVa+L~|&ry`m zsx}llQNg27taX*Ne16Q$+R*~t!-cd%!Q%=#S??)^o%P1TAa7lNwBY!BiIQ=v=Tr*m K2fU(?)bYOoD+59R diff --git a/i18n/languages/wp-members-pt_PT.po b/i18n/languages/wp-members-pt_PT.po index 18964480..3861c513 100644 --- a/i18n/languages/wp-members-pt_PT.po +++ b/i18n/languages/wp-members-pt_PT.po @@ -2,7 +2,7 @@ msgid "" msgstr "" "Project-Id-Version: WP-Members 3.2.6\n" "Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2020-05-22 17:48-0400\n" +"POT-Creation-Date: 2022-01-06 15:20-0500\n" "PO-Revision-Date: \n" "Last-Translator: \n" "Language-Team: Brazilian-portuguese \n" @@ -11,124 +11,132 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Poedit-SourceCharset: UTF-8\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "Opções" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "Campos" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 #, fuzzy msgid "Dialogs" msgstr "Notificações de Atualização" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 #, fuzzy msgid "Emails" msgstr "eMail" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "Moderar Registo:" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "Aviso de processo de registo completo:" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 #, fuzzy msgid "Registration is Moderated, User is Approved" msgstr "Aviso de processo de registo completo:" -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "Aviso de confirmação de redefinição de password:" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 #, fuzzy msgid "Admin Notification" msgstr "Notificar Administrador:" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Aviso para posts ou páginas restritos, exibido acima do formulário de login:" -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "Username já registado" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "Email já registado" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "Registo completo" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "Aviso de confirmação de atualização de dados do usuário:" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "As passwords não coincidem" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "Aviso de confirmação de alteração de senha:" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "Aviso para nome de usuário ou email não encontrado durante tentativa de " "reiniciar uma senha esquecida:" -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "Redefinição de password" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "Configurações" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -#, fuzzy -msgid "Block" -msgstr "Bloquear Posts por Padrão:" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -137,12 +145,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -151,14 +159,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -184,269 +197,288 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "Activar" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 #, fuzzy msgid "Export All Users" msgstr "Log In" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "Subscrição" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" -msgstr "" - -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" -msgstr "Utilizador" - -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "Ativo?" - -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" msgstr "" -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "Registado" - -#: includes/admin/class-wp-members-export.php:78 -#, fuzzy -msgid "IP" -msgstr "Registo completo" - -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 #, fuzzy msgid "Pages" msgstr "Bloquear Páginas por Padrão:" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -454,57 +486,108 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "Utilizador" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "Ativo?" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "Registado" + +#: includes/admin/class-wp-members-user-export.php:293 +#, fuzzy +msgid "IP" +msgstr "Registo completo" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -685,149 +768,134 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "Gerenciar Opções do reCAPTCHA" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA é um serviço de CAPTCHA gratuito e acessível que ajuda a " -"digitalizar livros enquanto bloqueia spam no seu blog." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, fuzzy, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" -msgstr "" -"reCAPTCHA solicita aos comentaristas que redigitem duas palavras escaneadas " -"de um livro para provar que eles são humanos. Isto prova que eles não são um " -"\"spambot\" enquanto corrige os escaneamentos automáticos de velhos livros. " -"Desda forma, você obtém menos spam e o mundo recebe melhores digitalizações " -"de livros. Todo mundo ganha! Para detalhes, visite o" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "Chaves do reCAPTCHA" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, fuzzy, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"reCAPTCHA exige uma Chave API (\"API Key\"), que consiste em um par de " -"chaves \"pública\" e \"privada\". Você pode se registrar para uma" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "Chave Pública" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "Chave Privada" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "Selecione o Tema" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "Vermelho" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "Branco" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "Vidro Fumê" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "Limpo" +msgid "reCAPTCHA Keys" +msgstr "Chaves do reCAPTCHA" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 -msgid "Characters for image" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 -msgid "Number of characters" +msgid "Characters for image" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +msgid "Number of characters" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 #, fuzzy msgid "Image type" msgstr "Campo" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 #, fuzzy msgid "Update CAPTCHA Settings" msgstr "Atualizar Configuração do reCAPTCHA" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 #, fuzzy msgid "CAPTCHA was updated for WP-Members" msgstr "WP-Members" @@ -895,8 +963,8 @@ msgstr "Inseriu um username ou password inválidos." #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "" @@ -905,22 +973,26 @@ msgstr "" msgid "Set a custom email name" msgstr "Inseriu um username ou password inválidos." -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "Aviso de email já registado:" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 #, fuzzy msgid "Update Emails" msgstr "Aviso de confirmação de atualização de dados do usuário:" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 #, fuzzy msgid "WP-Members emails were updated" msgstr "WP-Members possui direitos autorais" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -936,266 +1008,282 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "Requerido?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Edit Field" msgstr "Edite suas Informações" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Add a Field" msgstr "Campo" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "Campo" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 #, fuzzy msgid "Field Type" msgstr "Campo" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 #, fuzzy msgid "text" msgstr "" "Suas configurações do WordPress permitem feeds RSS com texto completo. Esta " "não é uma configuração recomendada." -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 #, fuzzy msgid "checkbox" msgstr "Campos Adicionais do WP-Members" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "Password" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Exibir?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "Requerido?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 #, fuzzy msgid "Checked by default?" msgstr "Bloquear Posts por Padrão:" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 #, fuzzy msgid "Stored value if checked:" msgstr "Bloquear Posts por Padrão:" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 #, fuzzy msgid "Add Field" msgstr "Campo" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 #, fuzzy msgid "Registration Date" msgstr "Registo completo" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -#, fuzzy -msgid "Active" -msgstr "Activar" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 #, fuzzy msgid "Registration IP" msgstr "Registo completo" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "Gerenciar Campos" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 #, fuzzy msgid "WP-Members fields were updated" msgstr "Campos Adicionais do WP-Members" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2267,8 +2455,83 @@ msgid "Chad Butler" msgstr "Chad Butler" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" -msgstr "http://butlerblog.com/" +msgid "https://butlerblog.com/" +msgstr "" + +#, fuzzy +#~ msgid "Block" +#~ msgstr "Bloquear Posts por Padrão:" + +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "Gerenciar Opções do reCAPTCHA" + +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "" +#~ "reCAPTCHA é um serviço de CAPTCHA gratuito e acessível que ajuda a " +#~ "digitalizar livros enquanto bloqueia spam no seu blog." + +#, fuzzy, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA solicita aos comentaristas que redigitem duas palavras " +#~ "escaneadas de um livro para provar que eles são humanos. Isto prova que " +#~ "eles não são um \"spambot\" enquanto corrige os escaneamentos automáticos " +#~ "de velhos livros. Desda forma, você obtém menos spam e o mundo recebe " +#~ "melhores digitalizações de livros. Todo mundo ganha! Para detalhes, " +#~ "visite o" + +#, fuzzy, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "reCAPTCHA exige uma Chave API (\"API Key\"), que consiste em um par de " +#~ "chaves \"pública\" e \"privada\". Você pode se registrar para uma" + +#~ msgid "Public Key" +#~ msgstr "Chave Pública" + +#~ msgid "Private Key" +#~ msgstr "Chave Privada" + +#~ msgid "Choose Theme" +#~ msgstr "Selecione o Tema" + +#~ msgid "Red" +#~ msgstr "Vermelho" + +#~ msgid "White" +#~ msgstr "Branco" + +#~ msgid "Black Glass" +#~ msgstr "Vidro Fumê" + +#~ msgid "Clean" +#~ msgstr "Limpo" + +#, fuzzy +#~ msgid "Active" +#~ msgstr "Activar" + +#, fuzzy +#~ msgid "Enable CAPTCHA" +#~ msgstr "Ativa a solicitação de CAPTCHA durante o processo de registro." + +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "Passwords não coincidem.

    Por favor, tente novamente." + +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "Username ou password não registado." + +#~ msgid "http://butlerblog.com/" +#~ msgstr "http://butlerblog.com/" #, fuzzy #~ msgid "Click to log out." diff --git a/i18n/languages/wp-members-sk_SK.mo b/i18n/languages/wp-members-sk_SK.mo index 448cd8b4b576748c55aae35526425bfc89f70cd6..b1939cc26450484c55b648bb05f3ee8670c6c905 100644 GIT binary patch delta 3565 zcmYk;3rv+|9LMp8n;;?}Ac|=m6vPA+M9}bp_dDLeD_%O{F;Nud92LBsQW0-qa#A!h zoo4AQ)Sa4hwON_Ytyc4zPN!{V)25conbg|){?2)IzUy~B&--xR_kEuK^SsCIx%Vw` z---#|X*e24d-5dMm`nIWb3QoQwlqe~1j|ks&UuDqZ%pNUFoxkmj769A_e~hexd(Nh z2FpVjV~pDzqmjTLzQtGYCbq_B*a{;fjbTj2hAl7!qc98g_kq^m3$YF7Q!yTwpaxQd z8bAYT00&X`|IF9#Hs%bCc65A?n!#_V3;#fUF^H#yU;@%*5>W%_#)rPwADiJs)Pts3 z=XTV9=c6j-vijZD`9_`de6xc_H10;-;0Sib6Bvj$Q8T@bn&D&2#pYb384bWj9EBQ4 z6H+|iMfniP#Su6b)nAO7NGZBC!%7-lV`@=1+=qJb5!8jBq6T&f)9@Qqr5>Vg^b~b{ z2n(8s@u>b>)PRSgo--45ofB1&)iJC;lQA`PXwB+Td!Z5ap!293JwXjDhZHR7vy5=Y@x?14#f#&p7>IO?ypt)xRUT#K6VMhrp^YG(DQ0UkzO zcpCfQ9ZbbUrq>^bV{hDuuibvUWz5ney7&DHJ zK{y`ka01>z{xdlYR|6=-vp5CoumjW4jE|#AdJ0w2pRE3?IGXd@sLH0<{J$f4sO$1E zJHTzs2pU>~)k*#mZ$>S_PRoO+lAb`7^crdgcTm@bcJzNg4t3*>mT9QH(-SF*8H$>a z9VxnTV=JC-_R!ET+)>mTAGiDp^?>uJO?m}&gBz$)HlYpU8I6{z7i!@7NNG(0YL7Uv z3s$2h(1;qqDRi@p<`NB!{1Nh|nZHpb3s3g1c>?P1S*Qo)p-MdnHN%mp*K;~*pmR|J zUx0ex3em>xLu=j&wO3M6 z*H@tiv=wo4L`B^ucDUXo^}2dd1Fl&>!7`mguSt!n})u)+;RhIZR=1EJcg6;OQa|! zhF=v{$Mix~rWo~a!8|O)y{OmkG4{dHUHwZ{gQ1+)qVBs3HDLDv8rlOF(1s6CGi;g0 zdSfP1bu$P1;U*l8=THNQOlKnnP&J%}4>J5qGpxJ+fiqA`Fc-CCm8f6RT7SRW9HODp zoI>sHix`G~VmLOTDiECMzhN;B;k*R3riW1_{Q{Y^xquYQ{EMunNoE#|)r>~QW>%nP zeh8!4f95icU^?!iZ}VX(=Yed5x3LUo;UnyY1=*}WR$~tSg8GGv@9CfE1XN`lr~z$8 zecy|-F_Md>;9}JNGv{b%H$KEm_!#%&Sr%56n8#B!!*bM&x1u)ZZq&dEa~>W^k; z>AHAiMSRB`KDE!@C(&do(LQr)gu3|op;BuDy+<|?m8u2NgSnr1i|isRiS~gG2iZpI zb@I~jI&I%Tt-jW%AD-t2)peUOoaGahT*o*+FFrTZYD-i?{Z?!xb%e>jIHu5ALgL7F zl0vZ-)-&GfV;K#5%XifBxxs3;!9Api z3?R>sbgQu#^#-*fWh9mOp08cGLnj<8{flEPtpc)?OnlMH|47o-xck1;r)DhCK8n%_ z#|+ZU*YbZ%fYoFzSwr3+zWFE9Xh%j8{p=Q!ax$3c&}%e_@+uif zwvZ9zO;Sl3$a3N#qlk_kWG>5g(d1okPGm%Yrywdd%5IzF zbW|+1FLIc{rLHQ^uBbEKhUnRWp4ix5TTgV@OI)SP?JkGSHNVtpTgF%Oy))x%Vczxa z`-OOZPFm=3Ca;U`k&&5|k(q1D%E{}IospU22}wB`)U#W**PD_R(7nh}R&KuAW}j;t zw9HlJs4&wPITqV(^BvAIyO~@y$5Fxk=_)q`4yUW!+b1rsn^FLo?CsZqg;+k*D_PYr@g{qH~#~rL~p79 delta 5468 zcmZ{l36K=k9f#j?2qL$Lf&|{Kaxcs6fdoMg5k!_l5b)}qX?B~L>0Y{f7IvddK;w;w zt5JvvtP#T@n$*ThBoTwNo0w>+6-_0gg;g4psEL+ISuqup%J-XTg;XW4_BY?_?$_`A z&)z+ae<~DC4D9xxVH`liP`bM@@4_c~@x!>NuQ8{?ixbX;dbA|rHE=Z7DcBR<4bOxR zB+vK59$dFW?emj_op7Kr1@j7%Av|~oo(n&RXTfv&88ZOZz%$@%*bQEpTrY$Cnd|uJ z4RcWITcFn61M$V|glEHt;9&R^lz~5oJviSSXClkqfjaolr3c1z>2J(Xu6sdwHWKQ^ z8mM)b!8!06sDpMxY&Ux$TbQSy);|YNgRenF;&^iX4m^YN&HGFg(od5IazocWpk5pZ zd1Qt_Z7>dwgHvD^cpc==+{lkS4dDgwE-1&2!6)I1Q2VtI_dal|;(sZV9ZVF$SCR*B zL3#24JO};*%Hx5!BSXf(QcXY^Fc<3m1yBaAfaBphsL0(8wcmYE@9%*l;P=lY{(A5# zH)Q$Sa60@uRL&<1Do5gCC!Cs(LgjcHR88%IGNc{qoVTG2{|L&l z&jt~HJs805^Pz>x`FbdWwn81W3l4{m!bR{HoC14u+IjF&s2WH?MZklK$VMoGw?KKm z4f1DN`O$j^3rsFy@-iF^dvWS4I0aq=H^Q;-AZ)HM=5=@;ybAZQ!Gu_=oZbO-;0`E< z9)Zg7A*jealkk^Nk$nTovBG;ys0;HETmaRBdT==$1#6*-aTC<{VH;HL_CQ7Cxr8U6 z<@#SxAs^0S73m_Vh~%LnbTd>$Zh`nxFt;;V$BjKOfd7Qo!^~F*EBqB)1AB2=HB7@9 za3^G`c?l|%@57O>57sS(Q(-N<1ulcHL$)%bY}tT$uv7iNkjec#=v!I#ybUU}2cdHH zGpG>%HhF#mF6R1=P@$e$MdT{@9zdV#JF%t(eg^d+iq0?ZyBSVp-BzenJ&m=c{(qi{ za`ke;x1d7*0aWM*a3K$eLA^K|YW)(ZRIN*xhAOfgBnxH>l*hZFy5YxAss1&T;lGCk zS@<_5DvHk%cB2w?K!2zMhr{l0Jd{C`p*Efgm4daHEey$~PFlTZi04#&Vh zK<(3S4Dpv`L%B=+nQ8EHxD@t;4?(^?W-pY*?U14|&%>VZIP3x6g{Q#}p(5~Cs6OvX z>&WmvP>!4lb+Concl=oLuLrZZp?+Qr^+nqPW${+116$!NcnE5P58#jBr%>-79#^iJ zBT&WmD%AT`w1Nzp2KnZg`H(s_Ya!n_(_CPp4YosBv>SGXhoSoR2k>-w49dV4p*;FG z)B)Y9%c&a-sXtQ%b$>pT;j7_%7(ng+G?YOvz#3S1gNY98IidVwZ>Zc2Pp+$>K9#ee zifT2~hbe-6;1datK-Izv@C^7KTm?UY6ueo;X)59zR0Maz3)KIQFj>Kk*P!}*^u+QP zaVu0#pM}bC2h_$dL6(}|LDfu;N#)|Jf{MUgI2o>oD!zx|SK(2p+WH*Ika;Y6rh@!8 zFj+%iR!uGE@TO_y1Mi2*(Qc^k!IMzmgO23>n^2MY7^)k3PA?bbC@2pnLPcN(lmk2A zJh%(?h9}^;oNqp4LLHeN#Dl^$lOdgG)hjkhw^wkREXN34C{n?;bV9MTr`6^fCr%r z?Q%)EhQ`9zxSjy_!it&Yh&&2aJBQ$4_zPHyz)bS5YW|QLvhWkADy=19SCf(yyqoK1 z=)G1r|I)I@Z@`{hzYSSta!7`3NBfbYcrVhSsu>-ogZ0i_q@h%d)%X7Z6Xj8Z{Yw7} z(r`BVVko~ukqYQGREJ#Tqf^JWmpt&lPAHiqQk;i!m~p zJOY)LZ=%zad;6fOd}(qm+=w1U!_Z~uZ1i=c>em>AYEd5PW41v3|1BmDA{FBQ8mqW@ zPx9cQgbk45HQz(mA3 zi%n=vaB?{1e=q{u&9?eI0pqtyz>eIWTSJp{o?B!V}idskX9ov0ngPU_(XZIc2 z)ph*V)qRVzy|}>*Ek8CNxuNgmTpNVe%{gAyI_Y%iMv+Yi)(>LqZuX+sdcFJ=_H+6qkWpzXQy+h}8AKVbfjWZ@rtjot) zH>}GB^);y=H?j5Q5!u3*r&=er3Hv@^O%JVqBC7kqy?{Ae$~35Y^Zffo%@*w%(0xRw37Z)zTX|LXky+RA#$PIRxkCDxFLAu#)^8BdME+Ca@Hzt=+wQceu zujHK_8J$d(-Q?DB-yIp5lYzuthX}bYCZtl> zvxxJ-waz)>cdpz2~Z3t|X$vUkEt18EYPUk)w7Z2p}W>s^Y8&bGb zT40vAQ5EgDP6PO{yH_sDB*WWPPWz%}X`dmSS5AJr;1sEwxjAgIm-7 zm-9Nh3|i3`I!!^7&iFDB?T?SDs3vA{U{+rSLdv&|abF=O5PTv22Tk@_8Z!0W!=Q@pXs==|HM?EL)oZ6H! zCvRJvbg`}EY?{7{vH@oir6@x{n;gG*z_!?o?=>{jnQlHq*a%ED+p)NK#C9Cbr*ZKB zy-Du|aZ{LXA(Z6>et{5aRnn9>PXSYdciv$Gg_))H%YI}V!c{(3FUC$-e3o2g{NmvT z4sbH1Qwe6|DdFyh(#Cmu!$wUsEE!G*yym+yHuBva;3(u>TGl4lxLfY zhdcKRVNS+#l@G3TSF2zw^j!`E=MTBB^bDZyGRsvpi%zprR C{`!Rg diff --git a/i18n/languages/wp-members-sk_SK.po b/i18n/languages/wp-members-sk_SK.po index d75d6737..ae661576 100644 --- a/i18n/languages/wp-members-sk_SK.po +++ b/i18n/languages/wp-members-sk_SK.po @@ -3,128 +3,136 @@ msgid "" msgstr "" "Project-Id-Version: WP-Members 3.2.6\n" "Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2020-05-22 17:48-0400\n" -"PO-Revision-Date: 2020-05-22 17:54-0400\n" +"POT-Creation-Date: 2022-01-06 15:20-0500\n" +"PO-Revision-Date: 2022-01-06 15:23-0500\n" "Last-Translator: \n" "Language-Team: Web Geeks\n" "Language: sk\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "Predmet" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "Telo" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "Možnosti" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "Polia" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "Dialógové okná" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "E-mailov" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "Nový zápis" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "Registrácia je moderovaná" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "Registrácia je moderovaná, schválené používateľom" -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "Vynulovanie hesla" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "Admin oznámenia" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Vyhradené miesto (alebo stránky), zobrazí nad prihlasovacie/registraÄný " "formulár" -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "BraÅ¥ meno" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "E-mail je registrovaný" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "Registrácia dokonÄená" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "Používateľom aktualizácie" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "Passwords did not match" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "Zmeny hesla" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "Uživateľské meno alebo e-mail neexistujú pri pokuse o obnovenie zabudnutého " "hesla" -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "Vynulovanie hesla" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "Nastavenia" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -#, fuzzy -msgid "Block" -msgstr "Blok miest v predvolenom nastavení" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -133,12 +141,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -147,14 +155,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -180,268 +193,288 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "AktivovaÅ¥" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "Vývoz" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 #, fuzzy msgid "Export All Users" msgstr "Vývoz" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "Predplatné" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" -msgstr "nie" - -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" -msgstr "Username" - -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "Aktivovaný?" - -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "Uplynie" - -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "Registrované" - -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "IP" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" +msgstr "" -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" -msgstr "áno" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" +msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "Uplynie" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "áno" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 #, fuzzy msgid "Pages" msgstr "BlokovaÅ¥ stránky v predvolenom nastavení" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -449,57 +482,107 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "nie" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "Username" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "Aktivovaný?" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "Registrované" + +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "IP" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -688,149 +771,134 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "SpravovaÅ¥ reCAPTCHA možnosti" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"ReCaptcha je zadarmo, prístupný CAPTCHA služba, ktorá pomáha pri " -"digitalizácii kníh blokovanie nevyžiadanej poÅ¡ty na svojom blogu." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" -msgstr "" -"ReCaptcha žiada commenters znovu zadávaÅ¥ dve slová naskenované z knihy " -"preukázaÅ¥, že sú ľudské. To potvrdzuje, že nie sú spambotmi zároveň opravuje " -"automatické skenovanie starých kníh. Takže ste si menej spamu, a svet sa " -"dostane presne digitalizované knihy. VÅ¡etci víťazí! Podrobnosti nájdete %s " -"ReCaptcha stránky%s" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "reCAPTCHA klávesy" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"ReCaptcha vyžaduje API kľúÄ, skladajúci sa z \"verejnosÅ¥\" a \"súkromný\" " -"kľúÄ. Môžete sa zaregistrovaÅ¥ pre %s bez kľúÄa s ReCaptcha%s" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "Verejný kľúÄ" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "Súkromný kľúÄ" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "VybraÅ¥ tému" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "Red" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "Biela" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "ÄŒierneho skla" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "VyÄistite" +msgid "reCAPTCHA Keys" +msgstr "reCAPTCHA klávesy" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 -msgid "Characters for image" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 -msgid "Number of characters" +msgid "Characters for image" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +msgid "Number of characters" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 #, fuzzy msgid "Image type" msgstr "Typ poľa" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 #, fuzzy msgid "Update CAPTCHA Settings" msgstr "AktualizovaÅ¥ nastavenia" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 #, fuzzy msgid "CAPTCHA was updated for WP-Members" msgstr "reCAPTCHA bol aktualizovaný poslancov WP" @@ -897,8 +965,8 @@ msgstr "NastaviÅ¥ vlastnú e-mailovú adresu" #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "(voliteľné)" @@ -906,20 +974,24 @@ msgstr "(voliteľné)" msgid "Set a custom email name" msgstr "NastaviÅ¥ názov vlastného e-mailu" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "Podpis e-mailu" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "Aktualizácia e-mailov" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "WP-Älenovia e-maily boli aktualizované" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -935,259 +1007,275 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "Vyžadováno?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Edit Field" msgstr "UpraviÅ¥ vaÅ¡e informácie" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Add a Field" msgstr "PridaÅ¥ a odstrániÅ¥" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "OznaÄenie poľa" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Typ poľa" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "textu" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "Textarea" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "Checkbox" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "heslo" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "ZobraziÅ¥?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "Vyžadováno?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 #, fuzzy msgid "Checked by default?" msgstr "SkontrolovaÅ¥?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 #, fuzzy msgid "Stored value if checked:" msgstr "SkontrolovaÅ¥?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "Možnosti by mala byÅ¥ možnosÅ¥ Name|option_value" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "Môžete tiež navÅ¡tíviÅ¥ lokalitu plugin pre ÄalÅ¡ie informácie" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 #, fuzzy msgid "Add Field" msgstr "PridaÅ¥ a odstrániÅ¥" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 #, fuzzy msgid "Registration Date" msgstr "Registrácia dokonÄená" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -#, fuzzy -msgid "Active" -msgstr "AktivovaÅ¥" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 msgid "Registration IP" msgstr "IP @ registrácie" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "SpravovaÅ¥ polia" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "WP-Älenovia polia boli aktualizované" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2250,8 +2438,82 @@ msgid "Chad Butler" msgstr "ÄŒad Butler" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" -msgstr "http://butlerblog.com/" +msgid "https://butlerblog.com/" +msgstr "" + +#, fuzzy +#~ msgid "Block" +#~ msgstr "Blok miest v predvolenom nastavení" + +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "SpravovaÅ¥ reCAPTCHA možnosti" + +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "" +#~ "ReCaptcha je zadarmo, prístupný CAPTCHA služba, ktorá pomáha pri " +#~ "digitalizácii kníh blokovanie nevyžiadanej poÅ¡ty na svojom blogu." + +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "ReCaptcha žiada commenters znovu zadávaÅ¥ dve slová naskenované z knihy " +#~ "preukázaÅ¥, že sú ľudské. To potvrdzuje, že nie sú spambotmi zároveň " +#~ "opravuje automatické skenovanie starých kníh. Takže ste si menej spamu, a " +#~ "svet sa dostane presne digitalizované knihy. VÅ¡etci víťazí! Podrobnosti " +#~ "nájdete %s ReCaptcha stránky%s" + +#, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "ReCaptcha vyžaduje API kľúÄ, skladajúci sa z \"verejnosÅ¥\" a \"súkromný\" " +#~ "kľúÄ. Môžete sa zaregistrovaÅ¥ pre %s bez kľúÄa s ReCaptcha%s" + +#~ msgid "Public Key" +#~ msgstr "Verejný kľúÄ" + +#~ msgid "Private Key" +#~ msgstr "Súkromný kľúÄ" + +#~ msgid "Choose Theme" +#~ msgstr "VybraÅ¥ tému" + +#~ msgid "Red" +#~ msgstr "Red" + +#~ msgid "White" +#~ msgstr "Biela" + +#~ msgid "Black Glass" +#~ msgstr "ÄŒierneho skla" + +#~ msgid "Clean" +#~ msgstr "VyÄistite" + +#, fuzzy +#~ msgid "Active" +#~ msgstr "AktivovaÅ¥" + +#, fuzzy +#~ msgid "Enable CAPTCHA" +#~ msgstr "Zapne CAPTCHA, registrácie" + +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "Heslá urobil nie zápas. < br / > < br / > prosím skúste to znova." + +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "Uživateľské meno alebo e-mail adresa v naÅ¡ich záznamov neexistuje." + +#~ msgid "http://butlerblog.com/" +#~ msgstr "http://butlerblog.com/" #, fuzzy #~ msgid "Click to log out." diff --git a/i18n/languages/wp-members-sr_RS.mo b/i18n/languages/wp-members-sr_RS.mo index 20733b3d8389811c8ebdeb5d96a326bc80ff920b..0e39444ca10fd811eb917bab25cc52dd4c695a7f 100644 GIT binary patch delta 3489 zcmXxldr*}{7{~GDCdV5Ph~OqBC(h)R=R)r6nJfn{A9y^%v`1Y(@LN)z#LROxiJ+ieu1)i!lbPQNORlaBM=| zZ+k$m*-Iswjzic1Ph%&%im`YfAHbLhW0;#s#z^dm>d&$L<1vnQ0k+3d)C6i!1Fu63 zyajdN-Tr>BF`rQBNXH4(%&(v>yovhZKNyD5j7rtSqb88bhkiE@Ti`guiA`nYN9?pA-ok7Q<|3_VFusp@NV3cw9FDq( zT{5|-{t2iB6rvVZhF*SaYN+T&4X6P(qb}Trn$SM%g+BCW2z8^IsO#@xS9GzD>hFP? z=s?s!lTg@t#Na~((F zJ=;HwM<#{#X!NHR^%z&9wqye;BZsZ$F@g4Lic0E?$ zuQ&&bct&-|j^IrE8++q4M$f^OsEK^ahcb8(lks1igh^eDnaudcL#2R@lgOWmW4f9^ z7M{ex*ogn3GSSGgl+w+p_5mD+AEQ#*A|ddeh(&$h5pS^-iKsIb(LG>1wqbnJor-?g z4+r2N)J)4z7t|w*Gn-Ibau}8BW2o!Cwq8KaskwqA$=pHRr!C7@I|H@F6Hza+IT*qC zW*!x`!z{61tVJEZ22@7&Alq$Dp$^d%)JkvI@BczgBqk{^P-oP{2cqsf0=1Qe7>1Ro zLs*So|7oPc!8Q)+Mte|a;Q(sDk5Dr|in{R`)Qv7;2>xi>*H9C`h00VA%kPJ6F&KxU z4skB(Y)nZe{{yL1(4hg}#xHQc{o!(s_GsF*sEM9Me~PVlP%8{e4cxdZDl-F61LmS8 zo`)@PD(ZbO%eL!M$-gdGXMea0d(ifw2D*&AL(FZ|R)p}SCejVH!oH{#=b$E1fLiea z)WDn3h5Jz7A3}}y4eHQ-@1>%{k(L&?(MWXBF2oF+k9pXH58-80#yarKhGT(sCbp#Q zMs3Lg+h2itzbr#7U^QmpE+l!z`yCafL~n!Pkb!KUsl<1AY??4fZ?ZmtJ*(*(7K}t7#grnuWE@mxj-bxKanuA(;cUEw3vn>d`aC`VyQ$>T(TX&Z>uoxQLC z)Aa?e!Z2*YDBOlYs4|y`Al@MKNKGe{EoDO2Y5ukH3K~yxM^|m7xb*h_-7Bh|*Mm%LZCs>G7H ziBO&4kyP|tW)qRlAFW~qlv1f8Cfbgkm|*Lo2T?(wUe_xHQqUt`jhWckL|(Ere42?a9d|(f Qiup^bPSlk#n%ZvjKhe8ja{vGU delta 5302 zcmZXW4R9S*6~}M--KHgJQ~JrrP1>}jO&$sTfB+R;k=9y$}a(B7S-)Oh$_!oNYebt>VwGn87w zxCYLL8{s%ufHkli%KBb77TycxeMe%J)f054F!3y$315b@;YoNVJOwAinkuC#VLcoL zn<0N{8JCH0J(P9Zq1?A1zNk((9Twm;cpDVM9)e?4S*Za!V$m@u8=i=6DD@Vc#rPd4 z9{n52gJY}Xb+h4W#?4SR3Lv(sZpcz~8ZeK`>W%0Bt)+zH-4Rr z-%iHwL;loM)!Gt8tIL)e@|gWZDd6 z!);JJy%x$5=Ak6tjS26764CpiIQAGM4b(GmJuDwjZj7hq<}on^Mxlk#_W;V787L9i zm+%PGj9-Kj^0(naIFW}WBFmvfXeE@0tb-EaO>hr1&|`n~Lps+o(Rg;8l?UK1#;?K# zIFDUh;C9GTbr4D@zXj{z>u@Xl7`DN6Si21#hP*<(3&nsjn$m_7;9cLVzTs3N0eyc9|fv_aYU zIw*$bp*Z9x^ZQ^~%I09Q;Bh#H@wXxQsGfxq!dIY_&wI)J5ewoMjfZl71{4FAK`~$@ z6o+<0d4Cql+1~`$!oyH<g1CE7Nr1DSTbSMkoh8y6A zPz-HZ6d%Ecgu5a6r}9udJ^zzax$5i+7Lf58_L3k zkYK15C}*C5d>mB?Ho@DWtUCrL!dIXi$(v9%_RKV!R!SCk8HsWjGIh4@$&-3s=G_!a&8Tt?)_8FN7_ymPK;3S7ViI*bOJb zeXt51gw<024<-{&Cwvh~622ZS;MWg|#~;I;uzE@C@m@$eC=X76_d(h4DAe#ctcCAD z$&Jx?A@g$~X{Oe}`BMKL9kK8pD0TV}lw^4nPKA%bYv2pefwPv82k=(73ce2wY#`3q zs18Dj%yB4XJAxk;F=RHJ4_Cm?Kns?4(|Li;)o}Vnv4tU&5Zw)5f=A)4u)QVr{I9Tv z@jsv>*~E+EPi_sAc?(`rLC9gi`1>TnA-HfwT&~ApHRG375P#OG186hah>oB;&}Hah zbRC+3B-Ecp`;jE#9wbddj~&skWOSHo6u`%f*Nsmi&u;WF&+Cw_#)y z&fB0y5&;~FLN8toZ&xLQufcneLDP~sfgFdlFQ6_Y#~U>{|Dm>u&P=pzXab&#h@QF| zU4#12SJBN#+P!EmO3Q$DHj*#m@HUpgeaJ^rL6TF_$V*jT!$p#6Ix3*AqlrjLa3{JS zNoz;zk(`^H`9X9P4YiO?cQUAjQli6KDH%xSOZzx_+5!S(EGa7J3j}j{4C}Xb~D}6i(D0;d&)n77wFqja=D3YIkv^3RMTX5%nTz zJJ1a%C4*sY7yUzMF8U(+3YvnJqjS*ps1-?@jEZQs3}{X0{HRAXchl*cR5#Y*OYi8g^48G6=$(P(yGCa0kY^mrxP5JB z{CJfec38gVqKnB2?fKfu8{5$)oAs?A&{>$*(tG%MHeJjIeL26)f)$S2h z#xC>-Df6$aM_SSJa1>C7vxQt=}29Y_VxLf#@9CNz}C?3)~4OqZc4TJ zcFBa6-ePsDwqn|`Gt%w5V#>^l>_B!(^|%pNbqo|{9UWc%WH)VsT%a>vK5x09oB3j04scpyB)>6aZ`lQ4s^-# z?Y*|eTR*kPEfW!=gM!JY>2-D34o^CPhao<}32nDM3acrG9**OOm=I`hulAg5WI&M8 z+dbXw6?MB6YDYpX?`zP;%|_2+I!n13Xp_kleFEcj6V7%!w97qsBX01Pbr{*5CK+^> z?FO}aJx7?eLe4N~&?P&tBky#5aQcXJmz8GTst?rZK;o_;LY9RInGE*WX}n4fRg)hj zJCj7Kqii{aDAchzJyvW?5{b0qWpWY%aY%cvcX*+Leo4KK?!6TzxOBXzz=%lh34EEZ2owgk7 zM1RiYO=`fO+dpFbP-wRfoSHYLV%v!$cF8BHtoZ4iV+!We_2T7D^qWrV!z)<)_ZC-+ zi#bkbaj;iyHl@>pD=pJ^f8Fdct$xXJy#c-8k#VEeSdKSvyy;iN%O~{Bi67ZIYcSaL zN}l$@Trnd>n58y+Fmr&y-6HgMx2LPN&gH!34RXT`kRV_;yFUui^DO3{lT| zX}eRbq*mEO63u85R|h4kDZZ;iGuX@9qZ~Dk-Q$(Shl1yqi#dz(E7=UvR<^U)Sxo8O zctqJaypFT8Lh9rHi-z!js%Ti8wt|9VLf16#K_MI5PKU49CxufCoMO8~Hy;N}>bE>( zO=oe)FM=r*k|WM>*|`u!L}irtMunaJPQ=+pXjEwBf>0H_tWWw8 JiD+!pe*xr2npXe- diff --git a/i18n/languages/wp-members-sr_RS.po b/i18n/languages/wp-members-sr_RS.po index 2fe4a69a..4c01b02e 100644 --- a/i18n/languages/wp-members-sr_RS.po +++ b/i18n/languages/wp-members-sr_RS.po @@ -4,8 +4,8 @@ msgid "" msgstr "" "Project-Id-Version: WP-Members 3.2.6\n" "Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2020-05-22 17:48-0400\n" -"PO-Revision-Date: 2020-05-22 17:54-0400\n" +"POT-Creation-Date: 2022-01-06 15:20-0500\n" +"PO-Revision-Date: 2022-01-06 15:24-0500\n" "Last-Translator: \n" "Language-Team: Dmitrii Krasnov \n" "Language: sr_RS\n" @@ -13,121 +13,129 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Poedit-SourceCharset: UTF-8\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "Subject" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "Telo" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "Opcije" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "Polja" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "Dijalozi" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "Emailovi" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "Nova registracija" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "Registracija je obavljena" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "Registracija je obavljena, korisnik je odobren." -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "Resetuj Å¡ifru" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "Admin notifikacije" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" "Zabranjeni post (ili stranica), prikazuje iznad login/registracijsku formu" -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "KorisniÄko ime je zauzeto" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "Email je registrovan" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "Registracija zavrÅ¡ena" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "Korisnik update-ovan" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "Å ifra se ne slaže" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "Å ifra se menja" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "KorisniÄko ime ili email ne postoje kada pokuÅ¡ate da resetujete zaboravljenu " "Å¡ifru" -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "Resetovanje Å¡ifre" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "Postavke" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -#, fuzzy -msgid "Block" -msgstr "Блокировать запиÑи по умолчанию" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -136,12 +144,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -150,14 +158,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -183,268 +196,288 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "Aktiviraj" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "Export" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 #, fuzzy msgid "Export All Users" msgstr "Выгрузить" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "Pretplata" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" -msgstr "Ne" - -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" -msgstr "Korisn iÄko ime" - -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "Aktivirano?" - -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "IstiÄe" - -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "Registrovan" - -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "IP" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" +msgstr "" -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" -msgstr "Da" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" +msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "IstiÄe" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "Da" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 #, fuzzy msgid "Pages" msgstr "Блокировать Ñтраницы по умолчанию" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -452,56 +485,106 @@ msgid "" "for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "Ne" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "Korisn iÄko ime" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "Aktivirano?" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "Registrovan" + +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "IP" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -684,149 +767,134 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "Upravljajte reCAPTCHA Opcijama" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA je besplatna, primenjliva CAPTCHA usluga pomaže digitalizovanju " -"knjiga dok blokira spam na vaÅ¡em blogu." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit the " -"%s reCAPTCHA website%s" -msgstr "" -"reCAPTCHA traži da ponovo otkucate dve reÄi skenirane iz knjige da dokaže da " -"ste Äovek . Ovo potvrÄ‘uje da oni nisu spambot i istovremeno ispravlja " -"automatski skenire starih knjiga . Tako dobijate manje spama , a svet dobija " -"taÄno digitalizovane poruke. Svi pobedjuju. Za detalje posetite %s reCAPTCHA " -"websajt%s" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "reCAPTCHA KljuÄevi" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"reCAPTCHA zahteva API kljuÄ, ckoji se sastoji od \"public\" i \"private" -"\" kljuÄa. Možete da se upiÅ¡ete za %s besplatan reCAPTCHA kljuÄ %s" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "Javni kljuÄ" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "Privatni kljuÄ" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "Izaberi temu" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "Crveno" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for the " +"new CAPTCHA type." +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "Belo" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "Black staklo" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "ÄŒisto" +msgid "reCAPTCHA Keys" +msgstr "reCAPTCHA KljuÄevi" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" key. " "You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 -msgid "Characters for image" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key here " +"%s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 -msgid "Number of characters" +msgid "Characters for image" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +msgid "Number of characters" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 #, fuzzy msgid "Image type" msgstr "Tip polja" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 #, fuzzy msgid "Update CAPTCHA Settings" msgstr "Update postavki" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 #, fuzzy msgid "CAPTCHA was updated for WP-Members" msgstr "reCAPTCHA je updatovano za WP-Members" @@ -893,8 +961,8 @@ msgstr "Podesi custom email adresu" #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "(opcionalno)" @@ -902,20 +970,24 @@ msgstr "(opcionalno)" msgid "Set a custom email name" msgstr "Podesi custom email ie" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "Email potpis" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "Updateuj mailove" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "WP-Members emailovi su updatovani" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -931,260 +1003,276 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "Potrbno?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Edit Field" msgstr "Редактирование ваших данных" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 #, fuzzy msgid "Add a Field" msgstr "Добавить/удалить" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "Pronadji oznaku" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Tip polja" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "tekst" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "podruÄje teksta" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "checkbox" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "Å¡ifra" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Prikaži?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "Potrbno?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 #, fuzzy msgid "Checked by default?" msgstr "Отмечено?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 #, fuzzy msgid "Stored value if checked:" msgstr "Отмечено?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "Opcije bi treblo da budu Option Name|option_value," -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "Posetite sajt plugina za viÅ¡e informacija" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 #, fuzzy msgid "Add Field" msgstr "Добавить/удалить" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 #, fuzzy msgid "Registration Date" msgstr "РегиÑÑ‚Ñ€Ð°Ñ†Ð¸Ñ Ð·Ð°Ð²ÐµÑ€ÑˆÐµÐ½Ð°" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -#, fuzzy -msgid "Active" -msgstr "Aktiviraj" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 #, fuzzy msgid "Registration IP" msgstr "IP при региÑтрации" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "Upravljazi poljima" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "WP-Members polja su updatovana" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2247,9 +2435,80 @@ msgid "Chad Butler" msgstr "" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" +msgid "https://butlerblog.com/" msgstr "" +#, fuzzy +#~ msgid "Block" +#~ msgstr "Блокировать запиÑи по умолчанию" + +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "Upravljajte reCAPTCHA Opcijama" + +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "" +#~ "reCAPTCHA je besplatna, primenjliva CAPTCHA usluga pomaže digitalizovanju " +#~ "knjiga dok blokira spam na vaÅ¡em blogu." + +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to prove " +#~ "that they are a human. This verifies that they are not a spambot while " +#~ "also correcting the automatic scans of old books. So you get less spam, " +#~ "and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA traži da ponovo otkucate dve reÄi skenirane iz knjige da dokaže " +#~ "da ste Äovek . Ovo potvrÄ‘uje da oni nisu spambot i istovremeno ispravlja " +#~ "automatski skenire starih knjiga . Tako dobijate manje spama , a svet " +#~ "dobija taÄno digitalizovane poruke. Svi pobedjuju. Za detalje posetite %s " +#~ "reCAPTCHA websajt%s" + +#, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "reCAPTCHA zahteva API kljuÄ, ckoji se sastoji od \"public\" i \"private" +#~ "\" kljuÄa. Možete da se upiÅ¡ete za %s besplatan reCAPTCHA kljuÄ %s" + +#~ msgid "Public Key" +#~ msgstr "Javni kljuÄ" + +#~ msgid "Private Key" +#~ msgstr "Privatni kljuÄ" + +#~ msgid "Choose Theme" +#~ msgstr "Izaberi temu" + +#~ msgid "Red" +#~ msgstr "Crveno" + +#~ msgid "White" +#~ msgstr "Belo" + +#~ msgid "Black Glass" +#~ msgstr "Black staklo" + +#~ msgid "Clean" +#~ msgstr "ÄŒisto" + +#, fuzzy +#~ msgid "Active" +#~ msgstr "Aktiviraj" + +#, fuzzy +#~ msgid "Enable CAPTCHA" +#~ msgstr "UkljuÄi CAPTCHA za registraciju" + +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "Å ivra se ne poklapa.

    PokÅ¡ajte opet." + +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "Ili korisniÄko ime ili email adresa ne postoje u neÄim beleÅ¡kama." + #, fuzzy #~ msgid "Click to log out." #~ msgstr "Войти" diff --git a/i18n/languages/wp-members-tr_TR.mo b/i18n/languages/wp-members-tr_TR.mo index 2bb5951ee0509e182bff9c376eb826836da25888..1d872cb69db78e6acc3a38d20c69cd6d56ddfa8e 100644 GIT binary patch delta 3884 zcmX}u2~bs49LMqV5CH*Yku43yKtT|EY?_LIX=+fCM!4^2xLaAdBu~Z2Fb#QGDVmj< zCYtFRW;AQet!$Y#b8>PUvt>$K&1STw`u^@abjJVtoO9p3XZfFVpIobR-FVz{Av$oq zq3j`UC04dJ<_EkQ$_J&soiS~2owX75)pqL}m`D2%rsA&{iwP0NgkTo7$KI&tN>Tk) zV6ZVBGl@zV7pm+R3#`=`&Gl7y3pQd$Y{s_u8ET-57=_m{5Q8KA{e>f!Oaf{GX;_E_ zsQZ^-Amf`gRN}eNfN{7B^}rEihUPSCBIi*v{}naxP5XT$y>+0SfLd`bYNZ9Jeukj# zAB!Z{JcuO8JcbdBZ)&ON#^*2yccBK}XWIu+D|-i(sS~IHKC|DSv+c{a{WCH*a~;)B z5VKFmb{K$tkgrSudbILkRC?ib)CxD_>$n3op$cZFl#j|6UN>8IE zcm*|)KT-V#$M`1@g?c_FhWu+!yKq4>>W`Xn8D`)}R7z`513ZoDun{}sZhQSB)I!dp z`niUhNNYayd`HxTQc!22Cu*yUV#&V_R|OX|;C$3Tn@}@u!USx#*FVNPX`e^!c{06d z;6l_u71#+UVhL7b4!)1c_&4edB=L~??WX)|#YL!;48c}dj#}v`Yrf7yDu*y{77W)ME4Mz3NwgbKTjIlX zyokzFC^suZ(a54r9FD~-oQHKd0dJxX>u5$9jT^8BUPEOnDM=IY@GupnbRl-dO<0CU z@m`GXV$5)yip;?@qb6_)PvDo>fSYggXTnWq%4i={M$6DS8(2zvA}X^@7|8hMO?$&( ztall65_R}SGaIFNDk`<}P#rDDURa0P(<7)eas{<@0py!Snh4Yx>WS*F*jj>`U^#k} z(wS7`L&&RY79(>oYcUP?BR>V^EGh#(qdE@fqy=FjYN9Eq=iNy5%^)ntsi@cd0P6lP zQ2m@uCI712;6f6{Gg@oB9ksWG7>pIjEoK60CAG+TGWDp;>_HB?IgGse=8W|x)PMn` zN%yru9pa9t`!c$de|1>Q1)cH|R0>C7E1ZV9aRzE-)fj>esGrhC+kO#s-wsqJ-alny4)wrCs0U7=w&FX~nfS+Ezb(^$i1JZ; zU5eVGnW*O*unlfN^}iL>-(J+jjv~qMm@lY=bKxIUYQwVpDT+Zo;6}ZU15q>fqE2@+ z>TI0G6g-b(FrcUZr*}MN)82`i&{xO{VlJWccLMtpqW3?XiuNcLHDCg2#Tm#yGmsA* zwgpIb%{qJp-$uqXxs1ZAZ>Hc~_ylTiKS6fWgy$G@&c$Cqcpt{(`44MVJ{e+svz$sh zT#Y(J8!;C5q9$|#wYO(b6T6C$7|4%+4pS_aV>T*-wa6Ie84Shas6GD#mBF7-TN%-t z{AyJ2|_HP)6WrhB?Z93}A%`PPWE-G3@OIctm+~fS;y%u%Alqr?xh?RuS!X`pnGmltE zOeNIuTtekxVz^Ud?{S%}=b|#H^JjLeLb;z{Yn(qw)Xvfeg>&R=htuF=H4#DR474Ne zAT|)}hO;dbaW}eF@@mO zbq)@g#|RzPGGYlapU`1@+b)`X`nKLP_AAfIuTD0 zuM&fanZE52OI+R_QH#C4sA%tpQ5SqyqALS@Rk4XK@8@yp`{S>N`2OnLzqPll>n!j5 z)D@9AneOaNcdw-E{JuGPneKdVK-!P3^0IP$zodQR@}5s`^sdNA_BCasx_pV5mjZm9 r+*K~`#q6QJoSfoN-@<~(An%qtYTD14wqV9w<9sGfo;`W)@qOk$ew>3E delta 5641 zcmZ{m36K=k8OM7;jz#V>AmW4NhFunvQv`N71q758jUv)J)4S8oOwXo!hGkZ85YH$c zxbYxSR-+<{*E(JpOe|TVrcAW3l2ln95lN*qNySPk#%QAX{ik~aRw}Rd-@o@>zkcs~ z-}k+@^UrO6yQ!@3!N61Qv?wp3k?2p|EbA+H=u{q*{rxPf96lPc2z$|fIpXW^EZXnD z39x5>%Nhc!VNbXW4uWf;zKcQ4=fNJ9Rj{^F(ONsA7rP?f1qaf9KO7E=@HF^K*avt?fVSNb|<6%6gTC*c=fQEJsDkOKo$?#PuPyHEo)A|296}jpws1SSuFNMR5Wo2Lh zH^GnLLRdT6vc3yKFP_cax;wmA*q=h6>tF@c z_^puqw01&$w-&O)?W0fzoL(7@9}9H~W)-ODgJnmRBr5m8h0(!j`u)? z=n2>bJ|DFYLXCSBo(g{ptKr8`;|5oS{llOdUapUOfg*KC6yz@1PQ+tb1c6L1af z?XVAg6Dl2Fj(A;b1ry4uNZ+ z42r`+uo=p*n_++WAe5(`g>~@ldH7#D8h3X1BeDwiq8)?E2@lGJyP#tIBvkB2#EaJJa0UD~ zlp)I&hK3~IMB2OHMesRz0qnCV{NJz{j-dS#)P{Zye+7RBAA?WTggJIep*Ebj0S@KG zjZoR%7I7cEjP?`J`%@QN*3)Ig5ALG>oh9K;H!ls7vH|kCwD|X-ibDDlw>iaoKQmPbnHa;B0^g#B!9`}JD@zNvIzxf z4Vr_<_W}sBaTQ#KbavTXsSu{pj}tYT(Tl1?h1@J%M0dm4s0r!xC=b$TFw!x66e$-v z3pa78T*UJ!t^Z>xcOjkmn~@Tuh|WNYxz6f#q#|=Spayh5sz6Vp8&Dm(2Xz+Zhu7JN zs8A{)yP%g)4^3E(h9Z?~(S@ZN*$d-QT|YQfY&5J?3y<9M)OF-koEukLVW9a z0j+w}iiV>CcR}gMfKpLX>4>OILf4>2kg}HlA*G*Er^6qjy-4NZ5LO;Ogi>fVYD6jy z>WZFFgK`dR9mX?3pwH)5pRJ9 z(DhM!Bs?#wcjjN|jNVG;_fRr=Sp%;?H%9FzVQ+LNx-IGxE)-Voj_tMX?*GvuH=A&L!^7kP$M@{CV=}&R(zcs2c0BGoL15w;<7KkO z+3E&a<9a5O^NsJsGJZU$DmD#h=+e*j>_&&a#Wm~d7O$u&zBy<@+3Izy+N?n)?#4?q zr0r}hQ8mBbH`5k`&vhxs4jhy9^TuwpU9ZYo=et|%tYcO=d23y+KIO(#ZT;)uDP{5E zh#_C}>~c|}*mqP-x1ot_wrSq9Y4y2m%JJ({nZ~MECOxfnO+~8kUrUS~Bm+Z#+VQfE zADC!p_P+80b5^P2|$HS7quF zZeX@JzT4nB%=)cCUIA~}CTOzL_0*aZZi+8cK?Xy79G7*y#*)kJTsDJG*rH4bOs2tP zQt^@jL6upbG5Ji+G&)(6QW!MfRAYPb(zlq-P+kVcj>U35K1=2CbfcSf3oYzM+hCTZ z7@4on#Pg=v^@7o68R3mPS>hW^HCx=kE$z;X3r>X3G&}Y5JL3ZDgd^FmjfWfu6Jjy! zaqHPt6mUcCY;j|ew-R%lR8z^-p*by1XiVe@LKREO1=^6wc-p0JN&##=SaD7N>dNYw zl{03T>9gm}oLO0YR_p4qpLRX7YI)pJaFpKSU>&OZBme-M~X1#Oxk=7R` zjO|9tZ7IGxVPaX?s@9FOMpoKNVAmsOmE~@d?Xr23wDTS9*_7>fw5L1TTjDk*B&&*L zla6&6abm}s*72Mq*~JtlUwnUxS9bA{y)Is$&p1cgQYh`j-EZae>cfY!4UT8BPSUsK zY|qJ`oY^&=oygjLXLd);)|Hj#mUp!KGN_}yxVy5pSGQUxZ?_bW&K}VH|0VmebFMv+ z>{D@OX;U7jG_X0Ssd%oVE$8Lfu~*u0+D;nx@FO^+-t|q=&Du>_24arwvGS2NImslQ zl$*wA+~Vibv0OB1-tk;^V=yXh2TW+V5S)TvWomQA&a0!v=5)mEsm2L3kLHg)&V;GX z$zm-&?`YTf_~An>PAcpAN#^~p^|Gz=^kh>1gw15Q`puKA&=81u`;l zTTI+e*v4)Nv&v54%5aSqj;Yr1@;3HTEzN*$up`NVxdJ0o3M5vzskDm^PT0+{Wuhvx z!ok7-H@3);{%BK^CwaVVM|-M3j7u(^`ag#VyRxPH<8-xzU0%rl1%#aIltOf@*`2+m8{ d^==BkcAnUT+md#&Zrt^&ELFVl$%eH<>py!q(4hbT diff --git a/i18n/languages/wp-members-tr_TR.po b/i18n/languages/wp-members-tr_TR.po index 3a4080ad..19b91434 100644 --- a/i18n/languages/wp-members-tr_TR.po +++ b/i18n/languages/wp-members-tr_TR.po @@ -4,8 +4,8 @@ msgid "" msgstr "" "Project-Id-Version: WP-Members 3.2.6\n" "Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-members\n" -"POT-Creation-Date: 2020-05-22 17:48-0400\n" -"PO-Revision-Date: 2020-05-22 17:55-0400\n" +"POT-Creation-Date: 2022-01-06 15:20-0500\n" +"PO-Revision-Date: 2022-01-06 15:24-0500\n" "Last-Translator: \n" "Language-Team: hakaner \n" "Language: tr\n" @@ -13,118 +13,126 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" "X-Poedit-SourceCharset: UTF-8\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "Konu" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "Gövde" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "Seçenekler" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "Bilgiler" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "İletiler" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "Epostalar" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "Yeni Kayıt" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "Kayıt Denetlendi" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "Kayıt Denetlendi, Kullanıcı Onaylandı" -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "Åžifre Sıfırlama" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "Yönetici Bildirimi" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "Kısıtlı yazı (veya sayfa), giriÅŸ/kayıt formunun üstünde görüntülenir" -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "Kullanıcı Adı alınmış" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "Eposta kayıtlıdır" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "Kayıt tamamlandı" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "Kullanıcı güncelleme" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "Åžifreler eÅŸleÅŸmedi" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "Åžifre deÄŸiÅŸiklikleri" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" "Unutulan ÅŸifreyi sıfırlamayı denerken kullanıcı adı veya eposta mevcut deÄŸil" -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "Åžifre sıfırlama" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "Ayarlar" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -#, fuzzy -msgid "Block" -msgstr "Varsayılan olarak Yazıları Engelle" +msgid "Restrict" +msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 #: includes/admin/class-wp-members-admin-posts.php:35 @@ -133,12 +141,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -147,14 +155,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -180,268 +193,288 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "EtkinleÅŸtir" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "Dışa aktar" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 #, fuzzy msgid "Export All Users" msgstr "Dışa aktar" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:341 msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:289 +#: includes/admin/class-wp-members-admin-users.php:342 msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 msgid "Subscription" msgstr "Abonelik" -#: includes/admin/class-wp-members-admin-users.php:291 +#: includes/admin/class-wp-members-admin-users.php:344 msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 +#: includes/admin/class-wp-members-admin-users.php:348 msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 +#: includes/admin/class-wp-members-admin-users.php:349 msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" -msgstr "Hayır" - -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" -msgstr "Kullanıcı Adı" - -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" -msgstr "Aktif edildi mi?" - -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" -msgstr "BitiÅŸ tarihi" - -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" -msgstr "Kayıtlı" - -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" -msgstr "IP" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" +msgstr "" -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" -msgstr "Evet" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" +msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "BitiÅŸ tarihi" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "Evet" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 #, fuzzy msgid "Pages" msgstr "Varsayılan olarak Sayfaları Engelle" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -449,57 +482,107 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "Hayır" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "Kullanıcı Adı" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "Aktif edildi mi?" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "Kayıtlı" + +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "IP" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -680,152 +763,135 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "Yardım mı lazım?" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" -msgstr "reCAPTCHA Seçeneklerini yönet" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +msgid "Manage CAPTCHA Options" msgstr "" -"reCAPTCHA blogunuzda spamı bloke ederken kitapları dijital ortama aktarmayla " -"yardımcı olan ücretsiz, ulaşılabilir CAPTCHA hizmetidir." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" -msgstr "" -"reCAPTCHA, onların insan olduÄŸunu kanıtlamak için bir kitaptan taranmış iki " -"kelimeyi yorumcuların yeniden yazmasnı ister. Bu aynı zamanda, eski " -"kitapların otomatik taramasını düzeltirken onların bir spambot olmadığını " -"doÄŸrular. Böylece, siz daha az spam alırsınız ve dünya ise doÄŸru olarak " -"dijitalleÅŸtirilmiÅŸ kitapları alır. Herkes kazanır! Ayrıntılar için, %s " -"reCAPTCHA web sitesini%s ziyaret edin." - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" -msgstr "reCAPTCHA Anahtarları" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, fuzzy, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -"reCAPTCHA, bir \"public\" ve bir \"private\"anahtarından oluÅŸan bir API " -"anahtarı gerektirir. %s Ücretsiz bir reCAPTCHA anahtarı\" için kayıt " -"olabilirsiniz." -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" -msgstr "Public Anahtar" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" -msgstr "Private Anahtar" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" -msgstr "Tema Seç" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" +msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" -msgstr "Kırmızı" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." +msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" -msgstr "Beyaz" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" -msgstr "Siyah Cam" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" -msgstr "Temiz" +msgid "reCAPTCHA Keys" +msgstr "reCAPTCHA Anahtarları" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 #, php-format msgid "" "reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " "key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 -msgid "Characters for image" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 +#, php-format +msgid "" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 +msgid "Characters for image" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 #, fuzzy msgid "Number of characters" msgstr "Alıntıdaki kelime sayısı:" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 #, fuzzy msgid "Image type" msgstr "Bilgi Alanı Türü" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 #, fuzzy msgid "Update CAPTCHA Settings" msgstr "Ayarları Güncelle" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 #, fuzzy msgid "CAPTCHA was updated for WP-Members" msgstr "reCAPTCHA WP-Members için güncellendi" @@ -893,8 +959,8 @@ msgstr "KiÅŸisel bir eposta adresi ayarla" #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "(isteÄŸe baÄŸlı)" @@ -902,20 +968,24 @@ msgstr "(isteÄŸe baÄŸlı)" msgid "Set a custom email name" msgstr "KiÅŸisel bir eposta adı ayarla" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "Eposta İmzası" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "Epostaları Güncelle" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "WP-Members epostaları güncellendi" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -931,37 +1001,36 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "Gerekli?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Edit Field" msgstr "Bilgi Alanını Düzenle" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Add a Field" msgstr "Bir Bilgi Alanı Ekle" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "Bilgi Alanı Etiketi" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "Kullanıcıya gösterilecek bilgi alanı adı." -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." @@ -969,218 +1038,235 @@ msgstr "" "Bilgi alanı için veritabanı meta deÄŸeri. Bu benzersiz olmalı ve boÅŸluk " "içermemelidir (alt çizgiler olabilir)." -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "Bilgi Alanı Türü" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "metin" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "metin alanı" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "onay kutusu" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "ÅŸifre" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "Görüntülensin?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "Gerekli?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 msgid "Checked by default?" msgstr "Varsayılan olarak İşaretli?" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 msgid "Stored value if checked:" msgstr "İşaretlendiÄŸinde depolanan deÄŸer:" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "Seçenekler Seçenek Adı|seçenek_deÄŸeri ÅŸeklinde olmalıdır," -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "Daha fazla bilgi için eklenti sitesini ziyaret edin" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 msgid "Add Field" msgstr "Alan ekle" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 #, fuzzy msgid "Registration Date" msgstr "Kayıt tamamlandı" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -#, fuzzy -msgid "Active" -msgstr "EtkinleÅŸtir" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 msgid "Registration IP" msgstr "IP @ kaydı" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "Alanları Yönet" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "WP-Members bilgi alanları güncellendi" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2241,8 +2427,85 @@ msgid "Chad Butler" msgstr "Chad Butler" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" -msgstr "http://butlerblog.com/" +msgid "https://butlerblog.com/" +msgstr "" + +#, fuzzy +#~ msgid "Block" +#~ msgstr "Varsayılan olarak Yazıları Engelle" + +#~ msgid "Manage reCAPTCHA Options" +#~ msgstr "reCAPTCHA Seçeneklerini yönet" + +#~ msgid "" +#~ "reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize " +#~ "books while blocking spam on your blog." +#~ msgstr "" +#~ "reCAPTCHA blogunuzda spamı bloke ederken kitapları dijital ortama " +#~ "aktarmayla yardımcı olan ücretsiz, ulaşılabilir CAPTCHA hizmetidir." + +#, php-format +#~ msgid "" +#~ "reCAPTCHA asks commenters to retype two words scanned from a book to " +#~ "prove that they are a human. This verifies that they are not a spambot " +#~ "while also correcting the automatic scans of old books. So you get less " +#~ "spam, and the world gets accurately digitized books. Everybody wins! For " +#~ "details, visit the %s reCAPTCHA website%s" +#~ msgstr "" +#~ "reCAPTCHA, onların insan olduÄŸunu kanıtlamak için bir kitaptan taranmış " +#~ "iki kelimeyi yorumcuların yeniden yazmasnı ister. Bu aynı zamanda, eski " +#~ "kitapların otomatik taramasını düzeltirken onların bir spambot olmadığını " +#~ "doÄŸrular. Böylece, siz daha az spam alırsınız ve dünya ise doÄŸru olarak " +#~ "dijitalleÅŸtirilmiÅŸ kitapları alır. Herkes kazanır! Ayrıntılar için, %s " +#~ "reCAPTCHA web sitesini%s ziyaret edin." + +#, fuzzy, php-format +#~ msgid "" +#~ "reCAPTCHA requires an API key, consisting of a \"public\" and a \"private" +#~ "\" key. You can sign up for a %s free reCAPTCHA key%s" +#~ msgstr "" +#~ "reCAPTCHA, bir \"public\" ve bir \"private\"anahtarından oluÅŸan bir API " +#~ "anahtarı gerektirir. %s Ücretsiz bir reCAPTCHA anahtarı\" için kayıt " +#~ "olabilirsiniz." + +#~ msgid "Public Key" +#~ msgstr "Public Anahtar" + +#~ msgid "Private Key" +#~ msgstr "Private Anahtar" + +#~ msgid "Choose Theme" +#~ msgstr "Tema Seç" + +#~ msgid "Red" +#~ msgstr "Kırmızı" + +#~ msgid "White" +#~ msgstr "Beyaz" + +#~ msgid "Black Glass" +#~ msgstr "Siyah Cam" + +#~ msgid "Clean" +#~ msgstr "Temiz" + +#, fuzzy +#~ msgid "Active" +#~ msgstr "EtkinleÅŸtir" + +#, fuzzy +#~ msgid "Enable CAPTCHA" +#~ msgstr "Kayıt için CAPTCHA özelliÄŸini açar" + +#~ msgid "Passwords did not match.

    Please try again." +#~ msgstr "Åžifreler eÅŸleÅŸmedi.

    Lütfen tekrar deneyin." + +#~ msgid "Either the username or email address do not exist in our records." +#~ msgstr "" +#~ "Kullanıcı adı veya eposta adresinin her ikisi de kayıtlarımızda yok." + +#~ msgid "http://butlerblog.com/" +#~ msgstr "http://butlerblog.com/" #, fuzzy #~ msgid "Click to log out." diff --git a/i18n/languages/wp-members.pot b/i18n/languages/wp-members.pot index 5d99ae4a..0e1e7222 100644 --- a/i18n/languages/wp-members.pot +++ b/i18n/languages/wp-members.pot @@ -3,14 +3,14 @@ msgid "" msgstr "" "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" "Project-Id-Version: WP-Members\n" -"POT-Creation-Date: 2020-05-22 17:48-0400\n" +"POT-Creation-Date: 2022-01-06 15:20-0500\n" "PO-Revision-Date: 2020-05-22 17:48-0400\n" "Last-Translator: \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.3.1\n" +"X-Generator: Poedit 2.4.3\n" "X-Poedit-Basepath: ../..\n" "X-Poedit-Flags-xgettext: --add-comments=translators:\n" "X-Poedit-WPHeader: wp-members.php\n" @@ -21,112 +21,121 @@ msgstr "" "X-Poedit-SearchPath-0: .\n" "X-Poedit-SearchPathExcluded-0: *.min.js\n" -#: includes/admin/class-wp-members-admin-api.php:292 +#: includes/admin/class-wp-members-admin-api.php:254 msgid "Custom email" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:293 -#: includes/admin/class-wp-members-admin-api.php:295 +#: includes/admin/class-wp-members-admin-api.php:255 +#: includes/admin/class-wp-members-admin-api.php:257 msgid "Subject" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:296 +#: includes/admin/class-wp-members-admin-api.php:258 msgid "Body" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:298 +#: includes/admin/class-wp-members-admin-api.php:260 msgid "Your custom email message content." msgstr "" -#: includes/admin/class-wp-members-admin-api.php:376 +#: includes/admin/class-wp-members-admin-api.php:338 msgid "Options" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:377 +#: includes/admin/class-wp-members-admin-api.php:339 msgid "Fields" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:378 +#: includes/admin/class-wp-members-admin-api.php:340 msgid "Dialogs" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:379 +#: includes/admin/class-wp-members-admin-api.php:341 msgid "Emails" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:395 +#: includes/admin/class-wp-members-admin-api.php:357 msgid "New Registration" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:404 +#: includes/admin/class-wp-members-admin-api.php:365 +#: includes/admin/class-wp-members-admin-api.php:383 +msgid "User email validated" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:375 msgid "Registration is Moderated" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:410 +#: includes/admin/class-wp-members-admin-api.php:391 msgid "Registration is Moderated, User is Approved" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:418 +#: includes/admin/class-wp-members-admin-api.php:399 msgid "Password Reset" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:425 +#: includes/admin/class-wp-members-admin-api.php:406 msgid "Retrieve Username" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:433 +#: includes/admin/class-wp-members-admin-api.php:414 msgid "Admin Notification" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:459 +#: includes/admin/class-wp-members-admin-api.php:440 msgid "Restricted post (or page), displays above the login/registration form" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:460 +#: includes/admin/class-wp-members-admin-api.php:441 msgid "Username is taken" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:461 +#: includes/admin/class-wp-members-admin-api.php:442 msgid "Email is registered" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:462 +#: includes/admin/class-wp-members-admin-api.php:443 msgid "Registration completed" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:463 +#: includes/admin/class-wp-members-admin-api.php:444 msgid "User update" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:464 +#: includes/admin/class-wp-members-admin-api.php:445 msgid "Passwords did not match" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:465 +#: includes/admin/class-wp-members-admin-api.php:446 msgid "Password changes" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:466 +#: includes/admin/class-wp-members-admin-api.php:447 msgid "Username or email do not exist when trying to reset forgotten password" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:467 +#: includes/admin/class-wp-members-admin-api.php:448 msgid "Password reset" msgstr "" -#: includes/admin/class-wp-members-admin-api.php:623 +#: includes/admin/class-wp-members-admin-api.php:547 +msgid "Close" +msgstr "" + +#: includes/admin/class-wp-members-admin-api.php:596 msgid "Settings" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:30 #: includes/admin/class-wp-members-admin-posts.php:33 -msgid "Unblock" +msgid "Unrestrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:31 #: includes/admin/class-wp-members-admin-posts.php:34 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:110 -msgid "Block" +msgid "Restrict" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:32 @@ -136,12 +145,12 @@ msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s blocked" +msgid "%s restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:125 #, php-format -msgid "%s unblocked" +msgid "%s unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:165 @@ -150,14 +159,19 @@ msgid "%s Restriction" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:195 -msgid "Unblocked" +#: includes/admin/class-wp-members-admin-posts.php:342 +#: includes/admin/class-wp-members-admin-posts.php:345 +msgid "Unrestricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:196 -msgid "Blocked" +#: includes/admin/class-wp-members-admin-posts.php:339 +#: includes/admin/class-wp-members-admin-posts.php:347 +msgid "Restricted" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:197 +#: includes/admin/class-wp-members-admin-posts.php:349 msgid "Hidden" msgstr "" @@ -182,266 +196,286 @@ msgid "Cancel" msgstr "" #: includes/admin/class-wp-members-admin-posts.php:305 -#: includes/admin/class-wp-members-products-admin.php:629 msgid "Status" msgstr "" #: includes/admin/class-wp-members-admin-users.php:28 -#: includes/admin/class-wp-members-admin-users.php:33 -#: includes/admin/class-wp-members-admin-users.php:59 +#: includes/admin/class-wp-members-admin-users.php:34 +#: includes/admin/class-wp-members-admin-users.php:79 msgid "Activate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:29 -#: includes/admin/class-wp-members-admin-users.php:34 -#: includes/admin/class-wp-members-admin-users.php:62 +#: includes/admin/class-wp-members-admin-users.php:35 +#: includes/admin/class-wp-members-admin-users.php:82 msgid "Deactivate" msgstr "" #: includes/admin/class-wp-members-admin-users.php:31 -#: includes/admin/class-wp-members-admin-users.php:36 +#: includes/admin/class-wp-members-admin-users.php:37 msgid "Export" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:37 -#: includes/admin/class-wp-members-admin-users.php:88 +#: includes/admin/class-wp-members-admin-users.php:32 +#: includes/admin/class-wp-members-admin-users.php:38 msgid "Export All Users" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:61 +msgid "Confirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:64 +msgid "Unconfirm" +msgstr "" + +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:126 +#: includes/admin/class-wp-members-admin-users.php:147 #, php-format msgid "%s users deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:129 +#: includes/admin/class-wp-members-admin-users.php:150 msgid "No users selected" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:147 +#: includes/admin/class-wp-members-admin-users.php:168 msgid "You cannot activate or deactivate yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:152 +#: includes/admin/class-wp-members-admin-users.php:173 #, php-format msgid "%s activated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:157 +#: includes/admin/class-wp-members-admin-users.php:178 #, php-format msgid "%s deactivated" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:161 +#: includes/admin/class-wp-members-admin-users.php:182 msgid "That user is already active" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:288 -msgid "Pending" -msgstr "" - -#: includes/admin/class-wp-members-admin-users.php:289 -msgid "Trial" +#: includes/admin/class-wp-members-admin-users.php:198 +msgid "You cannot confirm or unconfirm yourself" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:290 -#: includes/admin/class-wp-members-export.php:74 -msgid "Subscription" +#: includes/admin/class-wp-members-admin-users.php:203 +#, php-format +msgid "%s confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:291 -msgid "Expired" +#: includes/admin/class-wp-members-admin-users.php:208 +#, php-format +msgid "%s unconfirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:294 -msgid "Activated" +#: includes/admin/class-wp-members-admin-users.php:212 +msgid "That user is already confirmed" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:295 -msgid "Pending Activation" +#: includes/admin/class-wp-members-admin-users.php:341 +msgid "Pending" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:296 -msgid "Deactivated" +#: includes/admin/class-wp-members-admin-users.php:342 +msgid "Trial" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:298 -msgid "Not Exported" +#: includes/admin/class-wp-members-admin-users.php:343 +#: includes/admin/class-wp-members-user-export.php:289 +msgid "Subscription" msgstr "" -#: includes/admin/class-wp-members-admin-users.php:387 -#: includes/admin/class-wp-members-export.php:160 -msgid "No" +#: includes/admin/class-wp-members-admin-users.php:344 +msgid "Expired" msgstr "" -#: includes/admin/class-wp-members-export.php:64 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 -msgid "User ID" +#: includes/admin/class-wp-members-admin-users.php:347 +#: includes/admin/class-wp-members-admin-users.php:410 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:457 +msgid "Activated" msgstr "" -#: includes/admin/class-wp-members-export.php:65 -#: includes/class-wp-members.php:1523 includes/class-wp-members.php:1546 -msgid "Username" +#: includes/admin/class-wp-members-admin-users.php:348 +msgid "Pending Activation" msgstr "" -#: includes/admin/class-wp-members-export.php:71 -msgid "Activated?" +#: includes/admin/class-wp-members-admin-users.php:349 +msgid "Deactivated" msgstr "" -#: includes/admin/class-wp-members-export.php:75 -#: includes/admin/class-wp-members-products-admin.php:64 -#: includes/admin/class-wp-members-products-admin.php:632 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:448 -msgid "Expires" +#: includes/admin/class-wp-members-admin-users.php:352 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:456 +msgid "Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:77 -msgid "Registered" +#: includes/admin/class-wp-members-admin-users.php:353 +msgid "Not Confirmed" msgstr "" -#: includes/admin/class-wp-members-export.php:78 -msgid "IP" +#: includes/admin/class-wp-members-admin-users.php:355 +msgid "Not Exported" msgstr "" -#: includes/admin/class-wp-members-export.php:160 -#: includes/admin/class-wp-members-products-admin.php:104 -msgid "Yes" +#: includes/admin/class-wp-members-admin-users.php:475 +msgid "Not confirmed" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:62 +#: includes/admin/class-wp-members-products-admin.php:67 msgid "Slug" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:63 +#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-user-export.php:294 msgid "Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:66 +#: includes/admin/class-wp-members-products-admin.php:69 +#: includes/admin/class-wp-members-products-admin.php:740 +#: includes/admin/class-wp-members-user-export.php:290 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:460 +msgid "Expires" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:71 msgid "Default" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:68 +#: includes/admin/class-wp-members-products-admin.php:73 msgid "Last updated" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:92 +#: includes/admin/class-wp-members-products-admin.php:97 msgid "slug:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:95 +#: includes/admin/class-wp-members-products-admin.php:100 msgid "No role required" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:100 +#: includes/admin/class-wp-members-products-admin.php:105 msgid "Does not expire" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:140 +#: includes/admin/class-wp-members-products-admin.php:109 +#: includes/admin/class-wp-members-user-export.php:199 +msgid "Yes" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:145 msgid "Membership Product Details" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:148 +#: includes/admin/class-wp-members-products-admin.php:153 msgid "Membership Product Message (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:165 +#: includes/admin/class-wp-members-products-admin.php:169 +msgid "Access by child membership" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:185 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:62 msgid "Posts" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:166 +#: includes/admin/class-wp-members-products-admin.php:186 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:63 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:213 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:249 msgid "Pages" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 -#: includes/admin/class-wp-members-products-admin.php:235 -#: includes/admin/class-wp-members-products-admin.php:280 +#: includes/admin/class-wp-members-products-admin.php:213 +#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:309 msgid "Period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Day" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Week" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Month" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:193 +#: includes/admin/class-wp-members-products-admin.php:213 msgid "Year" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:199 +#: includes/admin/class-wp-members-products-admin.php:226 msgid "Name (slug)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:201 +#: includes/admin/class-wp-members-products-admin.php:228 msgid "Optional Defaults" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:204 +#: includes/admin/class-wp-members-products-admin.php:231 msgid "Assign as default at registration? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:212 +#: includes/admin/class-wp-members-products-admin.php:239 #, php-format msgid "Pre-selected by default for new %s" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:218 +#: includes/admin/class-wp-members-products-admin.php:245 msgid "Optional Properties" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:221 +#: includes/admin/class-wp-members-products-admin.php:248 msgid "Role Required? (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:224 +#: includes/admin/class-wp-members-products-admin.php:251 msgid "No Role" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:230 +#: includes/admin/class-wp-members-products-admin.php:257 msgid "Expires (optional)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:232 -#: includes/admin/class-wp-members-products-admin.php:234 -#: includes/admin/class-wp-members-products-admin.php:277 -#: includes/admin/class-wp-members-products-admin.php:279 +#: includes/admin/class-wp-members-products-admin.php:259 +#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:306 +#: includes/admin/class-wp-members-products-admin.php:308 msgid "Number" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:240 +#: includes/admin/class-wp-members-products-admin.php:267 msgid "Use \"no gap\" renewal" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:244 +#: includes/admin/class-wp-members-products-admin.php:271 msgid "Use a fixed period (such as Jan 1 - Dec 31, or Sept 1 - Aug 31)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:261 +#: includes/admin/class-wp-members-products-admin.php:288 +#: includes/admin/class-wp-members-products-admin.php:289 msgid "Period Start (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:262 +#: includes/admin/class-wp-members-products-admin.php:290 +#: includes/admin/class-wp-members-products-admin.php:291 msgid "Period End (dd-mm)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:275 +#: includes/admin/class-wp-members-products-admin.php:304 msgid "Fixed period grace period" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:284 +#: includes/admin/class-wp-members-products-admin.php:313 msgid "" "Grace period is the point at which expiration date is for following time " "period. For example, if user who register August 1st would be part of the " @@ -449,57 +483,107 @@ msgid "" "blank for no grace period." msgstr "" -#: includes/admin/class-wp-members-products-admin.php:333 +#: includes/admin/class-wp-members-products-admin.php:376 msgid "" "Restricted Message (displays when a user does not have access to a " "membership)" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:435 -#: includes/admin/tabs/class-wp-members-admin-tab-options.php:204 -#: includes/class-wp-members-forms.php:1092 -#: includes/class-wp-members-user-profile.php:112 +#: includes/admin/class-wp-members-products-admin.php:502 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:239 +#: includes/class-wp-members-forms.php:1196 +#: includes/class-wp-members-user-profile.php:132 msgid "None" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:450 -msgid "Limit access to:" +#: includes/admin/class-wp-members-products-admin.php:517 +msgid "Restrict access by membership:" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:520 +#: includes/admin/class-wp-members-products-admin.php:598 msgid "Required Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:559 -#: includes/admin/class-wp-members-products-admin.php:630 +#: includes/admin/class-wp-members-products-admin.php:644 +#: includes/admin/class-wp-members-products-admin.php:745 +#: includes/class-wp-members-products.php:335 msgid "Membership" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:599 -#: includes/class-wp-members-products.php:308 +#: includes/admin/class-wp-members-products-admin.php:680 +msgid "expires:" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:709 +#: includes/class-wp-members-products.php:336 +#: includes/class-wp-members-products.php:341 msgid "Memberships" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:626 -msgid "Product Access" +#: includes/admin/class-wp-members-products-admin.php:736 +msgid "Membership Access" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:631 +#: includes/admin/class-wp-members-products-admin.php:744 +msgid "Action" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:746 msgid "Enabled?" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:641 +#: includes/admin/class-wp-members-products-admin.php:757 msgid "Enable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:642 +#: includes/admin/class-wp-members-products-admin.php:758 msgid "Disable" msgstr "" -#: includes/admin/class-wp-members-products-admin.php:647 +#: includes/admin/class-wp-members-products-admin.php:759 +msgid "Update" +msgstr "" + +#: includes/admin/class-wp-members-products-admin.php:764 msgid "Expiration date (optional)" msgstr "" +#: includes/admin/class-wp-members-products-admin.php:795 +#, php-format +msgid "No memberships have been created. %sCreate new memberships here%s" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:199 +msgid "No" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:264 +msgid "You do not have the required user capabilities to export users." +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:277 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:461 +msgid "User ID" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:284 +#: includes/class-wp-members-dialogs.php:91 +#: includes/class-wp-members-dialogs.php:114 +msgid "Username" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:286 +msgid "Activated?" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:292 +msgid "Registered" +msgstr "" + +#: includes/admin/class-wp-members-user-export.php:293 +msgid "IP" +msgstr "" + #: includes/admin/dialogs.php:117 msgid "" "Your WP settings allow anyone to register - this is not the recommended " @@ -649,138 +733,132 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:74 #: includes/admin/tabs/class-wp-members-admin-tab-dialogs.php:57 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:100 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:109 #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:134 #: includes/admin/tabs/class-wp-members-admin-tab-options.php:78 msgid "Need help?" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:85 -msgid "Manage reCAPTCHA Options" +msgid "Manage CAPTCHA Options" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 -msgid "" -"reCAPTCHA is a free, accessible CAPTCHA service that helps to digitize books " -"while blocking spam on your blog." +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:91 +msgid "CAPTCHA Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:100 -#, php-format -msgid "" -"reCAPTCHA asks commenters to retype two words scanned from a book to prove " -"that they are a human. This verifies that they are not a spambot while also " -"correcting the automatic scans of old books. So you get less spam, and the " -"world gets accurately digitized books. Everybody wins! For details, visit " -"the %s reCAPTCHA website%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:96 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:243 +msgid "reCAPTCHA v2" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:105 -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:131 -msgid "reCAPTCHA Keys" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:97 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:244 +msgid "reCAPTCHA v3" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:107 -#, php-format -msgid "" -"reCAPTCHA requires an API key, consisting of a \"public\" and a \"private\" " -"key. You can sign up for a %s free reCAPTCHA key%s" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:98 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:245 +msgid "Really Simple CAPTCHA" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:108 -msgid "Public Key" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:99 +#: includes/admin/tabs/class-wp-members-admin-tab-options.php:246 +msgid "hCaptcha" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:109 -msgid "Private Key" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:106 +msgid "" +"CAPTCHA type was changed. Please verify and update the settings below for " +"the new CAPTCHA type." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:113 -msgid "Choose Theme" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 +msgid "reCAPTCHA Keys" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:116 -msgid "Red" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:120 +#, php-format +msgid "" +"reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " +"key. You can sign up for a %s free reCAPTCHA key%s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:117 -msgid "White" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:122 +msgid "Site Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:118 -msgid "Black Glass" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:123 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:139 +msgid "Secret Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:119 -msgid "Clean" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +msgid "hCaptcha Keys" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:133 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:136 #, php-format msgid "" -"reCAPTCHA requires an API key, consisting of a \"site\" and a \"secret\" " -"key. You can sign up for a %s free reCAPTCHA key%s" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:134 -msgid "Site Key" +"hCaptcha requires an API key. You can sign up for %s an hCaptcha API key " +"here %s" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:135 -msgid "Secret Key" +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:138 +msgid "API Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:166 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 msgid "Characters for image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:170 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 msgid "Number of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 msgid "Image dimensions" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Width" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:175 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:179 msgid "Height" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:178 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 msgid "Font color of characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:182 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 msgid "Background color of image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:186 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 msgid "Font size" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:190 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 msgid "Width between characters" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:198 msgid "Image type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:208 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:213 msgid "" "To use Really Simple CAPTCHA, you must have the Really Simple CAPTCHA plugin " "installed and activated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:233 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:241 msgid "Update CAPTCHA Settings" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-captcha.php:319 msgid "CAPTCHA was updated for WP-Members" msgstr "" @@ -844,8 +922,8 @@ msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:70 #: includes/admin/tabs/class-wp-members-admin-tab-emails.php:74 -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:163 msgid "(optional)" msgstr "" @@ -853,20 +931,24 @@ msgstr "" msgid "Set a custom email name" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:84 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:77 +msgid "Send HTML email" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:93 msgid "Email Signature" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:92 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:101 msgid "Update Emails" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:161 +#: includes/admin/tabs/class-wp-members-admin-tab-emails.php:172 msgid "WP-Members emails were updated" msgstr "" #: includes/admin/tabs/class-wp-members-admin-tab-fields.php:93 -#: includes/class-wp-members.php:1498 +#: includes/class-wp-members-dialogs.php:65 msgid "No fields selected for deletion" msgstr "" @@ -882,252 +964,269 @@ msgstr "" msgid "Field Manager Documentation" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:162 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 -#: includes/class-wp-members-forms.php:1626 -#: includes/class-wp-members-forms.php:1803 -#: includes/class-wp-members-user-profile.php:144 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:164 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 +#: includes/class-wp-members-forms.php:1629 +#: includes/class-wp-members-forms.php:1821 +#: includes/class-wp-members-user-profile.php:181 msgid "(required)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Edit Field" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:167 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:169 msgid "Add a Field" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:172 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 msgid "Field Label" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:174 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:176 msgid "The name of the field as it will be displayed to the user." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:177 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:179 #: includes/admin/tabs/class-wp-members-fields-table.php:58 msgid "Meta Key" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:183 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:185 msgid "" "The database meta value for the field. It must be unique and contain no " "spaces (underscores are ok)." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:187 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:189 #: includes/admin/tabs/class-wp-members-fields-table.php:59 msgid "Field Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:193 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 msgid "text" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:194 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 msgid "email" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:195 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 msgid "textarea" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:196 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 msgid "checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:197 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 msgid "multiple checkbox" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:198 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 msgid "select (dropdown)" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:199 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 msgid "multiple select" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:200 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 msgid "radio group" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:201 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 msgid "password" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:202 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 msgid "image" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:203 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 msgid "file" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:204 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 msgid "url" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:205 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 msgid "number" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:206 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:208 msgid "date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:207 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 msgid "hidden" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:209 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:211 msgid "membership" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:215 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:217 #: includes/admin/tabs/class-wp-members-fields-table.php:60 msgid "Display?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:219 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:221 msgid "This field is always displayed" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:224 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:226 msgid "Required?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:228 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:230 msgid "This field is always required" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:234 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:236 msgid "Allow HTML?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:241 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:243 msgid "Placeholder" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:249 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:251 msgid "Pattern" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:255 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:259 msgid "Title" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:264 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 msgid "Minimum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:268 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:272 msgid "Maximum Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:276 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 msgid "Rows" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:280 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:284 msgid "Columns" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:288 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:292 msgid "Accepted file types:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:293 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:297 msgid "Accepted file types should be set like this: jpg|jpeg|png|gif" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:300 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 msgid "Checked by default?" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:304 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:308 +msgid "HTML label position" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:310 +msgid "Before the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:311 +msgid "After the input tag" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:312 +msgid "" +"Selecting \"after\" will generally display the label to the right of the " +"checkbox" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:315 msgid "Stored value if checked:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:325 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:336 msgid "Stored values delimiter:" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:334 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:345 msgid "Values (Displayed|Stored):" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:359 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 msgid "Options should be Option Name|option_value," msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:363 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:374 msgid "Visit plugin site for more information" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:370 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:381 msgid "Value" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:389 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:514 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:515 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +msgid "Save Changes" +msgstr "" + +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:400 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:527 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:528 msgid "Add Field" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:391 -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:711 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:402 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:726 msgid "Return to Fields Table" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:438 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:449 msgid "Drag and drop to reorder fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:444 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:455 msgid "Registration Date" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:445 -msgid "Active" -msgstr "" - -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:446 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:458 msgid "Registration IP" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:447 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:459 msgid "Subscription Type" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:482 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:495 msgid "Manage Fields" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:581 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:595 msgid "WP-Members fields were updated" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:603 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:617 msgid "Field Label is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:604 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 msgid "Meta Key is required. Nothing was updated." msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:606 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:620 msgid "Meta Key must contain only letters, numbers, and underscores" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:613 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:627 msgid "A field with that meta key already exists" msgstr "" -#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:618 +#: includes/admin/tabs/class-wp-members-admin-tab-fields.php:632 #, php-format msgid "" "Sorry, \"%s\" is a the online Users Guide. A Quick Start Guide is also " -"available. WP-Members(tm) is a trademark of butlerblog.com." +"features, refer to the online Users Guide. A Quick Start Guide is also available. WP-" +"Members(tm) is a trademark of butlerblog.com." msgstr "" #. Author of the plugin/theme @@ -2160,5 +2360,5 @@ msgid "Chad Butler" msgstr "" #. Author URI of the plugin/theme -msgid "http://butlerblog.com/" +msgid "https://butlerblog.com/" msgstr "" From 7ee852468397c5221a70adb973c386d7279e732f Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 Jan 2022 11:54:16 -0500 Subject: [PATCH 1559/1694] change function name for backwards compatibility in paypal extension --- includes/api/api-users.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/includes/api/api-users.php b/includes/api/api-users.php index bfba625c..733b0d8c 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -236,6 +236,8 @@ function wpmem_user_has_access( $product, $user_id = false ) { * * Similar to wpmem_user_has_access(), but specifically checks the * expiration date for a specified product (must be expiration product). + * + * Must be named _user_is_current() as _is_user_current() exists in PayPal extension. * * @since 3.3.9 * @@ -243,7 +245,7 @@ function wpmem_user_has_access( $product, $user_id = false ) { * @param integer $user_id * @return boolean */ -function wpmem_is_user_current( $product, $user_id = false ) { +function wpmem_user_is_current( $product, $user_id = false ) { global $wpmem; $user_id = ( false === $user_id ) ? get_current_user_id() : $user_id; $memberships = wpmem_get_user_products( $user_id ); From 2942ad27e352997ebba54d292e916693da84a83d Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 Jan 2022 11:54:59 -0500 Subject: [PATCH 1560/1694] correct syntax --- includes/class-wp-members-shortcodes.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index cf028b2d..1ed3ae1b 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -451,7 +451,7 @@ function user_profile( $atts, $content, $tag ) { break; case "pwdchange": - $content = $this->render_pwd_reset()( $wpmem->regchk, $content ); + $content = $this->render_pwd_reset( $wpmem->regchk, $content ); $content = ( 'pwdchangesuccess' == $wpmem->regchk ) ? $content . $this->render_links() : $content; break; From 5af916e810c72f794be698a3bbf32e5270a9e126 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 Jan 2022 11:55:24 -0500 Subject: [PATCH 1561/1694] bug fix release --- readme.txt | 8 +++++++- wp-members.php | 4 ++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/readme.txt b/readme.txt index 7a67d16b..03dbabf7 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: cbutlerjr Tags: access, authentication, content, login, member, membership, password, protect, register, registration, restriction, subscriber Requires at least: 4.0 Tested up to: 5.8 -Stable tag: 3.4.1 +Stable tag: 3.4.1.1 License: GPLv3 @@ -134,6 +134,11 @@ WP-Members 3.4.1 is a minor update. Backup prior to upgrading is recommended. Se == Changelog == += 3.4.1.1 = + +* Fixes a bug in the password change shortcode that causes a "too few arguments" error. +* Changes wpmem_is_user_current() to wpmem_user_is_current() for backwards compatibility with the plugin's premium PayPal extension. + = 3.4.1 = * Revise the membership hierarchy logic (see release announcement for details). @@ -141,6 +146,7 @@ WP-Members 3.4.1 is a minor update. Backup prior to upgrading is recommended. Se * Changing "Block" text to "Restricted" for clarity (was planned for 3.4.0). * Added wpmem_is_user_current() api function. * Added attachements to email function. +* Added wpmem_email_attachments filter. * Moves external libraries to "vendor" directory. * Removes a overlooked use of wpmem_page_pwd_reset() which was deprecated as of 3.4.0. * Sanitize email as email, not text. diff --git a/wp-members.php b/wp-members.php index 6e79df34..ce127cea 100644 --- a/wp-members.php +++ b/wp-members.php @@ -3,7 +3,7 @@ Plugin Name: WP-Members Plugin URI: https://rocketgeek.com Description: WP access restriction and user registration. For more information on plugin features, refer to the online Users Guide. A Quick Start Guide is also available. WP-Members(tm) is a trademark of butlerblog.com. -Version: 3.4.1 +Version: 3.4.1.1 Author: Chad Butler Author URI: https://butlerblog.com/ Text Domain: wp-members @@ -58,7 +58,7 @@ } // Initialize constants. -define( 'WPMEM_VERSION', '3.4.1' ); +define( 'WPMEM_VERSION', '3.4.1.1' ); define( 'WPMEM_DB_VERSION', '2.3.0' ); define( 'WPMEM_PATH', plugin_dir_path( __FILE__ ) ); From 5c7bb516a8e57f49845b252fd6aa550d62d398a0 Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 Jan 2022 11:55:42 -0500 Subject: [PATCH 1562/1694] copyright date change --- assets/css/admin.css | 4 ++-- assets/css/forms/generic-no-float.css | 4 ++-- assets/css/forms/generic-rigid.css | 4 ++-- assets/css/forms/wp-members-styles.css | 4 ++-- assets/js/admin.js | 4 ++-- includes/admin/admin.php | 4 ++-- includes/admin/api.php | 4 ++-- includes/admin/dialogs.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-captcha.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-dialogs.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-dropins.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-emails.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-fields.php | 4 ++-- includes/admin/tabs/class-wp-members-admin-tab-options.php | 4 ++-- includes/admin/tabs/class-wp-members-dropins-table.php | 4 ++-- includes/admin/tabs/class-wp-members-fields-table.php | 4 ++-- includes/api/api-email.php | 4 ++-- includes/api/api-forms.php | 4 ++-- includes/api/api-products.php | 4 ++-- includes/api/api-users.php | 4 ++-- includes/api/api-utilities.php | 4 ++-- includes/api/api.php | 4 ++-- includes/class-wp-members-email.php | 4 ++-- includes/class-wp-members-shortcodes.php | 4 ++-- includes/deprecated.php | 4 ++-- includes/install.php | 4 ++-- includes/legacy/dialogs.php | 4 ++-- includes/vendor/rocketgeek-utilities/includes/arrays.php | 4 ++-- includes/vendor/rocketgeek-utilities/includes/dates.php | 4 ++-- includes/vendor/rocketgeek-utilities/includes/debug.php | 4 ++-- includes/vendor/rocketgeek-utilities/includes/forms.php | 4 ++-- includes/vendor/rocketgeek-utilities/includes/strings.php | 4 ++-- includes/vendor/rocketgeek-utilities/includes/utilities.php | 4 ++-- includes/vendor/rocketgeek-utilities/loader.php | 4 ++-- templates/tos.php | 4 ++-- uninstall.php | 4 ++-- wp-members.php | 2 +- 37 files changed, 73 insertions(+), 73 deletions(-) diff --git a/assets/css/admin.css b/assets/css/admin.css index 4fbf8fcc..653467e2 100644 --- a/assets/css/admin.css +++ b/assets/css/admin.css @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ diff --git a/assets/css/forms/generic-no-float.css b/assets/css/forms/generic-no-float.css index 85491a82..e692306d 100644 --- a/assets/css/forms/generic-no-float.css +++ b/assets/css/forms/generic-no-float.css @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ /* diff --git a/assets/css/forms/generic-rigid.css b/assets/css/forms/generic-rigid.css index 12fa7439..5f58383b 100644 --- a/assets/css/forms/generic-rigid.css +++ b/assets/css/forms/generic-rigid.css @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ /* diff --git a/assets/css/forms/wp-members-styles.css b/assets/css/forms/wp-members-styles.css index 8ea79c99..e1410e04 100644 --- a/assets/css/forms/wp-members-styles.css +++ b/assets/css/forms/wp-members-styles.css @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ /* diff --git a/assets/js/admin.js b/assets/js/admin.js index 5db2b3b5..d9101a79 100644 --- a/assets/js/admin.js +++ b/assets/js/admin.js @@ -5,12 +5,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ diff --git a/includes/admin/admin.php b/includes/admin/admin.php index 3a6c2fdd..69190474 100644 --- a/includes/admin/admin.php +++ b/includes/admin/admin.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 * * Functions included: * - wpmem_admin diff --git a/includes/admin/api.php b/includes/admin/api.php index 4578af2f..acae37ac 100644 --- a/includes/admin/api.php +++ b/includes/admin/api.php @@ -4,12 +4,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 * * Functions included: * - wpmem_add_custom_email diff --git a/includes/admin/dialogs.php b/includes/admin/dialogs.php index 33ed6ccf..60b64211 100644 --- a/includes/admin/dialogs.php +++ b/includes/admin/dialogs.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 * * Functions included: * - wpmem_a_do_warnings diff --git a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php index d0e6647f..fa0fbc10 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-captcha.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-captcha.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-dialogs.php b/includes/admin/tabs/class-wp-members-admin-tab-dialogs.php index 2284ceb3..815fc211 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-dialogs.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-dialogs.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-dropins.php b/includes/admin/tabs/class-wp-members-admin-tab-dropins.php index 59aa3810..c46c74cd 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-dropins.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-dropins.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-emails.php b/includes/admin/tabs/class-wp-members-admin-tab-emails.php index 1e124381..33986972 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-emails.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-emails.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-fields.php b/includes/admin/tabs/class-wp-members-admin-tab-fields.php index fd238a01..96e567ad 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-fields.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-fields.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-admin-tab-options.php b/includes/admin/tabs/class-wp-members-admin-tab-options.php index 0c164242..6973a694 100644 --- a/includes/admin/tabs/class-wp-members-admin-tab-options.php +++ b/includes/admin/tabs/class-wp-members-admin-tab-options.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-dropins-table.php b/includes/admin/tabs/class-wp-members-dropins-table.php index ed3c126b..ff461f94 100644 --- a/includes/admin/tabs/class-wp-members-dropins-table.php +++ b/includes/admin/tabs/class-wp-members-dropins-table.php @@ -4,12 +4,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/admin/tabs/class-wp-members-fields-table.php b/includes/admin/tabs/class-wp-members-fields-table.php index a2c06ac1..f1166691 100644 --- a/includes/admin/tabs/class-wp-members-fields-table.php +++ b/includes/admin/tabs/class-wp-members-fields-table.php @@ -4,12 +4,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/api/api-email.php b/includes/api/api-email.php index 611ea173..d54ec088 100644 --- a/includes/api/api-email.php +++ b/includes/api/api-email.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ /** diff --git a/includes/api/api-forms.php b/includes/api/api-forms.php index ceae10ea..533920de 100644 --- a/includes/api/api-forms.php +++ b/includes/api/api-forms.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ if ( ! function_exists( 'wpmem_login_form' ) ): diff --git a/includes/api/api-products.php b/includes/api/api-products.php index 8476085c..13a94b9b 100644 --- a/includes/api/api-products.php +++ b/includes/api/api-products.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ /** diff --git a/includes/api/api-users.php b/includes/api/api-users.php index 733b0d8c..c6af39e9 100644 --- a/includes/api/api-users.php +++ b/includes/api/api-users.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ /** diff --git a/includes/api/api-utilities.php b/includes/api/api-utilities.php index fb825203..bb040bfe 100644 --- a/includes/api/api-utilities.php +++ b/includes/api/api-utilities.php @@ -7,13 +7,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members Utility Functions * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ if ( ! function_exists( 'wpmem_securify' ) ): diff --git a/includes/api/api.php b/includes/api/api.php index d9aec24c..582c2136 100644 --- a/includes/api/api.php +++ b/includes/api/api.php @@ -4,13 +4,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP-Members API Functions * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/class-wp-members-email.php b/includes/class-wp-members-email.php index 99525ce1..ca1f9acc 100644 --- a/includes/class-wp-members-email.php +++ b/includes/class-wp-members-email.php @@ -7,13 +7,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP_Members_Shortcodes * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/class-wp-members-shortcodes.php b/includes/class-wp-members-shortcodes.php index 1ed3ae1b..4c2ba618 100644 --- a/includes/class-wp-members-shortcodes.php +++ b/includes/class-wp-members-shortcodes.php @@ -7,13 +7,13 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @subpackage WP_Members_Shortcodes * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/deprecated.php b/includes/deprecated.php index 1bcf1f2a..a38b208e 100644 --- a/includes/deprecated.php +++ b/includes/deprecated.php @@ -8,12 +8,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/install.php b/includes/install.php index bb53af82..760df7ac 100644 --- a/includes/install.php +++ b/includes/install.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/legacy/dialogs.php b/includes/legacy/dialogs.php index d03855ab..5893cc45 100644 --- a/includes/legacy/dialogs.php +++ b/includes/legacy/dialogs.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/includes/vendor/rocketgeek-utilities/includes/arrays.php b/includes/vendor/rocketgeek-utilities/includes/arrays.php index 53fad0e7..df9dea78 100644 --- a/includes/vendor/rocketgeek-utilities/includes/arrays.php +++ b/includes/vendor/rocketgeek-utilities/includes/arrays.php @@ -12,10 +12,10 @@ * @link https://github.com/rocketgeek/rocketgeek-utilities/ * @author Chad Butler * @author RocketGeek - * @copyright Copyright (c) 2021 Chad Butler + * @copyright Copyright (c) 2022 Chad Butler * @license Apache-2.0 * - * Copyright [2021] Chad Butler, RocketGeek + * Copyright [2022] Chad Butler, RocketGeek * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/includes/vendor/rocketgeek-utilities/includes/dates.php b/includes/vendor/rocketgeek-utilities/includes/dates.php index f56c567b..6e5f15b4 100644 --- a/includes/vendor/rocketgeek-utilities/includes/dates.php +++ b/includes/vendor/rocketgeek-utilities/includes/dates.php @@ -12,10 +12,10 @@ * @link https://github.com/rocketgeek/rocketgeek-utilities/ * @author Chad Butler * @author RocketGeek - * @copyright Copyright (c) 2021 Chad Butler + * @copyright Copyright (c) 2022 Chad Butler * @license Apache-2.0 * - * Copyright [2021] Chad Butler, RocketGeek + * Copyright [2022] Chad Butler, RocketGeek * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/includes/vendor/rocketgeek-utilities/includes/debug.php b/includes/vendor/rocketgeek-utilities/includes/debug.php index a12033d4..16d3a518 100644 --- a/includes/vendor/rocketgeek-utilities/includes/debug.php +++ b/includes/vendor/rocketgeek-utilities/includes/debug.php @@ -12,10 +12,10 @@ * @link https://github.com/rocketgeek/rocketgeek-utilities/ * @author Chad Butler * @author RocketGeek - * @copyright Copyright (c) 2021 Chad Butler + * @copyright Copyright (c) 2022 Chad Butler * @license Apache-2.0 * - * Copyright [2021] Chad Butler, RocketGeek + * Copyright [2022] Chad Butler, RocketGeek * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/includes/vendor/rocketgeek-utilities/includes/forms.php b/includes/vendor/rocketgeek-utilities/includes/forms.php index 40bb35e6..7f18f77f 100644 --- a/includes/vendor/rocketgeek-utilities/includes/forms.php +++ b/includes/vendor/rocketgeek-utilities/includes/forms.php @@ -12,10 +12,10 @@ * @link https://github.com/rocketgeek/rocketgeek-utilities/ * @author Chad Butler * @author RocketGeek - * @copyright Copyright (c) 2021 Chad Butler + * @copyright Copyright (c) 2022 Chad Butler * @license Apache-2.0 * - * Copyright [2021] Chad Butler, RocketGeek + * Copyright [2022] Chad Butler, RocketGeek * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/includes/vendor/rocketgeek-utilities/includes/strings.php b/includes/vendor/rocketgeek-utilities/includes/strings.php index 0b8ae5b3..5350b85c 100644 --- a/includes/vendor/rocketgeek-utilities/includes/strings.php +++ b/includes/vendor/rocketgeek-utilities/includes/strings.php @@ -12,10 +12,10 @@ * @link https://github.com/rocketgeek/rocketgeek-utilities/ * @author Chad Butler * @author RocketGeek - * @copyright Copyright (c) 2021 Chad Butler + * @copyright Copyright (c) 2022 Chad Butler * @license Apache-2.0 * - * Copyright [2021] Chad Butler, RocketGeek + * Copyright [2022] Chad Butler, RocketGeek * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/includes/vendor/rocketgeek-utilities/includes/utilities.php b/includes/vendor/rocketgeek-utilities/includes/utilities.php index 667e60f7..4f290458 100644 --- a/includes/vendor/rocketgeek-utilities/includes/utilities.php +++ b/includes/vendor/rocketgeek-utilities/includes/utilities.php @@ -12,10 +12,10 @@ * @link https://github.com/rocketgeek/rocketgeek-utilities/ * @author Chad Butler * @author RocketGeek - * @copyright Copyright (c) 2021 Chad Butler + * @copyright Copyright (c) 2022 Chad Butler * @license Apache-2.0 * - * Copyright [2021] Chad Butler, RocketGeek + * Copyright [2022] Chad Butler, RocketGeek * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/includes/vendor/rocketgeek-utilities/loader.php b/includes/vendor/rocketgeek-utilities/loader.php index 3efe6355..1087eb62 100644 --- a/includes/vendor/rocketgeek-utilities/loader.php +++ b/includes/vendor/rocketgeek-utilities/loader.php @@ -14,10 +14,10 @@ * @link https://github.com/rocketgeek/rocketgeek-utilities/ * @author Chad Butler * @author RocketGeek - * @copyright Copyright (c) 2021 Chad Butler + * @copyright Copyright (c) 2022 Chad Butler * @license Apache-2.0 * - * Copyright [2021] Chad Butler, RocketGeek + * Copyright [2022] Chad Butler, RocketGeek * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/templates/tos.php b/templates/tos.php index c5705af6..4e7160f2 100644 --- a/templates/tos.php +++ b/templates/tos.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ ?> diff --git a/uninstall.php b/uninstall.php index f1d5a754..74984ab7 100644 --- a/uninstall.php +++ b/uninstall.php @@ -6,12 +6,12 @@ * * This file is part of the WP-Members plugin by Chad Butler * You can find out more about this plugin at https://rocketgeek.com - * Copyright (c) 2006-2021 Chad Butler + * Copyright (c) 2006-2022 Chad Butler * WP-Members(tm) is a trademark of butlerblog.com * * @package WP-Members * @author Chad Butler - * @copyright 2006-2021 + * @copyright 2006-2022 */ // Exit if accessed directly. diff --git a/wp-members.php b/wp-members.php index ce127cea..e5ab52d6 100644 --- a/wp-members.php +++ b/wp-members.php @@ -12,7 +12,7 @@ */ /* - Copyright (c) 2006-2021 Chad Butler + Copyright (c) 2006-2022 Chad Butler The name WP-Members(tm) is a trademark of butlerblog.com From 0349aaf8ba0d8aebe40366e42ef59d69f07613eb Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 Jan 2022 11:56:31 -0500 Subject: [PATCH 1563/1694] only apply pwd reset override on frontend (login error) --- includes/class-wp-members.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/includes/class-wp-members.php b/includes/class-wp-members.php index 1202bbac..8f26176f 100644 --- a/includes/class-wp-members.php +++ b/includes/class-wp-members.php @@ -523,8 +523,11 @@ function load_hooks() { add_filter( 'authenticate', array( $this->user, 'check_activated' ), 99, 3 ); } - // Replace login error object. - if ( 1 == $this->login_error ) { + // Replace login error object, if profile page is set, AND it is not the wp-login.php page. + if ( 1 == $this->login_error + && isset( $this->user_pages['profile'] ) + && '' != $this->user_pages['profile'] + && 'wp-login.php' !== $GLOBALS['pagenow'] ) { add_filter( 'lostpassword_url', array( $this, 'lost_pwd_url' ), 10, 2 ); } From eeaf7c0d1e3222cb35e1fad978be15e50eb085ce Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 Jan 2022 12:03:40 -0500 Subject: [PATCH 1564/1694] add index.php --- includes/vendor/rocketgeek-utilities/includes/index.php | 1 + includes/vendor/rocketgeek-utilities/index.php | 1 + 2 files changed, 2 insertions(+) create mode 100644 includes/vendor/rocketgeek-utilities/includes/index.php create mode 100644 includes/vendor/rocketgeek-utilities/index.php diff --git a/includes/vendor/rocketgeek-utilities/includes/index.php b/includes/vendor/rocketgeek-utilities/includes/index.php new file mode 100644 index 00000000..6c40915e --- /dev/null +++ b/includes/vendor/rocketgeek-utilities/includes/index.php @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/includes/vendor/rocketgeek-utilities/index.php b/includes/vendor/rocketgeek-utilities/index.php new file mode 100644 index 00000000..6c40915e --- /dev/null +++ b/includes/vendor/rocketgeek-utilities/index.php @@ -0,0 +1 @@ + \ No newline at end of file From 86cf3e2ec8ecc1c6a22ec0e52a96dda79f8c83ac Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Mon, 10 Jan 2022 12:06:40 -0500 Subject: [PATCH 1565/1694] add index.php --- admin/index.php | 1 + assets/index.php | 1 + inc/index.php | 1 + includes/cli/index.php | 1 + 4 files changed, 4 insertions(+) create mode 100644 admin/index.php create mode 100644 assets/index.php create mode 100644 inc/index.php create mode 100644 includes/cli/index.php diff --git a/admin/index.php b/admin/index.php new file mode 100644 index 00000000..dc051a13 --- /dev/null +++ b/admin/index.php @@ -0,0 +1 @@ + Date: Tue, 11 Jan 2022 17:34:53 -0500 Subject: [PATCH 1566/1694] css fix for checkboxes on add new user screen --- assets/css/admin.css | 1 + assets/css/admin.min.css | 2 +- includes/admin/class-wp-members-admin-api.php | 5 +++-- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/assets/css/admin.css b/assets/css/admin.css index 653467e2..d86a052e 100644 --- a/assets/css/admin.css +++ b/assets/css/admin.css @@ -132,6 +132,7 @@ updatesettings a:hover { color: black; } +#adduser .form-field input[type="checkbox"], #createuser .form-field input[type="checkbox"] { width: initial; } diff --git a/assets/css/admin.min.css b/assets/css/admin.min.css index dfd8132d..b5ee909d 100644 --- a/assets/css/admin.min.css +++ b/assets/css/admin.min.css @@ -1 +1 @@ -.wpmem_tbl_drag{background:#fffbcc;font-weight:700;border:1px solid #900}.column-wpmem_block{width:80px}#addfieldform li,#editfieldform li,#updatesettings li{padding:5px 0}#addfieldform label,#editfieldform label,#updatesettings label{float:left;width:166px;clear:both;display:block}#addfieldform .add-field-indent,#editfieldform .add-field-indent{margin-left:165px}#add_field_postbox,#fields_postbox{min-width:950px}.req{color:red}.settings_page_wpmem-settings #the-list{cursor:move}#edit,#sort{width:30px}#wpmem_block input{vertical-align:-webkit-baseline-middle;margin:0 0 8px 0}#wpmem_block label{margin:0 0 0 8px}#wpmem_ok_block_status{margin:5px 0 0 0}#wpmem_post_block_status{font-weight:600}#wpmem_post_icon_0{color:red}#wpmem_post_icon_1{color:green}#wpmem_post_icon_2{color:#000}#wpmem_product_enabled{color:green}#_wpmem_products,#s2id__wpmem_products,.select2-search-field{width:100%}#wpmem_user_profile_tabs{padding:0;background:0 0;border-width:0}#wpmem_user_profile_tabs .ui-tabs-nav{padding-left:0;background:0 0;border-width:0 0 1px 0;-moz-border-radius:0;-webkit-border-radius:0;border-radius:0}#wpmem_user_profile_tabs .ui-tabs-panel{background:#fff;border-width:0 1px 1px 1px}#wpmem_user_profile_tabs .ui-state-active{border:1px solid #006799;background:#008ec2}#wpmem_user_profile_tabs .ui-state-active a{color:#fff}#wpmem_product_fixed_period,#wpmem_product_fixed_period_select input,#wpmem_product_fixed_period_select label,#wpmem_product_no_gap{margin-top:10px;margin-left:24px}#updatesettings a{text-decoration:none}updatesettings a:hover{color:#000}#createuser .form-field input[type="checkbox"]{width: initial;}.wpmem-user-table-membership {border-bottom:1px solid #999;} \ No newline at end of file +.wpmem_tbl_drag{background:#fffbcc;font-weight:700;border:1px solid #900}.column-wpmem_block{width:80px}#addfieldform li,#editfieldform li,#updatesettings li{padding:5px 0}#addfieldform label,#editfieldform label,#updatesettings label{float:left;width:166px;clear:both;display:block}#addfieldform .add-field-indent,#editfieldform .add-field-indent{margin-left:165px}#add_field_postbox,#fields_postbox{min-width:950px}.req{color:red}.settings_page_wpmem-settings #the-list{cursor:move}#edit,#sort{width:30px}#wpmem_block input{vertical-align:-webkit-baseline-middle;margin:0 0 8px 0}#wpmem_block label{margin:0 0 0 8px}#wpmem_ok_block_status{margin:5px 0 0 0}#wpmem_post_block_status{font-weight:600}#wpmem_post_icon_0{color:red}#wpmem_post_icon_1{color:green}#wpmem_post_icon_2{color:#000}#wpmem_product_enabled{color:green}#_wpmem_products,#s2id__wpmem_products,.select2-search-field{width:100%}#wpmem_user_profile_tabs{padding:0;background:0 0;border-width:0}#wpmem_user_profile_tabs .ui-tabs-nav{padding-left:0;background:0 0;border-width:0 0 1px 0;-moz-border-radius:0;-webkit-border-radius:0px;border-radius:0}#wpmem_user_profile_tabs .ui-tabs-panel{background:#fff;border-width:0 1px 1px 1px}#wpmem_user_profile_tabs .ui-state-active{border:1px solid #006799;background:#135e96}#wpmem_user_profile_tabs .ui-state-active a{color:#fff}#wpmem_product_fixed_period,#wpmem_product_fixed_period_select input,#wpmem_product_fixed_period_select label,#wpmem_product_no_gap{margin-top:10px;margin-left:24px}#updatesettings a{text-decoration:none}updatesettings a:hover{color:#000}#adduser .form-field input[type=checkbox],#createuser .form-field input[type=checkbox]{width:initial}.wpmem-user-table-membership{border-bottom:1px solid #999} \ No newline at end of file diff --git a/includes/admin/class-wp-members-admin-api.php b/includes/admin/class-wp-members-admin-api.php index 13daf98b..5b0371f1 100644 --- a/includes/admin/class-wp-members-admin-api.php +++ b/includes/admin/class-wp-members-admin-api.php @@ -533,8 +533,9 @@ function dashboard_enqueue_scripts( $hook ) { global $current_screen; if ( 'edit.php' == $hook || 'post.php' == $hook - || 'post-new.php' == $hook - || 'user-edit.php' == $hook + || 'post-new.php' == $hook + || 'user-new.php' == $hook + || 'user-edit.php' == $hook || 'profile.php' == $hook || 'users.php' == $hook || 'settings_page_wpmem-settings' == $hook ) { From 540f03d04b515c5a8f63813cf0d0ae10492af08a Mon Sep 17 00:00:00 2001 From: RocketGeek Date: Tue, 11 Jan 2022 17:36:05 -0500 Subject: [PATCH 1567/1694] added wpmem_recaptcha_url filter --- includes/class-wp-members-captcha.php | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/includes/class-wp-members-captcha.php b/includes/class-wp-members-captcha.php index 4476fd06..faeda6d4 100644 --- a/includes/class-wp-members-captcha.php +++ b/includes/class-wp-members-captcha.php @@ -101,17 +101,27 @@ static function hcaptcha( $key = false ) { */ static function recaptcha( $key = false ) { + global $wpmem; + if ( false == $key ) { $opts = get_option( 'wpmembers_captcha' ); $key = $opts['recaptcha']['public']; } - global $wpmem; + /** + * Filters the URL used for google recaptcha API. + * + * @since 3.4.2 + * + * @param string $url + */ + $wpmem_recaptcha_url = apply_filters( 'wpmem_recaptcha_url', 'https://www.google.com/recaptcha/api.js' ); + if ( 3 == $wpmem->captcha ) { - $html = ' + $html = '

    '; } else { - $html = ''; + $html = ''; $html.= "
  • ' . __( 'Status', 'wp-members' ) . '' . __( 'Action', 'wp-members' ) . ' ' . __( 'Membership', 'wp-members' ) . ' ' . __( 'Enabled?', 'wp-members' ) . '' . __( 'Expires', 'wp-members' ) . '' . $expires_heading . '
    ' . $value['title'] . '