diff --git a/README.md b/README.md
index f29f8ff0..95c67922 100644
--- a/README.md
+++ b/README.md
@@ -42,7 +42,7 @@ GNU Version 2 or Any Later Version
## Releases
-[Official Release Version: 2.6.5](https://github.com/ultimatemember/ultimatemember/releases/tag/2.6.5).
+[Official Release Version: 2.6.6](https://github.com/ultimatemember/ultimatemember/releases/tag/2.6.6).
## Changelog
diff --git a/includes/admin/core/class-admin-builder.php b/includes/admin/core/class-admin-builder.php
index 73cdf064..265771e4 100644
--- a/includes/admin/core/class-admin-builder.php
+++ b/includes/admin/core/class-admin-builder.php
@@ -915,11 +915,13 @@ if ( ! class_exists( 'um\admin\core\Admin_Builder' ) ) {
get_atts( $key, $classes, $conditional, $data ) . '>';
diff --git a/includes/core/um-actions-form.php b/includes/core/um-actions-form.php
index e8eea188..25c2a3e2 100644
--- a/includes/core/um-actions-form.php
+++ b/includes/core/um-actions-form.php
@@ -633,18 +633,22 @@ function um_submit_form_errors_hook_( $args ) {
}
}
- if ( isset( $array['force_confirm_pass'] ) && $array['force_confirm_pass'] == 1 ) {
- if ( $args[ 'confirm_' . $key ] == '' && ! UM()->form()->has_error( $key ) ) {
- UM()->form()->add_error( 'confirm_' . $key , __( 'Please confirm your password', 'ultimate-member' ) );
- }
- if ( $args[ 'confirm_' . $key ] != $args[$key] && !UM()->form()->has_error( $key ) ) {
- UM()->form()->add_error( 'confirm_' . $key , __( 'Your passwords do not match', 'ultimate-member' ) );
+ if ( ! empty( $array['force_confirm_pass'] ) ) {
+ if ( ! array_key_exists( 'confirm_' . $key, $args ) && ! UM()->form()->has_error( $key ) ) {
+ UM()->form()->add_error( 'confirm_' . $key, __( 'Please confirm your password', 'ultimate-member' ) );
+ } else {
+ if ( '' === $args[ 'confirm_' . $key ] && ! UM()->form()->has_error( $key ) ) {
+ UM()->form()->add_error( 'confirm_' . $key, __( 'Please confirm your password', 'ultimate-member' ) );
+ }
+ if ( $args[ 'confirm_' . $key ] !== $args[ $key ] && ! UM()->form()->has_error( $key ) ) {
+ UM()->form()->add_error( 'confirm_' . $key, __( 'Your passwords do not match', 'ultimate-member' ) );
+ }
}
}
if ( isset( $array['min_selections'] ) && $array['min_selections'] > 0 ) {
if ( ( ! isset( $args[ $key ] ) ) || ( isset( $args[ $key ] ) && is_array( $args[ $key ] ) && count( $args[ $key ] ) < $array['min_selections'] ) ) {
- UM()->form()->add_error($key, sprintf( __( 'Please select at least %s choices', 'ultimate-member' ), $array['min_selections'] ) );
+ UM()->form()->add_error( $key, sprintf( __( 'Please select at least %s choices', 'ultimate-member' ), $array['min_selections'] ) );
}
}
diff --git a/includes/core/um-actions-profile.php b/includes/core/um-actions-profile.php
index 4a4b10d2..5d3328c5 100644
--- a/includes/core/um-actions-profile.php
+++ b/includes/core/um-actions-profile.php
@@ -1691,7 +1691,7 @@ function um_profile_menu( $args ) {
$tab ) {
- $nav_link = UM()->permalinks()->get_current_url( get_option( 'permalink_structure' ) );
+ $nav_link = UM()->permalinks()->get_current_url( UM()->is_permalinks );
$nav_link = remove_query_arg( 'um_action', $nav_link );
$nav_link = remove_query_arg( 'subnav', $nav_link );
$nav_link = add_query_arg( 'profiletab', $id, $nav_link );
diff --git a/includes/core/um-filters-fields.php b/includes/core/um-filters-fields.php
index a64ec2ad..2bf8bb6d 100644
--- a/includes/core/um-filters-fields.php
+++ b/includes/core/um-filters-fields.php
@@ -87,11 +87,15 @@ add_filter( 'um_profile_field_filter_hook__youtube_video', 'um_profile_field_fil
*/
function um_profile_field_filter_hook__spotify( $value, $data ) {
if ( preg_match( '/https:\/\/open.spotify.com\/.*/', $value ) ) {
- $url = str_replace( 'open.spotify.com/', 'open.spotify.com/embed/', $value );
+ if ( false !== strpos( $value, '/user/' ) ) {
+ $value = '
' . esc_html( $value ) . '';
+ } else {
+ $url = str_replace( 'open.spotify.com/', 'open.spotify.com/embed/', $value );
- $value = '
+ $value = '
';
+ }
} else {
return __( 'Invalid Spotify URL', 'ultimate-member' );
}
@@ -439,7 +443,7 @@ function um_profile_field_filter_hook__( $value, $data, $type = '' ) {
$value = '
' . esc_html( $alt ) . '';
} else {
- if ( ( isset( $data['validate'] ) && $data['validate'] !== '' && strstr( $data['validate'], 'url' ) ) || ( isset( $data['type'] ) && $data['type'] == 'url' ) ) {
+ if ( ( isset( $data['validate'] ) && $data['validate'] !== '' && $data['type'] !== 'spotify' && strstr( $data['validate'], 'url' ) ) || ( isset( $data['type'] ) && $data['type'] == 'url' ) ) {
$alt = ( isset( $data['url_text'] ) && !empty( $data['url_text'] ) ) ? $data['url_text'] : $value;
$url_rel = ( isset( $data['url_rel'] ) && $data['url_rel'] == 'nofollow' ) ? 'rel="nofollow"' : '';
if ( ! strstr( $value, 'http' )
@@ -460,6 +464,7 @@ function um_profile_field_filter_hook__( $value, $data, $type = '' ) {
if ( $data['validate'] == 'tiktok_url' ) $value = 'https://tiktok.com/' . $value;
if ( $data['validate'] == 'twitch_url' ) $value = 'https://twitch.tv/' . $value;
if ( $data['validate'] == 'reddit_url' ) $value = 'https://www.reddit.com/user/' . $value;
+ if ( $data['validate'] == 'spotify_url' ) $value = 'https://open.spotify.com/' . $value;
}
if ( strpos( $value, 'http://' ) !== 0 ) {
diff --git a/readme.txt b/readme.txt
index cf58145f..06f8c613 100644
--- a/readme.txt
+++ b/readme.txt
@@ -7,7 +7,7 @@ Tags: community, member, membership, user-profile, user-registration
Requires PHP: 5.6
Requires at least: 5.5
Tested up to: 6.2
-Stable tag: 2.6.5
+Stable tag: 2.6.6
License: GNU Version 2 or Any Later Version
License URI: http://www.gnu.org/licenses/gpl-3.0.txt
@@ -163,6 +163,15 @@ No, you do not need to use our plugin’s login or registration pages and can us
* To learn more about version 2.1 please see this [docs](https://docs.ultimatemember.com/article/1512-upgrade-2-1-0)
* UM2.1+ is a significant update to the Member Directories' code base from 2.0.x. Please make sure you take a full-site backup with restore point before updating the plugin
+= 2.6.6: June 29, 2023 =
+
+* Bugfixes:
+
+ - Fixed: Password Confirm field and validation
+ - Fixed: Form Builder row editing
+ - Fixed: Spotify URL user URL display on user profile
+ - Fixed: Spotify URL validation
+
= 2.6.5: June 28, 2023 =
* Enhancements:
diff --git a/ultimate-member.php b/ultimate-member.php
index cb9a6c58..11466c42 100644
--- a/ultimate-member.php
+++ b/ultimate-member.php
@@ -3,7 +3,7 @@
Plugin Name: Ultimate Member
Plugin URI: http://ultimatemember.com/
Description: The easiest way to create powerful online communities and beautiful user profiles with WordPress
-Version: 2.6.5
+Version: 2.6.6
Author: Ultimate Member
Author URI: http://ultimatemember.com/
Text Domain: ultimate-member