Version Description
Download this release
Release Info
| Developer | ultimatemember |
| Plugin | |
| Version | 1.0.23 |
| Comparing to | |
| See all releases | |
Code changes from version 1.0.22 to 1.0.23
- core/um-actions-form.php +10 -4
- core/um-fields.php +5 -4
- index.php +1 -1
- readme.txt +5 -1
- um-config.php +1 -1
core/um-actions-form.php
CHANGED
|
@@ -77,9 +77,11 @@
|
|
| 77 |
|
| 78 |
$words = array_map("rtrim", explode("\n", $words));
|
| 79 |
foreach( $fields as $key => $array ) {
|
| 80 |
-
if ( isset($
|
| 81 |
-
if (
|
| 82 |
-
|
|
|
|
|
|
|
| 83 |
}
|
| 84 |
}
|
| 85 |
}
|
|
@@ -136,7 +138,9 @@
|
|
| 136 |
$fields = unserialize( $args['custom_fields'] );
|
| 137 |
|
| 138 |
foreach( $fields as $key => $array ) {
|
| 139 |
-
|
|
|
|
|
|
|
| 140 |
if ( isset( $array['required'] ) && $array['required'] == 1 ) {
|
| 141 |
if ( !isset($args[$key]) || $args[$key] == '' ) {
|
| 142 |
$ultimatemember->form->add_error($key, sprintf(__('%s is required'), $array['label']) );
|
|
@@ -295,4 +299,6 @@
|
|
| 295 |
}
|
| 296 |
}
|
| 297 |
|
|
|
|
|
|
|
| 298 |
}
|
| 77 |
|
| 78 |
$words = array_map("rtrim", explode("\n", $words));
|
| 79 |
foreach( $fields as $key => $array ) {
|
| 80 |
+
if ( isset( $args[$key] ) ) {
|
| 81 |
+
if ( isset($array['validate']) && in_array( $array['validate'], array('unique_username','unique_email','unique_username_or_email') ) ) {
|
| 82 |
+
if ( preg_grep( "/".$args[$key]."/i" , $words ) ) {
|
| 83 |
+
$ultimatemember->form->add_error( $key, __('You are not allowed to use this word as your username.') );
|
| 84 |
+
}
|
| 85 |
}
|
| 86 |
}
|
| 87 |
}
|
| 138 |
$fields = unserialize( $args['custom_fields'] );
|
| 139 |
|
| 140 |
foreach( $fields as $key => $array ) {
|
| 141 |
+
|
| 142 |
+
if ( isset( $args[$key] ) ) {
|
| 143 |
+
|
| 144 |
if ( isset( $array['required'] ) && $array['required'] == 1 ) {
|
| 145 |
if ( !isset($args[$key]) || $args[$key] == '' ) {
|
| 146 |
$ultimatemember->form->add_error($key, sprintf(__('%s is required'), $array['label']) );
|
| 299 |
}
|
| 300 |
}
|
| 301 |
|
| 302 |
+
} // end if ( isset in args array )
|
| 303 |
+
|
| 304 |
}
|
core/um-fields.php
CHANGED
|
@@ -547,10 +547,6 @@ class UM_Fields {
|
|
| 547 |
$array['disabled'] = 'disabled="disabled"';
|
| 548 |
}
|
| 549 |
|
| 550 |
-
if ( $key == 'user_login' && $this->set_mode == 'profile' && $this->editing == true ) {
|
| 551 |
-
$array['disabled'] = 'disabled="disabled"';
|
| 552 |
-
}
|
| 553 |
-
|
| 554 |
$array['input'] = 'text';
|
| 555 |
|
| 556 |
if (!isset($array['autocomplete'])) $array['autocomplete'] = 'on';
|
|
@@ -819,6 +815,11 @@ class UM_Fields {
|
|
| 819 |
if ( !um_can_view_field( $data ) ) return;
|
| 820 |
if ( !um_can_edit_field( $data ) ) return;
|
| 821 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 822 |
if ( isset( $data['required_opt'] ) ) {
|
| 823 |
$opt = $data['required_opt'];
|
| 824 |
if ( um_get_option( $opt[0] ) != $opt[1] ) {
|
| 547 |
$array['disabled'] = 'disabled="disabled"';
|
| 548 |
}
|
| 549 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 550 |
$array['input'] = 'text';
|
| 551 |
|
| 552 |
if (!isset($array['autocomplete'])) $array['autocomplete'] = 'on';
|
| 815 |
if ( !um_can_view_field( $data ) ) return;
|
| 816 |
if ( !um_can_edit_field( $data ) ) return;
|
| 817 |
|
| 818 |
+
// disable these fields in profile edit only
|
| 819 |
+
if ( in_array( $key, array('user_email','username','user_login') ) && $this->editing == true && $this->set_mode == 'profile' ) {
|
| 820 |
+
return;
|
| 821 |
+
}
|
| 822 |
+
|
| 823 |
if ( isset( $data['required_opt'] ) ) {
|
| 824 |
$opt = $data['required_opt'];
|
| 825 |
if ( um_get_option( $opt[0] ) != $opt[1] ) {
|
index.php
CHANGED
|
@@ -3,7 +3,7 @@
|
|
| 3 |
Plugin Name: Ultimate Member
|
| 4 |
Plugin URI: http://ultimatemember.com/
|
| 5 |
Description: Ultimate Member is a powerful community and membership plugin that allows you to create beautiful community and membership sites with WordPress
|
| 6 |
-
Version: 1.0.
|
| 7 |
Author: Ultimate Member
|
| 8 |
Author URI: http://ultimatemember.com/
|
| 9 |
*/
|
| 3 |
Plugin Name: Ultimate Member
|
| 4 |
Plugin URI: http://ultimatemember.com/
|
| 5 |
Description: Ultimate Member is a powerful community and membership plugin that allows you to create beautiful community and membership sites with WordPress
|
| 6 |
+
Version: 1.0.23
|
| 7 |
Author: Ultimate Member
|
| 8 |
Author URI: http://ultimatemember.com/
|
| 9 |
*/
|
readme.txt
CHANGED
|
@@ -7,7 +7,7 @@ Tags: access control, community, communities, conditional fields, conditional lo
|
|
| 7 |
Requires at least: 4.1
|
| 8 |
Tested up to: 4.1
|
| 9 |
|
| 10 |
-
Stable Tag: 1.0.
|
| 11 |
|
| 12 |
License: GNU Version 2 or Any Later Version
|
| 13 |
|
|
@@ -168,6 +168,10 @@ Yes. The plugin works fine with WordPress network / multisite now. In a recent u
|
|
| 168 |
|
| 169 |
== Changelog ==
|
| 170 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 171 |
= 1.0.22: January 25, 2015 =
|
| 172 |
|
| 173 |
* New: option to set maximum profile fields area width
|
| 7 |
Requires at least: 4.1
|
| 8 |
Tested up to: 4.1
|
| 9 |
|
| 10 |
+
Stable Tag: 1.0.23
|
| 11 |
|
| 12 |
License: GNU Version 2 or Any Later Version
|
| 13 |
|
| 168 |
|
| 169 |
== Changelog ==
|
| 170 |
|
| 171 |
+
= 1.0.23: January 25, 2015 =
|
| 172 |
+
|
| 173 |
+
* Fixed: important bugfix with profile editing
|
| 174 |
+
|
| 175 |
= 1.0.22: January 25, 2015 =
|
| 176 |
|
| 177 |
* New: option to set maximum profile fields area width
|
um-config.php
CHANGED
|
@@ -761,7 +761,7 @@ $this->sections[] = array(
|
|
| 761 |
'id' => 'image_compression',
|
| 762 |
'type' => 'text',
|
| 763 |
'title' => __( 'Image Quality' ),
|
| 764 |
-
'desc' => __( 'Quality is used to determine quality of image uploads, and ranges from 0 (worst quality, smaller file) to 100 (best quality, biggest file). The default range is
|
| 765 |
'default' => 60,
|
| 766 |
'validate' => 'numeric',
|
| 767 |
),
|
| 761 |
'id' => 'image_compression',
|
| 762 |
'type' => 'text',
|
| 763 |
'title' => __( 'Image Quality' ),
|
| 764 |
+
'desc' => __( 'Quality is used to determine quality of image uploads, and ranges from 0 (worst quality, smaller file) to 100 (best quality, biggest file). The default range is 60.' ),
|
| 765 |
'default' => 60,
|
| 766 |
'validate' => 'numeric',
|
| 767 |
),
|
