Ultimate Member – User Profile & Membership Plugin - Version 2.0.33

Version Description

Download this release

Release Info

Developer nsinelnikov
Plugin Icon 128x128 Ultimate Member – User Profile & Membership Plugin
Version 2.0.33
Comparing to
See all releases

Code changes from version 2.0.32 to 2.0.33

Files changed (45) hide show
  1. assets/js/um-modal.js +6 -3
  2. assets/js/um-modal.min.js +1 -1
  3. assets/js/um-profile.js +4 -2
  4. assets/js/um-profile.min.js +1 -1
  5. assets/js/um-scripts.js +12 -6
  6. assets/js/um-scripts.min.js +1 -1
  7. includes/admin/assets/js/um-admin-ajax.js +11 -1
  8. includes/admin/assets/js/um-admin-builder.js +2 -1
  9. includes/admin/assets/js/um-admin-field.js +7 -1
  10. includes/admin/assets/js/um-admin-modal.js +17 -2
  11. includes/admin/class-admin-functions.php +15 -0
  12. includes/admin/core/class-admin-builder.php +16 -9
  13. includes/admin/core/class-admin-dragdrop.php +7 -4
  14. includes/admin/core/class-admin-enqueue.php +2 -3
  15. includes/admin/core/class-admin-menu.php +11 -3
  16. includes/admin/core/class-admin-notices.php +1 -5
  17. includes/admin/core/class-admin-upgrade.php +8 -2
  18. includes/admin/core/packages/1.3.39/functions.php +2 -0
  19. includes/admin/core/packages/1.3.39/init.php +3 -2
  20. includes/admin/core/packages/2.0-beta1/functions.php +31 -0
  21. includes/admin/core/packages/2.0-beta1/init.php +45 -30
  22. includes/admin/core/packages/2.0.10/functions.php +4 -0
  23. includes/admin/core/packages/2.0.10/init.php +6 -4
  24. includes/admin/core/packages/2.0.24/functions.php +2 -0
  25. includes/admin/core/packages/2.0.24/init.php +3 -2
  26. includes/admin/templates/dashboard/language-contrib.php +0 -7
  27. includes/admin/templates/modal/dynamic_edit_field.php +1 -0
  28. includes/admin/templates/modal/dynamic_edit_row.php +1 -0
  29. includes/admin/templates/modal/dynamic_new_divider.php +1 -0
  30. includes/admin/templates/modal/dynamic_new_field.php +1 -0
  31. includes/admin/templates/modal/dynamic_new_group.php +1 -0
  32. includes/class-functions.php +15 -0
  33. includes/core/class-enqueue.php +3 -1
  34. includes/core/class-fields.php +7 -3
  35. includes/core/class-files.php +4 -0
  36. includes/core/class-form.php +3 -1
  37. includes/core/class-profile.php +5 -1
  38. includes/core/class-query.php +2 -0
  39. includes/core/class-user-posts.php +2 -0
  40. includes/core/class-user.php +7 -2
  41. includes/core/um-actions-ajax.php +2 -0
  42. languages/ultimate-member-en_US.mo +0 -0
  43. languages/ultimate-member-en_US.po +109 -118
  44. readme.txt +8 -1
  45. ultimate-member.php +1 -1
assets/js/um-modal.js CHANGED
@@ -34,7 +34,8 @@ jQuery(document).ready(function() {
34
type: 'post',
35
data: {
36
action: 'um_remove_file',
37
- src: src
38
}
39
});
40
@@ -64,7 +65,8 @@ jQuery(document).ready(function() {
64
type: 'post',
65
data: {
66
action: 'um_remove_file',
67
- src: src
68
}
69
});
70
@@ -115,7 +117,8 @@ jQuery(document).ready(function() {
115
src : src,
116
coord : coord,
117
user_id : user_id,
118
- key: key
119
},
120
success: function( response ){
121
34
type: 'post',
35
data: {
36
action: 'um_remove_file',
37
+ src: src,
38
+ nonce: um_scripts.nonce
39
}
40
});
41
65
type: 'post',
66
data: {
67
action: 'um_remove_file',
68
+ src: src,
69
+ nonce: um_scripts.nonce
70
}
71
});
72
117
src : src,
118
coord : coord,
119
user_id : user_id,
120
+ key: key,
121
+ nonce: um_scripts.nonce
122
},
123
success: function( response ){
124
assets/js/um-modal.min.js CHANGED
@@ -1 +1 @@
1
- jQuery(document).ready(function(){jQuery(document).on("click",".um-popup-overlay",function(){remove_Modal()}),jQuery(document).on("click",'.um-modal-overlay, a[data-action="um_remove_modal"]',function(){um_remove_modal()}),jQuery(document).on("click",'a[data-modal^="um_"], span[data-modal^="um_"], .um-modal a',function(e){return e.preventDefault(),!1}),jQuery(document).on("click",".um-modal .um-single-file-preview a.cancel",function(e){e.preventDefault();var a=jQuery(this).parents(".um-modal-body"),t=jQuery(this).parents(".um-modal-body").find(".um-single-fileinfo a").attr("href");return a.find(".um-single-file-preview").hide(),a.find(".ajax-upload-dragdrop").show(),a.find(".um-modal-btn.um-finish-upload").addClass("disabled"),um_modal_responsive(),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_remove_file",src:t}}),!1}),jQuery(document).on("click",".um-modal .um-single-image-preview a.cancel",function(e){e.preventDefault();var a=jQuery(this).parents(".um-modal-body"),t=jQuery(this).parents(".um-modal-body").find(".um-single-image-preview img").attr("src");return jQuery("img.cropper-hidden").cropper("destroy"),a.find(".um-single-image-preview img").attr("src",""),a.find(".um-single-image-preview").hide(),a.find(".ajax-upload-dragdrop").show(),a.find(".um-modal-btn.um-finish-upload").addClass("disabled"),um_modal_responsive(),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_remove_file",src:t}}),!1}),jQuery(document).on("click",".um-finish-upload.file:not(.disabled)",function(){var e=jQuery(this).attr("data-key"),a=jQuery(this).parents(".um-modal-body").find(".um-single-file-preview").html();um_remove_modal(),jQuery(".um-single-file-preview[data-key="+e+"]").fadeIn().html(a);var t=jQuery(".um-field[data-key="+e+"]").find(".um-single-fileinfo a").data("file");jQuery(".um-single-file-preview[data-key="+e+"]").parents(".um-field").find(".um-btn-auto-width").html(jQuery(this).attr("data-change")),jQuery(".um-single-file-preview[data-key="+e+"]").parents(".um-field").find('input[type="hidden"]').val(t)}),jQuery(document).on("click",".um-finish-upload.image:not(.disabled)",function(){var a=jQuery(this),t=jQuery(this).attr("data-key"),e=jQuery(this).parents(".um-modal-body").find(".um-single-image-preview"),i=e.find("img").attr("src"),r=e.attr("data-coord"),u=e.find("img").data("file"),m=0;jQuery(this).parents("#um_upload_single").data("user_id")&&(m=jQuery(this).parents("#um_upload_single").data("user_id")),r?(jQuery(this).html(jQuery(this).attr("data-processing")).addClass("disabled"),jQuery.ajax({url:wp.ajax.settings.url,type:"POST",dataType:"json",data:{action:"um_resize_image",src:i,coord:r,user_id:m,key:t},success:function(e){1==e.success&&(d=new Date,"profile_photo"==t&&jQuery(".um-profile-photo-img img").attr("src",e.data.image.source_url+"?"+d.getTime()),"cover_photo"==t&&(jQuery(".um-cover-e").empty().html('<img src="'+e.data.image.source_url+"?"+d.getTime()+'" alt="" />'),jQuery(".um").hasClass("um-editing")&&jQuery(".um-cover-overlay").show()),jQuery(".um-single-image-preview[data-key="+t+"]").fadeIn().find("img").attr("src",e.data.image.source_url+"?"+d.getTime()),um_remove_modal(),jQuery(".um-single-image-preview[data-key="+t+"]").parents(".um-field").find(".um-btn-auto-width").html(a.attr("data-change")),jQuery(".um-single-image-preview[data-key="+t+"]").parents(".um-field").find('input[type="hidden"]').val(e.data.image.filename))}})):(d=new Date,jQuery(".um-single-image-preview[data-key="+t+"]").fadeIn().find("img").attr("src",i+"?"+d.getTime()),um_remove_modal(),jQuery(".um-single-image-preview[data-key="+t+"]").parents(".um-field").find(".um-btn-auto-width").html(a.attr("data-change")),jQuery(".um-single-image-preview[data-key="+t+"]").parents(".um-field").find("input[type=hidden]").val(u))}),jQuery(document).on("click",'a[data-modal^="um_"], span[data-modal^="um_"]',function(e){var a=jQuery(this).attr("data-modal"),t="normal";if(jQuery(this).data("modal-size"))t=jQuery(this).data("modal-size");jQuery(this).data("modal-copy")&&(jQuery("#"+a).html(jQuery(this).parents(".um-field").find(".um-modal-hidden-content").html()),jQuery(this).parents(".um-profile-photo").attr("data-user_id")&&jQuery("#"+a).attr("data-user_id",jQuery(this).parents(".um-profile-photo").attr("data-user_id")),jQuery(this).parents(".um-cover").attr("data-ratio")&&jQuery("#"+a).attr("data-ratio",jQuery(this).parents(".um-cover").attr("data-ratio")),jQuery(this).parents(".um-cover").attr("data-user_id")&&jQuery("#"+a).attr("data-user_id",jQuery(this).parents(".um-cover").attr("data-user_id")),0<jQuery("input[type=hidden][name='user_id']").length&&jQuery("#"+a).attr("data-user_id",jQuery("input[type=hidden][name='user_id']").val())),um_new_modal(a,t)})});
1
+ jQuery(document).ready(function(){jQuery(document).on("click",".um-popup-overlay",function(){remove_Modal()}),jQuery(document).on("click",'.um-modal-overlay, a[data-action="um_remove_modal"]',function(){um_remove_modal()}),jQuery(document).on("click",'a[data-modal^="um_"], span[data-modal^="um_"], .um-modal a',function(e){return e.preventDefault(),!1}),jQuery(document).on("click",".um-modal .um-single-file-preview a.cancel",function(e){e.preventDefault();var a=jQuery(this).parents(".um-modal-body"),t=jQuery(this).parents(".um-modal-body").find(".um-single-fileinfo a").attr("href");return a.find(".um-single-file-preview").hide(),a.find(".ajax-upload-dragdrop").show(),a.find(".um-modal-btn.um-finish-upload").addClass("disabled"),um_modal_responsive(),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_remove_file",src:t,nonce:um_scripts.nonce}}),!1}),jQuery(document).on("click",".um-modal .um-single-image-preview a.cancel",function(e){e.preventDefault();var a=jQuery(this).parents(".um-modal-body"),t=jQuery(this).parents(".um-modal-body").find(".um-single-image-preview img").attr("src");return jQuery("img.cropper-hidden").cropper("destroy"),a.find(".um-single-image-preview img").attr("src",""),a.find(".um-single-image-preview").hide(),a.find(".ajax-upload-dragdrop").show(),a.find(".um-modal-btn.um-finish-upload").addClass("disabled"),um_modal_responsive(),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_remove_file",src:t,nonce:um_scripts.nonce}}),!1}),jQuery(document).on("click",".um-finish-upload.file:not(.disabled)",function(){var e=jQuery(this).attr("data-key"),a=jQuery(this).parents(".um-modal-body").find(".um-single-file-preview").html();um_remove_modal(),jQuery(".um-single-file-preview[data-key="+e+"]").fadeIn().html(a);var t=jQuery(".um-field[data-key="+e+"]").find(".um-single-fileinfo a").data("file");jQuery(".um-single-file-preview[data-key="+e+"]").parents(".um-field").find(".um-btn-auto-width").html(jQuery(this).attr("data-change")),jQuery(".um-single-file-preview[data-key="+e+"]").parents(".um-field").find('input[type="hidden"]').val(t)}),jQuery(document).on("click",".um-finish-upload.image:not(.disabled)",function(){var a=jQuery(this),t=jQuery(this).attr("data-key"),e=jQuery(this).parents(".um-modal-body").find(".um-single-image-preview"),i=e.find("img").attr("src"),r=e.attr("data-coord"),u=e.find("img").data("file"),n=0;jQuery(this).parents("#um_upload_single").data("user_id")&&(n=jQuery(this).parents("#um_upload_single").data("user_id")),r?(jQuery(this).html(jQuery(this).attr("data-processing")).addClass("disabled"),jQuery.ajax({url:wp.ajax.settings.url,type:"POST",dataType:"json",data:{action:"um_resize_image",src:i,coord:r,user_id:n,key:t,nonce:um_scripts.nonce},success:function(e){1==e.success&&(d=new Date,"profile_photo"==t&&jQuery(".um-profile-photo-img img").attr("src",e.data.image.source_url+"?"+d.getTime()),"cover_photo"==t&&(jQuery(".um-cover-e").empty().html('<img src="'+e.data.image.source_url+"?"+d.getTime()+'" alt="" />'),jQuery(".um").hasClass("um-editing")&&jQuery(".um-cover-overlay").show()),jQuery(".um-single-image-preview[data-key="+t+"]").fadeIn().find("img").attr("src",e.data.image.source_url+"?"+d.getTime()),um_remove_modal(),jQuery(".um-single-image-preview[data-key="+t+"]").parents(".um-field").find(".um-btn-auto-width").html(a.attr("data-change")),jQuery(".um-single-image-preview[data-key="+t+"]").parents(".um-field").find('input[type="hidden"]').val(e.data.image.filename))}})):(d=new Date,jQuery(".um-single-image-preview[data-key="+t+"]").fadeIn().find("img").attr("src",i+"?"+d.getTime()),um_remove_modal(),jQuery(".um-single-image-preview[data-key="+t+"]").parents(".um-field").find(".um-btn-auto-width").html(a.attr("data-change")),jQuery(".um-single-image-preview[data-key="+t+"]").parents(".um-field").find("input[type=hidden]").val(u))}),jQuery(document).on("click",'a[data-modal^="um_"], span[data-modal^="um_"]',function(e){var a=jQuery(this).attr("data-modal"),t="normal";if(jQuery(this).data("modal-size"))t=jQuery(this).data("modal-size");jQuery(this).data("modal-copy")&&(jQuery("#"+a).html(jQuery(this).parents(".um-field").find(".um-modal-hidden-content").html()),jQuery(this).parents(".um-profile-photo").attr("data-user_id")&&jQuery("#"+a).attr("data-user_id",jQuery(this).parents(".um-profile-photo").attr("data-user_id")),jQuery(this).parents(".um-cover").attr("data-ratio")&&jQuery("#"+a).attr("data-ratio",jQuery(this).parents(".um-cover").attr("data-ratio")),jQuery(this).parents(".um-cover").attr("data-user_id")&&jQuery("#"+a).attr("data-user_id",jQuery(this).parents(".um-cover").attr("data-user_id")),0<jQuery("input[type=hidden][name='user_id']").length&&jQuery("#"+a).attr("data-user_id",jQuery("input[type=hidden][name='user_id']").val())),um_new_modal(a,t)})});
assets/js/um-profile.js CHANGED
@@ -48,7 +48,8 @@ jQuery(document).ready(function() {
48
data: {
49
action:'um_delete_profile_photo',
50
metakey: metakey,
51
- user_id: user_id
52
}
53
});
54
@@ -71,7 +72,8 @@ jQuery(document).ready(function() {
71
data: {
72
action: 'um_delete_cover_photo',
73
metakey: metakey,
74
- user_id: user_id
75
},
76
success: function( response ) {
77
obj.hide();
48
data: {
49
action:'um_delete_profile_photo',
50
metakey: metakey,
51
+ user_id: user_id,
52
+ nonce: um_scripts.nonce
53
}
54
});
55
72
data: {
73
action: 'um_delete_cover_photo',
74
metakey: metakey,
75
+ user_id: user_id,
76
+ nonce: um_scripts.nonce
77
},
78
success: function( response ) {
79
obj.hide();
assets/js/um-profile.min.js CHANGED
@@ -1 +1 @@
1
- jQuery(document).ready(function(){function e(){if(void 0!==jQuery("textarea[id=um-meta-bio]").val()){var e=jQuery("textarea[id=um-meta-bio]").attr("data-character-limit")-jQuery("textarea[id=um-meta-bio]").val().length;jQuery("span.um-meta-bio-character span.um-bio-limit").text(e),e<5?jQuery("span.um-meta-bio-character").css("color","red"):jQuery("span.um-meta-bio-character").css("color","")}}jQuery(".um-profile.um-viewing .um-profile-body .um-row").each(function(){var e=jQuery(this);0==e.find(".um-field").length&&(e.prev(".um-row-heading").remove(),e.remove())}),jQuery(".um-profile.um-viewing .um-profile-body").length&&0==jQuery(".um-profile.um-viewing .um-profile-body").find(".um-field").length&&(jQuery(".um-row-heading,.um-row").remove(),jQuery(".um-profile-note").show()),jQuery(document).on("click",".um-profile-save",function(e){return e.preventDefault(),jQuery(this).parents(".um").find("form").submit(),!1}),jQuery(document).on("click",".um-profile-edit-a",function(e){jQuery(this).addClass("active")}),jQuery(document).on("click",".um-cover a.um-cover-add, .um-photo a",function(e){return e.preventDefault(),!1}),jQuery(document).on("click",".um-photo-modal",function(e){e.preventDefault();var t=jQuery(this).attr("data-src");return um_new_modal("um_view_photo","fit",!0,t),!1}),jQuery(document).on("click",".um-reset-profile-photo",function(e){jQuery(".um-profile-photo-img img").attr("src",jQuery(this).attr("data-default_src")),user_id=jQuery(this).attr("data-user_id"),metakey="profile_photo",jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_delete_profile_photo",metakey:metakey,user_id:user_id}})}),jQuery(document).on("click",".um-reset-cover-photo",function(e){var t=jQuery(this);jQuery(".um-cover-overlay").hide(),jQuery(".um-cover-e").html('<a href="#" class="um-cover-add um-manual-trigger" data-parent=".um-cover" data-child=".um-btn-auto-width"><span class="um-cover-add-i"><i class="um-icon-plus um-tip-n" title="Upload a cover photo"></i></span></a>'),jQuery(".um-dropdown").hide(),um_responsive(),user_id=jQuery(this).attr("data-user_id"),metakey="cover_photo",jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_delete_cover_photo",metakey:metakey,user_id:user_id},success:function(e){t.hide()}})}),e(),jQuery("textarea[id=um-meta-bio]").change(e),jQuery("textarea[id=um-meta-bio]").keyup(e),jQuery(".um-profile-edit a.um_delete-item").click(function(e){if(e.preventDefault(),!confirm("Are you sure that you want to delete this user?"))return!1})});
1
+ jQuery(document).ready(function(){function e(){if(void 0!==jQuery("textarea[id=um-meta-bio]").val()){var e=jQuery("textarea[id=um-meta-bio]").attr("data-character-limit")-jQuery("textarea[id=um-meta-bio]").val().length;jQuery("span.um-meta-bio-character span.um-bio-limit").text(e),e<5?jQuery("span.um-meta-bio-character").css("color","red"):jQuery("span.um-meta-bio-character").css("color","")}}jQuery(".um-profile.um-viewing .um-profile-body .um-row").each(function(){var e=jQuery(this);0==e.find(".um-field").length&&(e.prev(".um-row-heading").remove(),e.remove())}),jQuery(".um-profile.um-viewing .um-profile-body").length&&0==jQuery(".um-profile.um-viewing .um-profile-body").find(".um-field").length&&(jQuery(".um-row-heading,.um-row").remove(),jQuery(".um-profile-note").show()),jQuery(document).on("click",".um-profile-save",function(e){return e.preventDefault(),jQuery(this).parents(".um").find("form").submit(),!1}),jQuery(document).on("click",".um-profile-edit-a",function(e){jQuery(this).addClass("active")}),jQuery(document).on("click",".um-cover a.um-cover-add, .um-photo a",function(e){return e.preventDefault(),!1}),jQuery(document).on("click",".um-photo-modal",function(e){e.preventDefault();var t=jQuery(this).attr("data-src");return um_new_modal("um_view_photo","fit",!0,t),!1}),jQuery(document).on("click",".um-reset-profile-photo",function(e){jQuery(".um-profile-photo-img img").attr("src",jQuery(this).attr("data-default_src")),user_id=jQuery(this).attr("data-user_id"),metakey="profile_photo",jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_delete_profile_photo",metakey:metakey,user_id:user_id,nonce:um_scripts.nonce}})}),jQuery(document).on("click",".um-reset-cover-photo",function(e){var t=jQuery(this);jQuery(".um-cover-overlay").hide(),jQuery(".um-cover-e").html('<a href="#" class="um-cover-add um-manual-trigger" data-parent=".um-cover" data-child=".um-btn-auto-width"><span class="um-cover-add-i"><i class="um-icon-plus um-tip-n" title="Upload a cover photo"></i></span></a>'),jQuery(".um-dropdown").hide(),um_responsive(),user_id=jQuery(this).attr("data-user_id"),metakey="cover_photo",jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_delete_cover_photo",metakey:metakey,user_id:user_id,nonce:um_scripts.nonce},success:function(e){t.hide()}})}),e(),jQuery("textarea[id=um-meta-bio]").change(e),jQuery("textarea[id=um-meta-bio]").keyup(e),jQuery(".um-profile-edit a.um_delete-item").click(function(e){if(e.preventDefault(),!confirm("Are you sure that you want to delete this user?"))return!1})});
assets/js/um-scripts.js CHANGED
@@ -155,7 +155,8 @@ jQuery(document).ready(function() {
155
type: 'post',
156
data: {
157
action: 'um_remove_file',
158
- src: src
159
}
160
});
161
@@ -175,7 +176,8 @@ jQuery(document).ready(function() {
175
type: 'post',
176
data: {
177
action: 'um_remove_file',
178
- src: src
179
}
180
});
181
@@ -260,7 +262,8 @@ jQuery(document).ready(function() {
260
data: {
261
action: 'um_ajax_paginate_posts',
262
author: jQuery(this).data('author'),
263
- page: next_page
264
},
265
complete: function() {
266
parent.removeClass( 'loading' );
@@ -284,7 +287,8 @@ jQuery(document).ready(function() {
284
data: {
285
action: 'um_ajax_paginate',
286
hook: hook,
287
- args: args
288
},
289
complete: function() {
290
parent.removeClass( 'loading' );
@@ -315,7 +319,8 @@ jQuery(document).ready(function() {
315
action: 'um_muted_action',
316
hook: hook,
317
user_id: user_id,
318
- arguments: arguments
319
},
320
success: function(data){
321
@@ -370,7 +375,8 @@ jQuery(document).ready(function() {
370
child_callback: um_ajax_source,
371
child_name: me.attr('name'),
372
members_directory: me.attr('data-mebers-directory'),
373
- form_id: form_id
374
},
375
success: function( data ){
376
if( data.status == 'success' && parent.val() != '' ){
155
type: 'post',
156
data: {
157
action: 'um_remove_file',
158
+ src: src,
159
+ nonce: um_scripts.nonce
160
}
161
});
162
176
type: 'post',
177
data: {
178
action: 'um_remove_file',
179
+ src: src,
180
+ nonce: um_scripts.nonce
181
}
182
});
183
262
data: {
263
action: 'um_ajax_paginate_posts',
264
author: jQuery(this).data('author'),
265
+ page: next_page,
266
+ nonce: um_scripts.nonce
267
},
268
complete: function() {
269
parent.removeClass( 'loading' );
287
data: {
288
action: 'um_ajax_paginate',
289
hook: hook,
290
+ args: args,
291
+ nonce: um_scripts.nonce
292
},
293
complete: function() {
294
parent.removeClass( 'loading' );
319
action: 'um_muted_action',
320
hook: hook,
321
user_id: user_id,
322
+ arguments: arguments,
323
+ nonce: um_scripts.nonce
324
},
325
success: function(data){
326
375
child_callback: um_ajax_source,
376
child_name: me.attr('name'),
377
members_directory: me.attr('data-mebers-directory'),
378
+ form_id: form_id,
379
+ nonce: um_scripts.nonce
380
},
381
success: function( data ){
382
if( data.status == 'success' && parent.val() != '' ){
assets/js/um-scripts.min.js CHANGED
@@ -1 +1 @@
1
- jQuery(document).ready(function(){jQuery(document).on("click",".um-dropdown a",function(e){return!1}),jQuery(document).on("click",".um-dropdown a.real_url",function(e){window.location=jQuery(this).attr("href")}),jQuery(document).on("click",".um-trigger-menu-on-click",function(e){return jQuery(".um-dropdown").hide(),menu=jQuery(this).find(".um-dropdown"),menu.show(),!1}),jQuery(document).on("click",".um-dropdown-hide",function(e){UM_hide_menus()}),jQuery(document).on("click","a.um-manual-trigger",function(){var e=jQuery(this).attr("data-child"),t=jQuery(this).attr("data-parent");jQuery(this).parents(t).find(e).trigger("click")}),jQuery(".um-tip-n").tipsy({gravity:"n",opacity:1,live:"a.live",offset:3}),jQuery(".um-tip-w").tipsy({gravity:"w",opacity:1,live:"a.live",offset:3}),jQuery(".um-tip-e").tipsy({gravity:"e",opacity:1,live:"a.live",offset:3}),jQuery(".um-tip-s").tipsy({gravity:"s",opacity:1,live:"a.live",offset:3}),jQuery(document).on("change",".um-field-area input[type=radio]",function(){var e=jQuery(this).parents(".um-field-area"),t=jQuery(this).parents("label");e.find(".um-field-radio").removeClass("active"),e.find(".um-field-radio").find("i").removeAttr("class").addClass("um-icon-android-radio-button-off"),t.addClass("active"),t.find("i").removeAttr("class").addClass("um-icon-android-radio-button-on")}),jQuery(document).on("change",".um-field-area input[type=checkbox]",function(){jQuery(this).parents(".um-field-area");var e=jQuery(this).parents("label");e.hasClass("active")?(e.removeClass("active"),e.find("i").removeAttr("class").addClass("um-icon-android-checkbox-outline-blank")):(e.addClass("active"),e.find("i").removeAttr("class").addClass("um-icon-android-checkbox-outline"))}),jQuery(".um-datepicker").each(function(){if(elem=jQuery(this),""!=elem.attr("data-disabled_weekdays"))var e=JSON.parse(elem.attr("data-disabled_weekdays"));else e=!1;var t=elem.attr("data-years"),a=elem.attr("data-date_min"),i=elem.attr("data-date_max"),r=a.split(","),n=i.split(","),u=r.length?new Date(r):null,o=r.length?new Date(n):null;if(u&&"Invalid Date"==u.toString()&&3==r.length){var d=r[1]+"/"+r[2]+"/"+r[0];u=new Date(Date.parse(d))}if(o&&"Invalid Date"==o.toString()&&3==n.length){var s=n[1]+"/"+n[2]+"/"+n[0];o=new Date(Date.parse(s))}elem.pickadate({selectYears:t,min:u,max:o,disable:e,format:elem.attr("data-format"),formatSubmit:"yyyy/mm/dd",hiddenName:!0,onOpen:function(){elem.blur()},onClose:function(){elem.blur()}})}),jQuery(".um-timepicker").each(function(){elem=jQuery(this),elem.pickatime({format:elem.attr("data-format"),interval:parseInt(elem.attr("data-intervals")),formatSubmit:"HH:i",hiddenName:!0,onOpen:function(){elem.blur()},onClose:function(){elem.blur()}})}),jQuery(".um-rating").um_raty({half:!1,starType:"i",number:function(){return jQuery(this).attr("data-number")},score:function(){return jQuery(this).attr("data-score")},scoreName:function(){return jQuery(this).attr("data-key")},hints:!1,click:function(e,t){live_field=this.id,live_value=e,um_apply_conditions(jQuery(this),!1)}}),jQuery(".um-rating-readonly").um_raty({half:!1,starType:"i",number:function(){return jQuery(this).attr("data-number")},score:function(){return jQuery(this).attr("data-score")},scoreName:function(){return jQuery(this).attr("data-key")},hints:!1,readOnly:!0}),jQuery(document).on("click",".um .um-single-image-preview a.cancel",function(e){e.preventDefault();var t=jQuery(this).parents(".um-field"),a=jQuery(this).parents(".um-field").find(".um-single-image-preview img").attr("src");return t.find(".um-single-image-preview img").attr("src",""),t.find(".um-single-image-preview").hide(),t.find(".um-btn-auto-width").html("Upload"),t.find("input[type=hidden]").val("empty_file"),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_remove_file",src:a}}),!1}),jQuery(document).on("click",".um .um-single-file-preview a.cancel",function(e){e.preventDefault();var t=jQuery(this).parents(".um-field"),a=jQuery(this).parents(".um-field").find(".um-single-fileinfo a").attr("href");return t.find(".um-single-file-preview").hide(),t.find(".um-btn-auto-width").html("Upload"),t.find("input[type=hidden]").val("empty_file"),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_remove_file",src:a}}),!1}),jQuery(".um-s1,.um-s2").css({display:"block"}),jQuery(".um-s1").select2({allowClear:!0}),jQuery(".um-s2").select2({allowClear:!1,minimumResultsForSearch:10}),jQuery(document).on("click",".um-field-group-head:not(.disabled)",function(){var e=jQuery(this).parents(".um-field-group"),t=e.data("max_entries");e.find(".um-field-group-body").is(":hidden")?e.find(".um-field-group-body").show():e.find(".um-field-group-body:first").clone().appendTo(e),increase_id=0,e.find(".um-field-group-body").each(function(){increase_id++,jQuery(this).find("input").each(function(){var e=jQuery(this);e.attr("id",e.data("key")+"-"+increase_id),e.attr("name",e.data("key")+"-"+increase_id),e.parent().parent().find("label").attr("for",e.data("key")+"-"+increase_id)})}),0<t&&e.find(".um-field-group-body").length==t&&jQuery(this).addClass("disabled")}),jQuery(document).on("click",".um-field-group-cancel",function(e){e.preventDefault();var t=jQuery(this).parents(".um-field-group"),a=t.data("max_entries");return 1<t.find(".um-field-group-body").length?jQuery(this).parents(".um-field-group-body").remove():jQuery(this).parents(".um-field-group-body").hide(),0<a&&t.find(".um-field-group-body").length<a&&t.find(".um-field-group-head").removeClass("disabled"),!1}),jQuery(document.body).on("click",".um-ajax-paginate",function(e){e.preventDefault();var t=jQuery(this),a=jQuery(this).parent();a.addClass("loading");var i=jQuery(this).data("hook");if("um_load_posts"===i){var r=1*jQuery(this).data("pages"),n=1*jQuery(this).data("page")+1;jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_ajax_paginate_posts",author:jQuery(this).data("author"),page:n},complete:function(){a.removeClass("loading")},success:function(e){a.before(e),n===r?a.remove():t.data("page",n)}})}else{var u=jQuery(this).data("args"),o=jQuery(this).parents(".um").find(".um-ajax-items");jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_ajax_paginate",hook:i,args:u},complete:function(){a.removeClass("loading")},success:function(e){a.remove(),o.append(e)}})}}),jQuery(document).on("click",".um-ajax-action",function(e){e.preventDefault();var t=jQuery(this).data("hook"),a=jQuery(this).data("user_id"),arguments=jQuery(this).data("arguments");return jQuery(this).data("js-remove")&&jQuery(this).parents("."+jQuery(this).data("js-remove")).fadeOut("fast"),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_muted_action",hook:t,user_id:a,arguments:arguments},success:function(e){}}),!1}),jQuery(document).on("click","#um-search-button",function(){jQuery(this).parents("form").submit()}),jQuery(".um-form input[class=um-button][type=submit]").removeAttr("disabled"),jQuery(document).one("click",".um:not(.um-account) .um-form input[class=um-button][type=submit]:not(.um-has-recaptcha)",function(){jQuery(this).attr("disabled","disabled"),jQuery(this).parents("form").submit()});var o={};function d(e,t,a,i){var r=e.data("um-parent");e.attr("name"),jQuery('select[name="'+r+'"]');e.find('option[value!=""]').remove(),e.hasClass("um-child-option-disabled")||e.removeAttr("disabled");i=[];var n="";if("yes"===t.post.members_directory){var u=new URLSearchParams(window.location.search);n=u.get(t.post.child_name)}jQuery.each(t.items,function(e,t){i.push({id:e,text:t,selected:t===n})}),e.select2("destroy"),e.select2({data:i,allowClear:!0,minimumResultsForSearch:10}),"yes"!==t.post.members_directory&&(void 0===t.field.default||e.data("um-original-value")?""!=e.data("um-original-value")&&e.val(e.data("um-original-value")).trigger("change"):e.val(t.field.default).trigger("change"),0==t.field.editable&&(e.addClass("um-child-option-disabled"),e.attr("disabled","disabled"))),o[a]=t}jQuery("select[data-um-parent]").each(function(){var r=jQuery(this),n=r.data("um-parent"),u=(r.data("um-ajax-url"),r.data("um-ajax-source"));r.val();r.attr("data-um-init-field",!0),jQuery(document).on("change",'select[name="'+n+'"]',function(){var t=jQuery(this),e=t.closest("form").find("input[type=hidden][name=form_id]").val(),a=t.val();if(""!=t.val()&&"object"!=typeof o[a]&&jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_select_options",parent_option_name:n,parent_option:t.val(),child_callback:u,child_name:r.attr("name"),members_directory:r.attr("data-mebers-directory"),form_id:e},success:function(e){"success"==e.status&&""!=t.val()&&d(r,e,a),void 0!==e.debug&&console.log(e)},error:function(e){console.log(e)}}),""!=t.val()&&"object"==typeof o[a]){var i=o[a];d(r,i,a)}""==t.val()&&(r.find('option[value!=""]').remove(),r.val("").trigger("change"))}),jQuery('select[name="'+n+'"]').trigger("change")})});
1
+ jQuery(document).ready(function(){jQuery(document).on("click",".um-dropdown a",function(e){return!1}),jQuery(document).on("click",".um-dropdown a.real_url",function(e){window.location=jQuery(this).attr("href")}),jQuery(document).on("click",".um-trigger-menu-on-click",function(e){return jQuery(".um-dropdown").hide(),menu=jQuery(this).find(".um-dropdown"),menu.show(),!1}),jQuery(document).on("click",".um-dropdown-hide",function(e){UM_hide_menus()}),jQuery(document).on("click","a.um-manual-trigger",function(){var e=jQuery(this).attr("data-child"),t=jQuery(this).attr("data-parent");jQuery(this).parents(t).find(e).trigger("click")}),jQuery(".um-tip-n").tipsy({gravity:"n",opacity:1,live:"a.live",offset:3}),jQuery(".um-tip-w").tipsy({gravity:"w",opacity:1,live:"a.live",offset:3}),jQuery(".um-tip-e").tipsy({gravity:"e",opacity:1,live:"a.live",offset:3}),jQuery(".um-tip-s").tipsy({gravity:"s",opacity:1,live:"a.live",offset:3}),jQuery(document).on("change",".um-field-area input[type=radio]",function(){var e=jQuery(this).parents(".um-field-area"),t=jQuery(this).parents("label");e.find(".um-field-radio").removeClass("active"),e.find(".um-field-radio").find("i").removeAttr("class").addClass("um-icon-android-radio-button-off"),t.addClass("active"),t.find("i").removeAttr("class").addClass("um-icon-android-radio-button-on")}),jQuery(document).on("change",".um-field-area input[type=checkbox]",function(){jQuery(this).parents(".um-field-area");var e=jQuery(this).parents("label");e.hasClass("active")?(e.removeClass("active"),e.find("i").removeAttr("class").addClass("um-icon-android-checkbox-outline-blank")):(e.addClass("active"),e.find("i").removeAttr("class").addClass("um-icon-android-checkbox-outline"))}),jQuery(".um-datepicker").each(function(){if(elem=jQuery(this),""!=elem.attr("data-disabled_weekdays"))var e=JSON.parse(elem.attr("data-disabled_weekdays"));else e=!1;var t=elem.attr("data-years"),a=elem.attr("data-date_min"),i=elem.attr("data-date_max"),r=a.split(","),n=i.split(","),u=r.length?new Date(r):null,o=r.length?new Date(n):null;if(u&&"Invalid Date"==u.toString()&&3==r.length){var s=r[1]+"/"+r[2]+"/"+r[0];u=new Date(Date.parse(s))}if(o&&"Invalid Date"==o.toString()&&3==n.length){var d=n[1]+"/"+n[2]+"/"+n[0];o=new Date(Date.parse(d))}elem.pickadate({selectYears:t,min:u,max:o,disable:e,format:elem.attr("data-format"),formatSubmit:"yyyy/mm/dd",hiddenName:!0,onOpen:function(){elem.blur()},onClose:function(){elem.blur()}})}),jQuery(".um-timepicker").each(function(){elem=jQuery(this),elem.pickatime({format:elem.attr("data-format"),interval:parseInt(elem.attr("data-intervals")),formatSubmit:"HH:i",hiddenName:!0,onOpen:function(){elem.blur()},onClose:function(){elem.blur()}})}),jQuery(".um-rating").um_raty({half:!1,starType:"i",number:function(){return jQuery(this).attr("data-number")},score:function(){return jQuery(this).attr("data-score")},scoreName:function(){return jQuery(this).attr("data-key")},hints:!1,click:function(e,t){live_field=this.id,live_value=e,um_apply_conditions(jQuery(this),!1)}}),jQuery(".um-rating-readonly").um_raty({half:!1,starType:"i",number:function(){return jQuery(this).attr("data-number")},score:function(){return jQuery(this).attr("data-score")},scoreName:function(){return jQuery(this).attr("data-key")},hints:!1,readOnly:!0}),jQuery(document).on("click",".um .um-single-image-preview a.cancel",function(e){e.preventDefault();var t=jQuery(this).parents(".um-field"),a=jQuery(this).parents(".um-field").find(".um-single-image-preview img").attr("src");return t.find(".um-single-image-preview img").attr("src",""),t.find(".um-single-image-preview").hide(),t.find(".um-btn-auto-width").html("Upload"),t.find("input[type=hidden]").val("empty_file"),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_remove_file",src:a,nonce:um_scripts.nonce}}),!1}),jQuery(document).on("click",".um .um-single-file-preview a.cancel",function(e){e.preventDefault();var t=jQuery(this).parents(".um-field"),a=jQuery(this).parents(".um-field").find(".um-single-fileinfo a").attr("href");return t.find(".um-single-file-preview").hide(),t.find(".um-btn-auto-width").html("Upload"),t.find("input[type=hidden]").val("empty_file"),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_remove_file",src:a,nonce:um_scripts.nonce}}),!1}),jQuery(".um-s1,.um-s2").css({display:"block"}),jQuery(".um-s1").select2({allowClear:!0}),jQuery(".um-s2").select2({allowClear:!1,minimumResultsForSearch:10}),jQuery(document).on("click",".um-field-group-head:not(.disabled)",function(){var e=jQuery(this).parents(".um-field-group"),t=e.data("max_entries");e.find(".um-field-group-body").is(":hidden")?e.find(".um-field-group-body").show():e.find(".um-field-group-body:first").clone().appendTo(e),increase_id=0,e.find(".um-field-group-body").each(function(){increase_id++,jQuery(this).find("input").each(function(){var e=jQuery(this);e.attr("id",e.data("key")+"-"+increase_id),e.attr("name",e.data("key")+"-"+increase_id),e.parent().parent().find("label").attr("for",e.data("key")+"-"+increase_id)})}),0<t&&e.find(".um-field-group-body").length==t&&jQuery(this).addClass("disabled")}),jQuery(document).on("click",".um-field-group-cancel",function(e){e.preventDefault();var t=jQuery(this).parents(".um-field-group"),a=t.data("max_entries");return 1<t.find(".um-field-group-body").length?jQuery(this).parents(".um-field-group-body").remove():jQuery(this).parents(".um-field-group-body").hide(),0<a&&t.find(".um-field-group-body").length<a&&t.find(".um-field-group-head").removeClass("disabled"),!1}),jQuery(document.body).on("click",".um-ajax-paginate",function(e){e.preventDefault();var t=jQuery(this),a=jQuery(this).parent();a.addClass("loading");var i=jQuery(this).data("hook");if("um_load_posts"===i){var r=1*jQuery(this).data("pages"),n=1*jQuery(this).data("page")+1;jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_ajax_paginate_posts",author:jQuery(this).data("author"),page:n,nonce:um_scripts.nonce},complete:function(){a.removeClass("loading")},success:function(e){a.before(e),n===r?a.remove():t.data("page",n)}})}else{var u=jQuery(this).data("args"),o=jQuery(this).parents(".um").find(".um-ajax-items");jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_ajax_paginate",hook:i,args:u,nonce:um_scripts.nonce},complete:function(){a.removeClass("loading")},success:function(e){a.remove(),o.append(e)}})}}),jQuery(document).on("click",".um-ajax-action",function(e){e.preventDefault();var t=jQuery(this).data("hook"),a=jQuery(this).data("user_id"),arguments=jQuery(this).data("arguments");return jQuery(this).data("js-remove")&&jQuery(this).parents("."+jQuery(this).data("js-remove")).fadeOut("fast"),jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_muted_action",hook:t,user_id:a,arguments:arguments,nonce:um_scripts.nonce},success:function(e){}}),!1}),jQuery(document).on("click","#um-search-button",function(){jQuery(this).parents("form").submit()}),jQuery(".um-form input[class=um-button][type=submit]").removeAttr("disabled"),jQuery(document).one("click",".um:not(.um-account) .um-form input[class=um-button][type=submit]:not(.um-has-recaptcha)",function(){jQuery(this).attr("disabled","disabled"),jQuery(this).parents("form").submit()});var o={};function s(e,t,a,i){var r=e.data("um-parent");e.attr("name"),jQuery('select[name="'+r+'"]');e.find('option[value!=""]').remove(),e.hasClass("um-child-option-disabled")||e.removeAttr("disabled");i=[];var n="";if("yes"===t.post.members_directory){var u=new URLSearchParams(window.location.search);n=u.get(t.post.child_name)}jQuery.each(t.items,function(e,t){i.push({id:e,text:t,selected:t===n})}),e.select2("destroy"),e.select2({data:i,allowClear:!0,minimumResultsForSearch:10}),"yes"!==t.post.members_directory&&(void 0===t.field.default||e.data("um-original-value")?""!=e.data("um-original-value")&&e.val(e.data("um-original-value")).trigger("change"):e.val(t.field.default).trigger("change"),0==t.field.editable&&(e.addClass("um-child-option-disabled"),e.attr("disabled","disabled"))),o[a]=t}jQuery("select[data-um-parent]").each(function(){var r=jQuery(this),n=r.data("um-parent"),u=(r.data("um-ajax-url"),r.data("um-ajax-source"));r.val();r.attr("data-um-init-field",!0),jQuery(document).on("change",'select[name="'+n+'"]',function(){var t=jQuery(this),e=t.closest("form").find("input[type=hidden][name=form_id]").val(),a=t.val();if(""!=t.val()&&"object"!=typeof o[a]&&jQuery.ajax({url:wp.ajax.settings.url,type:"post",data:{action:"um_select_options",parent_option_name:n,parent_option:t.val(),child_callback:u,child_name:r.attr("name"),members_directory:r.attr("data-mebers-directory"),form_id:e,nonce:um_scripts.nonce},success:function(e){"success"==e.status&&""!=t.val()&&s(r,e,a),void 0!==e.debug&&console.log(e)},error:function(e){console.log(e)}}),""!=t.val()&&"object"==typeof o[a]){var i=o[a];s(r,i,a)}""==t.val()&&(r.find('option[value!=""]').remove(),r.val("").trigger("change"))}),jQuery('select[name="'+n+'"]').trigger("change")})});
includes/admin/assets/js/um-admin-ajax.js CHANGED
@@ -31,7 +31,17 @@ jQuery(document).ready(function() {
31
jQuery.ajax({
32
url: wp.ajax.settings.url,
33
type: 'POST',
34
- data: { action:'um_do_ajax_action',act_id : act_id, arg1 : arg1, arg2 : arg2, in_row: in_row, in_sub_row: in_sub_row, in_column: in_column, in_group: in_group },
35
success: function(data){
36
37
jQuery('.um-col-demon-settings').data('in_row', '');
31
jQuery.ajax({
32
url: wp.ajax.settings.url,
33
type: 'POST',
34
+ data: {
35
+ action:'um_do_ajax_action',
36
+ act_id : act_id,
37
+ arg1 : arg1,
38
+ arg2 : arg2,
39
+ in_row: in_row,
40
+ in_sub_row: in_sub_row,
41
+ in_column: in_column,
42
+ in_group: in_group,
43
+ nonce: um_admin_scripts.nonce
44
+ },
45
success: function(data){
46
47
jQuery('.um-col-demon-settings').data('in_row', '');
includes/admin/assets/js/um-admin-builder.js CHANGED
@@ -14,7 +14,8 @@ function um_admin_update_builder() {
14
type: 'POST',
15
data: {
16
action:'um_update_builder',
17
- form_id: form_id
18
},
19
success: function(data){
20
14
type: 'POST',
15
data: {
16
action:'um_update_builder',
17
+ form_id: form_id,
18
+ nonce: um_admin_scripts.nonce
19
},
20
success: function(data){
21
includes/admin/assets/js/um-admin-field.js CHANGED
@@ -13,7 +13,13 @@ jQuery(document).ready(function() {
13
jQuery.ajax({
14
url: wp.ajax.settings.url,
15
type: 'POST',
16
- data: {action:'um_do_ajax_action',act_id : 'um_admin_remove_field_global', arg1 : arg1 },
17
success: function(data){
18
19
},
13
jQuery.ajax({
14
url: wp.ajax.settings.url,
15
type: 'POST',
16
+ data: {
17
+ action:'um_do_ajax_action',
18
+ act_id : 'um_admin_remove_field_global',
19
+ arg1 : arg1,
20
+ nonce: um_admin_scripts.nonce
21
+
22
+ },
23
success: function(data){
24
25
},
includes/admin/assets/js/um-admin-modal.js CHANGED
@@ -54,7 +54,18 @@ function um_admin_modal_ajaxcall( act_id, arg1, arg2, arg3 ) {
54
jQuery.ajax({
55
url: wp.ajax.settings.url,
56
type: 'POST',
57
- data: { action:'um_dynamic_modal_content',act_id: act_id, arg1 : arg1, arg2 : arg2, arg3: arg3, in_row: in_row, in_sub_row: in_sub_row, in_column: in_column, in_group: in_group },
58
complete: function(){
59
um_admin_modal_loaded();
60
um_admin_modal_responsive();
@@ -386,7 +397,11 @@ jQuery(document).ready(function() {
386
jQuery.ajax({
387
url: wp.ajax.settings.url,
388
type: 'POST',
389
- data: { action:'populate_dropdown_options',um_option_callback: um_option_callback },
390
complete: function(){
391
392
},
54
jQuery.ajax({
55
url: wp.ajax.settings.url,
56
type: 'POST',
57
+ data: {
58
+ action:'um_dynamic_modal_content',
59
+ act_id: act_id,
60
+ arg1 : arg1,
61
+ arg2 : arg2,
62
+ arg3: arg3,
63
+ in_row: in_row,
64
+ in_sub_row: in_sub_row,
65
+ in_column: in_column,
66
+ in_group: in_group,
67
+ nonce: um_admin_scripts.nonce
68
+ },
69
complete: function(){
70
um_admin_modal_loaded();
71
um_admin_modal_responsive();
397
jQuery.ajax({
398
url: wp.ajax.settings.url,
399
type: 'POST',
400
+ data: {
401
+ action:'um_populate_dropdown_options',
402
+ um_option_callback: um_option_callback,
403
+ nonce: um_admin_scripts.nonce
404
+ },
405
complete: function(){
406
407
},
includes/admin/class-admin-functions.php CHANGED
@@ -22,6 +22,21 @@ if ( ! class_exists( 'um\admin\Admin_Functions' ) ) {
22
}
23
24
25
/**
26
* Boolean check if we're viewing UM backend
27
*
22
}
23
24
25
+ /**
26
+ * Check wp-admin nonce
27
+ *
28
+ * @param bool $action
29
+ */
30
+ function check_ajax_nonce( $action = false ) {
31
+ $nonce = isset( $_POST['nonce'] ) ? $_POST['nonce'] : '';
32
+ $action = empty( $action ) ? 'um-admin-nonce' : $action;
33
+
34
+ if ( ! wp_verify_nonce( $nonce, $action ) ) {
35
+ wp_send_json_error( esc_js( __( 'Wrong Nonce', 'ultimate-member' ) ) );
36
+ }
37
+ }
38
+
39
+
40
/**
41
* Boolean check if we're viewing UM backend
42
*
includes/admin/core/class-admin-builder.php CHANGED
@@ -292,9 +292,10 @@ if ( ! class_exists( 'um\admin\core\Admin_Builder' ) ) {
292
* Update the builder area
293
*/
294
function update_builder() {
295
296
if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) ) {
297
- die( 'Please login as administrator' );
298
}
299
300
extract( $_POST );
@@ -605,8 +606,11 @@ if ( ! class_exists( 'um\admin\core\Admin_Builder' ) ) {
605
*
606
*/
607
function update_field() {
608
- if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) )
609
- die( __('Please login as administrator','ultimate-member') );
610
611
$output['error'] = null;
612
@@ -757,12 +761,14 @@ if ( ! class_exists( 'um\admin\core\Admin_Builder' ) ) {
757
*
758
*/
759
function dynamic_modal_content() {
760
- $metabox = UM()->metabox();
761
762
if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) ) {
763
- die( __( 'Please login as administrator', 'ultimate-member' ) );
764
}
765
766
/**
767
* @var $act_id
768
* @var $arg1
@@ -1131,12 +1137,14 @@ if ( ! class_exists( 'um\admin\core\Admin_Builder' ) ) {
1131
* Retrieves dropdown/multi-select options from a callback function
1132
*/
1133
function populate_dropdown_options() {
1134
- $arr_options = array();
1135
1136
- if ( ! current_user_can('manage_options') ) {
1137
- wp_die( __( 'This is not possible for security reasons.', 'ultimate-member' ) );
1138
}
1139
1140
$um_callback_func = $_POST['um_option_callback'];
1141
if ( empty( $um_callback_func ) ) {
1142
$arr_options['status'] = 'empty';
@@ -1145,7 +1153,6 @@ if ( ! class_exists( 'um\admin\core\Admin_Builder' ) ) {
1145
}
1146
1147
$arr_options['data'] = array();
1148
-
1149
if ( function_exists( $um_callback_func ) ) {
1150
$arr_options['data'] = call_user_func( $um_callback_func );
1151
}
292
* Update the builder area
293
*/
294
function update_builder() {
295
+ UM()->admin()->check_ajax_nonce();
296
297
if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) ) {
298
+ wp_send_json_error( __( 'Please login as administrator', 'ultimate-member' ) );
299
}
300
301
extract( $_POST );
606
*
607
*/
608
function update_field() {
609
+ UM()->admin()->check_ajax_nonce();
610
+
611
+ if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) ) {
612
+ wp_send_json_error( __( 'Please login as administrator', 'ultimate-member' ) );
613
+ }
614
615
$output['error'] = null;
616
761
*
762
*/
763
function dynamic_modal_content() {
764
+ UM()->admin()->check_ajax_nonce();
765
766
if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) ) {
767
+ wp_send_json_error( __( 'Please login as administrator', 'ultimate-member' ) );
768
}
769
770
+ $metabox = UM()->metabox();
771
+
772
/**
773
* @var $act_id
774
* @var $arg1
1137
* Retrieves dropdown/multi-select options from a callback function
1138
*/
1139
function populate_dropdown_options() {
1140
+ UM()->admin()->check_ajax_nonce();
1141
1142
+ if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) ) {
1143
+ wp_send_json_error( __( 'This is not possible for security reasons.', 'ultimate-member' ) );
1144
}
1145
1146
+ $arr_options = array();
1147
+
1148
$um_callback_func = $_POST['um_option_callback'];
1149
if ( empty( $um_callback_func ) ) {
1150
$arr_options['status'] = 'empty';
1153
}
1154
1155
$arr_options['data'] = array();
1156
if ( function_exists( $um_callback_func ) ) {
1157
$arr_options['data'] = call_user_func( $um_callback_func );
1158
}
includes/admin/core/class-admin-dragdrop.php CHANGED
@@ -26,9 +26,11 @@ if ( ! class_exists( 'um\admin\core\Admin_DragDrop' ) ) {
26
* Update order of fields
27
*/
28
function update_order() {
29
30
- if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) )
31
- die( 'Please login as administrator' );
32
33
/**
34
* @var $form_id
@@ -43,8 +45,8 @@ if ( ! class_exists( 'um\admin\core\Admin_DragDrop' ) ) {
43
if ( ! empty( $fields ) ) {
44
foreach ( $fields as $key => $array ) {
45
if ( $array['type'] == 'row' ) {
46
- $this->row_data[$key] = $array;
47
- unset( $fields[$key] );
48
}
49
}
50
} else {
@@ -217,6 +219,7 @@ if ( ! class_exists( 'um\admin\core\Admin_DragDrop' ) ) {
217
218
<input type="hidden" name="form_id" id="form_id" value="<?php echo get_the_ID(); ?>" />
219
<input type="hidden" name="action" value="um_update_order" />
220
221
<div class="um_update_order_fields">
222
26
* Update order of fields
27
*/
28
function update_order() {
29
+ UM()->admin()->check_ajax_nonce();
30
31
+ if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) ) {
32
+ wp_send_json_error( __( 'Please login as administrator', 'ultimate-member' ) );
33
+ }
34
35
/**
36
* @var $form_id
45
if ( ! empty( $fields ) ) {
46
foreach ( $fields as $key => $array ) {
47
if ( $array['type'] == 'row' ) {
48
+ $this->row_data[ $key ] = $array;
49
+ unset( $fields[ $key ] );
50
}
51
}
52
} else {
219
220
<input type="hidden" name="form_id" id="form_id" value="<?php echo get_the_ID(); ?>" />
221
<input type="hidden" name="action" value="um_update_order" />
222
+ <input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'um-admin-nonce' ) ?>" />
223
224
<div class="um_update_order_fields">
225
includes/admin/core/class-admin-enqueue.php CHANGED
@@ -332,9 +332,8 @@ if ( ! class_exists( 'um\admin\core\Admin_Enqueue' ) ) {
332
* }
333
* ?>
334
*/
335
- $localize_data = apply_filters('um_admin_enqueue_localize_data', array(
336
- 'ajaxurl' => admin_url( 'admin-ajax.php' ),
337
- 'nonce' => wp_create_nonce( "um-admin-nonce" )
338
)
339
);
340
332
* }
333
* ?>
334
*/
335
+ $localize_data = apply_filters( 'um_admin_enqueue_localize_data', array(
336
+ 'nonce' => wp_create_nonce( "um-admin-nonce" )
337
)
338
);
339
includes/admin/core/class-admin-menu.php CHANGED
@@ -76,7 +76,8 @@ if ( ! class_exists( 'um\admin\core\Admin_Menu' ) ) {
76
url: wp.ajax.settings.url,
77
type: 'post',
78
data: {
79
- action: 'um_rated'
80
},
81
success: function(){
82
@@ -98,8 +99,14 @@ if ( ! class_exists( 'um\admin\core\Admin_Menu' ) ) {
98
* When user clicks the review link in backend
99
*/
100
function ultimatemember_rated() {
101
update_option( 'um_admin_footer_text_rated', 1 );
102
- die();
103
}
104
105
@@ -109,8 +116,9 @@ if ( ! class_exists( 'um\admin\core\Admin_Menu' ) ) {
109
public function menu_order_count() {
110
global $menu, $submenu;
111
112
- if ( ! current_user_can( 'list_users' ) )
113
return;
114
115
$count = UM()->user()->get_pending_users_count();
116
if ( is_array( $menu ) ) {
76
url: wp.ajax.settings.url,
77
type: 'post',
78
data: {
79
+ action: 'um_rated',
80
+ nonce: um_admin_scripts.nonce
81
},
82
success: function(){
83
99
* When user clicks the review link in backend
100
*/
101
function ultimatemember_rated() {
102
+ UM()->admin()->check_ajax_nonce();
103
+
104
+ if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) ) {
105
+ wp_send_json_error( __( 'Please login as administrator', 'ultimate-member' ) );
106
+ }
107
+
108
update_option( 'um_admin_footer_text_rated', 1 );
109
+ wp_send_json_success();
110
}
111
112
116
public function menu_order_count() {
117
global $menu, $submenu;
118
119
+ if ( ! current_user_can( 'list_users' ) ) {
120
return;
121
+ }
122
123
$count = UM()->user()->get_pending_users_count();
124
if ( is_array( $menu ) ) {
includes/admin/core/class-admin-notices.php CHANGED
@@ -666,11 +666,7 @@ if ( ! class_exists( 'um\admin\core\Admin_Notices' ) ) {
666
667
668
function dismiss_notice() {
669
- $nonce = isset( $_POST["nonce"] ) ? $_POST["nonce"] : "";
670
- if ( ! wp_verify_nonce( $nonce, "um-admin-nonce" ) ) {
671
- wp_send_json_error( esc_js( __( "Wrong Nonce", 'ultimate-member' ) ) );
672
- }
673
-
674
675
if ( empty( $_POST['key'] ) ) {
676
wp_send_json_error( __( 'Wrong Data', 'ultimate-member' ) );
666
667
668
function dismiss_notice() {
669
+ UM()->admin()->check_ajax_nonce();
670
671
if ( empty( $_POST['key'] ) ) {
672
wp_send_json_error( __( 'Wrong Data', 'ultimate-member' ) );
includes/admin/core/class-admin-upgrade.php CHANGED
@@ -260,7 +260,8 @@ if ( ! class_exists( 'um\admin\core\Admin_Upgrade' ) ) {
260
type: 'POST',
261
dataType: 'json',
262
data: {
263
- action: 'um_get_packages'
264
},
265
success: function( response ) {
266
um_packages = response.data.packages;
@@ -290,7 +291,8 @@ if ( ! class_exists( 'um\admin\core\Admin_Upgrade' ) ) {
290
dataType: 'html',
291
data: {
292
action: 'um_run_package',
293
- pack: pack
294
},
295
success: function( html ) {
296
um_add_upgrade_log( 'Package "' + pack + '" is ready. Start the execution...' );
@@ -334,6 +336,8 @@ if ( ! class_exists( 'um\admin\core\Admin_Upgrade' ) ) {
334
335
336
function ajax_run_package() {
337
if ( empty( $_POST['pack'] ) ) {
338
exit('');
339
} else {
@@ -346,6 +350,8 @@ if ( ! class_exists( 'um\admin\core\Admin_Upgrade' ) ) {
346
347
348
function ajax_get_packages() {
349
$update_versions = $this->need_run_upgrades();
350
wp_send_json_success( array( 'packages' => $update_versions ) );
351
}
260
type: 'POST',
261
dataType: 'json',
262
data: {
263
+ action: 'um_get_packages',
264
+ nonce: um_admin_scripts.nonce
265
},
266
success: function( response ) {
267
um_packages = response.data.packages;
291
dataType: 'html',
292
data: {
293
action: 'um_run_package',
294
+ pack: pack,
295
+ nonce: um_admin_scripts.nonce
296
},
297
success: function( html ) {
298
um_add_upgrade_log( 'Package "' + pack + '" is ready. Start the execution...' );
336
337
338
function ajax_run_package() {
339
+ UM()->admin()->check_ajax_nonce();
340
+
341
if ( empty( $_POST['pack'] ) ) {
342
exit('');
343
} else {
350
351
352
function ajax_get_packages() {
353
+ UM()->admin()->check_ajax_nonce();
354
+
355
$update_versions = $this->need_run_upgrades();
356
wp_send_json_success( array( 'packages' => $update_versions ) );
357
}
includes/admin/core/packages/1.3.39/functions.php CHANGED
@@ -1,5 +1,7 @@
1
<?php
2
function um_upgrade_usermetaquery1339() {
3
include 'usermeta_query.php';
4
5
update_option( 'um_last_version_upgrade', '1.3.39' );
1
<?php
2
function um_upgrade_usermetaquery1339() {
3
+ UM()->admin()->check_ajax_nonce();
4
+
5
include 'usermeta_query.php';
6
7
update_option( 'um_last_version_upgrade', '1.3.39' );
includes/admin/core/packages/1.3.39/init.php CHANGED
@@ -5,11 +5,12 @@
5
um_add_upgrade_log( 'Upgrade Usermeta...' );
6
7
jQuery.ajax({
8
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
9
type: 'POST',
10
dataType: 'json',
11
data: {
12
- action: 'um_usermetaquery1339'
13
},
14
success: function( response ) {
15
if ( typeof response.data != 'undefined' ) {
5
um_add_upgrade_log( 'Upgrade Usermeta...' );
6
7
jQuery.ajax({
8
+ url: wp.ajax.settings.url,
9
type: 'POST',
10
dataType: 'json',
11
data: {
12
+ action: 'um_usermetaquery1339',
13
+ nonce: um_admin_scripts.nonce
14
},
15
success: function( response ) {
16
if ( typeof response.data != 'undefined' ) {
includes/admin/core/packages/2.0-beta1/functions.php CHANGED
@@ -1,5 +1,7 @@
1
<?php
2
function um_upgrade_styles20beta1() {
3
um_maybe_unset_time_limit();
4
5
include 'styles.php';
@@ -8,6 +10,8 @@ function um_upgrade_styles20beta1() {
8
9
10
function um_upgrade_user_roles20beta1() {
11
um_maybe_unset_time_limit();
12
/**
13
* @var $response_roles_data
@@ -19,7 +23,10 @@ function um_upgrade_user_roles20beta1() {
19
20
21
function um_upgrade_get_users_per_role20beta1() {
22
um_maybe_unset_time_limit();
23
if ( ! empty( $_POST['key_in_meta'] ) ) {
24
$args = array(
25
'meta_query' => array(
@@ -43,6 +50,8 @@ function um_upgrade_get_users_per_role20beta1() {
43
44
45
function um_upgrade_update_users_per_page20beta1() {
46
um_maybe_unset_time_limit();
47
if ( ! empty( $_POST['key_in_meta'] ) && ! empty( $_POST['role_key'] ) && ! empty( $_POST['page'] ) ) {
48
$users_per_page = 100;
@@ -85,6 +94,8 @@ function um_upgrade_update_users_per_page20beta1() {
85
86
87
function um_upgrade_content_restriction20beta1() {
88
um_maybe_unset_time_limit();
89
90
include 'content_restriction.php';
@@ -94,6 +105,8 @@ function um_upgrade_content_restriction20beta1() {
94
95
96
function um_upgrade_settings20beta1() {
97
um_maybe_unset_time_limit();
98
99
include 'settings.php';
@@ -102,6 +115,8 @@ function um_upgrade_settings20beta1() {
102
103
104
function um_upgrade_menus20beta1() {
105
um_maybe_unset_time_limit();
106
107
include 'menus.php';
@@ -110,6 +125,8 @@ function um_upgrade_menus20beta1() {
110
111
112
function um_upgrade_mc_lists20beta1() {
113
um_maybe_unset_time_limit();
114
115
include 'mc_lists.php';
@@ -118,6 +135,8 @@ function um_upgrade_mc_lists20beta1() {
118
119
120
function um_upgrade_social_login20beta1() {
121
um_maybe_unset_time_limit();
122
123
include 'social_login.php';
@@ -126,6 +145,8 @@ function um_upgrade_social_login20beta1() {
126
127
128
function um_upgrade_cpt20beta1() {
129
um_maybe_unset_time_limit();
130
131
include 'um_cpt.php';
@@ -134,6 +155,8 @@ function um_upgrade_cpt20beta1() {
134
135
136
function um_upgrade_get_forums20beta1() {
137
um_maybe_unset_time_limit();
138
139
remove_all_actions( 'pre_get_posts' );
@@ -149,6 +172,8 @@ function um_upgrade_get_forums20beta1() {
149
150
151
function um_upgrade_update_forum_per_page20beta1() {
152
um_maybe_unset_time_limit();
153
154
if ( ! empty( $_POST['page'] ) ) {
@@ -205,6 +230,8 @@ function um_upgrade_update_forum_per_page20beta1() {
205
206
207
function um_upgrade_get_products20beta1() {
208
um_maybe_unset_time_limit();
209
210
$wc_products = get_posts( array(
@@ -218,6 +245,8 @@ function um_upgrade_get_products20beta1() {
218
219
220
function um_upgrade_update_products_per_page20beta1() {
221
um_maybe_unset_time_limit();
222
223
if ( ! empty( $_POST['page'] ) ) {
@@ -296,6 +325,8 @@ function um_upgrade_update_products_per_page20beta1() {
296
297
298
function um_upgrade_email_templates20beta1() {
299
um_maybe_unset_time_limit();
300
301
include 'email_templates.php';
1
<?php
2
function um_upgrade_styles20beta1() {
3
+ UM()->admin()->check_ajax_nonce();
4
+
5
um_maybe_unset_time_limit();
6
7
include 'styles.php';
10
11
12
function um_upgrade_user_roles20beta1() {
13
+ UM()->admin()->check_ajax_nonce();
14
+
15
um_maybe_unset_time_limit();
16
/**
17
* @var $response_roles_data
23
24
25
function um_upgrade_get_users_per_role20beta1() {
26
+ UM()->admin()->check_ajax_nonce();
27
+
28
um_maybe_unset_time_limit();
29
+
30
if ( ! empty( $_POST['key_in_meta'] ) ) {
31
$args = array(
32
'meta_query' => array(
50
51
52
function um_upgrade_update_users_per_page20beta1() {
53
+ UM()->admin()->check_ajax_nonce();
54
+
55
um_maybe_unset_time_limit();
56
if ( ! empty( $_POST['key_in_meta'] ) && ! empty( $_POST['role_key'] ) && ! empty( $_POST['page'] ) ) {
57
$users_per_page = 100;
94
95
96
function um_upgrade_content_restriction20beta1() {
97
+ UM()->admin()->check_ajax_nonce();
98
+
99
um_maybe_unset_time_limit();
100
101
include 'content_restriction.php';
105
106
107
function um_upgrade_settings20beta1() {
108
+ UM()->admin()->check_ajax_nonce();
109
+
110
um_maybe_unset_time_limit();
111
112
include 'settings.php';
115
116
117
function um_upgrade_menus20beta1() {
118
+ UM()->admin()->check_ajax_nonce();
119
+
120
um_maybe_unset_time_limit();
121
122
include 'menus.php';
125
126
127
function um_upgrade_mc_lists20beta1() {
128
+ UM()->admin()->check_ajax_nonce();
129
+
130
um_maybe_unset_time_limit();
131
132
include 'mc_lists.php';
135
136
137
function um_upgrade_social_login20beta1() {
138
+ UM()->admin()->check_ajax_nonce();
139
+
140
um_maybe_unset_time_limit();
141
142
include 'social_login.php';
145
146
147
function um_upgrade_cpt20beta1() {
148
+ UM()->admin()->check_ajax_nonce();
149
+
150
um_maybe_unset_time_limit();
151
152
include 'um_cpt.php';
155
156
157
function um_upgrade_get_forums20beta1() {
158
+ UM()->admin()->check_ajax_nonce();
159
+
160
um_maybe_unset_time_limit();
161
162
remove_all_actions( 'pre_get_posts' );
172
173
174
function um_upgrade_update_forum_per_page20beta1() {
175
+ UM()->admin()->check_ajax_nonce();
176
+
177
um_maybe_unset_time_limit();
178
179
if ( ! empty( $_POST['page'] ) ) {
230
231
232
function um_upgrade_get_products20beta1() {
233
+ UM()->admin()->check_ajax_nonce();
234
+
235
um_maybe_unset_time_limit();
236
237
$wc_products = get_posts( array(
245
246
247
function um_upgrade_update_products_per_page20beta1() {
248
+ UM()->admin()->check_ajax_nonce();
249
+
250
um_maybe_unset_time_limit();
251
252
if ( ! empty( $_POST['page'] ) ) {
325
326
327
function um_upgrade_email_templates20beta1() {
328
+ UM()->admin()->check_ajax_nonce();
329
+
330
um_maybe_unset_time_limit();
331
332
include 'email_templates.php';
includes/admin/core/packages/2.0-beta1/init.php CHANGED
@@ -13,11 +13,12 @@
13
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Styles...', 'ultimate-member' ) ) ?>' );
14
15
jQuery.ajax({
16
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
17
type: 'POST',
18
dataType: 'json',
19
data: {
20
- action: 'um_styles20beta1'
21
},
22
success: function( response ) {
23
if ( typeof response.data != 'undefined' ) {
@@ -36,11 +37,12 @@
36
function upgrade_roles() {
37
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Roles...', 'ultimate-member' ) ) ?>' );
38
jQuery.ajax({
39
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
40
type: 'POST',
41
dataType: 'json',
42
data: {
43
- action: 'um_user_roles20beta1'
44
},
45
success: function( response ) {
46
if ( typeof response.data != 'undefined' ) {
@@ -70,12 +72,13 @@
70
var role = um_roles_data.shift();
71
um_add_upgrade_log( '<?php echo esc_js( __( 'Getting ', 'ultimate-member' ) ) ?>"' + role.role_key + '"<?php echo esc_js( __( ' users...', 'ultimate-member' ) ) ?>' );
72
jQuery.ajax({
73
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
74
type: 'POST',
75
dataType: 'json',
76
data: {
77
action: 'um_get_users_per_role20beta1',
78
- key_in_meta: role.key_in_meta
79
},
80
success: function( response ) {
81
if ( typeof response.data.count != 'undefined' ) {
@@ -103,14 +106,15 @@
103
function update_user_per_page( role_key, key_in_meta ) {
104
if ( current_page <= users_pages ) {
105
jQuery.ajax({
106
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
107
type: 'POST',
108
dataType: 'json',
109
data: {
110
action: 'um_update_users_per_page20beta1',
111
role_key: role_key,
112
key_in_meta: key_in_meta,
113
- page: current_page
114
},
115
success: function( response ) {
116
if ( typeof response.data != 'undefined' ) {
@@ -135,11 +139,12 @@
135
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Content Restriction Settings...', 'ultimate-member' ) ) ?>' );
136
137
jQuery.ajax({
138
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
139
type: 'POST',
140
dataType: 'json',
141
data: {
142
- action: 'um_content_restriction20beta1'
143
},
144
success: function( response ) {
145
if ( typeof response.data != 'undefined' ) {
@@ -160,11 +165,12 @@
160
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Settings...', 'ultimate-member' ) ) ?>' );
161
162
jQuery.ajax({
163
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
164
type: 'POST',
165
dataType: 'json',
166
data: {
167
- action: 'um_settings20beta1'
168
},
169
success: function( response ) {
170
if ( typeof response.data != 'undefined' ) {
@@ -185,11 +191,12 @@
185
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Menu Items...', 'ultimate-member' ) ) ?>' );
186
187
jQuery.ajax({
188
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
189
type: 'POST',
190
dataType: 'json',
191
data: {
192
- action: 'um_menus20beta1'
193
},
194
success: function( response ) {
195
if ( typeof response.data != 'undefined' ) {
@@ -210,11 +217,12 @@
210
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Mailchimp Lists...', 'ultimate-member' ) ) ?>' );
211
212
jQuery.ajax({
213
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
214
type: 'POST',
215
dataType: 'json',
216
data: {
217
- action: 'um_mc_lists20beta1'
218
},
219
success: function( response ) {
220
if ( typeof response.data != 'undefined' ) {
@@ -235,11 +243,12 @@
235
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Social Login Forms...', 'ultimate-member' ) ) ?>' );
236
237
jQuery.ajax({
238
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
239
type: 'POST',
240
dataType: 'json',
241
data: {
242
- action: 'um_social_login20beta1'
243
},
244
success: function( response ) {
245
if ( typeof response.data != 'undefined' ) {
@@ -260,11 +269,12 @@
260
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade UM Custom Post Types...', 'ultimate-member' ) ) ?>' );
261
262
jQuery.ajax({
263
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
264
type: 'POST',
265
dataType: 'json',
266
data: {
267
- action: 'um_cpt20beta1'
268
},
269
success: function( response ) {
270
if ( typeof response.data != 'undefined' ) {
@@ -286,11 +296,12 @@
286
um_add_upgrade_log( '<?php echo esc_js( __( 'Get bbPress Forums count...', 'ultimate-member' ) ) ?>' );
287
current_page = 1;
288
jQuery.ajax({
289
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
290
type: 'POST',
291
dataType: 'json',
292
data: {
293
- action: 'um_get_forums20beta1'
294
},
295
success: function( response ) {
296
if ( typeof response.data != 'undefined' ) {
@@ -313,12 +324,13 @@
313
function update_forums_per_page() {
314
if ( current_page <= forums_pages ) {
315
jQuery.ajax({
316
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
317
type: 'POST',
318
dataType: 'json',
319
data: {
320
action: 'um_update_forum_per_page20beta1',
321
- page: current_page
322
},
323
success: function( response ) {
324
if ( typeof response.data != 'undefined' ) {
@@ -346,11 +358,12 @@
346
current_page = 1;
347
348
jQuery.ajax({
349
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
350
type: 'POST',
351
dataType: 'json',
352
data: {
353
- action: 'um_get_products20beta1'
354
},
355
success: function( response ) {
356
if ( typeof response.data != 'undefined' ) {
@@ -373,12 +386,13 @@
373
function update_products_per_page() {
374
if ( current_page <= products_pages ) {
375
jQuery.ajax({
376
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
377
type: 'POST',
378
dataType: 'json',
379
data: {
380
action: 'um_update_products_per_page20beta1',
381
- page: current_page
382
},
383
success: function( response ) {
384
if ( typeof response.data != 'undefined' ) {
@@ -402,11 +416,12 @@
402
function upgrade_email_templates() {
403
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Email Templates...', 'ultimate-member' ) ) ?>' );
404
jQuery.ajax({
405
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
406
type: 'POST',
407
dataType: 'json',
408
data: {
409
- action: 'um_email_templates20beta1'
410
},
411
success: function( response ) {
412
if ( typeof response.data != 'undefined' ) {
13
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Styles...', 'ultimate-member' ) ) ?>' );
14
15
jQuery.ajax({
16
+ url: wp.ajax.settings.url,
17
type: 'POST',
18
dataType: 'json',
19
data: {
20
+ action: 'um_styles20beta1',
21
+ nonce: um_admin_scripts.nonce
22
},
23
success: function( response ) {
24
if ( typeof response.data != 'undefined' ) {
37
function upgrade_roles() {
38
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Roles...', 'ultimate-member' ) ) ?>' );
39
jQuery.ajax({
40
+ url: wp.ajax.settings.url,
41
type: 'POST',
42
dataType: 'json',
43
data: {
44
+ action: 'um_user_roles20beta1',
45
+ nonce: um_admin_scripts.nonce
46
},
47
success: function( response ) {
48
if ( typeof response.data != 'undefined' ) {
72
var role = um_roles_data.shift();
73
um_add_upgrade_log( '<?php echo esc_js( __( 'Getting ', 'ultimate-member' ) ) ?>"' + role.role_key + '"<?php echo esc_js( __( ' users...', 'ultimate-member' ) ) ?>' );
74
jQuery.ajax({
75
+ url: wp.ajax.settings.url,
76
type: 'POST',
77
dataType: 'json',
78
data: {
79
action: 'um_get_users_per_role20beta1',
80
+ key_in_meta: role.key_in_meta,
81
+ nonce: um_admin_scripts.nonce
82
},
83
success: function( response ) {
84
if ( typeof response.data.count != 'undefined' ) {
106
function update_user_per_page( role_key, key_in_meta ) {
107
if ( current_page <= users_pages ) {
108
jQuery.ajax({
109
+ url: wp.ajax.settings.url,
110
type: 'POST',
111
dataType: 'json',
112
data: {
113
action: 'um_update_users_per_page20beta1',
114
role_key: role_key,
115
key_in_meta: key_in_meta,
116
+ page: current_page,
117
+ nonce: um_admin_scripts.nonce
118
},
119
success: function( response ) {
120
if ( typeof response.data != 'undefined' ) {
139
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Content Restriction Settings...', 'ultimate-member' ) ) ?>' );
140
141
jQuery.ajax({
142
+ url: wp.ajax.settings.url,
143
type: 'POST',
144
dataType: 'json',
145
data: {
146
+ action: 'um_content_restriction20beta1',
147
+ nonce: um_admin_scripts.nonce
148
},
149
success: function( response ) {
150
if ( typeof response.data != 'undefined' ) {
165
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Settings...', 'ultimate-member' ) ) ?>' );
166
167
jQuery.ajax({
168
+ url: wp.ajax.settings.url,
169
type: 'POST',
170
dataType: 'json',
171
data: {
172
+ action: 'um_settings20beta1',
173
+ nonce: um_admin_scripts.nonce
174
},
175
success: function( response ) {
176
if ( typeof response.data != 'undefined' ) {
191
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Menu Items...', 'ultimate-member' ) ) ?>' );
192
193
jQuery.ajax({
194
+ url: wp.ajax.settings.url,
195
type: 'POST',
196
dataType: 'json',
197
data: {
198
+ action: 'um_menus20beta1',
199
+ nonce: um_admin_scripts.nonce
200
},
201
success: function( response ) {
202
if ( typeof response.data != 'undefined' ) {
217
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Mailchimp Lists...', 'ultimate-member' ) ) ?>' );
218
219
jQuery.ajax({
220
+ url: wp.ajax.settings.url,
221
type: 'POST',
222
dataType: 'json',
223
data: {
224
+ action: 'um_mc_lists20beta1',
225
+ nonce: um_admin_scripts.nonce
226
},
227
success: function( response ) {
228
if ( typeof response.data != 'undefined' ) {
243
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Social Login Forms...', 'ultimate-member' ) ) ?>' );
244
245
jQuery.ajax({
246
+ url: wp.ajax.settings.url,
247
type: 'POST',
248
dataType: 'json',
249
data: {
250
+ action: 'um_social_login20beta1',
251
+ nonce: um_admin_scripts.nonce
252
},
253
success: function( response ) {
254
if ( typeof response.data != 'undefined' ) {
269
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade UM Custom Post Types...', 'ultimate-member' ) ) ?>' );
270
271
jQuery.ajax({
272
+ url: wp.ajax.settings.url,
273
type: 'POST',
274
dataType: 'json',
275
data: {
276
+ action: 'um_cpt20beta1',
277
+ nonce: um_admin_scripts.nonce
278
},
279
success: function( response ) {
280
if ( typeof response.data != 'undefined' ) {
296
um_add_upgrade_log( '<?php echo esc_js( __( 'Get bbPress Forums count...', 'ultimate-member' ) ) ?>' );
297
current_page = 1;
298
jQuery.ajax({
299
+ url: wp.ajax.settings.url,
300
type: 'POST',
301
dataType: 'json',
302
data: {
303
+ action: 'um_get_forums20beta1',
304
+ nonce: um_admin_scripts.nonce
305
},
306
success: function( response ) {
307
if ( typeof response.data != 'undefined' ) {
324
function update_forums_per_page() {
325
if ( current_page <= forums_pages ) {
326
jQuery.ajax({
327
+ url: wp.ajax.settings.url,
328
type: 'POST',
329
dataType: 'json',
330
data: {
331
action: 'um_update_forum_per_page20beta1',
332
+ page: current_page,
333
+ nonce: um_admin_scripts.nonce
334
},
335
success: function( response ) {
336
if ( typeof response.data != 'undefined' ) {
358
current_page = 1;
359
360
jQuery.ajax({
361
+ url: wp.ajax.settings.url,
362
type: 'POST',
363
dataType: 'json',
364
data: {
365
+ action: 'um_get_products20beta1',
366
+ nonce: um_admin_scripts.nonce
367
},
368
success: function( response ) {
369
if ( typeof response.data != 'undefined' ) {
386
function update_products_per_page() {
387
if ( current_page <= products_pages ) {
388
jQuery.ajax({
389
+ url: wp.ajax.settings.url,
390
type: 'POST',
391
dataType: 'json',
392
data: {
393
action: 'um_update_products_per_page20beta1',
394
+ page: current_page,
395
+ nonce: um_admin_scripts.nonce
396
},
397
success: function( response ) {
398
if ( typeof response.data != 'undefined' ) {
416
function upgrade_email_templates() {
417
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Email Templates...', 'ultimate-member' ) ) ?>' );
418
jQuery.ajax({
419
+ url: wp.ajax.settings.url,
420
type: 'POST',
421
dataType: 'json',
422
data: {
423
+ action: 'um_email_templates20beta1',
424
+ nonce: um_admin_scripts.nonce
425
},
426
success: function( response ) {
427
if ( typeof response.data != 'undefined' ) {
includes/admin/core/packages/2.0.10/functions.php CHANGED
@@ -1,5 +1,7 @@
1
<?php
2
function um_upgrade_styles2010() {
3
um_maybe_unset_time_limit();
4
5
include 'styles.php';
@@ -8,6 +10,8 @@ function um_upgrade_styles2010() {
8
9
10
function um_upgrade_cache2010() {
11
um_maybe_unset_time_limit();
12
13
UM()->user()->remove_cache_all_users();
1
<?php
2
function um_upgrade_styles2010() {
3
+ UM()->admin()->check_ajax_nonce();
4
+
5
um_maybe_unset_time_limit();
6
7
include 'styles.php';
10
11
12
function um_upgrade_cache2010() {
13
+ UM()->admin()->check_ajax_nonce();
14
+
15
um_maybe_unset_time_limit();
16
17
UM()->user()->remove_cache_all_users();
includes/admin/core/packages/2.0.10/init.php CHANGED
@@ -6,11 +6,12 @@
6
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Styles...', 'ultimate-member' ) ) ?>' );
7
8
jQuery.ajax({
9
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
10
type: 'POST',
11
dataType: 'json',
12
data: {
13
- action: 'um_styles2010'
14
},
15
success: function( response ) {
16
if ( typeof response.data != 'undefined' ) {
@@ -30,11 +31,12 @@
30
function um_clear_cache2010() {
31
um_add_upgrade_log( '<?php echo esc_js( __( 'Clear Users Cache...', 'ultimate-member' ) ) ?>' );
32
jQuery.ajax({
33
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
34
type: 'POST',
35
dataType: 'json',
36
data: {
37
- action: 'um_cache2010'
38
},
39
success: function( response ) {
40
if ( typeof response.data != 'undefined' ) {
6
um_add_upgrade_log( '<?php echo esc_js( __( 'Upgrade Styles...', 'ultimate-member' ) ) ?>' );
7
8
jQuery.ajax({
9
+ url: wp.ajax.settings.url,
10
type: 'POST',
11
dataType: 'json',
12
data: {
13
+ action: 'um_styles2010',
14
+ nonce: um_admin_scripts.nonce
15
},
16
success: function( response ) {
17
if ( typeof response.data != 'undefined' ) {
31
function um_clear_cache2010() {
32
um_add_upgrade_log( '<?php echo esc_js( __( 'Clear Users Cache...', 'ultimate-member' ) ) ?>' );
33
jQuery.ajax({
34
+ url: wp.ajax.settings.url,
35
type: 'POST',
36
dataType: 'json',
37
data: {
38
+ action: 'um_cache2010',
39
+ nonce: um_admin_scripts.nonce
40
},
41
success: function( response ) {
42
if ( typeof response.data != 'undefined' ) {
includes/admin/core/packages/2.0.24/functions.php CHANGED
@@ -1,5 +1,7 @@
1
<?php
2
function um_upgrade_tempfolder2024() {
3
um_maybe_unset_time_limit();
4
5
UM()->files()->remove_dir( UM()->files()->upload_temp );
1
<?php
2
function um_upgrade_tempfolder2024() {
3
+ UM()->admin()->check_ajax_nonce();
4
+
5
um_maybe_unset_time_limit();
6
7
UM()->files()->remove_dir( UM()->files()->upload_temp );
includes/admin/core/packages/2.0.24/init.php CHANGED
@@ -6,11 +6,12 @@
6
um_add_upgrade_log( '<?php echo esc_js( __( 'Purge temp files dir...', 'ultimate-member' ) ) ?>' );
7
8
jQuery.ajax({
9
- url: '<?php echo admin_url( 'admin-ajax.php' ) ?>',
10
type: 'POST',
11
dataType: 'json',
12
data: {
13
- action: 'um_tempfolder2024'
14
},
15
success: function( response ) {
16
if ( typeof response.data != 'undefined' ) {
6
um_add_upgrade_log( '<?php echo esc_js( __( 'Purge temp files dir...', 'ultimate-member' ) ) ?>' );
7
8
jQuery.ajax({
9
+ url: wp.ajax.settings.url,
10
type: 'POST',
11
dataType: 'json',
12
data: {
13
+ action: 'um_tempfolder2024',
14
+ nonce: um_admin_scripts.nonce
15
},
16
success: function( response ) {
17
if ( typeof response.data != 'undefined' ) {
includes/admin/templates/dashboard/language-contrib.php DELETED
@@ -1,7 +0,0 @@
1
- <p>
2
- <?php printf( __( 'Ultimate Member is not yet available in your language: <strong>%1$s</strong>.', 'ultimate-member' ), $locale ); ?>
3
- </p>
4
-
5
- <p>
6
- <?php _e( 'If you want to contribute this translation to the plugin, please add it on our <a href="https://ultimatemember.com/forums/">community forum</a>.', 'ultimate-member' ); ?>
7
- </p>
includes/admin/templates/modal/dynamic_edit_field.php CHANGED
@@ -11,6 +11,7 @@
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Update','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
<a href="#" data-action="UM_remove_modal" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
15
</div>
16
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Update','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
+ <input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'um-admin-nonce' ) ?>" />
15
<a href="#" data-action="UM_remove_modal" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
16
</div>
17
includes/admin/templates/modal/dynamic_edit_row.php CHANGED
@@ -11,6 +11,7 @@
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Update','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
<a href="#" data-action="UM_remove_modal" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
15
</div>
16
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Update','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
+ <input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'um-admin-nonce' ) ?>" />
15
<a href="#" data-action="UM_remove_modal" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
16
</div>
17
includes/admin/templates/modal/dynamic_new_divider.php CHANGED
@@ -11,6 +11,7 @@
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Add','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
<a href="#" data-action="UM_remove_modal" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
15
</div>
16
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Add','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
+ <input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'um-admin-nonce' ) ?>" />
15
<a href="#" data-action="UM_remove_modal" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
16
</div>
17
includes/admin/templates/modal/dynamic_new_field.php CHANGED
@@ -11,6 +11,7 @@
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Add','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
<a href="#" data-modal="UM_fields" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
15
</div>
16
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Add','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
+ <input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'um-admin-nonce' ) ?>" />
15
<a href="#" data-modal="UM_fields" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
16
</div>
17
includes/admin/templates/modal/dynamic_new_group.php CHANGED
@@ -11,6 +11,7 @@
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Add','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
<a href="#" data-action="UM_remove_modal" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
15
</div>
16
11
<div class="um-admin-modal-foot">
12
<input type="submit" value="<?php _e('Add','ultimate-member'); ?>" class="button-primary" />
13
<input type="hidden" name="action" value="um_update_field" />
14
+ <input type="hidden" name="nonce" value="<?php echo wp_create_nonce( 'um-admin-nonce' ) ?>" />
15
<a href="#" data-action="UM_remove_modal" class="button"><?php _e('Cancel','ultimate-member'); ?></a>
16
</div>
17
includes/class-functions.php CHANGED
@@ -16,6 +16,21 @@ if ( ! class_exists( 'UM_Functions' ) ) {
16
}
17
18
19
/**
20
* What type of request is this?
21
*
16
}
17
18
19
+ /**
20
+ * Check frontend nonce
21
+ *
22
+ * @param bool $action
23
+ */
24
+ function check_ajax_nonce( $action = false ) {
25
+ $nonce = isset( $_POST['nonce'] ) ? $_POST['nonce'] : '';
26
+ $action = empty( $action ) ? 'um-frontend-nonce' : $action;
27
+
28
+ if ( ! wp_verify_nonce( $nonce, $action ) ) {
29
+ wp_send_json_error( esc_js( __( 'Wrong Nonce', 'ultimate-member' ) ) );
30
+ }
31
+ }
32
+
33
+
34
/**
35
* What type of request is this?
36
*
includes/core/class-enqueue.php CHANGED
@@ -129,7 +129,9 @@ if ( ! class_exists( 'um\core\Enqueue' ) ) {
129
* }
130
* ?>
131
*/
132
- $localize_data = apply_filters( 'um_enqueue_localize_data', array() );
133
wp_localize_script( 'um_scripts', 'um_scripts', $localize_data );
134
135
wp_register_script('um_members', $this->js_baseurl . 'um-members' . $this->suffix . '.js', array( 'jquery' ), ultimatemember_version, true );
129
* }
130
* ?>
131
*/
132
+ $localize_data = apply_filters( 'um_enqueue_localize_data', array(
133
+ 'nonce' => wp_create_nonce( "um-frontend-nonce" ),
134
+ ) );
135
wp_localize_script( 'um_scripts', 'um_scripts', $localize_data );
136
137
wp_register_script('um_members', $this->js_baseurl . 'um-members' . $this->suffix . '.js', array( 'jquery' ), ultimatemember_version, true );
includes/core/class-fields.php CHANGED
@@ -4059,21 +4059,25 @@ if ( ! class_exists( 'um\core\Fields' ) ) {
4059
*
4060
*/
4061
function do_ajax_action() {
4062
- if (!is_user_logged_in() || !current_user_can( 'manage_options' )) die( __( 'Please login as administrator', 'ultimate-member' ) );
4063
4064
extract( $_POST );
4065
4066
$output = null;
4067
4068
$position = array();
4069
- if (!empty( $in_column )) {
4070
$position['in_row'] = '_um_row_' . ( (int)$in_row + 1 );
4071
$position['in_sub_row'] = $in_sub_row;
4072
$position['in_column'] = $in_column;
4073
$position['in_group'] = $in_group;
4074
}
4075
4076
- switch ($act_id) {
4077
4078
case 'um_admin_duplicate_field':
4079
$this->duplicate_field( $arg1, $arg2 );
4059
*
4060
*/
4061
function do_ajax_action() {
4062
+ UM()->admin()->check_ajax_nonce();
4063
+
4064
+ if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) ) {
4065
+ wp_send_json_error( __( 'Please login as administrator', 'ultimate-member' ) );
4066
+ }
4067
4068
extract( $_POST );
4069
4070
$output = null;
4071
4072
$position = array();
4073
+ if ( ! empty( $in_column ) ) {
4074
$position['in_row'] = '_um_row_' . ( (int)$in_row + 1 );
4075
$position['in_sub_row'] = $in_sub_row;
4076
$position['in_column'] = $in_column;
4077
$position['in_group'] = $in_group;
4078
}
4079
4080
+ switch ( $act_id ) {
4081
4082
case 'um_admin_duplicate_field':
4083
$this->duplicate_field( $arg1, $arg2 );
includes/core/class-files.php CHANGED
@@ -241,6 +241,8 @@ if ( ! class_exists( 'um\core\Files' ) ) {
241
* Remove file by AJAX
242
*/
243
function ajax_remove_file() {
244
/**
245
* @var $src
246
*/
@@ -255,6 +257,8 @@ if ( ! class_exists( 'um\core\Files' ) ) {
255
* Resize image AJAX handler
256
*/
257
function ajax_resize_image() {
258
/**
259
* @var $key
260
* @var $src
241
* Remove file by AJAX
242
*/
243
function ajax_remove_file() {
244
+ UM()->check_ajax_nonce();
245
+
246
/**
247
* @var $src
248
*/
257
* Resize image AJAX handler
258
*/
259
function ajax_resize_image() {
260
+ UM()->check_ajax_nonce();
261
+
262
/**
263
* @var $key
264
* @var $src
includes/core/class-form.php CHANGED
@@ -50,6 +50,8 @@ if ( ! class_exists( 'um\core\Form' ) ) {
50
*
51
*/
52
function ajax_muted_action() {
53
extract( $_REQUEST );
54
55
if ( ! UM()->roles()->um_current_user_can( 'edit', $user_id ) )
@@ -86,7 +88,7 @@ if ( ! class_exists( 'um\core\Form' ) ) {
86
*
87
*/
88
function ajax_select_options() {
89
-
90
91
$arr_options = array();
92
$arr_options['status'] = 'success';
50
*
51
*/
52
function ajax_muted_action() {
53
+ UM()->check_ajax_nonce();
54
+
55
extract( $_REQUEST );
56
57
if ( ! UM()->roles()->um_current_user_can( 'edit', $user_id ) )
88
*
89
*/
90
function ajax_select_options() {
91
+ UM()->check_ajax_nonce();
92
93
$arr_options = array();
94
$arr_options['status'] = 'success';
includes/core/class-profile.php CHANGED
@@ -45,6 +45,8 @@ if ( ! class_exists( 'um\core\Profile' ) ) {
45
* Delete profile avatar AJAX handler
46
*/
47
function ajax_delete_profile_photo() {
48
/**
49
* @var $user_id
50
*/
@@ -61,6 +63,8 @@ if ( ! class_exists( 'um\core\Profile' ) ) {
61
* Delete cover photo AJAX handler
62
*/
63
function ajax_delete_cover_photo() {
64
/**
65
* @var $user_id
66
*/
@@ -218,7 +222,7 @@ if ( ! class_exists( 'um\core\Profile' ) ) {
218
*/
219
function can_view_tab( $tab ) {
220
221
- $target_id = UM()->user()->target_id;
222
if ( empty( $target_id ) ) {
223
return true;
224
}
45
* Delete profile avatar AJAX handler
46
*/
47
function ajax_delete_profile_photo() {
48
+ UM()->check_ajax_nonce();
49
+
50
/**
51
* @var $user_id
52
*/
63
* Delete cover photo AJAX handler
64
*/
65
function ajax_delete_cover_photo() {
66
+ UM()->check_ajax_nonce();
67
+
68
/**
69
* @var $user_id
70
*/
222
*/
223
function can_view_tab( $tab ) {
224
225
+ $target_id = (int) UM()->user()->target_id;
226
if ( empty( $target_id ) ) {
227
return true;
228
}
includes/core/class-query.php CHANGED
@@ -39,6 +39,8 @@ if ( ! class_exists( 'um\core\Query' ) ) {
39
* Ajax pagination for posts
40
*/
41
function ajax_paginate() {
42
/**
43
* @var $hook
44
* @var $args
39
* Ajax pagination for posts
40
*/
41
function ajax_paginate() {
42
+ UM()->check_ajax_nonce();
43
+
44
/**
45
* @var $hook
46
* @var $args
includes/core/class-user-posts.php CHANGED
@@ -82,6 +82,8 @@ if ( ! class_exists( 'um\core\User_posts' ) ) {
82
*
83
*/
84
function load_posts() {
85
$author = ! empty( $_POST['author'] ) ? $_POST['author'] : get_current_user_id();
86
$page = ! empty( $_POST['page'] ) ? $_POST['page'] : 0;
87
82
*
83
*/
84
function load_posts() {
85
+ UM()->check_ajax_nonce();
86
+
87
$author = ! empty( $_POST['author'] ) ? $_POST['author'] : get_current_user_id();
88
$page = ! empty( $_POST['page'] ) ? $_POST['page'] : 0;
89
includes/core/class-user.php CHANGED
@@ -87,8 +87,11 @@ if ( ! class_exists( 'um\core\User' ) ) {
87
88
add_action( 'init', array( &$this, 'check_membership' ), 10 );
89
90
- add_action( 'delete_user', array( &$this, 'delete_user_handler' ), 10, 1 );
91
- add_action( 'wpmu_delete_user', array( &$this, 'delete_user_handler' ), 10, 1 );
92
}
93
94
@@ -96,6 +99,8 @@ if ( ! class_exists( 'um\core\User' ) ) {
96
* @param $user_id
97
*/
98
function delete_user_handler( $user_id ) {
99
100
um_fetch_user( $user_id );
101
87
88
add_action( 'init', array( &$this, 'check_membership' ), 10 );
89
90
+ if ( is_multisite() ) {
91
+ add_action( 'delete_user', array( &$this, 'delete_user_handler' ), 10, 1 );
92
+ } else {
93
+ add_action( 'wpmu_delete_user', array( &$this, 'delete_user_handler' ), 10, 1 );
94
+ }
95
}
96
97
99
* @param $user_id
100
*/
101
function delete_user_handler( $user_id ) {
102
+ error_log( '----------------' );
103
+ error_log( $user_id );
104
105
um_fetch_user( $user_id );
106
includes/core/um-actions-ajax.php CHANGED
@@ -8,6 +8,8 @@ if ( ! defined( 'ABSPATH' ) ) exit;
8
* @return boolean
9
*/
10
function ultimatemember_check_username_exists() {
11
$username = isset($_REQUEST['username']) ? $_REQUEST['username'] : '';
12
$exists = username_exists( $username );
13
8
* @return boolean
9
*/
10
function ultimatemember_check_username_exists() {
11
+ UM()->check_ajax_nonce();
12
+
13
$username = isset($_REQUEST['username']) ? $_REQUEST['username'] : '';
14
$exists = username_exists( $username );
15
languages/ultimate-member-en_US.mo CHANGED
Binary file
languages/ultimate-member-en_US.po CHANGED
@@ -1,8 +1,8 @@
1
msgid ""
2
msgstr ""
3
"Project-Id-Version: Ultimate Member\n"
4
- "POT-Creation-Date: 2018-11-20 13:57+0200\n"
5
- "PO-Revision-Date: 2018-11-20 13:57+0200\n"
6
"Last-Translator: \n"
7
"Language-Team: \n"
8
"Language: en_US\n"
@@ -21,6 +21,10 @@ msgstr ""
21
"X-Poedit-SearchPath-0: .\n"
22
"X-Poedit-SearchPathExcluded-0: *.js\n"
23
24
#: includes/admin/class-admin.php:181
25
#, php-format
26
msgid "Duplicate of %s"
@@ -94,63 +98,66 @@ msgstr ""
94
msgid "Reset all rules"
95
msgstr ""
96
97
- #: includes/admin/core/class-admin-builder.php:401
98
- #: includes/admin/core/class-admin-builder.php:471
99
- #: includes/admin/core/class-admin-dragdrop.php:161
100
- msgid "Add Row"
101
msgstr ""
102
103
#: includes/admin/core/class-admin-builder.php:402
104
#: includes/admin/core/class-admin-builder.php:472
105
- #: includes/admin/core/class-admin-dragdrop.php:162
106
- msgid "Edit Row"
107
msgstr ""
108
109
- #: includes/admin/core/class-admin-builder.php:475
110
#: includes/admin/core/class-admin-dragdrop.php:164
111
- #: includes/admin/core/class-admin-dragdrop.php:178
112
- #: includes/admin/core/class-admin-dragdrop.php:203
113
- msgid "Delete Row"
114
msgstr ""
115
116
- #: includes/admin/core/class-admin-builder.php:609
117
- #: includes/admin/core/class-admin-builder.php:763
118
- #: includes/core/class-fields.php:4062
119
- msgid "Please login as administrator"
120
msgstr ""
121
122
- #: includes/admin/core/class-admin-builder.php:827
123
msgid "Search Icons..."
124
msgstr ""
125
126
- #: includes/admin/core/class-admin-builder.php:847
127
msgid "Setup New Field"
128
msgstr ""
129
130
- #: includes/admin/core/class-admin-builder.php:863
131
msgid "Predefined Fields"
132
msgstr ""
133
134
- #: includes/admin/core/class-admin-builder.php:874
135
#: includes/core/class-builtin.php:1308
136
msgid "None"
137
msgstr ""
138
139
- #: includes/admin/core/class-admin-builder.php:878
140
msgid "Custom Fields"
141
msgstr ""
142
143
- #: includes/admin/core/class-admin-builder.php:889
144
msgid "You did not create any custom fields"
145
msgstr ""
146
147
- #: includes/admin/core/class-admin-builder.php:920
148
- #: includes/admin/core/class-admin-builder.php:992
149
msgid "This field type is not setup correcty."
150
msgstr ""
151
152
- #: includes/admin/core/class-admin-builder.php:1137
153
- #: includes/core/class-form.php:153 includes/core/class-form.php:326
154
#: includes/core/class-password.php:518
155
msgid "This is not possible for security reasons."
156
msgstr ""
@@ -371,65 +378,65 @@ msgid ""
371
"help us to grow the plugin and make it more popular. Thank you."
372
msgstr ""
373
374
- #: includes/admin/core/class-admin-menu.php:118
375
msgctxt "Admin menu name"
376
msgid "Users"
377
msgstr ""
378
379
- #: includes/admin/core/class-admin-menu.php:126
380
msgctxt "Admin menu name"
381
msgid "All Users"
382
msgstr ""
383
384
#. Plugin Name of the plugin/theme
385
#. Author of the plugin/theme
386
- #: includes/admin/core/class-admin-menu.php:138
387
- #: includes/core/class-user.php:552
388
msgid "Ultimate Member"
389
msgstr ""
390
391
- #: includes/admin/core/class-admin-menu.php:142
392
msgid "Dashboard"
393
msgstr ""
394
395
- #: includes/admin/core/class-admin-menu.php:150
396
#: includes/admin/templates/gdpr.php:7 includes/core/class-common.php:56
397
msgid "Forms"
398
msgstr ""
399
400
- #: includes/admin/core/class-admin-menu.php:152
401
#: includes/admin/core/list-tables/roles-list-table.php:477
402
#: includes/admin/core/packages/2.0-beta1/user_roles.php:12
403
msgid "User Roles"
404
msgstr ""
405
406
- #: includes/admin/core/class-admin-menu.php:155
407
#: includes/core/class-common.php:85
408
msgid "Member Directories"
409
msgstr ""
410
411
- #: includes/admin/core/class-admin-menu.php:197
412
#: includes/admin/core/class-admin-settings.php:1007
413
msgid "Extensions"
414
msgstr ""
415
416
- #: includes/admin/core/class-admin-menu.php:210
417
msgid "Users Overview"
418
msgstr ""
419
420
- #: includes/admin/core/class-admin-menu.php:212
421
msgid "Latest from our blog"
422
msgstr ""
423
424
- #: includes/admin/core/class-admin-menu.php:214
425
msgid "Purge Temp Files"
426
msgstr ""
427
428
- #: includes/admin/core/class-admin-menu.php:216
429
msgid "User Cache"
430
msgstr ""
431
432
- #: includes/admin/core/class-admin-menu.php:221
433
msgid "Upgrade's Manual Request"
434
msgstr ""
435
@@ -1305,11 +1312,7 @@ msgid ""
1305
"target=\"_blank\">here</a>"
1306
msgstr ""
1307
1308
- #: includes/admin/core/class-admin-notices.php:671
1309
- msgid "Wrong Nonce"
1310
- msgstr ""
1311
-
1312
- #: includes/admin/core/class-admin-notices.php:676
1313
msgid "Wrong Data"
1314
msgstr ""
1315
@@ -2549,7 +2552,7 @@ msgstr ""
2549
2550
#: includes/admin/core/class-admin-users.php:305
2551
#: includes/admin/templates/dashboard/users.php:11
2552
- #: includes/core/class-user.php:816
2553
msgid "Approved"
2554
msgstr ""
2555
@@ -2672,59 +2675,59 @@ msgstr ""
2672
msgid "User Role <strong>Deleted</strong> Successfully."
2673
msgstr ""
2674
2675
- #: includes/admin/core/packages/2.0-beta1/functions.php:6
2676
- #: includes/admin/core/packages/2.0.10/functions.php:6
2677
msgid "Styles was upgraded successfully"
2678
msgstr ""
2679
2680
- #: includes/admin/core/packages/2.0-beta1/functions.php:17
2681
msgid "User Roles was upgraded successfully"
2682
msgstr ""
2683
2684
- #: includes/admin/core/packages/2.0-beta1/functions.php:80
2685
#, php-format
2686
msgid "Users from %s to %s was upgraded successfully..."
2687
msgstr ""
2688
2689
- #: includes/admin/core/packages/2.0-beta1/functions.php:100
2690
msgid "Settings was upgraded successfully"
2691
msgstr ""
2692
2693
- #: includes/admin/core/packages/2.0-beta1/functions.php:108
2694
msgid "Menus settings was upgraded successfully"
2695
msgstr ""
2696
2697
- #: includes/admin/core/packages/2.0-beta1/functions.php:116
2698
msgid "Mailchimp Lists was upgraded successfully"
2699
msgstr ""
2700
2701
- #: includes/admin/core/packages/2.0-beta1/functions.php:124
2702
msgid "Social login forms was upgraded successfully"
2703
msgstr ""
2704
2705
- #: includes/admin/core/packages/2.0-beta1/functions.php:132
2706
msgid "UM Custom Posts was upgraded successfully"
2707
msgstr ""
2708
2709
- #: includes/admin/core/packages/2.0-beta1/functions.php:147
2710
msgid "Forums are ready for upgrade"
2711
msgstr ""
2712
2713
- #: includes/admin/core/packages/2.0-beta1/functions.php:200
2714
#, php-format
2715
msgid "Forums from %s to %s was upgraded successfully..."
2716
msgstr ""
2717
2718
- #: includes/admin/core/packages/2.0-beta1/functions.php:216
2719
msgid "Woocommerce Products are ready for upgrade"
2720
msgstr ""
2721
2722
- #: includes/admin/core/packages/2.0-beta1/functions.php:290
2723
#, php-format
2724
msgid "Woocommerce Products from %s to %s was upgraded successfully..."
2725
msgstr ""
2726
2727
- #: includes/admin/core/packages/2.0-beta1/functions.php:306
2728
msgid "Email Templates was upgraded successfully"
2729
msgstr ""
2730
@@ -2733,72 +2736,72 @@ msgstr ""
2733
msgid "Upgrade Styles..."
2734
msgstr ""
2735
2736
- #: includes/admin/core/packages/2.0-beta1/init.php:37
2737
msgid "Upgrade Roles..."
2738
msgstr ""
2739
2740
- #: includes/admin/core/packages/2.0-beta1/init.php:50
2741
msgid "Upgrade Users..."
2742
msgstr ""
2743
2744
- #: includes/admin/core/packages/2.0-beta1/init.php:71
2745
msgid "Getting "
2746
msgstr ""
2747
2748
- #: includes/admin/core/packages/2.0-beta1/init.php:71
2749
- #: includes/admin/core/packages/2.0-beta1/init.php:82
2750
msgid " users..."
2751
msgstr ""
2752
2753
- #: includes/admin/core/packages/2.0-beta1/init.php:82
2754
msgid "There are "
2755
msgstr ""
2756
2757
- #: includes/admin/core/packages/2.0-beta1/init.php:83
2758
msgid "Start users upgrading..."
2759
msgstr ""
2760
2761
- #: includes/admin/core/packages/2.0-beta1/init.php:135
2762
msgid "Upgrade Content Restriction Settings..."
2763
msgstr ""
2764
2765
- #: includes/admin/core/packages/2.0-beta1/init.php:160
2766
msgid "Upgrade Settings..."
2767
msgstr ""
2768
2769
- #: includes/admin/core/packages/2.0-beta1/init.php:185
2770
msgid "Upgrade Menu Items..."
2771
msgstr ""
2772
2773
- #: includes/admin/core/packages/2.0-beta1/init.php:210
2774
msgid "Upgrade Mailchimp Lists..."
2775
msgstr ""
2776
2777
- #: includes/admin/core/packages/2.0-beta1/init.php:235
2778
msgid "Upgrade Social Login Forms..."
2779
msgstr ""
2780
2781
- #: includes/admin/core/packages/2.0-beta1/init.php:260
2782
msgid "Upgrade UM Custom Post Types..."
2783
msgstr ""
2784
2785
- #: includes/admin/core/packages/2.0-beta1/init.php:285
2786
msgid "Upgrade bbPress Forums..."
2787
msgstr ""
2788
2789
- #: includes/admin/core/packages/2.0-beta1/init.php:286
2790
msgid "Get bbPress Forums count..."
2791
msgstr ""
2792
2793
- #: includes/admin/core/packages/2.0-beta1/init.php:343
2794
msgid "Upgrade Woocommerce Products..."
2795
msgstr ""
2796
2797
- #: includes/admin/core/packages/2.0-beta1/init.php:344
2798
msgid "Get all Products..."
2799
msgstr ""
2800
2801
- #: includes/admin/core/packages/2.0-beta1/init.php:403
2802
msgid "Upgrade Email Templates..."
2803
msgstr ""
2804
@@ -2827,15 +2830,15 @@ msgstr ""
2827
msgid "Search User Roles"
2828
msgstr ""
2829
2830
- #: includes/admin/core/packages/2.0.10/functions.php:17
2831
msgid "Users cache was cleared successfully"
2832
msgstr ""
2833
2834
- #: includes/admin/core/packages/2.0.10/init.php:31
2835
msgid "Clear Users Cache..."
2836
msgstr ""
2837
2838
- #: includes/admin/core/packages/2.0.24/functions.php:9
2839
msgid "Temporary dir was purged successfully"
2840
msgstr ""
2841
@@ -2856,18 +2859,6 @@ msgstr ""
2856
msgid "Latest From Ultimate Member"
2857
msgstr ""
2858
2859
- #: includes/admin/templates/dashboard/language-contrib.php:2
2860
- #, php-format
2861
- msgid ""
2862
- "Ultimate Member is not yet available in your language: <strong>%1$s</strong>."
2863
- msgstr ""
2864
-
2865
- #: includes/admin/templates/dashboard/language-contrib.php:6
2866
- msgid ""
2867
- "If you want to contribute this translation to the plugin, please add it on "
2868
- "our <a href=\"https://ultimatemember.com/forums/\">community forum</a>."
2869
- msgstr ""
2870
-
2871
#: includes/admin/templates/dashboard/purge.php:4
2872
#, php-format
2873
msgid ""
@@ -2896,12 +2887,12 @@ msgid "Get latest versions"
2896
msgstr ""
2897
2898
#: includes/admin/templates/dashboard/users.php:27
2899
- #: includes/core/class-user.php:824
2900
msgid "Pending Review"
2901
msgstr ""
2902
2903
#: includes/admin/templates/dashboard/users.php:32
2904
- #: includes/core/class-user.php:820
2905
msgid "Awaiting E-mail Confirmation"
2906
msgstr ""
2907
@@ -3485,11 +3476,11 @@ msgstr ""
3485
msgid "Update"
3486
msgstr ""
3487
3488
- #: includes/admin/templates/modal/dynamic_edit_field.php:14
3489
- #: includes/admin/templates/modal/dynamic_edit_row.php:14
3490
- #: includes/admin/templates/modal/dynamic_new_divider.php:14
3491
- #: includes/admin/templates/modal/dynamic_new_field.php:14
3492
- #: includes/admin/templates/modal/dynamic_new_group.php:14
3493
#: includes/admin/templates/modal/fonticons.php:11
3494
#: includes/admin/templates/role/publish.php:24
3495
#: includes/core/class-fields.php:2301 includes/core/class-fields.php:2398
@@ -4131,7 +4122,7 @@ msgstr ""
4131
msgid "You must add a shortcode to the content area"
4132
msgstr ""
4133
4134
- #: includes/core/class-builtin.php:663 includes/core/class-user.php:1538
4135
msgid "Only me"
4136
msgstr ""
4137
@@ -6290,40 +6281,40 @@ msgstr ""
6290
msgid "This user has not added any information to their profile yet."
6291
msgstr ""
6292
6293
- #: includes/core/class-files.php:267
6294
msgid "Invalid parameters"
6295
msgstr ""
6296
6297
- #: includes/core/class-files.php:272
6298
msgid "Invalid coordinates"
6299
msgstr ""
6300
6301
- #: includes/core/class-files.php:277
6302
msgid "Invalid file ownership"
6303
msgstr ""
6304
6305
- #: includes/core/class-files.php:330
6306
msgid "Invalid nonce"
6307
msgstr ""
6308
6309
- #: includes/core/class-files.php:350 includes/core/class-files.php:435
6310
msgid "A theme or plugin compatibility issue"
6311
msgstr ""
6312
6313
- #: includes/core/class-files.php:978
6314
msgid "Ultimate Member: Not a valid temp file"
6315
msgstr ""
6316
6317
- #: includes/core/class-files.php:1106
6318
msgid "Invalid user ID: "
6319
msgstr ""
6320
6321
- #: includes/core/class-files.php:1115 includes/core/class-files.php:1143
6322
msgid "Unauthorized to do this attempt."
6323
msgstr ""
6324
6325
- #: includes/core/class-form.php:56 includes/core/class-profile.php:54
6326
- #: includes/core/class-profile.php:70
6327
msgid "You can not edit this user"
6328
msgstr ""
6329
@@ -6385,15 +6376,15 @@ msgstr ""
6385
msgid "https://wordpress.org/support/"
6386
msgstr ""
6387
6388
- #: includes/core/class-profile.php:106
6389
msgid "About"
6390
msgstr ""
6391
6392
- #: includes/core/class-profile.php:110
6393
msgid "Posts"
6394
msgstr ""
6395
6396
- #: includes/core/class-profile.php:114
6397
msgid "Comments"
6398
msgstr ""
6399
@@ -6518,19 +6509,19 @@ msgstr ""
6518
msgid "Maximum file size allowed: %s"
6519
msgstr ""
6520
6521
- #: includes/core/class-user.php:610
6522
msgid "Ultimate Member Role"
6523
msgstr ""
6524
6525
- #: includes/core/class-user.php:613
6526
msgid "&mdash; No role for Ultimate Member &mdash;"
6527
msgstr ""
6528
6529
- #: includes/core/class-user.php:828
6530
msgid "Membership Rejected"
6531
msgstr ""
6532
6533
- #: includes/core/class-user.php:832
6534
msgid "Membership Inactive"
6535
msgstr ""
6536
1
msgid ""
2
msgstr ""
3
"Project-Id-Version: Ultimate Member\n"
4
+ "POT-Creation-Date: 2018-11-22 14:19+0200\n"
5
+ "PO-Revision-Date: 2018-11-22 14:19+0200\n"
6
"Last-Translator: \n"
7
"Language-Team: \n"
8
"Language: en_US\n"
21
"X-Poedit-SearchPath-0: .\n"
22
"X-Poedit-SearchPathExcluded-0: *.js\n"
23
24
+ #: includes/admin/class-admin-functions.php:35 includes/class-functions.php:29
25
+ msgid "Wrong Nonce"
26
+ msgstr ""
27
+
28
#: includes/admin/class-admin.php:181
29
#, php-format
30
msgid "Duplicate of %s"
98
msgid "Reset all rules"
99
msgstr ""
100
101
+ #: includes/admin/core/class-admin-builder.php:298
102
+ #: includes/admin/core/class-admin-builder.php:612
103
+ #: includes/admin/core/class-admin-builder.php:767
104
+ #: includes/admin/core/class-admin-dragdrop.php:32
105
+ #: includes/admin/core/class-admin-menu.php:105
106
+ #: includes/core/class-fields.php:4065
107
+ msgid "Please login as administrator"
108
msgstr ""
109
110
#: includes/admin/core/class-admin-builder.php:402
111
#: includes/admin/core/class-admin-builder.php:472
112
+ #: includes/admin/core/class-admin-dragdrop.php:163
113
+ msgid "Add Row"
114
msgstr ""
115
116
+ #: includes/admin/core/class-admin-builder.php:403
117
+ #: includes/admin/core/class-admin-builder.php:473
118
#: includes/admin/core/class-admin-dragdrop.php:164
119
+ msgid "Edit Row"
120
msgstr ""
121
122
+ #: includes/admin/core/class-admin-builder.php:476
123
+ #: includes/admin/core/class-admin-dragdrop.php:166
124
+ #: includes/admin/core/class-admin-dragdrop.php:180
125
+ #: includes/admin/core/class-admin-dragdrop.php:205
126
+ msgid "Delete Row"
127
msgstr ""
128
129
+ #: includes/admin/core/class-admin-builder.php:833
130
msgid "Search Icons..."
131
msgstr ""
132
133
+ #: includes/admin/core/class-admin-builder.php:853
134
msgid "Setup New Field"
135
msgstr ""
136
137
+ #: includes/admin/core/class-admin-builder.php:869
138
msgid "Predefined Fields"
139
msgstr ""
140
141
+ #: includes/admin/core/class-admin-builder.php:880
142
#: includes/core/class-builtin.php:1308
143
msgid "None"
144
msgstr ""
145
146
+ #: includes/admin/core/class-admin-builder.php:884
147
msgid "Custom Fields"
148
msgstr ""
149
150
+ #: includes/admin/core/class-admin-builder.php:895
151
msgid "You did not create any custom fields"
152
msgstr ""
153
154
+ #: includes/admin/core/class-admin-builder.php:926
155
+ #: includes/admin/core/class-admin-builder.php:998
156
msgid "This field type is not setup correcty."
157
msgstr ""
158
159
+ #: includes/admin/core/class-admin-builder.php:1143
160
+ #: includes/core/class-form.php:155 includes/core/class-form.php:328
161
#: includes/core/class-password.php:518
162
msgid "This is not possible for security reasons."
163
msgstr ""
378
"help us to grow the plugin and make it more popular. Thank you."
379
msgstr ""
380
381
+ #: includes/admin/core/class-admin-menu.php:126
382
msgctxt "Admin menu name"
383
msgid "Users"
384
msgstr ""
385
386
+ #: includes/admin/core/class-admin-menu.php:134
387
msgctxt "Admin menu name"
388
msgid "All Users"
389
msgstr ""
390
391
#. Plugin Name of the plugin/theme
392
#. Author of the plugin/theme
393
+ #: includes/admin/core/class-admin-menu.php:146
394
+ #: includes/core/class-user.php:557
395
msgid "Ultimate Member"
396
msgstr ""
397
398
+ #: includes/admin/core/class-admin-menu.php:150
399
msgid "Dashboard"
400
msgstr ""
401
402
+ #: includes/admin/core/class-admin-menu.php:158
403
#: includes/admin/templates/gdpr.php:7 includes/core/class-common.php:56
404
msgid "Forms"
405
msgstr ""
406
407
+ #: includes/admin/core/class-admin-menu.php:160
408
#: includes/admin/core/list-tables/roles-list-table.php:477
409
#: includes/admin/core/packages/2.0-beta1/user_roles.php:12
410
msgid "User Roles"
411
msgstr ""
412
413
+ #: includes/admin/core/class-admin-menu.php:163
414
#: includes/core/class-common.php:85
415
msgid "Member Directories"
416
msgstr ""
417
418
+ #: includes/admin/core/class-admin-menu.php:205
419
#: includes/admin/core/class-admin-settings.php:1007
420
msgid "Extensions"
421
msgstr ""
422
423
+ #: includes/admin/core/class-admin-menu.php:218
424
msgid "Users Overview"
425
msgstr ""
426
427
+ #: includes/admin/core/class-admin-menu.php:220
428
msgid "Latest from our blog"
429
msgstr ""
430
431
+ #: includes/admin/core/class-admin-menu.php:222
432
msgid "Purge Temp Files"
433
msgstr ""
434
435
+ #: includes/admin/core/class-admin-menu.php:224
436
msgid "User Cache"
437
msgstr ""
438
439
+ #: includes/admin/core/class-admin-menu.php:229
440
msgid "Upgrade's Manual Request"
441
msgstr ""
442
1312
"target=\"_blank\">here</a>"
1313
msgstr ""
1314
1315
+ #: includes/admin/core/class-admin-notices.php:672
1316
msgid "Wrong Data"
1317
msgstr ""
1318
2552
2553
#: includes/admin/core/class-admin-users.php:305
2554
#: includes/admin/templates/dashboard/users.php:11
2555
+ #: includes/core/class-user.php:821
2556
msgid "Approved"
2557
msgstr ""
2558
2675
msgid "User Role <strong>Deleted</strong> Successfully."
2676
msgstr ""
2677
2678
+ #: includes/admin/core/packages/2.0-beta1/functions.php:8
2679
+ #: includes/admin/core/packages/2.0.10/functions.php:8
2680
msgid "Styles was upgraded successfully"
2681
msgstr ""
2682
2683
+ #: includes/admin/core/packages/2.0-beta1/functions.php:21
2684
msgid "User Roles was upgraded successfully"
2685
msgstr ""
2686
2687
+ #: includes/admin/core/packages/2.0-beta1/functions.php:89
2688
#, php-format
2689
msgid "Users from %s to %s was upgraded successfully..."
2690
msgstr ""
2691
2692
+ #: includes/admin/core/packages/2.0-beta1/functions.php:113
2693
msgid "Settings was upgraded successfully"
2694
msgstr ""
2695
2696
+ #: includes/admin/core/packages/2.0-beta1/functions.php:123
2697
msgid "Menus settings was upgraded successfully"
2698
msgstr ""
2699
2700
+ #: includes/admin/core/packages/2.0-beta1/functions.php:133
2701
msgid "Mailchimp Lists was upgraded successfully"
2702
msgstr ""
2703
2704
+ #: includes/admin/core/packages/2.0-beta1/functions.php:143
2705
msgid "Social login forms was upgraded successfully"
2706
msgstr ""
2707
2708
+ #: includes/admin/core/packages/2.0-beta1/functions.php:153
2709
msgid "UM Custom Posts was upgraded successfully"
2710
msgstr ""
2711
2712
+ #: includes/admin/core/packages/2.0-beta1/functions.php:170
2713
msgid "Forums are ready for upgrade"
2714
msgstr ""
2715
2716
+ #: includes/admin/core/packages/2.0-beta1/functions.php:225
2717
#, php-format
2718
msgid "Forums from %s to %s was upgraded successfully..."
2719
msgstr ""
2720
2721
+ #: includes/admin/core/packages/2.0-beta1/functions.php:243
2722
msgid "Woocommerce Products are ready for upgrade"
2723
msgstr ""
2724
2725
+ #: includes/admin/core/packages/2.0-beta1/functions.php:319
2726
#, php-format
2727
msgid "Woocommerce Products from %s to %s was upgraded successfully..."
2728
msgstr ""
2729
2730
+ #: includes/admin/core/packages/2.0-beta1/functions.php:337
2731
msgid "Email Templates was upgraded successfully"
2732
msgstr ""
2733
2736
msgid "Upgrade Styles..."
2737
msgstr ""
2738
2739
+ #: includes/admin/core/packages/2.0-beta1/init.php:38
2740
msgid "Upgrade Roles..."
2741
msgstr ""
2742
2743
+ #: includes/admin/core/packages/2.0-beta1/init.php:52
2744
msgid "Upgrade Users..."
2745
msgstr ""
2746
2747
+ #: includes/admin/core/packages/2.0-beta1/init.php:73
2748
msgid "Getting "
2749
msgstr ""
2750
2751
+ #: includes/admin/core/packages/2.0-beta1/init.php:73
2752
+ #: includes/admin/core/packages/2.0-beta1/init.php:85
2753
msgid " users..."
2754
msgstr ""
2755
2756
+ #: includes/admin/core/packages/2.0-beta1/init.php:85
2757
msgid "There are "
2758
msgstr ""
2759
2760
+ #: includes/admin/core/packages/2.0-beta1/init.php:86
2761
msgid "Start users upgrading..."
2762
msgstr ""
2763
2764
+ #: includes/admin/core/packages/2.0-beta1/init.php:139
2765
msgid "Upgrade Content Restriction Settings..."
2766
msgstr ""
2767
2768
+ #: includes/admin/core/packages/2.0-beta1/init.php:165
2769
msgid "Upgrade Settings..."
2770
msgstr ""
2771
2772
+ #: includes/admin/core/packages/2.0-beta1/init.php:191
2773
msgid "Upgrade Menu Items..."
2774
msgstr ""
2775
2776
+ #: includes/admin/core/packages/2.0-beta1/init.php:217
2777
msgid "Upgrade Mailchimp Lists..."
2778
msgstr ""
2779
2780
+ #: includes/admin/core/packages/2.0-beta1/init.php:243
2781
msgid "Upgrade Social Login Forms..."
2782
msgstr ""
2783
2784
+ #: includes/admin/core/packages/2.0-beta1/init.php:269
2785
msgid "Upgrade UM Custom Post Types..."
2786
msgstr ""
2787
2788
+ #: includes/admin/core/packages/2.0-beta1/init.php:295
2789
msgid "Upgrade bbPress Forums..."
2790
msgstr ""
2791
2792
+ #: includes/admin/core/packages/2.0-beta1/init.php:296
2793
msgid "Get bbPress Forums count..."
2794
msgstr ""
2795
2796
+ #: includes/admin/core/packages/2.0-beta1/init.php:355
2797
msgid "Upgrade Woocommerce Products..."
2798
msgstr ""
2799
2800
+ #: includes/admin/core/packages/2.0-beta1/init.php:356
2801
msgid "Get all Products..."
2802
msgstr ""
2803
2804
+ #: includes/admin/core/packages/2.0-beta1/init.php:417
2805
msgid "Upgrade Email Templates..."
2806
msgstr ""
2807
2830
msgid "Search User Roles"
2831
msgstr ""
2832
2833
+ #: includes/admin/core/packages/2.0.10/functions.php:21
2834
msgid "Users cache was cleared successfully"
2835
msgstr ""
2836
2837
+ #: includes/admin/core/packages/2.0.10/init.php:32
2838
msgid "Clear Users Cache..."
2839
msgstr ""
2840
2841
+ #: includes/admin/core/packages/2.0.24/functions.php:11
2842
msgid "Temporary dir was purged successfully"
2843
msgstr ""
2844
2859
msgid "Latest From Ultimate Member"
2860
msgstr ""
2861
2862
#: includes/admin/templates/dashboard/purge.php:4
2863
#, php-format
2864
msgid ""
2887
msgstr ""
2888
2889
#: includes/admin/templates/dashboard/users.php:27
2890
+ #: includes/core/class-user.php:829
2891
msgid "Pending Review"
2892
msgstr ""
2893
2894
#: includes/admin/templates/dashboard/users.php:32
2895
+ #: includes/core/class-user.php:825
2896
msgid "Awaiting E-mail Confirmation"
2897
msgstr ""
2898
3476
msgid "Update"
3477
msgstr ""
3478
3479
+ #: includes/admin/templates/modal/dynamic_edit_field.php:15
3480
+ #: includes/admin/templates/modal/dynamic_edit_row.php:15
3481
+ #: includes/admin/templates/modal/dynamic_new_divider.php:15
3482
+ #: includes/admin/templates/modal/dynamic_new_field.php:15
3483
+ #: includes/admin/templates/modal/dynamic_new_group.php:15
3484
#: includes/admin/templates/modal/fonticons.php:11
3485
#: includes/admin/templates/role/publish.php:24
3486
#: includes/core/class-fields.php:2301 includes/core/class-fields.php:2398
4122
msgid "You must add a shortcode to the content area"
4123
msgstr ""
4124
4125
+ #: includes/core/class-builtin.php:663 includes/core/class-user.php:1543
4126
msgid "Only me"
4127
msgstr ""
4128
6281
msgid "This user has not added any information to their profile yet."
6282
msgstr ""
6283
6284
+ #: includes/core/class-files.php:271
6285
msgid "Invalid parameters"
6286
msgstr ""
6287
6288
+ #: includes/core/class-files.php:276
6289
msgid "Invalid coordinates"
6290
msgstr ""
6291
6292
+ #: includes/core/class-files.php:281
6293
msgid "Invalid file ownership"
6294
msgstr ""
6295
6296
+ #: includes/core/class-files.php:334
6297
msgid "Invalid nonce"
6298
msgstr ""
6299
6300
+ #: includes/core/class-files.php:354 includes/core/class-files.php:439
6301
msgid "A theme or plugin compatibility issue"
6302
msgstr ""
6303
6304
+ #: includes/core/class-files.php:982
6305
msgid "Ultimate Member: Not a valid temp file"
6306
msgstr ""
6307
6308
+ #: includes/core/class-files.php:1110
6309
msgid "Invalid user ID: "
6310
msgstr ""
6311
6312
+ #: includes/core/class-files.php:1119 includes/core/class-files.php:1147
6313
msgid "Unauthorized to do this attempt."
6314
msgstr ""
6315
6316
+ #: includes/core/class-form.php:58 includes/core/class-profile.php:56
6317
+ #: includes/core/class-profile.php:74
6318
msgid "You can not edit this user"
6319
msgstr ""
6320
6376
msgid "https://wordpress.org/support/"
6377
msgstr ""
6378
6379
+ #: includes/core/class-profile.php:110
6380
msgid "About"
6381
msgstr ""
6382
6383
+ #: includes/core/class-profile.php:114
6384
msgid "Posts"
6385
msgstr ""
6386
6387
+ #: includes/core/class-profile.php:118
6388
msgid "Comments"
6389
msgstr ""
6390
6509
msgid "Maximum file size allowed: %s"
6510
msgstr ""
6511
6512
+ #: includes/core/class-user.php:615
6513
msgid "Ultimate Member Role"
6514
msgstr ""
6515
6516
+ #: includes/core/class-user.php:618
6517
msgid "&mdash; No role for Ultimate Member &mdash;"
6518
msgstr ""
6519
6520
+ #: includes/core/class-user.php:833
6521
msgid "Membership Rejected"
6522
msgstr ""
6523
6524
+ #: includes/core/class-user.php:837
6525
msgid "Membership Inactive"
6526
msgstr ""
6527
readme.txt CHANGED
@@ -6,7 +6,7 @@ Donate link:
6
Tags: community, member, membership, user-profile, user-registration
7
Requires at least: 4.7
8
Tested up to: 4.9
9
- Stable tag: 2.0.32
10
License: GNU Version 2 or Any Later Version
11
License URI: http://www.gnu.org/licenses/gpl-3.0.txt
12
@@ -137,6 +137,13 @@ The plugin works with popular caching plugins by automatically excluding Ultimat
137
138
= Important: UM2.0+ is a significant update to the code base from 1.3.88. Please make sure you take a full-site backup with restore point before updating the plugin =
139
140
= 2.0.32: November 20, 2018 =
141
142