Bulk Delete - Version 5.6.0

Version Description

Added the ability to delete posts based on custom post status

Download this release

Release Info

Developer sudar
Plugin Icon 128x128 Bulk Delete
Version 5.6.0
Comparing to
See all releases

Code changes from version 5.5.7 to 5.6.0

Files changed (55) hide show
  1. assets/css/bulk-delete.css +21 -1
  2. assets/css/bulk-delete.css.map +1 -1
  3. assets/css/bulk-delete.min.css +2 -2
  4. assets/js/bulk-delete.js +90 -8
  5. assets/js/bulk-delete.js.map +1 -1
  6. assets/js/bulk-delete.min.js +2 -2
  7. bulk-delete.php +77 -37
  8. include/addons/addon-list.php +3 -3
  9. include/addons/base/class-bd-addon.php +9 -5
  10. include/addons/base/class-bd-base-addon.php +6 -5
  11. include/addons/base/class-bd-scheduler-addon.php +18 -7
  12. include/addons/pages.php +4 -3
  13. include/addons/posts.php +13 -12
  14. include/addons/util.php +11 -9
  15. include/base/class-bd-base-page.php +12 -4
  16. include/base/class-bd-meta-box-module.php +29 -12
  17. include/base/class-bd-page.php +5 -3
  18. include/base/users/class-bd-user-meta-box-module.php +92 -31
  19. include/class-bulk-delete-by-days.php +0 -1
  20. include/compatibility/advanced-custom-fields-pro.php +3 -2
  21. include/compatibility/simple-login-log.php +7 -4
  22. include/compatibility/the-event-calendar.php +2 -1
  23. include/compatibility/woocommerce.php +3 -2
  24. include/controller/class-bd-controller.php +11 -8
  25. include/cron/class-cron-list-table.php +12 -16
  26. include/deprecated/class-bulk-delete-users.php +4 -3
  27. include/deprecated/deprecated.php +85 -7
  28. include/libraries/EDD_SL_Plugin_Updater.php +219 -67
  29. include/license/class-bd-edd-api-wrapper.php +28 -20
  30. include/license/class-bd-license-handler.php +33 -29
  31. include/license/class-bd-license.php +47 -37
  32. include/license/class-license-list-table.php +30 -20
  33. include/meta/class-bulk-delete-comment-meta.php +21 -12
  34. include/meta/class-bulk-delete-meta.php +16 -6
  35. include/meta/class-bulk-delete-post-meta.php +20 -12
  36. include/meta/class-bulk-delete-user-meta.php +21 -12
  37. include/misc/class-bulk-delete-jetpack-contact-form-messages.php +186 -24
  38. include/misc/class-bulk-delete-misc.php +25 -15
  39. include/pages/class-bulk-delete-pages.php +19 -12
  40. include/posts/class-bulk-delete-posts.php +172 -178
  41. include/settings/class-bd-settings-page.php +16 -9
  42. include/settings/class-bd-settings.php +9 -8
  43. include/settings/setting-helpers.php +19 -12
  44. include/system-info/class-bd-system-info-page.php +7 -4
  45. include/ui/admin-ui.php +21 -16
  46. include/ui/class-bulk-delete-help-screen.php +12 -12
  47. include/ui/form.php +122 -5
  48. include/users/class-bd-users-page.php +10 -6
  49. include/users/modules/class-bulk-delete-users-by-user-meta.php +15 -8
  50. include/users/modules/class-bulk-delete-users-by-user-role.php +18 -10
  51. include/util/class-bd-util.php +87 -58
  52. include/util/class-bulk-delete-by-days.php +7 -6
  53. include/util/query.php +14 -6
  54. languages/bulk-delete.pot +952 -899
  55. readme.txt +17 -4
assets/css/bulk-delete.css CHANGED
@@ -1,6 +1,22 @@
1
- /*! Bulk Delete - v5.5.7 %>
2
  * http://bulkwp.com
3
  * Copyright (c) 2017; * Licensed GPLv2+ */
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4
  select[multiple].select2 {
5
  width: 60%;
6
  }
@@ -10,4 +26,8 @@ select[multiple].select2 {
10
  box-shadow: none;
11
  }
12
 
 
 
 
 
13
  /*# sourceMappingURL=bulk-delete.css.map */
1
+ /*! Bulk Delete - v5.6.0 %>
2
  * http://bulkwp.com
3
  * Copyright (c) 2017; * Licensed GPLv2+ */
4
+ .visually-hidden {
5
+ border: 0;
6
+ clip: rect(1px, 1px, 1px, 1px);
7
+ height: 1px;
8
+ margin: -1px;
9
+ overflow: hidden;
10
+ padding: 0;
11
+ position: absolute;
12
+ white-space: nowrap;
13
+ width: 1px;
14
+ }
15
+
16
+ table.filter-items {
17
+ margin-left: 21px;
18
+ }
19
+
20
  select[multiple].select2 {
21
  width: 60%;
22
  }
26
  box-shadow: none;
27
  }
28
 
29
+ .bd-help {
30
+ cursor: help;
31
+ }
32
+
33
  /*# sourceMappingURL=bulk-delete.css.map */
assets/css/bulk-delete.css.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["src/select2-compat.css"],"names":[],"mappings":";;;AAAA,MAAM,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC;AAC1B,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE;AACZ,CAAC;AACD;AACA,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC;AACnC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC;AAC1B,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC;AAClB,CAAC","file":"bulk-delete.css","sourcesContent":["select[multiple].select2 {\n\twidth: 60%;\n}\n\n#post-body .select2-search__field {\n\t-webkit-box-shadow: none;\n\tbox-shadow: none;\n}\n"]}
1
+ {"version":3,"sources":["src/common.css","src/delete-users.css","src/select2-compat.css","src/tooltip.css"],"names":[],"mappings":";;;AAAA,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;AAClB,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;AACX,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE;AAChC,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC;AACb,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC;AACd,CAAC,QAAQ,CAAC,CAAC,MAAM,CAAC;AAClB,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;AACZ,CAAC,QAAQ,CAAC,CAAC,QAAQ,CAAC;AACpB,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC;AACrB,CAAC,KAAK,CAAC,CAAC,GAAG,CAAC;AACZ,CAAC;;ACVD,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AACpB,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC;AACnB,CAAC;;ACFD,MAAM,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC;AAC1B,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE;AACZ,CAAC;AACD;AACA,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC;AACnC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC;AAC1B,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC;AAClB,CAAC;;ACPD,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC;AACV,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC;AACd,CAAC","file":"bulk-delete.css","sourcesContent":[".visually-hidden {\n\tborder: 0;\n\tclip: rect(1px, 1px, 1px, 1px);\n\theight: 1px;\n\tmargin: -1px;\n\toverflow: hidden;\n\tpadding: 0;\n\tposition: absolute;\n\twhite-space: nowrap;\n\twidth: 1px;\n}\n","table.filter-items {\n\tmargin-left: 21px;\n}\n","select[multiple].select2 {\n\twidth: 60%;\n}\n\n#post-body .select2-search__field {\n\t-webkit-box-shadow: none;\n\tbox-shadow: none;\n}\n",".bd-help {\n\tcursor: help;\n}\n"]}
assets/css/bulk-delete.min.css CHANGED
@@ -1,3 +1,3 @@
1
- /*! Bulk Delete - v5.5.7 %>
2
  * http://bulkwp.com
3
- * Copyright (c) 2017; * Licensed GPLv2+ */select[multiple].select2{width:60%}#post-body .select2-search__field{-webkit-box-shadow:none;box-shadow:none}
1
+ /*! Bulk Delete - v5.6.0 %>
2
  * http://bulkwp.com
3
+ * Copyright (c) 2017; * Licensed GPLv2+ */.visually-hidden{border:0;clip:rect(1px,1px,1px,1px);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}table.filter-items{margin-left:21px}select[multiple].select2{width:60%}#post-body .select2-search__field{-webkit-box-shadow:none;box-shadow:none}.bd-help{cursor:help}
assets/js/bulk-delete.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! Bulk Delete - v5.5.7 %>
2
  * http://bulkwp.com
3
  * Copyright (c) 2017; * Licensed GPLv2+ */
4
  /*global BulkWP, postboxes, pagenow*/
@@ -8,6 +8,23 @@ jQuery(document).ready(function () {
8
  */
9
  jQuery( '.select2' ).select2();
10
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11
  /**
12
  * Enable Postbox handling
13
  */
@@ -59,6 +76,18 @@ jQuery(document).ready(function () {
59
  }
60
  }
61
 
 
 
 
 
 
 
 
 
 
 
 
 
62
  // hide all terms
63
  function hideAllTerms() {
64
  jQuery('table.terms').hide();
@@ -101,6 +130,10 @@ jQuery(document).ready(function () {
101
  jQuery('#smbd' + value + '_registered_restrict').change(function () {
102
  toggle_registered_restrict(value);
103
  });
 
 
 
 
104
  });
105
 
106
  jQuery.each( BulkWP.pro_iterators, function ( index, value) {
@@ -163,13 +196,62 @@ jQuery(document).ready(function () {
163
  }
164
  };
165
 
166
- BulkWP.validateUserMeta = function() {
167
- if (jQuery('#smbd_u_meta_value').val() !== '') {
168
- return true;
169
- } else {
170
- return false;
171
- }
172
- };
173
  });
174
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
175
  //# sourceMappingURL=bulk-delete.js.map
1
+ /*! Bulk Delete - v5.6.0 %>
2
  * http://bulkwp.com
3
  * Copyright (c) 2017; * Licensed GPLv2+ */
4
  /*global BulkWP, postboxes, pagenow*/
8
  */
9
  jQuery( '.select2' ).select2();
10
 
11
+ // Start Jetpack.
12
+ BulkWP.jetpack();
13
+
14
+ BulkWP.enableHelpTooltips( jQuery( '.bd-help' ) );
15
+
16
+ jQuery( '.user_restrict_to_no_posts_filter' ).change( function() {
17
+ var $this = jQuery(this),
18
+ filterEnabled = $this.is( ':checked' ),
19
+ $filterItems = $this.parents( 'table' ).children().find( '.user_restrict_to_no_posts_filter_items' );
20
+
21
+ if ( filterEnabled ) {
22
+ $filterItems.removeClass( 'visually-hidden' );
23
+ } else {
24
+ $filterItems.addClass( 'visually-hidden' );
25
+ }
26
+ } );
27
+
28
  /**
29
  * Enable Postbox handling
30
  */
76
  }
77
  }
78
 
79
+ /**
80
+ * Toggle Post type dropdown.
81
+ */
82
+ function toggle_post_type_dropdown( el ) {
83
+ // TODO: Check why the element is not toggling even when display:none is added by JS.
84
+ if ( jQuery( "#smbd" + el + "_no_posts" ).is( ":checked" ) ) {
85
+ jQuery( "tr#smbd" + el + "-post-type-dropdown" ).show();
86
+ } else {
87
+ jQuery( "tr#smbd" + el + "-post-type-dropdown" ).hide();
88
+ }
89
+ }
90
+
91
  // hide all terms
92
  function hideAllTerms() {
93
  jQuery('table.terms').hide();
130
  jQuery('#smbd' + value + '_registered_restrict').change(function () {
131
  toggle_registered_restrict(value);
132
  });
133
+
134
+ jQuery( '#smbd' + value + '_no_posts' ).change( function () {
135
+ toggle_post_type_dropdown( value );
136
+ });
137
  });
138
 
139
  jQuery.each( BulkWP.pro_iterators, function ( index, value) {
196
  }
197
  };
198
 
199
+ BulkWP.validateUserMeta = function() {
200
+ if (jQuery('#smbd_u_meta_value').val() !== '') {
201
+ return true;
202
+ } else {
203
+ return false;
204
+ }
205
+ };
206
  });
207
 
208
+ BulkWP.jetpack = function() {
209
+ jQuery('.bd-feedback-pro').hide();
210
+
211
+ jQuery('#smbd_feedback_cron_freq, #smbd_feedback_cron_start, #smbd_feedback_cron').removeAttr('disabled');
212
+ jQuery('#smbd_feedback_use_filter').removeAttr('disabled');
213
+
214
+ // enable filters
215
+ jQuery('input[name="smbd_feedback_use_filter"]').change(function() {
216
+ if('true' === jQuery(this).val()) {
217
+ // using filters
218
+ jQuery('#jetpack-filters').show();
219
+ } else {
220
+ jQuery('#jetpack-filters').hide();
221
+ }
222
+ });
223
+
224
+ // enable individual filters
225
+ jQuery.each(['name', 'email', 'ip'], function (index, value) {
226
+ jQuery('#smbd_feedback_author_' + value + '_filter').change(function() {
227
+ if(jQuery(this).is(':checked')) {
228
+ jQuery('#smbd_feedback_author_' + value + '_op').removeAttr('disabled');
229
+ jQuery('#smbd_feedback_author_' + value + '_value').removeAttr('disabled');
230
+ } else {
231
+ jQuery('#smbd_feedback_author_' + value + '_op').attr('disabled', 'true');
232
+ jQuery('#smbd_feedback_author_' + value + '_value').attr('disabled', 'true');
233
+ }
234
+ });
235
+ });
236
+ };
237
+
238
+ BulkWP.enableHelpTooltips = function ( $selector ) {
239
+ $selector.tooltip({
240
+ content: function() {
241
+ return jQuery(this).prop('title');
242
+ },
243
+ position: {
244
+ my: 'center top',
245
+ at: 'center bottom+10',
246
+ collision: 'flipfit'
247
+ },
248
+ hide: {
249
+ duration: 200
250
+ },
251
+ show: {
252
+ duration: 200
253
+ }
254
+ });
255
+ };
256
+
257
  //# sourceMappingURL=bulk-delete.js.map
assets/js/bulk-delete.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["src/bulk-delete.js"],"names":[],"mappings":";;;AAAA,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC,SAAS,CAAC,CAAC,OAAO,EAAE;AACrC,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AACpC,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,OAAO;AAClB,EAAE,EAAE;AACJ,CAAC,MAAM,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,EAAE,OAAO,GAAG;AAChC;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,QAAQ;AAC3B,EAAE,EAAE;AACJ,CAAC,SAAS,CAAC,mBAAmB,CAAC,OAAO,EAAE;AACxC;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC,MAAM;AACnC,EAAE,EAAE;AACJ,CAAC,QAAQ,CAAC,oBAAoB,CAAC,EAAE,CAAC,CAAC,CAAC;AACpC,EAAE,EAAE,CAAC,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,GAAG,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AAC1D,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,UAAU,EAAE,QAAQ,GAAG;AACvD,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,GAAG,UAAU,EAAE,QAAQ,GAAG;AACzD,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AACzD,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AAC3D,EAAE,CAAC;AACH,CAAC,CAAC;AACF;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,MAAM;AAChC,EAAE,EAAE;AACJ,CAAC,QAAQ,CAAC,qBAAqB,CAAC,EAAE,CAAC,CAAC,CAAC;AACrC,EAAE,EAAE,CAAC,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,MAAM,GAAG,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AACvD,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC7D,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AAC/D,EAAE,CAAC;AACH,CAAC,CAAC;AACF;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,MAAM;AACrC,EAAE,EAAE;AACJ,CAAC,QAAQ,CAAC,qBAAqB,CAAC,EAAE,CAAC,CAAC,CAAC;AACrC,EAAE,EAAE,CAAC,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,eAAe,GAAG,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AAChE,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,WAAW,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC/D,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,WAAW,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AACjE,EAAE,CAAC;AACH,CAAC,CAAC;AACF;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,MAAM;AAC1C,EAAE,EAAE;AACJ,CAAC,QAAQ,CAAC,0BAA0B,CAAC,EAAE,CAAC,CAAC,CAAC;AAC1C,EAAE,EAAE,CAAC,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,oBAAoB,GAAG,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AACrE,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,gBAAgB,GAAG,UAAU,EAAE,QAAQ,GAAG;AACpE,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,gBAAgB,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AACtE,EAAE,CAAC;AACH,CAAC,CAAC;AACF;AACA,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK;AAClB,CAAC,QAAQ,CAAC,YAAY,EAAE,CAAC,CAAC;AAC1B,EAAE,MAAM,EAAE,KAAK,CAAC,KAAK,GAAG,IAAI,GAAG;AAC/B,EAAE,MAAM,EAAE,KAAK,CAAC,KAAK,GAAG,IAAI,EAAE,OAAO,EAAE,CAAC,KAAK,EAAE;AAC/C,CAAC,CAAC;AACF,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI;AAC9B,CAAC,YAAY,GAAG;AAChB;AACA,CAAC,EAAE,CAAC,QAAQ,CAAC,KAAK,CAAC,QAAQ;AAC3B,CAAC,MAAM,GAAG,MAAM,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AAC3C,EAAE,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,EAAE;AAC3B,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,GAAG;AACrB,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,EAAE;AACzC;AACA,EAAE,EAAE,CAAC,EAAE,IAAI,CAAC,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AAC7B,GAAG,YAAY,GAAG;AAClB,GAAG,CAAC,KAAK,CAAC,IAAI,EAAE,IAAI,GAAG;AACvB,EAAE,CAAC;AACH,CAAC,GAAG;AACJ;AACA,CAAC,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM;AACpB,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC,QAAQ,CAAC,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;AAC3D,EAAE,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM;AAChC,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,WAAW,GAAG,cAAc,EAAE;AAC1D,GAAG,UAAU,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC;AACzB,EAAE,GAAG;AACL;AACA,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,SAAS,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AAC5D,GAAG,oBAAoB,CAAC,KAAK,EAAE;AAC/B,EAAE,GAAG;AACL;AACA,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AACzD,GAAG,qBAAqB,CAAC,KAAK,EAAE;AAChC,EAAE,GAAG;AACL;AACA,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,eAAe,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AAClE,GAAG,qBAAqB,CAAC,KAAK,EAAE;AAChC,EAAE,GAAG;AACL;AACA,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,oBAAoB,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AACvE,GAAG,0BAA0B,CAAC,KAAK,EAAE;AACrC,EAAE,GAAG;AACL,CAAC,GAAG;AACJ;AACA,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;AAC9D,EAAE,MAAM,GAAG,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,GAAG,GAAG,IAAI,GAAG;AAC7D,EAAE,MAAM,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC3H,CAAC,CAAC,CAAC,EAAE;AACL;AACA,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM;AACxB,CAAC,MAAM,EAAE,MAAM,CAAC,IAAI,EAAE,SAAS,KAAK,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AACvD,EAAE,GAAG,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,EAAE,GAAG,GAAG;AACzC,EAAE,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC;AAChB,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,kBAAkB,EAAE;AACjC,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC,gBAAgB,EAAE;AAClC;AACA,EAAE,EAAE,CAAC,CAAC,aAAa,CAAC,EAAE,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,CAAC;AAC3C,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,aAAa,GAAG,IAAI,EAAE;AAC1D,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,EAAE,KAAK,GAAG,IAAI,GAAG,QAAQ,CAAC,OAAO,CAAC,KAAK,GAAG,IAAI,KAAK,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,SAAS,CAAC,QAAQ;AAClI,IAAI,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC;AACjB,GAAG,CAAC;AACJ,EAAE,CAAC;AACH;AACA,EAAE,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;AACd,GAAG,EAAE,CAAC,CAAC,aAAa,CAAC,EAAE,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC;AAChD,IAAI,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,cAAc,CAAC,aAAa,EAAE;AACnD,GAAG,CAAC;AACJ;AACA,GAAG,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,GAAG,CAAC,OAAO,GAAG;AACvC,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,EAAE,CAAC,CAAC,aAAa,CAAC,EAAE,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC;AAC3C,IAAI,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,SAAS,CAAC,aAAa,EAAE;AAChD,GAAG,CAAC;AACJ;AACA,GAAG,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,SAAS,GAAG;AAChC,EAAE,CAAC;AACH;AACA,EAAE,MAAM,CAAC,KAAK,CAAC;AACf,CAAC,GAAG;AACJ;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,UAAU,CAAC,SAAS;AACxB,EAAE,EAAE;AACJ,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;AACnC,EAAE,MAAM,CAAC,IAAI,CAAC;AACd,CAAC,EAAE;AACH;AACA,CAAC,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC;AAC1C,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,GAAG,IAAI,GAAG,OAAO,CAAC,QAAQ,IAAI,GAAG,GAAG,CAAC,CAAC;AAC1F,GAAG,MAAM,CAAC,IAAI,CAAC;AACf,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,CAAC,KAAK,CAAC;AAChB,EAAE,CAAC;AACH,CAAC,EAAE;AACH;AACA,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC;AACtC,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,EAAE,KAAK,GAAG,IAAI,EAAE,QAAQ,GAAG,GAAG,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AACrF,GAAG,MAAM,CAAC,IAAI,CAAC;AACf,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,CAAC,KAAK,CAAC;AAChB,EAAE,CAAC;AACH,CAAC,EAAE;AACH;AACA,IAAI,MAAM,CAAC,gBAAgB,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;AAC1C,QAAQ,EAAE,CAAC,CAAC,MAAM,GAAG,iBAAiB,GAAG,GAAG,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AACxD,YAAY,MAAM,CAAC,IAAI,CAAC;AACxB,QAAQ,CAAC,CAAC,IAAI,CAAC,CAAC;AAChB,YAAY,MAAM,CAAC,KAAK,CAAC;AACzB,QAAQ,CAAC;AACT,IAAI,EAAE;AACN,GAAG","file":"bulk-delete.js","sourcesContent":["/*global BulkWP, postboxes, pagenow*/\njQuery(document).ready(function () {\n\t/**\n\t * Enable select2\n\t */\n\tjQuery( '.select2' ).select2();\n\n\t/**\n\t * Enable Postbox handling\n\t */\n\tpostboxes.add_postbox_toggles(pagenow);\n\n\t/**\n\t * Toggle the date restrict fields\n\t */\n\tfunction toggle_date_restrict(el) {\n\t\tif (jQuery(\"#smbd\" + el + \"_restrict\").is(\":checked\")) {\n\t\t\tjQuery(\"#smbd\" + el + \"_op\").removeAttr('disabled');\n\t\t\tjQuery(\"#smbd\" + el + \"_days\").removeAttr('disabled');\n\t\t} else {\n\t\t\tjQuery(\"#smbd\" + el + \"_op\").attr('disabled', 'true');\n\t\t\tjQuery(\"#smbd\" + el + \"_days\").attr('disabled', 'true');\n\t\t}\n\t}\n\n\t/**\n\t * Toggle limit restrict fields\n\t */\n\tfunction toggle_limit_restrict(el) {\n\t\tif (jQuery(\"#smbd\" + el + \"_limit\").is(\":checked\")) {\n\t\t\tjQuery(\"#smbd\" + el + \"_limit_to\").removeAttr('disabled');\n\t\t} else {\n\t\t\tjQuery(\"#smbd\" + el + \"_limit_to\").attr('disabled', 'true');\n\t\t}\n\t}\n\n\t/**\n\t * Toggle user login restrict fields\n\t */\n\tfunction toggle_login_restrict(el) {\n\t\tif (jQuery(\"#smbd\" + el + \"_login_restrict\").is(\":checked\")) {\n\t\t\tjQuery(\"#smbd\" + el + \"_login_days\").removeAttr('disabled');\n\t\t} else {\n\t\t\tjQuery(\"#smbd\" + el + \"_login_days\").attr('disabled', 'true');\n\t\t}\n\t}\n\n\t/**\n\t * Toggle user registered restrict fields\n\t */\n\tfunction toggle_registered_restrict(el) {\n\t\tif (jQuery(\"#smbd\" + el + \"_registered_restrict\").is(\":checked\")) {\n\t\t\tjQuery(\"#smbd\" + el + \"_registered_days\").removeAttr('disabled');\n\t\t} else {\n\t\t\tjQuery(\"#smbd\" + el + \"_registered_days\").attr('disabled', 'true');\n\t\t}\n\t}\n\n\t// hide all terms\n\tfunction hideAllTerms() {\n\t\tjQuery('table.terms').hide();\n\t\tjQuery('input.terms').attr('checked', false);\n\t}\n\t// call it for the first time\n\thideAllTerms();\n\n\t// taxonomy click handling\n\tjQuery('.custom-tax').change(function () {\n\t\tvar $this = jQuery(this),\n\t\t$tax = $this.val(),\n\t\t$terms = jQuery('table.terms_' + $tax);\n\n\t\tif ($this.is(':checked')) {\n\t\t\thideAllTerms();\n\t\t\t$terms.show('slow');\n\t\t}\n\t});\n\n\t// date time picker\n\tjQuery.each(BulkWP.dt_iterators, function (index, value) {\n\t\t// invoke the date time picker\n\t\tjQuery('#smbd' + value + '_cron_start').datetimepicker({\n\t\t\ttimeFormat: 'HH:mm:ss'\n\t\t});\n\n\t\tjQuery('#smbd' + value + '_restrict').change(function () {\n\t\t\ttoggle_date_restrict(value);\n\t\t});\n\n\t\tjQuery('#smbd' + value + '_limit').change(function () {\n\t\t\ttoggle_limit_restrict(value);\n\t\t});\n\n\t\tjQuery('#smbd' + value + '_login_restrict').change(function () {\n\t\t\ttoggle_login_restrict(value);\n\t\t});\n\n\t\tjQuery('#smbd' + value + '_registered_restrict').change(function () {\n\t\t\ttoggle_registered_restrict(value);\n\t\t});\n\t});\n\n\tjQuery.each( BulkWP.pro_iterators, function ( index, value) {\n\t\tjQuery('.bd-' + value.replace( '_', '-' ) + '-pro').hide();\n\t\tjQuery('#smbd_' + value + '_cron_freq, #smbd_' + value + '_cron_start, #smbd_' + value + '_cron').removeAttr('disabled');\n\t} );\n\n\t// Validate user action\n\tjQuery('button[name=\"bd_action\"]').click(function () {\n\t\tvar currentButton = jQuery(this).val(),\n\t\tvalid = false,\n\t\tmsg_key = \"deletePostsWarning\",\n\t\t\terror_key = \"selectPostOption\";\n\n\t\tif (currentButton in BulkWP.validators) {\n\t\t\tvalid = BulkWP[BulkWP.validators[currentButton]](this);\n\t\t} else {\n\t\t\tif (jQuery(this).parent().prev().children('table').find(\":checkbox:checked[value!='true']\").size() > 0) { // monstrous selector\n\t\t\t\tvalid = true;\n\t\t\t}\n\t\t}\n\n\t\tif (valid) {\n\t\t\tif (currentButton in BulkWP.pre_action_msg) {\n\t\t\t\tmsg_key = BulkWP.pre_action_msg[currentButton];\n\t\t\t}\n\n\t\t\treturn confirm(BulkWP.msg[msg_key]);\n\t\t} else {\n\t\t\tif (currentButton in BulkWP.error_msg) {\n\t\t\t\terror_key = BulkWP.error_msg[currentButton];\n\t\t\t}\n\n\t\t\talert(BulkWP.msg[error_key]);\n\t\t}\n\n\t\treturn false;\n\t});\n\n\t/**\n\t * Validation functions\n\t */\n\tBulkWP.noValidation = function() {\n\t\treturn true;\n\t};\n\n\tBulkWP.validateSelect2 = function(that) {\n\t\tif (null !== jQuery(that).parent().prev().children().find(\".select2[multiple]\").val()) {\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t};\n\n\tBulkWP.validateUrl = function(that) {\n\t\tif (jQuery(that).parent().prev().children('table').find(\"textarea\").val() !== '') {\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t};\n\n BulkWP.validateUserMeta = function() {\n if (jQuery('#smbd_u_meta_value').val() !== '') {\n return true;\n } else {\n return false;\n }\n };\n});\n"]}
1
+ {"version":3,"sources":["src/bulk-delete.js"],"names":[],"mappings":";;;AAAA,EAAE,MAAM,CAAC,MAAM,CAAC,CAAC,SAAS,CAAC,CAAC,OAAO,EAAE;AACrC,MAAM,CAAC,QAAQ,EAAE,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AACpC,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,OAAO;AAClB,EAAE,EAAE;AACJ,CAAC,MAAM,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,EAAE,OAAO,GAAG;AAChC;AACA,CAAC,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC;AAClB,CAAC,MAAM,CAAC,OAAO,GAAG;AAClB;AACA,CAAC,MAAM,CAAC,kBAAkB,CAAC,CAAC,MAAM,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE;AACnD;AACA,CAAC,MAAM,CAAC,CAAC,EAAE,gCAAgC,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;AACnE,EAAE,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,EAAE;AAC3B,GAAG,aAAa,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,EAAE;AAC1C,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,QAAQ,GAAG,IAAI,CAAC,CAAC,EAAE,sCAAsC,CAAC,CAAC,EAAE;AAC3G;AACA,EAAE,EAAE,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;AACxB,GAAG,CAAC,WAAW,CAAC,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC,EAAE;AACjD,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC,EAAE;AAC9C,EAAE,CAAC;AACH,CAAC,CAAC,CAAC,EAAE;AACL;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,QAAQ;AAC3B,EAAE,EAAE;AACJ,CAAC,SAAS,CAAC,mBAAmB,CAAC,OAAO,EAAE;AACxC;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC,MAAM;AACnC,EAAE,EAAE;AACJ,CAAC,QAAQ,CAAC,oBAAoB,CAAC,EAAE,CAAC,CAAC,CAAC;AACpC,EAAE,EAAE,CAAC,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,GAAG,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AAC1D,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,UAAU,EAAE,QAAQ,GAAG;AACvD,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,GAAG,UAAU,EAAE,QAAQ,GAAG;AACzD,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AACzD,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AAC3D,EAAE,CAAC;AACH,CAAC,CAAC;AACF;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,MAAM;AAChC,EAAE,EAAE;AACJ,CAAC,QAAQ,CAAC,qBAAqB,CAAC,EAAE,CAAC,CAAC,CAAC;AACrC,EAAE,EAAE,CAAC,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,MAAM,GAAG,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AACvD,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC7D,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AAC/D,EAAE,CAAC;AACH,CAAC,CAAC;AACF;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,MAAM;AACrC,EAAE,EAAE;AACJ,CAAC,QAAQ,CAAC,qBAAqB,CAAC,EAAE,CAAC,CAAC,CAAC;AACrC,EAAE,EAAE,CAAC,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,eAAe,GAAG,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AAChE,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,WAAW,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC/D,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,WAAW,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AACjE,EAAE,CAAC;AACH,CAAC,CAAC;AACF;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,MAAM;AAC1C,EAAE,EAAE;AACJ,CAAC,QAAQ,CAAC,0BAA0B,CAAC,EAAE,CAAC,CAAC,CAAC;AAC1C,EAAE,EAAE,CAAC,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,oBAAoB,GAAG,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AACrE,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,gBAAgB,GAAG,UAAU,EAAE,QAAQ,GAAG;AACpE,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,gBAAgB,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AACtE,EAAE,CAAC;AACH,CAAC,CAAC;AACF;AACA,IAAI,GAAG;AACP,KAAK,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC;AACjC,KAAK,EAAE;AACP,IAAI,QAAQ,CAAC,yBAAyB,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAC9C,QAAQ,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC,GAAG,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC;AAC7F,QAAQ,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AACtE,YAAY,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,EAAE,IAAI,GAAG;AACpE,QAAQ,CAAC,CAAC,IAAI,CAAC,CAAC;AAChB,YAAY,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,EAAE,IAAI,GAAG;AACpE,QAAQ,CAAC;AACT,IAAI,CAAC;AACL;AACA,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,KAAK;AAClB,CAAC,QAAQ,CAAC,YAAY,EAAE,CAAC,CAAC;AAC1B,EAAE,MAAM,EAAE,KAAK,CAAC,KAAK,GAAG,IAAI,GAAG;AAC/B,EAAE,MAAM,EAAE,KAAK,CAAC,KAAK,GAAG,IAAI,EAAE,OAAO,EAAE,CAAC,KAAK,EAAE;AAC/C,CAAC,CAAC;AACF,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI;AAC9B,CAAC,YAAY,GAAG;AAChB;AACA,CAAC,EAAE,CAAC,QAAQ,CAAC,KAAK,CAAC,QAAQ;AAC3B,CAAC,MAAM,GAAG,MAAM,CAAC,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AAC3C,EAAE,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,EAAE;AAC3B,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,GAAG;AACrB,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,EAAE;AACzC;AACA,EAAE,EAAE,CAAC,EAAE,IAAI,CAAC,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AAC7B,GAAG,YAAY,GAAG;AAClB,GAAG,CAAC,KAAK,CAAC,IAAI,EAAE,IAAI,GAAG;AACvB,EAAE,CAAC;AACH,CAAC,GAAG;AACJ;AACA,CAAC,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM;AACpB,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC,QAAQ,CAAC,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;AAC3D,EAAE,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM;AAChC,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,WAAW,GAAG,cAAc,EAAE;AAC1D,GAAG,UAAU,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC;AACzB,EAAE,GAAG;AACL;AACA,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,SAAS,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AAC5D,GAAG,oBAAoB,CAAC,KAAK,EAAE;AAC/B,EAAE,GAAG;AACL;AACA,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AACzD,GAAG,qBAAqB,CAAC,KAAK,EAAE;AAChC,EAAE,GAAG;AACL;AACA,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,eAAe,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AAClE,GAAG,qBAAqB,CAAC,KAAK,EAAE;AAChC,EAAE,GAAG;AACL;AACA,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,oBAAoB,GAAG,MAAM,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AACvE,GAAG,0BAA0B,CAAC,KAAK,EAAE;AACrC,EAAE,GAAG;AACL;AACA,EAAE,MAAM,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AAC/D,GAAG,yBAAyB,CAAC,CAAC,KAAK,CAAC,EAAE;AACtC,EAAE,GAAG;AACL,CAAC,GAAG;AACJ;AACA,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;AAC9D,EAAE,MAAM,GAAG,EAAE,EAAE,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,GAAG,GAAG,IAAI,GAAG;AAC7D,EAAE,MAAM,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC3H,CAAC,CAAC,CAAC,EAAE;AACL;AACA,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM;AACxB,CAAC,MAAM,EAAE,MAAM,CAAC,IAAI,EAAE,SAAS,KAAK,KAAK,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;AACvD,EAAE,GAAG,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,EAAE,GAAG,GAAG;AACzC,EAAE,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC;AAChB,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,kBAAkB,EAAE;AACjC,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC,gBAAgB,EAAE;AAClC;AACA,EAAE,EAAE,CAAC,CAAC,aAAa,CAAC,EAAE,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,CAAC;AAC3C,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,aAAa,GAAG,IAAI,EAAE;AAC1D,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,EAAE,KAAK,GAAG,IAAI,GAAG,QAAQ,CAAC,OAAO,CAAC,KAAK,GAAG,IAAI,KAAK,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,SAAS,CAAC,QAAQ;AAClI,IAAI,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC;AACjB,GAAG,CAAC;AACJ,EAAE,CAAC;AACH;AACA,EAAE,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;AACd,GAAG,EAAE,CAAC,CAAC,aAAa,CAAC,EAAE,CAAC,MAAM,CAAC,cAAc,CAAC,CAAC,CAAC;AAChD,IAAI,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,cAAc,CAAC,aAAa,EAAE;AACnD,GAAG,CAAC;AACJ;AACA,GAAG,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,GAAG,CAAC,OAAO,GAAG;AACvC,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,EAAE,CAAC,CAAC,aAAa,CAAC,EAAE,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC;AAC3C,IAAI,SAAS,CAAC,CAAC,CAAC,MAAM,CAAC,SAAS,CAAC,aAAa,EAAE;AAChD,GAAG,CAAC;AACJ;AACA,GAAG,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,SAAS,GAAG;AAChC,EAAE,CAAC;AACH;AACA,EAAE,MAAM,CAAC,KAAK,CAAC;AACf,CAAC,GAAG;AACJ;AACA,CAAC,GAAG;AACJ,EAAE,CAAC,CAAC,UAAU,CAAC,SAAS;AACxB,EAAE,EAAE;AACJ,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;AACnC,EAAE,MAAM,CAAC,IAAI,CAAC;AACd,CAAC,EAAE;AACH;AACA,CAAC,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC;AAC1C,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,GAAG,IAAI,GAAG,OAAO,CAAC,QAAQ,IAAI,GAAG,GAAG,CAAC,CAAC;AAC1F,GAAG,MAAM,CAAC,IAAI,CAAC;AACf,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,CAAC,KAAK,CAAC;AAChB,EAAE,CAAC;AACH,CAAC,EAAE;AACH;AACA,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC;AACtC,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,EAAE,KAAK,GAAG,IAAI,EAAE,QAAQ,GAAG,GAAG,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AACrF,GAAG,MAAM,CAAC,IAAI,CAAC;AACf,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,CAAC,KAAK,CAAC;AAChB,EAAE,CAAC;AACH,CAAC,EAAE;AACH;AACA,CAAC,MAAM,CAAC,gBAAgB,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;AACvC,EAAE,EAAE,CAAC,CAAC,MAAM,GAAG,iBAAiB,GAAG,GAAG,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AAClD,GAAG,MAAM,CAAC,IAAI,CAAC;AACf,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,CAAC,KAAK,CAAC;AAChB,EAAE,CAAC;AACH,CAAC,EAAE;AACH,GAAG;AACH;AACA,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;AAC7B,CAAC,MAAM,GAAG,EAAE,CAAC,QAAQ,CAAC,GAAG,GAAG,IAAI,GAAG;AACnC;AACA,CAAC,MAAM,GAAG,uBAAuB,CAAC,CAAC,CAAC,wBAAwB,CAAC,CAAC,CAAC,kBAAkB,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC3G,CAAC,MAAM,GAAG,wBAAwB,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC5D;AACA,CAAC,EAAE,CAAC,MAAM,CAAC,OAAO;AAClB,CAAC,MAAM,EAAE,KAAK,CAAC,IAAI,EAAE,wBAAwB,KAAK,MAAM,CAAC,QAAQ,EAAE,CAAC,CAAC;AACrE,EAAE,EAAE,EAAE,IAAI,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE,GAAG,GAAG,CAAC,CAAC;AACrC,GAAG,EAAE,CAAC,KAAK,CAAC,OAAO;AACnB,GAAG,MAAM,GAAG,OAAO,CAAC,OAAO,GAAG,IAAI,GAAG;AACrC,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC;AACV,GAAG,MAAM,GAAG,OAAO,CAAC,OAAO,GAAG,IAAI,GAAG;AACrC,EAAE,CAAC;AACH,CAAC,GAAG;AACJ;AACA,CAAC,EAAE,CAAC,MAAM,CAAC,UAAU,CAAC,OAAO;AAC7B,CAAC,MAAM,CAAC,IAAI,GAAG,IAAI,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,EAAE,GAAG,CAAC,QAAQ,CAAC,CAAC,KAAK,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC;AAC/D,EAAE,MAAM,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,OAAO,GAAG,MAAM,CAAC,QAAQ,EAAE,CAAC,CAAC;AAC1E,GAAG,EAAE,CAAC,MAAM,CAAC,IAAI,EAAE,EAAE,GAAG,OAAO,GAAG,CAAC,CAAC;AACpC,IAAI,MAAM,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC5E,IAAI,MAAM,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,GAAG,UAAU,EAAE,QAAQ,GAAG;AAC/E,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC;AACX,IAAI,MAAM,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,GAAG,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AAC9E,IAAI,MAAM,GAAG,qBAAqB,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,GAAG,IAAI,EAAE,QAAQ,EAAE,CAAC,CAAC,IAAI,GAAG;AACjF,GAAG,CAAC;AACJ,EAAE,GAAG;AACL,CAAC,GAAG;AACJ,EAAE;AACF;AACA,MAAM,CAAC,kBAAkB,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC;AACpD,CAAC,CAAC,QAAQ,CAAC,OAAO,EAAE;AACpB,EAAE,OAAO,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC;AACvB,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,GAAG;AACrC,EAAE,EAAE;AACJ,EAAE,QAAQ,CAAC,CAAC,CAAC;AACb,GAAG,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,EAAE;AACpB,GAAG,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,EAAE;AAC1B,GAAG,SAAS,CAAC,CAAC,CAAC,OAAO,CAAC;AACvB,EAAE,EAAE;AACJ,EAAE,IAAI,CAAC,CAAC,CAAC;AACT,GAAG,QAAQ,CAAC,CAAC,GAAG;AAChB,EAAE,EAAE;AACJ,EAAE,IAAI,CAAC,CAAC,CAAC;AACT,GAAG,QAAQ,CAAC,CAAC,GAAG;AAChB,EAAE,CAAC;AACH,CAAC,GAAG;AACJ,EAAE","file":"bulk-delete.js","sourcesContent":["/*global BulkWP, postboxes, pagenow*/\njQuery(document).ready(function () {\n\t/**\n\t * Enable select2\n\t */\n\tjQuery( '.select2' ).select2();\n\n\t// Start Jetpack.\n\tBulkWP.jetpack();\n\n\tBulkWP.enableHelpTooltips( jQuery( '.bd-help' ) );\n\n\tjQuery( '.user_restrict_to_no_posts_filter' ).change( function() {\n\t\tvar $this = jQuery(this),\n\t\t\tfilterEnabled = $this.is( ':checked' ),\n\t\t $filterItems = $this.parents( 'table' ).children().find( '.user_restrict_to_no_posts_filter_items' );\n\n\t\tif ( filterEnabled ) {\n\t\t\t$filterItems.removeClass( 'visually-hidden' );\n\t\t} else {\n\t\t\t$filterItems.addClass( 'visually-hidden' );\n\t\t}\n\t} );\n\n\t/**\n\t * Enable Postbox handling\n\t */\n\tpostboxes.add_postbox_toggles(pagenow);\n\n\t/**\n\t * Toggle the date restrict fields\n\t */\n\tfunction toggle_date_restrict(el) {\n\t\tif (jQuery(\"#smbd\" + el + \"_restrict\").is(\":checked\")) {\n\t\t\tjQuery(\"#smbd\" + el + \"_op\").removeAttr('disabled');\n\t\t\tjQuery(\"#smbd\" + el + \"_days\").removeAttr('disabled');\n\t\t} else {\n\t\t\tjQuery(\"#smbd\" + el + \"_op\").attr('disabled', 'true');\n\t\t\tjQuery(\"#smbd\" + el + \"_days\").attr('disabled', 'true');\n\t\t}\n\t}\n\n\t/**\n\t * Toggle limit restrict fields\n\t */\n\tfunction toggle_limit_restrict(el) {\n\t\tif (jQuery(\"#smbd\" + el + \"_limit\").is(\":checked\")) {\n\t\t\tjQuery(\"#smbd\" + el + \"_limit_to\").removeAttr('disabled');\n\t\t} else {\n\t\t\tjQuery(\"#smbd\" + el + \"_limit_to\").attr('disabled', 'true');\n\t\t}\n\t}\n\n\t/**\n\t * Toggle user login restrict fields\n\t */\n\tfunction toggle_login_restrict(el) {\n\t\tif (jQuery(\"#smbd\" + el + \"_login_restrict\").is(\":checked\")) {\n\t\t\tjQuery(\"#smbd\" + el + \"_login_days\").removeAttr('disabled');\n\t\t} else {\n\t\t\tjQuery(\"#smbd\" + el + \"_login_days\").attr('disabled', 'true');\n\t\t}\n\t}\n\n\t/**\n\t * Toggle user registered restrict fields\n\t */\n\tfunction toggle_registered_restrict(el) {\n\t\tif (jQuery(\"#smbd\" + el + \"_registered_restrict\").is(\":checked\")) {\n\t\t\tjQuery(\"#smbd\" + el + \"_registered_days\").removeAttr('disabled');\n\t\t} else {\n\t\t\tjQuery(\"#smbd\" + el + \"_registered_days\").attr('disabled', 'true');\n\t\t}\n\t}\n\n /**\n * Toggle Post type dropdown.\n */\n function toggle_post_type_dropdown( el ) {\n // TODO: Check why the element is not toggling even when display:none is added by JS.\n if ( jQuery( \"#smbd\" + el + \"_no_posts\" ).is( \":checked\" ) ) {\n jQuery( \"tr#smbd\" + el + \"-post-type-dropdown\" ).show();\n } else {\n jQuery( \"tr#smbd\" + el + \"-post-type-dropdown\" ).hide();\n }\n }\n\n\t// hide all terms\n\tfunction hideAllTerms() {\n\t\tjQuery('table.terms').hide();\n\t\tjQuery('input.terms').attr('checked', false);\n\t}\n\t// call it for the first time\n\thideAllTerms();\n\n\t// taxonomy click handling\n\tjQuery('.custom-tax').change(function () {\n\t\tvar $this = jQuery(this),\n\t\t$tax = $this.val(),\n\t\t$terms = jQuery('table.terms_' + $tax);\n\n\t\tif ($this.is(':checked')) {\n\t\t\thideAllTerms();\n\t\t\t$terms.show('slow');\n\t\t}\n\t});\n\n\t// date time picker\n\tjQuery.each(BulkWP.dt_iterators, function (index, value) {\n\t\t// invoke the date time picker\n\t\tjQuery('#smbd' + value + '_cron_start').datetimepicker({\n\t\t\ttimeFormat: 'HH:mm:ss'\n\t\t});\n\n\t\tjQuery('#smbd' + value + '_restrict').change(function () {\n\t\t\ttoggle_date_restrict(value);\n\t\t});\n\n\t\tjQuery('#smbd' + value + '_limit').change(function () {\n\t\t\ttoggle_limit_restrict(value);\n\t\t});\n\n\t\tjQuery('#smbd' + value + '_login_restrict').change(function () {\n\t\t\ttoggle_login_restrict(value);\n\t\t});\n\n\t\tjQuery('#smbd' + value + '_registered_restrict').change(function () {\n\t\t\ttoggle_registered_restrict(value);\n\t\t});\n\n\t\tjQuery( '#smbd' + value + '_no_posts' ).change( function () {\n\t\t\ttoggle_post_type_dropdown( value );\n\t\t});\n\t});\n\n\tjQuery.each( BulkWP.pro_iterators, function ( index, value) {\n\t\tjQuery('.bd-' + value.replace( '_', '-' ) + '-pro').hide();\n\t\tjQuery('#smbd_' + value + '_cron_freq, #smbd_' + value + '_cron_start, #smbd_' + value + '_cron').removeAttr('disabled');\n\t} );\n\n\t// Validate user action\n\tjQuery('button[name=\"bd_action\"]').click(function () {\n\t\tvar currentButton = jQuery(this).val(),\n\t\tvalid = false,\n\t\tmsg_key = \"deletePostsWarning\",\n\t\t\terror_key = \"selectPostOption\";\n\n\t\tif (currentButton in BulkWP.validators) {\n\t\t\tvalid = BulkWP[BulkWP.validators[currentButton]](this);\n\t\t} else {\n\t\t\tif (jQuery(this).parent().prev().children('table').find(\":checkbox:checked[value!='true']\").size() > 0) { // monstrous selector\n\t\t\t\tvalid = true;\n\t\t\t}\n\t\t}\n\n\t\tif (valid) {\n\t\t\tif (currentButton in BulkWP.pre_action_msg) {\n\t\t\t\tmsg_key = BulkWP.pre_action_msg[currentButton];\n\t\t\t}\n\n\t\t\treturn confirm(BulkWP.msg[msg_key]);\n\t\t} else {\n\t\t\tif (currentButton in BulkWP.error_msg) {\n\t\t\t\terror_key = BulkWP.error_msg[currentButton];\n\t\t\t}\n\n\t\t\talert(BulkWP.msg[error_key]);\n\t\t}\n\n\t\treturn false;\n\t});\n\n\t/**\n\t * Validation functions\n\t */\n\tBulkWP.noValidation = function() {\n\t\treturn true;\n\t};\n\n\tBulkWP.validateSelect2 = function(that) {\n\t\tif (null !== jQuery(that).parent().prev().children().find(\".select2[multiple]\").val()) {\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t};\n\n\tBulkWP.validateUrl = function(that) {\n\t\tif (jQuery(that).parent().prev().children('table').find(\"textarea\").val() !== '') {\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t};\n\n\tBulkWP.validateUserMeta = function() {\n\t\tif (jQuery('#smbd_u_meta_value').val() !== '') {\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t};\n});\n\nBulkWP.jetpack = function() {\n\tjQuery('.bd-feedback-pro').hide();\n\n\tjQuery('#smbd_feedback_cron_freq, #smbd_feedback_cron_start, #smbd_feedback_cron').removeAttr('disabled');\n\tjQuery('#smbd_feedback_use_filter').removeAttr('disabled');\n\n\t// enable filters\n\tjQuery('input[name=\"smbd_feedback_use_filter\"]').change(function() {\n\t\tif('true' === jQuery(this).val()) {\n\t\t\t// using filters\n\t\t\tjQuery('#jetpack-filters').show();\n\t\t} else {\n\t\t\tjQuery('#jetpack-filters').hide();\n\t\t}\n\t});\n\n\t// enable individual filters\n\tjQuery.each(['name', 'email', 'ip'], function (index, value) {\n\t\tjQuery('#smbd_feedback_author_' + value + '_filter').change(function() {\n\t\t\tif(jQuery(this).is(':checked')) {\n\t\t\t\tjQuery('#smbd_feedback_author_' + value + '_op').removeAttr('disabled');\n\t\t\t\tjQuery('#smbd_feedback_author_' + value + '_value').removeAttr('disabled');\n\t\t\t} else {\n\t\t\t\tjQuery('#smbd_feedback_author_' + value + '_op').attr('disabled', 'true');\n\t\t\t\tjQuery('#smbd_feedback_author_' + value + '_value').attr('disabled', 'true');\n\t\t\t}\n\t\t});\n\t});\n};\n\nBulkWP.enableHelpTooltips = function ( $selector ) {\n\t$selector.tooltip({\n\t\tcontent: function() {\n\t\t\treturn jQuery(this).prop('title');\n\t\t},\n\t\tposition: {\n\t\t\tmy: 'center top',\n\t\t\tat: 'center bottom+10',\n\t\t\tcollision: 'flipfit'\n\t\t},\n\t\thide: {\n\t\t\tduration: 200\n\t\t},\n\t\tshow: {\n\t\t\tduration: 200\n\t\t}\n\t});\n};\n"]}
assets/js/bulk-delete.min.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! Bulk Delete - v5.5.7
2
  * http://bulkwp.com
3
  * Copyright (c) 2017; * Licensed GPLv2+ */
4
- jQuery(document).ready(function(){function a(a){jQuery("#smbd"+a+"_restrict").is(":checked")?(jQuery("#smbd"+a+"_op").removeAttr("disabled"),jQuery("#smbd"+a+"_days").removeAttr("disabled")):(jQuery("#smbd"+a+"_op").attr("disabled","true"),jQuery("#smbd"+a+"_days").attr("disabled","true"))}function b(a){jQuery("#smbd"+a+"_limit").is(":checked")?jQuery("#smbd"+a+"_limit_to").removeAttr("disabled"):jQuery("#smbd"+a+"_limit_to").attr("disabled","true")}function c(a){jQuery("#smbd"+a+"_login_restrict").is(":checked")?jQuery("#smbd"+a+"_login_days").removeAttr("disabled"):jQuery("#smbd"+a+"_login_days").attr("disabled","true")}function d(a){jQuery("#smbd"+a+"_registered_restrict").is(":checked")?jQuery("#smbd"+a+"_registered_days").removeAttr("disabled"):jQuery("#smbd"+a+"_registered_days").attr("disabled","true")}function e(){jQuery("table.terms").hide(),jQuery("input.terms").attr("checked",!1)}jQuery(".select2").select2(),postboxes.add_postbox_toggles(pagenow),e(),jQuery(".custom-tax").change(function(){var a=jQuery(this),b=a.val(),c=jQuery("table.terms_"+b);a.is(":checked")&&(e(),c.show("slow"))}),jQuery.each(BulkWP.dt_iterators,function(e,f){jQuery("#smbd"+f+"_cron_start").datetimepicker({timeFormat:"HH:mm:ss"}),jQuery("#smbd"+f+"_restrict").change(function(){a(f)}),jQuery("#smbd"+f+"_limit").change(function(){b(f)}),jQuery("#smbd"+f+"_login_restrict").change(function(){c(f)}),jQuery("#smbd"+f+"_registered_restrict").change(function(){d(f)})}),jQuery.each(BulkWP.pro_iterators,function(a,b){jQuery(".bd-"+b.replace("_","-")+"-pro").hide(),jQuery("#smbd_"+b+"_cron_freq, #smbd_"+b+"_cron_start, #smbd_"+b+"_cron").removeAttr("disabled")}),jQuery('button[name="bd_action"]').click(function(){var a=jQuery(this).val(),b=!1,c="deletePostsWarning",d="selectPostOption";return a in BulkWP.validators?b=BulkWP[BulkWP.validators[a]](this):jQuery(this).parent().prev().children("table").find(":checkbox:checked[value!='true']").size()>0&&(b=!0),b?(a in BulkWP.pre_action_msg&&(c=BulkWP.pre_action_msg[a]),confirm(BulkWP.msg[c])):(a in BulkWP.error_msg&&(d=BulkWP.error_msg[a]),alert(BulkWP.msg[d]),!1)}),BulkWP.noValidation=function(){return!0},BulkWP.validateSelect2=function(a){return null!==jQuery(a).parent().prev().children().find(".select2[multiple]").val()?!0:!1},BulkWP.validateUrl=function(a){return""!==jQuery(a).parent().prev().children("table").find("textarea").val()?!0:!1},BulkWP.validateUserMeta=function(){return""!==jQuery("#smbd_u_meta_value").val()?!0:!1}});
1
+ /*! Bulk Delete - v5.6.0
2
  * http://bulkwp.com
3
  * Copyright (c) 2017; * Licensed GPLv2+ */
4
+ jQuery(document).ready(function(){function a(a){jQuery("#smbd"+a+"_restrict").is(":checked")?(jQuery("#smbd"+a+"_op").removeAttr("disabled"),jQuery("#smbd"+a+"_days").removeAttr("disabled")):(jQuery("#smbd"+a+"_op").attr("disabled","true"),jQuery("#smbd"+a+"_days").attr("disabled","true"))}function b(a){jQuery("#smbd"+a+"_limit").is(":checked")?jQuery("#smbd"+a+"_limit_to").removeAttr("disabled"):jQuery("#smbd"+a+"_limit_to").attr("disabled","true")}function c(a){jQuery("#smbd"+a+"_login_restrict").is(":checked")?jQuery("#smbd"+a+"_login_days").removeAttr("disabled"):jQuery("#smbd"+a+"_login_days").attr("disabled","true")}function d(a){jQuery("#smbd"+a+"_registered_restrict").is(":checked")?jQuery("#smbd"+a+"_registered_days").removeAttr("disabled"):jQuery("#smbd"+a+"_registered_days").attr("disabled","true")}function e(a){jQuery("#smbd"+a+"_no_posts").is(":checked")?jQuery("tr#smbd"+a+"-post-type-dropdown").show():jQuery("tr#smbd"+a+"-post-type-dropdown").hide()}function f(){jQuery("table.terms").hide(),jQuery("input.terms").attr("checked",!1)}jQuery(".select2").select2(),BulkWP.jetpack(),BulkWP.enableHelpTooltips(jQuery(".bd-help")),jQuery(".user_restrict_to_no_posts_filter").change(function(){var a=jQuery(this),b=a.is(":checked"),c=a.parents("table").children().find(".user_restrict_to_no_posts_filter_items");b?c.removeClass("visually-hidden"):c.addClass("visually-hidden")}),postboxes.add_postbox_toggles(pagenow),f(),jQuery(".custom-tax").change(function(){var a=jQuery(this),b=a.val(),c=jQuery("table.terms_"+b);a.is(":checked")&&(f(),c.show("slow"))}),jQuery.each(BulkWP.dt_iterators,function(f,g){jQuery("#smbd"+g+"_cron_start").datetimepicker({timeFormat:"HH:mm:ss"}),jQuery("#smbd"+g+"_restrict").change(function(){a(g)}),jQuery("#smbd"+g+"_limit").change(function(){b(g)}),jQuery("#smbd"+g+"_login_restrict").change(function(){c(g)}),jQuery("#smbd"+g+"_registered_restrict").change(function(){d(g)}),jQuery("#smbd"+g+"_no_posts").change(function(){e(g)})}),jQuery.each(BulkWP.pro_iterators,function(a,b){jQuery(".bd-"+b.replace("_","-")+"-pro").hide(),jQuery("#smbd_"+b+"_cron_freq, #smbd_"+b+"_cron_start, #smbd_"+b+"_cron").removeAttr("disabled")}),jQuery('button[name="bd_action"]').click(function(){var a=jQuery(this).val(),b=!1,c="deletePostsWarning",d="selectPostOption";return a in BulkWP.validators?b=BulkWP[BulkWP.validators[a]](this):jQuery(this).parent().prev().children("table").find(":checkbox:checked[value!='true']").size()>0&&(b=!0),b?(a in BulkWP.pre_action_msg&&(c=BulkWP.pre_action_msg[a]),confirm(BulkWP.msg[c])):(a in BulkWP.error_msg&&(d=BulkWP.error_msg[a]),alert(BulkWP.msg[d]),!1)}),BulkWP.noValidation=function(){return!0},BulkWP.validateSelect2=function(a){return null!==jQuery(a).parent().prev().children().find(".select2[multiple]").val()?!0:!1},BulkWP.validateUrl=function(a){return""!==jQuery(a).parent().prev().children("table").find("textarea").val()?!0:!1},BulkWP.validateUserMeta=function(){return""!==jQuery("#smbd_u_meta_value").val()?!0:!1}}),BulkWP.jetpack=function(){jQuery(".bd-feedback-pro").hide(),jQuery("#smbd_feedback_cron_freq, #smbd_feedback_cron_start, #smbd_feedback_cron").removeAttr("disabled"),jQuery("#smbd_feedback_use_filter").removeAttr("disabled"),jQuery('input[name="smbd_feedback_use_filter"]').change(function(){"true"===jQuery(this).val()?jQuery("#jetpack-filters").show():jQuery("#jetpack-filters").hide()}),jQuery.each(["name","email","ip"],function(a,b){jQuery("#smbd_feedback_author_"+b+"_filter").change(function(){jQuery(this).is(":checked")?(jQuery("#smbd_feedback_author_"+b+"_op").removeAttr("disabled"),jQuery("#smbd_feedback_author_"+b+"_value").removeAttr("disabled")):(jQuery("#smbd_feedback_author_"+b+"_op").attr("disabled","true"),jQuery("#smbd_feedback_author_"+b+"_value").attr("disabled","true"))})})},BulkWP.enableHelpTooltips=function(a){a.tooltip({content:function(){return jQuery(this).prop("title")},position:{my:"center top",at:"center bottom+10",collision:"flipfit"},hide:{duration:200},show:{duration:200}})};
bulk-delete.php CHANGED
@@ -5,17 +5,19 @@
5
  * Plugin URI: http://bulkwp.com
6
  * Description: Bulk delete users and posts from selected categories, tags, post types, custom taxonomies or by post status like drafts, scheduled posts, revisions etc.
7
  * Donate Link: http://sudarmuthu.com/if-you-wanna-thank-me
8
- * Version: 5.5.7
9
  * License: GPL
10
  * Author: Sudar
11
  * Author URI: http://sudarmuthu.com/
12
  * Text Domain: bulk-delete
13
  * Domain Path: languages/
14
  * === RELEASE NOTES ===
15
- * Check readme file for full release notes
 
 
16
  *
17
- * @version 5.5.7
18
  * @author Sudar
 
19
  * @package BulkDelete
20
  */
21
 
@@ -30,20 +32,19 @@
30
  * GNU General Public License for more details.
31
  * You should have received a copy of the GNU General Public License
32
  * along with this program; if not, write to the Free Software
33
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
34
  */
35
-
36
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
37
 
38
  /**
39
- * Main Bulk_Delete class
40
  *
41
  * Singleton @since 5.0
42
  */
43
  final class Bulk_Delete {
44
-
45
  /**
46
  * @var Bulk_Delete The one true Bulk_Delete
 
47
  * @since 5.0
48
  */
49
  private static $instance;
@@ -51,7 +52,7 @@ final class Bulk_Delete {
51
  private $controller;
52
 
53
  // version
54
- const VERSION = '5.5.7';
55
 
56
  // Numeric constants
57
  const MENU_ORDER = '26';
@@ -130,7 +131,7 @@ final class Bulk_Delete {
130
  public $users_page;
131
 
132
  /**
133
- * Main Bulk_Delete Instance
134
  *
135
  * Insures that only one instance of Bulk_Delete exists in memory at any one
136
  * time. Also prevents needing to define globals all over the place.
@@ -138,11 +139,14 @@ final class Bulk_Delete {
138
  * @since 5.0
139
  * @static
140
  * @staticvar array $instance
 
141
  * @see BULK_DELETE()
 
142
  * @uses Bulk_Delete::setup_paths() Setup the plugin paths
143
  * @uses Bulk_Delete::includes() Include the required files
144
  * @uses Bulk_Delete::load_textdomain() Load text domain for translation
145
  * @uses Bulk_Delete::setup_actions() Setup the hooks and actions
 
146
  * @return Bulk_Delete The one true instance of Bulk_Delete
147
  */
148
  public static function instance() {
@@ -153,17 +157,19 @@ final class Bulk_Delete {
153
  self::$instance->load_textdomain();
154
  self::$instance->setup_actions();
155
  }
 
156
  return self::$instance;
157
  }
158
 
159
  /**
160
- * Throw error on object clone
161
  *
162
  * The whole idea of the singleton design pattern is that there is a single
163
  * object therefore, we don't want the object to be cloned.
164
  *
165
  * @since 5.0
166
  * @access protected
 
167
  * @return void
168
  */
169
  public function __clone() {
@@ -172,10 +178,11 @@ final class Bulk_Delete {
172
  }
173
 
174
  /**
175
- * Disable unserializing of the class
176
  *
177
  * @since 5.0
178
  * @access protected
 
179
  * @return void
180
  */
181
  public function __wakeup() {
@@ -184,10 +191,12 @@ final class Bulk_Delete {
184
  }
185
 
186
  /**
187
- * Setup plugin constants
188
  *
189
  * @access private
 
190
  * @since 5.0
 
191
  * @return void
192
  */
193
  private function setup_paths() {
@@ -202,10 +211,12 @@ final class Bulk_Delete {
202
  }
203
 
204
  /**
205
- * Include required files
206
  *
207
  * @access private
 
208
  * @since 5.0
 
209
  * @return void
210
  */
211
  private function includes() {
@@ -268,7 +279,7 @@ final class Bulk_Delete {
268
  }
269
 
270
  /**
271
- * Loads the plugin language files
272
  *
273
  * @since 5.0
274
  */
@@ -279,20 +290,52 @@ final class Bulk_Delete {
279
  }
280
 
281
  /**
282
- * Loads the plugin's actions and hooks
283
  *
284
  * @access private
 
285
  * @since 5.0
 
286
  * @return void
287
  */
288
  private function setup_actions() {
289
  $this->controller = new BD_Controller();
290
 
291
  add_action( 'admin_menu', array( $this, 'add_menu' ) );
 
 
 
 
 
 
292
  }
293
 
294
  /**
295
- * Add navigation menu
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
296
  */
297
  public function add_menu() {
298
  add_menu_page( __( 'Bulk WP', 'bulk-delete' ), __( 'Bulk WP', 'bulk-delete' ), 'manage_options', self::POSTS_PAGE_SLUG, array( $this, 'display_posts_page' ), 'dashicons-trash', self::MENU_ORDER );
@@ -301,7 +344,7 @@ final class Bulk_Delete {
301
  $this->pages_page = add_submenu_page( self::POSTS_PAGE_SLUG, __( 'Bulk Delete Pages', 'bulk-delete' ), __( 'Bulk Delete Pages', 'bulk-delete' ), 'delete_pages', self::PAGES_PAGE_SLUG, array( $this, 'display_pages_page' ) );
302
 
303
  /**
304
- * Runs just after adding all *delete* menu items to Bulk WP main menu
305
  *
306
  * This action is primarily for adding extra *delete* menu items to the Bulk WP main menu.
307
  *
@@ -310,7 +353,7 @@ final class Bulk_Delete {
310
  do_action( 'bd_after_primary_menus' );
311
 
312
  /**
313
- * Runs just before adding non-action menu items to Bulk WP main menu
314
  *
315
  * This action is primarily for adding extra menu items before non-action menu items to the Bulk WP main menu.
316
  *
@@ -322,7 +365,7 @@ final class Bulk_Delete {
322
  $this->addon_page = add_submenu_page( self::POSTS_PAGE_SLUG, __( 'Addon Licenses' , 'bulk-delete' ), __( 'Addon Licenses', 'bulk-delete' ), 'activate_plugins', self::ADDON_PAGE_SLUG, array( 'BD_License', 'display_addon_page' ) );
323
 
324
  /**
325
- * Runs just after adding all menu items to Bulk WP main menu
326
  *
327
  * This action is primarily for adding extra menu items to the Bulk WP main menu.
328
  *
@@ -344,12 +387,11 @@ final class Bulk_Delete {
344
  }
345
 
346
  /**
347
- * Add settings Panel for delete posts page
348
  */
349
  public function add_delete_posts_settings_panel() {
350
-
351
  /**
352
- * Add contextual help for admin screens
353
  *
354
  * @since 5.1
355
  */
@@ -363,7 +405,7 @@ final class Bulk_Delete {
363
  }
364
 
365
  /**
366
- * Register meta boxes for delete posts page
367
  */
368
  public function add_delete_posts_meta_boxes() {
369
  add_meta_box( self::BOX_POST_STATUS , __( 'By Post Status' , 'bulk-delete' ) , 'Bulk_Delete_Posts::render_delete_posts_by_status_box' , $this->posts_page , 'advanced' );
@@ -376,7 +418,7 @@ final class Bulk_Delete {
376
 
377
  /**
378
  * Add meta box in delete posts page
379
- * This hook can be used for adding additional meta boxes in delete posts page
380
  *
381
  * @since 5.3
382
  */
@@ -384,14 +426,13 @@ final class Bulk_Delete {
384
  }
385
 
386
  /**
387
- * Setup settings panel for delete pages page
388
  *
389
  * @since 5.0
390
  */
391
  public function add_delete_pages_settings_panel() {
392
-
393
  /**
394
- * Add contextual help for admin screens
395
  *
396
  * @since 5.1
397
  */
@@ -405,7 +446,7 @@ final class Bulk_Delete {
405
  }
406
 
407
  /**
408
- * Register meta boxes for delete pages page
409
  *
410
  * @since 5.0
411
  */
@@ -414,7 +455,7 @@ final class Bulk_Delete {
414
 
415
  /**
416
  * Add meta box in delete pages page
417
- * This hook can be used for adding additional meta boxes in delete pages page
418
  *
419
  * @since 5.3
420
  */
@@ -443,15 +484,15 @@ final class Bulk_Delete {
443
  wp_enqueue_style( 'select2', plugins_url( '/assets/css/select2.min.css', __FILE__ ), array(), '4.0.0' );
444
 
445
  $postfix = ( defined( 'SCRIPT_DEBUG' ) && true === SCRIPT_DEBUG ) ? '' : '.min';
446
- wp_enqueue_script( self::JS_HANDLE, plugins_url( '/assets/js/bulk-delete' . $postfix . '.js', __FILE__ ), array( 'jquery-ui-timepicker' ), self::VERSION, true );
447
  wp_enqueue_style( self::CSS_HANDLE, plugins_url( '/assets/css/bulk-delete' . $postfix . '.css', __FILE__ ), array( 'select2' ), self::VERSION );
448
 
449
- $ui = $wp_scripts->query( 'jquery-ui-core' );
450
  $url = "//ajax.googleapis.com/ajax/libs/jqueryui/{$ui->ver}/themes/smoothness/jquery-ui.css";
451
  wp_enqueue_style( 'jquery-ui-smoothness', $url, false, $ui->ver );
452
 
453
  /**
454
- * Filter JavaScript array
455
  *
456
  * This filter can be used to extend the array that is passed to JavaScript
457
  *
@@ -525,9 +566,10 @@ final class Bulk_Delete {
525
  }
526
 
527
  /**
528
- * Display the delete pages page
529
  *
530
  * @Todo Move this function to Bulk_Delete_Pages class
 
531
  * @since 5.0
532
  */
533
  public function display_pages_page() {
@@ -573,10 +615,9 @@ final class Bulk_Delete {
573
  }
574
 
575
  /**
576
- * Display the schedule page
577
  */
578
  public function display_cron_page() {
579
-
580
  if ( ! class_exists( 'WP_List_Table' ) ) {
581
  require_once ABSPATH . WPINC . '/class-wp-list-table.php';
582
  }
@@ -610,7 +651,6 @@ final class Bulk_Delete {
610
  }
611
  }
612
 
613
-
614
  /**
615
  * The main function responsible for returning the one true Bulk_Delete
616
  * Instance to functions everywhere.
@@ -621,6 +661,7 @@ final class Bulk_Delete {
621
  * Example: `<?php $bulk_delete = BULK_DELETE(); ?>`
622
  *
623
  * @since 5.0
 
624
  * @return Bulk_Delete The one true Bulk_Delete Instance
625
  */
626
  function BULK_DELETE() {
@@ -629,4 +670,3 @@ function BULK_DELETE() {
629
 
630
  // Get BULK_DELETE Running
631
  BULK_DELETE();
632
- ?>
5
  * Plugin URI: http://bulkwp.com
6
  * Description: Bulk delete users and posts from selected categories, tags, post types, custom taxonomies or by post status like drafts, scheduled posts, revisions etc.
7
  * Donate Link: http://sudarmuthu.com/if-you-wanna-thank-me
8
+ * Version: 5.6.0
9
  * License: GPL
10
  * Author: Sudar
11
  * Author URI: http://sudarmuthu.com/
12
  * Text Domain: bulk-delete
13
  * Domain Path: languages/
14
  * === RELEASE NOTES ===
15
+ * Check readme file for full release notes.
16
+ *
17
+ * @version 5.6.0
18
  *
 
19
  * @author Sudar
20
+ *
21
  * @package BulkDelete
22
  */
23
 
32
  * GNU General Public License for more details.
33
  * You should have received a copy of the GNU General Public License
34
  * along with this program; if not, write to the Free Software
35
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
36
  */
 
37
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
38
 
39
  /**
40
+ * Main Bulk_Delete class.
41
  *
42
  * Singleton @since 5.0
43
  */
44
  final class Bulk_Delete {
 
45
  /**
46
  * @var Bulk_Delete The one true Bulk_Delete
47
+ *
48
  * @since 5.0
49
  */
50
  private static $instance;
52
  private $controller;
53
 
54
  // version
55
+ const VERSION = '5.6.0';
56
 
57
  // Numeric constants
58
  const MENU_ORDER = '26';
131
  public $users_page;
132
 
133
  /**
134
+ * Main Bulk_Delete Instance.
135
  *
136
  * Insures that only one instance of Bulk_Delete exists in memory at any one
137
  * time. Also prevents needing to define globals all over the place.
139
  * @since 5.0
140
  * @static
141
  * @staticvar array $instance
142
+ *
143
  * @see BULK_DELETE()
144
+ *
145
  * @uses Bulk_Delete::setup_paths() Setup the plugin paths
146
  * @uses Bulk_Delete::includes() Include the required files
147
  * @uses Bulk_Delete::load_textdomain() Load text domain for translation
148
  * @uses Bulk_Delete::setup_actions() Setup the hooks and actions
149
+ *
150
  * @return Bulk_Delete The one true instance of Bulk_Delete
151
  */
152
  public static function instance() {
157
  self::$instance->load_textdomain();
158
  self::$instance->setup_actions();
159
  }
160
+
161
  return self::$instance;
162
  }
163
 
164
  /**
165
+ * Throw error on object clone.
166
  *
167
  * The whole idea of the singleton design pattern is that there is a single
168
  * object therefore, we don't want the object to be cloned.
169
  *
170
  * @since 5.0
171
  * @access protected
172
+ *
173
  * @return void
174
  */
175
  public function __clone() {
178
  }
179
 
180
  /**
181
+ * Disable unserializing of the class.
182
  *
183
  * @since 5.0
184
  * @access protected
185
+ *
186
  * @return void
187
  */
188
  public function __wakeup() {
191
  }
192
 
193
  /**
194
+ * Setup plugin constants.
195
  *
196
  * @access private
197
+ *
198
  * @since 5.0
199
+ *
200
  * @return void
201
  */
202
  private function setup_paths() {
211
  }
212
 
213
  /**
214
+ * Include required files.
215
  *
216
  * @access private
217
+ *
218
  * @since 5.0
219
+ *
220
  * @return void
221
  */
222
  private function includes() {
279
  }
280
 
281
  /**
282
+ * Loads the plugin language files.
283
  *
284
  * @since 5.0
285
  */
290
  }
291
 
292
  /**
293
+ * Loads the plugin's actions and hooks.
294
  *
295
  * @access private
296
+ *
297
  * @since 5.0
298
+ *
299
  * @return void
300
  */
301
  private function setup_actions() {
302
  $this->controller = new BD_Controller();
303
 
304
  add_action( 'admin_menu', array( $this, 'add_menu' ) );
305
+
306
+ add_filter( 'bd_help_tooltip', 'bd_generate_help_tooltip', 10, 2 );
307
+
308
+ if ( defined( 'BD_DEBUG' ) && BD_DEBUG ) {
309
+ add_action( 'bd_after_query', array( $this, 'log_sql_query' ) );
310
+ }
311
  }
312
 
313
  /**
314
+ * Log SQL query used by Bulk Delete.
315
+ *
316
+ * Query is logged only when `BD_DEBUG` is set.
317
+ *
318
+ * @since 5.6
319
+ *
320
+ * @param \WP_Query $wp_query WP Query object.
321
+ */
322
+ public function log_sql_query( $wp_query ) {
323
+ $query = $wp_query->request;
324
+
325
+ /**
326
+ * Bulk Delete query is getting logged.
327
+ *
328
+ * @since 5.6
329
+ *
330
+ * @param string $query Bulk Delete SQL Query.
331
+ */
332
+ do_action( 'bd_log_sql_query', $query );
333
+
334
+ error_log( 'Bulk Delete Query: ' . $query );
335
+ }
336
+
337
+ /**
338
+ * Add navigation menu.
339
  */
340
  public function add_menu() {
341
  add_menu_page( __( 'Bulk WP', 'bulk-delete' ), __( 'Bulk WP', 'bulk-delete' ), 'manage_options', self::POSTS_PAGE_SLUG, array( $this, 'display_posts_page' ), 'dashicons-trash', self::MENU_ORDER );
344
  $this->pages_page = add_submenu_page( self::POSTS_PAGE_SLUG, __( 'Bulk Delete Pages', 'bulk-delete' ), __( 'Bulk Delete Pages', 'bulk-delete' ), 'delete_pages', self::PAGES_PAGE_SLUG, array( $this, 'display_pages_page' ) );
345
 
346
  /**
347
+ * Runs just after adding all *delete* menu items to Bulk WP main menu.
348
  *
349
  * This action is primarily for adding extra *delete* menu items to the Bulk WP main menu.
350
  *
353
  do_action( 'bd_after_primary_menus' );
354
 
355
  /**
356
+ * Runs just before adding non-action menu items to Bulk WP main menu.
357
  *
358
  * This action is primarily for adding extra menu items before non-action menu items to the Bulk WP main menu.
359
  *
365
  $this->addon_page = add_submenu_page( self::POSTS_PAGE_SLUG, __( 'Addon Licenses' , 'bulk-delete' ), __( 'Addon Licenses', 'bulk-delete' ), 'activate_plugins', self::ADDON_PAGE_SLUG, array( 'BD_License', 'display_addon_page' ) );
366
 
367
  /**
368
+ * Runs just after adding all menu items to Bulk WP main menu.
369
  *
370
  * This action is primarily for adding extra menu items to the Bulk WP main menu.
371
  *
387
  }
388
 
389
  /**
390
+ * Add settings Panel for delete posts page.
391
  */
392
  public function add_delete_posts_settings_panel() {
 
393
  /**
394
+ * Add contextual help for admin screens.
395
  *
396
  * @since 5.1
397
  */
405
  }
406
 
407
  /**
408
+ * Register meta boxes for delete posts page.
409
  */
410
  public function add_delete_posts_meta_boxes() {
411
  add_meta_box( self::BOX_POST_STATUS , __( 'By Post Status' , 'bulk-delete' ) , 'Bulk_Delete_Posts::render_delete_posts_by_status_box' , $this->posts_page , 'advanced' );
418
 
419
  /**
420
  * Add meta box in delete posts page
421
+ * This hook can be used for adding additional meta boxes in delete posts page.
422
  *
423
  * @since 5.3
424
  */
426
  }
427
 
428
  /**
429
+ * Setup settings panel for delete pages page.
430
  *
431
  * @since 5.0
432
  */
433
  public function add_delete_pages_settings_panel() {
 
434
  /**
435
+ * Add contextual help for admin screens.
436
  *
437
  * @since 5.1
438
  */
446
  }
447
 
448
  /**
449
+ * Register meta boxes for delete pages page.
450
  *
451
  * @since 5.0
452
  */
455
 
456
  /**
457
  * Add meta box in delete pages page
458
+ * This hook can be used for adding additional meta boxes in delete pages page.
459
  *
460
  * @since 5.3
461
  */
484
  wp_enqueue_style( 'select2', plugins_url( '/assets/css/select2.min.css', __FILE__ ), array(), '4.0.0' );
485
 
486
  $postfix = ( defined( 'SCRIPT_DEBUG' ) && true === SCRIPT_DEBUG ) ? '' : '.min';
487
+ wp_enqueue_script( self::JS_HANDLE, plugins_url( '/assets/js/bulk-delete' . $postfix . '.js', __FILE__ ), array( 'jquery-ui-timepicker', 'jquery-ui-tooltip' ), self::VERSION, true );
488
  wp_enqueue_style( self::CSS_HANDLE, plugins_url( '/assets/css/bulk-delete' . $postfix . '.css', __FILE__ ), array( 'select2' ), self::VERSION );
489
 
490
+ $ui = $wp_scripts->query( 'jquery-ui-core' );
491
  $url = "//ajax.googleapis.com/ajax/libs/jqueryui/{$ui->ver}/themes/smoothness/jquery-ui.css";
492
  wp_enqueue_style( 'jquery-ui-smoothness', $url, false, $ui->ver );
493
 
494
  /**
495
+ * Filter JavaScript array.
496
  *
497
  * This filter can be used to extend the array that is passed to JavaScript
498
  *
566
  }
567
 
568
  /**
569
+ * Display the delete pages page.
570
  *
571
  * @Todo Move this function to Bulk_Delete_Pages class
572
+ *
573
  * @since 5.0
574
  */
575
  public function display_pages_page() {
615
  }
616
 
617
  /**
618
+ * Display the schedule page.
619
  */
620
  public function display_cron_page() {
 
621
  if ( ! class_exists( 'WP_List_Table' ) ) {
622
  require_once ABSPATH . WPINC . '/class-wp-list-table.php';
623
  }
651
  }
652
  }
653
 
 
654
  /**
655
  * The main function responsible for returning the one true Bulk_Delete
656
  * Instance to functions everywhere.
661
  * Example: `<?php $bulk_delete = BULK_DELETE(); ?>`
662
  *
663
  * @since 5.0
664
+ *
665
  * @return Bulk_Delete The one true Bulk_Delete Instance
666
  */
667
  function BULK_DELETE() {
670
 
671
  // Get BULK_DELETE Running
672
  BULK_DELETE();
 
include/addons/addon-list.php CHANGED
@@ -3,14 +3,15 @@
3
  * Addon related util functions.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Util\Addon
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
- * Display information about all available addons
14
  *
15
  * @since 5.5
16
  */
@@ -143,4 +144,3 @@ function bd_display_available_addon_list() {
143
 
144
  echo '</ul>';
145
  }
146
- ?>
3
  * Addon related util functions.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Util\Addon
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
+ * Display information about all available addons.
15
  *
16
  * @since 5.5
17
  */
144
 
145
  echo '</ul>';
146
  }
 
include/addons/base/class-bd-addon.php CHANGED
@@ -3,16 +3,18 @@
3
  * Base class for all BD Addons.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Addons\Base
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
  * Base class for BD Addons.
14
  *
15
  * @abstract
 
16
  * @since 5.5
17
  */
18
  abstract class BD_Addon {
@@ -56,16 +58,16 @@ abstract class BD_Addon {
56
  *
57
  * @since 5.5
58
  * @abstract
 
59
  * @return void
60
  */
61
  abstract protected function initialize();
62
 
63
  /**
64
  * Use `factory()` method to create instance of this class.
65
- * Don't create instances directly
66
  *
67
  * @since 5.5
68
- *
69
  * @see factory()
70
  */
71
  public function __construct() {
@@ -76,6 +78,7 @@ abstract class BD_Addon {
76
  * Setup the module.
77
  *
78
  * @access protected
 
79
  * @since 5.5
80
  */
81
  protected function setup() {
@@ -100,6 +103,7 @@ abstract class BD_Addon {
100
  * Setup translation.
101
  *
102
  * @access protected
 
103
  * @since 5.5
104
  */
105
  protected function setup_translation() {
@@ -117,7 +121,7 @@ abstract class BD_Addon {
117
  * @param string $plugin_file Addon file name relative to plugin directory.
118
  */
119
  public function setup_license_handler( $plugin_file ) {
120
- $this->addon_file = $plugin_file;
121
  $this->license_handler = new BD_License_Handler(
122
  $this->addon_name,
123
  $this->addon_code,
@@ -131,10 +135,10 @@ abstract class BD_Addon {
131
  * Get addon class name.
132
  *
133
  * @since 5.5
 
134
  * @return string Addon class name
135
  */
136
  protected function get_addon_class_name() {
137
  return bd_get_addon_class_name( $this->addon_name );
138
  }
139
  }
140
- ?>
3
  * Base class for all BD Addons.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Addons\Base
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
  * Base class for BD Addons.
15
  *
16
  * @abstract
17
+ *
18
  * @since 5.5
19
  */
20
  abstract class BD_Addon {
58
  *
59
  * @since 5.5
60
  * @abstract
61
+ *
62
  * @return void
63
  */
64
  abstract protected function initialize();
65
 
66
  /**
67
  * Use `factory()` method to create instance of this class.
68
+ * Don't create instances directly.
69
  *
70
  * @since 5.5
 
71
  * @see factory()
72
  */
73
  public function __construct() {
78
  * Setup the module.
79
  *
80
  * @access protected
81
+ *
82
  * @since 5.5
83
  */
84
  protected function setup() {
103
  * Setup translation.
104
  *
105
  * @access protected
106
+ *
107
  * @since 5.5
108
  */
109
  protected function setup_translation() {
121
  * @param string $plugin_file Addon file name relative to plugin directory.
122
  */
123
  public function setup_license_handler( $plugin_file ) {
124
+ $this->addon_file = $plugin_file;
125
  $this->license_handler = new BD_License_Handler(
126
  $this->addon_name,
127
  $this->addon_code,
135
  * Get addon class name.
136
  *
137
  * @since 5.5
138
+ *
139
  * @return string Addon class name
140
  */
141
  protected function get_addon_class_name() {
142
  return bd_get_addon_class_name( $this->addon_name );
143
  }
144
  }
 
include/addons/base/class-bd-base-addon.php CHANGED
@@ -3,26 +3,26 @@
3
  * Base class for all Base Addons.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Addons\Base
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
  * Base class for Base Addons.
14
  *
15
  * @abstract
 
16
  * @since 5.5
17
  */
18
  abstract class BD_Base_Addon extends BD_Addon {
19
-
20
  /**
21
  * Use `factory()` method to create instance of this class.
22
- * Don't create instances directly
23
  *
24
  * @since 5.5
25
- *
26
  * @see factory()
27
  */
28
  public function __construct() {
@@ -42,6 +42,7 @@ abstract class BD_Base_Addon extends BD_Addon {
42
  * Getter for cron hook.
43
  *
44
  * @since 5.5
 
45
  * @return string Cron hook.
46
  */
47
  public function get_cron_hook() {
@@ -52,10 +53,10 @@ abstract class BD_Base_Addon extends BD_Addon {
52
  * Return reference to the module.
53
  *
54
  * @since 5.5
 
55
  * @return Module Reference to Module Object
56
  */
57
  public function get_module() {
58
  return $this->module;
59
  }
60
  }
61
- ?>
3
  * Base class for all Base Addons.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Addons\Base
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
  * Base class for Base Addons.
15
  *
16
  * @abstract
17
+ *
18
  * @since 5.5
19
  */
20
  abstract class BD_Base_Addon extends BD_Addon {
 
21
  /**
22
  * Use `factory()` method to create instance of this class.
23
+ * Don't create instances directly.
24
  *
25
  * @since 5.5
 
26
  * @see factory()
27
  */
28
  public function __construct() {
42
  * Getter for cron hook.
43
  *
44
  * @since 5.5
45
+ *
46
  * @return string Cron hook.
47
  */
48
  public function get_cron_hook() {
53
  * Return reference to the module.
54
  *
55
  * @since 5.5
56
+ *
57
  * @return Module Reference to Module Object
58
  */
59
  public function get_module() {
60
  return $this->module;
61
  }
62
  }
 
include/addons/base/class-bd-scheduler-addon.php CHANGED
@@ -3,20 +3,21 @@
3
  * Base class for all Scheduler Addons.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Addons\Base
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
  * Base class for Base Addons.
14
  *
15
  * @abstract
 
16
  * @since 5.5
17
  */
18
  abstract class BD_Scheduler_Addon extends BD_Addon {
19
-
20
  /**
21
  * @var No base addon for this scheduler addon.
22
  */
@@ -49,10 +50,9 @@ abstract class BD_Scheduler_Addon extends BD_Addon {
49
 
50
  /**
51
  * Use `factory()` method to create instance of this class.
52
- * Don't create instances directly
53
  *
54
  * @since 5.5
55
- *
56
  * @see factory()
57
  */
58
  public function __construct() {
@@ -63,11 +63,14 @@ abstract class BD_Scheduler_Addon extends BD_Addon {
63
  * Check if the base addon is available.
64
  *
65
  * @access protected
 
66
  * @since 5.5
67
  *
68
  * @todo check for version as well
69
  *
70
  * @param string Base Addon class name. Default null. If not specified then it is auto calculated based on addon name.
 
 
71
  * @return bool True if base addon is found, False other wise
72
  */
73
  protected function check_base_addon( $addon_class_name = null ) {
@@ -80,9 +83,11 @@ abstract class BD_Scheduler_Addon extends BD_Addon {
80
  if ( class_exists( $this->base_addon_class_name ) ) {
81
  // Ugly workaround, since we need to support PHP 5.2
82
  $this->base_addon_obj = call_user_func( array( $this->base_addon_class_name, 'factory' ) );
 
83
  return true;
84
  } else {
85
  add_action( 'admin_notices', array( $this, 'addon_missing_notice' ) );
 
86
  return false;
87
  }
88
  }
@@ -125,8 +130,10 @@ abstract class BD_Scheduler_Addon extends BD_Addon {
125
  * Filter JS Array and add pro hooks.
126
  *
127
  * @since 5.5
128
- * @param array $js_array JavaScript Array
129
- * @return array Modified JavaScript Array
 
 
130
  */
131
  public function filter_js_array( $js_array ) {
132
  $js_array['pro_iterators'][] = $this->get_module()->get_field_slug();
@@ -138,6 +145,7 @@ abstract class BD_Scheduler_Addon extends BD_Addon {
138
  * Hook handler.
139
  *
140
  * @since 5.5
 
141
  * @param array $delete_options
142
  */
143
  public function do_delete( $delete_options ) {
@@ -150,7 +158,9 @@ abstract class BD_Scheduler_Addon extends BD_Addon {
150
  * Get the cron hook.
151
  *
152
  * @access protected
 
153
  * @since 5.5
 
154
  * @return string Cron hook.
155
  */
156
  protected function get_cron_hook() {
@@ -166,7 +176,9 @@ abstract class BD_Scheduler_Addon extends BD_Addon {
166
  * Get base module.
167
  *
168
  * @access protected
 
169
  * @since 5.5
 
170
  * @return object Base module object
171
  */
172
  protected function get_module() {
@@ -177,4 +189,3 @@ abstract class BD_Scheduler_Addon extends BD_Addon {
177
  }
178
  }
179
  }
180
- ?>
3
  * Base class for all Scheduler Addons.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Addons\Base
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
  * Base class for Base Addons.
15
  *
16
  * @abstract
17
+ *
18
  * @since 5.5
19
  */
20
  abstract class BD_Scheduler_Addon extends BD_Addon {
 
21
  /**
22
  * @var No base addon for this scheduler addon.
23
  */
50
 
51
  /**
52
  * Use `factory()` method to create instance of this class.
53
+ * Don't create instances directly.
54
  *
55
  * @since 5.5
 
56
  * @see factory()
57
  */
58
  public function __construct() {
63
  * Check if the base addon is available.
64
  *
65
  * @access protected
66
+ *
67
  * @since 5.5
68
  *
69
  * @todo check for version as well
70
  *
71
  * @param string Base Addon class name. Default null. If not specified then it is auto calculated based on addon name.
72
+ * @param mixed|null $addon_class_name
73
+ *
74
  * @return bool True if base addon is found, False other wise
75
  */
76
  protected function check_base_addon( $addon_class_name = null ) {
83
  if ( class_exists( $this->base_addon_class_name ) ) {
84
  // Ugly workaround, since we need to support PHP 5.2
85
  $this->base_addon_obj = call_user_func( array( $this->base_addon_class_name, 'factory' ) );
86
+
87
  return true;
88
  } else {
89
  add_action( 'admin_notices', array( $this, 'addon_missing_notice' ) );
90
+
91
  return false;
92
  }
93
  }
130
  * Filter JS Array and add pro hooks.
131
  *
132
  * @since 5.5
133
+ *
134
+ * @param array $js_array JavaScript Array
135
+ *
136
+ * @return array Modified JavaScript Array
137
  */
138
  public function filter_js_array( $js_array ) {
139
  $js_array['pro_iterators'][] = $this->get_module()->get_field_slug();
145
  * Hook handler.
146
  *
147
  * @since 5.5
148
+ *
149
  * @param array $delete_options
150
  */
151
  public function do_delete( $delete_options ) {
158
  * Get the cron hook.
159
  *
160
  * @access protected
161
+ *
162
  * @since 5.5
163
+ *
164
  * @return string Cron hook.
165
  */
166
  protected function get_cron_hook() {
176
  * Get base module.
177
  *
178
  * @access protected
179
+ *
180
  * @since 5.5
181
+ *
182
  * @return object Base module object
183
  */
184
  protected function get_module() {
189
  }
190
  }
191
  }
 
include/addons/pages.php CHANGED
@@ -3,10 +3,11 @@
3
  * Page Addons related functions.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Addon
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -29,6 +30,7 @@ add_action( 'bd_add_meta_box_for_pages', 'bd_register_page_addons' );
29
  function bd_render_delete_pages_from_trash() {
30
  if ( BD_Util::is_pages_box_hidden( Bulk_Delete::BOX_PAGE_FROM_TRASH ) ) {
31
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::PAGES_PAGE_SLUG );
 
32
  return;
33
  }
34
 
@@ -44,9 +46,8 @@ function bd_render_delete_pages_from_trash() {
44
  <!-- pages In Trash box end-->
45
  <?php
46
  } else {
47
-
48
  /**
49
- * Render delete pages from trash box
50
  *
51
  * @since 5.4
52
  */
3
  * Page Addons related functions.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Addon
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
30
  function bd_render_delete_pages_from_trash() {
31
  if ( BD_Util::is_pages_box_hidden( Bulk_Delete::BOX_PAGE_FROM_TRASH ) ) {
32
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::PAGES_PAGE_SLUG );
33
+
34
  return;
35
  }
36
 
46
  <!-- pages In Trash box end-->
47
  <?php
48
  } else {
 
49
  /**
50
+ * Render delete pages from trash box.
51
  *
52
  * @since 5.4
53
  */
include/addons/posts.php CHANGED
@@ -3,10 +3,11 @@
3
  * Post Addons related functions.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Addon
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -26,14 +27,14 @@ function bd_register_post_addons() {
26
  add_action( 'bd_add_meta_box_for_posts', 'bd_register_post_addons' );
27
 
28
  /**
29
- * Render delete posts by custom field box
30
  *
31
  * @since 5.5
32
  */
33
  function bd_render_delete_posts_by_custom_field_box() {
34
-
35
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_CUSTOM_FIELD ) ) {
36
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
37
  return;
38
  }
39
 
@@ -54,14 +55,14 @@ function bd_render_delete_posts_by_custom_field_box() {
54
  }
55
 
56
  /**
57
- * Render posts by title box
58
  *
59
  * @since 5.5
60
  */
61
  function bd_render_delete_posts_by_title_box() {
62
-
63
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_TITLE ) ) {
64
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
65
  return;
66
  }
67
 
@@ -82,14 +83,14 @@ function bd_render_delete_posts_by_title_box() {
82
  }
83
 
84
  /**
85
- * Render delete posts by duplicate title box
86
  *
87
  * @since 5.5
88
  */
89
  function bd_render_delete_posts_by_duplicate_title_box() {
90
-
91
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_DUPLICATE_TITLE ) ) {
92
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
93
  return;
94
  }
95
 
@@ -110,14 +111,14 @@ function bd_render_delete_posts_by_duplicate_title_box() {
110
  }
111
 
112
  /**
113
- * Delete posts by user role
114
  *
115
  * @since 5.5
116
  */
117
  function bd_render_delete_posts_by_user_role_box() {
118
-
119
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_BY_ROLE ) ) {
120
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
121
  return;
122
  }
123
  if ( ! class_exists( 'Bulk_Delete_Posts_By_User_Role' ) ) {
@@ -137,13 +138,14 @@ function bd_render_delete_posts_by_user_role_box() {
137
  }
138
 
139
  /**
140
- * Render delete posts from trash box
141
  *
142
  * @since 5.5
143
  */
144
  function bd_render_delete_posts_from_trash() {
145
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_FROM_TRASH ) ) {
146
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
147
  return;
148
  }
149
 
@@ -159,9 +161,8 @@ function bd_render_delete_posts_from_trash() {
159
  <!-- Posts In Trash box end-->
160
  <?php
161
  } else {
162
-
163
  /**
164
- * Render delete posts from trash box
165
  *
166
  * @since 5.4
167
  */
3
  * Post Addons related functions.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Addon
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
27
  add_action( 'bd_add_meta_box_for_posts', 'bd_register_post_addons' );
28
 
29
  /**
30
+ * Render delete posts by custom field box.
31
  *
32
  * @since 5.5
33
  */
34
  function bd_render_delete_posts_by_custom_field_box() {
 
35
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_CUSTOM_FIELD ) ) {
36
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
37
+
38
  return;
39
  }
40
 
55
  }
56
 
57
  /**
58
+ * Render posts by title box.
59
  *
60
  * @since 5.5
61
  */
62
  function bd_render_delete_posts_by_title_box() {
 
63
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_TITLE ) ) {
64
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
65
+
66
  return;
67
  }
68
 
83
  }
84
 
85
  /**
86
+ * Render delete posts by duplicate title box.
87
  *
88
  * @since 5.5
89
  */
90
  function bd_render_delete_posts_by_duplicate_title_box() {
 
91
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_DUPLICATE_TITLE ) ) {
92
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
93
+
94
  return;
95
  }
96
 
111
  }
112
 
113
  /**
114
+ * Delete posts by user role.
115
  *
116
  * @since 5.5
117
  */
118
  function bd_render_delete_posts_by_user_role_box() {
 
119
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_BY_ROLE ) ) {
120
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
121
+
122
  return;
123
  }
124
  if ( ! class_exists( 'Bulk_Delete_Posts_By_User_Role' ) ) {
138
  }
139
 
140
  /**
141
+ * Render delete posts from trash box.
142
  *
143
  * @since 5.5
144
  */
145
  function bd_render_delete_posts_from_trash() {
146
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_FROM_TRASH ) ) {
147
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
148
+
149
  return;
150
  }
151
 
161
  <!-- Posts In Trash box end-->
162
  <?php
163
  } else {
 
164
  /**
165
+ * Render delete posts from trash box.
166
  *
167
  * @since 5.4
168
  */
include/addons/util.php CHANGED
@@ -3,10 +3,11 @@
3
  * Addons related util functions.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Addon
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -15,6 +16,7 @@ defined( 'ABSPATH' ) || exit; // Exit if accessed directly
15
  * @since 5.5
16
  *
17
  * @param string $addon_name Name of the addon.
 
18
  * @return string Computed class name for the addon.
19
  */
20
  function bd_get_addon_class_name( $addon_name ) {
@@ -32,7 +34,7 @@ function bd_get_addon_class_name( $addon_name ) {
32
  * @since 5.5
33
  *
34
  * @param string $addon_class_name Addon class name
35
- * @param string $addon_name Addon name
36
  */
37
  return apply_filters( 'bd_addon_class_name', $addon_class_name, $addon_name );
38
  }
@@ -42,12 +44,13 @@ function bd_get_addon_class_name( $addon_name ) {
42
  *
43
  * @since 5.5
44
  *
45
- * @param string $addon_name Name of the addon.
46
- * @param array $campaign_args Campaign_args. Default empty array
47
- * @return string Computed url for the addon.
 
48
  */
49
  function bd_get_addon_url( $addon_name, $campaign_args = array() ) {
50
- $base = 'http://bulkwp.com/addons/';
51
  $addon_slug = str_replace( ' ', '-', strtolower( $addon_name ) );
52
 
53
  if ( false !== strpos( $addon_name, 'scheduler' ) ) {
@@ -62,10 +65,9 @@ function bd_get_addon_url( $addon_name, $campaign_args = array() ) {
62
  *
63
  * @since 5.5
64
  *
65
- * @param string $addon_name Addon name
66
- * @param string $addon_url Addon url
67
  * @param array $campaign_args Campaign_args. Default empty array
68
  */
69
  return apply_filters( 'bd_addon_url', $addon_url, $addon_name, $campaign_args );
70
  }
71
- ?>
3
  * Addons related util functions.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Addon
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
16
  * @since 5.5
17
  *
18
  * @param string $addon_name Name of the addon.
19
+ *
20
  * @return string Computed class name for the addon.
21
  */
22
  function bd_get_addon_class_name( $addon_name ) {
34
  * @since 5.5
35
  *
36
  * @param string $addon_class_name Addon class name
37
+ * @param string $addon_name Addon name
38
  */
39
  return apply_filters( 'bd_addon_class_name', $addon_class_name, $addon_name );
40
  }
44
  *
45
  * @since 5.5
46
  *
47
+ * @param string $addon_name Name of the addon.
48
+ * @param array $campaign_args Campaign_args. Default empty array
49
+ *
50
+ * @return string Computed url for the addon.
51
  */
52
  function bd_get_addon_url( $addon_name, $campaign_args = array() ) {
53
+ $base = 'http://bulkwp.com/addons/';
54
  $addon_slug = str_replace( ' ', '-', strtolower( $addon_name ) );
55
 
56
  if ( false !== strpos( $addon_name, 'scheduler' ) ) {
65
  *
66
  * @since 5.5
67
  *
68
+ * @param string $addon_name Addon name
69
+ * @param string $addon_url Addon url
70
  * @param array $campaign_args Campaign_args. Default empty array
71
  */
72
  return apply_filters( 'bd_addon_url', $addon_url, $addon_name, $campaign_args );
73
  }
 
include/base/class-bd-base-page.php CHANGED
@@ -3,16 +3,18 @@
3
  * Base class for all Pages.
4
  *
5
  * @since 5.5.4
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Base\Page
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
  * Base class for Pages.
14
  *
15
  * @abstract
 
16
  * @since 5.5.4
17
  */
18
  abstract class BD_Base_Page {
@@ -62,6 +64,7 @@ abstract class BD_Base_Page {
62
  *
63
  * @since 5.5.4
64
  * @abstract
 
65
  * @return void
66
  */
67
  abstract protected function initialize();
@@ -71,16 +74,16 @@ abstract class BD_Base_Page {
71
  *
72
  * @since 5.5.4
73
  * @abstract
 
74
  * @return void
75
  */
76
  abstract protected function render_body();
77
 
78
  /**
79
  * Use `factory()` method to create instance of this class.
80
- * Don't create instances directly
81
  *
82
  * @since 5.5.4
83
- *
84
  * @see factory()
85
  */
86
  public function __construct() {
@@ -130,6 +133,7 @@ abstract class BD_Base_Page {
130
  * Check for nonce before executing the action.
131
  *
132
  * @since 5.5.4
 
133
  * @param bool $result The current result.
134
  * @param string $action Action name.
135
  */
@@ -147,8 +151,10 @@ abstract class BD_Base_Page {
147
  * Modify help tabs for the current page.
148
  *
149
  * @since 5.5.4
 
150
  * @param array $help_tabs Current list of help tabs.
151
- * @param string $screen Current screen name.
 
152
  * @return array Modified list of help tabs.
153
  */
154
  public function render_help_tab( $help_tabs, $screen ) {
@@ -164,7 +170,9 @@ abstract class BD_Base_Page {
164
  * Help tabs can be added by overriding this function in the child class.
165
  *
166
  * @since 5.5.4
 
167
  * @param array $help_tabs Current list of help tabs.
 
168
  * @return array List of help tabs.
169
  */
170
  protected function add_help_tab( $help_tabs ) {
3
  * Base class for all Pages.
4
  *
5
  * @since 5.5.4
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Base\Page
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
  * Base class for Pages.
15
  *
16
  * @abstract
17
+ *
18
  * @since 5.5.4
19
  */
20
  abstract class BD_Base_Page {
64
  *
65
  * @since 5.5.4
66
  * @abstract
67
+ *
68
  * @return void
69
  */
70
  abstract protected function initialize();
74
  *
75
  * @since 5.5.4
76
  * @abstract
77
+ *
78
  * @return void
79
  */
80
  abstract protected function render_body();
81
 
82
  /**
83
  * Use `factory()` method to create instance of this class.
84
+ * Don't create instances directly.
85
  *
86
  * @since 5.5.4
 
87
  * @see factory()
88
  */
89
  public function __construct() {
133
  * Check for nonce before executing the action.
134
  *
135
  * @since 5.5.4
136
+ *
137
  * @param bool $result The current result.
138
  * @param string $action Action name.
139
  */
151
  * Modify help tabs for the current page.
152
  *
153
  * @since 5.5.4
154
+ *
155
  * @param array $help_tabs Current list of help tabs.
156
+ * @param string $screen Current screen name.
157
+ *
158
  * @return array Modified list of help tabs.
159
  */
160
  public function render_help_tab( $help_tabs, $screen ) {
170
  * Help tabs can be added by overriding this function in the child class.
171
  *
172
  * @since 5.5.4
173
+ *
174
  * @param array $help_tabs Current list of help tabs.
175
+ *
176
  * @return array List of help tabs.
177
  */
178
  protected function add_help_tab( $help_tabs ) {
include/base/class-bd-meta-box-module.php CHANGED
@@ -3,10 +3,11 @@
3
  * Base class for a Bulk Delete Meta Box Module.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Base
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -72,6 +73,7 @@ abstract class BD_Meta_Box_Module {
72
  *
73
  * @since 5.5
74
  * @abstract
 
75
  * @return void
76
  */
77
  abstract protected function initialize();
@@ -81,6 +83,7 @@ abstract class BD_Meta_Box_Module {
81
  *
82
  * @since 5.5
83
  * @abstract
 
84
  * @return void
85
  */
86
  abstract public function render();
@@ -90,25 +93,28 @@ abstract class BD_Meta_Box_Module {
90
  *
91
  * @since 5.5
92
  * @abstract
 
93
  * @return void
94
  */
95
  abstract public function process();
96
 
97
  /**
98
- * Perform the deletion
99
  *
100
  * @since 5.5
101
  * @abstract
102
- * @return int Number of users deleted
 
 
 
103
  */
104
  abstract public function delete( $delete_options );
105
 
106
  /**
107
  * Use `factory()` method to create instance of this class.
108
- * Don't create instances directly
109
  *
110
  * @since 5.5
111
- *
112
  * @see factory()
113
  */
114
  public function __construct() {
@@ -140,9 +146,12 @@ abstract class BD_Meta_Box_Module {
140
  * Setup the meta box.
141
  *
142
  * @since 5.5
 
 
 
143
  */
144
  public function setup_metabox( $screen, $page_slug ) {
145
- $this->screen = $screen;
146
  $this->page_slug = $page_slug;
147
 
148
  add_meta_box( $this->meta_box_slug, $this->messages['box_label'], array( $this, 'render_box' ), $this->screen, 'advanced' );
@@ -156,6 +165,7 @@ abstract class BD_Meta_Box_Module {
156
  public function render_box() {
157
  if ( $this->is_hidden() ) {
158
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . $this->page_slug );
 
159
  return;
160
  }
161
 
@@ -166,12 +176,13 @@ abstract class BD_Meta_Box_Module {
166
  * Is the current meta box hidden by user.
167
  *
168
  * @since 5.5
 
169
  * @return bool True, if hidden. False, otherwise.
170
  */
171
  protected function is_hidden() {
172
- $current_user = wp_get_current_user();
173
  $user_meta_field = $this->get_hidden_box_user_meta_field();
174
- $hidden_boxes = get_user_meta( $current_user->ID, $user_meta_field, true );
175
 
176
  return is_array( $hidden_boxes ) && in_array( $this->meta_box_slug, $hidden_boxes );
177
  }
@@ -180,6 +191,7 @@ abstract class BD_Meta_Box_Module {
180
  * Get the user meta field that stores the status of the hidden meta boxes.
181
  *
182
  * @since 5.5
 
183
  * @return string Name of the User Meta field.
184
  */
185
  protected function get_hidden_box_user_meta_field() {
@@ -195,8 +207,10 @@ abstract class BD_Meta_Box_Module {
195
  * This function will be overridden by the child classes.
196
  *
197
  * @since 5.5
198
- * @param array $js_array JavaScript Array
199
- * @return array Modified JavaScript Array
 
 
200
  */
201
  public function filter_js_array( $js_array) {
202
  return $js_array;
@@ -261,6 +275,8 @@ abstract class BD_Meta_Box_Module {
261
  * Setups up cron and invokes the actual delete method.
262
  *
263
  * @since 5.5
 
 
264
  */
265
  protected function process_delete( $delete_options ) {
266
  if ( array_get_bool( $_POST, 'smbd_' . $this->field_slug . '_cron', false ) ) {
@@ -277,7 +293,7 @@ abstract class BD_Meta_Box_Module {
277
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
278
  } else {
279
  $deleted_count = $this->delete( $delete_options );
280
- $msg = sprintf( _n( $this->messages['deleted_single'], $this->messages['deleted_plural'] , $deleted_count, 'bulk-delete' ), $deleted_count );
281
  }
282
 
283
  add_settings_error(
@@ -292,6 +308,7 @@ abstract class BD_Meta_Box_Module {
292
  * Getter for cron_hook.
293
  *
294
  * @since 5.5
 
295
  * @return string Cron Hook name.
296
  */
297
  public function get_cron_hook() {
@@ -302,10 +319,10 @@ abstract class BD_Meta_Box_Module {
302
  * Getter for field slug.
303
  *
304
  * @since 5.5
 
305
  * @return string Field Slug.
306
  */
307
  public function get_field_slug() {
308
  return $this->field_slug;
309
  }
310
  }
311
- ?>
3
  * Base class for a Bulk Delete Meta Box Module.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Base
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
73
  *
74
  * @since 5.5
75
  * @abstract
76
+ *
77
  * @return void
78
  */
79
  abstract protected function initialize();
83
  *
84
  * @since 5.5
85
  * @abstract
86
+ *
87
  * @return void
88
  */
89
  abstract public function render();
93
  *
94
  * @since 5.5
95
  * @abstract
96
+ *
97
  * @return void
98
  */
99
  abstract public function process();
100
 
101
  /**
102
+ * Perform the deletion.
103
  *
104
  * @since 5.5
105
  * @abstract
106
+ *
107
+ * @param mixed $delete_options
108
+ *
109
+ * @return int Number of users deleted
110
  */
111
  abstract public function delete( $delete_options );
112
 
113
  /**
114
  * Use `factory()` method to create instance of this class.
115
+ * Don't create instances directly.
116
  *
117
  * @since 5.5
 
118
  * @see factory()
119
  */
120
  public function __construct() {
146
  * Setup the meta box.
147
  *
148
  * @since 5.5
149
+ *
150
+ * @param mixed $screen
151
+ * @param mixed $page_slug
152
  */
153
  public function setup_metabox( $screen, $page_slug ) {
154
+ $this->screen = $screen;
155
  $this->page_slug = $page_slug;
156
 
157
  add_meta_box( $this->meta_box_slug, $this->messages['box_label'], array( $this, 'render_box' ), $this->screen, 'advanced' );
165
  public function render_box() {
166
  if ( $this->is_hidden() ) {
167
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . $this->page_slug );
168
+
169
  return;
170
  }
171
 
176
  * Is the current meta box hidden by user.
177
  *
178
  * @since 5.5
179
+ *
180
  * @return bool True, if hidden. False, otherwise.
181
  */
182
  protected function is_hidden() {
183
+ $current_user = wp_get_current_user();
184
  $user_meta_field = $this->get_hidden_box_user_meta_field();
185
+ $hidden_boxes = get_user_meta( $current_user->ID, $user_meta_field, true );
186
 
187
  return is_array( $hidden_boxes ) && in_array( $this->meta_box_slug, $hidden_boxes );
188
  }
191
  * Get the user meta field that stores the status of the hidden meta boxes.
192
  *
193
  * @since 5.5
194
+ *
195
  * @return string Name of the User Meta field.
196
  */
197
  protected function get_hidden_box_user_meta_field() {
207
  * This function will be overridden by the child classes.
208
  *
209
  * @since 5.5
210
+ *
211
+ * @param array $js_array JavaScript Array
212
+ *
213
+ * @return array Modified JavaScript Array
214
  */
215
  public function filter_js_array( $js_array) {
216
  return $js_array;
275
  * Setups up cron and invokes the actual delete method.
276
  *
277
  * @since 5.5
278
+ *
279
+ * @param mixed $delete_options
280
  */
281
  protected function process_delete( $delete_options ) {
282
  if ( array_get_bool( $_POST, 'smbd_' . $this->field_slug . '_cron', false ) ) {
293
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
294
  } else {
295
  $deleted_count = $this->delete( $delete_options );
296
+ $msg = sprintf( _n( $this->messages['deleted_single'], $this->messages['deleted_plural'] , $deleted_count, 'bulk-delete' ), $deleted_count );
297
  }
298
 
299
  add_settings_error(
308
  * Getter for cron_hook.
309
  *
310
  * @since 5.5
311
+ *
312
  * @return string Cron Hook name.
313
  */
314
  public function get_cron_hook() {
319
  * Getter for field slug.
320
  *
321
  * @since 5.5
322
+ *
323
  * @return string Field Slug.
324
  */
325
  public function get_field_slug() {
326
  return $this->field_slug;
327
  }
328
  }
 
include/base/class-bd-page.php CHANGED
@@ -3,16 +3,18 @@
3
  * Base class for all Metabox Pages.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Base\Page
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
  * Base class for Metabox Pages.
14
  *
15
  * @abstract
 
16
  * @since 5.5
17
  */
18
  abstract class BD_Page extends BD_Base_Page {
@@ -36,6 +38,7 @@ abstract class BD_Page extends BD_Base_Page {
36
  * Check for nonce before executing the action.
37
  *
38
  * @since 5.5
 
39
  * @param bool $result The current result.
40
  * @param string $action Action name.
41
  */
@@ -94,7 +97,7 @@ abstract class BD_Page extends BD_Base_Page {
94
  public function add_meta_boxes() {
95
  /**
96
  * Add meta box in delete users page.
97
- * This hook can be used for adding additional meta boxes in delete users page
98
  *
99
  * @since 5.3
100
  */
@@ -141,4 +144,3 @@ abstract class BD_Page extends BD_Base_Page {
141
  do_action( "bd_admin_footer_for_{$this->item_type}" );
142
  }
143
  }
144
- ?>
3
  * Base class for all Metabox Pages.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Base\Page
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
  * Base class for Metabox Pages.
15
  *
16
  * @abstract
17
+ *
18
  * @since 5.5
19
  */
20
  abstract class BD_Page extends BD_Base_Page {
38
  * Check for nonce before executing the action.
39
  *
40
  * @since 5.5
41
+ *
42
  * @param bool $result The current result.
43
  * @param string $action Action name.
44
  */
97
  public function add_meta_boxes() {
98
  /**
99
  * Add meta box in delete users page.
100
+ * This hook can be used for adding additional meta boxes in delete users page.
101
  *
102
  * @since 5.3
103
  */
144
  do_action( "bd_admin_footer_for_{$this->item_type}" );
145
  }
146
  }
 
include/base/users/class-bd-user-meta-box-module.php CHANGED
@@ -3,10 +3,11 @@
3
  * Base class for a Bulk Delete User Meta Box Module.
4
  *
5
  * @since 5.5.2
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Base\Users
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -18,15 +19,16 @@ defined( 'ABSPATH' ) || exit; // Exit if accessed directly
18
  * @abstract
19
  */
20
  abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
21
-
22
  /**
23
  * Query and Delete users.
24
  *
25
  * @since 5.5.2
26
  * @access protected
27
- * @param array $options Options to query users.
28
- * @param array $delete_options Delete options.
29
- * @return int Number of users who were deleted.
 
 
30
  */
31
  protected function delete_users( $options, $delete_options ) {
32
  $count = 0;
@@ -59,16 +61,17 @@ abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
59
  *
60
  * @since 5.5.2
61
  * @access protected
62
- * @param array $delete_options Delete Options.
63
- * @param object $user User objet that needs to be deleted.
64
- * @return bool True if the user can be deleted, false otherwise.
 
 
65
  */
66
  protected function can_delete_by_post_count( $delete_options, $user ) {
67
- if ( $delete_options['no_posts'] && count_user_posts( $user->ID ) > 0 ) {
68
- return false;
69
- }
70
-
71
- return true;
72
  }
73
 
74
  /**
@@ -76,9 +79,11 @@ abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
76
  *
77
  * @since 5.5.3
78
  * @access protected
79
- * @param array $delete_options Delete Options.
80
- * @param object $user User object that needs to be deleted.
81
- * @return bool True if the user can be deleted, false otherwise.
 
 
82
  */
83
  protected function can_delete_by_registered_date( $delete_options, $user ) {
84
  if ( $delete_options['registered_restrict'] ) {
@@ -100,9 +105,11 @@ abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
100
  *
101
  * @since 5.5.2
102
  * @access protected
103
- * @param array $delete_options Delete Options.
104
- * @param object $user User object that needs to be deleted.
105
- * @return bool True if the user can be deleted, false otherwise.
 
 
106
  */
107
  protected function can_delete_by_logged_date( $delete_options, $user ) {
108
  if ( $delete_options['login_restrict'] ) {
@@ -128,11 +135,15 @@ abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
128
 
129
  /**
130
  * Process user delete form.
 
131
  * Helper function to handle common delete user fields.
 
 
132
  *
133
  * @since 5.5.3
134
  * @access protected
135
- * @param array $delete_options Delete Options.
 
136
  */
137
  protected function process_user_delete( $delete_options ) {
138
  $delete_options['login_restrict'] = array_get_bool( $_POST, "smbd_{$this->field_slug}_login_restrict", false );
@@ -142,10 +153,12 @@ abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
142
  $delete_options['registered_days'] = absint( array_get( $_POST, "smbd_{$this->field_slug}_registered_days", 0 ) );
143
 
144
  $delete_options['no_posts'] = array_get_bool( $_POST, "smbd_{$this->field_slug}_no_posts", false );
 
 
145
  $delete_options['limit_to'] = absint( array_get( $_POST, "smbd_{$this->field_slug}_limit_to", 0 ) );
146
 
147
  $this->process_delete( $delete_options );
148
- }
149
 
150
  /**
151
  * Render User Login restrict settings.
@@ -157,8 +170,8 @@ abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
157
  <tr>
158
  <td scope="row" colspan="2">
159
  <input name="smbd_<?php echo esc_attr( $this->field_slug ); ?>_registered_restrict" id="smbd_<?php echo esc_attr( $this->field_slug ); ?>_registered_restrict" value="true" type="checkbox">
160
- <?php _e( 'Restrict to users who have registered at least ', 'bulk-delete' );?>
161
- <input type="number" name="smbd_<?php echo esc_attr( $this->field_slug ); ?>_registered_days" id="smbd_<?php echo esc_attr( $this->field_slug ); ?>_registered_days" class="screen-per-page" value="0" min="0" disabled> <?php _e( 'days ago', 'bulk-delete' );?>.
162
  </td>
163
  </tr>
164
 
@@ -182,10 +195,12 @@ abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
182
  </td>
183
  </tr>
184
 
185
- <tr>
186
- <td scope="row" colspan="2">
187
- <?php _e( 'Enter "0 days" to delete users who have never logged in after the "Simple Login Log" plugin has been installed.', 'bulk-delete' ); ?>
188
- </tr>
 
 
189
  <?php
190
  }
191
 
@@ -195,13 +210,59 @@ abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
195
  * @since 5.5
196
  */
197
  protected function render_user_with_no_posts_settings() {
198
- ?>
199
  <tr>
200
  <td scope="row" colspan="2">
201
- <input name="smbd_<?php echo $this->field_slug; ?>_no_posts" id="smbd_<?php echo $this->field_slug; ?>_no_posts" value="true" type="checkbox">
202
- <?php _e( "Only if user doesn't have any post. Only posts from 'post' post type would be considered.", 'bulk-delete' ); ?>
 
 
 
203
  </td>
204
  </tr>
205
- <?php
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
206
  }
207
  }
3
  * Base class for a Bulk Delete User Meta Box Module.
4
  *
5
  * @since 5.5.2
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Base\Users
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
19
  * @abstract
20
  */
21
  abstract class BD_User_Meta_Box_Module extends BD_Meta_Box_Module {
 
22
  /**
23
  * Query and Delete users.
24
  *
25
  * @since 5.5.2
26
  * @access protected
27
+ *
28
+ * @param array $options Options to query users.
29
+ * @param array $delete_options Delete options.
30
+ *
31
+ * @return int Number of users who were deleted.
32
  */
33
  protected function delete_users( $options, $delete_options ) {
34
  $count = 0;
61
  *
62
  * @since 5.5.2
63
  * @access protected
64
+ *
65
+ * @param array $delete_options Delete Options.
66
+ * @param object $user User object that needs to be deleted.
67
+ *
68
+ * @return bool True if the user can be deleted, false otherwise.
69
  */
70
  protected function can_delete_by_post_count( $delete_options, $user ) {
71
+ return ! (
72
+ $delete_options['no_posts'] &&
73
+ count_user_posts( $user->ID, $delete_options['no_posts_post_types'] ) > 0
74
+ );
 
75
  }
76
 
77
  /**
79
  *
80
  * @since 5.5.3
81
  * @access protected
82
+ *
83
+ * @param array $delete_options Delete Options.
84
+ * @param object $user User object that needs to be deleted.
85
+ *
86
+ * @return bool True if the user can be deleted, false otherwise.
87
  */
88
  protected function can_delete_by_registered_date( $delete_options, $user ) {
89
  if ( $delete_options['registered_restrict'] ) {
105
  *
106
  * @since 5.5.2
107
  * @access protected
108
+ *
109
+ * @param array $delete_options Delete Options.
110
+ * @param object $user User object that needs to be deleted.
111
+ *
112
+ * @return bool True if the user can be deleted, false otherwise.
113
  */
114
  protected function can_delete_by_logged_date( $delete_options, $user ) {
115
  if ( $delete_options['login_restrict'] ) {
135
 
136
  /**
137
  * Process user delete form.
138
+ *
139
  * Helper function to handle common delete user fields.
140
+ * Nonce verification is done in the hook that calls this function.
141
+ * phpcs:disable WordPress.CSRF.NonceVerification.NoNonceVerification
142
  *
143
  * @since 5.5.3
144
  * @access protected
145
+ *
146
+ * @param array $delete_options Delete Options.
147
  */
148
  protected function process_user_delete( $delete_options ) {
149
  $delete_options['login_restrict'] = array_get_bool( $_POST, "smbd_{$this->field_slug}_login_restrict", false );
153
  $delete_options['registered_days'] = absint( array_get( $_POST, "smbd_{$this->field_slug}_registered_days", 0 ) );
154
 
155
  $delete_options['no_posts'] = array_get_bool( $_POST, "smbd_{$this->field_slug}_no_posts", false );
156
+ $delete_options['no_posts_post_types'] = bd_array_get( $_POST, "smbd_{$this->field_slug}_no_post_post_types", array() );
157
+
158
  $delete_options['limit_to'] = absint( array_get( $_POST, "smbd_{$this->field_slug}_limit_to", 0 ) );
159
 
160
  $this->process_delete( $delete_options );
161
+ } // phpcs:disable
162
 
163
  /**
164
  * Render User Login restrict settings.
170
  <tr>
171
  <td scope="row" colspan="2">
172
  <input name="smbd_<?php echo esc_attr( $this->field_slug ); ?>_registered_restrict" id="smbd_<?php echo esc_attr( $this->field_slug ); ?>_registered_restrict" value="true" type="checkbox">
173
+ <?php _e( 'Restrict to users who are registered in the site for at least ', 'bulk-delete' );?>
174
+ <input type="number" name="smbd_<?php echo esc_attr( $this->field_slug ); ?>_registered_days" id="smbd_<?php echo esc_attr( $this->field_slug ); ?>_registered_days" class="screen-per-page" value="0" min="0" disabled> <?php _e( 'days.', 'bulk-delete' );?>
175
  </td>
176
  </tr>
177
 
195
  </td>
196
  </tr>
197
 
198
+ <?php if ( bd_is_simple_login_log_present() ) : ?>
199
+ <tr>
200
+ <td scope="row" colspan="2">
201
+ <?php _e( 'Enter "0 days" to delete users who have never logged in after the "Simple Login Log" plugin has been installed.', 'bulk-delete' ); ?>
202
+ </tr>
203
+ <?php endif; ?>
204
  <?php
205
  }
206
 
210
  * @since 5.5
211
  */
212
  protected function render_user_with_no_posts_settings() {
213
+ ?>
214
  <tr>
215
  <td scope="row" colspan="2">
216
+ <input type="checkbox" value="true"
217
+ name="smbd_<?php echo esc_attr( $this->field_slug ); ?>_no_posts"
218
+ id="smbd_<?php echo esc_attr( $this->field_slug ); ?>_no_posts" class="user_restrict_to_no_posts_filter">
219
+
220
+ <?php _e( "Restrict to users who don't have any posts.", 'bulk-delete' ); ?>
221
  </td>
222
  </tr>
223
+
224
+ <tr class="user_restrict_to_no_posts_filter_items visually-hidden">
225
+ <td scope="row" colspan="2">
226
+ <table class="filter-items">
227
+ <tr>
228
+ <td scope="row">
229
+ <?php _e( 'Select the post types. By default all post types are considered.', 'bulk-delete' ); ?>
230
+ </td>
231
+ </tr>
232
+
233
+ <?php $this->render_post_type_checkboxes( "smbd_{$this->field_slug}_no_post_post_types" ); ?>
234
+ </table>
235
+ </td>
236
+ </tr>
237
+
238
+ <?php
239
+ }
240
+
241
+ /**
242
+ * Render Post Types as checkboxes.
243
+ *
244
+ * @since 5.6.0
245
+ *
246
+ * @param $name Name of post type checkboxes.
247
+ */
248
+ protected function render_post_type_checkboxes( $name ) {
249
+ $post_types = bd_get_post_type_objects();
250
+ ?>
251
+
252
+ <?php foreach( $post_types as $post_type ) : ?>
253
+
254
+ <tr>
255
+ <td scope="row">
256
+ <input type="checkbox" name="<?php echo esc_attr( $name ); ?>[]" value="<?php echo esc_attr( $post_type->name ); ?>"
257
+ id="smbd_post_type_<?php echo esc_html( $post_type->name ); ?>" checked>
258
+
259
+ <label for="smbd_post_type_<?php echo esc_html( $post_type->name ); ?>">
260
+ <?php echo esc_html( $post_type->label ); ?>
261
+ </label>
262
+ </td>
263
+ </tr>
264
+
265
+ <?php endforeach; ?>
266
+ <?php
267
  }
268
  }
include/class-bulk-delete-by-days.php CHANGED
@@ -13,4 +13,3 @@ if ( ! defined( 'ABSPATH' ) ) {
13
 
14
  // include the correct file
15
  require_once Bulk_Delete::$PLUGIN_DIR . '/include/util/class-bulk-delete-by-days.php';
16
- ?>
13
 
14
  // include the correct file
15
  require_once Bulk_Delete::$PLUGIN_DIR . '/include/util/class-bulk-delete-by-days.php';
 
include/compatibility/advanced-custom-fields-pro.php CHANGED
@@ -3,17 +3,18 @@
3
  * Code to enable compatibility with 'Advanced Custom Fields Pro' plugin.
4
  *
5
  * @since 5.5.2
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Util\Compatibility
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
  * Deregister select2 style registered by Advanced Custom Fields Pro plugin.
14
  * Advanced Custom Fields Pro is including their version of select2 in all admin pages.
15
- * @see https://github.com/sudar/bulk-delete/issues/114
16
  *
 
17
  * @since 5.5.2
18
  */
19
  function bd_deregister_acf_select2() {
3
  * Code to enable compatibility with 'Advanced Custom Fields Pro' plugin.
4
  *
5
  * @since 5.5.2
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Util\Compatibility
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
  * Deregister select2 style registered by Advanced Custom Fields Pro plugin.
15
  * Advanced Custom Fields Pro is including their version of select2 in all admin pages.
 
16
  *
17
+ * @see https://github.com/sudar/bulk-delete/issues/114
18
  * @since 5.5.2
19
  */
20
  function bd_deregister_acf_select2() {
include/compatibility/simple-login-log.php CHANGED
@@ -3,18 +3,20 @@
3
  * Code to enable compatibility with other plugins.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Util\Compatibility
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
  * Find out if Simple Login Log is installed or not.
14
- * http://wordpress.org/plugins/simple-login-log/
15
  *
16
  * @since 5.5
17
- * @return bool True if plugin is installed, False otherwise
 
18
  */
19
  function bd_is_simple_login_log_present() {
20
  global $wpdb;
@@ -27,7 +29,9 @@ function bd_is_simple_login_log_present() {
27
  * Find the last login date/time of a user.
28
  *
29
  * @since 5.5
 
30
  * @param int $user_id
 
31
  * @return string
32
  */
33
  function bd_get_last_login( $user_id ) {
@@ -37,4 +41,3 @@ function bd_get_last_login( $user_id ) {
37
 
38
  return $wpdb->get_var( $wpdb->prepare( "SELECT time FROM {$wpdb->prefix}{$simple_login_log_table} WHERE uid = %d ORDER BY time DESC LIMIT 1", $user_id ) );
39
  }
40
- ?>
3
  * Code to enable compatibility with other plugins.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Util\Compatibility
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
  * Find out if Simple Login Log is installed or not.
15
+ * http://wordpress.org/plugins/simple-login-log/.
16
  *
17
  * @since 5.5
18
+ *
19
+ * @return bool True if plugin is installed, False otherwise
20
  */
21
  function bd_is_simple_login_log_present() {
22
  global $wpdb;
29
  * Find the last login date/time of a user.
30
  *
31
  * @since 5.5
32
+ *
33
  * @param int $user_id
34
+ *
35
  * @return string
36
  */
37
  function bd_get_last_login( $user_id ) {
41
 
42
  return $wpdb->get_var( $wpdb->prepare( "SELECT time FROM {$wpdb->prefix}{$simple_login_log_table} WHERE uid = %d ORDER BY time DESC LIMIT 1", $user_id ) );
43
  }
 
include/compatibility/the-event-calendar.php CHANGED
@@ -3,10 +3,11 @@
3
  * Code to enable compatibility with 'The Event Calendar' plugin.
4
  *
5
  * @since 5.5.1
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Util\Compatibility
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
3
  * Code to enable compatibility with 'The Event Calendar' plugin.
4
  *
5
  * @since 5.5.1
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Util\Compatibility
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
include/compatibility/woocommerce.php CHANGED
@@ -3,18 +3,19 @@
3
  * Code to enable compatibility with 'WooCommerce' plugin.
4
  *
5
  * @since 5.5.1
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Util\Compatibility
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
  * Deregister select2 script registered by WooCommerce plugin.
14
  * WooCommerce is using an older version of select2 which is conflicting with the version used by Bulk WP.
 
15
  * @see https://github.com/sudar/bulk-delete/issues/111
16
  * @see https://github.com/woothemes/woocommerce/issues/8766
17
- *
18
  * @since 5.5.1
19
  */
20
  function bd_deregister_woo_select2() {
3
  * Code to enable compatibility with 'WooCommerce' plugin.
4
  *
5
  * @since 5.5.1
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Util\Compatibility
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
  * Deregister select2 script registered by WooCommerce plugin.
15
  * WooCommerce is using an older version of select2 which is conflicting with the version used by Bulk WP.
16
+ *
17
  * @see https://github.com/sudar/bulk-delete/issues/111
18
  * @see https://github.com/woothemes/woocommerce/issues/8766
 
19
  * @since 5.5.1
20
  */
21
  function bd_deregister_woo_select2() {
include/controller/class-bd-controller.php CHANGED
@@ -1,12 +1,13 @@
1
  <?php
2
  /**
3
- * Request Handler
4
  *
5
  * @since 5.5.4
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Controller
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -29,7 +30,7 @@ class BD_Controller {
29
  */
30
  public function request_handler() {
31
  if ( isset( $_POST['bd_action'] ) ) {
32
- $bd_action = sanitize_text_field( $_POST['bd_action'] );
33
  $nonce_valid = false;
34
 
35
  if ( 'delete_pages_' === substr( $bd_action, 0, strlen( 'delete_pages_' ) )
@@ -62,7 +63,7 @@ class BD_Controller {
62
 
63
  /**
64
  * Before performing a bulk action.
65
- * This hook is for doing actions just before performing any bulk operation
66
  *
67
  * @since 5.4
68
  */
@@ -78,7 +79,7 @@ class BD_Controller {
78
  }
79
 
80
  if ( isset( $_GET['bd_action'] ) ) {
81
- $bd_action = sanitize_text_field( $_GET['bd_action'] );
82
  $nonce_valid = false;
83
 
84
  /**
@@ -104,9 +105,11 @@ class BD_Controller {
104
  * Verify if GET request has a valid nonce.
105
  *
106
  * @since 5.5.4
107
- * @param bool $result Whether nonce is valid.
108
- * @param string $action Action name
109
- * @return bool True if nonce is valid, otherwise return $result.
 
 
110
  */
111
  public function verify_get_request_nonce( $result, $action ) {
112
  if ( check_admin_referer( "bd-{$action}", "bd-{$action}-nonce" ) ) {
1
  <?php
2
  /**
3
+ * Request Handler.
4
  *
5
  * @since 5.5.4
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Controller
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
30
  */
31
  public function request_handler() {
32
  if ( isset( $_POST['bd_action'] ) ) {
33
+ $bd_action = sanitize_text_field( $_POST['bd_action'] );
34
  $nonce_valid = false;
35
 
36
  if ( 'delete_pages_' === substr( $bd_action, 0, strlen( 'delete_pages_' ) )
63
 
64
  /**
65
  * Before performing a bulk action.
66
+ * This hook is for doing actions just before performing any bulk operation.
67
  *
68
  * @since 5.4
69
  */
79
  }
80
 
81
  if ( isset( $_GET['bd_action'] ) ) {
82
+ $bd_action = sanitize_text_field( $_GET['bd_action'] );
83
  $nonce_valid = false;
84
 
85
  /**
105
  * Verify if GET request has a valid nonce.
106
  *
107
  * @since 5.5.4
108
+ *
109
+ * @param bool $result Whether nonce is valid.
110
+ * @param string $action Action name
111
+ *
112
+ * @return bool True if nonce is valid, otherwise return $result.
113
  */
114
  public function verify_get_request_nonce( $result, $action ) {
115
  if ( check_admin_referer( "bd-{$action}", "bd-{$action}-nonce" ) ) {
include/cron/class-cron-list-table.php CHANGED
@@ -1,15 +1,14 @@
1
  <?php
2
  /**
3
- * Table to show cron list
4
  *
5
  * @author Sudar
 
6
  * @package BulkDelete\Cron
7
  */
8
-
9
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
10
 
11
  class Cron_List_Table extends WP_List_Table {
12
-
13
  /**
14
  * Constructor, we override the parent to pass our own arguments
15
  * We usually focus on three parameters: singular and plural labels, as well as whether the class supports AJAX.
@@ -18,14 +17,14 @@ class Cron_List_Table extends WP_List_Table {
18
  parent::__construct( array(
19
  'singular' => 'cron_list', //Singular label
20
  'plural' => 'cron_lists', //plural label, also this well be one of the table css class
21
- 'ajax' => false //We won't support Ajax for this table
22
  ) );
23
  }
24
 
25
  /**
26
- * Add extra markup in the toolbars before or after the list
27
  *
28
- * @param string $which Whether the markup should appear after (bottom) or before (top) the list
29
  */
30
  public function extra_tablenav( $which ) {
31
  if ( 'top' == $which ) {
@@ -61,12 +60,12 @@ class Cron_List_Table extends WP_List_Table {
61
  */
62
  public function get_sortable_columns() {
63
  return array(
64
- 'col_cron_type' => array( 'cron_type', true )
65
  );
66
  }
67
 
68
  /**
69
- * Prepare the table with different parameters, pagination, columns and table elements
70
  */
71
  public function prepare_items() {
72
  $cron_items = BD_Util::get_cron_schedules();
@@ -76,7 +75,7 @@ class Cron_List_Table extends WP_List_Table {
76
  $perpage = 50;
77
 
78
  //How many pages do we have in total?
79
- $totalpages = ceil( $totalitems/$perpage );
80
 
81
  /* -- Register the pagination -- */
82
  $this->set_pagination_args( array(
@@ -88,9 +87,9 @@ class Cron_List_Table extends WP_List_Table {
88
  //The pagination links are automatically built according to those parameters
89
 
90
  /* — Register the Columns — */
91
- $columns = $this->get_columns();
92
- $hidden = array();
93
- $sortable = $this->get_sortable_columns();
94
  $this->_column_headers = array( $columns, $hidden, $sortable );
95
 
96
  $this->items = $cron_items;
@@ -100,6 +99,7 @@ class Cron_List_Table extends WP_List_Table {
100
  * Display cron due date column.
101
  *
102
  * @param array $item
 
103
  * @return string
104
  */
105
  public function column_col_cron_due( $item ) {
@@ -151,11 +151,7 @@ class Cron_List_Table extends WP_List_Table {
151
  print_r( $item['args'] );
152
  }
153
 
154
- /**
155
- *
156
- */
157
  public function no_items() {
158
  _e( 'You have not scheduled any bulk delete jobs.', 'bulk-delete' );
159
  }
160
  }
161
- ?>
1
  <?php
2
  /**
3
+ * Table to show cron list.
4
  *
5
  * @author Sudar
6
+ *
7
  * @package BulkDelete\Cron
8
  */
 
9
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
10
 
11
  class Cron_List_Table extends WP_List_Table {
 
12
  /**
13
  * Constructor, we override the parent to pass our own arguments
14
  * We usually focus on three parameters: singular and plural labels, as well as whether the class supports AJAX.
17
  parent::__construct( array(
18
  'singular' => 'cron_list', //Singular label
19
  'plural' => 'cron_lists', //plural label, also this well be one of the table css class
20
+ 'ajax' => false, //We won't support Ajax for this table
21
  ) );
22
  }
23
 
24
  /**
25
+ * Add extra markup in the toolbars before or after the list.
26
  *
27
+ * @param string $which Whether the markup should appear after (bottom) or before (top) the list
28
  */
29
  public function extra_tablenav( $which ) {
30
  if ( 'top' == $which ) {
60
  */
61
  public function get_sortable_columns() {
62
  return array(
63
+ 'col_cron_type' => array( 'cron_type', true ),
64
  );
65
  }
66
 
67
  /**
68
+ * Prepare the table with different parameters, pagination, columns and table elements.
69
  */
70
  public function prepare_items() {
71
  $cron_items = BD_Util::get_cron_schedules();
75
  $perpage = 50;
76
 
77
  //How many pages do we have in total?
78
+ $totalpages = ceil( $totalitems / $perpage );
79
 
80
  /* -- Register the pagination -- */
81
  $this->set_pagination_args( array(
87
  //The pagination links are automatically built according to those parameters
88
 
89
  /* — Register the Columns — */
90
+ $columns = $this->get_columns();
91
+ $hidden = array();
92
+ $sortable = $this->get_sortable_columns();
93
  $this->_column_headers = array( $columns, $hidden, $sortable );
94
 
95
  $this->items = $cron_items;
99
  * Display cron due date column.
100
  *
101
  * @param array $item
102
+ *
103
  * @return string
104
  */
105
  public function column_col_cron_due( $item ) {
151
  print_r( $item['args'] );
152
  }
153
 
 
 
 
154
  public function no_items() {
155
  _e( 'You have not scheduled any bulk delete jobs.', 'bulk-delete' );
156
  }
157
  }
 
include/deprecated/class-bulk-delete-users.php CHANGED
@@ -4,21 +4,22 @@
4
  * It is still hear for compatibility reasons and most probably will be removed in v6.0.
5
  *
6
  * @author Sudar
 
7
  * @package BulkDelete\Deprecated
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class Bulk_Delete_Users {
13
-
14
  /**
15
  * Wire up proper class for backward compatibility.
16
  *
17
  * @since 5.5
 
 
18
  */
19
  public static function delete_users_by_role( $delete_options ) {
20
  $factory = Bulk_Delete_Users_By_User_Role::factory();
 
21
  return $factory->delete( $delete_options );
22
  }
23
  }
24
- ?>
4
  * It is still hear for compatibility reasons and most probably will be removed in v6.0.
5
  *
6
  * @author Sudar
7
+ *
8
  * @package BulkDelete\Deprecated
9
  */
 
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class Bulk_Delete_Users {
 
13
  /**
14
  * Wire up proper class for backward compatibility.
15
  *
16
  * @since 5.5
17
+ *
18
+ * @param mixed $delete_options
19
  */
20
  public static function delete_users_by_role( $delete_options ) {
21
  $factory = Bulk_Delete_Users_By_User_Role::factory();
22
+
23
  return $factory->delete( $delete_options );
24
  }
25
  }
 
include/deprecated/deprecated.php CHANGED
@@ -4,17 +4,20 @@
4
  * Don't depend on the code in this file. It would be removed in future versions of the plugin.
5
  *
6
  * @author Sudar
 
7
  * @package BulkDelete\Util\Deprecated
 
8
  * @since 5.5
9
  */
10
-
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
  * Backward compatibility for delete options.
15
  *
16
  * @since 5.5
 
17
  * @param array $options Old options.
 
18
  * @return array New options.
19
  */
20
  function bd_delete_options_compatibility( $options ) {
@@ -30,7 +33,7 @@ function bd_delete_options_compatibility( $options ) {
30
  if ( array_key_exists( 'date_op', $options ) && array_key_exists( 'days', $options ) ) {
31
  if ( '<' == $options['date_op'] ) {
32
  $options['date_op'] = 'before';
33
- } else if ( '>' == $options['date_op'] ) {
34
  $options['date_op'] = 'after';
35
  }
36
  }
@@ -39,17 +42,65 @@ function bd_delete_options_compatibility( $options ) {
39
  }
40
  add_filter( 'bd_delete_options', 'bd_delete_options_compatibility' );
41
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
42
  /**
43
  * Enable cron for old pro addons that required separate JavaScript.
44
- * This will be removed in v6.0
45
  *
46
  * @since 5.5
47
- * @param array $js_array JavaScript Array
48
- * @return array Modified JavaScript Array
 
 
49
  */
50
  function bd_enable_cron_for_old_addons( $js_array ) {
51
  if ( ! function_exists( 'is_plugin_active' ) ) {
52
- require_once( ABSPATH . 'wp-admin/includes/plugin.php' );
53
  }
54
 
55
  if ( is_plugin_active( 'bulk-delete-scheduler-for-deleting-users-by-role/bulk-delete-scheduler-for-deleting-users-by-role.php' ) ) {
@@ -59,4 +110,31 @@ function bd_enable_cron_for_old_addons( $js_array ) {
59
  return $js_array;
60
  }
61
  add_filter( 'bd_javascript_array', 'bd_enable_cron_for_old_addons' );
62
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4
  * Don't depend on the code in this file. It would be removed in future versions of the plugin.
5
  *
6
  * @author Sudar
7
+ *
8
  * @package BulkDelete\Util\Deprecated
9
+ *
10
  * @since 5.5
11
  */
 
12
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
13
 
14
  /**
15
  * Backward compatibility for delete options.
16
  *
17
  * @since 5.5
18
+ *
19
  * @param array $options Old options.
20
+ *
21
  * @return array New options.
22
  */
23
  function bd_delete_options_compatibility( $options ) {
33
  if ( array_key_exists( 'date_op', $options ) && array_key_exists( 'days', $options ) ) {
34
  if ( '<' == $options['date_op'] ) {
35
  $options['date_op'] = 'before';
36
+ } elseif ( '>' == $options['date_op'] ) {
37
  $options['date_op'] = 'after';
38
  }
39
  }
42
  }
43
  add_filter( 'bd_delete_options', 'bd_delete_options_compatibility' );
44
 
45
+ /**
46
+ * Handle backward compatibility for Delete Posts by status delete options.
47
+ *
48
+ * Backward compatibility code. Will be removed in Bulk Delete v6.0.
49
+ *
50
+ * @since 5.6.0
51
+ *
52
+ * @param array $delete_options Delete Options.
53
+ *
54
+ * @return array Processed delete options.
55
+ */
56
+ function bd_convert_old_options_for_delete_post_by_status( $delete_options ) {
57
+ // Format changed in 5.5.0.
58
+ if ( array_key_exists( 'post_status_op', $delete_options ) ) {
59
+ $delete_options['date_op'] = $delete_options['post_status_op'];
60
+ $delete_options['days'] = $delete_options['post_status_days'];
61
+ }
62
+
63
+ // Format changed in 5.6.0.
64
+ if ( isset( $delete_options['sticky'] ) ) {
65
+ if ( 'sticky' === $delete_options['sticky'] ) {
66
+ $delete_options['delete-sticky-posts'] = true;
67
+ } else {
68
+ $delete_options['delete-sticky-posts'] = false;
69
+ }
70
+ }
71
+
72
+ if ( ! isset( $delete_options['post_status'] ) ) {
73
+ $delete_options['post_status'] = array();
74
+ }
75
+
76
+ $old_statuses = array( 'publish', 'draft', 'pending', 'future', 'private' );
77
+
78
+ foreach ( $old_statuses as $old_status ) {
79
+ if ( isset( $delete_options[ $old_status ] ) ) {
80
+ $delete_options['post_status'][] = $old_status;
81
+ }
82
+ }
83
+
84
+ if ( isset( $delete_options['drafts'] ) && 'drafts' === $delete_options['drafts'] ) {
85
+ $delete_options['post_status'][] = 'draft';
86
+ }
87
+
88
+ return $delete_options;
89
+ }
90
+
91
  /**
92
  * Enable cron for old pro addons that required separate JavaScript.
93
+ * This will be removed in v6.0.
94
  *
95
  * @since 5.5
96
+ *
97
+ * @param array $js_array JavaScript Array
98
+ *
99
+ * @return array Modified JavaScript Array
100
  */
101
  function bd_enable_cron_for_old_addons( $js_array ) {
102
  if ( ! function_exists( 'is_plugin_active' ) ) {
103
+ require_once ABSPATH . 'wp-admin/includes/plugin.php';
104
  }
105
 
106
  if ( is_plugin_active( 'bulk-delete-scheduler-for-deleting-users-by-role/bulk-delete-scheduler-for-deleting-users-by-role.php' ) ) {
110
  return $js_array;
111
  }
112
  add_filter( 'bd_javascript_array', 'bd_enable_cron_for_old_addons' );
113
+
114
+ // Deprecated functions.
115
+
116
+ if ( ! function_exists( 'array_get' ) ) {
117
+ /**
118
+ * Deprecated. Use `bd_array_get`.
119
+ *
120
+ * @param mixed $array
121
+ * @param mixed $key
122
+ * @param mixed|null $default
123
+ */
124
+ function array_get( $array, $key, $default = null ) {
125
+ return bd_array_get( $array, $key, $default );
126
+ }
127
+ }
128
+
129
+ if ( ! function_exists( 'array_get_bool' ) ) {
130
+ /**
131
+ * Deprecated. Use `bd_array_get_bool`.
132
+ *
133
+ * @param mixed $array
134
+ * @param mixed $key
135
+ * @param mixed $default
136
+ */
137
+ function array_get_bool( $array, $key, $default = false ) {
138
+ return bd_array_get_bool( $array, $key, $default );
139
+ }
140
+ }
include/libraries/EDD_SL_Plugin_Updater.php CHANGED
@@ -1,23 +1,23 @@
1
  <?php
2
 
3
- // uncomment this line for testing
4
- //set_site_transient( 'update_plugins', null );
5
-
6
  // Exit if accessed directly
7
  if ( ! defined( 'ABSPATH' ) ) exit;
8
 
9
  /**
10
  * Allows plugins to use their own update API.
11
  *
12
- * @author Pippin Williamson
13
- * @version 1.6.2
14
  */
15
  class EDD_SL_Plugin_Updater {
16
- private $api_url = '';
17
- private $api_data = array();
18
- private $name = '';
19
- private $slug = '';
20
- private $version = '';
 
 
 
21
 
22
  /**
23
  * Class constructor.
@@ -29,16 +29,23 @@ class EDD_SL_Plugin_Updater {
29
  * @param string $_plugin_file Path to the plugin file.
30
  * @param array $_api_data Optional data to send with API calls.
31
  */
32
- function __construct( $_api_url, $_plugin_file, $_api_data = null ) {
33
- $this->api_url = trailingslashit( $_api_url );
34
- $this->api_data = $_api_data;
35
- $this->name = plugin_basename( $_plugin_file );
36
- $this->slug = basename( $_plugin_file, '.php' );
37
- $this->version = $_api_data['version'];
 
 
 
 
 
 
 
 
38
 
39
  // Set up hooks.
40
  $this->init();
41
- add_action( 'admin_init', array( $this, 'show_changelog' ) );
42
 
43
  }
44
 
@@ -50,11 +57,13 @@ class EDD_SL_Plugin_Updater {
50
  * @return void
51
  */
52
  public function init() {
 
53
  add_filter( 'pre_set_site_transient_update_plugins', array( $this, 'check_update' ) );
54
  add_filter( 'plugins_api', array( $this, 'plugins_api_filter' ), 10, 3 );
55
-
56
- remove_action( 'after_plugin_row_' . $this->name, 'wp_plugin_update_row', 10, 2 );
57
  add_action( 'after_plugin_row_' . $this->name, array( $this, 'show_update_notification' ), 10, 2 );
 
 
58
  }
59
 
60
  /**
@@ -70,35 +79,42 @@ class EDD_SL_Plugin_Updater {
70
  * @param array $_transient_data Update array build by WordPress.
71
  * @return array Modified update array with custom plugin data.
72
  */
73
- function check_update( $_transient_data ) {
74
 
75
  global $pagenow;
76
 
77
- if( ! is_object( $_transient_data ) ) {
78
  $_transient_data = new stdClass;
79
  }
80
 
81
- if( 'plugins.php' == $pagenow && is_multisite() ) {
 
 
 
 
82
  return $_transient_data;
83
  }
84
 
85
- if ( empty( $_transient_data->response ) || empty( $_transient_data->response[ $this->name ] ) ) {
86
 
87
- $version_info = $this->api_request( 'plugin_latest_version', array( 'slug' => $this->slug ) );
 
88
 
89
- if ( false !== $version_info && is_object( $version_info ) && isset( $version_info->new_version ) ) {
90
 
91
- if( version_compare( $this->version, $version_info->new_version, '<' ) ) {
92
 
93
- $_transient_data->response[ $this->name ] = $version_info;
94
 
95
- }
96
 
97
- $_transient_data->last_checked = time();
98
- $_transient_data->checked[ $this->name ] = $this->version;
99
 
100
  }
101
 
 
 
 
102
  }
103
 
104
  return $_transient_data;
@@ -112,6 +128,10 @@ class EDD_SL_Plugin_Updater {
112
  */
113
  public function show_update_notification( $file, $plugin ) {
114
 
 
 
 
 
115
  if( ! current_user_can( 'update_plugins' ) ) {
116
  return;
117
  }
@@ -128,33 +148,30 @@ class EDD_SL_Plugin_Updater {
128
  remove_filter( 'pre_set_site_transient_update_plugins', array( $this, 'check_update' ), 10 );
129
 
130
  $update_cache = get_site_transient( 'update_plugins' );
131
-
132
  $update_cache = is_object( $update_cache ) ? $update_cache : new stdClass();
133
 
134
  if ( empty( $update_cache->response ) || empty( $update_cache->response[ $this->name ] ) ) {
135
 
136
- $cache_key = md5( 'edd_plugin_' .sanitize_key( $this->name ) . '_version_info' );
137
- $version_info = get_transient( $cache_key );
138
 
139
- if( false === $version_info ) {
 
140
 
141
- $version_info = $this->api_request( 'plugin_latest_version', array( 'slug' => $this->slug ) );
142
-
143
- set_transient( $cache_key, $version_info, 3600 );
144
  }
145
 
146
-
147
- if( ! is_object( $version_info ) ) {
148
  return;
149
  }
150
 
151
- if( version_compare( $this->version, $version_info->new_version, '<' ) ) {
152
 
153
  $update_cache->response[ $this->name ] = $version_info;
154
 
155
  }
156
 
157
- $update_cache->last_checked = time();
158
  $update_cache->checked[ $this->name ] = $this->version;
159
 
160
  set_site_transient( 'update_plugins', $update_cache );
@@ -172,32 +189,39 @@ class EDD_SL_Plugin_Updater {
172
 
173
  // build a plugin list row, with update notification
174
  $wp_list_table = _get_list_table( 'WP_Plugins_List_Table' );
175
- echo '<tr class="plugin-update-tr"><td colspan="' . $wp_list_table->get_column_count() . '" class="plugin-update colspanchange"><div class="update-message">';
 
 
 
176
 
177
  $changelog_link = self_admin_url( 'index.php?edd_sl_action=view_plugin_changelog&plugin=' . $this->name . '&slug=' . $this->slug . '&TB_iframe=true&width=772&height=911' );
178
 
179
  if ( empty( $version_info->download_link ) ) {
180
  printf(
181
- __( 'There is a new version of %1$s available. <a target="_blank" class="thickbox" href="%2$s">View version %3$s details</a>.', 'bulk-delete' ),
182
  esc_html( $version_info->name ),
183
- esc_url( $changelog_link ),
184
- esc_html( $version_info->new_version )
 
185
  );
186
  } else {
187
  printf(
188
- __( 'There is a new version of %1$s available. <a target="_blank" class="thickbox" href="%2$s">View version %3$s details</a> or <a href="%4$s">update now</a>.', 'bulk-delete' ),
189
  esc_html( $version_info->name ),
190
- esc_url( $changelog_link ),
191
  esc_html( $version_info->new_version ),
192
- esc_url( wp_nonce_url( self_admin_url( 'update.php?action=upgrade-plugin&plugin=' ) . $this->name, 'upgrade-plugin_' . $this->name ) )
 
 
193
  );
194
  }
195
 
 
 
196
  echo '</div></td></tr>';
197
  }
198
  }
199
 
200
-
201
  /**
202
  * Updates information on the "View version x.x details" page with custom data.
203
  *
@@ -208,8 +232,7 @@ class EDD_SL_Plugin_Updater {
208
  * @param object $_args
209
  * @return object $_data
210
  */
211
- function plugins_api_filter( $_data, $_action = '', $_args = null ) {
212
-
213
 
214
  if ( $_action != 'plugin_information' ) {
215
 
@@ -227,21 +250,55 @@ class EDD_SL_Plugin_Updater {
227
  'slug' => $this->slug,
228
  'is_ssl' => is_ssl(),
229
  'fields' => array(
230
- 'banners' => false, // These will be supported soon hopefully
231
  'reviews' => false
232
  )
233
  );
234
 
235
- $api_response = $this->api_request( 'plugin_information', $to_send );
 
 
 
 
 
 
236
 
237
- if ( false !== $api_response ) {
238
- $_data = $api_response;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
239
  }
240
 
241
  return $_data;
242
  }
243
 
244
-
245
  /**
246
  * Disable SSL verification in order to prevent download update failures
247
  *
@@ -249,12 +306,14 @@ class EDD_SL_Plugin_Updater {
249
  * @param string $url
250
  * @return object $array
251
  */
252
- function http_request_args( $args, $url ) {
253
- // If it is an https request and we are performing a package download, disable ssl verification
 
254
  if ( strpos( $url, 'https://' ) !== false && strpos( $url, 'edd_action=package_download' ) ) {
255
- $args['sslverify'] = false;
256
  }
257
  return $args;
 
258
  }
259
 
260
  /**
@@ -278,7 +337,7 @@ class EDD_SL_Plugin_Updater {
278
  return;
279
  }
280
 
281
- if( $this->api_url == home_url() ) {
282
  return false; // Don't allow a plugin to ping itself
283
  }
284
 
@@ -287,12 +346,15 @@ class EDD_SL_Plugin_Updater {
287
  'license' => ! empty( $data['license'] ) ? $data['license'] : '',
288
  'item_name' => isset( $data['item_name'] ) ? $data['item_name'] : false,
289
  'item_id' => isset( $data['item_id'] ) ? $data['item_id'] : false,
 
290
  'slug' => $data['slug'],
291
  'author' => $data['author'],
292
- 'url' => home_url()
 
293
  );
294
 
295
- $request = wp_remote_post( $this->api_url, array( 'timeout' => 15, 'sslverify' => false, 'body' => $api_params ) );
 
296
 
297
  if ( ! is_wp_error( $request ) ) {
298
  $request = json_decode( wp_remote_retrieve_body( $request ) );
@@ -304,11 +366,22 @@ class EDD_SL_Plugin_Updater {
304
  $request = false;
305
  }
306
 
 
 
 
 
 
 
 
 
 
 
307
  return $request;
308
  }
309
 
310
  public function show_changelog() {
311
 
 
312
 
313
  if( empty( $_REQUEST['edd_sl_action'] ) || 'view_plugin_changelog' != $_REQUEST['edd_sl_action'] ) {
314
  return;
@@ -323,17 +396,96 @@ class EDD_SL_Plugin_Updater {
323
  }
324
 
325
  if( ! current_user_can( 'update_plugins' ) ) {
326
- wp_die( __( 'You do not have permission to install plugin updates', 'bulk-delete' ), __( 'Error', 'bulk-delete' ), array( 'response' => 403 ) );
327
  }
328
 
329
- $response = $this->api_request( 'plugin_latest_version', array( 'slug' => $_REQUEST['slug'] ) );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
330
 
331
- if( $response && isset( $response->sections['changelog'] ) ) {
332
- echo '<div style="background:#fff;padding:10px;">' . $response->sections['changelog'] . '</div>';
333
  }
334
 
 
 
 
335
 
336
  exit;
337
  }
338
 
339
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  <?php
2
 
 
 
 
3
  // Exit if accessed directly
4
  if ( ! defined( 'ABSPATH' ) ) exit;
5
 
6
  /**
7
  * Allows plugins to use their own update API.
8
  *
9
+ * @author Easy Digital Downloads
10
+ * @version 1.6.15
11
  */
12
  class EDD_SL_Plugin_Updater {
13
+
14
+ private $api_url = '';
15
+ private $api_data = array();
16
+ private $name = '';
17
+ private $slug = '';
18
+ private $version = '';
19
+ private $wp_override = false;
20
+ private $cache_key = '';
21
 
22
  /**
23
  * Class constructor.
29
  * @param string $_plugin_file Path to the plugin file.
30
  * @param array $_api_data Optional data to send with API calls.
31
  */
32
+ public function __construct( $_api_url, $_plugin_file, $_api_data = null ) {
33
+
34
+ global $edd_plugin_data;
35
+
36
+ $this->api_url = trailingslashit( $_api_url );
37
+ $this->api_data = $_api_data;
38
+ $this->name = plugin_basename( $_plugin_file );
39
+ $this->slug = basename( $_plugin_file, '.php' );
40
+ $this->version = $_api_data['version'];
41
+ $this->wp_override = isset( $_api_data['wp_override'] ) ? (bool) $_api_data['wp_override'] : false;
42
+ $this->beta = ! empty( $this->api_data['beta'] ) ? true : false;
43
+ $this->cache_key = 'edd_sl_' . md5( serialize( $this->slug . $this->api_data['license'] . $this->beta ) );
44
+
45
+ $edd_plugin_data[ $this->slug ] = $this->api_data;
46
 
47
  // Set up hooks.
48
  $this->init();
 
49
 
50
  }
51
 
57
  * @return void
58
  */
59
  public function init() {
60
+
61
  add_filter( 'pre_set_site_transient_update_plugins', array( $this, 'check_update' ) );
62
  add_filter( 'plugins_api', array( $this, 'plugins_api_filter' ), 10, 3 );
63
+ remove_action( 'after_plugin_row_' . $this->name, 'wp_plugin_update_row', 10 );
 
64
  add_action( 'after_plugin_row_' . $this->name, array( $this, 'show_update_notification' ), 10, 2 );
65
+ add_action( 'admin_init', array( $this, 'show_changelog' ) );
66
+
67
  }
68
 
69
  /**
79
  * @param array $_transient_data Update array build by WordPress.
80
  * @return array Modified update array with custom plugin data.
81
  */
82
+ public function check_update( $_transient_data ) {
83
 
84
  global $pagenow;
85
 
86
+ if ( ! is_object( $_transient_data ) ) {
87
  $_transient_data = new stdClass;
88
  }
89
 
90
+ if ( 'plugins.php' == $pagenow && is_multisite() ) {
91
+ return $_transient_data;
92
+ }
93
+
94
+ if ( ! empty( $_transient_data->response ) && ! empty( $_transient_data->response[ $this->name ] ) && false === $this->wp_override ) {
95
  return $_transient_data;
96
  }
97
 
98
+ $version_info = $this->get_cached_version_info();
99
 
100
+ if ( false === $version_info ) {
101
+ $version_info = $this->api_request( 'plugin_latest_version', array( 'slug' => $this->slug, 'beta' => $this->beta ) );
102
 
103
+ $this->set_version_info_cache( $version_info );
104
 
105
+ }
106
 
107
+ if ( false !== $version_info && is_object( $version_info ) && isset( $version_info->new_version ) ) {
108
 
109
+ if ( version_compare( $this->version, $version_info->new_version, '<' ) ) {
110
 
111
+ $_transient_data->response[ $this->name ] = $version_info;
 
112
 
113
  }
114
 
115
+ $_transient_data->last_checked = current_time( 'timestamp' );
116
+ $_transient_data->checked[ $this->name ] = $this->version;
117
+
118
  }
119
 
120
  return $_transient_data;
128
  */
129
  public function show_update_notification( $file, $plugin ) {
130
 
131
+ if ( is_network_admin() ) {
132
+ return;
133
+ }
134
+
135
  if( ! current_user_can( 'update_plugins' ) ) {
136
  return;
137
  }
148
  remove_filter( 'pre_set_site_transient_update_plugins', array( $this, 'check_update' ), 10 );
149
 
150
  $update_cache = get_site_transient( 'update_plugins' );
151
+
152
  $update_cache = is_object( $update_cache ) ? $update_cache : new stdClass();
153
 
154
  if ( empty( $update_cache->response ) || empty( $update_cache->response[ $this->name ] ) ) {
155
 
156
+ $version_info = $this->get_cached_version_info();
 
157
 
158
+ if ( false === $version_info ) {
159
+ $version_info = $this->api_request( 'plugin_latest_version', array( 'slug' => $this->slug, 'beta' => $this->beta ) );
160
 
161
+ $this->set_version_info_cache( $version_info );
 
 
162
  }
163
 
164
+ if ( ! is_object( $version_info ) ) {
 
165
  return;
166
  }
167
 
168
+ if ( version_compare( $this->version, $version_info->new_version, '<' ) ) {
169
 
170
  $update_cache->response[ $this->name ] = $version_info;
171
 
172
  }
173
 
174
+ $update_cache->last_checked = current_time( 'timestamp' );
175
  $update_cache->checked[ $this->name ] = $this->version;
176
 
177
  set_site_transient( 'update_plugins', $update_cache );
189
 
190
  // build a plugin list row, with update notification
191
  $wp_list_table = _get_list_table( 'WP_Plugins_List_Table' );
192
+ # <tr class="plugin-update-tr"><td colspan="' . $wp_list_table->get_column_count() . '" class="plugin-update colspanchange">
193
+ echo '<tr class="plugin-update-tr" id="' . $this->slug . '-update" data-slug="' . $this->slug . '" data-plugin="' . $this->slug . '/' . $file . '">';
194
+ echo '<td colspan="3" class="plugin-update colspanchange">';
195
+ echo '<div class="update-message notice inline notice-warning notice-alt">';
196
 
197
  $changelog_link = self_admin_url( 'index.php?edd_sl_action=view_plugin_changelog&plugin=' . $this->name . '&slug=' . $this->slug . '&TB_iframe=true&width=772&height=911' );
198
 
199
  if ( empty( $version_info->download_link ) ) {
200
  printf(
201
+ __( 'There is a new version of %1$s available. %2$sView version %3$s details%4$s.', 'easy-digital-downloads' ),
202
  esc_html( $version_info->name ),
203
+ '<a target="_blank" class="thickbox" href="' . esc_url( $changelog_link ) . '">',
204
+ esc_html( $version_info->new_version ),
205
+ '</a>'
206
  );
207
  } else {
208
  printf(
209
+ __( 'There is a new version of %1$s available. %2$sView version %3$s details%4$s or %5$supdate now%6$s.', 'easy-digital-downloads' ),
210
  esc_html( $version_info->name ),
211
+ '<a target="_blank" class="thickbox" href="' . esc_url( $changelog_link ) . '">',
212
  esc_html( $version_info->new_version ),
213
+ '</a>',
214
+ '<a href="' . esc_url( wp_nonce_url( self_admin_url( 'update.php?action=upgrade-plugin&plugin=' ) . $this->name, 'upgrade-plugin_' . $this->name ) ) .'">',
215
+ '</a>'
216
  );
217
  }
218
 
219
+ do_action( "in_plugin_update_message-{$file}", $plugin, $version_info );
220
+
221
  echo '</div></td></tr>';
222
  }
223
  }
224
 
 
225
  /**
226
  * Updates information on the "View version x.x details" page with custom data.
227
  *
232
  * @param object $_args
233
  * @return object $_data
234
  */
235
+ public function plugins_api_filter( $_data, $_action = '', $_args = null ) {
 
236
 
237
  if ( $_action != 'plugin_information' ) {
238
 
250
  'slug' => $this->slug,
251
  'is_ssl' => is_ssl(),
252
  'fields' => array(
253
+ 'banners' => array(),
254
  'reviews' => false
255
  )
256
  );
257
 
258
+ $cache_key = 'edd_api_request_' . md5( serialize( $this->slug . $this->api_data['license'] . $this->beta ) );
259
+
260
+ // Get the transient where we store the api request for this plugin for 24 hours
261
+ $edd_api_request_transient = $this->get_cached_version_info( $cache_key );
262
+
263
+ //If we have no transient-saved value, run the API, set a fresh transient with the API value, and return that value too right now.
264
+ if ( empty( $edd_api_request_transient ) ) {
265
 
266
+ $api_response = $this->api_request( 'plugin_information', $to_send );
267
+
268
+ // Expires in 3 hours
269
+ $this->set_version_info_cache( $api_response, $cache_key );
270
+
271
+ if ( false !== $api_response ) {
272
+ $_data = $api_response;
273
+ }
274
+
275
+ } else {
276
+ $_data = $edd_api_request_transient;
277
+ }
278
+
279
+ // Convert sections into an associative array, since we're getting an object, but Core expects an array.
280
+ if ( isset( $_data->sections ) && ! is_array( $_data->sections ) ) {
281
+ $new_sections = array();
282
+ foreach ( $_data->sections as $key => $value ) {
283
+ $new_sections[ $key ] = $value;
284
+ }
285
+
286
+ $_data->sections = $new_sections;
287
+ }
288
+
289
+ // Convert banners into an associative array, since we're getting an object, but Core expects an array.
290
+ if ( isset( $_data->banners ) && ! is_array( $_data->banners ) ) {
291
+ $new_banners = array();
292
+ foreach ( $_data->banners as $key => $value ) {
293
+ $new_banners[ $key ] = $value;
294
+ }
295
+
296
+ $_data->banners = $new_banners;
297
  }
298
 
299
  return $_data;
300
  }
301
 
 
302
  /**
303
  * Disable SSL verification in order to prevent download update failures
304
  *
306
  * @param string $url
307
  * @return object $array
308
  */
309
+ public function http_request_args( $args, $url ) {
310
+
311
+ $verify_ssl = $this->verify_ssl();
312
  if ( strpos( $url, 'https://' ) !== false && strpos( $url, 'edd_action=package_download' ) ) {
313
+ $args['sslverify'] = $verify_ssl;
314
  }
315
  return $args;
316
+
317
  }
318
 
319
  /**
337
  return;
338
  }
339
 
340
+ if( $this->api_url == trailingslashit (home_url() ) ) {
341
  return false; // Don't allow a plugin to ping itself
342
  }
343
 
346
  'license' => ! empty( $data['license'] ) ? $data['license'] : '',
347
  'item_name' => isset( $data['item_name'] ) ? $data['item_name'] : false,
348
  'item_id' => isset( $data['item_id'] ) ? $data['item_id'] : false,
349
+ 'version' => isset( $data['version'] ) ? $data['version'] : false,
350
  'slug' => $data['slug'],
351
  'author' => $data['author'],
352
+ 'url' => home_url(),
353
+ 'beta' => ! empty( $data['beta'] ),
354
  );
355
 
356
+ $verify_ssl = $this->verify_ssl();
357
+ $request = wp_remote_post( $this->api_url, array( 'timeout' => 15, 'sslverify' => $verify_ssl, 'body' => $api_params ) );
358
 
359
  if ( ! is_wp_error( $request ) ) {
360
  $request = json_decode( wp_remote_retrieve_body( $request ) );
366
  $request = false;
367
  }
368
 
369
+ if ( $request && isset( $request->banners ) ) {
370
+ $request->banners = maybe_unserialize( $request->banners );
371
+ }
372
+
373
+ if( ! empty( $request->sections ) ) {
374
+ foreach( $request->sections as $key => $section ) {
375
+ $request->$key = (array) $section;
376
+ }
377
+ }
378
+
379
  return $request;
380
  }
381
 
382
  public function show_changelog() {
383
 
384
+ global $edd_plugin_data;
385
 
386
  if( empty( $_REQUEST['edd_sl_action'] ) || 'view_plugin_changelog' != $_REQUEST['edd_sl_action'] ) {
387
  return;
396
  }
397
 
398
  if( ! current_user_can( 'update_plugins' ) ) {
399
+ wp_die( __( 'You do not have permission to install plugin updates', 'easy-digital-downloads' ), __( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) );
400
  }
401
 
402
+ $data = $edd_plugin_data[ $_REQUEST['slug'] ];
403
+ $beta = ! empty( $data['beta'] ) ? true : false;
404
+ $cache_key = md5( 'edd_plugin_' . sanitize_key( $_REQUEST['plugin'] ) . '_' . $beta . '_version_info' );
405
+ $version_info = $this->get_cached_version_info( $cache_key );
406
+
407
+ if( false === $version_info ) {
408
+
409
+ $api_params = array(
410
+ 'edd_action' => 'get_version',
411
+ 'item_name' => isset( $data['item_name'] ) ? $data['item_name'] : false,
412
+ 'item_id' => isset( $data['item_id'] ) ? $data['item_id'] : false,
413
+ 'slug' => $_REQUEST['slug'],
414
+ 'author' => $data['author'],
415
+ 'url' => home_url(),
416
+ 'beta' => ! empty( $data['beta'] )
417
+ );
418
+
419
+ $verify_ssl = $this->verify_ssl();
420
+ $request = wp_remote_post( $this->api_url, array( 'timeout' => 15, 'sslverify' => $verify_ssl, 'body' => $api_params ) );
421
+
422
+ if ( ! is_wp_error( $request ) ) {
423
+ $version_info = json_decode( wp_remote_retrieve_body( $request ) );
424
+ }
425
+
426
+
427
+ if ( ! empty( $version_info ) && isset( $version_info->sections ) ) {
428
+ $version_info->sections = maybe_unserialize( $version_info->sections );
429
+ } else {
430
+ $version_info = false;
431
+ }
432
+
433
+ if( ! empty( $version_info ) ) {
434
+ foreach( $version_info->sections as $key => $section ) {
435
+ $version_info->$key = (array) $section;
436
+ }
437
+ }
438
+
439
+ $this->set_version_info_cache( $version_info, $cache_key );
440
 
 
 
441
  }
442
 
443
+ if( ! empty( $version_info ) && isset( $version_info->sections['changelog'] ) ) {
444
+ echo '<div style="background:#fff;padding:10px;">' . $version_info->sections['changelog'] . '</div>';
445
+ }
446
 
447
  exit;
448
  }
449
 
450
+ public function get_cached_version_info( $cache_key = '' ) {
451
+
452
+ if( empty( $cache_key ) ) {
453
+ $cache_key = $this->cache_key;
454
+ }
455
+
456
+ $cache = get_option( $cache_key );
457
+
458
+ if( empty( $cache['timeout'] ) || current_time( 'timestamp' ) > $cache['timeout'] ) {
459
+ return false; // Cache is expired
460
+ }
461
+
462
+ return json_decode( $cache['value'] );
463
+
464
+ }
465
+
466
+ public function set_version_info_cache( $value = '', $cache_key = '' ) {
467
+
468
+ if( empty( $cache_key ) ) {
469
+ $cache_key = $this->cache_key;
470
+ }
471
+
472
+ $data = array(
473
+ 'timeout' => strtotime( '+3 hours', current_time( 'timestamp' ) ),
474
+ 'value' => json_encode( $value )
475
+ );
476
+
477
+ update_option( $cache_key, $data, 'no' );
478
+
479
+ }
480
+
481
+ /**
482
+ * Returns if the SSL of the store should be verified.
483
+ *
484
+ * @since 1.6.13
485
+ * @return bool
486
+ */
487
+ private function verify_ssl() {
488
+ return (bool) apply_filters( 'edd_sl_api_request_verify_ssl', true, $this );
489
+ }
490
+
491
+ }
include/license/class-bd-edd-api-wrapper.php CHANGED
@@ -1,31 +1,33 @@
1
  <?php
2
  /**
3
- * Wrapper for EDD API
4
  *
5
  * @since 5.0
 
6
  * @author Sudar
 
7
  * @package BulkDelete\License
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class BD_EDD_API_Wrapper {
13
-
14
  /**
15
- * Store url
16
  *
17
  * @since 5.0
18
  */
19
  const STORE_URL = 'http://bulkwp.com';
20
 
21
  /**
22
- * Check license
23
  *
24
  * @since 5.0
25
  * @static
26
- * @param string $addon Addon name
27
- * @param string $license The license code
28
- * @return array|false False if request fails, API response otherwise
 
 
29
  */
30
  public static function check_license( $addon, $license ) {
31
  $api_params = array(
@@ -62,13 +64,15 @@ class BD_EDD_API_Wrapper {
62
  }
63
 
64
  /**
65
- * Activate license
66
  *
67
  * @since 5.0
68
  * @static
69
- * @param string $addon The addon that needs to be activated
70
- * @param string $license The license code
71
- * @return array|false False if request fails, License info otherwise
 
 
72
  */
73
  public static function activate_license( $addon, $license ) {
74
  $api_params = array(
@@ -105,13 +109,15 @@ class BD_EDD_API_Wrapper {
105
  }
106
 
107
  /**
108
- * Deactivate License
109
  *
110
  * @since 5.0
111
  * @static
112
- * @param string $addon The addon that needs to be deactivated
113
- * @param string $license The license code
114
- * @return bool True if deactivated, False otherwise
 
 
115
  */
116
  public static function deactivate_license( $addon, $license ) {
117
  $api_params = array(
@@ -133,13 +139,15 @@ class BD_EDD_API_Wrapper {
133
  }
134
 
135
  /**
136
- * Call the EDD API
137
  *
138
  * @since 5.0
139
  * @static
140
  * @access private
141
- * @param array $api_params Parameters for API
142
- * @return bool|array $license_data False if request fails, API response otherwise
 
 
143
  */
144
  private static function call_edd_api( $api_params ) {
145
  $response = wp_remote_get( add_query_arg( $api_params, self::STORE_URL ), array( 'timeout' => 15, 'sslverify' => false ) );
@@ -150,7 +158,7 @@ class BD_EDD_API_Wrapper {
150
  }
151
 
152
  $license_object = json_decode( wp_remote_retrieve_body( $response ) );
 
153
  return $license_object;
154
  }
155
  }
156
- ?>
1
  <?php
2
  /**
3
+ * Wrapper for EDD API.
4
  *
5
  * @since 5.0
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\License
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  class BD_EDD_API_Wrapper {
 
14
  /**
15
+ * Store url.
16
  *
17
  * @since 5.0
18
  */
19
  const STORE_URL = 'http://bulkwp.com';
20
 
21
  /**
22
+ * Check license.
23
  *
24
  * @since 5.0
25
  * @static
26
+ *
27
+ * @param string $addon Addon name
28
+ * @param string $license The license code
29
+ *
30
+ * @return array|false False if request fails, API response otherwise
31
  */
32
  public static function check_license( $addon, $license ) {
33
  $api_params = array(
64
  }
65
 
66
  /**
67
+ * Activate license.
68
  *
69
  * @since 5.0
70
  * @static
71
+ *
72
+ * @param string $addon The addon that needs to be activated
73
+ * @param string $license The license code
74
+ *
75
+ * @return array|false False if request fails, License info otherwise
76
  */
77
  public static function activate_license( $addon, $license ) {
78
  $api_params = array(
109
  }
110
 
111
  /**
112
+ * Deactivate License.
113
  *
114
  * @since 5.0
115
  * @static
116
+ *
117
+ * @param string $addon The addon that needs to be deactivated
118
+ * @param string $license The license code
119
+ *
120
+ * @return bool True if deactivated, False otherwise
121
  */
122
  public static function deactivate_license( $addon, $license ) {
123
  $api_params = array(
139
  }
140
 
141
  /**
142
+ * Call the EDD API.
143
  *
144
  * @since 5.0
145
  * @static
146
  * @access private
147
+ *
148
+ * @param array $api_params Parameters for API
149
+ *
150
+ * @return array|bool $license_data False if request fails, API response otherwise
151
  */
152
  private static function call_edd_api( $api_params ) {
153
  $response = wp_remote_get( add_query_arg( $api_params, self::STORE_URL ), array( 'timeout' => 15, 'sslverify' => false ) );
158
  }
159
 
160
  $license_object = json_decode( wp_remote_retrieve_body( $response ) );
161
+
162
  return $license_object;
163
  }
164
  }
 
include/license/class-bd-license-handler.php CHANGED
@@ -1,53 +1,53 @@
1
  <?php
2
  /**
3
- * License Handler for Bulk Delete Addons
4
  *
5
  * @since 5.0
 
6
  * @author Sudar
 
7
  * @package BulkDelete/License
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class BD_License_Handler {
13
-
14
  /**
15
- * Name of the addon
16
  *
17
  * @since 5.0
18
  */
19
  private $addon_name;
20
 
21
  /**
22
- * Code of the addon
23
  *
24
  * @since 5.0
25
  */
26
  private $addon_code;
27
 
28
  /**
29
- * Version of the plugin
30
  *
31
  * @since 5.0
32
  */
33
  private $version;
34
 
35
  /**
36
- * plugin file name
37
  *
38
  * @since 5.0
39
  */
40
  private $plugin_file;
41
 
42
  /**
43
- * Plugin base name
44
  *
45
  * @since 5.5
46
  */
47
  private $plugin_basename;
48
 
49
  /**
50
- * Author of the plugin
51
  *
52
  * @since 5.0
53
  */
@@ -68,15 +68,15 @@ class BD_License_Handler {
68
  private $notice_msg = '';
69
 
70
  /**
71
- * Constructor
72
  *
73
  * @since 5.0
74
  *
75
- * @param string $addon_name Name of the addon
76
- * @param string $addon_code Code of the addon
77
- * @param string $version Version of the addon
78
- * @param string $plugin_file Addon file name
79
- * @param string $author (optional) Author of the addon
80
  */
81
  public function __construct( $addon_name, $addon_code, $version, $plugin_file, $author = 'Sudar Muthu' ) {
82
  $this->addon_name = $addon_name;
@@ -90,9 +90,10 @@ class BD_License_Handler {
90
  }
91
 
92
  /**
93
- * setup hooks
94
  *
95
  * @access private
 
96
  * @since 5.0
97
  */
98
  private function hooks() {
@@ -131,14 +132,12 @@ class BD_License_Handler {
131
  if ( false == $license_code ) {
132
  $this->notice_msg = sprintf( __( '"%1$s" addon is installed but not activated. To activate the addon, please <a href="%2$s">enter your license key</a>. If you don\'t have a license key, then you can <a href="%3$s" target="_blank">purchase one</a>.', 'bulk-delete' ), $this->addon_name, esc_url( get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::ADDON_PAGE_SLUG ), esc_url( $addon_url ) );
133
  } else {
134
- if ( BD_License::has_valid_license( $this->addon_name, $this->addon_code ) ) {
135
- if ( false != $license_code ) {
136
- $this->hook_updater( $license_code );
137
- }
138
- } else {
139
  $this->notice_msg = sprintf( __( 'The license for "%1$s" addon is either invalid or has expired. Please <a href="%2$s" target="_blank">renew the license</a> or <a href="%3$s">enter a new license key</a> to receive updates and support.', 'bulk-delete' ), $this->addon_name, esc_url( $addon_url ), esc_url( get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::ADDON_PAGE_SLUG ) );
140
  }
141
  }
 
 
142
  }
143
 
144
  /**
@@ -146,7 +145,8 @@ class BD_License_Handler {
146
  *
147
  * @since 5.0
148
  * @access private
149
- * @param string $license_code License Code
 
150
  */
151
  private function hook_updater( $license_code ) {
152
  if ( ! class_exists( 'EDD_SL_Plugin_Updater' ) ) {
@@ -159,7 +159,7 @@ class BD_License_Handler {
159
  'item_name' => $this->addon_name,
160
  'addon_code' => $this->addon_code,
161
  'author' => $this->author,
162
- 'url' => home_url()
163
  )
164
  );
165
  }
@@ -179,6 +179,7 @@ class BD_License_Handler {
179
  * Display license information about addon in plugin list table.
180
  *
181
  * @since 5.5
 
182
  * @param string $plugin_file Path to the plugin file, relative to the plugins directory.
183
  * @param array $plugin_data An array of plugin data.
184
  * @param string $status Status of the plugin.
@@ -221,19 +222,19 @@ class BD_License_Handler {
221
  }
222
 
223
  /**
224
- * Decide whether to display the license form or not
225
  *
226
  * @since 5.0
227
  */
228
  public function display_license_form() {
229
  if ( ! BD_License::has_valid_license( $this->addon_name, $this->addon_code ) ) {
230
- $bd = BULK_DELETE();
231
  $bd->display_activate_license_form = true;
232
  }
233
  }
234
 
235
  /**
236
- * Add the license field to license form
237
  *
238
  * @since 5.0
239
  */
@@ -250,7 +251,7 @@ class BD_License_Handler {
250
  }
251
 
252
  /**
253
- * Print the license field
254
  *
255
  * @since 5.0
256
  */
@@ -268,10 +269,12 @@ class BD_License_Handler {
268
 
269
  /**
270
  * Parse the license key and activate it if needed.
271
- * If the key is invalid, then don't save it in the setting option
272
  *
273
  * @since 5.0
 
274
  * @param array $input
 
275
  * @return array
276
  */
277
  public function parse_license_input( $input ) {
@@ -290,10 +293,11 @@ class BD_License_Handler {
290
  }
291
  } else {
292
  if ( BD_License::has_valid_license( $this->addon_name, $this->addon_code ) ) {
293
- $license_code = BD_License::get_license_code( $this->addon_code );
294
  $input[ $this->addon_code ] = $license_code;
295
  }
296
  }
 
297
  return $input;
298
  }
299
  }
1
  <?php
2
  /**
3
+ * License Handler for Bulk Delete Addons.
4
  *
5
  * @since 5.0
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete/License
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  class BD_License_Handler {
 
14
  /**
15
+ * Name of the addon.
16
  *
17
  * @since 5.0
18
  */
19
  private $addon_name;
20
 
21
  /**
22
+ * Code of the addon.
23
  *
24
  * @since 5.0
25
  */
26
  private $addon_code;
27
 
28
  /**
29
+ * Version of the plugin.
30
  *
31
  * @since 5.0
32
  */
33
  private $version;
34
 
35
  /**
36
+ * plugin file name.
37
  *
38
  * @since 5.0
39
  */
40
  private $plugin_file;
41
 
42
  /**
43
+ * Plugin base name.
44
  *
45
  * @since 5.5
46
  */
47
  private $plugin_basename;
48
 
49
  /**
50
+ * Author of the plugin.
51
  *
52
  * @since 5.0
53
  */
68
  private $notice_msg = '';
69
 
70
  /**
71
+ * Constructor.
72
  *
73
  * @since 5.0
74
  *
75
+ * @param string $addon_name Name of the addon
76
+ * @param string $addon_code Code of the addon
77
+ * @param string $version Version of the addon
78
+ * @param string $plugin_file Addon file name
79
+ * @param string $author (optional) Author of the addon
80
  */
81
  public function __construct( $addon_name, $addon_code, $version, $plugin_file, $author = 'Sudar Muthu' ) {
82
  $this->addon_name = $addon_name;
90
  }
91
 
92
  /**
93
+ * setup hooks.
94
  *
95
  * @access private
96
+ *
97
  * @since 5.0
98
  */
99
  private function hooks() {
132
  if ( false == $license_code ) {
133
  $this->notice_msg = sprintf( __( '"%1$s" addon is installed but not activated. To activate the addon, please <a href="%2$s">enter your license key</a>. If you don\'t have a license key, then you can <a href="%3$s" target="_blank">purchase one</a>.', 'bulk-delete' ), $this->addon_name, esc_url( get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::ADDON_PAGE_SLUG ), esc_url( $addon_url ) );
134
  } else {
135
+ if ( ! BD_License::has_valid_license( $this->addon_name, $this->addon_code ) ) {
 
 
 
 
136
  $this->notice_msg = sprintf( __( 'The license for "%1$s" addon is either invalid or has expired. Please <a href="%2$s" target="_blank">renew the license</a> or <a href="%3$s">enter a new license key</a> to receive updates and support.', 'bulk-delete' ), $this->addon_name, esc_url( $addon_url ), esc_url( get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::ADDON_PAGE_SLUG ) );
137
  }
138
  }
139
+
140
+ $this->hook_updater( $license_code );
141
  }
142
 
143
  /**
145
  *
146
  * @since 5.0
147
  * @access private
148
+ *
149
+ * @param string $license_code License Code
150
  */
151
  private function hook_updater( $license_code ) {
152
  if ( ! class_exists( 'EDD_SL_Plugin_Updater' ) ) {
159
  'item_name' => $this->addon_name,
160
  'addon_code' => $this->addon_code,
161
  'author' => $this->author,
162
+ 'url' => home_url(),
163
  )
164
  );
165
  }
179
  * Display license information about addon in plugin list table.
180
  *
181
  * @since 5.5
182
+ *
183
  * @param string $plugin_file Path to the plugin file, relative to the plugins directory.
184
  * @param array $plugin_data An array of plugin data.
185
  * @param string $status Status of the plugin.
222
  }
223
 
224
  /**
225
+ * Decide whether to display the license form or not.
226
  *
227
  * @since 5.0
228
  */
229
  public function display_license_form() {
230
  if ( ! BD_License::has_valid_license( $this->addon_name, $this->addon_code ) ) {
231
+ $bd = BULK_DELETE();
232
  $bd->display_activate_license_form = true;
233
  }
234
  }
235
 
236
  /**
237
+ * Add the license field to license form.
238
  *
239
  * @since 5.0
240
  */
251
  }
252
 
253
  /**
254
+ * Print the license field.
255
  *
256
  * @since 5.0
257
  */
269
 
270
  /**
271
  * Parse the license key and activate it if needed.
272
+ * If the key is invalid, then don't save it in the setting option.
273
  *
274
  * @since 5.0
275
+ *
276
  * @param array $input
277
+ *
278
  * @return array
279
  */
280
  public function parse_license_input( $input ) {
293
  }
294
  } else {
295
  if ( BD_License::has_valid_license( $this->addon_name, $this->addon_code ) ) {
296
+ $license_code = BD_License::get_license_code( $this->addon_code );
297
  $input[ $this->addon_code ] = $license_code;
298
  }
299
  }
300
+
301
  return $input;
302
  }
303
  }
include/license/class-bd-license.php CHANGED
@@ -1,18 +1,18 @@
1
  <?php
2
  /**
3
- * Addon license related functions
4
  *
5
  * @since 5.0
 
6
  * @author Sudar
 
7
  * @package BulkDelete\License
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class BD_License {
13
-
14
  /**
15
- * Output addon page content
16
  *
17
  * @since 5.0
18
  * @static
@@ -52,7 +52,7 @@ class BD_License {
52
  }
53
 
54
  /**
55
- * Display License form
56
  *
57
  * @since 5.0
58
  * @static
@@ -68,16 +68,18 @@ class BD_License {
68
  }
69
 
70
  /**
71
- * Check if an addon has a valid license or not
72
  *
73
  * @since 5.0
74
  * @static
75
- * @param string $addon_name Addon Name
76
- * @param string $addon_code Addon short Name
77
- * @return bool True if addon has a valid license, False otherwise
 
 
78
  */
79
  public static function has_valid_license( $addon_name, $addon_code ) {
80
- $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
81
  $license_data = get_option( $key, false );
82
 
83
  if ( ! $license_data ) {
@@ -106,14 +108,15 @@ class BD_License {
106
  }
107
 
108
  /**
109
- * Get the list of all licenses information to be displayed in the license page
110
  *
111
  * @since 5.0
112
  * @static
 
113
  * @return array $license_data License information
114
  */
115
  public static function get_licenses() {
116
- $licenses = get_option( Bulk_Delete::SETTING_OPTION_NAME );
117
  $license_data = array();
118
 
119
  if ( is_array( $licenses ) ) {
@@ -126,15 +129,17 @@ class BD_License {
126
  }
127
 
128
  /**
129
- * Retrieve license information about an addon
130
  *
131
  * @since 5.0
132
  * @static
133
- * @param string $addon_code Addon short name
 
 
134
  * @return object $license_data License information
135
  */
136
  public static function get_license( $addon_code ) {
137
- $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
138
  $license_data = get_option( $key, false );
139
 
140
  if ( $license_data && is_array( $license_data ) && key_exists( 'validity', $license_data ) ) {
@@ -152,11 +157,13 @@ class BD_License {
152
  }
153
 
154
  /**
155
- * Get license code of an addon
156
  *
157
  * @since 5.0
158
  * @static
159
- * @param string $addon_code Addon code
 
 
160
  * @return bool|string License code of the addon, False otherwise
161
  */
162
  public static function get_license_code( $addon_code ) {
@@ -171,7 +178,7 @@ class BD_License {
171
  }
172
 
173
  /**
174
- * Deactivate license
175
  *
176
  * @since 5.0
177
  * @static
@@ -190,7 +197,6 @@ class BD_License {
190
  self::delete_license_from_cache( $addon_code );
191
  $msg['msg'] = sprintf( __( 'The license key for "%s" addon was successfully deactivated', 'bulk-delete' ), $addon_name );
192
  $msg['type'] = 'updated';
193
-
194
  } else {
195
  self::validate_license( $addon_code, $addon_name );
196
  $msg['msg'] = sprintf( __( 'There was some problem while trying to deactivate license key for "%s" addon. Kindly try again', 'bulk-delete' ), $addon_name );
@@ -205,7 +211,7 @@ class BD_License {
205
  }
206
 
207
  /**
208
- * Delete license
209
  *
210
  * @since 5.0
211
  * @static
@@ -227,11 +233,12 @@ class BD_License {
227
  }
228
 
229
  /**
230
- * Delete license information from cache
231
  *
232
  * @since 5.0
233
  * @static
234
- * @param string $addon_code Addon code
 
235
  */
236
  private static function delete_license_from_cache( $addon_code ) {
237
  $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
@@ -246,15 +253,17 @@ class BD_License {
246
  }
247
 
248
  /**
249
- * Activate license
250
- *
251
- * @since 5.0
252
- * @static
253
- * @param string $addon_name Addon name
254
- * @param string $addon_code Addon code
255
- * @param string $license License code
256
- * @return bool $valid True if valid, False otherwise
257
- */
 
 
258
  public static function activate_license( $addon_name, $addon_code, $license ) {
259
  $license_data = BD_EDD_API_Wrapper::activate_license( $addon_name, $license );
260
  $valid = false;
@@ -265,17 +274,16 @@ class BD_License {
265
 
266
  if ( $license_data && is_array( $license_data ) && key_exists( 'validity', $license_data ) ) {
267
  if ( 'valid' == $license_data['validity'] ) {
268
- $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
269
  $license_data['addon-code'] = $addon_code;
270
  update_option( $key, $license_data );
271
 
272
  $msg['msg'] = sprintf( __( 'The license key for "%s" addon was successfully activated. The addon will get updates automatically till the license key is valid.', 'bulk-delete' ), $addon_name );
273
  $msg['type'] = 'updated';
274
- $valid = true;
275
  } else {
276
  if ( key_exists( 'error', $license_data ) ) {
277
  switch ( $license_data['error'] ) {
278
-
279
  case 'no_activations_left':
280
  $msg['msg'] = sprintf( __( 'The license key for "%s" addon doesn\'t have any more activations left. Kindly buy a new license.', 'bulk-delete' ), $addon_name );
281
  break;
@@ -306,16 +314,18 @@ class BD_License {
306
  if ( ! $valid && isset( $key ) ) {
307
  delete_option( $key );
308
  }
 
309
  return $valid;
310
  }
311
 
312
  /**
313
- * Validate the license for the given addon
314
  *
315
  * @since 5.0
316
  * @static
317
- * @param string $addon_code Addon code
318
- * @param string $addon_name Addon name
 
319
  */
320
  public static function validate_license( $addon_code, $addon_name ) {
321
  $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
1
  <?php
2
  /**
3
+ * Addon license related functions.
4
  *
5
  * @since 5.0
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\License
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  class BD_License {
 
14
  /**
15
+ * Output addon page content.
16
  *
17
  * @since 5.0
18
  * @static
52
  }
53
 
54
  /**
55
+ * Display License form.
56
  *
57
  * @since 5.0
58
  * @static
68
  }
69
 
70
  /**
71
+ * Check if an addon has a valid license or not.
72
  *
73
  * @since 5.0
74
  * @static
75
+ *
76
+ * @param string $addon_name Addon Name
77
+ * @param string $addon_code Addon short Name
78
+ *
79
+ * @return bool True if addon has a valid license, False otherwise
80
  */
81
  public static function has_valid_license( $addon_name, $addon_code ) {
82
+ $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
83
  $license_data = get_option( $key, false );
84
 
85
  if ( ! $license_data ) {
108
  }
109
 
110
  /**
111
+ * Get the list of all licenses information to be displayed in the license page.
112
  *
113
  * @since 5.0
114
  * @static
115
+ *
116
  * @return array $license_data License information
117
  */
118
  public static function get_licenses() {
119
+ $licenses = get_option( Bulk_Delete::SETTING_OPTION_NAME );
120
  $license_data = array();
121
 
122
  if ( is_array( $licenses ) ) {
129
  }
130
 
131
  /**
132
+ * Retrieve license information about an addon.
133
  *
134
  * @since 5.0
135
  * @static
136
+ *
137
+ * @param string $addon_code Addon short name
138
+ *
139
  * @return object $license_data License information
140
  */
141
  public static function get_license( $addon_code ) {
142
+ $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
143
  $license_data = get_option( $key, false );
144
 
145
  if ( $license_data && is_array( $license_data ) && key_exists( 'validity', $license_data ) ) {
157
  }
158
 
159
  /**
160
+ * Get license code of an addon.
161
  *
162
  * @since 5.0
163
  * @static
164
+ *
165
+ * @param string $addon_code Addon code
166
+ *
167
  * @return bool|string License code of the addon, False otherwise
168
  */
169
  public static function get_license_code( $addon_code ) {
178
  }
179
 
180
  /**
181
+ * Deactivate license.
182
  *
183
  * @since 5.0
184
  * @static
197
  self::delete_license_from_cache( $addon_code );
198
  $msg['msg'] = sprintf( __( 'The license key for "%s" addon was successfully deactivated', 'bulk-delete' ), $addon_name );
199
  $msg['type'] = 'updated';
 
200
  } else {
201
  self::validate_license( $addon_code, $addon_name );
202
  $msg['msg'] = sprintf( __( 'There was some problem while trying to deactivate license key for "%s" addon. Kindly try again', 'bulk-delete' ), $addon_name );
211
  }
212
 
213
  /**
214
+ * Delete license.
215
  *
216
  * @since 5.0
217
  * @static
233
  }
234
 
235
  /**
236
+ * Delete license information from cache.
237
  *
238
  * @since 5.0
239
  * @static
240
+ *
241
+ * @param string $addon_code Addon code
242
  */
243
  private static function delete_license_from_cache( $addon_code ) {
244
  $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
253
  }
254
 
255
  /**
256
+ * Activate license.
257
+ *
258
+ * @since 5.0
259
+ * @static
260
+ *
261
+ * @param string $addon_name Addon name
262
+ * @param string $addon_code Addon code
263
+ * @param string $license License code
264
+ *
265
+ * @return bool $valid True if valid, False otherwise
266
+ */
267
  public static function activate_license( $addon_name, $addon_code, $license ) {
268
  $license_data = BD_EDD_API_Wrapper::activate_license( $addon_name, $license );
269
  $valid = false;
274
 
275
  if ( $license_data && is_array( $license_data ) && key_exists( 'validity', $license_data ) ) {
276
  if ( 'valid' == $license_data['validity'] ) {
277
+ $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
278
  $license_data['addon-code'] = $addon_code;
279
  update_option( $key, $license_data );
280
 
281
  $msg['msg'] = sprintf( __( 'The license key for "%s" addon was successfully activated. The addon will get updates automatically till the license key is valid.', 'bulk-delete' ), $addon_name );
282
  $msg['type'] = 'updated';
283
+ $valid = true;
284
  } else {
285
  if ( key_exists( 'error', $license_data ) ) {
286
  switch ( $license_data['error'] ) {
 
287
  case 'no_activations_left':
288
  $msg['msg'] = sprintf( __( 'The license key for "%s" addon doesn\'t have any more activations left. Kindly buy a new license.', 'bulk-delete' ), $addon_name );
289
  break;
314
  if ( ! $valid && isset( $key ) ) {
315
  delete_option( $key );
316
  }
317
+
318
  return $valid;
319
  }
320
 
321
  /**
322
+ * Validate the license for the given addon.
323
  *
324
  * @since 5.0
325
  * @static
326
+ *
327
+ * @param string $addon_code Addon code
328
+ * @param string $addon_name Addon name
329
  */
330
  public static function validate_license( $addon_code, $addon_name ) {
331
  $key = Bulk_Delete::LICENSE_CACHE_KEY_PREFIX . $addon_code;
include/license/class-license-list-table.php CHANGED
@@ -1,18 +1,18 @@
1
  <?php
2
  /**
3
- * Table to show the list of addon licenses
4
  *
5
  * @since 5.0
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Addon
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class License_List_Table extends WP_List_Table {
13
-
14
  /**
15
- * Constructor, setup labels
16
  *
17
  * @since 5.0
18
  */
@@ -26,10 +26,11 @@ class License_List_Table extends WP_List_Table {
26
  }
27
 
28
  /**
29
- * Add extra markup in the toolbars before or after the list
30
  *
31
  * @since 5.0
32
- * @param string $which Whether the markup should be after (bottom) or before (top) the list
 
33
  */
34
  public function extra_tablenav( $which ) {
35
  if ( 'top' == $which ) {
@@ -43,6 +44,7 @@ class License_List_Table extends WP_List_Table {
43
  * Define the list of columns that will be used in the table.
44
  *
45
  * @since 5.0
 
46
  * @return array The list of columns in the table
47
  */
48
  public function get_columns() {
@@ -50,24 +52,25 @@ class License_List_Table extends WP_List_Table {
50
  'col_addon_name' => __( 'Addon Name', 'bulk-delete' ),
51
  'col_license' => __( 'License Code', 'bulk-delete' ),
52
  'col_license_validity' => __( 'Validity', 'bulk-delete' ),
53
- 'col_expires' => __( 'Expires', 'bulk-delete' )
54
  );
55
  }
56
 
57
  /**
58
- * Defines columns that can be sorted
59
  *
60
  * @since 5.0
 
61
  * @return array List of columns that can be sorted
62
  */
63
  public function get_sortable_columns() {
64
  return array(
65
- 'col_addon_name' => array( 'addon_name', false )
66
  );
67
  }
68
 
69
  /**
70
- * Prepare the table
71
  *
72
  * @since 5.0
73
  */
@@ -82,10 +85,12 @@ class License_List_Table extends WP_List_Table {
82
  }
83
 
84
  /**
85
- * Display the col_addon_name column
86
  *
87
  * @since 5.0
88
- * @param array $item Single row of data
 
 
89
  * @return string
90
  */
91
  public function column_col_addon_name( $item ) {
@@ -118,10 +123,12 @@ class License_List_Table extends WP_List_Table {
118
  }
119
 
120
  /**
121
- * Display the col_license column
122
  *
123
  * @since 5.0
124
- * @param array $item Single row of data
 
 
125
  * @return string
126
  */
127
  public function column_col_license( $item ) {
@@ -129,10 +136,12 @@ class License_List_Table extends WP_List_Table {
129
  }
130
 
131
  /**
132
- * Display the col_license_validity column
133
  *
134
  * @since 5.0
135
- * @param array $item Single row of data
 
 
136
  * @return string
137
  */
138
  public function column_col_license_validity( $item ) {
@@ -145,10 +154,12 @@ class License_List_Table extends WP_List_Table {
145
  }
146
 
147
  /**
148
- * Display the col_expires column
149
  *
150
  * @since 5.0
151
- * @param array $item Single row of data
 
 
152
  * @return string
153
  */
154
  public function column_col_expires( $item ) {
@@ -160,7 +171,7 @@ class License_List_Table extends WP_List_Table {
160
  }
161
 
162
  /**
163
- * Define the message that will be shown when the table is empty
164
  *
165
  * @since 5.0
166
  */
@@ -168,4 +179,3 @@ class License_List_Table extends WP_List_Table {
168
  _e( "You don't have any valid addon license yet.", 'bulk-delete' );
169
  }
170
  }
171
- ?>
1
  <?php
2
  /**
3
+ * Table to show the list of addon licenses.
4
  *
5
  * @since 5.0
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Addon
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  class License_List_Table extends WP_List_Table {
 
14
  /**
15
+ * Constructor, setup labels.
16
  *
17
  * @since 5.0
18
  */
26
  }
27
 
28
  /**
29
+ * Add extra markup in the toolbars before or after the list.
30
  *
31
  * @since 5.0
32
+ *
33
+ * @param string $which Whether the markup should be after (bottom) or before (top) the list
34
  */
35
  public function extra_tablenav( $which ) {
36
  if ( 'top' == $which ) {
44
  * Define the list of columns that will be used in the table.
45
  *
46
  * @since 5.0
47
+ *
48
  * @return array The list of columns in the table
49
  */
50
  public function get_columns() {
52
  'col_addon_name' => __( 'Addon Name', 'bulk-delete' ),
53
  'col_license' => __( 'License Code', 'bulk-delete' ),
54
  'col_license_validity' => __( 'Validity', 'bulk-delete' ),
55
+ 'col_expires' => __( 'Expires', 'bulk-delete' ),
56
  );
57
  }
58
 
59
  /**
60
+ * Defines columns that can be sorted.
61
  *
62
  * @since 5.0
63
+ *
64
  * @return array List of columns that can be sorted
65
  */
66
  public function get_sortable_columns() {
67
  return array(
68
+ 'col_addon_name' => array( 'addon_name', false ),
69
  );
70
  }
71
 
72
  /**
73
+ * Prepare the table.
74
  *
75
  * @since 5.0
76
  */
85
  }
86
 
87
  /**
88
+ * Display the col_addon_name column.
89
  *
90
  * @since 5.0
91
+ *
92
+ * @param array $item Single row of data
93
+ *
94
  * @return string
95
  */
96
  public function column_col_addon_name( $item ) {
123
  }
124
 
125
  /**
126
+ * Display the col_license column.
127
  *
128
  * @since 5.0
129
+ *
130
+ * @param array $item Single row of data
131
+ *
132
  * @return string
133
  */
134
  public function column_col_license( $item ) {
136
  }
137
 
138
  /**
139
+ * Display the col_license_validity column.
140
  *
141
  * @since 5.0
142
+ *
143
+ * @param array $item Single row of data
144
+ *
145
  * @return string
146
  */
147
  public function column_col_license_validity( $item ) {
154
  }
155
 
156
  /**
157
+ * Display the col_expires column.
158
  *
159
  * @since 5.0
160
+ *
161
+ * @param array $item Single row of data
162
+ *
163
  * @return string
164
  */
165
  public function column_col_expires( $item ) {
171
  }
172
 
173
  /**
174
+ * Define the message that will be shown when the table is empty.
175
  *
176
  * @since 5.0
177
  */
179
  _e( "You don't have any valid addon license yet.", 'bulk-delete' );
180
  }
181
  }
 
include/meta/class-bulk-delete-comment-meta.php CHANGED
@@ -3,13 +3,12 @@
3
  * Utility class for deleting Comment Meta.
4
  *
5
  * @since 5.4
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Meta
8
  */
9
-
10
-
11
  class Bulk_Delete_Comment_Meta {
12
-
13
  /**
14
  * Box slug.
15
  *
@@ -28,6 +27,7 @@ class Bulk_Delete_Comment_Meta {
28
  * Register comment-meta meta box for delete meta page.
29
  *
30
  * @static
 
31
  * @since 5.4
32
  */
33
  public static function add_delete_comment_meta_box() {
@@ -46,11 +46,13 @@ class Bulk_Delete_Comment_Meta {
46
  * Render delete comment-meta meta box for delete meta page.
47
  *
48
  * @static
 
49
  * @since 5.4
50
  */
51
  public static function render_delete_comment_meta_box() {
52
  if ( Bulk_Delete_Meta::is_meta_box_hidden( self::BOX_COMMENT_META ) ) {
53
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete_meta::META_PAGE_SLUG );
 
54
  return;
55
  }
56
  ?>
@@ -110,7 +112,7 @@ class Bulk_Delete_Comment_Meta {
110
  <?php
111
  /**
112
  * Add more fields to the delete comment meta field form.
113
- * This hook can be used to add more fields to the delete comment meta field form
114
  *
115
  * @since 5.4
116
  */
@@ -187,15 +189,17 @@ class Bulk_Delete_Comment_Meta {
187
  *
188
  * @since 5.4
189
  * @static
190
- * @param array $js_array JavaScript Array
191
- * @return array Modified JavaScript Array
 
 
192
  */
193
  public static function filter_js_array( $js_array ) {
194
- $js_array['dt_iterators'][] = '_cm';
195
  $js_array['validators']['delete_meta_comment'] = 'noValidation';
196
 
197
  $js_array['pre_action_msg']['delete_meta_comment'] = 'deleteCMWarning';
198
- $js_array['msg']['deleteCMWarning'] = __( 'Are you sure you want to delete all the comment meta fields that match the selected filters?', 'bulk-delete' );
199
 
200
  return $js_array;
201
  }
@@ -204,6 +208,7 @@ class Bulk_Delete_Comment_Meta {
204
  * Controller for deleting comment meta fields.
205
  *
206
  * @static
 
207
  * @since 5.4
208
  */
209
  public static function do_delete_comment_meta() {
@@ -221,7 +226,7 @@ class Bulk_Delete_Comment_Meta {
221
 
222
  /**
223
  * Delete comment-meta delete options filter.
224
- * This filter is for processing filtering options for deleting comment meta
225
  *
226
  * @since 5.4
227
  */
@@ -240,7 +245,7 @@ class Bulk_Delete_Comment_Meta {
240
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
241
  } else {
242
  $deleted_count = self::delete_comment_meta( $delete_options );
243
- $msg = sprintf( _n( 'Deleted comment meta field from %d comment', 'Deleted comment meta field from %d comments' , $deleted_count, 'bulk-delete' ), $deleted_count );
244
  }
245
 
246
  add_settings_error(
@@ -255,9 +260,12 @@ class Bulk_Delete_Comment_Meta {
255
  * Delete Comment Meta.
256
  *
257
  * @static
 
258
  * @since 5.4
259
- * @param array $delete_options Options for deleting
260
- * @return int Number of comments that were deleted
 
 
261
  */
262
  public static function delete_comment_meta( $delete_options ) {
263
  $count = 0;
@@ -299,6 +307,7 @@ class Bulk_Delete_Comment_Meta {
299
  $count++;
300
  }
301
  }
 
302
  return $count;
303
  }
304
  }
3
  * Utility class for deleting Comment Meta.
4
  *
5
  * @since 5.4
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Meta
10
  */
 
 
11
  class Bulk_Delete_Comment_Meta {
 
12
  /**
13
  * Box slug.
14
  *
27
  * Register comment-meta meta box for delete meta page.
28
  *
29
  * @static
30
+ *
31
  * @since 5.4
32
  */
33
  public static function add_delete_comment_meta_box() {
46
  * Render delete comment-meta meta box for delete meta page.
47
  *
48
  * @static
49
+ *
50
  * @since 5.4
51
  */
52
  public static function render_delete_comment_meta_box() {
53
  if ( Bulk_Delete_Meta::is_meta_box_hidden( self::BOX_COMMENT_META ) ) {
54
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete_meta::META_PAGE_SLUG );
55
+
56
  return;
57
  }
58
  ?>
112
  <?php
113
  /**
114
  * Add more fields to the delete comment meta field form.
115
+ * This hook can be used to add more fields to the delete comment meta field form.
116
  *
117
  * @since 5.4
118
  */
189
  *
190
  * @since 5.4
191
  * @static
192
+ *
193
+ * @param array $js_array JavaScript Array
194
+ *
195
+ * @return array Modified JavaScript Array
196
  */
197
  public static function filter_js_array( $js_array ) {
198
+ $js_array['dt_iterators'][] = '_cm';
199
  $js_array['validators']['delete_meta_comment'] = 'noValidation';
200
 
201
  $js_array['pre_action_msg']['delete_meta_comment'] = 'deleteCMWarning';
202
+ $js_array['msg']['deleteCMWarning'] = __( 'Are you sure you want to delete all the comment meta fields that match the selected filters?', 'bulk-delete' );
203
 
204
  return $js_array;
205
  }
208
  * Controller for deleting comment meta fields.
209
  *
210
  * @static
211
+ *
212
  * @since 5.4
213
  */
214
  public static function do_delete_comment_meta() {
226
 
227
  /**
228
  * Delete comment-meta delete options filter.
229
+ * This filter is for processing filtering options for deleting comment meta.
230
  *
231
  * @since 5.4
232
  */
245
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
246
  } else {
247
  $deleted_count = self::delete_comment_meta( $delete_options );
248
+ $msg = sprintf( _n( 'Deleted comment meta field from %d comment', 'Deleted comment meta field from %d comments' , $deleted_count, 'bulk-delete' ), $deleted_count );
249
  }
250
 
251
  add_settings_error(
260
  * Delete Comment Meta.
261
  *
262
  * @static
263
+ *
264
  * @since 5.4
265
+ *
266
+ * @param array $delete_options Options for deleting
267
+ *
268
+ * @return int Number of comments that were deleted
269
  */
270
  public static function delete_comment_meta( $delete_options ) {
271
  $count = 0;
307
  $count++;
308
  }
309
  }
310
+
311
  return $count;
312
  }
313
  }
include/meta/class-bulk-delete-meta.php CHANGED
@@ -3,14 +3,14 @@
3
  * Utility class for deleting Meta Fields.
4
  *
5
  * @since 5.4
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Meta
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class Bulk_Delete_Meta {
13
-
14
  /**
15
  * Slug for *meta* page.
16
  *
@@ -29,6 +29,7 @@ class Bulk_Delete_Meta {
29
  * Add *meta* menu.
30
  *
31
  * @static
 
32
  * @since 5.4
33
  */
34
  public static function add_menu() {
@@ -55,6 +56,7 @@ class Bulk_Delete_Meta {
55
  * Add settings Panel for delete meta page.
56
  *
57
  * @static
 
58
  * @since 5.4
59
  */
60
  public static function add_delete_meta_settings_panel() {
@@ -78,13 +80,13 @@ class Bulk_Delete_Meta {
78
  * Register meta boxes for delete meta page.
79
  *
80
  * @static
 
81
  * @since 5.4
82
  */
83
  public static function add_delete_meta_meta_boxes() {
84
-
85
  /**
86
  * Add meta box in meta page.
87
- * This hook can be used for adding additional meta boxes in *meta* page
88
  *
89
  * @since 5.4
90
  */
@@ -95,6 +97,7 @@ class Bulk_Delete_Meta {
95
  * Show the delete meta page.
96
  *
97
  * @static
 
98
  * @since 5.4
99
  */
100
  public static function display_meta_page() {
@@ -141,12 +144,16 @@ class Bulk_Delete_Meta {
141
  *
142
  * @static
143
  * @access private
 
144
  * @since 5.4
145
- * @param string $box The name of the box to check
146
- * @return bool True if the box is hidden, False otherwise
 
 
147
  */
148
  public static function is_meta_box_hidden( $box ) {
149
  $hidden_boxes = self::get_meta_hidden_boxes();
 
150
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
151
  }
152
 
@@ -155,11 +162,14 @@ class Bulk_Delete_Meta {
155
  *
156
  * @static
157
  * @access private
 
158
  * @since 5.4
 
159
  * @return array The array of hidden meta boxes
160
  */
161
  private static function get_meta_hidden_boxes() {
162
  $current_user = wp_get_current_user();
 
163
  return get_user_meta( $current_user->ID, self::VISIBLE_META_BOXES, true );
164
  }
165
  }
3
  * Utility class for deleting Meta Fields.
4
  *
5
  * @since 5.4
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Meta
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  class Bulk_Delete_Meta {
 
14
  /**
15
  * Slug for *meta* page.
16
  *
29
  * Add *meta* menu.
30
  *
31
  * @static
32
+ *
33
  * @since 5.4
34
  */
35
  public static function add_menu() {
56
  * Add settings Panel for delete meta page.
57
  *
58
  * @static
59
+ *
60
  * @since 5.4
61
  */
62
  public static function add_delete_meta_settings_panel() {
80
  * Register meta boxes for delete meta page.
81
  *
82
  * @static
83
+ *
84
  * @since 5.4
85
  */
86
  public static function add_delete_meta_meta_boxes() {
 
87
  /**
88
  * Add meta box in meta page.
89
+ * This hook can be used for adding additional meta boxes in *meta* page.
90
  *
91
  * @since 5.4
92
  */
97
  * Show the delete meta page.
98
  *
99
  * @static
100
+ *
101
  * @since 5.4
102
  */
103
  public static function display_meta_page() {
144
  *
145
  * @static
146
  * @access private
147
+ *
148
  * @since 5.4
149
+ *
150
+ * @param string $box The name of the box to check
151
+ *
152
+ * @return bool True if the box is hidden, False otherwise
153
  */
154
  public static function is_meta_box_hidden( $box ) {
155
  $hidden_boxes = self::get_meta_hidden_boxes();
156
+
157
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
158
  }
159
 
162
  *
163
  * @static
164
  * @access private
165
+ *
166
  * @since 5.4
167
+ *
168
  * @return array The array of hidden meta boxes
169
  */
170
  private static function get_meta_hidden_boxes() {
171
  $current_user = wp_get_current_user();
172
+
173
  return get_user_meta( $current_user->ID, self::VISIBLE_META_BOXES, true );
174
  }
175
  }
include/meta/class-bulk-delete-post-meta.php CHANGED
@@ -3,13 +3,12 @@
3
  * Utility class for deleting Post Meta.
4
  *
5
  * @since 5.4
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Meta
8
  */
9
-
10
-
11
  class Bulk_Delete_Post_Meta {
12
-
13
  /**
14
  * Box slug.
15
  *
@@ -28,6 +27,7 @@ class Bulk_Delete_Post_Meta {
28
  * Register post-meta meta box for delete meta page.
29
  *
30
  * @static
 
31
  * @since 5.4
32
  */
33
  public static function add_delete_post_meta_box() {
@@ -46,11 +46,13 @@ class Bulk_Delete_Post_Meta {
46
  * Render delete post-meta meta box for delete meta page.
47
  *
48
  * @static
 
49
  * @since 5.4
50
  */
51
  public static function render_delete_post_meta_box() {
52
  if ( Bulk_Delete_Meta::is_meta_box_hidden( self::BOX_POST_META ) ) {
53
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete_meta::META_PAGE_SLUG );
 
54
  return;
55
  }
56
  ?>
@@ -110,7 +112,7 @@ class Bulk_Delete_Post_Meta {
110
  <?php
111
  /**
112
  * Add more fields to the delete post meta field form.
113
- * This hook can be used to add more fields to the delete post meta field form
114
  *
115
  * @since 5.4
116
  */
@@ -187,15 +189,17 @@ class Bulk_Delete_Post_Meta {
187
  *
188
  * @since 5.4
189
  * @static
190
- * @param array $js_array JavaScript Array
191
- * @return array Modified JavaScript Array
 
 
192
  */
193
  public static function filter_js_array( $js_array ) {
194
- $js_array['dt_iterators'][] = '_pm';
195
  $js_array['validators']['delete_meta_post'] = 'noValidation';
196
 
197
  $js_array['pre_action_msg']['delete_meta_post'] = 'deletePMWarning';
198
- $js_array['msg']['deletePMWarning'] = __( 'Are you sure you want to delete all the post meta fields that match the selected filters?', 'bulk-delete' );
199
 
200
  return $js_array;
201
  }
@@ -204,6 +208,7 @@ class Bulk_Delete_Post_Meta {
204
  * Controller for deleting post meta fields.
205
  *
206
  * @static
 
207
  * @since 5.4
208
  */
209
  public static function do_delete_post_meta() {
@@ -221,7 +226,7 @@ class Bulk_Delete_Post_Meta {
221
 
222
  /**
223
  * Delete post-meta delete options filter.
224
- * This filter is for processing filtering options for deleting post meta
225
  *
226
  * @since 5.4
227
  */
@@ -240,7 +245,7 @@ class Bulk_Delete_Post_Meta {
240
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
241
  } else {
242
  $deleted_count = self::delete_post_meta( $delete_options );
243
- $msg = sprintf( _n( 'Deleted post meta field from %d post', 'Deleted post meta field from %d posts' , $deleted_count, 'bulk-delete' ), $deleted_count );
244
  }
245
 
246
  add_settings_error(
@@ -255,9 +260,12 @@ class Bulk_Delete_Post_Meta {
255
  * Delete Post Meta.
256
  *
257
  * @static
 
258
  * @since 5.4
259
- * @param array $delete_options Options for deleting
260
- * @return int Number of posts that were deleted
 
 
261
  */
262
  public static function delete_post_meta( $delete_options ) {
263
  $count = 0;
3
  * Utility class for deleting Post Meta.
4
  *
5
  * @since 5.4
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Meta
10
  */
 
 
11
  class Bulk_Delete_Post_Meta {
 
12
  /**
13
  * Box slug.
14
  *
27
  * Register post-meta meta box for delete meta page.
28
  *
29
  * @static
30
+ *
31
  * @since 5.4
32
  */
33
  public static function add_delete_post_meta_box() {
46
  * Render delete post-meta meta box for delete meta page.
47
  *
48
  * @static
49
+ *
50
  * @since 5.4
51
  */
52
  public static function render_delete_post_meta_box() {
53
  if ( Bulk_Delete_Meta::is_meta_box_hidden( self::BOX_POST_META ) ) {
54
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete_meta::META_PAGE_SLUG );
55
+
56
  return;
57
  }
58
  ?>
112
  <?php
113
  /**
114
  * Add more fields to the delete post meta field form.
115
+ * This hook can be used to add more fields to the delete post meta field form.
116
  *
117
  * @since 5.4
118
  */
189
  *
190
  * @since 5.4
191
  * @static
192
+ *
193
+ * @param array $js_array JavaScript Array
194
+ *
195
+ * @return array Modified JavaScript Array
196
  */
197
  public static function filter_js_array( $js_array ) {
198
+ $js_array['dt_iterators'][] = '_pm';
199
  $js_array['validators']['delete_meta_post'] = 'noValidation';
200
 
201
  $js_array['pre_action_msg']['delete_meta_post'] = 'deletePMWarning';
202
+ $js_array['msg']['deletePMWarning'] = __( 'Are you sure you want to delete all the post meta fields that match the selected filters?', 'bulk-delete' );
203
 
204
  return $js_array;
205
  }
208
  * Controller for deleting post meta fields.
209
  *
210
  * @static
211
+ *
212
  * @since 5.4
213
  */
214
  public static function do_delete_post_meta() {
226
 
227
  /**
228
  * Delete post-meta delete options filter.
229
+ * This filter is for processing filtering options for deleting post meta.
230
  *
231
  * @since 5.4
232
  */
245
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
246
  } else {
247
  $deleted_count = self::delete_post_meta( $delete_options );
248
+ $msg = sprintf( _n( 'Deleted post meta field from %d post', 'Deleted post meta field from %d posts' , $deleted_count, 'bulk-delete' ), $deleted_count );
249
  }
250
 
251
  add_settings_error(
260
  * Delete Post Meta.
261
  *
262
  * @static
263
+ *
264
  * @since 5.4
265
+ *
266
+ * @param array $delete_options Options for deleting
267
+ *
268
+ * @return int Number of posts that were deleted
269
  */
270
  public static function delete_post_meta( $delete_options ) {
271
  $count = 0;
include/meta/class-bulk-delete-user-meta.php CHANGED
@@ -3,13 +3,12 @@
3
  * Utility class for deleting User Meta.
4
  *
5
  * @since 5.4
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Meta
8
  */
9
-
10
-
11
  class Bulk_Delete_User_Meta {
12
-
13
  /**
14
  * Box slug.
15
  *
@@ -28,6 +27,7 @@ class Bulk_Delete_User_Meta {
28
  * Register user-meta meta box for delete meta page.
29
  *
30
  * @static
 
31
  * @since 5.4
32
  */
33
  public static function add_delete_user_meta_box() {
@@ -46,11 +46,13 @@ class Bulk_Delete_User_Meta {
46
  * Render delete user-meta meta box for delete meta page.
47
  *
48
  * @static
 
49
  * @since 5.4
50
  */
51
  public static function render_delete_user_meta_box() {
52
  if ( Bulk_Delete_Meta::is_meta_box_hidden( self::BOX_USER_META ) ) {
53
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete_meta::META_PAGE_SLUG );
 
54
  return;
55
  }
56
  ?>
@@ -102,7 +104,7 @@ class Bulk_Delete_User_Meta {
102
  <?php
103
  /**
104
  * Add more fields to the delete user meta field form.
105
- * This hook can be used to add more fields to the delete user meta field form
106
  *
107
  * @since 5.4
108
  */
@@ -167,15 +169,17 @@ class Bulk_Delete_User_Meta {
167
  *
168
  * @since 5.4
169
  * @static
170
- * @param array $js_array JavaScript Array
171
- * @return array Modified JavaScript Array
 
 
172
  */
173
  public static function filter_js_array( $js_array ) {
174
- $js_array['dt_iterators'][] = '_um';
175
  $js_array['validators']['delete_meta_user'] = 'noValidation';
176
 
177
  $js_array['pre_action_msg']['delete_meta_user'] = 'deleteUMWarning';
178
- $js_array['msg']['deleteUMWarning'] = __( 'Are you sure you want to delete all the user meta fields that match the selected filters?', 'bulk-delete' );
179
 
180
  return $js_array;
181
  }
@@ -184,6 +188,7 @@ class Bulk_Delete_User_Meta {
184
  * Controller for deleting user meta fields.
185
  *
186
  * @static
 
187
  * @since 5.4
188
  */
189
  public static function do_delete_user_meta() {
@@ -197,7 +202,7 @@ class Bulk_Delete_User_Meta {
197
 
198
  /**
199
  * Delete user-meta delete options filter.
200
- * This filter is for processing filtering options for deleting user meta
201
  *
202
  * @since 5.4
203
  */
@@ -216,7 +221,7 @@ class Bulk_Delete_User_Meta {
216
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
217
  } else {
218
  $deleted_count = self::delete_user_meta( $delete_options );
219
- $msg = sprintf( _n( 'Deleted user meta field from %d user', 'Deleted user meta field from %d users' , $deleted_count, 'bulk-delete' ), $deleted_count );
220
  }
221
 
222
  add_settings_error(
@@ -231,9 +236,12 @@ class Bulk_Delete_User_Meta {
231
  * Delete User Meta.
232
  *
233
  * @static
 
234
  * @since 5.4
235
- * @param array $delete_options Options for deleting
236
- * @return int Number of users that were deleted
 
 
237
  */
238
  public static function delete_user_meta( $delete_options ) {
239
  $count = 0;
@@ -263,6 +271,7 @@ class Bulk_Delete_User_Meta {
263
  $count++;
264
  }
265
  }
 
266
  return $count;
267
  }
268
  }
3
  * Utility class for deleting User Meta.
4
  *
5
  * @since 5.4
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Meta
10
  */
 
 
11
  class Bulk_Delete_User_Meta {
 
12
  /**
13
  * Box slug.
14
  *
27
  * Register user-meta meta box for delete meta page.
28
  *
29
  * @static
30
+ *
31
  * @since 5.4
32
  */
33
  public static function add_delete_user_meta_box() {
46
  * Render delete user-meta meta box for delete meta page.
47
  *
48
  * @static
49
+ *
50
  * @since 5.4
51
  */
52
  public static function render_delete_user_meta_box() {
53
  if ( Bulk_Delete_Meta::is_meta_box_hidden( self::BOX_USER_META ) ) {
54
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete_meta::META_PAGE_SLUG );
55
+
56
  return;
57
  }
58
  ?>
104
  <?php
105
  /**
106
  * Add more fields to the delete user meta field form.
107
+ * This hook can be used to add more fields to the delete user meta field form.
108
  *
109
  * @since 5.4
110
  */
169
  *
170
  * @since 5.4
171
  * @static
172
+ *
173
+ * @param array $js_array JavaScript Array
174
+ *
175
+ * @return array Modified JavaScript Array
176
  */
177
  public static function filter_js_array( $js_array ) {
178
+ $js_array['dt_iterators'][] = '_um';
179
  $js_array['validators']['delete_meta_user'] = 'noValidation';
180
 
181
  $js_array['pre_action_msg']['delete_meta_user'] = 'deleteUMWarning';
182
+ $js_array['msg']['deleteUMWarning'] = __( 'Are you sure you want to delete all the user meta fields that match the selected filters?', 'bulk-delete' );
183
 
184
  return $js_array;
185
  }
188
  * Controller for deleting user meta fields.
189
  *
190
  * @static
191
+ *
192
  * @since 5.4
193
  */
194
  public static function do_delete_user_meta() {
202
 
203
  /**
204
  * Delete user-meta delete options filter.
205
+ * This filter is for processing filtering options for deleting user meta.
206
  *
207
  * @since 5.4
208
  */
221
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
222
  } else {
223
  $deleted_count = self::delete_user_meta( $delete_options );
224
+ $msg = sprintf( _n( 'Deleted user meta field from %d user', 'Deleted user meta field from %d users' , $deleted_count, 'bulk-delete' ), $deleted_count );
225
  }
226
 
227
  add_settings_error(
236
  * Delete User Meta.
237
  *
238
  * @static
239
+ *
240
  * @since 5.4
241
+ *
242
+ * @param array $delete_options Options for deleting
243
+ *
244
+ * @return int Number of users that were deleted
245
  */
246
  public static function delete_user_meta( $delete_options ) {
247
  $count = 0;
271
  $count++;
272
  }
273
  }
274
+
275
  return $count;
276
  }
277
  }
include/misc/class-bulk-delete-jetpack-contact-form-messages.php CHANGED
@@ -1,25 +1,26 @@
1
  <?php
2
  /**
3
- * Utility class for deleting Jetpack Contact Form Messages
4
  *
5
  * @since 5.3
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Misc
8
  */
9
-
10
-
11
  class Bulk_Delete_Jetpack_Contact_Form_Message {
12
-
13
  // box slugs
14
  const BOX_JETPACK_MESSAGES = 'bd-jetpack-feedback';
15
 
16
  const FEEDBACK_POST_TYPE = 'feedback';
17
  const CRON_HOOK = 'do-bulk-delete-feedback';
 
18
 
19
  /**
20
- * Register Jetpack Feedback meta box for delete misc page
21
  *
22
  * @static
 
23
  * @since 5.3
24
  */
25
  public static function add_delete_jetpack_messages_meta_box() {
@@ -35,14 +36,16 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
35
  }
36
 
37
  /**
38
- * Render Jetpack Feedback meta box for delete misc page
39
  *
40
  * @static
 
41
  * @since 5.3
42
  */
43
  public static function render_delete_jetpack_messages_box() {
44
  if ( Bulk_Delete_Misc::is_misc_box_hidden( self::BOX_JETPACK_MESSAGES ) ) {
45
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete_Misc::MISC_PAGE_SLUG );
 
46
  return;
47
  }
48
 
@@ -84,7 +87,7 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
84
  <?php
85
  /**
86
  * Add more fields to the delete jetpack messages form
87
- * This hook can be used to add more fields to the delete jetpack messages form
88
  *
89
  * @since 5.3
90
  */
@@ -166,26 +169,30 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
166
  }
167
 
168
  /**
169
- * Filter JS Array and add validation hooks
170
  *
171
  * @since 5.4
172
  * @static
173
- * @param array $js_array JavaScript Array
174
- * @return array Modified JavaScript Array
 
 
175
  */
176
  public static function filter_js_array( $js_array ) {
177
- $js_array['dt_iterators'][] = '_feedback';
178
  $js_array['validators']['delete_jetpack_messages'] = 'noValidation';
179
 
180
  $js_array['pre_action_msg']['delete_jetpack_messages'] = 'deleteJetpackWarning';
181
- $js_array['msg']['deleteJetpackWarning'] = __( 'Are you sure you want to delete all the Jetpack contact form messages based on the selected filters?', 'bulk-delete' );
 
182
  return $js_array;
183
  }
184
 
185
  /**
186
- * Controller for deleting Jetpack contact form messages
187
  *
188
  * @static
 
189
  * @since 5.3
190
  */
191
  public static function do_delete_jetpack_messages() {
@@ -202,7 +209,7 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
202
 
203
  /**
204
  * Delete jetpack feedback delete options filter
205
- * This filter is for processing filtering options for deleting jetpack message
206
  *
207
  * @since 5.3
208
  */
@@ -221,7 +228,7 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
221
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
222
  } else {
223
  $deleted_count = self::delete_jetpack_messages( $delete_options );
224
- $msg = sprintf( _n( 'Deleted %d Jetpack contact form message', 'Deleted %d Jetpack contact form messages' , $deleted_count, 'bulk-delete' ), $deleted_count );
225
  }
226
 
227
  add_settings_error(
@@ -233,15 +240,18 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
233
  }
234
 
235
  /**
236
- * Delete Jetpack contact form messages
237
  *
238
  * @static
 
239
  * @since 5.3
240
- * @param array $delete_options Options for deleting
241
- * @return int Number of posts that were deleted
 
 
242
  */
243
  public static function delete_jetpack_messages( $delete_options ) {
244
- $count = 0;
245
  $use_filter = $delete_options['use_filter'];
246
 
247
  $options = array(
@@ -266,7 +276,7 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
266
  }
267
 
268
  if ( 'true' == $delete_options['restrict'] ) {
269
- $options['op'] = $delete_options['feedback_op'];
270
  $options['days'] = $delete_options['feedback_days'];
271
 
272
  if ( ! class_exists( 'Bulk_Delete_By_Days' ) ) {
@@ -278,9 +288,8 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
278
  $post_ids = bd_query( $options );
279
  foreach ( $post_ids as $post_id ) {
280
  if ( 'true' == $use_filter ) {
281
-
282
  /**
283
- * Process additional filters for deleting jetpack messages
284
  *
285
  * @since 5.3
286
  */
@@ -303,10 +312,12 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
303
  }
304
 
305
  /**
306
- * Check whether Jetpack Contact Form is active
307
  *
308
  * @static
 
309
  * @since 5.3
 
310
  * @return bool True if active, False otherwise
311
  */
312
  public static function is_jetpack_contact_active() {
@@ -317,11 +328,162 @@ class Bulk_Delete_Jetpack_Contact_Form_Message {
317
 
318
  return false;
319
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
320
  }
321
 
322
  // hooks
323
  add_action( 'bd_add_meta_box_for_misc' , array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'add_delete_jetpack_messages_meta_box' ) );
324
  add_action( 'bd_delete_jetpack_messages', array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'do_delete_jetpack_messages' ) );
325
 
326
- add_filter( 'bd_javascript_array' , array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'filter_js_array' ) );
 
 
 
 
 
 
 
327
  ?>
1
  <?php
2
  /**
3
+ * Utility class for deleting Jetpack Contact Form Messages.
4
  *
5
  * @since 5.3
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Misc
10
  */
 
 
11
  class Bulk_Delete_Jetpack_Contact_Form_Message {
 
12
  // box slugs
13
  const BOX_JETPACK_MESSAGES = 'bd-jetpack-feedback';
14
 
15
  const FEEDBACK_POST_TYPE = 'feedback';
16
  const CRON_HOOK = 'do-bulk-delete-feedback';
17
+ const CRON_NAME = 'Bulk Delete Jetpack Contact Form Messages';
18
 
19
  /**
20
+ * Register Jetpack Feedback meta box for delete misc page.
21
  *
22
  * @static
23
+ *
24
  * @since 5.3
25
  */
26
  public static function add_delete_jetpack_messages_meta_box() {
36
  }
37
 
38
  /**
39
+ * Render Jetpack Feedback meta box for delete misc page.
40
  *
41
  * @static
42
+ *
43
  * @since 5.3
44
  */
45
  public static function render_delete_jetpack_messages_box() {
46
  if ( Bulk_Delete_Misc::is_misc_box_hidden( self::BOX_JETPACK_MESSAGES ) ) {
47
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete_Misc::MISC_PAGE_SLUG );
48
+
49
  return;
50
  }
51
 
87
  <?php
88
  /**
89
  * Add more fields to the delete jetpack messages form
90
+ * This hook can be used to add more fields to the delete jetpack messages form.
91
  *
92
  * @since 5.3
93
  */
169
  }
170
 
171
  /**
172
+ * Filter JS Array and add validation hooks.
173
  *
174
  * @since 5.4
175
  * @static
176
+ *
177
+ * @param array $js_array JavaScript Array
178
+ *
179
+ * @return array Modified JavaScript Array
180
  */
181
  public static function filter_js_array( $js_array ) {
182
+ $js_array['dt_iterators'][] = '_feedback';
183
  $js_array['validators']['delete_jetpack_messages'] = 'noValidation';
184
 
185
  $js_array['pre_action_msg']['delete_jetpack_messages'] = 'deleteJetpackWarning';
186
+ $js_array['msg']['deleteJetpackWarning'] = __( 'Are you sure you want to delete all the Jetpack contact form messages based on the selected filters?', 'bulk-delete' );
187
+
188
  return $js_array;
189
  }
190
 
191
  /**
192
+ * Controller for deleting Jetpack contact form messages.
193
  *
194
  * @static
195
+ *
196
  * @since 5.3
197
  */
198
  public static function do_delete_jetpack_messages() {
209
 
210
  /**
211
  * Delete jetpack feedback delete options filter
212
+ * This filter is for processing filtering options for deleting jetpack message.
213
  *
214
  * @since 5.3
215
  */
228
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
229
  } else {
230
  $deleted_count = self::delete_jetpack_messages( $delete_options );
231
+ $msg = sprintf( _n( 'Deleted %d Jetpack contact form message', 'Deleted %d Jetpack contact form messages' , $deleted_count, 'bulk-delete' ), $deleted_count );
232
  }
233
 
234
  add_settings_error(
240
  }
241
 
242
  /**
243
+ * Delete Jetpack contact form messages.
244
  *
245
  * @static
246
+ *
247
  * @since 5.3
248
+ *
249
+ * @param array $delete_options Options for deleting
250
+ *
251
+ * @return int Number of posts that were deleted
252
  */
253
  public static function delete_jetpack_messages( $delete_options ) {
254
+ $count = 0;
255
  $use_filter = $delete_options['use_filter'];
256
 
257
  $options = array(
276
  }
277
 
278
  if ( 'true' == $delete_options['restrict'] ) {
279
+ $options['op'] = $delete_options['feedback_op'];
280
  $options['days'] = $delete_options['feedback_days'];
281
 
282
  if ( ! class_exists( 'Bulk_Delete_By_Days' ) ) {
288
  $post_ids = bd_query( $options );
289
  foreach ( $post_ids as $post_id ) {
290
  if ( 'true' == $use_filter ) {
 
291
  /**
292
+ * Process additional filters for deleting jetpack messages.
293
  *
294
  * @since 5.3
295
  */
312
  }
313
 
314
  /**
315
+ * Check whether Jetpack Contact Form is active.
316
  *
317
  * @static
318
+ *
319
  * @since 5.3
320
+ *
321
  * @return bool True if active, False otherwise
322
  */
323
  public static function is_jetpack_contact_active() {
328
 
329
  return false;
330
  }
331
+
332
+ /**
333
+ * Append filtering options to the delete feedback page.
334
+ *
335
+ * @since 0.1
336
+ * @static
337
+ */
338
+ public static function add_filtering_options() {
339
+ ?>
340
+ <table class="optiontable" id="jetpack-filters" style="display:none;">
341
+ <tr>
342
+ <td colspan="2">
343
+ <h4><?php _e( 'Choose your filtering options', 'bulk-delete' ); ?></h4>
344
+ </td>
345
+ </tr>
346
+
347
+ <tr>
348
+ <td scope="row">
349
+ <input name="smbd_feedback_author_name_filter" id ="smbd_feedback_author_name_filter" value = "true" type = "checkbox">
350
+ </td>
351
+ <td>
352
+ <?php _e( 'Only if author name ', 'bulk-delete' );?>
353
+ <select name="smbd_feedback_author_name_op" id="smbd_feedback_author_name_op" disabled>
354
+ <option value ="is"><?php _e( 'is', 'bulk-delete' );?></option>
355
+ <option value ="is-not"><?php _e( 'is not', 'bulk-delete' );?></option>
356
+ </select>
357
+ <input type ="textbox" name="smbd_feedback_author_name_value" id ="smbd_feedback_author_name_value" disabled placeholder="<?php _e( 'Author Name', 'bulk-delete' ); ?>">
358
+ </td>
359
+ </tr>
360
+
361
+ <tr>
362
+ <td scope="row">
363
+ <input name="smbd_feedback_author_email_filter" id ="smbd_feedback_author_email_filter" value = "true" type = "checkbox">
364
+ </td>
365
+ <td>
366
+ <?php _e( 'Only if author email ', 'bulk-delete' );?>
367
+ <select name="smbd_feedback_author_email_op" id="smbd_feedback_author_email_op" disabled>
368
+ <option value ="is"><?php _e( 'is', 'bulk-delete' );?></option>
369
+ <option value ="is-not"><?php _e( 'is not', 'bulk-delete' );?></option>
370
+ </select>
371
+ <input type ="textbox" name="smbd_feedback_author_email_value" id ="smbd_feedback_author_email_value" disabled placeholder="<?php _e( 'Author Email', 'bulk-delete' ); ?>">
372
+ </td>
373
+ </tr>
374
+
375
+ <tr>
376
+ <td scope="row">
377
+ <input name="smbd_feedback_author_ip_filter" id ="smbd_feedback_author_ip_filter" value = "true" type = "checkbox">
378
+ </td>
379
+ <td>
380
+ <?php _e( 'Only if author ip ', 'bulk-delete' );?>
381
+ <select name="smbd_feedback_author_ip_op" id="smbd_feedback_author_ip_op" disabled>
382
+ <option value ="is"><?php _e( 'is', 'bulk-delete' );?></option>
383
+ <option value ="is-not"><?php _e( 'is not', 'bulk-delete' );?></option>
384
+ </select>
385
+ <input type ="textbox" name="smbd_feedback_author_ip_value" id ="smbd_feedback_author_ip_value" disabled placeholder="<?php _e( 'Author ip', 'bulk-delete' ); ?>">
386
+ </td>
387
+ </tr>
388
+ </table>
389
+ <?php
390
+ }
391
+
392
+ /**
393
+ * Process additional delete options.
394
+ *
395
+ * @since 0.1
396
+ * @static
397
+ *
398
+ * @param array $delete_options Delete options array
399
+ * @param array $post The Post array
400
+ *
401
+ * @return array Processed delete options array
402
+ */
403
+ public static function process_filtering_options( $delete_options, $post ) {
404
+ $filters = array();
405
+
406
+ if ( 'true' == array_get( $post, 'smbd_feedback_use_filter', 'false' ) ) {
407
+ foreach ( array( 'name', 'email', 'ip' ) as $filter_name ) {
408
+ if( 'true' == array_get( $post, "smbd_feedback_author_{$filter_name}_filter", 'false' ) ) {
409
+ $filters[$filter_name] = array(
410
+ 'op' => array_get( $post, "smbd_feedback_author_{$filter_name}_op", 'is' ),
411
+ 'value' => array_get( $post, "smbd_feedback_author_{$filter_name}_value", '' ),
412
+ );
413
+ }
414
+ }
415
+ }
416
+
417
+ $delete_options['filters'] = $filters;
418
+
419
+ return $delete_options;
420
+ }
421
+
422
+ /**
423
+ * Whether the current message should be deleted based on user selection.
424
+ *
425
+ * @static
426
+ *
427
+ * @since 0.1
428
+ *
429
+ * @param array $delete_options List of options chosen by the user
430
+ * @param int $post_id Post id
431
+ *
432
+ * @return bool True if the message should be deleted, False otherwise
433
+ */
434
+ public static function can_delete( $delete_options, $post_id ) {
435
+ $can_delete = false;
436
+
437
+ if ( Bulk_Delete_Jetpack_Contact_Form_Message::is_jetpack_contact_active() ) {
438
+ $content_fields = Grunion_Contact_Form_Plugin::parse_fields_from_content( $post_id );
439
+
440
+ $author_name = $content_fields['_feedback_author'];
441
+ $author_email = $content_fields['_feedback_author_email'];
442
+ $author_ip = $content_fields['_feedback_ip'];
443
+
444
+ $filters = $delete_options['filters'];
445
+ foreach ( $filters as $name => $filter ) {
446
+ $field = "author_{$name}";
447
+ if ( 'is' == $filter['op'] ) {
448
+ if ( $$field == $filter['value'] ) {
449
+ $can_delete = true;
450
+ }
451
+ } else {
452
+ if ( $$field != $filter['value'] ) {
453
+ $can_delete = true;
454
+ }
455
+ }
456
+ }
457
+ }
458
+
459
+ return $can_delete;
460
+ }
461
+
462
+ /**
463
+ * Hook handler.
464
+ *
465
+ * @since 0.1
466
+ * @static
467
+ *
468
+ * @param array $delete_options Delete options array
469
+ */
470
+ public static function do_delete_jetpack_messages_cron( $delete_options ) {
471
+ do_action( 'bd_before_scheduler', self::CRON_NAME );
472
+ $count = self::delete_jetpack_messages( $delete_options );
473
+ do_action( 'bd_after_scheduler', self::CRON_NAME, $count );
474
+ }
475
  }
476
 
477
  // hooks
478
  add_action( 'bd_add_meta_box_for_misc' , array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'add_delete_jetpack_messages_meta_box' ) );
479
  add_action( 'bd_delete_jetpack_messages', array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'do_delete_jetpack_messages' ) );
480
 
481
+ add_filter( 'bd_javascript_array', array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'filter_js_array' ) );
482
+ add_action( 'bd_delete_jetpack_messages_form', array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'add_filtering_options' ) );
483
+
484
+ add_filter( 'bd_delete_jetpack_messages_delete_options', array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'process_filtering_options' ), 10, 2 );
485
+ add_filter( 'bd_delete_jetpack_messages_can_delete', array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'can_delete' ), 10, 2 );
486
+
487
+ // cron hooks
488
+ add_action( Bulk_Delete_Jetpack_Contact_Form_Message::CRON_HOOK, array( 'Bulk_Delete_Jetpack_Contact_Form_Message', 'do_delete_jetpack_messages_cron' ), 10, 1 );
489
  ?>
include/misc/class-bulk-delete-misc.php CHANGED
@@ -1,18 +1,18 @@
1
  <?php
2
  /**
3
- * Utility class for deleting Misc stuff
4
  *
5
  * @since 5.3
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Misc
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class Bulk_Delete_Misc {
13
-
14
  /**
15
- * Slug for *misc* page
16
  *
17
  * @since 5.3
18
  */
@@ -21,9 +21,10 @@ class Bulk_Delete_Misc {
21
  const VISIBLE_MISC_BOXES = 'metaboxhidden_bulk-delete_page_bulk-delete-misc';
22
 
23
  /**
24
- * Add *misc* menu
25
  *
26
  * @static
 
27
  * @since 5.3
28
  */
29
  public static function add_menu() {
@@ -47,16 +48,17 @@ class Bulk_Delete_Misc {
47
  }
48
 
49
  /**
50
- * Add settings Panel for delete misc page
51
  *
52
  * @static
 
53
  * @since 5.3
54
  */
55
  public static function add_delete_misc_settings_panel() {
56
  $bd = BULK_DELETE();
57
 
58
  /**
59
- * Add contextual help for admin screens
60
  *
61
  * @since 5.3
62
  */
@@ -70,16 +72,16 @@ class Bulk_Delete_Misc {
70
  }
71
 
72
  /**
73
- * Register meta boxes for delete misc page
74
  *
75
  * @static
 
76
  * @since 5.3
77
  */
78
  public static function add_delete_misc_meta_boxes() {
79
-
80
  /**
81
  * Add meta box in misc page
82
- * This hook can be used for adding additional meta boxes in *misc* page
83
  *
84
  * @since 5.3
85
  */
@@ -87,9 +89,10 @@ class Bulk_Delete_Misc {
87
  }
88
 
89
  /**
90
- * Show the delete misc page
91
  *
92
  * @static
 
93
  * @since 5.3
94
  */
95
  public static function display_misc_page() {
@@ -135,29 +138,36 @@ class Bulk_Delete_Misc {
135
  }
136
 
137
  /**
138
- * Check whether the meta box in misc page is hidden or not
139
  *
140
  * @static
141
  * @access private
 
142
  * @since 5.3
143
- * @param string $box The name of the box to check
144
- * @return bool True if the box is hidden, False otherwise
 
 
145
  */
146
  public static function is_misc_box_hidden( $box ) {
147
  $hidden_boxes = self::get_misc_hidden_boxes();
 
148
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
149
  }
150
 
151
  /**
152
- * Get the list of hidden boxes in misc page
153
  *
154
  * @static
155
  * @access private
 
156
  * @since 5.3
 
157
  * @return array The array of hidden meta boxes
158
  */
159
  private static function get_misc_hidden_boxes() {
160
  $current_user = wp_get_current_user();
 
161
  return get_user_meta( $current_user->ID, self::VISIBLE_MISC_BOXES, true );
162
  }
163
  }
1
  <?php
2
  /**
3
+ * Utility class for deleting Misc stuff.
4
  *
5
  * @since 5.3
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Misc
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  class Bulk_Delete_Misc {
 
14
  /**
15
+ * Slug for *misc* page.
16
  *
17
  * @since 5.3
18
  */
21
  const VISIBLE_MISC_BOXES = 'metaboxhidden_bulk-delete_page_bulk-delete-misc';
22
 
23
  /**
24
+ * Add *misc* menu.
25
  *
26
  * @static
27
+ *
28
  * @since 5.3
29
  */
30
  public static function add_menu() {
48
  }
49
 
50
  /**
51
+ * Add settings Panel for delete misc page.
52
  *
53
  * @static
54
+ *
55
  * @since 5.3
56
  */
57
  public static function add_delete_misc_settings_panel() {
58
  $bd = BULK_DELETE();
59
 
60
  /**
61
+ * Add contextual help for admin screens.
62
  *
63
  * @since 5.3
64
  */
72
  }
73
 
74
  /**
75
+ * Register meta boxes for delete misc page.
76
  *
77
  * @static
78
+ *
79
  * @since 5.3
80
  */
81
  public static function add_delete_misc_meta_boxes() {
 
82
  /**
83
  * Add meta box in misc page
84
+ * This hook can be used for adding additional meta boxes in *misc* page.
85
  *
86
  * @since 5.3
87
  */
89
  }
90
 
91
  /**
92
+ * Show the delete misc page.
93
  *
94
  * @static
95
+ *
96
  * @since 5.3
97
  */
98
  public static function display_misc_page() {
138
  }
139
 
140
  /**
141
+ * Check whether the meta box in misc page is hidden or not.
142
  *
143
  * @static
144
  * @access private
145
+ *
146
  * @since 5.3
147
+ *
148
+ * @param string $box The name of the box to check
149
+ *
150
+ * @return bool True if the box is hidden, False otherwise
151
  */
152
  public static function is_misc_box_hidden( $box ) {
153
  $hidden_boxes = self::get_misc_hidden_boxes();
154
+
155
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
156
  }
157
 
158
  /**
159
+ * Get the list of hidden boxes in misc page.
160
  *
161
  * @static
162
  * @access private
163
+ *
164
  * @since 5.3
165
+ *
166
  * @return array The array of hidden meta boxes
167
  */
168
  private static function get_misc_hidden_boxes() {
169
  $current_user = wp_get_current_user();
170
+
171
  return get_user_meta( $current_user->ID, self::VISIBLE_MISC_BOXES, true );
172
  }
173
  }
include/pages/class-bulk-delete-pages.php CHANGED
@@ -1,26 +1,28 @@
1
  <?php
2
  /**
3
- * Utility class for deleting pages
4
  *
5
  * @since 5.0
 
6
  * @author Sudar
 
7
  * @package BulkDelete
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class Bulk_Delete_Pages {
13
-
14
  /**
15
- * Render delete pages by page status box
16
  *
17
  * @access public
18
  * @static
 
19
  * @since 5.0
20
  */
21
  public static function render_delete_pages_by_status_box() {
22
  if ( BD_Util::is_pages_box_hidden( Bulk_Delete::BOX_PAGE_STATUS ) ) {
23
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::PAGES_PAGE_SLUG );
 
24
  return;
25
  }
26
 
@@ -87,7 +89,7 @@ class Bulk_Delete_Pages {
87
  }
88
 
89
  /**
90
- * Request handler for deleting pages by status
91
  *
92
  * @since 5.0
93
  */
@@ -119,7 +121,7 @@ class Bulk_Delete_Pages {
119
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
120
  } else {
121
  $deleted_count = self::delete_pages_by_status( $delete_options );
122
- $msg = sprintf( _n( 'Deleted %d page', 'Deleted %d pages' , $deleted_count, 'bulk-delete' ), $deleted_count );
123
  }
124
 
125
  add_settings_error(
@@ -131,11 +133,13 @@ class Bulk_Delete_Pages {
131
  }
132
 
133
  /**
134
- * Bulk Delete pages
135
  *
136
  * @since 5.0
 
137
  * @param array $delete_options
138
- * @return integer
 
139
  */
140
  public static function delete_pages_by_status( $delete_options ) {
141
  global $wp_query;
@@ -180,7 +184,7 @@ class Bulk_Delete_Pages {
180
  );
181
 
182
  $options = bd_build_query_options( $delete_options, $options );
183
- $pages = $wp_query->query( $options );
184
  foreach ( $pages as $page ) {
185
  wp_delete_post( $page->ID, $delete_options['force_delete'] );
186
  }
@@ -189,15 +193,18 @@ class Bulk_Delete_Pages {
189
  }
190
 
191
  /**
192
- * Filter JS Array and add validation hooks
193
  *
194
  * @since 5.4
195
  * @static
196
- * @param array $js_array JavaScript Array
197
- * @return array Modified JavaScript Array
 
 
198
  */
199
  public static function filter_js_array( $js_array ) {
200
  $js_array['dt_iterators'][] = '_pages';
 
201
  return $js_array;
202
  }
203
  }
1
  <?php
2
  /**
3
+ * Utility class for deleting pages.
4
  *
5
  * @since 5.0
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  class Bulk_Delete_Pages {
 
14
  /**
15
+ * Render delete pages by page status box.
16
  *
17
  * @access public
18
  * @static
19
+ *
20
  * @since 5.0
21
  */
22
  public static function render_delete_pages_by_status_box() {
23
  if ( BD_Util::is_pages_box_hidden( Bulk_Delete::BOX_PAGE_STATUS ) ) {
24
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::PAGES_PAGE_SLUG );
25
+
26
  return;
27
  }
28
 
89
  }
90
 
91
  /**
92
+ * Request handler for deleting pages by status.
93
  *
94
  * @since 5.0
95
  */
121
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
122
  } else {
123
  $deleted_count = self::delete_pages_by_status( $delete_options );
124
+ $msg = sprintf( _n( 'Deleted %d page', 'Deleted %d pages' , $deleted_count, 'bulk-delete' ), $deleted_count );
125
  }
126
 
127
  add_settings_error(
133
  }
134
 
135
  /**
136
+ * Bulk Delete pages.
137
  *
138
  * @since 5.0
139
+ *
140
  * @param array $delete_options
141
+ *
142
+ * @return int
143
  */
144
  public static function delete_pages_by_status( $delete_options ) {
145
  global $wp_query;
184
  );
185
 
186
  $options = bd_build_query_options( $delete_options, $options );
187
+ $pages = $wp_query->query( $options );
188
  foreach ( $pages as $page ) {
189
  wp_delete_post( $page->ID, $delete_options['force_delete'] );
190
  }
193
  }
194
 
195
  /**
196
+ * Filter JS Array and add validation hooks.
197
  *
198
  * @since 5.4
199
  * @static
200
+ *
201
+ * @param array $js_array JavaScript Array
202
+ *
203
+ * @return array Modified JavaScript Array
204
  */
205
  public static function filter_js_array( $js_array ) {
206
  $js_array['dt_iterators'][] = '_pages';
207
+
208
  return $js_array;
209
  }
210
  }
include/posts/class-bulk-delete-posts.php CHANGED
@@ -1,132 +1,119 @@
1
  <?php
2
  /**
3
- * Utility class for deleting posts
4
  *
5
  * @author Sudar
 
6
  * @package BulkDelete
7
  */
8
-
9
- defined( 'ABSPATH' ) || exit; // Exit if accessed directly
10
 
11
  class Bulk_Delete_Posts {
12
  /**
13
- * Render post status box
14
  */
15
  public static function render_delete_posts_by_status_box() {
16
-
17
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_STATUS ) ) {
 
18
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
19
  return;
20
  }
21
 
22
- $posts_count = wp_count_posts();
23
- $publish = $posts_count->publish;
24
- $drafts = $posts_count->draft;
25
- $future = $posts_count->future;
26
- $pending = $posts_count->pending;
27
- $private = $posts_count->private;
28
-
29
- $sticky = count( get_option( 'sticky_posts' ) );
30
  ?>
31
- <h4><?php _e( 'Select the post status from which you want to delete posts', 'bulk-delete' ); ?></h4>
32
-
33
- <fieldset class="options">
34
- <table class="optiontable">
35
- <tr>
36
- <td>
37
- <input name="smbd_publish" id="smbd_publish" value="publish" type="checkbox">
38
- <label for="smbd_publish"><?php _e( 'All Published Posts', 'bulk-delete' ); ?> (<?php echo $publish . ' '; _e( 'Posts', 'bulk-delete' ); ?>)</label>
39
- </td>
40
- </tr>
41
-
42
- <tr>
43
- <td scope="row">
44
- <input name="smbd_drafts" id="smbd_drafts" value="drafts" type="checkbox">
45
- <label for="smbd_drafts"><?php _e( 'All Draft Posts', 'bulk-delete' ); ?> (<?php echo $drafts . ' '; _e( 'Drafts', 'bulk-delete' ); ?>)</label>
46
- </td>
47
- </tr>
48
-
49
- <tr>
50
- <td>
51
- <input name="smbd_pending" id="smbd_pending" value="pending" type="checkbox">
52
- <label for="smbd_pending"><?php _e( 'All Pending Posts', 'bulk-delete' ); ?> (<?php echo $pending . ' '; _e( 'Posts', 'bulk-delete' ); ?>)</label>
53
- </td>
54
- </tr>
55
-
56
- <tr>
57
- <td>
58
- <input name="smbd_future" id="smbd_future" value="future" type="checkbox">
59
- <label for="smbd_future"><?php _e( 'All Scheduled Posts', 'bulk-delete' ); ?> (<?php echo $future . ' '; _e( 'Posts', 'bulk-delete' ); ?>)</label>
60
- </td>
61
- </tr>
62
-
63
- <tr>
64
- <td>
65
- <input name="smbd_private" id="smbd_private" value="private" type="checkbox">
66
- <label for="smbd_private"><?php _e( 'All Private Posts', 'bulk-delete' ); ?> (<?php echo $private . ' '; _e( 'Posts', 'bulk-delete' ); ?>)</label>
67
- </td>
68
- </tr>
69
-
70
- <tr>
71
- <td>
72
- <input name="smbd_sticky" id="smbd_sticky" value="sticky" type="checkbox">
73
  <label for="smbd_sticky">
74
- <?php _e( 'All Sticky Posts', 'bulk-delete' ); ?> (<?php echo $sticky . ' '; _e( 'Posts', 'bulk-delete' ); ?>)
 
75
  <?php echo '<strong>', __( 'Note', 'bulk-delete' ), '</strong>: ', __( 'The date filter will not work for sticky posts', 'bulk-delete' ); ?>
76
  </label>
77
- </td>
78
- </tr>
 
79
  </table>
80
 
81
- <table class="optiontable">
82
  <?php bd_render_filtering_table_header(); ?>
83
  <?php bd_render_restrict_settings( 'post_status' ); ?>
84
  <?php bd_render_delete_settings( 'post_status' ); ?>
85
  <?php bd_render_limit_settings( 'post_status' ); ?>
86
  <?php bd_render_cron_settings( 'post_status', 'http://bulkwp.com/addons/scheduler-for-deleting-posts-by-status/?utm_source=wpadmin&utm_campaign=BulkDelete&utm_medium=buynow&utm_content=bd-sps' ); ?>
87
- </table>
88
 
89
- </fieldset>
90
  <?php
91
  bd_render_submit_button( 'delete_posts_by_status' );
92
  }
93
 
94
  /**
95
- * Delete posts by post status
96
  *
97
  * @since 5.0
98
  * @static
 
 
 
99
  */
100
  public static function do_delete_posts_by_status() {
101
- $delete_options = array();
102
- $delete_options['restrict'] = array_get_bool( $_POST, 'smbd_post_status_restrict', false );
103
- $delete_options['limit_to'] = absint( array_get( $_POST, 'smbd_post_status_limit_to', 0 ) );
104
- $delete_options['force_delete'] = array_get_bool( $_POST, 'smbd_post_status_force_delete', false );
105
-
106
- $delete_options['date_op'] = array_get( $_POST, 'smbd_post_status_op' );
107
- $delete_options['days'] = absint( array_get( $_POST, 'smbd_post_status_days' ) );
108
-
109
- $delete_options['publish'] = array_get( $_POST, 'smbd_publish' );
110
- $delete_options['drafts'] = array_get( $_POST, 'smbd_drafts' );
111
- $delete_options['pending'] = array_get( $_POST, 'smbd_pending' );
112
- $delete_options['future'] = array_get( $_POST, 'smbd_future' );
113
- $delete_options['private'] = array_get( $_POST, 'smbd_private' );
114
- $delete_options['sticky'] = array_get( $_POST, 'smbd_sticky' );
115
-
116
- if ( array_get( $_POST, 'smbd_post_status_cron', 'false' ) == 'true' ) {
117
- $freq = $_POST['smbd_post_status_cron_freq'];
118
  $time = strtotime( $_POST['smbd_post_status_cron_start'] ) - ( get_option( 'gmt_offset' ) * 60 * 60 );
119
 
120
- if ( $freq == -1 ) {
121
  wp_schedule_single_event( $time, Bulk_Delete::CRON_HOOK_POST_STATUS, array( $delete_options ) );
122
  } else {
123
  wp_schedule_event( $time, $freq, Bulk_Delete::CRON_HOOK_POST_STATUS, array( $delete_options ) );
124
  }
125
- $msg = __( 'Posts with the selected status are scheduled for deletion.', 'bulk-delete' ) . ' ' .
126
- sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
 
 
 
127
  } else {
128
  $deleted_count = self::delete_posts_by_status( $delete_options );
129
- $msg = sprintf( _n( 'Deleted %d post with the selected post status', 'Deleted %d posts with the selected post status' , $deleted_count, 'bulk-delete' ), $deleted_count );
 
 
130
  }
131
 
132
  add_settings_error(
@@ -135,7 +122,7 @@ class Bulk_Delete_Posts {
135
  $msg,
136
  'updated'
137
  );
138
- }
139
 
140
  /**
141
  * Delete posts by post status - drafts, pending posts, scheduled posts etc.
@@ -143,82 +130,67 @@ class Bulk_Delete_Posts {
143
  * @since 5.0
144
  * @static
145
  *
146
- * @param array $delete_options Options for deleting posts
147
- * @return int $posts_deleted Number of posts that were deleted
 
148
  */
149
  public static function delete_posts_by_status( $delete_options ) {
150
- global $wpdb;
151
-
152
- // Backward compatibility code. Will be removed in Bulk Delete v6.0
153
- if ( array_key_exists( 'post_status_op', $delete_options ) ) {
154
- $delete_options['date_op'] = $delete_options['post_status_op'];
155
- $delete_options['days'] = $delete_options['post_status_days'];
156
- }
157
-
158
  $delete_options = apply_filters( 'bd_delete_options', $delete_options );
159
 
160
  $posts_deleted = 0;
161
 
162
- // Delete sticky posts
163
- if ( 'sticky' == $delete_options['sticky'] ) {
164
- $sticky_post_ids = get_option( 'sticky_posts' );
165
-
166
- foreach ( $sticky_post_ids as $sticky_post_id ) {
167
- wp_delete_post( $sticky_post_id, $delete_options['force_delete'] );
168
- }
169
-
170
- $posts_deleted += count( $sticky_post_ids );
171
- }
172
-
173
- $options = array();
174
- $post_status = array();
175
-
176
- // Published posts
177
- if ( 'publish' == $delete_options['publish'] ) {
178
- $post_status[] = 'publish';
179
  }
180
 
181
- // Drafts
182
- if ( 'drafts' == $delete_options['drafts'] ) {
183
- $post_status[] = 'draft';
184
-
185
- // ignore sticky posts.
186
- // For some reason, sticky posts also gets deleted when deleting drafts through a schedule
187
- $options['post__not_in'] = get_option( 'sticky_posts' );
188
- }
189
-
190
- // Pending Posts
191
- if ( 'pending' == $delete_options['pending'] ) {
192
- $post_status[] = 'pending';
193
- }
194
-
195
- // Future Posts
196
- if ( 'future' == $delete_options['future'] ) {
197
- $post_status[] = 'future';
198
  }
199
 
200
- // Private Posts
201
- if ( 'private' == $delete_options['private'] ) {
202
- $post_status[] = 'private';
203
- }
204
 
205
- $options['post_status'] = $post_status;
206
  $options = bd_build_query_options( $delete_options, $options );
 
207
  $post_ids = bd_query( $options );
208
  foreach ( $post_ids as $post_id ) {
209
  wp_delete_post( $post_id, $delete_options['force_delete'] );
210
  }
211
 
212
  $posts_deleted += count( $post_ids );
 
213
  return $posts_deleted;
214
  }
215
 
216
  /**
217
- * Render Delete posts by category box
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
218
  */
219
  public static function render_delete_posts_by_category_box() {
220
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_CATEGORY ) ) {
221
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
222
  return;
223
  }
224
  ?>
@@ -265,7 +237,7 @@ class Bulk_Delete_Posts {
265
  }
266
 
267
  /**
268
- * Process delete posts by category
269
  *
270
  * @since 5.0
271
  * @static
@@ -297,7 +269,7 @@ class Bulk_Delete_Posts {
297
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
298
  } else {
299
  $deleted_count = self::delete_posts_by_category( $delete_options );
300
- $msg = sprintf( _n( 'Deleted %d post from the selected categories', 'Deleted %d posts from the selected categories' , $deleted_count, 'bulk-delete' ), $deleted_count );
301
  }
302
 
303
  add_settings_error(
@@ -309,12 +281,14 @@ class Bulk_Delete_Posts {
309
  }
310
 
311
  /**
312
- * Delete posts by category
313
  *
314
  * @since 5.0
315
  * @static
316
- * @param array $delete_options Options for deleting posts
317
- * @return int $posts_deleted Number of posts that were deleted
 
 
318
  */
319
  public static function delete_posts_by_category( $delete_options ) {
320
  // Backward compatibility code. Will be removed in Bulk Delete v6.0
@@ -327,7 +301,7 @@ class Bulk_Delete_Posts {
327
 
328
  $delete_options = apply_filters( 'bd_delete_options', $delete_options );
329
 
330
- $options = array();
331
  $selected_cats = $delete_options['selected_cats'];
332
  if ( in_array( 'all', $selected_cats ) ) {
333
  $options['category__not__in'] = array(0);
@@ -335,7 +309,7 @@ class Bulk_Delete_Posts {
335
  $options['category__in'] = $selected_cats;
336
  }
337
 
338
- $options = bd_build_query_options( $delete_options, $options );
339
  $post_ids = bd_query( $options );
340
 
341
  foreach ( $post_ids as $post_id ) {
@@ -351,11 +325,12 @@ class Bulk_Delete_Posts {
351
  }
352
 
353
  /**
354
- * Render delete posts by tag box
355
  */
356
  public static function render_delete_posts_by_tag_box() {
357
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_TAG ) ) {
358
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
359
  return;
360
  }
361
 
@@ -398,9 +373,10 @@ class Bulk_Delete_Posts {
398
  }
399
 
400
  /**
401
- * Process Delete Posts by tag request
402
  *
403
  * @static
 
404
  * @since 5.0
405
  */
406
  public static function do_delete_posts_by_tag() {
@@ -427,7 +403,7 @@ class Bulk_Delete_Posts {
427
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
428
  } else {
429
  $deleted_count = self::delete_posts_by_tag( $delete_options );
430
- $msg = sprintf( _n( 'Deleted %d post from the selected tags', 'Deleted %d posts from the selected tags' , $deleted_count, 'bulk-delete' ), $deleted_count );
431
  }
432
 
433
  add_settings_error(
@@ -439,12 +415,14 @@ class Bulk_Delete_Posts {
439
  }
440
 
441
  /**
442
- * Delete posts by tag
443
  *
444
  * @since 5.0
445
  * @static
446
- * @param array $delete_options Options for deleting posts
447
- * @return int $posts_deleted Number of posts that were deleted
 
 
448
  */
449
  public static function delete_posts_by_tag( $delete_options ) {
450
  // Backward compatibility code. Will be removed in Bulk Delete v6.0
@@ -455,7 +433,7 @@ class Bulk_Delete_Posts {
455
 
456
  $delete_options = apply_filters( 'bd_delete_options', $delete_options );
457
 
458
- $options = array();
459
  $selected_tags = $delete_options['selected_tags'];
460
  if ( in_array( 'all', $selected_tags ) ) {
461
  $options['tag__not__in'] = array(0);
@@ -463,7 +441,7 @@ class Bulk_Delete_Posts {
463
  $options['tag__in'] = $selected_tags;
464
  }
465
 
466
- $options = bd_build_query_options( $delete_options, $options );
467
  $post_ids = bd_query( $options );
468
  foreach ( $post_ids as $post_id ) {
469
  wp_delete_post( $post_id, $delete_options['force_delete'] );
@@ -478,12 +456,13 @@ class Bulk_Delete_Posts {
478
  public static function render_delete_posts_by_taxonomy_box() {
479
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_TAX ) ) {
480
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
481
  return;
482
  }
483
 
484
  $taxs = get_taxonomies( array(
485
  'public' => true,
486
- '_builtin' => false
487
  ), 'objects'
488
  );
489
 
@@ -573,6 +552,7 @@ class Bulk_Delete_Posts {
573
  * Process Delete posts by Taxonomy Request.
574
  *
575
  * @static
 
576
  * @since 5.0
577
  */
578
  public static function do_delete_posts_by_taxonomy() {
@@ -601,7 +581,7 @@ class Bulk_Delete_Posts {
601
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
602
  } else {
603
  $deleted_count = self::delete_posts_by_taxonomy( $delete_options );
604
- $msg = sprintf( _n( 'Deleted %d post from the selected custom taxonomies', 'Deleted %d posts from the selected custom taxonomies' , $deleted_count, 'bulk-delete' ), $deleted_count );
605
  }
606
 
607
  add_settings_error(
@@ -617,8 +597,10 @@ class Bulk_Delete_Posts {
617
  *
618
  * @since 5.0
619
  * @static
 
620
  * @param array $delete_options Options for deleting posts
621
- * @return int $posts_deleted Number of posts that were deleted
 
622
  */
623
  public static function delete_posts_by_taxonomy( $delete_options ) {
624
  // For compatibility reasons set default post type to 'post'
@@ -643,10 +625,10 @@ class Bulk_Delete_Posts {
643
  'terms' => $selected_tax_terms,
644
  'field' => 'slug',
645
  ),
646
- )
647
  );
648
 
649
- $options = bd_build_query_options( $delete_options, $options );
650
  $post_ids = bd_query( $options );
651
  foreach ( $post_ids as $post_id ) {
652
  // $force delete parameter to custom post types doesn't work
@@ -668,6 +650,7 @@ class Bulk_Delete_Posts {
668
  public static function render_delete_posts_by_post_type_box() {
669
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_TYPE ) ) {
670
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
671
  return;
672
  }
673
 
@@ -739,6 +722,7 @@ class Bulk_Delete_Posts {
739
  * Process request to delete posts by post type.
740
  *
741
  * @static
 
742
  * @since 5.0
743
  */
744
  public static function do_delete_posts_by_post_type() {
@@ -766,7 +750,7 @@ class Bulk_Delete_Posts {
766
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
767
  } else {
768
  $deleted_count = self::delete_posts_by_post_type( $delete_options );
769
- $msg = sprintf( _n( 'Deleted %d post from the selected custom post type', 'Deleted %d posts from the selected custom post type' , $deleted_count, 'bulk-delete' ), $deleted_count );
770
  }
771
 
772
  add_settings_error(
@@ -781,9 +765,12 @@ class Bulk_Delete_Posts {
781
  * Delete posts by custom post type.
782
  *
783
  * @static
 
784
  * @since 5.0
785
- * @param array $delete_options Options for deleting posts
786
- * @return int $posts_deleted Number of posts that were deleted
 
 
787
  */
788
  public static function delete_posts_by_post_type( $delete_options ) {
789
  // Backward compatibility code. Will be removed in Bulk Delete v6.0
@@ -794,11 +781,10 @@ class Bulk_Delete_Posts {
794
 
795
  $delete_options = apply_filters( 'bd_delete_options', $delete_options );
796
 
797
- $count = 0;
798
  $selected_types = $delete_options['selected_types'];
799
 
800
  foreach ( $selected_types as $selected_type ) {
801
-
802
  $type_status = BD_Util::split_post_type_status( $selected_type );
803
 
804
  $type = $type_status['type'];
@@ -809,7 +795,7 @@ class Bulk_Delete_Posts {
809
  'post_type' => $type,
810
  );
811
 
812
- $options = bd_build_query_options( $delete_options, $options );
813
  $post_ids = bd_query( $options );
814
  foreach ( $post_ids as $post_id ) {
815
  // $force delete parameter to custom post types doesn't work
@@ -834,6 +820,7 @@ class Bulk_Delete_Posts {
834
  public static function render_delete_posts_by_url_box() {
835
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_URL ) ) {
836
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
837
  return;
838
  }
839
  ?>
@@ -860,9 +847,10 @@ class Bulk_Delete_Posts {
860
  }
861
 
862
  /**
863
- * Delete posts by url
864
  *
865
  * @static
 
866
  * @since 5.0
867
  */
868
  public static function do_delete_posts_by_url() {
@@ -879,7 +867,7 @@ class Bulk_Delete_Posts {
879
  }
880
 
881
  $deleted_count = count( $urls );
882
- $msg = sprintf( _n( 'Deleted %d post with the specified urls', 'Deleted %d posts with the specified urls' , $deleted_count, 'bulk-delete' ), $deleted_count );
883
 
884
  add_settings_error(
885
  Bulk_Delete::POSTS_PAGE_SLUG,
@@ -890,7 +878,7 @@ class Bulk_Delete_Posts {
890
  }
891
 
892
  /**
893
- * Render delete by post revisions box
894
  *
895
  * @static
896
  */
@@ -899,6 +887,7 @@ class Bulk_Delete_Posts {
899
 
900
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_REVISION ) ) {
901
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
 
902
  return;
903
  }
904
 
@@ -923,9 +912,10 @@ class Bulk_Delete_Posts {
923
  }
924
 
925
  /**
926
- * Process delete revisions request
927
  *
928
  * @static
 
929
  * @since 5.0
930
  */
931
  public static function do_delete_posts_by_revision() {
@@ -944,12 +934,14 @@ class Bulk_Delete_Posts {
944
  }
945
 
946
  /**
947
- * Delete all post revisions
948
  *
949
  * @since 5.0
950
  * @static
 
951
  * @param array $delete_options
952
- * @return int The number of posts that were deleted
 
953
  */
954
  public static function delete_posts_by_revision( $delete_options ) {
955
  global $wpdb;
@@ -969,28 +961,30 @@ class Bulk_Delete_Posts {
969
  }
970
 
971
  /**
972
- * Filter JS Array and add validation hooks
973
  *
974
  * @since 5.4
975
  * @static
976
- * @param array $js_array JavaScript Array
977
- * @return array Modified JavaScript Array
 
 
978
  */
979
  public static function filter_js_array( $js_array ) {
980
  $js_array['msg']['deletePostsWarning'] = __( 'Are you sure you want to delete all the posts based on the selected option?', 'bulk-delete' );
981
- $js_array['msg']['selectPostOption'] = __( 'Please select posts from at least one option', 'bulk-delete' );
982
 
983
  $js_array['validators']['delete_posts_by_category'] = 'validateSelect2';
984
- $js_array['error_msg']['delete_posts_by_category'] = 'selectCategory';
985
- $js_array['msg']['selectCategory'] = __( 'Please select at least one category', 'bulk-delete' );
986
 
987
- $js_array['validators']['delete_posts_by_tag'] = 'validateSelect2';
988
  $js_array['error_msg']['delete_posts_by_category'] = 'selectTag';
989
- $js_array['msg']['selectTag'] = __( 'Please select at least one tag', 'bulk-delete' );
990
 
991
  $js_array['validators']['delete_posts_by_url'] = 'validateUrl';
992
- $js_array['error_msg']['delete_posts_by_url'] = 'enterUrl';
993
- $js_array['msg']['enterUrl'] = __( 'Please enter at least one post url', 'bulk-delete' );
994
 
995
  $js_array['dt_iterators'][] = '_cats';
996
  $js_array['dt_iterators'][] = '_tags';
@@ -1004,13 +998,13 @@ class Bulk_Delete_Posts {
1004
  /**
1005
  * Process delete cron job request.
1006
  * This should ideally go in a separate class. But I was
1007
- * lazy to create a separate class for a single function
1008
  *
1009
  * @since 5.0
1010
  * @static
1011
  */
1012
  public static function do_delete_cron() {
1013
- $cron_id = absint( $_GET['cron_id'] );
1014
  $cron_items = BD_Util::get_cron_schedules();
1015
  wp_unschedule_event( $cron_items[$cron_id]['timestamp'], $cron_items[$cron_id]['type'], $cron_items[$cron_id]['args'] );
1016
 
1
  <?php
2
  /**
3
+ * Utility class for deleting posts.
4
  *
5
  * @author Sudar
6
+ *
7
  * @package BulkDelete
8
  */
9
+ defined( 'ABSPATH' ) || exit; // Exit if accessed directly.
 
10
 
11
  class Bulk_Delete_Posts {
12
  /**
13
+ * Render post status box.
14
  */
15
  public static function render_delete_posts_by_status_box() {
 
16
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_STATUS ) ) {
17
+ /* translators: 1 Number of posts that are deleted. */
18
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
19
+
20
  return;
21
  }
22
 
23
+ $post_statuses = bd_get_post_statuses();
24
+ $post_count = wp_count_posts();
 
 
 
 
 
 
25
  ?>
26
+ <h4><?php _e( 'Select the post statuses from which you want to delete posts', 'bulk-delete' ); ?></h4>
27
+
28
+ <fieldset class="options">
29
+ <table class="optiontable">
30
+
31
+ <?php foreach ( $post_statuses as $post_status ) : ?>
32
+ <tr>
33
+ <td>
34
+ <input name="smbd_post_status[]" id="smbd_<?php echo esc_attr( $post_status->name ); ?>"
35
+ value="<?php echo esc_attr( $post_status->name ); ?>" type="checkbox">
36
+
37
+ <label for="smbd_<?php echo esc_attr( $post_status->name ); ?>">
38
+ <?php echo esc_html( $post_status->label ), ' '; ?>
39
+ <?php if ( property_exists( $post_count, $post_status->name ) ) : ?>
40
+ (<?php echo absint( $post_count->{ $post_status->name } ) . ' ', __( 'Posts', 'bulk-delete' ); ?>)
41
+ <?php endif; ?>
42
+ </label>
43
+ </td>
44
+ </tr>
45
+ <?php endforeach; ?>
46
+
47
+ <?php $sticky_post_count = count( get_option( 'sticky_posts' ) ); ?>
48
+
49
+ <tr>
50
+ <td>
51
+ <input name="smbd_sticky" id="smbd_sticky" value="on" type="checkbox">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
52
  <label for="smbd_sticky">
53
+ <?php echo __( 'All Sticky Posts', 'bulk-delete' ), ' '; ?>
54
+ (<?php echo absint( $sticky_post_count ), ' ', __( 'Posts', 'bulk-delete' ); ?>)
55
  <?php echo '<strong>', __( 'Note', 'bulk-delete' ), '</strong>: ', __( 'The date filter will not work for sticky posts', 'bulk-delete' ); ?>
56
  </label>
57
+ </td>
58
+ </tr>
59
+
60
  </table>
61
 
62
+ <table class="optiontable">
63
  <?php bd_render_filtering_table_header(); ?>
64
  <?php bd_render_restrict_settings( 'post_status' ); ?>
65
  <?php bd_render_delete_settings( 'post_status' ); ?>
66
  <?php bd_render_limit_settings( 'post_status' ); ?>
67
  <?php bd_render_cron_settings( 'post_status', 'http://bulkwp.com/addons/scheduler-for-deleting-posts-by-status/?utm_source=wpadmin&utm_campaign=BulkDelete&utm_medium=buynow&utm_content=bd-sps' ); ?>
68
+ </table>
69
 
70
+ </fieldset>
71
  <?php
72
  bd_render_submit_button( 'delete_posts_by_status' );
73
  }
74
 
75
  /**
76
+ * Delete posts by post status.
77
  *
78
  * @since 5.0
79
  * @static
80
+ *
81
+ * Nonce verification is done in the hook that calls this function.
82
+ * phpcs:disable WordPress.CSRF.NonceVerification.NoNonceVerification
83
  */
84
  public static function do_delete_posts_by_status() {
85
+ $delete_options = array();
86
+
87
+ $delete_options['restrict'] = bd_array_get_bool( $_POST, 'smbd_post_status_restrict', false );
88
+ $delete_options['limit_to'] = absint( bd_array_get( $_POST, 'smbd_post_status_limit_to', 0 ) );
89
+ $delete_options['force_delete'] = bd_array_get_bool( $_POST, 'smbd_post_status_force_delete', false );
90
+
91
+ $delete_options['date_op'] = bd_array_get( $_POST, 'smbd_post_status_op' );
92
+ $delete_options['days'] = absint( bd_array_get( $_POST, 'smbd_post_status_days' ) );
93
+
94
+ $delete_options['post_status'] = array_map( 'sanitize_text_field', bd_array_get( $_POST, 'smbd_post_status', array() ) );
95
+
96
+ $delete_options['delete-sticky-posts'] = bd_array_get_bool( $_POST, 'smbd_sticky', false );
97
+
98
+ if ( bd_array_get_bool( $_POST, 'smbd_post_status_cron', false ) ) {
99
+ $freq = sanitize_text_field( $_POST['smbd_post_status_cron_freq'] );
 
 
100
  $time = strtotime( $_POST['smbd_post_status_cron_start'] ) - ( get_option( 'gmt_offset' ) * 60 * 60 );
101
 
102
+ if ( -1 === $freq ) {
103
  wp_schedule_single_event( $time, Bulk_Delete::CRON_HOOK_POST_STATUS, array( $delete_options ) );
104
  } else {
105
  wp_schedule_event( $time, $freq, Bulk_Delete::CRON_HOOK_POST_STATUS, array( $delete_options ) );
106
  }
107
+
108
+ $msg = __( 'Posts with the selected status are scheduled for deletion.', 'bulk-delete' ) . ' ';
109
+
110
+ /* translators: 1 Url to view cron jobs */
111
+ $msg .= sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>', 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
112
  } else {
113
  $deleted_count = self::delete_posts_by_status( $delete_options );
114
+
115
+ /* translators: 1 Number of posts deleted */
116
+ $msg = sprintf( _n( 'Deleted %d post with the selected post status', 'Deleted %d posts with the selected post status', $deleted_count, 'bulk-delete' ), $deleted_count );
117
  }
118
 
119
  add_settings_error(
122
  $msg,
123
  'updated'
124
  );
125
+ } // phpcs:enable
126
 
127
  /**
128
  * Delete posts by post status - drafts, pending posts, scheduled posts etc.
130
  * @since 5.0
131
  * @static
132
  *
133
+ * @param array $delete_options Options for deleting posts.
134
+ *
135
+ * @return int $posts_deleted Number of posts that were deleted
136
  */
137
  public static function delete_posts_by_status( $delete_options ) {
138
+ $delete_options = bd_convert_old_options_for_delete_post_by_status( $delete_options );
 
 
 
 
 
 
 
139
  $delete_options = apply_filters( 'bd_delete_options', $delete_options );
140
 
141
  $posts_deleted = 0;
142
 
143
+ if ( $delete_options['delete-sticky-posts'] ) {
144
+ $posts_deleted += self::delete_sticky_posts( $delete_options['force_delete'] );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
145
  }
146
 
147
+ if ( empty( $delete_options['post_status'] ) ) {
148
+ return $posts_deleted;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
149
  }
150
 
151
+ $options = array(
152
+ 'post_status' => $delete_options['post_status'],
153
+ 'post__not_in' => get_option( 'sticky_posts' ),
154
+ );
155
 
 
156
  $options = bd_build_query_options( $delete_options, $options );
157
+
158
  $post_ids = bd_query( $options );
159
  foreach ( $post_ids as $post_id ) {
160
  wp_delete_post( $post_id, $delete_options['force_delete'] );
161
  }
162
 
163
  $posts_deleted += count( $post_ids );
164
+
165
  return $posts_deleted;
166
  }
167
 
168
  /**
169
+ * Delete all sticky posts.
170
+ *
171
+ * @since 5.6.0
172
+ *
173
+ * @param bool $force_delete Whether to force delete the posts.
174
+ *
175
+ * @return int Number of posts deleted.
176
+ */
177
+ public static function delete_sticky_posts( $force_delete ) {
178
+ $sticky_post_ids = get_option( 'sticky_posts' );
179
+
180
+ foreach ( $sticky_post_ids as $sticky_post_id ) {
181
+ wp_delete_post( $sticky_post_id, $force_delete );
182
+ }
183
+
184
+ return count( $sticky_post_ids );
185
+ }
186
+
187
+ /**
188
+ * Render Delete posts by category box.
189
  */
190
  public static function render_delete_posts_by_category_box() {
191
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_CATEGORY ) ) {
192
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
193
+
194
  return;
195
  }
196
  ?>
237
  }
238
 
239
  /**
240
+ * Process delete posts by category.
241
  *
242
  * @since 5.0
243
  * @static
269
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
270
  } else {
271
  $deleted_count = self::delete_posts_by_category( $delete_options );
272
+ $msg = sprintf( _n( 'Deleted %d post from the selected categories', 'Deleted %d posts from the selected categories' , $deleted_count, 'bulk-delete' ), $deleted_count );
273
  }
274
 
275
  add_settings_error(
281
  }
282
 
283
  /**
284
+ * Delete posts by category.
285
  *
286
  * @since 5.0
287
  * @static
288
+ *
289
+ * @param array $delete_options Options for deleting posts
290
+ *
291
+ * @return int $posts_deleted Number of posts that were deleted
292
  */
293
  public static function delete_posts_by_category( $delete_options ) {
294
  // Backward compatibility code. Will be removed in Bulk Delete v6.0
301
 
302
  $delete_options = apply_filters( 'bd_delete_options', $delete_options );
303
 
304
+ $options = array();
305
  $selected_cats = $delete_options['selected_cats'];
306
  if ( in_array( 'all', $selected_cats ) ) {
307
  $options['category__not__in'] = array(0);
309
  $options['category__in'] = $selected_cats;
310
  }
311
 
312
+ $options = bd_build_query_options( $delete_options, $options );
313
  $post_ids = bd_query( $options );
314
 
315
  foreach ( $post_ids as $post_id ) {
325
  }
326
 
327
  /**
328
+ * Render delete posts by tag box.
329
  */
330
  public static function render_delete_posts_by_tag_box() {
331
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_TAG ) ) {
332
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
333
+
334
  return;
335
  }
336
 
373
  }
374
 
375
  /**
376
+ * Process Delete Posts by tag request.
377
  *
378
  * @static
379
+ *
380
  * @since 5.0
381
  */
382
  public static function do_delete_posts_by_tag() {
403
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
404
  } else {
405
  $deleted_count = self::delete_posts_by_tag( $delete_options );
406
+ $msg = sprintf( _n( 'Deleted %d post from the selected tags', 'Deleted %d posts from the selected tags' , $deleted_count, 'bulk-delete' ), $deleted_count );
407
  }
408
 
409
  add_settings_error(
415
  }
416
 
417
  /**
418
+ * Delete posts by tag.
419
  *
420
  * @since 5.0
421
  * @static
422
+ *
423
+ * @param array $delete_options Options for deleting posts
424
+ *
425
+ * @return int $posts_deleted Number of posts that were deleted
426
  */
427
  public static function delete_posts_by_tag( $delete_options ) {
428
  // Backward compatibility code. Will be removed in Bulk Delete v6.0
433
 
434
  $delete_options = apply_filters( 'bd_delete_options', $delete_options );
435
 
436
+ $options = array();
437
  $selected_tags = $delete_options['selected_tags'];
438
  if ( in_array( 'all', $selected_tags ) ) {
439
  $options['tag__not__in'] = array(0);
441
  $options['tag__in'] = $selected_tags;
442
  }
443
 
444
+ $options = bd_build_query_options( $delete_options, $options );
445
  $post_ids = bd_query( $options );
446
  foreach ( $post_ids as $post_id ) {
447
  wp_delete_post( $post_id, $delete_options['force_delete'] );
456
  public static function render_delete_posts_by_taxonomy_box() {
457
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_TAX ) ) {
458
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
459
+
460
  return;
461
  }
462
 
463
  $taxs = get_taxonomies( array(
464
  'public' => true,
465
+ '_builtin' => false,
466
  ), 'objects'
467
  );
468
 
552
  * Process Delete posts by Taxonomy Request.
553
  *
554
  * @static
555
+ *
556
  * @since 5.0
557
  */
558
  public static function do_delete_posts_by_taxonomy() {
581
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
582
  } else {
583
  $deleted_count = self::delete_posts_by_taxonomy( $delete_options );
584
+ $msg = sprintf( _n( 'Deleted %d post from the selected custom taxonomies', 'Deleted %d posts from the selected custom taxonomies' , $deleted_count, 'bulk-delete' ), $deleted_count );
585
  }
586
 
587
  add_settings_error(
597
  *
598
  * @since 5.0
599
  * @static
600
+ *
601
  * @param array $delete_options Options for deleting posts
602
+ *
603
+ * @return int $posts_deleted Number of posts that were deleted
604
  */
605
  public static function delete_posts_by_taxonomy( $delete_options ) {
606
  // For compatibility reasons set default post type to 'post'
625
  'terms' => $selected_tax_terms,
626
  'field' => 'slug',
627
  ),
628
+ ),
629
  );
630
 
631
+ $options = bd_build_query_options( $delete_options, $options );
632
  $post_ids = bd_query( $options );
633
  foreach ( $post_ids as $post_id ) {
634
  // $force delete parameter to custom post types doesn't work
650
  public static function render_delete_posts_by_post_type_box() {
651
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_TYPE ) ) {
652
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
653
+
654
  return;
655
  }
656
 
722
  * Process request to delete posts by post type.
723
  *
724
  * @static
725
+ *
726
  * @since 5.0
727
  */
728
  public static function do_delete_posts_by_post_type() {
750
  sprintf( __( 'See the full list of <a href = "%s">scheduled tasks</a>' , 'bulk-delete' ), get_bloginfo( 'wpurl' ) . '/wp-admin/admin.php?page=' . Bulk_Delete::CRON_PAGE_SLUG );
751
  } else {
752
  $deleted_count = self::delete_posts_by_post_type( $delete_options );
753
+ $msg = sprintf( _n( 'Deleted %d post from the selected custom post type', 'Deleted %d posts from the selected custom post type' , $deleted_count, 'bulk-delete' ), $deleted_count );
754
  }
755
 
756
  add_settings_error(
765
  * Delete posts by custom post type.
766
  *
767
  * @static
768
+ *
769
  * @since 5.0
770
+ *
771
+ * @param array $delete_options Options for deleting posts
772
+ *
773
+ * @return int $posts_deleted Number of posts that were deleted
774
  */
775
  public static function delete_posts_by_post_type( $delete_options ) {
776
  // Backward compatibility code. Will be removed in Bulk Delete v6.0
781
 
782
  $delete_options = apply_filters( 'bd_delete_options', $delete_options );
783
 
784
+ $count = 0;
785
  $selected_types = $delete_options['selected_types'];
786
 
787
  foreach ( $selected_types as $selected_type ) {
 
788
  $type_status = BD_Util::split_post_type_status( $selected_type );
789
 
790
  $type = $type_status['type'];
795
  'post_type' => $type,
796
  );
797
 
798
+ $options = bd_build_query_options( $delete_options, $options );
799
  $post_ids = bd_query( $options );
800
  foreach ( $post_ids as $post_id ) {
801
  // $force delete parameter to custom post types doesn't work
820
  public static function render_delete_posts_by_url_box() {
821
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_URL ) ) {
822
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
823
+
824
  return;
825
  }
826
  ?>
847
  }
848
 
849
  /**
850
+ * Delete posts by url.
851
  *
852
  * @static
853
+ *
854
  * @since 5.0
855
  */
856
  public static function do_delete_posts_by_url() {
867
  }
868
 
869
  $deleted_count = count( $urls );
870
+ $msg = sprintf( _n( 'Deleted %d post with the specified urls', 'Deleted %d posts with the specified urls' , $deleted_count, 'bulk-delete' ), $deleted_count );
871
 
872
  add_settings_error(
873
  Bulk_Delete::POSTS_PAGE_SLUG,
878
  }
879
 
880
  /**
881
+ * Render delete by post revisions box.
882
  *
883
  * @static
884
  */
887
 
888
  if ( BD_Util::is_posts_box_hidden( Bulk_Delete::BOX_POST_REVISION ) ) {
889
  printf( __( 'This section just got enabled. Kindly <a href = "%1$s">refresh</a> the page to fully enable it.', 'bulk-delete' ), 'admin.php?page=' . Bulk_Delete::POSTS_PAGE_SLUG );
890
+
891
  return;
892
  }
893
 
912
  }
913
 
914
  /**
915
+ * Process delete revisions request.
916
  *
917
  * @static
918
+ *
919
  * @since 5.0
920
  */
921
  public static function do_delete_posts_by_revision() {
934
  }
935
 
936
  /**
937
+ * Delete all post revisions.
938
  *
939
  * @since 5.0
940
  * @static
941
+ *
942
  * @param array $delete_options
943
+ *
944
+ * @return int The number of posts that were deleted
945
  */
946
  public static function delete_posts_by_revision( $delete_options ) {
947
  global $wpdb;
961
  }
962
 
963
  /**
964
+ * Filter JS Array and add validation hooks.
965
  *
966
  * @since 5.4
967
  * @static
968
+ *
969
+ * @param array $js_array JavaScript Array
970
+ *
971
+ * @return array Modified JavaScript Array
972
  */
973
  public static function filter_js_array( $js_array ) {
974
  $js_array['msg']['deletePostsWarning'] = __( 'Are you sure you want to delete all the posts based on the selected option?', 'bulk-delete' );
975
+ $js_array['msg']['selectPostOption'] = __( 'Please select posts from at least one option', 'bulk-delete' );
976
 
977
  $js_array['validators']['delete_posts_by_category'] = 'validateSelect2';
978
+ $js_array['error_msg']['delete_posts_by_category'] = 'selectCategory';
979
+ $js_array['msg']['selectCategory'] = __( 'Please select at least one category', 'bulk-delete' );
980
 
981
+ $js_array['validators']['delete_posts_by_tag'] = 'validateSelect2';
982
  $js_array['error_msg']['delete_posts_by_category'] = 'selectTag';
983
+ $js_array['msg']['selectTag'] = __( 'Please select at least one tag', 'bulk-delete' );
984
 
985
  $js_array['validators']['delete_posts_by_url'] = 'validateUrl';
986
+ $js_array['error_msg']['delete_posts_by_url'] = 'enterUrl';
987
+ $js_array['msg']['enterUrl'] = __( 'Please enter at least one post url', 'bulk-delete' );
988
 
989
  $js_array['dt_iterators'][] = '_cats';
990
  $js_array['dt_iterators'][] = '_tags';
998
  /**
999
  * Process delete cron job request.
1000
  * This should ideally go in a separate class. But I was
1001
+ * lazy to create a separate class for a single function.
1002
  *
1003
  * @since 5.0
1004
  * @static
1005
  */
1006
  public static function do_delete_cron() {
1007
+ $cron_id = absint( $_GET['cron_id'] );
1008
  $cron_items = BD_Util::get_cron_schedules();
1009
  wp_unschedule_event( $cron_items[$cron_id]['timestamp'], $cron_items[$cron_id]['type'], $cron_items[$cron_id]['args'] );
1010
 
include/settings/class-bd-settings-page.php CHANGED
@@ -1,25 +1,25 @@
1
  <?php
2
  /**
3
- * Utility class for Settings page
4
  *
5
  * @since 5.3
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Admin\Settings
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class BD_Settings_Page {
13
-
14
  /**
15
- * Slug for settings page
16
  *
17
  * @since 5.3
18
  */
19
  const SETTINGS_PAGE_SLUG = 'bd-settings';
20
 
21
  /**
22
- * Slugs for addon settings
23
  *
24
  * @since 5.3
25
  */
@@ -27,9 +27,10 @@ class BD_Settings_Page {
27
  const ADDON_SETTING_OPTION_NAME = 'bd_addon_settings';
28
 
29
  /**
30
- * Add settings menu if needed
31
  *
32
  * @static
 
33
  * @since 5.3
34
  */
35
  public static function add_menu() {
@@ -59,11 +60,14 @@ class BD_Settings_Page {
59
  }
60
 
61
  /**
62
- * Sanitize Settings
63
  *
64
  * @static
 
65
  * @since 5.3
 
66
  * @param array $input (optional) Input array
 
67
  * @return array Sanitized input
68
  */
69
  public static function sanitize_settings( $input = array() ) {
@@ -71,21 +75,24 @@ class BD_Settings_Page {
71
  }
72
 
73
  /**
74
- * Return Addon settings
75
  *
76
  * @since 5.3
77
  * @static
 
78
  * @return array Addon settings
79
  */
80
  public static function get_addon_settings() {
81
  $options = get_option( self::ADDON_SETTING_OPTION_NAME, array() );
 
82
  return apply_filters( 'bd_addon_settings', $options );
83
  }
84
 
85
  /**
86
- * Show the settings page
87
  *
88
  * @static
 
89
  * @since 5.3
90
  */
91
  public static function display_settings_page() {
1
  <?php
2
  /**
3
+ * Utility class for Settings page.
4
  *
5
  * @since 5.3
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Admin\Settings
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  class BD_Settings_Page {
 
14
  /**
15
+ * Slug for settings page.
16
  *
17
  * @since 5.3
18
  */
19
  const SETTINGS_PAGE_SLUG = 'bd-settings';
20
 
21
  /**
22
+ * Slugs for addon settings.
23
  *
24
  * @since 5.3
25
  */
27
  const ADDON_SETTING_OPTION_NAME = 'bd_addon_settings';
28
 
29
  /**
30
+ * Add settings menu if needed.
31
  *
32
  * @static
33
+ *
34
  * @since 5.3
35
  */
36
  public static function add_menu() {
60
  }
61
 
62
  /**
63
+ * Sanitize Settings.
64
  *
65
  * @static
66
+ *
67
  * @since 5.3
68
+ *
69
  * @param array $input (optional) Input array
70
+ *
71
  * @return array Sanitized input
72
  */
73
  public static function sanitize_settings( $input = array() ) {
75
  }
76
 
77
  /**
78
+ * Return Addon settings.
79
  *
80
  * @since 5.3
81
  * @static
82
+ *
83
  * @return array Addon settings
84
  */
85
  public static function get_addon_settings() {
86
  $options = get_option( self::ADDON_SETTING_OPTION_NAME, array() );
87
+
88
  return apply_filters( 'bd_addon_settings', $options );
89
  }
90
 
91
  /**
92
+ * Show the settings page.
93
  *
94
  * @static
95
+ *
96
  * @since 5.3
97
  */
98
  public static function display_settings_page() {
include/settings/class-bd-settings.php CHANGED
@@ -1,18 +1,18 @@
1
  <?php
2
  /**
3
- * Encapsulates the settings API for Bulk Delete Plugin
4
  *
5
  * @since 5.0
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Settings
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  class BD_Settings {
13
-
14
  /**
15
- * Register settings used by the plugin
16
  *
17
  * @since 5.0
18
  * @static
@@ -32,7 +32,7 @@ class BD_Settings {
32
  );
33
 
34
  /**
35
- * Runs just after registering license form fields
36
  *
37
  * This action is primarily for adding more fields to the license form
38
  *
@@ -42,16 +42,18 @@ class BD_Settings {
42
  }
43
 
44
  /**
45
- * Callback for sanitizing settings
46
  *
47
  * @since 5.0
48
  * @static
 
49
  * @param array $input
 
50
  * @return array
51
  */
52
  public static function check_license( $input ) {
53
  /**
54
- * Filter license form inputs
55
  *
56
  * @since 5.0
57
  */
@@ -61,4 +63,3 @@ class BD_Settings {
61
 
62
  // hooks
63
  add_action( 'admin_init', array( 'BD_Settings', 'create_settings' ), 100 );
64
- ?>
1
  <?php
2
  /**
3
+ * Encapsulates the settings API for Bulk Delete Plugin.
4
  *
5
  * @since 5.0
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Settings
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  class BD_Settings {
 
14
  /**
15
+ * Register settings used by the plugin.
16
  *
17
  * @since 5.0
18
  * @static
32
  );
33
 
34
  /**
35
+ * Runs just after registering license form fields.
36
  *
37
  * This action is primarily for adding more fields to the license form
38
  *
42
  }
43
 
44
  /**
45
+ * Callback for sanitizing settings.
46
  *
47
  * @since 5.0
48
  * @static
49
+ *
50
  * @param array $input
51
+ *
52
  * @return array
53
  */
54
  public static function check_license( $input ) {
55
  /**
56
+ * Filter license form inputs.
57
  *
58
  * @since 5.0
59
  */
63
 
64
  // hooks
65
  add_action( 'admin_init', array( 'BD_Settings', 'create_settings' ), 100 );
 
include/settings/setting-helpers.php CHANGED
@@ -1,21 +1,26 @@
1
  <?php
2
  /**
3
  * Helper functions for settings API.
4
- * Most of these functions are copied from Easy Digital Downloads
5
  *
6
  * @since 5.3
 
7
  * @author Sudar
 
8
  * @package BulkDelete\Settings
 
 
9
  */
10
 
11
-
12
  /**
13
- * Header Callback
14
  *
15
  * Renders the header.
16
  *
17
  * @since 5.3
18
- * @param array $args Arguments passed by the setting
 
 
19
  * @return void
20
  */
21
  function bd_header_callback( $args ) {
@@ -23,17 +28,19 @@ function bd_header_callback( $args ) {
23
  }
24
 
25
  /**
26
- * Text Callback
27
  *
28
  * Renders text fields.
29
  *
30
  * @since 5.3
31
- * @param array $args Arguments passed by the setting
 
 
32
  * @return void
33
  */
34
  function bd_text_callback( $args ) {
35
  $option_name = $args['option'];
36
- $bd_options = get_option( $option_name );
37
 
38
  if ( isset( $bd_options[ $args['id'] ] ) ) {
39
  $value = $bd_options[ $args['id'] ];
@@ -43,22 +50,23 @@ function bd_text_callback( $args ) {
43
 
44
  $size = ( isset( $args['size'] ) && ! is_null( $args['size'] ) ) ? $args['size'] : 'regular';
45
  $html = '<input type="text" class="' . $size . '-text" id="' . $option_name . '[' . $args['id'] . ']" name="' . $option_name . '[' . $args['id'] . ']" value="' . esc_attr( stripslashes( $value ) ) . '">';
46
- $html .= '<label for="' . $option_name . '[' . $args['id'] . ']"> ' . $args['desc'] . '</label>';
47
 
48
  echo $html;
49
  }
50
 
51
  /**
52
- * Rich Editor Callback
53
  *
54
  * Renders rich editor fields.
55
  *
56
  * @since 5.3
57
- * @param array $args Arguments passed by the setting
 
58
  */
59
  function bd_rich_editor_callback( $args ) {
60
  $option_name = $args['option'];
61
- $bd_options = get_option( $option_name );
62
 
63
  if ( isset( $bd_options[ $args['id'] ] ) ) {
64
  $value = $bd_options[ $args['id'] ];
@@ -74,4 +82,3 @@ function bd_rich_editor_callback( $args ) {
74
 
75
  echo $html;
76
  }
77
- ?>
1
  <?php
2
  /**
3
  * Helper functions for settings API.
4
+ * Most of these functions are copied from Easy Digital Downloads.
5
  *
6
  * @since 5.3
7
+ *
8
  * @author Sudar
9
+ *
10
  * @package BulkDelete\Settings
11
+ *
12
+ * @param mixed $args
13
  */
14
 
 
15
  /**
16
+ * Header Callback.
17
  *
18
  * Renders the header.
19
  *
20
  * @since 5.3
21
+ *
22
+ * @param array $args Arguments passed by the setting
23
+ *
24
  * @return void
25
  */
26
  function bd_header_callback( $args ) {
28
  }
29
 
30
  /**
31
+ * Text Callback.
32
  *
33
  * Renders text fields.
34
  *
35
  * @since 5.3
36
+ *
37
+ * @param array $args Arguments passed by the setting
38
+ *
39
  * @return void
40
  */
41
  function bd_text_callback( $args ) {
42
  $option_name = $args['option'];
43
+ $bd_options = get_option( $option_name );
44
 
45
  if ( isset( $bd_options[ $args['id'] ] ) ) {
46
  $value = $bd_options[ $args['id'] ];
50
 
51
  $size = ( isset( $args['size'] ) && ! is_null( $args['size'] ) ) ? $args['size'] : 'regular';
52
  $html = '<input type="text" class="' . $size . '-text" id="' . $option_name . '[' . $args['id'] . ']" name="' . $option_name . '[' . $args['id'] . ']" value="' . esc_attr( stripslashes( $value ) ) . '">';
53
+ $html .= '<label for="' . $option_name . '[' . $args['id'] . ']"> ' . $args['desc'] . '</label>';
54
 
55
  echo $html;
56
  }
57
 
58
  /**
59
+ * Rich Editor Callback.
60
  *
61
  * Renders rich editor fields.
62
  *
63
  * @since 5.3
64
+ *
65
+ * @param array $args Arguments passed by the setting
66
  */
67
  function bd_rich_editor_callback( $args ) {
68
  $option_name = $args['option'];
69
+ $bd_options = get_option( $option_name );
70
 
71
  if ( isset( $bd_options[ $args['id'] ] ) ) {
72
  $value = $bd_options[ $args['id'] ];
82
 
83
  echo $html;
84
  }
 
include/system-info/class-bd-system-info-page.php CHANGED
@@ -6,10 +6,11 @@
6
  *
7
  * @since 5.5.4
8
  * @note Based on the code from Easy Digital Downloads plugin
 
9
  * @author Sudar
 
10
  * @package BulkDelete\Admin
11
  */
12
-
13
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
14
 
15
  /**
@@ -18,11 +19,11 @@ defined( 'ABSPATH' ) || exit; // Exit if accessed directly
18
  * @since 5.5.4
19
  */
20
  class BD_System_Info_page extends BD_Base_Page {
21
-
22
  /**
23
  * Make this class a "hybrid Singleton".
24
  *
25
  * @static
 
26
  * @since 5.5.4
27
  */
28
  public static function factory() {
@@ -41,9 +42,9 @@ class BD_System_Info_page extends BD_Base_Page {
41
  * @since 5.5.4
42
  */
43
  protected function initialize() {
44
- $this->page_slug = 'bulk-delete-info';
45
  $this->menu_action = 'bd_after_all_menus';
46
- $this->actions = array( 'download_sysinfo' );
47
 
48
  $this->label = array(
49
  'page_title' => __( 'Bulk Delete - System Info', 'bulk-delete' ),
@@ -91,6 +92,7 @@ class BD_System_Info_page extends BD_Base_Page {
91
  * Shows the system info panel which contains version data and debug info.
92
  *
93
  * @since 5.5.4
 
94
  * @global $wpdb Global object $wpdb Used to query the database using the WordPress Database API
95
  */
96
  protected function render_body() {
@@ -210,6 +212,7 @@ NETWORK ACTIVE PLUGINS:
210
  * Generates the System Info Download File.
211
  *
212
  * @since 5.0
 
213
  * @return void
214
  */
215
  public function generate_sysinfo_download() {
6
  *
7
  * @since 5.5.4
8
  * @note Based on the code from Easy Digital Downloads plugin
9
+ *
10
  * @author Sudar
11
+ *
12
  * @package BulkDelete\Admin
13
  */
 
14
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
15
 
16
  /**
19
  * @since 5.5.4
20
  */
21
  class BD_System_Info_page extends BD_Base_Page {
 
22
  /**
23
  * Make this class a "hybrid Singleton".
24
  *
25
  * @static
26
+ *
27
  * @since 5.5.4
28
  */
29
  public static function factory() {
42
  * @since 5.5.4
43
  */
44
  protected function initialize() {
45
+ $this->page_slug = 'bulk-delete-info';
46
  $this->menu_action = 'bd_after_all_menus';
47
+ $this->actions = array( 'download_sysinfo' );
48
 
49
  $this->label = array(
50
  'page_title' => __( 'Bulk Delete - System Info', 'bulk-delete' ),
92
  * Shows the system info panel which contains version data and debug info.
93
  *
94
  * @since 5.5.4
95
+ *
96
  * @global $wpdb Global object $wpdb Used to query the database using the WordPress Database API
97
  */
98
  protected function render_body() {
212
  * Generates the System Info Download File.
213
  *
214
  * @since 5.0
215
+ *
216
  * @return void
217
  */
218
  public function generate_sysinfo_download() {
include/ui/admin-ui.php CHANGED
@@ -1,20 +1,23 @@
1
  <?php
2
  /**
3
- * Customize admin UI for Bulk Delete plugin
4
  *
5
  * @since 5.0
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Admin
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
13
- * Add rating links to the admin dashboard
14
  *
15
  * @since 5.0
16
- * @param string $footer_text The existing footer text
17
- * @return string
 
 
18
  */
19
  function bd_add_rating_link( $footer_text ) {
20
  $rating_text = sprintf( __( 'Thank you for using <a href = "%1$s">Bulk Delete</a> plugin! Kindly <a href = "%2$s">rate us</a> at <a href = "%2$s">WordPress.org</a>', 'bulk-delete' ),
@@ -23,11 +26,12 @@ function bd_add_rating_link( $footer_text ) {
23
  );
24
 
25
  $rating_text = apply_filters( 'bd_rating_link', $rating_text );
 
26
  return str_replace( '</span>', '', $footer_text ) . ' | ' . $rating_text . '</span>';
27
  }
28
 
29
  /**
30
- * Modify admin footer in Bulk Delete plugin pages
31
  *
32
  * @since 5.0
33
  */
@@ -37,11 +41,12 @@ function bd_modify_admin_footer() {
37
 
38
  /**
39
  * Adds setting links in plugin listing page.
40
- * Based on http://striderweb.com/nerdaphernalia/2008/06/wp-use-action-links/
41
  *
42
- * @param array $links List of current links
43
- * @param string $file Plugin filename
44
- * @return array $links Modified list of links
 
45
  */
46
  function bd_add_plugin_action_links( $links, $file ) {
47
  $this_plugin = plugin_basename( Bulk_Delete::$PLUGIN_FILE );
@@ -56,18 +61,19 @@ function bd_add_plugin_action_links( $links, $file ) {
56
 
57
  /**
58
  * Add additional links in the Plugin listing page.
59
- * Based on http://zourbuth.com/archives/751/creating-additional-wordpress-plugin-links-row-meta/
 
 
 
60
  *
61
- * @param array $links List of current links
62
- * @param string $file Plugin filename
63
- * @return array $links Modified list of links
64
  */
65
  function bd_add_links_in_plugin_listing( $links, $file ) {
66
  $plugin = plugin_basename( Bulk_Delete::$PLUGIN_FILE );
67
 
68
  if ( $file == $plugin ) { // only for this plugin
69
  return array_merge( $links, array(
70
- '<a href="http://bulkwp.com/addons?utm_source=wpadmin&utm_campaign=BulkDelete&utm_medium=plugin-page" target="_blank">' . __( 'Buy Addons', 'bulk-delete' ) . '</a>'
71
  ) );
72
  }
73
 
@@ -84,4 +90,3 @@ add_action( 'bd_admin_footer_info_page' , 'bd_modify_admin_footer' );
84
  // Change plugin listing page
85
  add_filter( 'plugin_action_links', 'bd_add_plugin_action_links', 10, 2 );
86
  add_filter( 'plugin_row_meta', 'bd_add_links_in_plugin_listing', 10, 2 );
87
- ?>
1
  <?php
2
  /**
3
+ * Customize admin UI for Bulk Delete plugin.
4
  *
5
  * @since 5.0
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Admin
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
14
+ * Add rating links to the admin dashboard.
15
  *
16
  * @since 5.0
17
+ *
18
+ * @param string $footer_text The existing footer text
19
+ *
20
+ * @return string
21
  */
22
  function bd_add_rating_link( $footer_text ) {
23
  $rating_text = sprintf( __( 'Thank you for using <a href = "%1$s">Bulk Delete</a> plugin! Kindly <a href = "%2$s">rate us</a> at <a href = "%2$s">WordPress.org</a>', 'bulk-delete' ),
26
  );
27
 
28
  $rating_text = apply_filters( 'bd_rating_link', $rating_text );
29
+
30
  return str_replace( '</span>', '', $footer_text ) . ' | ' . $rating_text . '</span>';
31
  }
32
 
33
  /**
34
+ * Modify admin footer in Bulk Delete plugin pages.
35
  *
36
  * @since 5.0
37
  */
41
 
42
  /**
43
  * Adds setting links in plugin listing page.
44
+ * Based on http://striderweb.com/nerdaphernalia/2008/06/wp-use-action-links/.
45
  *
46
+ * @param array $links List of current links
47
+ * @param string $file Plugin filename
48
+ *
49
+ * @return array $links Modified list of links
50
  */
51
  function bd_add_plugin_action_links( $links, $file ) {
52
  $this_plugin = plugin_basename( Bulk_Delete::$PLUGIN_FILE );
61
 
62
  /**
63
  * Add additional links in the Plugin listing page.
64
+ * Based on http://zourbuth.com/archives/751/creating-additional-wordpress-plugin-links-row-meta/.
65
+ *
66
+ * @param array $links List of current links
67
+ * @param string $file Plugin filename
68
  *
69
+ * @return array $links Modified list of links
 
 
70
  */
71
  function bd_add_links_in_plugin_listing( $links, $file ) {
72
  $plugin = plugin_basename( Bulk_Delete::$PLUGIN_FILE );
73
 
74
  if ( $file == $plugin ) { // only for this plugin
75
  return array_merge( $links, array(
76
+ '<a href="http://bulkwp.com/addons?utm_source=wpadmin&utm_campaign=BulkDelete&utm_medium=plugin-page" target="_blank">' . __( 'Buy Addons', 'bulk-delete' ) . '</a>',
77
  ) );
78
  }
79
 
90
  // Change plugin listing page
91
  add_filter( 'plugin_action_links', 'bd_add_plugin_action_links', 10, 2 );
92
  add_filter( 'plugin_row_meta', 'bd_add_links_in_plugin_listing', 10, 2 );
 
include/ui/class-bulk-delete-help-screen.php CHANGED
@@ -1,25 +1,25 @@
1
  <?php
2
  /**
3
- * Bulk Delete Help Screen
4
  *
5
  * Displays the help tab on top of Bulk Delete Admin pages
6
  *
7
  * @since 5.1
 
8
  * @author Sudar
 
9
  * @package BulkDelete\Help
10
  */
11
-
12
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
13
 
14
  class Bulk_Delete_Help_Screen {
15
-
16
  /**
17
- * Add contextual help to admin screens
18
  *
19
  * @since 5.1
20
  * @static
21
  *
22
- * @param string $screen Screen name
23
  */
24
  public static function add_contextual_help( $screen ) {
25
  $help_tabs = self::get_help_tabs( $screen );
@@ -39,17 +39,18 @@ class Bulk_Delete_Help_Screen {
39
  }
40
 
41
  /**
42
- * Get the list of help tabs for a given screen
43
  *
44
  * @since 5.1
45
  * @static
46
  * @access private
47
  *
48
- * @param string $screen Screen name
49
- * @return array $help_tabs List of tabs
 
50
  */
51
  private static function get_help_tabs( $screen ) {
52
- $bd = BULK_DELETE();
53
  $help_tabs = array();
54
 
55
  switch ( $screen ) {
@@ -88,7 +89,7 @@ class Bulk_Delete_Help_Screen {
88
  $help_tabs['about_plugin_tab'] = $about_plugin_tab;
89
 
90
  /**
91
- * Filters help tab content for admin screens
92
  *
93
  * @since 5.1
94
  */
@@ -96,7 +97,7 @@ class Bulk_Delete_Help_Screen {
96
  }
97
 
98
  /**
99
- * print the about plugin tab content
100
  *
101
  * @since 5.1
102
  * @static
@@ -109,4 +110,3 @@ class Bulk_Delete_Help_Screen {
109
 
110
  // hooks
111
  add_action( 'bd_add_contextual_help', array( 'Bulk_Delete_Help_Screen', 'add_contextual_help' ) );
112
- ?>
1
  <?php
2
  /**
3
+ * Bulk Delete Help Screen.
4
  *
5
  * Displays the help tab on top of Bulk Delete Admin pages
6
  *
7
  * @since 5.1
8
+ *
9
  * @author Sudar
10
+ *
11
  * @package BulkDelete\Help
12
  */
 
13
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
14
 
15
  class Bulk_Delete_Help_Screen {
 
16
  /**
17
+ * Add contextual help to admin screens.
18
  *
19
  * @since 5.1
20
  * @static
21
  *
22
+ * @param string $screen Screen name
23
  */
24
  public static function add_contextual_help( $screen ) {
25
  $help_tabs = self::get_help_tabs( $screen );
39
  }
40
 
41
  /**
42
+ * Get the list of help tabs for a given screen.
43
  *
44
  * @since 5.1
45
  * @static
46
  * @access private
47
  *
48
+ * @param string $screen Screen name
49
+ *
50
+ * @return array $help_tabs List of tabs
51
  */
52
  private static function get_help_tabs( $screen ) {
53
+ $bd = BULK_DELETE();
54
  $help_tabs = array();
55
 
56
  switch ( $screen ) {
89
  $help_tabs['about_plugin_tab'] = $about_plugin_tab;
90
 
91
  /**
92
+ * Filters help tab content for admin screens.
93
  *
94
  * @since 5.1
95
  */
97
  }
98
 
99
  /**
100
+ * print the about plugin tab content.
101
  *
102
  * @since 5.1
103
  * @static
110
 
111
  // hooks
112
  add_action( 'bd_add_contextual_help', array( 'Bulk_Delete_Help_Screen', 'add_contextual_help' ) );
 
include/ui/form.php CHANGED
@@ -3,10 +3,11 @@
3
  * Utility functions for displaying form.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Ui
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -28,6 +29,7 @@ function bd_render_filtering_table_header() {
28
  * Render "restrict by created date" dropdown.
29
  *
30
  * @since 5.5
 
31
  * @param string $slug The slug to be used in field names.
32
  * @param string $item (optional) Item for which form is displayed. Default is 'posts'.
33
  */
@@ -53,6 +55,7 @@ function bd_render_restrict_settings( $slug, $item = 'posts' ) {
53
  * Render "force delete" setting fields.
54
  *
55
  * @since 5.5
 
56
  * @param string $slug The slug to be used in field names.
57
  */
58
  function bd_render_delete_settings( $slug ) {
@@ -70,6 +73,7 @@ function bd_render_delete_settings( $slug ) {
70
  * Render the "private post" setting fields.
71
  *
72
  * @since 5.5
 
73
  * @param string $slug The slug to be used in field names.
74
  */
75
  function bd_render_private_post_settings( $slug ) {
@@ -87,6 +91,7 @@ function bd_render_private_post_settings( $slug ) {
87
  * Render the "limit" setting fields.
88
  *
89
  * @since 5.5
 
90
  * @param string $slug The slug to be used in field names.
91
  * @param string $item (Optional) Item type. Possible values are 'posts', 'pages', 'users'
92
  */
@@ -109,7 +114,8 @@ function bd_render_limit_settings( $slug, $item = 'posts' ) {
109
  * Render cron setting fields.
110
  *
111
  * @since 5.5
112
- * @param string $slug The slug to be used in field names.
 
113
  * @param string $addon_url Url for the pro addon.
114
  */
115
  function bd_render_cron_settings( $slug, $addon_url ) {
@@ -145,6 +151,7 @@ function bd_render_cron_settings( $slug, $addon_url ) {
145
  * Render the submit button.
146
  *
147
  * @since 5.5
 
148
  * @param string $action The action attribute of the submit button.
149
  */
150
  function bd_render_submit_button( $action ) {
@@ -159,12 +166,11 @@ function bd_render_submit_button( $action ) {
159
  * Render the post type dropdown.
160
  *
161
  * @since 5.5
 
162
  * @param string $slug The slug to be used in field names.
163
  */
164
  function bd_render_post_type_dropdown( $slug ) {
165
- $types = get_post_types( array( '_builtin' => false ), 'names' );
166
- array_unshift( $types, 'page' );
167
- array_unshift( $types, 'post' );
168
  ?>
169
  <tr>
170
  <td scope="row" >
@@ -178,3 +184,114 @@ function bd_render_post_type_dropdown( $slug ) {
178
  <?php
179
  }
180
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  * Utility functions for displaying form.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Ui
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
29
  * Render "restrict by created date" dropdown.
30
  *
31
  * @since 5.5
32
+ *
33
  * @param string $slug The slug to be used in field names.
34
  * @param string $item (optional) Item for which form is displayed. Default is 'posts'.
35
  */
55
  * Render "force delete" setting fields.
56
  *
57
  * @since 5.5
58
+ *
59
  * @param string $slug The slug to be used in field names.
60
  */
61
  function bd_render_delete_settings( $slug ) {
73
  * Render the "private post" setting fields.
74
  *
75
  * @since 5.5
76
+ *
77
  * @param string $slug The slug to be used in field names.
78
  */
79
  function bd_render_private_post_settings( $slug ) {
91
  * Render the "limit" setting fields.
92
  *
93
  * @since 5.5
94
+ *
95
  * @param string $slug The slug to be used in field names.
96
  * @param string $item (Optional) Item type. Possible values are 'posts', 'pages', 'users'
97
  */
114
  * Render cron setting fields.
115
  *
116
  * @since 5.5
117
+ *
118
+ * @param string $slug The slug to be used in field names.
119
  * @param string $addon_url Url for the pro addon.
120
  */
121
  function bd_render_cron_settings( $slug, $addon_url ) {
151
  * Render the submit button.
152
  *
153
  * @since 5.5
154
+ *
155
  * @param string $action The action attribute of the submit button.
156
  */
157
  function bd_render_submit_button( $action ) {
166
  * Render the post type dropdown.
167
  *
168
  * @since 5.5
169
+ *
170
  * @param string $slug The slug to be used in field names.
171
  */
172
  function bd_render_post_type_dropdown( $slug ) {
173
+ $types = bd_get_post_types();
 
 
174
  ?>
175
  <tr>
176
  <td scope="row" >
184
  <?php
185
  }
186
 
187
+ /**
188
+ * Get the list of post type names that will be used in filters.
189
+ *
190
+ * @since 5.6.0
191
+ *
192
+ * @return array List of post types.
193
+ */
194
+ function bd_get_post_types() {
195
+ $post_types = get_post_types( array( '_builtin' => false ), 'names' );
196
+
197
+ array_unshift( $post_types, 'page' );
198
+ array_unshift( $post_types, 'post' );
199
+
200
+ return $post_types;
201
+ }
202
+
203
+ /**
204
+ * Get the list of post type objects that will be used in filters.
205
+ *
206
+ * @since 5.6.0
207
+ *
208
+ * @return \WP_Post_Type[] List of post type objects.
209
+ */
210
+ function bd_get_post_type_objects() {
211
+ $types = get_post_types( array( '_builtin' => false ), 'objects' );
212
+
213
+ $types['post'] = get_post_type_object( 'post' );
214
+ $types['page'] = get_post_type_object( 'page' );
215
+
216
+ return $types;
217
+ }
218
+
219
+ /**
220
+ * Render the post status filter.
221
+ *
222
+ * @since 5.6.0
223
+ *
224
+ * @param string $slug The slug to be used in field names.
225
+ * @param string $selected Default selected status.
226
+ */
227
+ function bd_render_post_status_filter( $slug, $selected = 'publish' ) {
228
+ $post_statuses = bd_get_post_statuses();
229
+
230
+ foreach ( $post_statuses as $key => $value ) {
231
+ ?>
232
+ <tr>
233
+ <td>
234
+ <label>
235
+ <input name="smbd_<?php echo esc_attr( $slug ); ?>_post_status[]" type="checkbox"
236
+ value="<?php echo esc_attr( $key ); ?>" <?php checked( $key, $selected ); ?>>
237
+
238
+ <?php echo __( 'All', 'bulk-delete' ), ' ', esc_html( $value->label ), ' ', __( 'Posts', 'bulk-delete' ); ?>
239
+ </label>
240
+ </td>
241
+ </tr>
242
+ <?php
243
+ }
244
+ }
245
+
246
+ /**
247
+ * Get the list of post statuses.
248
+ *
249
+ * This includes all custom post status, but excludes built-in private posts.
250
+ *
251
+ * @since 5.6.0
252
+ *
253
+ * @return array List of post status objects.
254
+ */
255
+ function bd_get_post_statuses() {
256
+ $post_statuses = get_post_stati( array(), 'object' );
257
+
258
+ /**
259
+ * List of post statuses that should be excluded from post status filter.
260
+ *
261
+ * @since 5.6.0
262
+ *
263
+ * @param array $post_statuses List of post statuses.
264
+ */
265
+ $exclude_post_statuses = apply_filters( 'bd_exclude_post_statuses', array( 'inherit', 'trash', 'auto-draft' ) );
266
+
267
+ foreach ( $exclude_post_statuses as $key ) {
268
+ unset( $post_statuses[ $key ] );
269
+ }
270
+
271
+ /**
272
+ * List of post statuses that are displayed in the post status filter.
273
+ *
274
+ * @since 5.6.0
275
+ *
276
+ * @param array $post_statuses List of post statuses.
277
+ */
278
+ return apply_filters( 'bd_post_statuses', $post_statuses );
279
+ }
280
+
281
+ /**
282
+ * Generate help tooltip and append it to existing markup.
283
+ *
284
+ * @param string $markup Existing markup.
285
+ * @param string $content Tooltip content.
286
+ *
287
+ * @return string Markup with tooltip markup appended to it.
288
+ */
289
+ function bd_generate_help_tooltip( $markup, $content ) {
290
+ if ( empty( $content ) ) {
291
+ return $markup;
292
+ }
293
+
294
+ $tooltip = '<span alt="f223" class="bd-help dashicons dashicons-editor-help" title="' . $content . '"></span>';
295
+
296
+ return $markup . $tooltip;
297
+ }
include/users/class-bd-users-page.php CHANGED
@@ -4,10 +4,11 @@
4
  * Shows the list of modules that allows you to delete users.
5
  *
6
  * @since 5.5
 
7
  * @author Sudar
 
8
  * @package BulkDelete\Users
9
  */
10
-
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
@@ -20,6 +21,7 @@ class BD_Users_Page extends BD_Page {
20
  * Make this class a "hybrid Singleton".
21
  *
22
  * @static
 
23
  * @since 5.5
24
  */
25
  public static function factory() {
@@ -56,11 +58,12 @@ class BD_Users_Page extends BD_Page {
56
 
57
  /**
58
  * Adds setting links in plugin listing page.
59
- * Based on http://striderweb.com/nerdaphernalia/2008/06/wp-use-action-links/
 
 
 
60
  *
61
- * @param array $links List of current links
62
- * @param string $file Plugin filename
63
- * @return array $links Modified list of links
64
  */
65
  public function add_plugin_action_links( $links, $file ) {
66
  $this_plugin = plugin_basename( Bulk_Delete::$PLUGIN_FILE );
@@ -77,6 +80,8 @@ class BD_Users_Page extends BD_Page {
77
  * Add Help tabs.
78
  *
79
  * @since 5.5
 
 
80
  */
81
  protected function add_help_tab( $help_tabs ) {
82
  $overview_tab = array(
@@ -92,4 +97,3 @@ class BD_Users_Page extends BD_Page {
92
  }
93
 
94
  BD_Users_Page::factory();
95
- ?>
4
  * Shows the list of modules that allows you to delete users.
5
  *
6
  * @since 5.5
7
+ *
8
  * @author Sudar
9
+ *
10
  * @package BulkDelete\Users
11
  */
 
12
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
13
 
14
  /**
21
  * Make this class a "hybrid Singleton".
22
  *
23
  * @static
24
+ *
25
  * @since 5.5
26
  */
27
  public static function factory() {
58
 
59
  /**
60
  * Adds setting links in plugin listing page.
61
+ * Based on http://striderweb.com/nerdaphernalia/2008/06/wp-use-action-links/.
62
+ *
63
+ * @param array $links List of current links
64
+ * @param string $file Plugin filename
65
  *
66
+ * @return array $links Modified list of links
 
 
67
  */
68
  public function add_plugin_action_links( $links, $file ) {
69
  $this_plugin = plugin_basename( Bulk_Delete::$PLUGIN_FILE );
80
  * Add Help tabs.
81
  *
82
  * @since 5.5
83
+ *
84
+ * @param mixed $help_tabs
85
  */
86
  protected function add_help_tab( $help_tabs ) {
87
  $overview_tab = array(
97
  }
98
 
99
  BD_Users_Page::factory();
 
include/users/modules/class-bulk-delete-users-by-user-meta.php CHANGED
@@ -3,10 +3,11 @@
3
  * Bulk Delete Users by User Meta.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Users\Modules
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -19,6 +20,7 @@ class Bulk_Delete_Users_By_User_Meta extends BD_User_Meta_Box_Module {
19
  * Make this class a "hybrid Singleton".
20
  *
21
  * @static
 
22
  * @since 5.5
23
  */
24
  public static function factory() {
@@ -44,7 +46,7 @@ class Bulk_Delete_Users_By_User_Meta extends BD_User_Meta_Box_Module {
44
  $this->delete_action = 'delete_users_by_meta';
45
  $this->cron_hook = 'do-bulk-delete-users-by-meta';
46
  $this->scheduler_url = 'http://bulkwp.com/addons/scheduler-for-deleting-users-by-meta/?utm_source=wpadmin&utm_campaign=BulkDelete&utm_medium=buynow&utm_content=bd-u-ma';
47
- $this->messages = array(
48
  'box_label' => __( 'By User Meta', 'bulk-delete' ),
49
  'scheduled' => __( 'Users from with the selected user meta are scheduled for deletion.', 'bulk-delete' ),
50
  'deleted_single' => __( 'Deleted %d user with the selected user meta', 'bulk-delete' ),
@@ -121,8 +123,10 @@ class Bulk_Delete_Users_By_User_Meta extends BD_User_Meta_Box_Module {
121
  * Delete users by user meta.
122
  *
123
  * @since 5.5
 
124
  * @param array $delete_options Delete Options
125
- * @return int Number of users deleted
 
126
  */
127
  public function delete( $delete_options ) {
128
  if ( ! function_exists( 'wp_delete_user' ) ) {
@@ -150,18 +154,20 @@ class Bulk_Delete_Users_By_User_Meta extends BD_User_Meta_Box_Module {
150
  * Filter JS Array and add validation hooks.
151
  *
152
  * @since 5.5
153
- * @param array $js_array JavaScript Array
154
- * @return array Modified JavaScript Array
 
 
155
  */
156
  public function filter_js_array( $js_array ) {
157
- $js_array['dt_iterators'][] = '_' . $this->field_slug;
158
  $js_array['validators'][ $this->delete_action ] = 'noValidation';
159
 
160
  $js_array['pre_action_msg'][ $this->delete_action ] = 'deleteUsersByMetaWarning';
161
- $js_array['msg']['deleteUsersByMetaWarning'] = __( 'Are you sure you want to delete all the users from the selected user meta?', 'bulk-delete' );
162
 
163
  $js_array['error_msg'][ $this->delete_action ] = 'enterUserMetaValue';
164
- $js_array['msg']['enterUserMetaValue'] = __( 'Please enter the value for the user meta field based on which you want to delete users', 'bulk-delete' );
165
 
166
  return $js_array;
167
  }
@@ -170,6 +176,7 @@ class Bulk_Delete_Users_By_User_Meta extends BD_User_Meta_Box_Module {
170
  * Get unique user meta keys.
171
  *
172
  * @since 5.5
 
173
  * @return array List of unique meta keys.
174
  */
175
  private function get_unique_meta_keys() {
3
  * Bulk Delete Users by User Meta.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Users\Modules
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
20
  * Make this class a "hybrid Singleton".
21
  *
22
  * @static
23
+ *
24
  * @since 5.5
25
  */
26
  public static function factory() {
46
  $this->delete_action = 'delete_users_by_meta';
47
  $this->cron_hook = 'do-bulk-delete-users-by-meta';
48
  $this->scheduler_url = 'http://bulkwp.com/addons/scheduler-for-deleting-users-by-meta/?utm_source=wpadmin&utm_campaign=BulkDelete&utm_medium=buynow&utm_content=bd-u-ma';
49
+ $this->messages = array(
50
  'box_label' => __( 'By User Meta', 'bulk-delete' ),
51
  'scheduled' => __( 'Users from with the selected user meta are scheduled for deletion.', 'bulk-delete' ),
52
  'deleted_single' => __( 'Deleted %d user with the selected user meta', 'bulk-delete' ),
123
  * Delete users by user meta.
124
  *
125
  * @since 5.5
126
+ *
127
  * @param array $delete_options Delete Options
128
+ *
129
+ * @return int Number of users deleted
130
  */
131
  public function delete( $delete_options ) {
132
  if ( ! function_exists( 'wp_delete_user' ) ) {
154
  * Filter JS Array and add validation hooks.
155
  *
156
  * @since 5.5
157
+ *
158
+ * @param array $js_array JavaScript Array
159
+ *
160
+ * @return array Modified JavaScript Array
161
  */
162
  public function filter_js_array( $js_array ) {
163
+ $js_array['dt_iterators'][] = '_' . $this->field_slug;
164
  $js_array['validators'][ $this->delete_action ] = 'noValidation';
165
 
166
  $js_array['pre_action_msg'][ $this->delete_action ] = 'deleteUsersByMetaWarning';
167
+ $js_array['msg']['deleteUsersByMetaWarning'] = __( 'Are you sure you want to delete all the users from the selected user meta?', 'bulk-delete' );
168
 
169
  $js_array['error_msg'][ $this->delete_action ] = 'enterUserMetaValue';
170
+ $js_array['msg']['enterUserMetaValue'] = __( 'Please enter the value for the user meta field based on which you want to delete users', 'bulk-delete' );
171
 
172
  return $js_array;
173
  }
176
  * Get unique user meta keys.
177
  *
178
  * @since 5.5
179
+ *
180
  * @return array List of unique meta keys.
181
  */
182
  private function get_unique_meta_keys() {
include/users/modules/class-bulk-delete-users-by-user-role.php CHANGED
@@ -1,12 +1,13 @@
1
  <?php
2
  /**
3
- * Bulk Delete Users by User Role
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Users\Modules
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -19,6 +20,7 @@ class Bulk_Delete_Users_By_User_Role extends BD_User_Meta_Box_Module {
19
  * Make this class a "hybrid Singleton".
20
  *
21
  * @static
 
22
  * @since 5.5
23
  */
24
  public static function factory() {
@@ -44,7 +46,7 @@ class Bulk_Delete_Users_By_User_Role extends BD_User_Meta_Box_Module {
44
  $this->delete_action = 'delete_users_by_role';
45
  $this->cron_hook = 'do-bulk-delete-users-by-role';
46
  $this->scheduler_url = 'http://bulkwp.com/addons/scheduler-for-deleting-users-by-role/?utm_source=wpadmin&utm_campaign=BulkDelete&utm_medium=buynow&utm_content=bd-u-ur';
47
- $this->messages = array(
48
  'box_label' => __( 'By User Role', 'bulk-delete' ),
49
  'scheduled' => __( 'Users from the selected userrole are scheduled for deletion.', 'bulk-delete' ),
50
  'deleted_single' => __( 'Deleted %d user from the selected roles', 'bulk-delete' ),
@@ -101,7 +103,9 @@ class Bulk_Delete_Users_By_User_Role extends BD_User_Meta_Box_Module {
101
  */
102
  public function process() {
103
  $delete_options = array();
104
- $delete_options['selected_roles'] = array_get( $_POST, 'smbd_u_roles' );
 
 
105
 
106
  $this->process_user_delete( $delete_options );
107
  }
@@ -110,8 +114,10 @@ class Bulk_Delete_Users_By_User_Role extends BD_User_Meta_Box_Module {
110
  * Delete users by user role.
111
  *
112
  * @since 5.5
 
113
  * @param array $delete_options Delete Options
114
- * @return int Number of users deleted
 
115
  */
116
  public function delete( $delete_options ) {
117
  if ( ! function_exists( 'wp_delete_user' ) ) {
@@ -133,20 +139,22 @@ class Bulk_Delete_Users_By_User_Role extends BD_User_Meta_Box_Module {
133
  }
134
 
135
  /**
136
- * Filter JS Array and add validation hooks
137
  *
138
  * @since 5.5
139
- * @param array $js_array JavaScript Array
140
- * @return array Modified JavaScript Array
 
 
141
  */
142
  public function filter_js_array( $js_array ) {
143
  $js_array['dt_iterators'][] = '_' . $this->field_slug;
144
 
145
  $js_array['pre_action_msg'][ $this->delete_action ] = 'deleteUsersWarning';
146
- $js_array['msg']['deleteUsersWarning'] = __( 'Are you sure you want to delete all the users from the selected user role?', 'bulk-delete' );
147
 
148
  $js_array['error_msg'][ $this->delete_action ] = 'selectOneUserRole';
149
- $js_array['msg']['selectOneUserRole'] = __( 'Select at least one user role from which users should be deleted', 'bulk-delete' );
150
 
151
  return $js_array;
152
  }
1
  <?php
2
  /**
3
+ * Bulk Delete Users by User Role.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Users\Modules
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
20
  * Make this class a "hybrid Singleton".
21
  *
22
  * @static
23
+ *
24
  * @since 5.5
25
  */
26
  public static function factory() {
46
  $this->delete_action = 'delete_users_by_role';
47
  $this->cron_hook = 'do-bulk-delete-users-by-role';
48
  $this->scheduler_url = 'http://bulkwp.com/addons/scheduler-for-deleting-users-by-role/?utm_source=wpadmin&utm_campaign=BulkDelete&utm_medium=buynow&utm_content=bd-u-ur';
49
+ $this->messages = array(
50
  'box_label' => __( 'By User Role', 'bulk-delete' ),
51
  'scheduled' => __( 'Users from the selected userrole are scheduled for deletion.', 'bulk-delete' ),
52
  'deleted_single' => __( 'Deleted %d user from the selected roles', 'bulk-delete' ),
103
  */
104
  public function process() {
105
  $delete_options = array();
106
+
107
+ // Nonce verification is handled in `request_handler()`.
108
+ $delete_options['selected_roles'] = array_get( $_POST, 'smbd_u_roles' ); // WPCS: XSS ok.
109
 
110
  $this->process_user_delete( $delete_options );
111
  }
114
  * Delete users by user role.
115
  *
116
  * @since 5.5
117
+ *
118
  * @param array $delete_options Delete Options
119
+ *
120
+ * @return int Number of users deleted
121
  */
122
  public function delete( $delete_options ) {
123
  if ( ! function_exists( 'wp_delete_user' ) ) {
139
  }
140
 
141
  /**
142
+ * Filter JS Array and add validation hooks.
143
  *
144
  * @since 5.5
145
+ *
146
+ * @param array $js_array JavaScript Array
147
+ *
148
+ * @return array Modified JavaScript Array
149
  */
150
  public function filter_js_array( $js_array ) {
151
  $js_array['dt_iterators'][] = '_' . $this->field_slug;
152
 
153
  $js_array['pre_action_msg'][ $this->delete_action ] = 'deleteUsersWarning';
154
+ $js_array['msg']['deleteUsersWarning'] = __( 'Are you sure you want to delete all the users from the selected user role?', 'bulk-delete' );
155
 
156
  $js_array['error_msg'][ $this->delete_action ] = 'selectOneUserRole';
157
+ $js_array['msg']['selectOneUserRole'] = __( 'Select at least one user role from which users should be deleted', 'bulk-delete' );
158
 
159
  return $js_array;
160
  }
include/util/class-bd-util.php CHANGED
@@ -3,9 +3,9 @@
3
  * Utility classes and functions.
4
  *
5
  * @author Sudar
 
6
  * @package BulkDelete\Util
7
  */
8
-
9
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
10
 
11
  /**
@@ -20,95 +20,110 @@ class BD_Util {
20
  const VISIBLE_USER_BOXES = 'metaboxhidden_bulk-delete_page_bulk-delete-users';
21
 
22
  /**
23
- * Check whether the meta box in posts page is hidden or not
24
  *
25
  * @static
26
  * @access public
27
- * @param string $box The name of the box
28
- * @return bool True if the box is hidden, False otherwise
 
 
29
  */
30
  public static function is_posts_box_hidden( $box ) {
31
  $hidden_boxes = self::get_posts_hidden_boxes();
 
32
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
33
  }
34
 
35
  /**
36
- * Get the list of hidden boxes in posts page
37
  *
38
  * @static
39
  * @access public
 
40
  * @return array The list of hidden meta boxes
41
  */
42
  public static function get_posts_hidden_boxes() {
43
  $current_user = wp_get_current_user();
 
44
  return get_user_meta( $current_user->ID, self::VISIBLE_POST_BOXES, true );
45
  }
46
 
47
  /**
48
- * Check whether the meta box in pages page is hidden or not
49
  *
50
  * @since 5.0
51
  * @static
52
  * @access public
53
- * @param string $box The name of the box to check
54
- * @return bool True if the box is hidden, False otherwise
 
 
55
  */
56
  public static function is_pages_box_hidden( $box ) {
57
  $hidden_boxes = self::get_pages_hidden_boxes();
 
58
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
59
  }
60
 
61
  /**
62
- * Get the list of hidden boxes in posts page
63
  *
64
  * @since 5.0
65
  * @static
66
  * @access public
 
67
  * @return the array of hidden meta boxes
68
  */
69
  public static function get_pages_hidden_boxes() {
70
  $current_user = wp_get_current_user();
 
71
  return get_user_meta( $current_user->ID, self::VISIBLE_PAGE_BOXES, true );
72
  }
73
 
74
  /**
75
- * Check whether the meta box in users page is hidden or not
76
  *
77
  * @static
78
  * @access public
79
- * @param string $box The name of the box to check
80
- * @return bool True if the box is hidden, False otherwise
 
 
81
  */
82
  public static function is_users_box_hidden( $box ) {
83
  $hidden_boxes = self::get_users_hidden_boxes();
 
84
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
85
  }
86
 
87
  /**
88
- * Get the list of hidden boxes in users page
89
  *
90
  * @static
91
  * @access public
 
92
  * @return array The array of hidden meta boxes
93
  */
94
  public static function get_users_hidden_boxes() {
95
  $current_user = wp_get_current_user();
 
96
  return get_user_meta( $current_user->ID, self::VISIBLE_USER_BOXES, true );
97
  }
98
 
99
  /**
100
- * Get the list of cron schedules
101
  *
102
  * @static
103
  * @access public
 
104
  * @return array The list of cron schedules
105
  */
106
  public static function get_cron_schedules() {
107
-
108
- $cron_items = array();
109
- $cron = _get_cron_array();
110
  $date_format = _x( 'M j, Y @ G:i', 'Cron table date format', 'bulk-delete' );
111
- $i = 0;
112
 
113
  foreach ( $cron as $timestamp => $cronhooks ) {
114
  foreach ( (array) $cronhooks as $hook => $events ) {
@@ -117,11 +132,11 @@ class BD_Util {
117
 
118
  foreach ( (array) $events as $key => $event ) {
119
  $cron_item['timestamp'] = $timestamp;
120
- $cron_item['due'] = date_i18n( $date_format, $timestamp + ( get_option( 'gmt_offset' ) * 60 * 60 ) );
121
- $cron_item['schedule'] = $event['schedule'];
122
- $cron_item['type'] = $hook;
123
- $cron_item['args'] = $event['args'];
124
- $cron_item['id'] = $i;
125
  }
126
 
127
  $cron_items[ $i ] = $cron_item;
@@ -129,14 +144,17 @@ class BD_Util {
129
  }
130
  }
131
  }
 
132
  return $cron_items;
133
  }
134
 
135
  /**
136
- * Generate display name from post type and status
137
  *
138
  * @static
 
139
  * @param string $str
 
140
  * @return string Label
141
  */
142
  public static function display_post_type_status( $str ) {
@@ -168,11 +186,13 @@ class BD_Util {
168
  }
169
 
170
  /**
171
- * Split post type and status
172
  *
173
  * @static
174
  * @access public
 
175
  * @param string $str
 
176
  * @return array
177
  */
178
  public static function split_post_type_status( $str ) {
@@ -192,40 +212,45 @@ class BD_Util {
192
  }
193
  }
194
 
195
- if ( ! function_exists( 'array_get' ) ) {
196
- /**
197
- * Get a value from an array based on key.
198
- * If key is present returns the value, else returns the default value
199
- *
200
- * @param array $array Array from which value has to be retrieved
201
- * @param string $key Key, whose value to be retrieved
202
- * @param string $default Optional. Default value to be returned, if the key is not found
203
- * @return mixed Value if key is present, else the default value
204
- */
205
- function array_get( $array, $key, $default = null ) {
206
- return isset( $array[ $key ] ) ? $array[ $key ] : $default;
207
- }
 
 
208
  }
209
 
210
- if ( ! function_exists( 'array_get_bool' ) ) {
211
- /**
212
- * Get a value from an array based on key and convert it into bool.
213
- *
214
- * @param array $array Array from which value has to be retrieved
215
- * @param string $key Key, whose value to be retrieved
216
- * @param bool $default (Optional) Default value to be returned, if the key is not found
217
- * @return mixed Boolean converted Value if key is present, else the default value
218
- */
219
- function array_get_bool( $array, $key, $default = false ) {
220
- return filter_var( array_get( $array, $key, $default ), FILTER_VALIDATE_BOOLEAN );
221
- }
 
222
  }
223
 
224
  /**
225
  * Convert a string value into boolean, based on whether the value "True" or "False" is present.
226
  *
227
  * @since 5.5
 
228
  * @param string $string String value to compare.
 
229
  * @return bool True if string is "True", False otherwise.
230
  */
231
  function bd_to_bool( $string ) {
@@ -237,23 +262,24 @@ function bd_to_bool( $string ) {
237
  * This function was originally defined in the Bulk Delete Attachment addon.
238
  *
239
  * @since 5.5
 
240
  * @return array List of allowed mime types after formatting
241
  */
242
  function bd_get_allowed_mime_types() {
243
  $mime_types = get_allowed_mime_types();
244
  sort( $mime_types );
245
 
246
- $processed_mime_types = array();
247
  $processed_mime_types['all'] = __( 'All mime types', 'bulk-delete' );
248
 
249
  $last_value = '';
250
  foreach ( $mime_types as $key => $value ) {
251
  $splitted = explode( '/', $value, 2 );
252
- $prefix = $splitted[0];
253
 
254
  if ( '' == $last_value || $prefix != $last_value ) {
255
  $processed_mime_types[ $prefix ] = __( 'All', 'bulk-delete' ) . ' ' . $prefix;
256
- $last_value = $prefix;
257
  }
258
 
259
  $processed_mime_types[ $value ] = $value;
@@ -266,14 +292,17 @@ function bd_get_allowed_mime_types() {
266
  * Get current theme name.
267
  *
268
  * @since 5.5.4
 
269
  * @return string Current theme name.
270
  */
271
  function bd_get_current_theme_name() {
272
  if ( get_bloginfo( 'version' ) < '3.4' ) {
273
  $theme_data = get_theme_data( get_stylesheet_directory() . '/style.css' );
 
274
  return $theme_data['Name'] . ' ' . $theme_data['Version'];
275
  } else {
276
  $theme_data = wp_get_theme();
 
277
  return $theme_data->Name . ' ' . $theme_data->Version;
278
  }
279
  }
@@ -282,6 +311,7 @@ function bd_get_current_theme_name() {
282
  * Try to identity the hosting provider.
283
  *
284
  * @since 5.5.4
 
285
  * @return string Web host name if identified, empty string otherwise.
286
  */
287
  function bd_identify_host() {
@@ -301,7 +331,7 @@ function bd_identify_host() {
301
  * @since 5.5.4
302
  */
303
  function bd_print_current_plugins() {
304
- $plugins = get_plugins();
305
  $active_plugins = get_option( 'active_plugins', array() );
306
 
307
  foreach ( $plugins as $plugin_path => $plugin ) {
@@ -310,7 +340,7 @@ function bd_print_current_plugins() {
310
  continue;
311
  }
312
 
313
- echo $plugin['Name'] . ': ' . $plugin['Version'] ."\n";
314
  }
315
  }
316
 
@@ -320,7 +350,7 @@ function bd_print_current_plugins() {
320
  * @since 5.5.4
321
  */
322
  function bd_print_network_active_plugins() {
323
- $plugins = wp_get_active_network_plugins();
324
  $active_plugins = get_site_option( 'active_sitewide_plugins', array() );
325
 
326
  foreach ( $plugins as $plugin_path ) {
@@ -333,7 +363,6 @@ function bd_print_network_active_plugins() {
333
 
334
  $plugin = get_plugin_data( $plugin_path );
335
 
336
- echo $plugin['Name'] . ' :' . $plugin['Version'] ."\n";
337
  }
338
  }
339
- ?>
3
  * Utility classes and functions.
4
  *
5
  * @author Sudar
6
+ *
7
  * @package BulkDelete\Util
8
  */
 
9
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
10
 
11
  /**
20
  const VISIBLE_USER_BOXES = 'metaboxhidden_bulk-delete_page_bulk-delete-users';
21
 
22
  /**
23
+ * Check whether the meta box in posts page is hidden or not.
24
  *
25
  * @static
26
  * @access public
27
+ *
28
+ * @param string $box The name of the box
29
+ *
30
+ * @return bool True if the box is hidden, False otherwise
31
  */
32
  public static function is_posts_box_hidden( $box ) {
33
  $hidden_boxes = self::get_posts_hidden_boxes();
34
+
35
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
36
  }
37
 
38
  /**
39
+ * Get the list of hidden boxes in posts page.
40
  *
41
  * @static
42
  * @access public
43
+ *
44
  * @return array The list of hidden meta boxes
45
  */
46
  public static function get_posts_hidden_boxes() {
47
  $current_user = wp_get_current_user();
48
+
49
  return get_user_meta( $current_user->ID, self::VISIBLE_POST_BOXES, true );
50
  }
51
 
52
  /**
53
+ * Check whether the meta box in pages page is hidden or not.
54
  *
55
  * @since 5.0
56
  * @static
57
  * @access public
58
+ *
59
+ * @param string $box The name of the box to check
60
+ *
61
+ * @return bool True if the box is hidden, False otherwise
62
  */
63
  public static function is_pages_box_hidden( $box ) {
64
  $hidden_boxes = self::get_pages_hidden_boxes();
65
+
66
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
67
  }
68
 
69
  /**
70
+ * Get the list of hidden boxes in posts page.
71
  *
72
  * @since 5.0
73
  * @static
74
  * @access public
75
+ *
76
  * @return the array of hidden meta boxes
77
  */
78
  public static function get_pages_hidden_boxes() {
79
  $current_user = wp_get_current_user();
80
+
81
  return get_user_meta( $current_user->ID, self::VISIBLE_PAGE_BOXES, true );
82
  }
83
 
84
  /**
85
+ * Check whether the meta box in users page is hidden or not.
86
  *
87
  * @static
88
  * @access public
89
+ *
90
+ * @param string $box The name of the box to check
91
+ *
92
+ * @return bool True if the box is hidden, False otherwise
93
  */
94
  public static function is_users_box_hidden( $box ) {
95
  $hidden_boxes = self::get_users_hidden_boxes();
96
+
97
  return is_array( $hidden_boxes ) && in_array( $box, $hidden_boxes );
98
  }
99
 
100
  /**
101
+ * Get the list of hidden boxes in users page.
102
  *
103
  * @static
104
  * @access public
105
+ *
106
  * @return array The array of hidden meta boxes
107
  */
108
  public static function get_users_hidden_boxes() {
109
  $current_user = wp_get_current_user();
110
+
111
  return get_user_meta( $current_user->ID, self::VISIBLE_USER_BOXES, true );
112
  }
113
 
114
  /**
115
+ * Get the list of cron schedules.
116
  *
117
  * @static
118
  * @access public
119
+ *
120
  * @return array The list of cron schedules
121
  */
122
  public static function get_cron_schedules() {
123
+ $cron_items = array();
124
+ $cron = _get_cron_array();
 
125
  $date_format = _x( 'M j, Y @ G:i', 'Cron table date format', 'bulk-delete' );
126
+ $i = 0;
127
 
128
  foreach ( $cron as $timestamp => $cronhooks ) {
129
  foreach ( (array) $cronhooks as $hook => $events ) {
132
 
133
  foreach ( (array) $events as $key => $event ) {
134
  $cron_item['timestamp'] = $timestamp;
135
+ $cron_item['due'] = date_i18n( $date_format, $timestamp + ( get_option( 'gmt_offset' ) * 60 * 60 ) );
136
+ $cron_item['schedule'] = $event['schedule'];
137
+ $cron_item['type'] = $hook;
138
+ $cron_item['args'] = $event['args'];
139
+ $cron_item['id'] = $i;
140
  }
141
 
142
  $cron_items[ $i ] = $cron_item;
144
  }
145
  }
146
  }
147
+
148
  return $cron_items;
149
  }
150
 
151
  /**
152
+ * Generate display name from post type and status.
153
  *
154
  * @static
155
+ *
156
  * @param string $str
157
+ *
158
  * @return string Label
159
  */
160
  public static function display_post_type_status( $str ) {
186
  }
187
 
188
  /**
189
+ * Split post type and status.
190
  *
191
  * @static
192
  * @access public
193
+ *
194
  * @param string $str
195
+ *
196
  * @return array
197
  */
198
  public static function split_post_type_status( $str ) {
212
  }
213
  }
214
 
215
+ /**
216
+ * Get a value from an array based on key.
217
+ *
218
+ * If key is present returns the value, else returns the default value.
219
+ *
220
+ * @since 5.6.0 added `bd` prefix.
221
+ *
222
+ * @param array $array Array from which value has to be retrieved.
223
+ * @param string $key Key, whose value to be retrieved.
224
+ * @param string $default Optional. Default value to be returned, if the key is not found.
225
+ *
226
+ * @return mixed Value if key is present, else the default value.
227
+ */
228
+ function bd_array_get( $array, $key, $default = null ) {
229
+ return isset( $array[ $key ] ) ? $array[ $key ] : $default;
230
  }
231
 
232
+ /**
233
+ * Get a value from an array based on key and convert it into bool.
234
+ *
235
+ * @since 5.6.0 added `bd` prefix.
236
+ *
237
+ * @param array $array Array from which value has to be retrieved.
238
+ * @param string $key Key, whose value to be retrieved.
239
+ * @param bool $default (Optional) Default value to be returned, if the key is not found.
240
+ *
241
+ * @return bool Boolean converted Value if key is present, else the default value.
242
+ */
243
+ function bd_array_get_bool( $array, $key, $default = false ) {
244
+ return bd_to_bool( bd_array_get( $array, $key, $default ) );
245
  }
246
 
247
  /**
248
  * Convert a string value into boolean, based on whether the value "True" or "False" is present.
249
  *
250
  * @since 5.5
251
+ *
252
  * @param string $string String value to compare.
253
+ *
254
  * @return bool True if string is "True", False otherwise.
255
  */
256
  function bd_to_bool( $string ) {
262
  * This function was originally defined in the Bulk Delete Attachment addon.
263
  *
264
  * @since 5.5
265
+ *
266
  * @return array List of allowed mime types after formatting
267
  */
268
  function bd_get_allowed_mime_types() {
269
  $mime_types = get_allowed_mime_types();
270
  sort( $mime_types );
271
 
272
+ $processed_mime_types = array();
273
  $processed_mime_types['all'] = __( 'All mime types', 'bulk-delete' );
274
 
275
  $last_value = '';
276
  foreach ( $mime_types as $key => $value ) {
277
  $splitted = explode( '/', $value, 2 );
278
+ $prefix = $splitted[0];
279
 
280
  if ( '' == $last_value || $prefix != $last_value ) {
281
  $processed_mime_types[ $prefix ] = __( 'All', 'bulk-delete' ) . ' ' . $prefix;
282
+ $last_value = $prefix;
283
  }
284
 
285
  $processed_mime_types[ $value ] = $value;
292
  * Get current theme name.
293
  *
294
  * @since 5.5.4
295
+ *
296
  * @return string Current theme name.
297
  */
298
  function bd_get_current_theme_name() {
299
  if ( get_bloginfo( 'version' ) < '3.4' ) {
300
  $theme_data = get_theme_data( get_stylesheet_directory() . '/style.css' );
301
+
302
  return $theme_data['Name'] . ' ' . $theme_data['Version'];
303
  } else {
304
  $theme_data = wp_get_theme();
305
+
306
  return $theme_data->Name . ' ' . $theme_data->Version;
307
  }
308
  }
311
  * Try to identity the hosting provider.
312
  *
313
  * @since 5.5.4
314
+ *
315
  * @return string Web host name if identified, empty string otherwise.
316
  */
317
  function bd_identify_host() {
331
  * @since 5.5.4
332
  */
333
  function bd_print_current_plugins() {
334
+ $plugins = get_plugins();
335
  $active_plugins = get_option( 'active_plugins', array() );
336
 
337
  foreach ( $plugins as $plugin_path => $plugin ) {
340
  continue;
341
  }
342
 
343
+ echo $plugin['Name'] . ': ' . $plugin['Version'] . "\n";
344
  }
345
  }
346
 
350
  * @since 5.5.4
351
  */
352
  function bd_print_network_active_plugins() {
353
+ $plugins = wp_get_active_network_plugins();
354
  $active_plugins = get_site_option( 'active_sitewide_plugins', array() );
355
 
356
  foreach ( $plugins as $plugin_path ) {
363
 
364
  $plugin = get_plugin_data( $plugin_path );
365
 
366
+ echo $plugin['Name'] . ' :' . $plugin['Version'] . "\n";
367
  }
368
  }
 
include/util/class-bulk-delete-by-days.php CHANGED
@@ -1,16 +1,16 @@
1
  <?php
2
  /**
3
- * Class that encapsulates the deletion of posts based on days
4
  *
5
  * @author Sudar
 
6
  * @package BulkDelete
7
  */
8
-
9
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
10
 
11
  class Bulk_Delete_By_Days {
12
- var $days;
13
- var $op;
14
 
15
  /**
16
  * Default constructor.
@@ -27,7 +27,7 @@ class Bulk_Delete_By_Days {
27
  public function parse_query( $query ) {
28
  if ( isset( $query->query_vars['days'] ) ) {
29
  $this->days = $query->query_vars['days'];
30
- $this->op = $query->query_vars['op'];
31
 
32
  add_filter( 'posts_where', array( $this, 'filter_where' ) );
33
  add_filter( 'posts_selection', array( $this, 'remove_where' ) );
@@ -38,10 +38,12 @@ class Bulk_Delete_By_Days {
38
  * Modify the where clause.
39
  *
40
  * @param string $where (optional)
 
41
  * @return string
42
  */
43
  public function filter_where( $where = '' ) {
44
  $where .= ' AND post_date ' . $this->op . " '" . date( 'y-m-d', strtotime( '-' . $this->days . ' days' ) ) . "'";
 
45
  return $where;
46
  }
47
 
@@ -52,4 +54,3 @@ class Bulk_Delete_By_Days {
52
  remove_filter( 'posts_where', array( $this, 'filter_where' ) );
53
  }
54
  }
55
- ?>
1
  <?php
2
  /**
3
+ * Class that encapsulates the deletion of posts based on days.
4
  *
5
  * @author Sudar
6
+ *
7
  * @package BulkDelete
8
  */
 
9
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
10
 
11
  class Bulk_Delete_By_Days {
12
+ public $days;
13
+ public $op;
14
 
15
  /**
16
  * Default constructor.
27
  public function parse_query( $query ) {
28
  if ( isset( $query->query_vars['days'] ) ) {
29
  $this->days = $query->query_vars['days'];
30
+ $this->op = $query->query_vars['op'];
31
 
32
  add_filter( 'posts_where', array( $this, 'filter_where' ) );
33
  add_filter( 'posts_selection', array( $this, 'remove_where' ) );
38
  * Modify the where clause.
39
  *
40
  * @param string $where (optional)
41
+ *
42
  * @return string
43
  */
44
  public function filter_where( $where = '' ) {
45
  $where .= ' AND post_date ' . $this->op . " '" . date( 'y-m-d', strtotime( '-' . $this->days . ' days' ) ) . "'";
46
+
47
  return $where;
48
  }
49
 
54
  remove_filter( 'posts_where', array( $this, 'filter_where' ) );
55
  }
56
  }
 
include/util/query.php CHANGED
@@ -3,10 +3,11 @@
3
  * Utility and wrapper functions for WP_Query.
4
  *
5
  * @since 5.5
 
6
  * @author Sudar
 
7
  * @package BulkDelete\Util
8
  */
9
-
10
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
11
 
12
  /**
@@ -60,8 +61,10 @@ function bd_build_query_options( $delete_options, $options = array() ) {
60
  * Adds some performance enhancing defaults.
61
  *
62
  * @since 5.5
63
- * @param array $options List of options
64
- * @return array Result array
 
 
65
  */
66
  function bd_query( $options ) {
67
  $defaults = array(
@@ -79,8 +82,11 @@ function bd_query( $options ) {
79
  * This action runs before the query happens.
80
  *
81
  * @since 5.5
 
 
 
82
  */
83
- do_action( 'bd_before_query' );
84
 
85
  $posts = $wp_query->query( $options );
86
 
@@ -88,9 +94,11 @@ function bd_query( $options ) {
88
  * This action runs after the query happens.
89
  *
90
  * @since 5.5
 
 
 
91
  */
92
- do_action( 'bd_after_query' );
93
 
94
  return $posts;
95
  }
96
- ?>
3
  * Utility and wrapper functions for WP_Query.
4
  *
5
  * @since 5.5
6
+ *
7
  * @author Sudar
8
+ *
9
  * @package BulkDelete\Util
10
  */
 
11
  defined( 'ABSPATH' ) || exit; // Exit if accessed directly
12
 
13
  /**
61
  * Adds some performance enhancing defaults.
62
  *
63
  * @since 5.5
64
+ *
65
+ * @param array $options List of options
66
+ *
67
+ * @return array Result array
68
  */
69
  function bd_query( $options ) {
70
  $defaults = array(
82
  * This action runs before the query happens.
83
  *
84
  * @since 5.5
85
+ * @since 5.6 added $wp_query param.
86
+ *
87
+ * @param \WP_Query $wp_query Query object.
88
  */
89
+ do_action( 'bd_before_query', $wp_query );
90
 
91
  $posts = $wp_query->query( $options );
92
 
94
  * This action runs after the query happens.
95
  *
96
  * @since 5.5
97
+ * @since 5.6 added $wp_query param.
98
+ *
99
+ * @param \WP_Query $wp_query Query object.
100
  */
101
+ do_action( 'bd_after_query', $wp_query );
102
 
103
  return $posts;
104
  }
 
languages/bulk-delete.pot CHANGED
@@ -2,9 +2,9 @@
2
  # This file is distributed under the same license as the Bulk Delete package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Bulk Delete 5.5.7\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/bulk-delete\n"
7
- "POT-Creation-Date: 2017-11-07 18:20:17+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
@@ -12,604 +12,615 @@ msgstr ""
12
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
 
15
- #: bulk-delete.php:171 bulk-delete.php:183 dist/bulk-delete.php:171
16
- #: dist/bulk-delete.php:183
17
  msgid "Cheatin&#8217; huh?"
18
  msgstr ""
19
 
20
- #: bulk-delete.php:298 dist/bulk-delete.php:298
21
  msgid "Bulk WP"
22
  msgstr ""
23
 
24
- #: bulk-delete.php:300 bulk-delete.php:488 dist/bulk-delete.php:300
25
- #: dist/bulk-delete.php:488 dist/include/ui/admin-ui.php:50
26
- #: include/ui/admin-ui.php:50
27
  msgid "Bulk Delete Posts"
28
  msgstr ""
29
 
30
- #: bulk-delete.php:301 bulk-delete.php:536 dist/bulk-delete.php:301
31
- #: dist/bulk-delete.php:538
32
  msgid "Bulk Delete Pages"
33
  msgstr ""
34
 
35
- #: bulk-delete.php:321 bulk-delete.php:593 dist/bulk-delete.php:321
36
- #: dist/bulk-delete.php:597
37
  msgid "Bulk Delete Schedules"
38
  msgstr ""
39
 
40
- #: bulk-delete.php:321 dist/bulk-delete.php:321
41
  msgid "Scheduled Jobs"
42
  msgstr ""
43
 
44
- #: bulk-delete.php:322 dist/bulk-delete.php:322
45
  #: dist/include/license/class-bd-license.php:33
46
  #: include/license/class-bd-license.php:33
47
  msgid "Addon Licenses"
48
  msgstr ""
49
 
50
- #: bulk-delete.php:369 dist/bulk-delete.php:369
51
  msgid "By Post Status"
52
  msgstr ""
53
 
54
- #: bulk-delete.php:370 dist/bulk-delete.php:370
55
  msgid "By Category"
56
  msgstr ""
57
 
58
- #: bulk-delete.php:371 dist/bulk-delete.php:371
59
  msgid "By Tag"
60
  msgstr ""
61
 
62
- #: bulk-delete.php:372 dist/bulk-delete.php:372
63
  msgid "By Custom Taxonomy"
64
  msgstr ""
65
 
66
- #: bulk-delete.php:373 dist/bulk-delete.php:373
67
  msgid "By Custom Post Type"
68
  msgstr ""
69
 
70
- #: bulk-delete.php:374 dist/bulk-delete.php:374
71
  msgid "By URL"
72
  msgstr ""
73
 
74
- #: bulk-delete.php:375 dist/bulk-delete.php:375
75
  msgid "By Post Revision"
76
  msgstr ""
77
 
78
- #: bulk-delete.php:413 dist/bulk-delete.php:413
79
  msgid "By Page Status"
80
  msgstr ""
81
 
82
- #: bulk-delete.php:504 dist/bulk-delete.php:504
83
- #: dist/include/misc/class-bulk-delete-misc.php:114
84
- #: include/misc/class-bulk-delete-misc.php:114
85
  msgid "WARNING: Posts deleted once cannot be retrieved back. Use with caution."
86
  msgstr ""
87
 
88
- #: bulk-delete.php:552 dist/bulk-delete.php:554
89
  msgid "WARNING: Pages deleted once cannot be retrieved back. Use with caution."
90
  msgstr ""
91
 
92
- #: dist/include/addons/addon-list.php:19 include/addons/addon-list.php:19
93
  msgid ""
94
  "The following are the list of pro addons that are currently available for "
95
  "purchase."
96
  msgstr ""
97
 
98
- #: dist/include/addons/addon-list.php:25 include/addons/addon-list.php:25
99
  msgid "Delete posts by custom field"
100
  msgstr ""
101
 
102
- #: dist/include/addons/addon-list.php:26 include/addons/addon-list.php:26
103
  msgid "Adds the ability to delete posts based on custom fields"
104
  msgstr ""
105
 
106
- #: dist/include/addons/addon-list.php:27 dist/include/addons/addon-list.php:33
107
- #: dist/include/addons/addon-list.php:39 dist/include/addons/addon-list.php:45
108
- #: dist/include/addons/addon-list.php:51 dist/include/addons/addon-list.php:57
109
- #: dist/include/addons/addon-list.php:63 dist/include/addons/addon-list.php:69
110
- #: dist/include/addons/addon-list.php:75 dist/include/addons/addon-list.php:81
111
- #: dist/include/addons/addon-list.php:87 dist/include/addons/addon-list.php:93
112
- #: dist/include/addons/addon-list.php:99 dist/include/addons/addon-list.php:105
113
- #: dist/include/addons/addon-list.php:111
114
- #: dist/include/addons/addon-list.php:117
115
- #: dist/include/addons/addon-list.php:123
116
- #: dist/include/addons/addon-list.php:129
117
- #: dist/include/addons/addon-list.php:135
118
- #: dist/include/addons/addon-list.php:141 include/addons/addon-list.php:27
119
- #: include/addons/addon-list.php:33 include/addons/addon-list.php:39
120
- #: include/addons/addon-list.php:45 include/addons/addon-list.php:51
121
- #: include/addons/addon-list.php:57 include/addons/addon-list.php:63
122
- #: include/addons/addon-list.php:69 include/addons/addon-list.php:75
123
- #: include/addons/addon-list.php:81 include/addons/addon-list.php:87
124
- #: include/addons/addon-list.php:93 include/addons/addon-list.php:99
125
- #: include/addons/addon-list.php:105 include/addons/addon-list.php:111
126
- #: include/addons/addon-list.php:117 include/addons/addon-list.php:123
127
- #: include/addons/addon-list.php:129 include/addons/addon-list.php:135
128
- #: include/addons/addon-list.php:141
 
129
  msgid "More Info"
130
  msgstr ""
131
 
132
- #: dist/include/addons/addon-list.php:31 include/addons/addon-list.php:31
133
  msgid "Delete posts by title"
134
  msgstr ""
135
 
136
- #: dist/include/addons/addon-list.php:32 include/addons/addon-list.php:32
137
  msgid "Adds the ability to delete posts based on title"
138
  msgstr ""
139
 
140
- #: dist/include/addons/addon-list.php:37 include/addons/addon-list.php:37
141
  msgid "Delete posts by duplicate title"
142
  msgstr ""
143
 
144
- #: dist/include/addons/addon-list.php:38 include/addons/addon-list.php:38
145
  msgid "Adds the ability to delete posts based on duplicate title"
146
  msgstr ""
147
 
148
- #: dist/include/addons/addon-list.php:43 include/addons/addon-list.php:43
149
  msgid "Delete posts by attachment"
150
  msgstr ""
151
 
152
- #: dist/include/addons/addon-list.php:44 include/addons/addon-list.php:44
153
  msgid ""
154
  "Adds the ability to delete posts based on whether it contains attachment or "
155
  "not"
156
  msgstr ""
157
 
158
- #: dist/include/addons/addon-list.php:49 include/addons/addon-list.php:49
159
  msgid "Delete posts by user role"
160
  msgstr ""
161
 
162
- #: dist/include/addons/addon-list.php:50 include/addons/addon-list.php:50
163
  msgid "Adds the ability to delete posts based on user role"
164
  msgstr ""
165
 
166
- #: dist/include/addons/addon-list.php:55 include/addons/addon-list.php:55
167
  msgid "Delete from trash"
168
  msgstr ""
169
 
170
- #: dist/include/addons/addon-list.php:56 include/addons/addon-list.php:56
171
  msgid "Adds the ability to delete posts and pages from trash"
172
  msgstr ""
173
 
174
- #: dist/include/addons/addon-list.php:61 include/addons/addon-list.php:61
175
  msgid "Scheduler Email"
176
  msgstr ""
177
 
178
- #: dist/include/addons/addon-list.php:62 include/addons/addon-list.php:62
179
  msgid "Sends an email every time a Bulk WP scheduler runs"
180
  msgstr ""
181
 
182
- #: dist/include/addons/addon-list.php:67 include/addons/addon-list.php:67
183
  msgid "Scheduler for deleting Posts by Category"
184
  msgstr ""
185
 
186
- #: dist/include/addons/addon-list.php:68 include/addons/addon-list.php:68
187
  msgid "Adds the ability to schedule auto delete of posts based on category"
188
  msgstr ""
189
 
190
- #: dist/include/addons/addon-list.php:73 include/addons/addon-list.php:73
191
  msgid "Scheduler for deleting Posts by Tag"
192
  msgstr ""
193
 
194
- #: dist/include/addons/addon-list.php:74 include/addons/addon-list.php:74
195
  msgid "Adds the ability to schedule auto delete of posts based on tag"
196
  msgstr ""
197
 
198
- #: dist/include/addons/addon-list.php:79 include/addons/addon-list.php:79
199
  msgid "Scheduler for deleting Posts by Custom Taxonomy"
200
  msgstr ""
201
 
202
- #: dist/include/addons/addon-list.php:80 include/addons/addon-list.php:80
203
  msgid ""
204
  "Adds the ability to schedule auto delete of posts based on custom taxonomy"
205
  msgstr ""
206
 
207
- #: dist/include/addons/addon-list.php:85 include/addons/addon-list.php:85
208
  msgid "Scheduler for deleting Posts by Custom Post Type"
209
  msgstr ""
210
 
211
- #: dist/include/addons/addon-list.php:86 include/addons/addon-list.php:86
212
  msgid ""
213
  "Adds the ability to schedule auto delete of posts based on custom post type"
214
  msgstr ""
215
 
216
- #: dist/include/addons/addon-list.php:91 include/addons/addon-list.php:91
217
  msgid "Scheduler for deleting Posts by Post Status"
218
  msgstr ""
219
 
220
- #: dist/include/addons/addon-list.php:92 include/addons/addon-list.php:92
221
  msgid ""
222
  "Adds the ability to schedule auto delete of posts based on post status like "
223
  "drafts, pending posts, scheduled posts etc."
224
  msgstr ""
225
 
226
- #: dist/include/addons/addon-list.php:97 include/addons/addon-list.php:97
227
  msgid "Scheduler for deleting Pages by Status"
228
  msgstr ""
229
 
230
- #: dist/include/addons/addon-list.php:98 include/addons/addon-list.php:98
231
  msgid "Adds the ability to schedule auto delete pages based on status"
232
  msgstr ""
233
 
234
- #: dist/include/addons/addon-list.php:103 include/addons/addon-list.php:103
235
  msgid "Scheduler for deleting Users by User Role"
236
  msgstr ""
237
 
238
- #: dist/include/addons/addon-list.php:104 include/addons/addon-list.php:104
239
  msgid "Adds the ability to schedule auto delete of users based on user role"
240
  msgstr ""
241
 
242
- #: dist/include/addons/addon-list.php:109 include/addons/addon-list.php:109
243
  msgid "Scheduler for deleting Users by User Meta"
244
  msgstr ""
245
 
246
- #: dist/include/addons/addon-list.php:110 include/addons/addon-list.php:110
247
  msgid "Adds the ability to schedule auto delete of users based on user meta"
248
  msgstr ""
249
 
250
- #: dist/include/addons/addon-list.php:115 include/addons/addon-list.php:115
251
  msgid "Delete Post Meta Fields"
252
  msgstr ""
253
 
254
- #: dist/include/addons/addon-list.php:116 include/addons/addon-list.php:116
255
  msgid ""
256
  "Adds the ability to delete post meta fields based on value and to schedule "
257
  "automatic deletion"
258
  msgstr ""
259
 
260
- #: dist/include/addons/addon-list.php:121 include/addons/addon-list.php:121
261
  msgid "Delete Comment Meta Fields"
262
  msgstr ""
263
 
264
- #: dist/include/addons/addon-list.php:122 include/addons/addon-list.php:122
265
  msgid ""
266
  "Adds the ability to delete comment meta fields based on value and to "
267
  "schedule automatic deletion"
268
  msgstr ""
269
 
270
- #: dist/include/addons/addon-list.php:127 include/addons/addon-list.php:127
271
  msgid "Delete User Meta Fields"
272
  msgstr ""
273
 
274
- #: dist/include/addons/addon-list.php:128 include/addons/addon-list.php:128
275
  msgid ""
276
  "Adds the ability to delete user meta fields based on value and to schedule "
277
  "automatic deletion"
278
  msgstr ""
279
 
280
- #: dist/include/addons/addon-list.php:133 include/addons/addon-list.php:133
281
  msgid "Delete attachment"
282
  msgstr ""
283
 
284
- #: dist/include/addons/addon-list.php:134 include/addons/addon-list.php:134
285
  msgid ""
286
  "Adds the ability to delete attachments based on whether they are attached to "
287
  "a post or not"
288
  msgstr ""
289
 
290
- #: dist/include/addons/addon-list.php:139 include/addons/addon-list.php:139
291
  msgid "Delete Jetpack Contact Form Messages"
292
  msgstr ""
293
 
294
- #: dist/include/addons/addon-list.php:140 include/addons/addon-list.php:140
295
  msgid ""
296
  "Adds the ability to delete Jetpack Contact Form Messages based on filters "
297
  "and to schedule automatic deletion"
298
  msgstr ""
299
 
300
- #: dist/include/addons/base/class-bd-scheduler-addon.php:106
301
- #: include/addons/base/class-bd-scheduler-addon.php:106
302
  msgid ""
303
  "\"%s\" addon requires \"<a href=\"%s\" target=\"_blank\">%s</a>\" addon to "
304
  "be installed and activated!"
305
  msgstr ""
306
 
307
- #: dist/include/addons/pages.php:20 include/addons/pages.php:20
308
  msgid "Pages in Trash"
309
  msgstr ""
310
 
311
- #: dist/include/addons/pages.php:31 dist/include/addons/posts.php:36
 
312
  #: dist/include/addons/posts.php:64 dist/include/addons/posts.php:92
313
- #: dist/include/addons/posts.php:120 dist/include/addons/posts.php:146
314
- #: dist/include/base/class-bd-meta-box-module.php:158
315
- #: dist/include/meta/class-bulk-delete-comment-meta.php:53
316
- #: dist/include/meta/class-bulk-delete-post-meta.php:53
317
- #: dist/include/meta/class-bulk-delete-user-meta.php:53
318
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:45
319
- #: dist/include/pages/class-bulk-delete-pages.php:23
320
  #: dist/include/posts/class-bulk-delete-posts.php:18
321
- #: dist/include/posts/class-bulk-delete-posts.php:221
322
- #: dist/include/posts/class-bulk-delete-posts.php:358
323
- #: dist/include/posts/class-bulk-delete-posts.php:480
324
- #: dist/include/posts/class-bulk-delete-posts.php:670
325
- #: dist/include/posts/class-bulk-delete-posts.php:836
326
- #: dist/include/posts/class-bulk-delete-posts.php:901
327
- #: include/addons/pages.php:31 include/addons/posts.php:36
328
  #: include/addons/posts.php:64 include/addons/posts.php:92
329
- #: include/addons/posts.php:120 include/addons/posts.php:146
330
- #: include/base/class-bd-meta-box-module.php:158
331
- #: include/meta/class-bulk-delete-comment-meta.php:53
332
- #: include/meta/class-bulk-delete-post-meta.php:53
333
- #: include/meta/class-bulk-delete-user-meta.php:53
334
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:45
335
- #: include/pages/class-bulk-delete-pages.php:23
336
  #: include/posts/class-bulk-delete-posts.php:18
337
- #: include/posts/class-bulk-delete-posts.php:221
338
- #: include/posts/class-bulk-delete-posts.php:358
339
- #: include/posts/class-bulk-delete-posts.php:480
340
- #: include/posts/class-bulk-delete-posts.php:670
341
- #: include/posts/class-bulk-delete-posts.php:836
342
- #: include/posts/class-bulk-delete-posts.php:901
343
  msgid ""
344
  "This section just got enabled. Kindly <a href = \"%1$s\">refresh</a> the "
345
  "page to fully enable it."
346
  msgstr ""
347
 
348
- #: dist/include/addons/pages.php:40 include/addons/pages.php:40
349
  msgid "You need \"Bulk Delete From Trash\" Addon, to delete pages in Trash."
350
  msgstr ""
351
 
352
- #: dist/include/addons/posts.php:20 include/addons/posts.php:20
353
  msgid "By Custom Field"
354
  msgstr ""
355
 
356
- #: dist/include/addons/posts.php:21 include/addons/posts.php:21
357
  msgid "By Title"
358
  msgstr ""
359
 
360
- #: dist/include/addons/posts.php:22 include/addons/posts.php:22
361
  msgid "By Duplicate Title"
362
  msgstr ""
363
 
364
- #: dist/include/addons/posts.php:23
365
- #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:48
366
- #: include/addons/posts.php:23
367
- #: include/users/modules/class-bulk-delete-users-by-user-role.php:48
368
  msgid "By User Role"
369
  msgstr ""
370
 
371
- #: dist/include/addons/posts.php:24 include/addons/posts.php:24
372
  #: tmp_addon/bulk-delete-from-trash.php:151
373
  msgid "Posts in Trash"
374
  msgstr ""
375
 
376
- #: dist/include/addons/posts.php:45 include/addons/posts.php:45
377
  msgid ""
378
  "You need \"Bulk Delete Posts by Custom Field\" Addon, to delete post by "
379
  "custom field."
380
  msgstr ""
381
 
382
- #: dist/include/addons/posts.php:73 include/addons/posts.php:73
383
  msgid "You need \"Bulk Delete Posts by Title\" Addon, to delete post by title."
384
  msgstr ""
385
 
386
- #: dist/include/addons/posts.php:101 include/addons/posts.php:101
387
  msgid ""
388
  "You need \"Bulk Delete Posts by Duplicate Title\" Addon, to delete post by "
389
  "duplicate title."
390
  msgstr ""
391
 
392
- #: dist/include/addons/posts.php:128 include/addons/posts.php:128
393
  msgid ""
394
  "You need \"Bulk Delete Posts by User Role\" Addon, to delete post based on "
395
  "User Role"
396
  msgstr ""
397
 
398
- #: dist/include/addons/posts.php:155 include/addons/posts.php:155
399
  msgid "You need \"Bulk Delete From Trash\" Addon, to delete post in Trash."
400
  msgstr ""
401
 
402
- #: dist/include/base/class-bd-meta-box-module.php:277
403
- #: dist/include/meta/class-bulk-delete-comment-meta.php:240
404
- #: dist/include/meta/class-bulk-delete-post-meta.php:240
405
- #: dist/include/meta/class-bulk-delete-user-meta.php:216
406
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:221
407
- #: dist/include/pages/class-bulk-delete-pages.php:119
408
- #: dist/include/posts/class-bulk-delete-posts.php:126
409
- #: dist/include/posts/class-bulk-delete-posts.php:297
410
- #: dist/include/posts/class-bulk-delete-posts.php:427
411
- #: dist/include/posts/class-bulk-delete-posts.php:601
412
- #: dist/include/posts/class-bulk-delete-posts.php:766
413
- #: include/base/class-bd-meta-box-module.php:277
414
- #: include/meta/class-bulk-delete-comment-meta.php:240
415
- #: include/meta/class-bulk-delete-post-meta.php:240
416
- #: include/meta/class-bulk-delete-user-meta.php:216
417
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:221
418
- #: include/pages/class-bulk-delete-pages.php:119
419
- #: include/posts/class-bulk-delete-posts.php:126
420
- #: include/posts/class-bulk-delete-posts.php:297
421
- #: include/posts/class-bulk-delete-posts.php:427
422
- #: include/posts/class-bulk-delete-posts.php:601
423
- #: include/posts/class-bulk-delete-posts.php:766
 
424
  #: tmp_addon/bulk-delete-posts-by-attachment.php:288
425
  #: tmp_addon/bulk-delete-posts-by-content.php:292
426
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:326
427
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:257
428
- #: tmp_addon/bulk-delete-posts-by-title.php:277
429
  #: tmp_addon/bulk-delete-posts-by-user-role.php:225
430
  #: tmp_addon/bulk-delete-posts-by-user.php:265
 
431
  msgid "See the full list of <a href = \"%s\">scheduled tasks</a>"
432
  msgstr ""
433
 
434
- #: dist/include/base/users/class-bd-user-meta-box-module.php:160
435
- #: include/base/users/class-bd-user-meta-box-module.php:160
436
- msgid "Restrict to users who have registered at least "
437
  msgstr ""
438
 
439
- #: dist/include/base/users/class-bd-user-meta-box-module.php:161
440
- #: include/base/users/class-bd-user-meta-box-module.php:161
441
- msgid "days ago"
442
  msgstr ""
443
 
444
- #: dist/include/base/users/class-bd-user-meta-box-module.php:175
445
- #: include/base/users/class-bd-user-meta-box-module.php:175
446
  msgid "Restrict to users who have not logged in the last "
447
  msgstr ""
448
 
449
- #: dist/include/base/users/class-bd-user-meta-box-module.php:176
450
- #: dist/include/meta/class-bulk-delete-comment-meta.php:134
451
- #: dist/include/meta/class-bulk-delete-post-meta.php:134
452
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:110
453
- #: dist/include/ui/form.php:46
454
- #: include/base/users/class-bd-user-meta-box-module.php:176
455
- #: include/meta/class-bulk-delete-comment-meta.php:134
456
- #: include/meta/class-bulk-delete-post-meta.php:134
457
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:110
458
- #: include/ui/form.php:46 tmp_addon/bulk-delete-from-trash.php:348
459
  #: tmp_addon/bulk-delete-posts-by-attachment.php:177
460
  #: tmp_addon/bulk-delete-posts-by-content.php:197
461
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:213
462
- #: tmp_addon/bulk-delete-posts-by-title.php:179
463
  #: tmp_addon/bulk-delete-posts-by-user-role.php:140
464
  #: tmp_addon/bulk-delete-posts-by-user.php:181
 
465
  msgid "days"
466
  msgstr ""
467
 
468
- #: dist/include/base/users/class-bd-user-meta-box-module.php:179
469
- #: include/base/users/class-bd-user-meta-box-module.php:179
470
  msgid "Need the free \"Simple Login Log\" Plugin"
471
  msgstr ""
472
 
473
- #: dist/include/base/users/class-bd-user-meta-box-module.php:187
474
- #: include/base/users/class-bd-user-meta-box-module.php:187
475
  msgid ""
476
  "Enter \"0 days\" to delete users who have never logged in after the \"Simple "
477
  "Login Log\" plugin has been installed."
478
  msgstr ""
479
 
480
- #: dist/include/base/users/class-bd-user-meta-box-module.php:202
481
- #: include/base/users/class-bd-user-meta-box-module.php:202
482
- msgid ""
483
- "Only if user doesn't have any post. Only posts from 'post' post type would "
484
- "be considered."
 
 
 
485
  msgstr ""
486
 
487
- #: dist/include/cron/class-cron-list-table.php:34
488
- #: include/cron/class-cron-list-table.php:34
489
  msgid ""
490
  "This is the list of jobs that are currently scheduled for auto deleting "
491
  "posts in Bulk Delete Plugin."
492
  msgstr ""
493
 
494
- #: dist/include/cron/class-cron-list-table.php:36
495
- #: include/cron/class-cron-list-table.php:36
496
  msgid "Note: "
497
  msgstr ""
498
 
499
- #: dist/include/cron/class-cron-list-table.php:38
500
- #: include/cron/class-cron-list-table.php:38
501
  msgid ""
502
  "Scheduling auto post or user deletion is available only when you buy pro "
503
  "addons."
504
  msgstr ""
505
 
506
- #: dist/include/cron/class-cron-list-table.php:50
507
- #: include/cron/class-cron-list-table.php:50
508
  msgid "Next Due"
509
  msgstr ""
510
 
511
- #: dist/include/cron/class-cron-list-table.php:51
512
- #: dist/include/meta/class-bulk-delete-comment-meta.php:150
513
- #: dist/include/meta/class-bulk-delete-post-meta.php:150
514
- #: dist/include/meta/class-bulk-delete-user-meta.php:130
515
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:141
516
- #: dist/include/ui/form.php:121 include/cron/class-cron-list-table.php:51
517
- #: include/meta/class-bulk-delete-comment-meta.php:150
518
- #: include/meta/class-bulk-delete-post-meta.php:150
519
- #: include/meta/class-bulk-delete-user-meta.php:130
520
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:141
521
- #: include/ui/form.php:121 tmp_addon/bulk-delete-posts-by-attachment.php:209
522
  #: tmp_addon/bulk-delete-posts-by-content.php:227
523
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:252
524
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:186
525
- #: tmp_addon/bulk-delete-posts-by-title.php:207
526
  #: tmp_addon/bulk-delete-posts-by-user-role.php:164
527
  #: tmp_addon/bulk-delete-posts-by-user.php:205
 
528
  msgid "Schedule"
529
  msgstr ""
530
 
531
- #: dist/include/cron/class-cron-list-table.php:52
532
- #: include/cron/class-cron-list-table.php:52
533
  msgid "Type"
534
  msgstr ""
535
 
536
- #: dist/include/cron/class-cron-list-table.php:53
537
- #: include/cron/class-cron-list-table.php:53
538
  msgid "Options"
539
  msgstr ""
540
 
541
  #: dist/include/cron/class-cron-list-table.php:114
542
- #: dist/include/license/class-license-list-table.php:93
543
  #: include/cron/class-cron-list-table.php:114
544
- #: include/license/class-license-list-table.php:93
545
  msgid "Delete"
546
  msgstr ""
547
 
548
- #: dist/include/cron/class-cron-list-table.php:158
549
- #: include/cron/class-cron-list-table.php:158
550
  msgid "You have not scheduled any bulk delete jobs."
551
  msgstr ""
552
 
553
  #: dist/include/libraries/EDD_SL_Plugin_Updater.php:201
 
554
  msgid ""
555
  "There is a new version of %1$s available. %2$sView version %3$s details%4$s."
556
  msgstr ""
557
 
558
  #: dist/include/libraries/EDD_SL_Plugin_Updater.php:209
 
559
  msgid ""
560
  "There is a new version of %1$s available. %2$sView version %3$s details%4$s "
561
  "or %5$supdate now%6$s."
562
  msgstr ""
563
 
564
  #: dist/include/libraries/EDD_SL_Plugin_Updater.php:399
565
- #: include/libraries/EDD_SL_Plugin_Updater.php:326
566
  msgid "You do not have permission to install plugin updates"
567
  msgstr ""
568
 
569
  #: dist/include/libraries/EDD_SL_Plugin_Updater.php:399
570
- #: include/libraries/EDD_SL_Plugin_Updater.php:326
571
  msgid "Error"
572
  msgstr ""
573
 
574
- #: dist/include/license/class-bd-license-handler.php:132
575
- #: include/license/class-bd-license-handler.php:132
576
  msgid ""
577
  "\"%1$s\" addon is installed but not activated. To activate the addon, please "
578
  "<a href=\"%2$s\">enter your license key</a>. If you don't have a license "
579
  "key, then you can <a href=\"%3$s\" target=\"_blank\">purchase one</a>."
580
  msgstr ""
581
 
582
- #: dist/include/license/class-bd-license-handler.php:139
583
- #: include/license/class-bd-license-handler.php:139
584
  msgid ""
585
  "The license for \"%1$s\" addon is either invalid or has expired. Please <a "
586
  "href=\"%2$s\" target=\"_blank\">renew the license</a> or <a href=\"%3$s"
587
  "\">enter a new license key</a> to receive updates and support."
588
  msgstr ""
589
 
590
- #: dist/include/license/class-bd-license-handler.php:201
591
- #: include/license/class-bd-license-handler.php:201
592
  msgid ""
593
  "Addon is not activated. To activate the addon, please <a href=\"%1$s\">enter "
594
  "your license key</a>. If you don't have a license key, then you can <a href="
595
  "\"%2$s\" target=\"_blank\">purchase one</a>."
596
  msgstr ""
597
 
598
- #: dist/include/license/class-bd-license-handler.php:211
599
- #: include/license/class-bd-license-handler.php:211
600
  msgid ""
601
  "The license for this addon is either invalid or has expired. Please <a href="
602
  "\"%1$s\" target=\"_blank\">renew the license</a> or <a href=\"%2$s\">enter a "
603
  "new license key</a> to receive updates and support."
604
  msgstr ""
605
 
606
- #: dist/include/license/class-bd-license-handler.php:244
607
- #: include/license/class-bd-license-handler.php:244
608
  msgid "Addon License Key"
609
  msgstr ""
610
 
611
- #: dist/include/license/class-bd-license-handler.php:264
612
- #: include/license/class-bd-license-handler.php:264
613
  msgid "Enter license key"
614
  msgstr ""
615
 
@@ -618,98 +629,98 @@ msgstr ""
618
  msgid "Activate License"
619
  msgstr ""
620
 
621
- #: dist/include/license/class-bd-license.php:191
622
- #: include/license/class-bd-license.php:191
623
  msgid "The license key for \"%s\" addon was successfully deactivated"
624
  msgstr ""
625
 
626
- #: dist/include/license/class-bd-license.php:196
627
- #: include/license/class-bd-license.php:196
628
  msgid ""
629
  "There was some problem while trying to deactivate license key for \"%s\" "
630
  "addon. Kindly try again"
631
  msgstr ""
632
 
633
- #: dist/include/license/class-bd-license.php:219
634
- #: include/license/class-bd-license.php:219
635
  msgid "The license key was successfully deleted"
636
  msgstr ""
637
 
638
- #: dist/include/license/class-bd-license.php:262
639
- #: include/license/class-bd-license.php:262
640
  msgid ""
641
  "There was some problem in contacting our store to activate the license key "
642
  "for \"%s\" addon"
643
  msgstr ""
644
 
645
- #: dist/include/license/class-bd-license.php:272
646
- #: include/license/class-bd-license.php:272
647
  msgid ""
648
  "The license key for \"%s\" addon was successfully activated. The addon will "
649
  "get updates automatically till the license key is valid."
650
  msgstr ""
651
 
652
- #: dist/include/license/class-bd-license.php:280
653
- #: include/license/class-bd-license.php:280
654
  msgid ""
655
  "The license key for \"%s\" addon doesn't have any more activations left. "
656
  "Kindly buy a new license."
657
  msgstr ""
658
 
659
- #: dist/include/license/class-bd-license.php:284
660
- #: include/license/class-bd-license.php:284
661
  msgid "The license key for \"%s\" addon is revoked. Kindly buy a new license."
662
  msgstr ""
663
 
664
- #: dist/include/license/class-bd-license.php:288
665
- #: include/license/class-bd-license.php:288
666
  msgid "The license key for \"%s\" addon has expired. Kindly buy a new license."
667
  msgstr ""
668
 
669
- #: dist/include/license/class-bd-license.php:292
670
- #: include/license/class-bd-license.php:292
671
  msgid "The license key for \"%s\" addon is invalid"
672
  msgstr ""
673
 
674
- #: dist/include/license/class-license-list-table.php:37
675
- #: include/license/class-license-list-table.php:37
676
  msgid ""
677
  "This is the list of addon license that are currently registered with the "
678
  "plugin."
679
  msgstr ""
680
 
681
- #: dist/include/license/class-license-list-table.php:50
682
- #: include/license/class-license-list-table.php:50
683
  msgid "Addon Name"
684
  msgstr ""
685
 
686
- #: dist/include/license/class-license-list-table.php:51
687
- #: include/license/class-license-list-table.php:51
688
  msgid "License Code"
689
  msgstr ""
690
 
691
- #: dist/include/license/class-license-list-table.php:52
692
- #: include/license/class-license-list-table.php:52
693
  msgid "Validity"
694
  msgstr ""
695
 
696
- #: dist/include/license/class-license-list-table.php:53
697
- #: include/license/class-license-list-table.php:53
698
  msgid "Expires"
699
  msgstr ""
700
 
701
- #: dist/include/license/class-license-list-table.php:97
702
- #: include/license/class-license-list-table.php:97
703
  msgid "Deactivate"
704
  msgstr ""
705
 
706
- #: dist/include/license/class-license-list-table.php:158
707
- #: include/license/class-license-list-table.php:158
708
  msgid "N/A"
709
  msgstr ""
710
 
711
- #: dist/include/license/class-license-list-table.php:168
712
- #: include/license/class-license-list-table.php:168
713
  msgid "You don't have any valid addon license yet."
714
  msgstr ""
715
 
@@ -718,255 +729,263 @@ msgstr ""
718
  msgid "Bulk Delete Comment Meta"
719
  msgstr ""
720
 
721
- #: dist/include/meta/class-bulk-delete-comment-meta.php:68
722
- #: include/meta/class-bulk-delete-comment-meta.php:68
723
  msgid "Select the post type whose comment meta fields you want to delete"
724
  msgstr ""
725
 
726
- #: dist/include/meta/class-bulk-delete-comment-meta.php:84
727
- #: include/meta/class-bulk-delete-comment-meta.php:84
728
  msgid "Choose your comment meta field settings"
729
  msgstr ""
730
 
731
- #: dist/include/meta/class-bulk-delete-comment-meta.php:89
732
- #: include/meta/class-bulk-delete-comment-meta.php:89
733
  msgid "Delete based on comment meta key name only"
734
  msgstr ""
735
 
736
- #: dist/include/meta/class-bulk-delete-comment-meta.php:96
737
- #: include/meta/class-bulk-delete-comment-meta.php:96
738
  msgid "Delete based on comment meta key name and value"
739
  msgstr ""
740
 
741
- #: dist/include/meta/class-bulk-delete-comment-meta.php:98
742
- #: dist/include/meta/class-bulk-delete-comment-meta.php:164
743
- #: dist/include/meta/class-bulk-delete-post-meta.php:98
744
- #: dist/include/meta/class-bulk-delete-post-meta.php:164
745
- #: dist/include/meta/class-bulk-delete-user-meta.php:90
746
- #: dist/include/meta/class-bulk-delete-user-meta.php:144
747
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:80
748
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:154
749
- #: dist/include/ui/form.php:132
750
- #: include/meta/class-bulk-delete-comment-meta.php:98
751
- #: include/meta/class-bulk-delete-comment-meta.php:164
752
- #: include/meta/class-bulk-delete-post-meta.php:98
753
- #: include/meta/class-bulk-delete-post-meta.php:164
754
- #: include/meta/class-bulk-delete-user-meta.php:90
755
- #: include/meta/class-bulk-delete-user-meta.php:144
756
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:80
757
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:154
758
- #: include/ui/form.php:132 tmp_addon/bulk-delete-posts-by-attachment.php:222
759
  #: tmp_addon/bulk-delete-posts-by-content.php:240
760
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:267
761
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:199
762
- #: tmp_addon/bulk-delete-posts-by-title.php:222
763
  #: tmp_addon/bulk-delete-posts-by-user-role.php:177
764
  #: tmp_addon/bulk-delete-posts-by-user.php:218
 
765
  msgid "Only available in Pro Addon"
766
  msgstr ""
767
 
768
- #: dist/include/meta/class-bulk-delete-comment-meta.php:105
769
- #: include/meta/class-bulk-delete-comment-meta.php:105
770
  msgid "Comment Meta Key "
771
  msgstr ""
772
 
773
- #: dist/include/meta/class-bulk-delete-comment-meta.php:106
774
- #: dist/include/meta/class-bulk-delete-post-meta.php:106
775
- #: dist/include/meta/class-bulk-delete-user-meta.php:98
776
- #: include/meta/class-bulk-delete-comment-meta.php:106
777
- #: include/meta/class-bulk-delete-post-meta.php:106
778
- #: include/meta/class-bulk-delete-user-meta.php:98
779
  msgid "Meta Key"
780
  msgstr ""
781
 
782
- #: dist/include/meta/class-bulk-delete-comment-meta.php:122
783
- #: dist/include/meta/class-bulk-delete-post-meta.php:122
784
- #: dist/include/meta/class-bulk-delete-user-meta.php:114
785
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:127
786
- #: include/meta/class-bulk-delete-comment-meta.php:122
787
- #: include/meta/class-bulk-delete-post-meta.php:122
788
- #: include/meta/class-bulk-delete-user-meta.php:114
789
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:127
790
  msgid "Choose your deletion options"
791
  msgstr ""
792
 
793
- #: dist/include/meta/class-bulk-delete-comment-meta.php:129
794
- #: include/meta/class-bulk-delete-comment-meta.php:129
795
  msgid "Only restrict to comments which are "
796
  msgstr ""
797
 
798
- #: dist/include/meta/class-bulk-delete-comment-meta.php:131
799
- #: dist/include/meta/class-bulk-delete-post-meta.php:131
800
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:107
801
- #: dist/include/ui/form.php:43
802
- #: include/meta/class-bulk-delete-comment-meta.php:131
803
- #: include/meta/class-bulk-delete-post-meta.php:131
804
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:107
805
- #: include/ui/form.php:43 tmp_addon/bulk-delete-posts-by-attachment.php:174
806
  #: tmp_addon/bulk-delete-posts-by-content.php:194
807
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:209
808
- #: tmp_addon/bulk-delete-posts-by-title.php:175
809
  #: tmp_addon/bulk-delete-posts-by-user-role.php:137
810
  #: tmp_addon/bulk-delete-posts-by-user.php:178
 
811
  msgid "older than"
812
  msgstr ""
813
 
814
- #: dist/include/meta/class-bulk-delete-comment-meta.php:132
815
- #: include/meta/class-bulk-delete-comment-meta.php:132
816
  msgid "commented within last"
817
  msgstr ""
818
 
819
- #: dist/include/meta/class-bulk-delete-comment-meta.php:141
820
- #: include/meta/class-bulk-delete-comment-meta.php:141
821
  msgid "Only delete comment meta field from first "
822
  msgstr ""
823
 
824
- #: dist/include/meta/class-bulk-delete-comment-meta.php:142
825
- #: include/meta/class-bulk-delete-comment-meta.php:142
826
  msgid "comments."
827
  msgstr ""
828
 
829
- #: dist/include/meta/class-bulk-delete-comment-meta.php:143
830
- #: dist/include/meta/class-bulk-delete-post-meta.php:143
831
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:121
832
- #: include/meta/class-bulk-delete-comment-meta.php:143
833
- #: include/meta/class-bulk-delete-post-meta.php:143
834
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:121
835
  #: tmp_addon/bulk-delete-posts-by-attachment.php:202
836
  #: tmp_addon/bulk-delete-posts-by-content.php:220
837
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:243
838
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:179
839
- #: tmp_addon/bulk-delete-posts-by-title.php:198
 
840
  msgid ""
841
  "Use this option if there are more than 1000 posts and the script timesout."
842
  msgstr ""
843
 
844
- #: dist/include/meta/class-bulk-delete-comment-meta.php:149
845
- #: dist/include/meta/class-bulk-delete-post-meta.php:149
846
- #: dist/include/meta/class-bulk-delete-user-meta.php:129
847
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:140
848
- #: dist/include/ui/form.php:120
849
- #: include/meta/class-bulk-delete-comment-meta.php:149
850
- #: include/meta/class-bulk-delete-post-meta.php:149
851
- #: include/meta/class-bulk-delete-user-meta.php:129
852
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:140
853
- #: include/ui/form.php:120 tmp_addon/bulk-delete-posts-by-attachment.php:208
854
- #: tmp_addon/bulk-delete-posts-by-content.php:226
855
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:250
856
- #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:185
857
- #: tmp_addon/bulk-delete-posts-by-title.php:205
858
- #: tmp_addon/bulk-delete-posts-by-user-role.php:163
859
- #: tmp_addon/bulk-delete-posts-by-user.php:204
860
- msgid "Delete now"
861
- msgstr ""
862
-
863
  #: dist/include/meta/class-bulk-delete-comment-meta.php:151
864
  #: dist/include/meta/class-bulk-delete-post-meta.php:151
865
  #: dist/include/meta/class-bulk-delete-user-meta.php:131
866
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:142
867
- #: dist/include/ui/form.php:122
868
  #: include/meta/class-bulk-delete-comment-meta.php:151
869
  #: include/meta/class-bulk-delete-post-meta.php:151
870
  #: include/meta/class-bulk-delete-user-meta.php:131
871
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:142
872
- #: include/ui/form.php:122 tmp_addon/bulk-delete-posts-by-attachment.php:210
873
- #: tmp_addon/bulk-delete-posts-by-content.php:228
874
  #: tmp_addon/bulk-delete-posts-by-custom-field.php:254
875
- #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:187
876
- #: tmp_addon/bulk-delete-posts-by-title.php:209
877
- #: tmp_addon/bulk-delete-posts-by-user-role.php:165
878
- #: tmp_addon/bulk-delete-posts-by-user.php:206
879
- msgid "repeat "
 
880
  msgstr ""
881
 
882
  #: dist/include/meta/class-bulk-delete-comment-meta.php:153
883
  #: dist/include/meta/class-bulk-delete-post-meta.php:153
884
  #: dist/include/meta/class-bulk-delete-user-meta.php:133
885
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:144
886
- #: dist/include/ui/form.php:124
887
  #: include/meta/class-bulk-delete-comment-meta.php:153
888
  #: include/meta/class-bulk-delete-post-meta.php:153
889
  #: include/meta/class-bulk-delete-user-meta.php:133
890
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:144
891
- #: include/ui/form.php:124 tmp_addon/bulk-delete-posts-by-attachment.php:212
892
- #: tmp_addon/bulk-delete-posts-by-content.php:230
893
  #: tmp_addon/bulk-delete-posts-by-custom-field.php:256
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
894
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:189
895
- #: tmp_addon/bulk-delete-posts-by-title.php:211
896
  #: tmp_addon/bulk-delete-posts-by-user-role.php:167
897
  #: tmp_addon/bulk-delete-posts-by-user.php:208
 
898
  msgid "Don't repeat"
899
  msgstr ""
900
 
901
- #: dist/include/meta/class-bulk-delete-comment-meta.php:171
902
- #: dist/include/meta/class-bulk-delete-post-meta.php:171
903
- #: dist/include/meta/class-bulk-delete-user-meta.php:151
904
- #: include/meta/class-bulk-delete-comment-meta.php:171
905
- #: include/meta/class-bulk-delete-post-meta.php:171
906
- #: include/meta/class-bulk-delete-user-meta.php:151
907
  #: tmp_addon/bulk-delete-posts-by-attachment.php:228
908
  #: tmp_addon/bulk-delete-posts-by-content.php:246
909
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:274
910
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:205
911
- #: tmp_addon/bulk-delete-posts-by-title.php:229
912
  #: tmp_addon/bulk-delete-posts-by-user-role.php:183
913
  #: tmp_addon/bulk-delete-posts-by-user.php:224
 
914
  msgid "Enter time in Y-m-d H:i:s format or enter now to use current time"
915
  msgstr ""
916
 
917
- #: dist/include/meta/class-bulk-delete-comment-meta.php:179
918
- #: dist/include/meta/class-bulk-delete-post-meta.php:179
919
- #: dist/include/meta/class-bulk-delete-user-meta.php:159
920
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:161
921
- #: dist/include/ui/form.php:153
922
- #: include/meta/class-bulk-delete-comment-meta.php:179
923
- #: include/meta/class-bulk-delete-post-meta.php:179
924
- #: include/meta/class-bulk-delete-user-meta.php:159
925
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:161
926
- #: include/ui/form.php:153 tmp_addon/bulk-delete-from-trash.php:162
927
  #: tmp_addon/bulk-delete-from-trash.php:270
928
  #: tmp_addon/bulk-delete-posts-by-attachment.php:235
929
  #: tmp_addon/bulk-delete-posts-by-content.php:254
930
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:283
931
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:213
932
- #: tmp_addon/bulk-delete-posts-by-title.php:238
933
  #: tmp_addon/bulk-delete-posts-by-user-role.php:191
934
  #: tmp_addon/bulk-delete-posts-by-user.php:232
 
935
  msgid "Bulk Delete "
936
  msgstr ""
937
 
938
- #: dist/include/meta/class-bulk-delete-comment-meta.php:198
939
- #: include/meta/class-bulk-delete-comment-meta.php:198
940
  msgid ""
941
  "Are you sure you want to delete all the comment meta fields that match the "
942
  "selected filters?"
943
  msgstr ""
944
 
945
- #: dist/include/meta/class-bulk-delete-comment-meta.php:239
946
- #: include/meta/class-bulk-delete-comment-meta.php:239
947
  msgid ""
948
  "Comment meta fields from the comments with the selected criteria are "
949
  "scheduled for deletion."
950
  msgstr ""
951
 
952
- #: dist/include/meta/class-bulk-delete-comment-meta.php:243
953
- #: include/meta/class-bulk-delete-comment-meta.php:243
954
  msgid "Deleted comment meta field from %d comment"
955
  msgid_plural "Deleted comment meta field from %d comments"
956
  msgstr[0] ""
957
  msgstr[1] ""
958
 
959
- #: dist/include/meta/class-bulk-delete-meta.php:39
960
  #: dist/include/meta/class-bulk-delete-meta.php:40
961
- #: dist/include/meta/class-bulk-delete-meta.php:103
962
- #: include/meta/class-bulk-delete-meta.php:39
963
  #: include/meta/class-bulk-delete-meta.php:40
964
- #: include/meta/class-bulk-delete-meta.php:103
 
965
  msgid "Bulk Delete Meta Fields"
966
  msgstr ""
967
 
968
- #: dist/include/meta/class-bulk-delete-meta.php:118
969
- #: include/meta/class-bulk-delete-meta.php:118
970
  msgid "WARNING: Items deleted once cannot be retrieved back. Use with caution."
971
  msgstr ""
972
 
@@ -975,91 +994,94 @@ msgstr ""
975
  msgid "Bulk Delete Post Meta"
976
  msgstr ""
977
 
978
- #: dist/include/meta/class-bulk-delete-post-meta.php:68
979
- #: include/meta/class-bulk-delete-post-meta.php:68
980
  msgid "Select the post type whose post meta fields you want to delete"
981
  msgstr ""
982
 
983
- #: dist/include/meta/class-bulk-delete-post-meta.php:84
984
- #: include/meta/class-bulk-delete-post-meta.php:84
985
  msgid "Choose your post meta field settings"
986
  msgstr ""
987
 
988
- #: dist/include/meta/class-bulk-delete-post-meta.php:89
989
- #: include/meta/class-bulk-delete-post-meta.php:89
990
  msgid "Delete based on post meta key name only"
991
  msgstr ""
992
 
993
- #: dist/include/meta/class-bulk-delete-post-meta.php:96
994
- #: include/meta/class-bulk-delete-post-meta.php:96
995
  msgid "Delete based on post meta key name and value"
996
  msgstr ""
997
 
998
- #: dist/include/meta/class-bulk-delete-post-meta.php:105
999
- #: include/meta/class-bulk-delete-post-meta.php:105
1000
  msgid "Post Meta Key "
1001
  msgstr ""
1002
 
1003
- #: dist/include/meta/class-bulk-delete-post-meta.php:129
1004
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:105
1005
- #: include/meta/class-bulk-delete-post-meta.php:129
1006
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:105
1007
  #: tmp_addon/bulk-delete-posts-by-attachment.php:172
1008
  #: tmp_addon/bulk-delete-posts-by-content.php:192
1009
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:207
1010
- #: tmp_addon/bulk-delete-posts-by-title.php:173
1011
  #: tmp_addon/bulk-delete-posts-by-user-role.php:135
1012
  #: tmp_addon/bulk-delete-posts-by-user.php:176
 
1013
  msgid "Only restrict to posts which are "
1014
  msgstr ""
1015
 
1016
- #: dist/include/meta/class-bulk-delete-post-meta.php:132
1017
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:108
1018
- #: dist/include/ui/form.php:44 include/meta/class-bulk-delete-post-meta.php:132
1019
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:108
1020
- #: include/ui/form.php:44 tmp_addon/bulk-delete-posts-by-attachment.php:175
1021
  #: tmp_addon/bulk-delete-posts-by-content.php:195
1022
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:210
1023
- #: tmp_addon/bulk-delete-posts-by-title.php:176
1024
  #: tmp_addon/bulk-delete-posts-by-user-role.php:138
1025
  #: tmp_addon/bulk-delete-posts-by-user.php:179
 
1026
  msgid "posted within last"
1027
  msgstr ""
1028
 
1029
- #: dist/include/meta/class-bulk-delete-post-meta.php:141
1030
- #: include/meta/class-bulk-delete-post-meta.php:141
1031
  msgid "Only delete post meta field from first "
1032
  msgstr ""
1033
 
1034
- #: dist/include/meta/class-bulk-delete-post-meta.php:142
1035
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:120
1036
- #: include/meta/class-bulk-delete-post-meta.php:142
1037
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:120
1038
  #: tmp_addon/bulk-delete-posts-by-attachment.php:201
1039
  #: tmp_addon/bulk-delete-posts-by-content.php:219
1040
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:242
1041
- #: tmp_addon/bulk-delete-posts-by-title.php:197
1042
  #: tmp_addon/bulk-delete-posts-by-user-role.php:156
1043
  #: tmp_addon/bulk-delete-posts-by-user.php:197
 
1044
  msgid "posts."
1045
  msgstr ""
1046
 
1047
- #: dist/include/meta/class-bulk-delete-post-meta.php:198
1048
- #: include/meta/class-bulk-delete-post-meta.php:198
1049
  msgid ""
1050
  "Are you sure you want to delete all the post meta fields that match the "
1051
  "selected filters?"
1052
  msgstr ""
1053
 
1054
- #: dist/include/meta/class-bulk-delete-post-meta.php:239
1055
- #: include/meta/class-bulk-delete-post-meta.php:239
1056
  msgid ""
1057
  "Post meta fields from the posts with the selected criteria are scheduled for "
1058
  "deletion."
1059
  msgstr ""
1060
 
1061
- #: dist/include/meta/class-bulk-delete-post-meta.php:243
1062
- #: include/meta/class-bulk-delete-post-meta.php:243
1063
  msgid "Deleted post meta field from %d post"
1064
  msgid_plural "Deleted post meta field from %d posts"
1065
  msgstr[0] ""
@@ -1070,531 +1092,575 @@ msgstr[1] ""
1070
  msgid "Bulk Delete User Meta"
1071
  msgstr ""
1072
 
1073
- #: dist/include/meta/class-bulk-delete-user-meta.php:59
1074
- #: include/meta/class-bulk-delete-user-meta.php:59
1075
  msgid "Select the user role whose user meta fields you want to delete"
1076
  msgstr ""
1077
 
1078
- #: dist/include/meta/class-bulk-delete-user-meta.php:68
1079
- #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:74
1080
- #: include/meta/class-bulk-delete-user-meta.php:68
1081
- #: include/users/modules/class-bulk-delete-users-by-user-role.php:74
1082
  #: tmp_addon/bulk-delete-posts-by-user-role.php:96
1083
  msgid "Users"
1084
  msgstr ""
1085
 
1086
- #: dist/include/meta/class-bulk-delete-user-meta.php:76
1087
- #: include/meta/class-bulk-delete-user-meta.php:76
1088
  msgid "Choose your user meta field settings"
1089
  msgstr ""
1090
 
1091
- #: dist/include/meta/class-bulk-delete-user-meta.php:81
1092
- #: include/meta/class-bulk-delete-user-meta.php:81
1093
  msgid "Delete based on user meta key name only"
1094
  msgstr ""
1095
 
1096
- #: dist/include/meta/class-bulk-delete-user-meta.php:88
1097
- #: include/meta/class-bulk-delete-user-meta.php:88
1098
  msgid "Delete based on user meta key name and value"
1099
  msgstr ""
1100
 
1101
- #: dist/include/meta/class-bulk-delete-user-meta.php:97
1102
- #: include/meta/class-bulk-delete-user-meta.php:97
1103
  msgid "User Meta Key "
1104
  msgstr ""
1105
 
1106
- #: dist/include/meta/class-bulk-delete-user-meta.php:121
1107
- #: include/meta/class-bulk-delete-user-meta.php:121
1108
  msgid "Only delete user meta field from first "
1109
  msgstr ""
1110
 
1111
- #: dist/include/meta/class-bulk-delete-user-meta.php:122
1112
- #: include/meta/class-bulk-delete-user-meta.php:122
1113
  msgid "users."
1114
  msgstr ""
1115
 
1116
- #: dist/include/meta/class-bulk-delete-user-meta.php:123
1117
- #: include/meta/class-bulk-delete-user-meta.php:123
1118
  msgid ""
1119
  "Use this option if there are more than 1000 users and the script timesout."
1120
  msgstr ""
1121
 
1122
- #: dist/include/meta/class-bulk-delete-user-meta.php:178
1123
- #: include/meta/class-bulk-delete-user-meta.php:178
1124
  msgid ""
1125
  "Are you sure you want to delete all the user meta fields that match the "
1126
  "selected filters?"
1127
  msgstr ""
1128
 
1129
- #: dist/include/meta/class-bulk-delete-user-meta.php:215
1130
- #: include/meta/class-bulk-delete-user-meta.php:215
1131
  msgid ""
1132
  "User meta fields from the users with the selected criteria are scheduled for "
1133
  "deletion."
1134
  msgstr ""
1135
 
1136
- #: dist/include/meta/class-bulk-delete-user-meta.php:219
1137
- #: include/meta/class-bulk-delete-user-meta.php:219
1138
  msgid "Deleted user meta field from %d user"
1139
  msgid_plural "Deleted user meta field from %d users"
1140
  msgstr[0] ""
1141
  msgstr[1] ""
1142
 
1143
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:30
1144
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:30
1145
  msgid "Bulk Delete Jetpack Contact Form Messages"
1146
  msgstr ""
1147
 
1148
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:54
1149
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:54
1150
  msgid "Jetpack contact form is not enabled."
1151
  msgstr ""
1152
 
1153
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:70
1154
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:70
1155
  msgid "Delete all Contact Form Messages"
1156
  msgstr ""
1157
 
1158
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:70
1159
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:70
1160
  msgid "in total"
1161
  msgstr ""
1162
 
1163
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:79
1164
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:79
1165
  msgid "Delete Messages based on filters"
1166
  msgstr ""
1167
 
1168
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:96
1169
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:96
1170
  msgid "Choose your date options"
1171
  msgstr ""
1172
 
1173
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:119
1174
- #: dist/include/ui/form.php:100
1175
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:119
1176
- #: include/ui/form.php:100 tmp_addon/bulk-delete-posts-by-attachment.php:200
1177
  #: tmp_addon/bulk-delete-posts-by-content.php:218
1178
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:240
1179
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:177
1180
- #: tmp_addon/bulk-delete-posts-by-title.php:195
1181
  #: tmp_addon/bulk-delete-posts-by-user-role.php:154
1182
  #: tmp_addon/bulk-delete-posts-by-user.php:195
 
1183
  msgid "Only delete first "
1184
  msgstr ""
1185
 
1186
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:133
1187
- #: dist/include/ui/form.php:62
1188
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:133
1189
- #: include/ui/form.php:62 tmp_addon/bulk-delete-posts-by-attachment.php:183
1190
  #: tmp_addon/bulk-delete-posts-by-content.php:203
1191
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:220
1192
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:169
1193
- #: tmp_addon/bulk-delete-posts-by-title.php:186
1194
  #: tmp_addon/bulk-delete-posts-by-user-role.php:146
1195
  #: tmp_addon/bulk-delete-posts-by-user.php:187
 
1196
  msgid "Move to Trash"
1197
  msgstr ""
1198
 
1199
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:134
1200
- #: dist/include/ui/form.php:63
1201
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:134
1202
- #: include/ui/form.php:63 tmp_addon/bulk-delete-posts-by-attachment.php:184
1203
  #: tmp_addon/bulk-delete-posts-by-content.php:204
1204
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:222
1205
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:170
1206
- #: tmp_addon/bulk-delete-posts-by-title.php:188
1207
  #: tmp_addon/bulk-delete-posts-by-user-role.php:147
1208
  #: tmp_addon/bulk-delete-posts-by-user.php:188
 
1209
  msgid "Delete permanently"
1210
  msgstr ""
1211
 
1212
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:181
1213
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:181
1214
  msgid ""
1215
  "Are you sure you want to delete all the Jetpack contact form messages based "
1216
  "on the selected filters?"
1217
  msgstr ""
1218
 
1219
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:220
1220
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:220
1221
  msgid ""
1222
  "Jetpack contact form messages with the selected criteria are scheduled for "
1223
  "deletion."
1224
  msgstr ""
1225
 
1226
- #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:224
1227
- #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:224
1228
  msgid "Deleted %d Jetpack contact form message"
1229
  msgid_plural "Deleted %d Jetpack contact form messages"
1230
  msgstr[0] ""
1231
  msgstr[1] ""
1232
 
1233
- #: dist/include/misc/class-bulk-delete-misc.php:34
1234
- #: dist/include/misc/class-bulk-delete-misc.php:98
1235
- #: include/misc/class-bulk-delete-misc.php:34
1236
- #: include/misc/class-bulk-delete-misc.php:98
1237
- msgid "Bulk Delete Miscellaneous Items"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1238
  msgstr ""
1239
 
1240
  #: dist/include/misc/class-bulk-delete-misc.php:35
 
1241
  #: include/misc/class-bulk-delete-misc.php:35
 
 
 
 
 
 
1242
  msgid "Bulk Delete Misc"
1243
  msgstr ""
1244
 
1245
- #: dist/include/pages/class-bulk-delete-pages.php:35
1246
- #: include/pages/class-bulk-delete-pages.php:35
1247
  msgid "Select the status from which you want to delete pages"
1248
  msgstr ""
1249
 
1250
- #: dist/include/pages/class-bulk-delete-pages.php:42
1251
- #: include/pages/class-bulk-delete-pages.php:42
1252
  msgid "All Published Pages"
1253
  msgstr ""
1254
 
1255
- #: dist/include/pages/class-bulk-delete-pages.php:42
1256
- #: dist/include/pages/class-bulk-delete-pages.php:49
1257
- #: dist/include/pages/class-bulk-delete-pages.php:56
1258
- #: dist/include/pages/class-bulk-delete-pages.php:63
1259
- #: dist/include/pages/class-bulk-delete-pages.php:70
1260
- #: include/pages/class-bulk-delete-pages.php:42
1261
- #: include/pages/class-bulk-delete-pages.php:49
1262
- #: include/pages/class-bulk-delete-pages.php:56
1263
- #: include/pages/class-bulk-delete-pages.php:63
1264
- #: include/pages/class-bulk-delete-pages.php:70
1265
  msgid "Pages"
1266
  msgstr ""
1267
 
1268
- #: dist/include/pages/class-bulk-delete-pages.php:49
1269
- #: include/pages/class-bulk-delete-pages.php:49
1270
  msgid "All Draft Pages"
1271
  msgstr ""
1272
 
1273
- #: dist/include/pages/class-bulk-delete-pages.php:56
1274
- #: include/pages/class-bulk-delete-pages.php:56
1275
  msgid "All Scheduled Pages"
1276
  msgstr ""
1277
 
1278
- #: dist/include/pages/class-bulk-delete-pages.php:63
1279
- #: include/pages/class-bulk-delete-pages.php:63
1280
  msgid "All Pending Pages"
1281
  msgstr ""
1282
 
1283
- #: dist/include/pages/class-bulk-delete-pages.php:70
1284
- #: include/pages/class-bulk-delete-pages.php:70
1285
  msgid "All Private Pages"
1286
  msgstr ""
1287
 
1288
- #: dist/include/pages/class-bulk-delete-pages.php:118
1289
- #: include/pages/class-bulk-delete-pages.php:118
1290
  msgid "The selected pages are scheduled for deletion."
1291
  msgstr ""
1292
 
1293
- #: dist/include/pages/class-bulk-delete-pages.php:122
1294
- #: include/pages/class-bulk-delete-pages.php:122
1295
  msgid "Deleted %d page"
1296
  msgid_plural "Deleted %d pages"
1297
  msgstr[0] ""
1298
  msgstr[1] ""
1299
 
1300
- #: dist/include/posts/class-bulk-delete-posts.php:31
1301
- #: include/posts/class-bulk-delete-posts.php:31
1302
- msgid "Select the post status from which you want to delete posts"
1303
- msgstr ""
1304
-
1305
- #: dist/include/posts/class-bulk-delete-posts.php:38
1306
- #: include/posts/class-bulk-delete-posts.php:38
1307
- msgid "All Published Posts"
1308
- msgstr ""
1309
-
1310
- #: dist/include/posts/class-bulk-delete-posts.php:38
1311
- #: dist/include/posts/class-bulk-delete-posts.php:52
1312
- #: dist/include/posts/class-bulk-delete-posts.php:59
1313
- #: dist/include/posts/class-bulk-delete-posts.php:66
1314
- #: dist/include/posts/class-bulk-delete-posts.php:74
1315
- #: dist/include/posts/class-bulk-delete-posts.php:246
1316
- #: dist/include/posts/class-bulk-delete-posts.php:375
1317
- #: dist/include/posts/class-bulk-delete-posts.php:543
1318
- #: dist/include/ui/form.php:219 include/posts/class-bulk-delete-posts.php:38
1319
- #: include/posts/class-bulk-delete-posts.php:52
1320
- #: include/posts/class-bulk-delete-posts.php:59
1321
- #: include/posts/class-bulk-delete-posts.php:66
1322
- #: include/posts/class-bulk-delete-posts.php:74
1323
- #: include/posts/class-bulk-delete-posts.php:246
1324
- #: include/posts/class-bulk-delete-posts.php:375
1325
- #: include/posts/class-bulk-delete-posts.php:543
1326
  msgid "Posts"
1327
  msgstr ""
1328
 
1329
- #: dist/include/posts/class-bulk-delete-posts.php:45
1330
- #: include/posts/class-bulk-delete-posts.php:45
1331
- msgid "All Draft Posts"
1332
- msgstr ""
1333
-
1334
- #: dist/include/posts/class-bulk-delete-posts.php:45
1335
- #: include/posts/class-bulk-delete-posts.php:45
1336
- msgid "Drafts"
1337
- msgstr ""
1338
-
1339
- #: dist/include/posts/class-bulk-delete-posts.php:52
1340
- #: include/posts/class-bulk-delete-posts.php:52
1341
- msgid "All Pending Posts"
1342
- msgstr ""
1343
-
1344
- #: dist/include/posts/class-bulk-delete-posts.php:59
1345
- #: include/posts/class-bulk-delete-posts.php:59
1346
- msgid "All Scheduled Posts"
1347
- msgstr ""
1348
-
1349
- #: dist/include/posts/class-bulk-delete-posts.php:66
1350
- #: include/posts/class-bulk-delete-posts.php:66
1351
- msgid "All Private Posts"
1352
- msgstr ""
1353
-
1354
- #: dist/include/posts/class-bulk-delete-posts.php:74
1355
- #: include/posts/class-bulk-delete-posts.php:74
1356
  msgid "All Sticky Posts"
1357
  msgstr ""
1358
 
1359
- #: dist/include/posts/class-bulk-delete-posts.php:75
1360
- #: include/posts/class-bulk-delete-posts.php:75
1361
  msgid "Note"
1362
  msgstr ""
1363
 
1364
- #: dist/include/posts/class-bulk-delete-posts.php:75
1365
- #: include/posts/class-bulk-delete-posts.php:75
1366
  msgid "The date filter will not work for sticky posts"
1367
  msgstr ""
1368
 
1369
- #: dist/include/posts/class-bulk-delete-posts.php:125
1370
- #: include/posts/class-bulk-delete-posts.php:125
1371
  msgid "Posts with the selected status are scheduled for deletion."
1372
  msgstr ""
1373
 
1374
- #: dist/include/posts/class-bulk-delete-posts.php:129
1375
- #: include/posts/class-bulk-delete-posts.php:129
 
1376
  msgid "Deleted %d post with the selected post status"
1377
  msgid_plural "Deleted %d posts with the selected post status"
1378
  msgstr[0] ""
1379
  msgstr[1] ""
1380
 
1381
- #: dist/include/posts/class-bulk-delete-posts.php:226
1382
- #: include/posts/class-bulk-delete-posts.php:226
1383
  msgid "Select the post type from which you want to delete posts by category"
1384
  msgstr ""
1385
 
1386
- #: dist/include/posts/class-bulk-delete-posts.php:232
1387
- #: include/posts/class-bulk-delete-posts.php:232
1388
  msgid "Select the categories from which you wan to delete posts"
1389
  msgstr ""
1390
 
1391
- #: dist/include/posts/class-bulk-delete-posts.php:233
1392
- #: include/posts/class-bulk-delete-posts.php:233
1393
  msgid ""
1394
  "Note: The post count below for each category is the total number of posts in "
1395
  "that category, irrespective of post type"
1396
  msgstr ""
1397
 
1398
- #: dist/include/posts/class-bulk-delete-posts.php:243
1399
- #: include/posts/class-bulk-delete-posts.php:243
1400
  msgid "Select Categories"
1401
  msgstr ""
1402
 
1403
- #: dist/include/posts/class-bulk-delete-posts.php:244
1404
- #: include/posts/class-bulk-delete-posts.php:244
1405
  msgid "All Categories"
1406
  msgstr ""
1407
 
1408
- #: dist/include/posts/class-bulk-delete-posts.php:296
1409
- #: include/posts/class-bulk-delete-posts.php:296
1410
  msgid "Posts from the selected categories are scheduled for deletion."
1411
  msgstr ""
1412
 
1413
- #: dist/include/posts/class-bulk-delete-posts.php:300
1414
- #: include/posts/class-bulk-delete-posts.php:300
1415
  msgid "Deleted %d post from the selected categories"
1416
  msgid_plural "Deleted %d posts from the selected categories"
1417
  msgstr[0] ""
1418
  msgstr[1] ""
1419
 
1420
- #: dist/include/posts/class-bulk-delete-posts.php:365
1421
- #: include/posts/class-bulk-delete-posts.php:365
1422
  msgid "Select the tags from which you want to delete posts"
1423
  msgstr ""
1424
 
1425
- #: dist/include/posts/class-bulk-delete-posts.php:372
1426
- #: include/posts/class-bulk-delete-posts.php:372
1427
  msgid "Select Tags"
1428
  msgstr ""
1429
 
1430
- #: dist/include/posts/class-bulk-delete-posts.php:373
1431
- #: include/posts/class-bulk-delete-posts.php:373
1432
  msgid "All Tags"
1433
  msgstr ""
1434
 
1435
- #: dist/include/posts/class-bulk-delete-posts.php:395
1436
- #: include/posts/class-bulk-delete-posts.php:395
1437
  msgid "You don't have any posts assigned to tags in this blog."
1438
  msgstr ""
1439
 
1440
- #: dist/include/posts/class-bulk-delete-posts.php:426
1441
- #: include/posts/class-bulk-delete-posts.php:426
1442
  msgid "Posts from the selected tags are scheduled for deletion."
1443
  msgstr ""
1444
 
1445
- #: dist/include/posts/class-bulk-delete-posts.php:430
1446
- #: include/posts/class-bulk-delete-posts.php:430
1447
  msgid "Deleted %d post from the selected tags"
1448
  msgid_plural "Deleted %d posts from the selected tags"
1449
  msgstr[0] ""
1450
  msgstr[1] ""
1451
 
1452
- #: dist/include/posts/class-bulk-delete-posts.php:503
1453
- #: include/posts/class-bulk-delete-posts.php:503
1454
  msgid ""
1455
  "Select the post type from which you want to delete posts by custom taxonomy"
1456
  msgstr ""
1457
 
1458
- #: dist/include/posts/class-bulk-delete-posts.php:510
1459
- #: include/posts/class-bulk-delete-posts.php:510
1460
  msgid "Select the taxonomies from which you want to delete posts"
1461
  msgstr ""
1462
 
1463
- #: dist/include/posts/class-bulk-delete-posts.php:529
1464
- #: include/posts/class-bulk-delete-posts.php:529
1465
  msgid ""
1466
  "The selected taxonomy has the following terms. Select the terms from which "
1467
  "you want to delete posts"
1468
  msgstr ""
1469
 
1470
- #: dist/include/posts/class-bulk-delete-posts.php:530
1471
- #: include/posts/class-bulk-delete-posts.php:530
1472
  msgid ""
1473
  "Note: The post count below for each term is the total number of posts in "
1474
  "that term, irrespective of post type"
1475
  msgstr ""
1476
 
1477
- #: dist/include/posts/class-bulk-delete-posts.php:567
1478
- #: include/posts/class-bulk-delete-posts.php:567
1479
  msgid ""
1480
  "This WordPress installation doesn't have any non-empty custom taxonomies "
1481
  "defined"
1482
  msgstr ""
1483
 
1484
- #: dist/include/posts/class-bulk-delete-posts.php:600
1485
- #: include/posts/class-bulk-delete-posts.php:600
1486
  msgid "Posts from the selected custom taxonomies are scheduled for deletion."
1487
  msgstr ""
1488
 
1489
- #: dist/include/posts/class-bulk-delete-posts.php:604
1490
- #: include/posts/class-bulk-delete-posts.php:604
1491
  msgid "Deleted %d post from the selected custom taxonomies"
1492
  msgid_plural "Deleted %d posts from the selected custom taxonomies"
1493
  msgstr[0] ""
1494
  msgstr[1] ""
1495
 
1496
- #: dist/include/posts/class-bulk-delete-posts.php:705
1497
- #: include/posts/class-bulk-delete-posts.php:705
1498
  msgid "Select the custom post types from which you want to delete posts"
1499
  msgstr ""
1500
 
1501
- #: dist/include/posts/class-bulk-delete-posts.php:734
1502
- #: include/posts/class-bulk-delete-posts.php:734
1503
  msgid ""
1504
  "This WordPress installation doesn't have any non-empty custom post types"
1505
  msgstr ""
1506
 
1507
- #: dist/include/posts/class-bulk-delete-posts.php:765
1508
- #: include/posts/class-bulk-delete-posts.php:765
1509
  msgid "Posts from the selected custom post type are scheduled for deletion."
1510
  msgstr ""
1511
 
1512
- #: dist/include/posts/class-bulk-delete-posts.php:769
1513
- #: include/posts/class-bulk-delete-posts.php:769
1514
  msgid "Deleted %d post from the selected custom post type"
1515
  msgid_plural "Deleted %d posts from the selected custom post type"
1516
  msgstr[0] ""
1517
  msgstr[1] ""
1518
 
1519
- #: dist/include/posts/class-bulk-delete-posts.php:841
1520
- #: include/posts/class-bulk-delete-posts.php:841
1521
  msgid "Delete posts and pages that have the following Permalink"
1522
  msgstr ""
1523
 
1524
- #: dist/include/posts/class-bulk-delete-posts.php:847
1525
- #: include/posts/class-bulk-delete-posts.php:847
1526
  msgid "Enter one post url (not post ids) per line"
1527
  msgstr ""
1528
 
1529
- #: dist/include/posts/class-bulk-delete-posts.php:882
1530
- #: include/posts/class-bulk-delete-posts.php:882
1531
  msgid "Deleted %d post with the specified urls"
1532
  msgid_plural "Deleted %d posts with the specified urls"
1533
  msgstr[0] ""
1534
  msgstr[1] ""
1535
 
1536
- #: dist/include/posts/class-bulk-delete-posts.php:908
1537
- #: include/posts/class-bulk-delete-posts.php:908
1538
  msgid "Select the posts which you want to delete"
1539
  msgstr ""
1540
 
1541
- #: dist/include/posts/class-bulk-delete-posts.php:915
1542
- #: include/posts/class-bulk-delete-posts.php:915
1543
  msgid "All Revisions"
1544
  msgstr ""
1545
 
1546
- #: dist/include/posts/class-bulk-delete-posts.php:915
1547
- #: include/posts/class-bulk-delete-posts.php:915
1548
  msgid "Revisions"
1549
  msgstr ""
1550
 
1551
- #: dist/include/posts/class-bulk-delete-posts.php:936
1552
- #: include/posts/class-bulk-delete-posts.php:936
1553
  msgid "Deleted %d post revision"
1554
  msgid_plural "Deleted %d post revisions"
1555
  msgstr[0] ""
1556
  msgstr[1] ""
1557
 
1558
- #: dist/include/posts/class-bulk-delete-posts.php:980
1559
- #: include/posts/class-bulk-delete-posts.php:980
1560
  msgid ""
1561
  "Are you sure you want to delete all the posts based on the selected option?"
1562
  msgstr ""
1563
 
1564
- #: dist/include/posts/class-bulk-delete-posts.php:981
1565
- #: include/posts/class-bulk-delete-posts.php:981
1566
  msgid "Please select posts from at least one option"
1567
  msgstr ""
1568
 
1569
- #: dist/include/posts/class-bulk-delete-posts.php:985
1570
- #: include/posts/class-bulk-delete-posts.php:985
1571
  msgid "Please select at least one category"
1572
  msgstr ""
1573
 
1574
- #: dist/include/posts/class-bulk-delete-posts.php:989
1575
- #: include/posts/class-bulk-delete-posts.php:989
1576
  msgid "Please select at least one tag"
1577
  msgstr ""
1578
 
1579
- #: dist/include/posts/class-bulk-delete-posts.php:993
1580
- #: include/posts/class-bulk-delete-posts.php:993
1581
  msgid "Please enter at least one post url"
1582
  msgstr ""
1583
 
1584
- #: dist/include/posts/class-bulk-delete-posts.php:1017
1585
- #: include/posts/class-bulk-delete-posts.php:1017
1586
  msgid "The selected scheduled job was successfully deleted "
1587
  msgstr ""
1588
 
1589
- #: dist/include/settings/class-bd-settings-page.php:46
1590
- #: dist/include/settings/class-bd-settings-page.php:94
1591
- #: include/settings/class-bd-settings-page.php:46
1592
- #: include/settings/class-bd-settings-page.php:94
1593
  msgid "Bulk Delete Settings"
1594
  msgstr ""
1595
 
1596
- #: dist/include/settings/class-bd-settings-page.php:47
1597
- #: include/settings/class-bd-settings-page.php:47
1598
  msgid "Settings"
1599
  msgstr ""
1600
 
@@ -1603,50 +1669,50 @@ msgstr ""
1603
  msgid "Add Addon License"
1604
  msgstr ""
1605
 
1606
- #: dist/include/system-info/class-bd-system-info-page.php:49
1607
- #: include/system-info/class-bd-system-info-page.php:49
1608
  msgid "Bulk Delete - System Info"
1609
  msgstr ""
1610
 
1611
- #: dist/include/system-info/class-bd-system-info-page.php:50
1612
- #: include/system-info/class-bd-system-info-page.php:50
1613
  msgid "System Info"
1614
  msgstr ""
1615
 
1616
- #: dist/include/system-info/class-bd-system-info-page.php:54
1617
- #: include/system-info/class-bd-system-info-page.php:54
1618
  msgid "Please include this information when posting support requests."
1619
  msgstr ""
1620
 
1621
- #: dist/include/system-info/class-bd-system-info-page.php:74
1622
- #: include/system-info/class-bd-system-info-page.php:74
1623
  msgid ""
1624
  "SAVEQUERIES is <a href=\"%s\" target=\"_blank\">enabled</a>. This puts "
1625
  "additional load on the memory and will restrict the number of items that can "
1626
  "be deleted."
1627
  msgstr ""
1628
 
1629
- #: dist/include/system-info/class-bd-system-info-page.php:82
1630
- #: include/system-info/class-bd-system-info-page.php:82
1631
  msgid ""
1632
  "DISABLE_WP_CRON is <a href=\"%s\" target=\"_blank\">enabled</a>. This "
1633
  "prevents scheduler from running."
1634
  msgstr ""
1635
 
1636
- #: dist/include/system-info/class-bd-system-info-page.php:100
1637
- #: include/system-info/class-bd-system-info-page.php:99
1638
  msgid ""
1639
  "To copy the system info, click below then press Ctrl + C (PC) or Cmd + C "
1640
  "(Mac)."
1641
  msgstr ""
1642
 
1643
- #: dist/include/ui/admin-ui.php:20 include/ui/admin-ui.php:20
1644
  msgid ""
1645
  "Thank you for using <a href = \"%1$s\">Bulk Delete</a> plugin! Kindly <a "
1646
  "href = \"%2$s\">rate us</a> at <a href = \"%2$s\">WordPress.org</a>"
1647
  msgstr ""
1648
 
1649
- #: dist/include/ui/admin-ui.php:70 include/ui/admin-ui.php:70
1650
  msgid "Buy Addons"
1651
  msgstr ""
1652
 
@@ -1675,262 +1741,195 @@ msgstr ""
1675
  msgid "Other Plugin's by Author"
1676
  msgstr ""
1677
 
1678
- #: dist/include/ui/class-bulk-delete-help-screen.php:58
1679
- #: dist/include/ui/class-bulk-delete-help-screen.php:70
1680
- #: dist/include/users/class-bd-users-page.php:83
1681
- #: include/ui/class-bulk-delete-help-screen.php:58
1682
- #: include/ui/class-bulk-delete-help-screen.php:70
1683
- #: include/users/class-bd-users-page.php:83
1684
  #: tmp_addon/class-bd-attachment-page.php:62
1685
  msgid "Overview"
1686
  msgstr ""
1687
 
1688
- #: dist/include/ui/class-bulk-delete-help-screen.php:60
1689
- #: include/ui/class-bulk-delete-help-screen.php:60
1690
  msgid ""
1691
  "This screen contains different modules that allows you to delete posts or "
1692
  "schedule them for deletion."
1693
  msgstr ""
1694
 
1695
- #: dist/include/ui/class-bulk-delete-help-screen.php:72
1696
- #: include/ui/class-bulk-delete-help-screen.php:72
1697
  msgid ""
1698
  "This screen contains different modules that allows you to delete pages or "
1699
  "schedule them for deletion."
1700
  msgstr ""
1701
 
1702
- #: dist/include/ui/class-bulk-delete-help-screen.php:82
1703
- #: include/ui/class-bulk-delete-help-screen.php:82
1704
  msgid "About Plugin"
1705
  msgstr ""
1706
 
1707
- #: dist/include/ui/class-bulk-delete-help-screen.php:105
1708
- #: include/ui/class-bulk-delete-help-screen.php:105
1709
  msgid "This plugin allows you to perform bulk operations in WordPress easily."
1710
  msgstr ""
1711
 
1712
- #: dist/include/ui/class-bulk-delete-help-screen.php:106
1713
- #: include/ui/class-bulk-delete-help-screen.php:106
1714
  msgid ""
1715
  "This plugin can be used to delete the posts, pages or users using various "
1716
  "filters and conditions."
1717
  msgstr ""
1718
 
1719
- #: dist/include/ui/form.php:21 include/ui/form.php:21
1720
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:123
1721
- #: tmp_addon/bulk-delete-posts-by-attachment.php:163
1722
- #: tmp_addon/bulk-delete-posts-by-content.php:186
1723
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:198
1724
- #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:163
1725
- #: tmp_addon/bulk-delete-posts-by-title.php:166
1726
- #: tmp_addon/bulk-delete-posts-by-user-role.php:130
1727
- #: tmp_addon/bulk-delete-posts-by-user.php:171
1728
- msgid "Choose your filtering options"
1729
- msgstr ""
1730
-
1731
- #: dist/include/ui/form.php:41 include/ui/form.php:41
1732
  msgid "Only restrict to %s which are "
1733
  msgstr ""
1734
 
1735
- #: dist/include/ui/form.php:79 include/ui/form.php:79
1736
  #: tmp_addon/bulk-delete-posts-by-attachment.php:190
1737
  #: tmp_addon/bulk-delete-posts-by-content.php:210
1738
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:229
 
1739
  msgid "Public posts"
1740
  msgstr ""
1741
 
1742
- #: dist/include/ui/form.php:80 include/ui/form.php:80
1743
  #: tmp_addon/bulk-delete-posts-by-attachment.php:191
1744
  #: tmp_addon/bulk-delete-posts-by-content.php:211
1745
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:231
 
1746
  msgid "Private Posts"
1747
  msgstr ""
1748
 
1749
- #: dist/include/ui/form.php:102 include/ui/form.php:102
1750
  msgid "Use this option if there are more than 1000 %s and the script timesout."
1751
  msgstr ""
1752
 
1753
- #: dist/include/ui/form.php:138 include/ui/form.php:138
1754
  msgid ""
1755
  "Enter time in <strong>Y-m-d H:i:s</strong> format or enter <strong>now</"
1756
  "strong> to use current time"
1757
  msgstr ""
1758
 
1759
- #: dist/include/ui/form.php:219 dist/include/util/class-bd-util.php:255
1760
- #: include/util/class-bd-util.php:255
1761
  msgid "All"
1762
  msgstr ""
1763
 
1764
- #: dist/include/users/class-bd-users-page.php:46
1765
- #: dist/include/users/class-bd-users-page.php:47
1766
- #: dist/include/users/class-bd-users-page.php:69
1767
- #: include/users/class-bd-users-page.php:46
1768
- #: include/users/class-bd-users-page.php:47
1769
- #: include/users/class-bd-users-page.php:69
1770
  msgid "Bulk Delete Users"
1771
  msgstr ""
1772
 
1773
- #: dist/include/users/class-bd-users-page.php:51
1774
- #: include/users/class-bd-users-page.php:51
1775
  msgid "WARNING: Users deleted once cannot be retrieved back. Use with caution."
1776
  msgstr ""
1777
 
1778
- #: dist/include/users/class-bd-users-page.php:85
1779
- #: include/users/class-bd-users-page.php:85
1780
  #: tmp_addon/class-bd-attachment-page.php:64
1781
  msgid ""
1782
  "This screen contains different modules that allows you to delete users or "
1783
  "schedule them for deletion."
1784
  msgstr ""
1785
 
1786
- #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:48
1787
- #: include/users/modules/class-bulk-delete-users-by-user-meta.php:48
1788
  msgid "By User Meta"
1789
  msgstr ""
1790
 
1791
- #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:49
1792
- #: include/users/modules/class-bulk-delete-users-by-user-meta.php:49
1793
  msgid "Users from with the selected user meta are scheduled for deletion."
1794
  msgstr ""
1795
 
1796
- #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:50
1797
- #: include/users/modules/class-bulk-delete-users-by-user-meta.php:50
1798
  msgid "Deleted %d user with the selected user meta"
1799
  msgstr ""
1800
 
1801
- #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:51
1802
- #: include/users/modules/class-bulk-delete-users-by-user-meta.php:51
1803
  msgid "Deleted %d users with the selected user meta"
1804
  msgstr ""
1805
 
1806
- #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:63
1807
- #: include/users/modules/class-bulk-delete-users-by-user-meta.php:63
1808
  msgid "Select the user meta from which you want to delete users"
1809
  msgstr ""
1810
 
1811
- #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:83
1812
- #: include/users/modules/class-bulk-delete-users-by-user-meta.php:83
1813
  #: tmp_addon/bulk-delete-comment-meta.php:145
1814
  #: tmp_addon/bulk-delete-post-meta.php:145
1815
  #: tmp_addon/bulk-delete-user-meta.php:145
1816
  msgid "Meta Value"
1817
  msgstr ""
1818
 
1819
- #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:88
1820
- #: include/users/modules/class-bulk-delete-users-by-user-meta.php:88
1821
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:192
1822
  msgid "If you want to check for null values, then leave the value column blank"
1823
  msgstr ""
1824
 
1825
- #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:161
1826
- #: include/users/modules/class-bulk-delete-users-by-user-meta.php:161
1827
  msgid ""
1828
  "Are you sure you want to delete all the users from the selected user meta?"
1829
  msgstr ""
1830
 
1831
- #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:164
1832
- #: include/users/modules/class-bulk-delete-users-by-user-meta.php:164
1833
  msgid ""
1834
  "Please enter the value for the user meta field based on which you want to "
1835
  "delete users"
1836
  msgstr ""
1837
 
1838
- #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:49
1839
- #: include/users/modules/class-bulk-delete-users-by-user-role.php:49
1840
  msgid "Users from the selected userrole are scheduled for deletion."
1841
  msgstr ""
1842
 
1843
- #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:50
1844
- #: include/users/modules/class-bulk-delete-users-by-user-role.php:50
1845
  msgid "Deleted %d user from the selected roles"
1846
  msgstr ""
1847
 
1848
- #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:51
1849
- #: include/users/modules/class-bulk-delete-users-by-user-role.php:51
1850
  msgid "Deleted %d users from the selected roles"
1851
  msgstr ""
1852
 
1853
- #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:63
1854
- #: include/users/modules/class-bulk-delete-users-by-user-role.php:63
1855
  msgid "Select the user roles from which you want to delete users"
1856
  msgstr ""
1857
 
1858
- #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:146
1859
- #: include/users/modules/class-bulk-delete-users-by-user-role.php:146
1860
  msgid ""
1861
  "Are you sure you want to delete all the users from the selected user role?"
1862
  msgstr ""
1863
 
1864
- #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:149
1865
- #: include/users/modules/class-bulk-delete-users-by-user-role.php:149
1866
  msgid "Select at least one user role from which users should be deleted"
1867
  msgstr ""
1868
 
1869
- #: dist/include/util/class-bd-util.php:110 include/util/class-bd-util.php:110
1870
  msgctxt "Cron table date format"
1871
  msgid "M j, Y @ G:i"
1872
  msgstr ""
1873
 
1874
- #: dist/include/util/class-bd-util.php:247 include/util/class-bd-util.php:247
1875
  msgid "All mime types"
1876
  msgstr ""
1877
 
1878
- #: include/libraries/EDD_SL_Plugin_Updater.php:181
1879
- msgid ""
1880
- "There is a new version of %1$s available. <a target=\"_blank\" class="
1881
- "\"thickbox\" href=\"%2$s\">View version %3$s details</a>."
1882
- msgstr ""
1883
-
1884
- #: include/libraries/EDD_SL_Plugin_Updater.php:188
1885
- msgid ""
1886
- "There is a new version of %1$s available. <a target=\"_blank\" class="
1887
- "\"thickbox\" href=\"%2$s\">View version %3$s details</a> or <a href=\"%4$s"
1888
- "\">update now</a>."
1889
- msgstr ""
1890
-
1891
- #: node_modules/grunt-wp-i18n/test/fixtures/basic-theme/exclude/file.php:3
1892
- #: node_modules/grunt-wp-i18n/test/fixtures/plugin-include/plugin-include.php:6
1893
- msgid "Exclude"
1894
- msgstr ""
1895
-
1896
- #: node_modules/grunt-wp-i18n/test/fixtures/plugin-include/include/file.php:2
1897
- msgid "Include"
1898
- msgstr ""
1899
-
1900
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/add-domain.php:2
1901
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-all-domains.php:2
1902
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-all-domains.php:3
1903
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-all-domains.php:4
1904
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-domains.php:2
1905
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-domains.php:3
1906
- msgid "String"
1907
- msgstr ""
1908
-
1909
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-all-domains.php:6
1910
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-all-domains.php:7
1911
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-all-domains.php:8
1912
- msgctxt "a string"
1913
- msgid "String"
1914
- msgstr ""
1915
-
1916
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-all-domains.php:9
1917
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-all-domains.php:10
1918
- #: node_modules/grunt-wp-i18n/test/fixtures/text-domains/update-all-domains.php:11
1919
- msgid "1 Star"
1920
- msgid_plural "%s Stars"
1921
- msgstr[0] ""
1922
- msgstr[1] ""
1923
-
1924
- #. translators: A single line translators comment.
1925
- #: node_modules/grunt-wp-i18n/test/fixtures/translator-comments/translator-comments.php:7
1926
- msgid "A"
1927
- msgstr ""
1928
-
1929
- #. translators: A multiline translators comment.
1930
- #: node_modules/grunt-wp-i18n/test/fixtures/translator-comments/translator-comments.php:15
1931
- msgid "B"
1932
- msgstr ""
1933
-
1934
  #: tmp_addon/bulk-delete-comment-meta.php:123
1935
  msgid "Comment Meta Value "
1936
  msgstr ""
@@ -1938,7 +1937,8 @@ msgstr ""
1938
  #: tmp_addon/bulk-delete-comment-meta.php:125
1939
  #: tmp_addon/bulk-delete-post-meta.php:125
1940
  #: tmp_addon/bulk-delete-posts-by-content.php:165
1941
- #: tmp_addon/bulk-delete-posts-by-title.php:137
 
1942
  #: tmp_addon/bulk-delete-user-meta.php:125
1943
  msgid "equal to"
1944
  msgstr ""
@@ -1946,13 +1946,14 @@ msgstr ""
1946
  #: tmp_addon/bulk-delete-comment-meta.php:126
1947
  #: tmp_addon/bulk-delete-post-meta.php:126
1948
  #: tmp_addon/bulk-delete-posts-by-content.php:166
1949
- #: tmp_addon/bulk-delete-posts-by-title.php:138
1950
  #: tmp_addon/bulk-delete-user-meta.php:126
1951
  msgid "not equal to"
1952
  msgstr ""
1953
 
1954
  #: tmp_addon/bulk-delete-comment-meta.php:127
1955
  #: tmp_addon/bulk-delete-post-meta.php:127
 
1956
  #: tmp_addon/bulk-delete-user-meta.php:127
1957
  msgid "less than"
1958
  msgstr ""
@@ -1965,6 +1966,7 @@ msgstr ""
1965
 
1966
  #: tmp_addon/bulk-delete-comment-meta.php:129
1967
  #: tmp_addon/bulk-delete-post-meta.php:129
 
1968
  #: tmp_addon/bulk-delete-user-meta.php:129
1969
  msgid "greater than"
1970
  msgstr ""
@@ -2047,11 +2049,12 @@ msgstr ""
2047
  #: tmp_addon/bulk-delete-post-meta.php:213
2048
  #: tmp_addon/bulk-delete-posts-by-attachment.php:377
2049
  #: tmp_addon/bulk-delete-posts-by-content.php:388
2050
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:495
2051
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:367
2052
- #: tmp_addon/bulk-delete-posts-by-title.php:425
2053
  #: tmp_addon/bulk-delete-posts-by-user-role.php:325
2054
  #: tmp_addon/bulk-delete-posts-by-user.php:335
 
2055
  #: tmp_addon/bulk-delete-scheduler-email.php:335
2056
  #: tmp_addon/bulk-delete-scheduler-for-deleting-pages-by-status.php:108
2057
  #: tmp_addon/bulk-delete-scheduler-for-deleting-posts-by-attachment.php:114
@@ -2151,42 +2154,6 @@ msgstr ""
2151
  msgid "in the last"
2152
  msgstr ""
2153
 
2154
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:132
2155
- msgid "Only if author name "
2156
- msgstr ""
2157
-
2158
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:134
2159
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:148
2160
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:162
2161
- msgid "is"
2162
- msgstr ""
2163
-
2164
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:135
2165
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:149
2166
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:163
2167
- msgid "is not"
2168
- msgstr ""
2169
-
2170
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:137
2171
- msgid "Author Name"
2172
- msgstr ""
2173
-
2174
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:146
2175
- msgid "Only if author email "
2176
- msgstr ""
2177
-
2178
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:151
2179
- msgid "Author Email"
2180
- msgstr ""
2181
-
2182
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:160
2183
- msgid "Only if author ip "
2184
- msgstr ""
2185
-
2186
- #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:165
2187
- msgid "Author ip"
2188
- msgstr ""
2189
-
2190
  #: tmp_addon/bulk-delete-post-meta.php:123
2191
  msgid "Post Meta Value "
2192
  msgstr ""
@@ -2196,7 +2163,7 @@ msgid "By Attachment"
2196
  msgstr ""
2197
 
2198
  #: tmp_addon/bulk-delete-posts-by-attachment.php:129
2199
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:140
2200
  msgid "Select the post type whose posts you want to delete"
2201
  msgstr ""
2202
 
@@ -2229,14 +2196,17 @@ msgid "By Content"
2229
  msgstr ""
2230
 
2231
  #: tmp_addon/bulk-delete-posts-by-content.php:135
 
2232
  msgid "Select the fields to check for"
2233
  msgstr ""
2234
 
2235
  #: tmp_addon/bulk-delete-posts-by-content.php:140
 
2236
  msgid "Check only Post Content"
2237
  msgstr ""
2238
 
2239
  #: tmp_addon/bulk-delete-posts-by-content.php:145
 
2240
  msgid "Check only Post Title"
2241
  msgstr ""
2242
 
@@ -2253,22 +2223,22 @@ msgid "Specify your content"
2253
  msgstr ""
2254
 
2255
  #: tmp_addon/bulk-delete-posts-by-content.php:167
2256
- #: tmp_addon/bulk-delete-posts-by-title.php:139
2257
  msgid "contains"
2258
  msgstr ""
2259
 
2260
  #: tmp_addon/bulk-delete-posts-by-content.php:168
2261
- #: tmp_addon/bulk-delete-posts-by-title.php:140
2262
  msgid "doesn't contains"
2263
  msgstr ""
2264
 
2265
  #: tmp_addon/bulk-delete-posts-by-content.php:169
2266
- #: tmp_addon/bulk-delete-posts-by-title.php:141
2267
  msgid "starts with"
2268
  msgstr ""
2269
 
2270
  #: tmp_addon/bulk-delete-posts-by-content.php:170
2271
- #: tmp_addon/bulk-delete-posts-by-title.php:142
2272
  msgid "ends with"
2273
  msgstr ""
2274
 
@@ -2289,16 +2259,19 @@ msgid "Separate multiple phrases by comma (,)"
2289
  msgstr ""
2290
 
2291
  #: tmp_addon/bulk-delete-posts-by-content.php:291
 
2292
  msgid "Posts matching the selected content setting are scheduled for deletion."
2293
  msgstr ""
2294
 
2295
  #: tmp_addon/bulk-delete-posts-by-content.php:295
 
2296
  msgid "Deleted %d post using the selected content condition"
2297
  msgid_plural "Deleted %d posts using the selected content condition"
2298
  msgstr[0] ""
2299
  msgstr[1] ""
2300
 
2301
  #: tmp_addon/bulk-delete-posts-by-content.php:366
 
2302
  msgid ""
2303
  "Are you sure you want to delete all the posts that match the selected "
2304
  "content criteria?"
@@ -2308,80 +2281,136 @@ msgstr ""
2308
  msgid "Please enter the content based on which you want to delete posts"
2309
  msgstr ""
2310
 
2311
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:159
2312
  msgid "Choose your custom field settings"
2313
  msgstr ""
2314
 
2315
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:163
2316
  msgid "Key "
2317
  msgstr ""
2318
 
2319
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:166
2320
  msgid "equal to (string)"
2321
  msgstr ""
2322
 
2323
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:167
2324
  msgid "not equal to (string)"
2325
  msgstr ""
2326
 
2327
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:168
2328
  msgid "equal to (date)"
2329
  msgstr ""
2330
 
2331
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:169
2332
  msgid "not equal to (date)"
2333
  msgstr ""
2334
 
2335
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:170
2336
  msgid "less than (date)"
2337
  msgstr ""
2338
 
2339
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:171
2340
  msgid "greater than (date)"
2341
  msgstr ""
2342
 
2343
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:172
2344
  msgid "less than (number)"
2345
  msgstr ""
2346
 
2347
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:173
2348
  msgid "greater than (number)"
2349
  msgstr ""
2350
 
2351
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:175
2352
  msgid "Value "
2353
  msgstr ""
2354
 
2355
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:182
2356
- msgid "Enter the Date Format "
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2357
  msgstr ""
2358
 
2359
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:185
2360
- msgid "Possible Values"
2361
  msgstr ""
2362
 
2363
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:186
2364
- msgid "If you leave date format blank, then \"YYYYMMDD\", will be assumed"
2365
  msgstr ""
2366
 
2367
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:325
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2368
  msgid ""
2369
  "Posts matching the selected custom field setting are scheduled for deletion."
2370
  msgstr ""
2371
 
2372
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:330
2373
  msgid "Deleted %d post using the selected custom field condition"
2374
  msgid_plural "Deleted %d posts using the selected custom field condition"
2375
  msgstr[0] ""
2376
  msgstr[1] ""
2377
 
2378
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:404
2379
  msgid ""
2380
  "Are you sure you want to delete all the posts that match the entered custom "
2381
  "field condition?"
2382
  msgstr ""
2383
 
2384
- #: tmp_addon/bulk-delete-posts-by-custom-field.php:407
2385
  msgid "Please enter the custom field based on which you want to delete posts"
2386
  msgstr ""
2387
 
@@ -2424,7 +2453,7 @@ msgid ""
2424
  msgstr ""
2425
 
2426
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:261
2427
- #: tmp_addon/bulk-delete-posts-by-title.php:280
2428
  msgid "Deleted %d post using the selected title condition"
2429
  msgid_plural "Deleted %d posts using the selected title condition"
2430
  msgstr[0] ""
@@ -2435,32 +2464,32 @@ msgid ""
2435
  "Are you sure you want to delete all the posts that have duplicate title?"
2436
  msgstr ""
2437
 
2438
- #: tmp_addon/bulk-delete-posts-by-title.php:129
 
 
 
 
2439
  msgid "Choose your title settings"
2440
  msgstr ""
2441
 
2442
- #: tmp_addon/bulk-delete-posts-by-title.php:135
2443
  msgid "Title"
2444
  msgstr ""
2445
 
2446
  #: tmp_addon/bulk-delete-posts-by-title.php:150
2447
- msgid "Select the post type"
2448
- msgstr ""
2449
-
2450
- #: tmp_addon/bulk-delete-posts-by-title.php:158
2451
  msgid "Select the post status"
2452
  msgstr ""
2453
 
2454
- #: tmp_addon/bulk-delete-posts-by-title.php:276
2455
  msgid "Posts matching the selected title setting are scheduled for deletion."
2456
  msgstr ""
2457
 
2458
- #: tmp_addon/bulk-delete-posts-by-title.php:403
2459
  msgid ""
2460
  "Are you sure you want to delete all the posts that match the entered title?"
2461
  msgstr ""
2462
 
2463
- #: tmp_addon/bulk-delete-posts-by-title.php:406
2464
  msgid "Please enter the title based on which you want to delete posts"
2465
  msgstr ""
2466
 
@@ -2522,6 +2551,30 @@ msgid ""
2522
  "Are you sure you want to delete all the posts belonging to the selected user?"
2523
  msgstr ""
2524
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2525
  #: tmp_addon/bulk-delete-scheduler-email.php:91
2526
  msgid "Scheduler Email Settings"
2527
  msgstr ""
2
  # This file is distributed under the same license as the Bulk Delete package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Bulk Delete 5.6.0\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/bulk-delete\n"
7
+ "POT-Creation-Date: 2017-12-28 12:34:38+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
12
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
 
15
+ #: bulk-delete.php:177 bulk-delete.php:190 dist/bulk-delete.php:177
16
+ #: dist/bulk-delete.php:190
17
  msgid "Cheatin&#8217; huh?"
18
  msgstr ""
19
 
20
+ #: bulk-delete.php:341 dist/bulk-delete.php:311
21
  msgid "Bulk WP"
22
  msgstr ""
23
 
24
+ #: bulk-delete.php:343 bulk-delete.php:529 dist/bulk-delete.php:313
25
+ #: dist/bulk-delete.php:499 dist/include/ui/admin-ui.php:55
26
+ #: include/ui/admin-ui.php:55
27
  msgid "Bulk Delete Posts"
28
  msgstr ""
29
 
30
+ #: bulk-delete.php:344 bulk-delete.php:578 dist/bulk-delete.php:314
31
+ #: dist/bulk-delete.php:548
32
  msgid "Bulk Delete Pages"
33
  msgstr ""
34
 
35
+ #: bulk-delete.php:364 bulk-delete.php:634 dist/bulk-delete.php:334
36
+ #: dist/bulk-delete.php:604
37
  msgid "Bulk Delete Schedules"
38
  msgstr ""
39
 
40
+ #: bulk-delete.php:364 dist/bulk-delete.php:334
41
  msgid "Scheduled Jobs"
42
  msgstr ""
43
 
44
+ #: bulk-delete.php:365 dist/bulk-delete.php:335
45
  #: dist/include/license/class-bd-license.php:33
46
  #: include/license/class-bd-license.php:33
47
  msgid "Addon Licenses"
48
  msgstr ""
49
 
50
+ #: bulk-delete.php:411 dist/bulk-delete.php:381
51
  msgid "By Post Status"
52
  msgstr ""
53
 
54
+ #: bulk-delete.php:412 dist/bulk-delete.php:382
55
  msgid "By Category"
56
  msgstr ""
57
 
58
+ #: bulk-delete.php:413 dist/bulk-delete.php:383
59
  msgid "By Tag"
60
  msgstr ""
61
 
62
+ #: bulk-delete.php:414 dist/bulk-delete.php:384
63
  msgid "By Custom Taxonomy"
64
  msgstr ""
65
 
66
+ #: bulk-delete.php:415 dist/bulk-delete.php:385
67
  msgid "By Custom Post Type"
68
  msgstr ""
69
 
70
+ #: bulk-delete.php:416 dist/bulk-delete.php:386
71
  msgid "By URL"
72
  msgstr ""
73
 
74
+ #: bulk-delete.php:417 dist/bulk-delete.php:387
75
  msgid "By Post Revision"
76
  msgstr ""
77
 
78
+ #: bulk-delete.php:454 dist/bulk-delete.php:424
79
  msgid "By Page Status"
80
  msgstr ""
81
 
82
+ #: bulk-delete.php:545 dist/bulk-delete.php:515
83
+ #: dist/include/misc/class-bulk-delete-misc.php:117
84
+ #: include/misc/class-bulk-delete-misc.php:117
85
  msgid "WARNING: Posts deleted once cannot be retrieved back. Use with caution."
86
  msgstr ""
87
 
88
+ #: bulk-delete.php:594 dist/bulk-delete.php:564
89
  msgid "WARNING: Pages deleted once cannot be retrieved back. Use with caution."
90
  msgstr ""
91
 
92
+ #: dist/include/addons/addon-list.php:20 include/addons/addon-list.php:20
93
  msgid ""
94
  "The following are the list of pro addons that are currently available for "
95
  "purchase."
96
  msgstr ""
97
 
98
+ #: dist/include/addons/addon-list.php:26 include/addons/addon-list.php:26
99
  msgid "Delete posts by custom field"
100
  msgstr ""
101
 
102
+ #: dist/include/addons/addon-list.php:27 include/addons/addon-list.php:27
103
  msgid "Adds the ability to delete posts based on custom fields"
104
  msgstr ""
105
 
106
+ #: dist/include/addons/addon-list.php:28 dist/include/addons/addon-list.php:34
107
+ #: dist/include/addons/addon-list.php:40 dist/include/addons/addon-list.php:46
108
+ #: dist/include/addons/addon-list.php:52 dist/include/addons/addon-list.php:58
109
+ #: dist/include/addons/addon-list.php:64 dist/include/addons/addon-list.php:70
110
+ #: dist/include/addons/addon-list.php:76 dist/include/addons/addon-list.php:82
111
+ #: dist/include/addons/addon-list.php:88 dist/include/addons/addon-list.php:94
112
+ #: dist/include/addons/addon-list.php:100
113
+ #: dist/include/addons/addon-list.php:106
114
+ #: dist/include/addons/addon-list.php:112
115
+ #: dist/include/addons/addon-list.php:118
116
+ #: dist/include/addons/addon-list.php:124
117
+ #: dist/include/addons/addon-list.php:130
118
+ #: dist/include/addons/addon-list.php:136
119
+ #: dist/include/addons/addon-list.php:142 include/addons/addon-list.php:28
120
+ #: include/addons/addon-list.php:34 include/addons/addon-list.php:40
121
+ #: include/addons/addon-list.php:46 include/addons/addon-list.php:52
122
+ #: include/addons/addon-list.php:58 include/addons/addon-list.php:64
123
+ #: include/addons/addon-list.php:70 include/addons/addon-list.php:76
124
+ #: include/addons/addon-list.php:82 include/addons/addon-list.php:88
125
+ #: include/addons/addon-list.php:94 include/addons/addon-list.php:100
126
+ #: include/addons/addon-list.php:106 include/addons/addon-list.php:112
127
+ #: include/addons/addon-list.php:118 include/addons/addon-list.php:124
128
+ #: include/addons/addon-list.php:130 include/addons/addon-list.php:136
129
+ #: include/addons/addon-list.php:142
130
  msgid "More Info"
131
  msgstr ""
132
 
133
+ #: dist/include/addons/addon-list.php:32 include/addons/addon-list.php:32
134
  msgid "Delete posts by title"
135
  msgstr ""
136
 
137
+ #: dist/include/addons/addon-list.php:33 include/addons/addon-list.php:33
138
  msgid "Adds the ability to delete posts based on title"
139
  msgstr ""
140
 
141
+ #: dist/include/addons/addon-list.php:38 include/addons/addon-list.php:38
142
  msgid "Delete posts by duplicate title"
143
  msgstr ""
144
 
145
+ #: dist/include/addons/addon-list.php:39 include/addons/addon-list.php:39
146
  msgid "Adds the ability to delete posts based on duplicate title"
147
  msgstr ""
148
 
149
+ #: dist/include/addons/addon-list.php:44 include/addons/addon-list.php:44
150
  msgid "Delete posts by attachment"
151
  msgstr ""
152
 
153
+ #: dist/include/addons/addon-list.php:45 include/addons/addon-list.php:45
154
  msgid ""
155
  "Adds the ability to delete posts based on whether it contains attachment or "
156
  "not"
157
  msgstr ""
158
 
159
+ #: dist/include/addons/addon-list.php:50 include/addons/addon-list.php:50
160
  msgid "Delete posts by user role"
161
  msgstr ""
162
 
163
+ #: dist/include/addons/addon-list.php:51 include/addons/addon-list.php:51
164
  msgid "Adds the ability to delete posts based on user role"
165
  msgstr ""
166
 
167
+ #: dist/include/addons/addon-list.php:56 include/addons/addon-list.php:56
168
  msgid "Delete from trash"
169
  msgstr ""
170
 
171
+ #: dist/include/addons/addon-list.php:57 include/addons/addon-list.php:57
172
  msgid "Adds the ability to delete posts and pages from trash"
173
  msgstr ""
174
 
175
+ #: dist/include/addons/addon-list.php:62 include/addons/addon-list.php:62
176
  msgid "Scheduler Email"
177
  msgstr ""
178
 
179
+ #: dist/include/addons/addon-list.php:63 include/addons/addon-list.php:63
180
  msgid "Sends an email every time a Bulk WP scheduler runs"
181
  msgstr ""
182
 
183
+ #: dist/include/addons/addon-list.php:68 include/addons/addon-list.php:68
184
  msgid "Scheduler for deleting Posts by Category"
185
  msgstr ""
186
 
187
+ #: dist/include/addons/addon-list.php:69 include/addons/addon-list.php:69
188
  msgid "Adds the ability to schedule auto delete of posts based on category"
189
  msgstr ""
190
 
191
+ #: dist/include/addons/addon-list.php:74 include/addons/addon-list.php:74
192
  msgid "Scheduler for deleting Posts by Tag"
193
  msgstr ""
194
 
195
+ #: dist/include/addons/addon-list.php:75 include/addons/addon-list.php:75
196
  msgid "Adds the ability to schedule auto delete of posts based on tag"
197
  msgstr ""
198
 
199
+ #: dist/include/addons/addon-list.php:80 include/addons/addon-list.php:80
200
  msgid "Scheduler for deleting Posts by Custom Taxonomy"
201
  msgstr ""
202
 
203
+ #: dist/include/addons/addon-list.php:81 include/addons/addon-list.php:81
204
  msgid ""
205
  "Adds the ability to schedule auto delete of posts based on custom taxonomy"
206
  msgstr ""
207
 
208
+ #: dist/include/addons/addon-list.php:86 include/addons/addon-list.php:86
209
  msgid "Scheduler for deleting Posts by Custom Post Type"
210
  msgstr ""
211
 
212
+ #: dist/include/addons/addon-list.php:87 include/addons/addon-list.php:87
213
  msgid ""
214
  "Adds the ability to schedule auto delete of posts based on custom post type"
215
  msgstr ""
216
 
217
+ #: dist/include/addons/addon-list.php:92 include/addons/addon-list.php:92
218
  msgid "Scheduler for deleting Posts by Post Status"
219
  msgstr ""
220
 
221
+ #: dist/include/addons/addon-list.php:93 include/addons/addon-list.php:93
222
  msgid ""
223
  "Adds the ability to schedule auto delete of posts based on post status like "
224
  "drafts, pending posts, scheduled posts etc."
225
  msgstr ""
226
 
227
+ #: dist/include/addons/addon-list.php:98 include/addons/addon-list.php:98
228
  msgid "Scheduler for deleting Pages by Status"
229
  msgstr ""
230
 
231
+ #: dist/include/addons/addon-list.php:99 include/addons/addon-list.php:99
232
  msgid "Adds the ability to schedule auto delete pages based on status"
233
  msgstr ""
234
 
235
+ #: dist/include/addons/addon-list.php:104 include/addons/addon-list.php:104
236
  msgid "Scheduler for deleting Users by User Role"
237
  msgstr ""
238
 
239
+ #: dist/include/addons/addon-list.php:105 include/addons/addon-list.php:105
240
  msgid "Adds the ability to schedule auto delete of users based on user role"
241
  msgstr ""
242
 
243
+ #: dist/include/addons/addon-list.php:110 include/addons/addon-list.php:110
244
  msgid "Scheduler for deleting Users by User Meta"
245
  msgstr ""
246
 
247
+ #: dist/include/addons/addon-list.php:111 include/addons/addon-list.php:111
248
  msgid "Adds the ability to schedule auto delete of users based on user meta"
249
  msgstr ""
250
 
251
+ #: dist/include/addons/addon-list.php:116 include/addons/addon-list.php:116
252
  msgid "Delete Post Meta Fields"
253
  msgstr ""
254
 
255
+ #: dist/include/addons/addon-list.php:117 include/addons/addon-list.php:117
256
  msgid ""
257
  "Adds the ability to delete post meta fields based on value and to schedule "
258
  "automatic deletion"
259
  msgstr ""
260
 
261
+ #: dist/include/addons/addon-list.php:122 include/addons/addon-list.php:122
262
  msgid "Delete Comment Meta Fields"
263
  msgstr ""
264
 
265
+ #: dist/include/addons/addon-list.php:123 include/addons/addon-list.php:123
266
  msgid ""
267
  "Adds the ability to delete comment meta fields based on value and to "
268
  "schedule automatic deletion"
269
  msgstr ""
270
 
271
+ #: dist/include/addons/addon-list.php:128 include/addons/addon-list.php:128
272
  msgid "Delete User Meta Fields"
273
  msgstr ""
274
 
275
+ #: dist/include/addons/addon-list.php:129 include/addons/addon-list.php:129
276
  msgid ""
277
  "Adds the ability to delete user meta fields based on value and to schedule "
278
  "automatic deletion"
279
  msgstr ""
280
 
281
+ #: dist/include/addons/addon-list.php:134 include/addons/addon-list.php:134
282
  msgid "Delete attachment"
283
  msgstr ""
284
 
285
+ #: dist/include/addons/addon-list.php:135 include/addons/addon-list.php:135
286
  msgid ""
287
  "Adds the ability to delete attachments based on whether they are attached to "
288
  "a post or not"
289
  msgstr ""
290
 
291
+ #: dist/include/addons/addon-list.php:140 include/addons/addon-list.php:140
292
  msgid "Delete Jetpack Contact Form Messages"
293
  msgstr ""
294
 
295
+ #: dist/include/addons/addon-list.php:141 include/addons/addon-list.php:141
296
  msgid ""
297
  "Adds the ability to delete Jetpack Contact Form Messages based on filters "
298
  "and to schedule automatic deletion"
299
  msgstr ""
300
 
301
+ #: dist/include/addons/base/class-bd-scheduler-addon.php:111
302
+ #: include/addons/base/class-bd-scheduler-addon.php:111
303
  msgid ""
304
  "\"%s\" addon requires \"<a href=\"%s\" target=\"_blank\">%s</a>\" addon to "
305
  "be installed and activated!"
306
  msgstr ""
307
 
308
+ #: dist/include/addons/pages.php:21 include/addons/pages.php:21
309
  msgid "Pages in Trash"
310
  msgstr ""
311
 
312
+ #. translators: 1 Number of posts that are deleted.
313
+ #: dist/include/addons/pages.php:32 dist/include/addons/posts.php:36
314
  #: dist/include/addons/posts.php:64 dist/include/addons/posts.php:92
315
+ #: dist/include/addons/posts.php:120 dist/include/addons/posts.php:147
316
+ #: dist/include/base/class-bd-meta-box-module.php:167
317
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:54
318
+ #: dist/include/meta/class-bulk-delete-post-meta.php:54
319
+ #: dist/include/meta/class-bulk-delete-user-meta.php:54
320
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:47
321
+ #: dist/include/pages/class-bulk-delete-pages.php:24
322
  #: dist/include/posts/class-bulk-delete-posts.php:18
323
+ #: dist/include/posts/class-bulk-delete-posts.php:192
324
+ #: dist/include/posts/class-bulk-delete-posts.php:332
325
+ #: dist/include/posts/class-bulk-delete-posts.php:458
326
+ #: dist/include/posts/class-bulk-delete-posts.php:652
327
+ #: dist/include/posts/class-bulk-delete-posts.php:822
328
+ #: dist/include/posts/class-bulk-delete-posts.php:889
329
+ #: include/addons/pages.php:32 include/addons/posts.php:36
330
  #: include/addons/posts.php:64 include/addons/posts.php:92
331
+ #: include/addons/posts.php:120 include/addons/posts.php:147
332
+ #: include/base/class-bd-meta-box-module.php:167
333
+ #: include/meta/class-bulk-delete-comment-meta.php:54
334
+ #: include/meta/class-bulk-delete-post-meta.php:54
335
+ #: include/meta/class-bulk-delete-user-meta.php:54
336
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:47
337
+ #: include/pages/class-bulk-delete-pages.php:24
338
  #: include/posts/class-bulk-delete-posts.php:18
339
+ #: include/posts/class-bulk-delete-posts.php:192
340
+ #: include/posts/class-bulk-delete-posts.php:332
341
+ #: include/posts/class-bulk-delete-posts.php:458
342
+ #: include/posts/class-bulk-delete-posts.php:652
343
+ #: include/posts/class-bulk-delete-posts.php:822
344
+ #: include/posts/class-bulk-delete-posts.php:889
345
  msgid ""
346
  "This section just got enabled. Kindly <a href = \"%1$s\">refresh</a> the "
347
  "page to fully enable it."
348
  msgstr ""
349
 
350
+ #: dist/include/addons/pages.php:42 include/addons/pages.php:42
351
  msgid "You need \"Bulk Delete From Trash\" Addon, to delete pages in Trash."
352
  msgstr ""
353
 
354
+ #: dist/include/addons/posts.php:21 include/addons/posts.php:21
355
  msgid "By Custom Field"
356
  msgstr ""
357
 
358
+ #: dist/include/addons/posts.php:22 include/addons/posts.php:22
359
  msgid "By Title"
360
  msgstr ""
361
 
362
+ #: dist/include/addons/posts.php:23 include/addons/posts.php:23
363
  msgid "By Duplicate Title"
364
  msgstr ""
365
 
366
+ #: dist/include/addons/posts.php:24
367
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:50
368
+ #: include/addons/posts.php:24
369
+ #: include/users/modules/class-bulk-delete-users-by-user-role.php:50
370
  msgid "By User Role"
371
  msgstr ""
372
 
373
+ #: dist/include/addons/posts.php:25 include/addons/posts.php:25
374
  #: tmp_addon/bulk-delete-from-trash.php:151
375
  msgid "Posts in Trash"
376
  msgstr ""
377
 
378
+ #: dist/include/addons/posts.php:46 include/addons/posts.php:46
379
  msgid ""
380
  "You need \"Bulk Delete Posts by Custom Field\" Addon, to delete post by "
381
  "custom field."
382
  msgstr ""
383
 
384
+ #: dist/include/addons/posts.php:74 include/addons/posts.php:74
385
  msgid "You need \"Bulk Delete Posts by Title\" Addon, to delete post by title."
386
  msgstr ""
387
 
388
+ #: dist/include/addons/posts.php:102 include/addons/posts.php:102
389
  msgid ""
390
  "You need \"Bulk Delete Posts by Duplicate Title\" Addon, to delete post by "
391
  "duplicate title."
392
  msgstr ""
393
 
394
+ #: dist/include/addons/posts.php:129 include/addons/posts.php:129
395
  msgid ""
396
  "You need \"Bulk Delete Posts by User Role\" Addon, to delete post based on "
397
  "User Role"
398
  msgstr ""
399
 
400
+ #: dist/include/addons/posts.php:157 include/addons/posts.php:157
401
  msgid "You need \"Bulk Delete From Trash\" Addon, to delete post in Trash."
402
  msgstr ""
403
 
404
+ #. translators: 1 Url to view cron jobs
405
+ #: dist/include/base/class-bd-meta-box-module.php:293
406
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:245
407
+ #: dist/include/meta/class-bulk-delete-post-meta.php:245
408
+ #: dist/include/meta/class-bulk-delete-user-meta.php:221
409
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:228
410
+ #: dist/include/pages/class-bulk-delete-pages.php:121
411
+ #: dist/include/posts/class-bulk-delete-posts.php:111
412
+ #: dist/include/posts/class-bulk-delete-posts.php:269
413
+ #: dist/include/posts/class-bulk-delete-posts.php:403
414
+ #: dist/include/posts/class-bulk-delete-posts.php:581
415
+ #: dist/include/posts/class-bulk-delete-posts.php:750
416
+ #: include/base/class-bd-meta-box-module.php:293
417
+ #: include/meta/class-bulk-delete-comment-meta.php:245
418
+ #: include/meta/class-bulk-delete-post-meta.php:245
419
+ #: include/meta/class-bulk-delete-user-meta.php:221
420
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:228
421
+ #: include/pages/class-bulk-delete-pages.php:121
422
+ #: include/posts/class-bulk-delete-posts.php:111
423
+ #: include/posts/class-bulk-delete-posts.php:269
424
+ #: include/posts/class-bulk-delete-posts.php:403
425
+ #: include/posts/class-bulk-delete-posts.php:581
426
+ #: include/posts/class-bulk-delete-posts.php:750
427
  #: tmp_addon/bulk-delete-posts-by-attachment.php:288
428
  #: tmp_addon/bulk-delete-posts-by-content.php:292
429
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:339
430
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:257
431
+ #: tmp_addon/bulk-delete-posts-by-title.php:274
432
  #: tmp_addon/bulk-delete-posts-by-user-role.php:225
433
  #: tmp_addon/bulk-delete-posts-by-user.php:265
434
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:300
435
  msgid "See the full list of <a href = \"%s\">scheduled tasks</a>"
436
  msgstr ""
437
 
438
+ #: dist/include/base/users/class-bd-user-meta-box-module.php:173
439
+ #: include/base/users/class-bd-user-meta-box-module.php:173
440
+ msgid "Restrict to users who are registered in the site for at least "
441
  msgstr ""
442
 
443
+ #: dist/include/base/users/class-bd-user-meta-box-module.php:174
444
+ #: include/base/users/class-bd-user-meta-box-module.php:174
445
+ msgid "days."
446
  msgstr ""
447
 
448
+ #: dist/include/base/users/class-bd-user-meta-box-module.php:188
449
+ #: include/base/users/class-bd-user-meta-box-module.php:188
450
  msgid "Restrict to users who have not logged in the last "
451
  msgstr ""
452
 
453
+ #: dist/include/base/users/class-bd-user-meta-box-module.php:189
454
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:136
455
+ #: dist/include/meta/class-bulk-delete-post-meta.php:136
456
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:113
457
+ #: dist/include/ui/form.php:48
458
+ #: include/base/users/class-bd-user-meta-box-module.php:189
459
+ #: include/meta/class-bulk-delete-comment-meta.php:136
460
+ #: include/meta/class-bulk-delete-post-meta.php:136
461
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:113
462
+ #: include/ui/form.php:48 tmp_addon/bulk-delete-from-trash.php:348
463
  #: tmp_addon/bulk-delete-posts-by-attachment.php:177
464
  #: tmp_addon/bulk-delete-posts-by-content.php:197
465
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:222
466
+ #: tmp_addon/bulk-delete-posts-by-title.php:172
467
  #: tmp_addon/bulk-delete-posts-by-user-role.php:140
468
  #: tmp_addon/bulk-delete-posts-by-user.php:181
469
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:193
470
  msgid "days"
471
  msgstr ""
472
 
473
+ #: dist/include/base/users/class-bd-user-meta-box-module.php:192
474
+ #: include/base/users/class-bd-user-meta-box-module.php:192
475
  msgid "Need the free \"Simple Login Log\" Plugin"
476
  msgstr ""
477
 
478
+ #: dist/include/base/users/class-bd-user-meta-box-module.php:201
479
+ #: include/base/users/class-bd-user-meta-box-module.php:201
480
  msgid ""
481
  "Enter \"0 days\" to delete users who have never logged in after the \"Simple "
482
  "Login Log\" plugin has been installed."
483
  msgstr ""
484
 
485
+ #: dist/include/base/users/class-bd-user-meta-box-module.php:220
486
+ #: include/base/users/class-bd-user-meta-box-module.php:220
487
+ msgid "Restrict to users who don't have any posts."
488
+ msgstr ""
489
+
490
+ #: dist/include/base/users/class-bd-user-meta-box-module.php:229
491
+ #: include/base/users/class-bd-user-meta-box-module.php:229
492
+ msgid "Select the post types. By default all post types are considered."
493
  msgstr ""
494
 
495
+ #: dist/include/cron/class-cron-list-table.php:33
496
+ #: include/cron/class-cron-list-table.php:33
497
  msgid ""
498
  "This is the list of jobs that are currently scheduled for auto deleting "
499
  "posts in Bulk Delete Plugin."
500
  msgstr ""
501
 
502
+ #: dist/include/cron/class-cron-list-table.php:35
503
+ #: include/cron/class-cron-list-table.php:35
504
  msgid "Note: "
505
  msgstr ""
506
 
507
+ #: dist/include/cron/class-cron-list-table.php:37
508
+ #: include/cron/class-cron-list-table.php:37
509
  msgid ""
510
  "Scheduling auto post or user deletion is available only when you buy pro "
511
  "addons."
512
  msgstr ""
513
 
514
+ #: dist/include/cron/class-cron-list-table.php:49
515
+ #: include/cron/class-cron-list-table.php:49
516
  msgid "Next Due"
517
  msgstr ""
518
 
519
+ #: dist/include/cron/class-cron-list-table.php:50
520
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:152
521
+ #: dist/include/meta/class-bulk-delete-post-meta.php:152
522
+ #: dist/include/meta/class-bulk-delete-user-meta.php:132
523
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:144
524
+ #: dist/include/ui/form.php:127 include/cron/class-cron-list-table.php:50
525
+ #: include/meta/class-bulk-delete-comment-meta.php:152
526
+ #: include/meta/class-bulk-delete-post-meta.php:152
527
+ #: include/meta/class-bulk-delete-user-meta.php:132
528
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:144
529
+ #: include/ui/form.php:127 tmp_addon/bulk-delete-posts-by-attachment.php:209
530
  #: tmp_addon/bulk-delete-posts-by-content.php:227
531
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:255
532
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:186
533
+ #: tmp_addon/bulk-delete-posts-by-title.php:200
534
  #: tmp_addon/bulk-delete-posts-by-user-role.php:164
535
  #: tmp_addon/bulk-delete-posts-by-user.php:205
536
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:230
537
  msgid "Schedule"
538
  msgstr ""
539
 
540
+ #: dist/include/cron/class-cron-list-table.php:51
541
+ #: include/cron/class-cron-list-table.php:51
542
  msgid "Type"
543
  msgstr ""
544
 
545
+ #: dist/include/cron/class-cron-list-table.php:52
546
+ #: include/cron/class-cron-list-table.php:52
547
  msgid "Options"
548
  msgstr ""
549
 
550
  #: dist/include/cron/class-cron-list-table.php:114
551
+ #: dist/include/license/class-license-list-table.php:98
552
  #: include/cron/class-cron-list-table.php:114
553
+ #: include/license/class-license-list-table.php:98
554
  msgid "Delete"
555
  msgstr ""
556
 
557
+ #: dist/include/cron/class-cron-list-table.php:155
558
+ #: include/cron/class-cron-list-table.php:155
559
  msgid "You have not scheduled any bulk delete jobs."
560
  msgstr ""
561
 
562
  #: dist/include/libraries/EDD_SL_Plugin_Updater.php:201
563
+ #: include/libraries/EDD_SL_Plugin_Updater.php:201
564
  msgid ""
565
  "There is a new version of %1$s available. %2$sView version %3$s details%4$s."
566
  msgstr ""
567
 
568
  #: dist/include/libraries/EDD_SL_Plugin_Updater.php:209
569
+ #: include/libraries/EDD_SL_Plugin_Updater.php:209
570
  msgid ""
571
  "There is a new version of %1$s available. %2$sView version %3$s details%4$s "
572
  "or %5$supdate now%6$s."
573
  msgstr ""
574
 
575
  #: dist/include/libraries/EDD_SL_Plugin_Updater.php:399
576
+ #: include/libraries/EDD_SL_Plugin_Updater.php:399
577
  msgid "You do not have permission to install plugin updates"
578
  msgstr ""
579
 
580
  #: dist/include/libraries/EDD_SL_Plugin_Updater.php:399
581
+ #: include/libraries/EDD_SL_Plugin_Updater.php:399
582
  msgid "Error"
583
  msgstr ""
584
 
585
+ #: dist/include/license/class-bd-license-handler.php:133
586
+ #: include/license/class-bd-license-handler.php:133
587
  msgid ""
588
  "\"%1$s\" addon is installed but not activated. To activate the addon, please "
589
  "<a href=\"%2$s\">enter your license key</a>. If you don't have a license "
590
  "key, then you can <a href=\"%3$s\" target=\"_blank\">purchase one</a>."
591
  msgstr ""
592
 
593
+ #: dist/include/license/class-bd-license-handler.php:136
594
+ #: include/license/class-bd-license-handler.php:136
595
  msgid ""
596
  "The license for \"%1$s\" addon is either invalid or has expired. Please <a "
597
  "href=\"%2$s\" target=\"_blank\">renew the license</a> or <a href=\"%3$s"
598
  "\">enter a new license key</a> to receive updates and support."
599
  msgstr ""
600
 
601
+ #: dist/include/license/class-bd-license-handler.php:202
602
+ #: include/license/class-bd-license-handler.php:202
603
  msgid ""
604
  "Addon is not activated. To activate the addon, please <a href=\"%1$s\">enter "
605
  "your license key</a>. If you don't have a license key, then you can <a href="
606
  "\"%2$s\" target=\"_blank\">purchase one</a>."
607
  msgstr ""
608
 
609
+ #: dist/include/license/class-bd-license-handler.php:212
610
+ #: include/license/class-bd-license-handler.php:212
611
  msgid ""
612
  "The license for this addon is either invalid or has expired. Please <a href="
613
  "\"%1$s\" target=\"_blank\">renew the license</a> or <a href=\"%2$s\">enter a "
614
  "new license key</a> to receive updates and support."
615
  msgstr ""
616
 
617
+ #: dist/include/license/class-bd-license-handler.php:245
618
+ #: include/license/class-bd-license-handler.php:245
619
  msgid "Addon License Key"
620
  msgstr ""
621
 
622
+ #: dist/include/license/class-bd-license-handler.php:265
623
+ #: include/license/class-bd-license-handler.php:265
624
  msgid "Enter license key"
625
  msgstr ""
626
 
629
  msgid "Activate License"
630
  msgstr ""
631
 
632
+ #: dist/include/license/class-bd-license.php:198
633
+ #: include/license/class-bd-license.php:198
634
  msgid "The license key for \"%s\" addon was successfully deactivated"
635
  msgstr ""
636
 
637
+ #: dist/include/license/class-bd-license.php:202
638
+ #: include/license/class-bd-license.php:202
639
  msgid ""
640
  "There was some problem while trying to deactivate license key for \"%s\" "
641
  "addon. Kindly try again"
642
  msgstr ""
643
 
644
+ #: dist/include/license/class-bd-license.php:225
645
+ #: include/license/class-bd-license.php:225
646
  msgid "The license key was successfully deleted"
647
  msgstr ""
648
 
649
+ #: dist/include/license/class-bd-license.php:271
650
+ #: include/license/class-bd-license.php:271
651
  msgid ""
652
  "There was some problem in contacting our store to activate the license key "
653
  "for \"%s\" addon"
654
  msgstr ""
655
 
656
+ #: dist/include/license/class-bd-license.php:281
657
+ #: include/license/class-bd-license.php:281
658
  msgid ""
659
  "The license key for \"%s\" addon was successfully activated. The addon will "
660
  "get updates automatically till the license key is valid."
661
  msgstr ""
662
 
663
+ #: dist/include/license/class-bd-license.php:288
664
+ #: include/license/class-bd-license.php:288
665
  msgid ""
666
  "The license key for \"%s\" addon doesn't have any more activations left. "
667
  "Kindly buy a new license."
668
  msgstr ""
669
 
670
+ #: dist/include/license/class-bd-license.php:292
671
+ #: include/license/class-bd-license.php:292
672
  msgid "The license key for \"%s\" addon is revoked. Kindly buy a new license."
673
  msgstr ""
674
 
675
+ #: dist/include/license/class-bd-license.php:296
676
+ #: include/license/class-bd-license.php:296
677
  msgid "The license key for \"%s\" addon has expired. Kindly buy a new license."
678
  msgstr ""
679
 
680
+ #: dist/include/license/class-bd-license.php:300
681
+ #: include/license/class-bd-license.php:300
682
  msgid "The license key for \"%s\" addon is invalid"
683
  msgstr ""
684
 
685
+ #: dist/include/license/class-license-list-table.php:38
686
+ #: include/license/class-license-list-table.php:38
687
  msgid ""
688
  "This is the list of addon license that are currently registered with the "
689
  "plugin."
690
  msgstr ""
691
 
692
+ #: dist/include/license/class-license-list-table.php:52
693
+ #: include/license/class-license-list-table.php:52
694
  msgid "Addon Name"
695
  msgstr ""
696
 
697
+ #: dist/include/license/class-license-list-table.php:53
698
+ #: include/license/class-license-list-table.php:53
699
  msgid "License Code"
700
  msgstr ""
701
 
702
+ #: dist/include/license/class-license-list-table.php:54
703
+ #: include/license/class-license-list-table.php:54
704
  msgid "Validity"
705
  msgstr ""
706
 
707
+ #: dist/include/license/class-license-list-table.php:55
708
+ #: include/license/class-license-list-table.php:55
709
  msgid "Expires"
710
  msgstr ""
711
 
712
+ #: dist/include/license/class-license-list-table.php:102
713
+ #: include/license/class-license-list-table.php:102
714
  msgid "Deactivate"
715
  msgstr ""
716
 
717
+ #: dist/include/license/class-license-list-table.php:169
718
+ #: include/license/class-license-list-table.php:169
719
  msgid "N/A"
720
  msgstr ""
721
 
722
+ #: dist/include/license/class-license-list-table.php:179
723
+ #: include/license/class-license-list-table.php:179
724
  msgid "You don't have any valid addon license yet."
725
  msgstr ""
726
 
729
  msgid "Bulk Delete Comment Meta"
730
  msgstr ""
731
 
732
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:70
733
+ #: include/meta/class-bulk-delete-comment-meta.php:70
734
  msgid "Select the post type whose comment meta fields you want to delete"
735
  msgstr ""
736
 
737
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:86
738
+ #: include/meta/class-bulk-delete-comment-meta.php:86
739
  msgid "Choose your comment meta field settings"
740
  msgstr ""
741
 
742
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:91
743
+ #: include/meta/class-bulk-delete-comment-meta.php:91
744
  msgid "Delete based on comment meta key name only"
745
  msgstr ""
746
 
747
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:98
748
+ #: include/meta/class-bulk-delete-comment-meta.php:98
749
  msgid "Delete based on comment meta key name and value"
750
  msgstr ""
751
 
752
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:100
753
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:166
754
+ #: dist/include/meta/class-bulk-delete-post-meta.php:100
755
+ #: dist/include/meta/class-bulk-delete-post-meta.php:166
756
+ #: dist/include/meta/class-bulk-delete-user-meta.php:92
757
+ #: dist/include/meta/class-bulk-delete-user-meta.php:146
758
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:83
759
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:157
760
+ #: dist/include/ui/form.php:138
761
+ #: include/meta/class-bulk-delete-comment-meta.php:100
762
+ #: include/meta/class-bulk-delete-comment-meta.php:166
763
+ #: include/meta/class-bulk-delete-post-meta.php:100
764
+ #: include/meta/class-bulk-delete-post-meta.php:166
765
+ #: include/meta/class-bulk-delete-user-meta.php:92
766
+ #: include/meta/class-bulk-delete-user-meta.php:146
767
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:83
768
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:157
769
+ #: include/ui/form.php:138 tmp_addon/bulk-delete-posts-by-attachment.php:222
770
  #: tmp_addon/bulk-delete-posts-by-content.php:240
771
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:269
772
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:199
773
+ #: tmp_addon/bulk-delete-posts-by-title.php:215
774
  #: tmp_addon/bulk-delete-posts-by-user-role.php:177
775
  #: tmp_addon/bulk-delete-posts-by-user.php:218
776
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:245
777
  msgid "Only available in Pro Addon"
778
  msgstr ""
779
 
780
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:107
781
+ #: include/meta/class-bulk-delete-comment-meta.php:107
782
  msgid "Comment Meta Key "
783
  msgstr ""
784
 
785
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:108
786
+ #: dist/include/meta/class-bulk-delete-post-meta.php:108
787
+ #: dist/include/meta/class-bulk-delete-user-meta.php:100
788
+ #: include/meta/class-bulk-delete-comment-meta.php:108
789
+ #: include/meta/class-bulk-delete-post-meta.php:108
790
+ #: include/meta/class-bulk-delete-user-meta.php:100
791
  msgid "Meta Key"
792
  msgstr ""
793
 
794
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:124
795
+ #: dist/include/meta/class-bulk-delete-post-meta.php:124
796
+ #: dist/include/meta/class-bulk-delete-user-meta.php:116
797
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:130
798
+ #: include/meta/class-bulk-delete-comment-meta.php:124
799
+ #: include/meta/class-bulk-delete-post-meta.php:124
800
+ #: include/meta/class-bulk-delete-user-meta.php:116
801
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:130
802
  msgid "Choose your deletion options"
803
  msgstr ""
804
 
805
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:131
806
+ #: include/meta/class-bulk-delete-comment-meta.php:131
807
  msgid "Only restrict to comments which are "
808
  msgstr ""
809
 
810
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:133
811
+ #: dist/include/meta/class-bulk-delete-post-meta.php:133
812
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:110
813
+ #: dist/include/ui/form.php:45
814
+ #: include/meta/class-bulk-delete-comment-meta.php:133
815
+ #: include/meta/class-bulk-delete-post-meta.php:133
816
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:110
817
+ #: include/ui/form.php:45 tmp_addon/bulk-delete-posts-by-attachment.php:174
818
  #: tmp_addon/bulk-delete-posts-by-content.php:194
819
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:218
820
+ #: tmp_addon/bulk-delete-posts-by-title.php:168
821
  #: tmp_addon/bulk-delete-posts-by-user-role.php:137
822
  #: tmp_addon/bulk-delete-posts-by-user.php:178
823
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:189
824
  msgid "older than"
825
  msgstr ""
826
 
827
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:134
828
+ #: include/meta/class-bulk-delete-comment-meta.php:134
829
  msgid "commented within last"
830
  msgstr ""
831
 
832
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:143
833
+ #: include/meta/class-bulk-delete-comment-meta.php:143
834
  msgid "Only delete comment meta field from first "
835
  msgstr ""
836
 
837
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:144
838
+ #: include/meta/class-bulk-delete-comment-meta.php:144
839
  msgid "comments."
840
  msgstr ""
841
 
842
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:145
843
+ #: dist/include/meta/class-bulk-delete-post-meta.php:145
844
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:124
845
+ #: include/meta/class-bulk-delete-comment-meta.php:145
846
+ #: include/meta/class-bulk-delete-post-meta.php:145
847
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:124
848
  #: tmp_addon/bulk-delete-posts-by-attachment.php:202
849
  #: tmp_addon/bulk-delete-posts-by-content.php:220
850
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:248
851
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:179
852
+ #: tmp_addon/bulk-delete-posts-by-title.php:191
853
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:221
854
  msgid ""
855
  "Use this option if there are more than 1000 posts and the script timesout."
856
  msgstr ""
857
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
858
  #: dist/include/meta/class-bulk-delete-comment-meta.php:151
859
  #: dist/include/meta/class-bulk-delete-post-meta.php:151
860
  #: dist/include/meta/class-bulk-delete-user-meta.php:131
861
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:143
862
+ #: dist/include/ui/form.php:126
863
  #: include/meta/class-bulk-delete-comment-meta.php:151
864
  #: include/meta/class-bulk-delete-post-meta.php:151
865
  #: include/meta/class-bulk-delete-user-meta.php:131
866
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:143
867
+ #: include/ui/form.php:126 tmp_addon/bulk-delete-posts-by-attachment.php:208
868
+ #: tmp_addon/bulk-delete-posts-by-content.php:226
869
  #: tmp_addon/bulk-delete-posts-by-custom-field.php:254
870
+ #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:185
871
+ #: tmp_addon/bulk-delete-posts-by-title.php:198
872
+ #: tmp_addon/bulk-delete-posts-by-user-role.php:163
873
+ #: tmp_addon/bulk-delete-posts-by-user.php:204
874
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:228
875
+ msgid "Delete now"
876
  msgstr ""
877
 
878
  #: dist/include/meta/class-bulk-delete-comment-meta.php:153
879
  #: dist/include/meta/class-bulk-delete-post-meta.php:153
880
  #: dist/include/meta/class-bulk-delete-user-meta.php:133
881
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:145
882
+ #: dist/include/ui/form.php:128
883
  #: include/meta/class-bulk-delete-comment-meta.php:153
884
  #: include/meta/class-bulk-delete-post-meta.php:153
885
  #: include/meta/class-bulk-delete-user-meta.php:133
886
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:145
887
+ #: include/ui/form.php:128 tmp_addon/bulk-delete-posts-by-attachment.php:210
888
+ #: tmp_addon/bulk-delete-posts-by-content.php:228
889
  #: tmp_addon/bulk-delete-posts-by-custom-field.php:256
890
+ #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:187
891
+ #: tmp_addon/bulk-delete-posts-by-title.php:202
892
+ #: tmp_addon/bulk-delete-posts-by-user-role.php:165
893
+ #: tmp_addon/bulk-delete-posts-by-user.php:206
894
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:232
895
+ msgid "repeat "
896
+ msgstr ""
897
+
898
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:155
899
+ #: dist/include/meta/class-bulk-delete-post-meta.php:155
900
+ #: dist/include/meta/class-bulk-delete-user-meta.php:135
901
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:147
902
+ #: dist/include/ui/form.php:130
903
+ #: include/meta/class-bulk-delete-comment-meta.php:155
904
+ #: include/meta/class-bulk-delete-post-meta.php:155
905
+ #: include/meta/class-bulk-delete-user-meta.php:135
906
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:147
907
+ #: include/ui/form.php:130 tmp_addon/bulk-delete-posts-by-attachment.php:212
908
+ #: tmp_addon/bulk-delete-posts-by-content.php:230
909
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:259
910
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:189
911
+ #: tmp_addon/bulk-delete-posts-by-title.php:204
912
  #: tmp_addon/bulk-delete-posts-by-user-role.php:167
913
  #: tmp_addon/bulk-delete-posts-by-user.php:208
914
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:234
915
  msgid "Don't repeat"
916
  msgstr ""
917
 
918
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:173
919
+ #: dist/include/meta/class-bulk-delete-post-meta.php:173
920
+ #: dist/include/meta/class-bulk-delete-user-meta.php:153
921
+ #: include/meta/class-bulk-delete-comment-meta.php:173
922
+ #: include/meta/class-bulk-delete-post-meta.php:173
923
+ #: include/meta/class-bulk-delete-user-meta.php:153
924
  #: tmp_addon/bulk-delete-posts-by-attachment.php:228
925
  #: tmp_addon/bulk-delete-posts-by-content.php:246
926
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:277
927
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:205
928
+ #: tmp_addon/bulk-delete-posts-by-title.php:222
929
  #: tmp_addon/bulk-delete-posts-by-user-role.php:183
930
  #: tmp_addon/bulk-delete-posts-by-user.php:224
931
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:252
932
  msgid "Enter time in Y-m-d H:i:s format or enter now to use current time"
933
  msgstr ""
934
 
935
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:181
936
+ #: dist/include/meta/class-bulk-delete-post-meta.php:181
937
+ #: dist/include/meta/class-bulk-delete-user-meta.php:161
938
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:164
939
+ #: dist/include/ui/form.php:160
940
+ #: include/meta/class-bulk-delete-comment-meta.php:181
941
+ #: include/meta/class-bulk-delete-post-meta.php:181
942
+ #: include/meta/class-bulk-delete-user-meta.php:161
943
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:164
944
+ #: include/ui/form.php:160 tmp_addon/bulk-delete-from-trash.php:162
945
  #: tmp_addon/bulk-delete-from-trash.php:270
946
  #: tmp_addon/bulk-delete-posts-by-attachment.php:235
947
  #: tmp_addon/bulk-delete-posts-by-content.php:254
948
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:286
949
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:213
950
+ #: tmp_addon/bulk-delete-posts-by-title.php:231
951
  #: tmp_addon/bulk-delete-posts-by-user-role.php:191
952
  #: tmp_addon/bulk-delete-posts-by-user.php:232
953
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:261
954
  msgid "Bulk Delete "
955
  msgstr ""
956
 
957
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:202
958
+ #: include/meta/class-bulk-delete-comment-meta.php:202
959
  msgid ""
960
  "Are you sure you want to delete all the comment meta fields that match the "
961
  "selected filters?"
962
  msgstr ""
963
 
964
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:244
965
+ #: include/meta/class-bulk-delete-comment-meta.php:244
966
  msgid ""
967
  "Comment meta fields from the comments with the selected criteria are "
968
  "scheduled for deletion."
969
  msgstr ""
970
 
971
+ #: dist/include/meta/class-bulk-delete-comment-meta.php:248
972
+ #: include/meta/class-bulk-delete-comment-meta.php:248
973
  msgid "Deleted comment meta field from %d comment"
974
  msgid_plural "Deleted comment meta field from %d comments"
975
  msgstr[0] ""
976
  msgstr[1] ""
977
 
 
978
  #: dist/include/meta/class-bulk-delete-meta.php:40
979
+ #: dist/include/meta/class-bulk-delete-meta.php:41
980
+ #: dist/include/meta/class-bulk-delete-meta.php:106
981
  #: include/meta/class-bulk-delete-meta.php:40
982
+ #: include/meta/class-bulk-delete-meta.php:41
983
+ #: include/meta/class-bulk-delete-meta.php:106
984
  msgid "Bulk Delete Meta Fields"
985
  msgstr ""
986
 
987
+ #: dist/include/meta/class-bulk-delete-meta.php:121
988
+ #: include/meta/class-bulk-delete-meta.php:121
989
  msgid "WARNING: Items deleted once cannot be retrieved back. Use with caution."
990
  msgstr ""
991
 
994
  msgid "Bulk Delete Post Meta"
995
  msgstr ""
996
 
997
+ #: dist/include/meta/class-bulk-delete-post-meta.php:70
998
+ #: include/meta/class-bulk-delete-post-meta.php:70
999
  msgid "Select the post type whose post meta fields you want to delete"
1000
  msgstr ""
1001
 
1002
+ #: dist/include/meta/class-bulk-delete-post-meta.php:86
1003
+ #: include/meta/class-bulk-delete-post-meta.php:86
1004
  msgid "Choose your post meta field settings"
1005
  msgstr ""
1006
 
1007
+ #: dist/include/meta/class-bulk-delete-post-meta.php:91
1008
+ #: include/meta/class-bulk-delete-post-meta.php:91
1009
  msgid "Delete based on post meta key name only"
1010
  msgstr ""
1011
 
1012
+ #: dist/include/meta/class-bulk-delete-post-meta.php:98
1013
+ #: include/meta/class-bulk-delete-post-meta.php:98
1014
  msgid "Delete based on post meta key name and value"
1015
  msgstr ""
1016
 
1017
+ #: dist/include/meta/class-bulk-delete-post-meta.php:107
1018
+ #: include/meta/class-bulk-delete-post-meta.php:107
1019
  msgid "Post Meta Key "
1020
  msgstr ""
1021
 
1022
+ #: dist/include/meta/class-bulk-delete-post-meta.php:131
1023
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:108
1024
+ #: include/meta/class-bulk-delete-post-meta.php:131
1025
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:108
1026
  #: tmp_addon/bulk-delete-posts-by-attachment.php:172
1027
  #: tmp_addon/bulk-delete-posts-by-content.php:192
1028
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:216
1029
+ #: tmp_addon/bulk-delete-posts-by-title.php:166
1030
  #: tmp_addon/bulk-delete-posts-by-user-role.php:135
1031
  #: tmp_addon/bulk-delete-posts-by-user.php:176
1032
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:187
1033
  msgid "Only restrict to posts which are "
1034
  msgstr ""
1035
 
1036
+ #: dist/include/meta/class-bulk-delete-post-meta.php:134
1037
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:111
1038
+ #: dist/include/ui/form.php:46 include/meta/class-bulk-delete-post-meta.php:134
1039
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:111
1040
+ #: include/ui/form.php:46 tmp_addon/bulk-delete-posts-by-attachment.php:175
1041
  #: tmp_addon/bulk-delete-posts-by-content.php:195
1042
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:219
1043
+ #: tmp_addon/bulk-delete-posts-by-title.php:169
1044
  #: tmp_addon/bulk-delete-posts-by-user-role.php:138
1045
  #: tmp_addon/bulk-delete-posts-by-user.php:179
1046
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:190
1047
  msgid "posted within last"
1048
  msgstr ""
1049
 
1050
+ #: dist/include/meta/class-bulk-delete-post-meta.php:143
1051
+ #: include/meta/class-bulk-delete-post-meta.php:143
1052
  msgid "Only delete post meta field from first "
1053
  msgstr ""
1054
 
1055
+ #: dist/include/meta/class-bulk-delete-post-meta.php:144
1056
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:123
1057
+ #: include/meta/class-bulk-delete-post-meta.php:144
1058
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:123
1059
  #: tmp_addon/bulk-delete-posts-by-attachment.php:201
1060
  #: tmp_addon/bulk-delete-posts-by-content.php:219
1061
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:247
1062
+ #: tmp_addon/bulk-delete-posts-by-title.php:190
1063
  #: tmp_addon/bulk-delete-posts-by-user-role.php:156
1064
  #: tmp_addon/bulk-delete-posts-by-user.php:197
1065
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:220
1066
  msgid "posts."
1067
  msgstr ""
1068
 
1069
+ #: dist/include/meta/class-bulk-delete-post-meta.php:202
1070
+ #: include/meta/class-bulk-delete-post-meta.php:202
1071
  msgid ""
1072
  "Are you sure you want to delete all the post meta fields that match the "
1073
  "selected filters?"
1074
  msgstr ""
1075
 
1076
+ #: dist/include/meta/class-bulk-delete-post-meta.php:244
1077
+ #: include/meta/class-bulk-delete-post-meta.php:244
1078
  msgid ""
1079
  "Post meta fields from the posts with the selected criteria are scheduled for "
1080
  "deletion."
1081
  msgstr ""
1082
 
1083
+ #: dist/include/meta/class-bulk-delete-post-meta.php:248
1084
+ #: include/meta/class-bulk-delete-post-meta.php:248
1085
  msgid "Deleted post meta field from %d post"
1086
  msgid_plural "Deleted post meta field from %d posts"
1087
  msgstr[0] ""
1092
  msgid "Bulk Delete User Meta"
1093
  msgstr ""
1094
 
1095
+ #: dist/include/meta/class-bulk-delete-user-meta.php:61
1096
+ #: include/meta/class-bulk-delete-user-meta.php:61
1097
  msgid "Select the user role whose user meta fields you want to delete"
1098
  msgstr ""
1099
 
1100
+ #: dist/include/meta/class-bulk-delete-user-meta.php:70
1101
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:76
1102
+ #: include/meta/class-bulk-delete-user-meta.php:70
1103
+ #: include/users/modules/class-bulk-delete-users-by-user-role.php:76
1104
  #: tmp_addon/bulk-delete-posts-by-user-role.php:96
1105
  msgid "Users"
1106
  msgstr ""
1107
 
1108
+ #: dist/include/meta/class-bulk-delete-user-meta.php:78
1109
+ #: include/meta/class-bulk-delete-user-meta.php:78
1110
  msgid "Choose your user meta field settings"
1111
  msgstr ""
1112
 
1113
+ #: dist/include/meta/class-bulk-delete-user-meta.php:83
1114
+ #: include/meta/class-bulk-delete-user-meta.php:83
1115
  msgid "Delete based on user meta key name only"
1116
  msgstr ""
1117
 
1118
+ #: dist/include/meta/class-bulk-delete-user-meta.php:90
1119
+ #: include/meta/class-bulk-delete-user-meta.php:90
1120
  msgid "Delete based on user meta key name and value"
1121
  msgstr ""
1122
 
1123
+ #: dist/include/meta/class-bulk-delete-user-meta.php:99
1124
+ #: include/meta/class-bulk-delete-user-meta.php:99
1125
  msgid "User Meta Key "
1126
  msgstr ""
1127
 
1128
+ #: dist/include/meta/class-bulk-delete-user-meta.php:123
1129
+ #: include/meta/class-bulk-delete-user-meta.php:123
1130
  msgid "Only delete user meta field from first "
1131
  msgstr ""
1132
 
1133
+ #: dist/include/meta/class-bulk-delete-user-meta.php:124
1134
+ #: include/meta/class-bulk-delete-user-meta.php:124
1135
  msgid "users."
1136
  msgstr ""
1137
 
1138
+ #: dist/include/meta/class-bulk-delete-user-meta.php:125
1139
+ #: include/meta/class-bulk-delete-user-meta.php:125
1140
  msgid ""
1141
  "Use this option if there are more than 1000 users and the script timesout."
1142
  msgstr ""
1143
 
1144
+ #: dist/include/meta/class-bulk-delete-user-meta.php:182
1145
+ #: include/meta/class-bulk-delete-user-meta.php:182
1146
  msgid ""
1147
  "Are you sure you want to delete all the user meta fields that match the "
1148
  "selected filters?"
1149
  msgstr ""
1150
 
1151
+ #: dist/include/meta/class-bulk-delete-user-meta.php:220
1152
+ #: include/meta/class-bulk-delete-user-meta.php:220
1153
  msgid ""
1154
  "User meta fields from the users with the selected criteria are scheduled for "
1155
  "deletion."
1156
  msgstr ""
1157
 
1158
+ #: dist/include/meta/class-bulk-delete-user-meta.php:224
1159
+ #: include/meta/class-bulk-delete-user-meta.php:224
1160
  msgid "Deleted user meta field from %d user"
1161
  msgid_plural "Deleted user meta field from %d users"
1162
  msgstr[0] ""
1163
  msgstr[1] ""
1164
 
1165
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:31
1166
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:31
1167
  msgid "Bulk Delete Jetpack Contact Form Messages"
1168
  msgstr ""
1169
 
1170
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:57
1171
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:57
1172
  msgid "Jetpack contact form is not enabled."
1173
  msgstr ""
1174
 
1175
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:73
1176
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:73
1177
  msgid "Delete all Contact Form Messages"
1178
  msgstr ""
1179
 
1180
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:73
1181
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:73
1182
  msgid "in total"
1183
  msgstr ""
1184
 
1185
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:82
1186
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:82
1187
  msgid "Delete Messages based on filters"
1188
  msgstr ""
1189
 
1190
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:99
1191
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:99
1192
  msgid "Choose your date options"
1193
  msgstr ""
1194
 
1195
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:122
1196
+ #: dist/include/ui/form.php:105
1197
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:122
1198
+ #: include/ui/form.php:105 tmp_addon/bulk-delete-posts-by-attachment.php:200
1199
  #: tmp_addon/bulk-delete-posts-by-content.php:218
1200
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:245
1201
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:177
1202
+ #: tmp_addon/bulk-delete-posts-by-title.php:188
1203
  #: tmp_addon/bulk-delete-posts-by-user-role.php:154
1204
  #: tmp_addon/bulk-delete-posts-by-user.php:195
1205
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:218
1206
  msgid "Only delete first "
1207
  msgstr ""
1208
 
1209
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:136
1210
+ #: dist/include/ui/form.php:65
1211
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:136
1212
+ #: include/ui/form.php:65 tmp_addon/bulk-delete-posts-by-attachment.php:183
1213
  #: tmp_addon/bulk-delete-posts-by-content.php:203
1214
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:228
1215
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:169
1216
+ #: tmp_addon/bulk-delete-posts-by-title.php:179
1217
  #: tmp_addon/bulk-delete-posts-by-user-role.php:146
1218
  #: tmp_addon/bulk-delete-posts-by-user.php:187
1219
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:200
1220
  msgid "Move to Trash"
1221
  msgstr ""
1222
 
1223
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:137
1224
+ #: dist/include/ui/form.php:66
1225
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:137
1226
+ #: include/ui/form.php:66 tmp_addon/bulk-delete-posts-by-attachment.php:184
1227
  #: tmp_addon/bulk-delete-posts-by-content.php:204
1228
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:229
1229
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:170
1230
+ #: tmp_addon/bulk-delete-posts-by-title.php:181
1231
  #: tmp_addon/bulk-delete-posts-by-user-role.php:147
1232
  #: tmp_addon/bulk-delete-posts-by-user.php:188
1233
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:202
1234
  msgid "Delete permanently"
1235
  msgstr ""
1236
 
1237
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:186
1238
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:186
1239
  msgid ""
1240
  "Are you sure you want to delete all the Jetpack contact form messages based "
1241
  "on the selected filters?"
1242
  msgstr ""
1243
 
1244
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:227
1245
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:227
1246
  msgid ""
1247
  "Jetpack contact form messages with the selected criteria are scheduled for "
1248
  "deletion."
1249
  msgstr ""
1250
 
1251
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:231
1252
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:231
1253
  msgid "Deleted %d Jetpack contact form message"
1254
  msgid_plural "Deleted %d Jetpack contact form messages"
1255
  msgstr[0] ""
1256
  msgstr[1] ""
1257
 
1258
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:343
1259
+ #: dist/include/ui/form.php:22
1260
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:343
1261
+ #: include/ui/form.php:22
1262
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:123
1263
+ #: tmp_addon/bulk-delete-posts-by-attachment.php:163
1264
+ #: tmp_addon/bulk-delete-posts-by-content.php:186
1265
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:207
1266
+ #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:163
1267
+ #: tmp_addon/bulk-delete-posts-by-title.php:159
1268
+ #: tmp_addon/bulk-delete-posts-by-user-role.php:130
1269
+ #: tmp_addon/bulk-delete-posts-by-user.php:171
1270
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:181
1271
+ msgid "Choose your filtering options"
1272
+ msgstr ""
1273
+
1274
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:352
1275
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:352
1276
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:132
1277
+ msgid "Only if author name "
1278
+ msgstr ""
1279
+
1280
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:354
1281
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:368
1282
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:382
1283
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:354
1284
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:368
1285
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:382
1286
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:134
1287
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:148
1288
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:162
1289
+ msgid "is"
1290
+ msgstr ""
1291
+
1292
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:355
1293
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:369
1294
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:383
1295
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:355
1296
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:369
1297
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:383
1298
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:135
1299
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:149
1300
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:163
1301
+ msgid "is not"
1302
+ msgstr ""
1303
+
1304
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:357
1305
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:357
1306
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:137
1307
+ msgid "Author Name"
1308
+ msgstr ""
1309
+
1310
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:366
1311
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:366
1312
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:146
1313
+ msgid "Only if author email "
1314
+ msgstr ""
1315
+
1316
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:371
1317
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:371
1318
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:151
1319
+ msgid "Author Email"
1320
+ msgstr ""
1321
+
1322
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:380
1323
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:380
1324
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:160
1325
+ msgid "Only if author ip "
1326
+ msgstr ""
1327
+
1328
+ #: dist/include/misc/class-bulk-delete-jetpack-contact-form-messages.php:385
1329
+ #: include/misc/class-bulk-delete-jetpack-contact-form-messages.php:385
1330
+ #: tmp_addon/bulk-delete-jetpack-contact-form-messages.php:165
1331
+ msgid "Author ip"
1332
  msgstr ""
1333
 
1334
  #: dist/include/misc/class-bulk-delete-misc.php:35
1335
+ #: dist/include/misc/class-bulk-delete-misc.php:101
1336
  #: include/misc/class-bulk-delete-misc.php:35
1337
+ #: include/misc/class-bulk-delete-misc.php:101
1338
+ msgid "Bulk Delete Miscellaneous Items"
1339
+ msgstr ""
1340
+
1341
+ #: dist/include/misc/class-bulk-delete-misc.php:36
1342
+ #: include/misc/class-bulk-delete-misc.php:36
1343
  msgid "Bulk Delete Misc"
1344
  msgstr ""
1345
 
1346
+ #: dist/include/pages/class-bulk-delete-pages.php:37
1347
+ #: include/pages/class-bulk-delete-pages.php:37
1348
  msgid "Select the status from which you want to delete pages"
1349
  msgstr ""
1350
 
1351
+ #: dist/include/pages/class-bulk-delete-pages.php:44
1352
+ #: include/pages/class-bulk-delete-pages.php:44
1353
  msgid "All Published Pages"
1354
  msgstr ""
1355
 
1356
+ #: dist/include/pages/class-bulk-delete-pages.php:44
1357
+ #: dist/include/pages/class-bulk-delete-pages.php:51
1358
+ #: dist/include/pages/class-bulk-delete-pages.php:58
1359
+ #: dist/include/pages/class-bulk-delete-pages.php:65
1360
+ #: dist/include/pages/class-bulk-delete-pages.php:72
1361
+ #: include/pages/class-bulk-delete-pages.php:44
1362
+ #: include/pages/class-bulk-delete-pages.php:51
1363
+ #: include/pages/class-bulk-delete-pages.php:58
1364
+ #: include/pages/class-bulk-delete-pages.php:65
1365
+ #: include/pages/class-bulk-delete-pages.php:72
1366
  msgid "Pages"
1367
  msgstr ""
1368
 
1369
+ #: dist/include/pages/class-bulk-delete-pages.php:51
1370
+ #: include/pages/class-bulk-delete-pages.php:51
1371
  msgid "All Draft Pages"
1372
  msgstr ""
1373
 
1374
+ #: dist/include/pages/class-bulk-delete-pages.php:58
1375
+ #: include/pages/class-bulk-delete-pages.php:58
1376
  msgid "All Scheduled Pages"
1377
  msgstr ""
1378
 
1379
+ #: dist/include/pages/class-bulk-delete-pages.php:65
1380
+ #: include/pages/class-bulk-delete-pages.php:65
1381
  msgid "All Pending Pages"
1382
  msgstr ""
1383
 
1384
+ #: dist/include/pages/class-bulk-delete-pages.php:72
1385
+ #: include/pages/class-bulk-delete-pages.php:72
1386
  msgid "All Private Pages"
1387
  msgstr ""
1388
 
1389
+ #: dist/include/pages/class-bulk-delete-pages.php:120
1390
+ #: include/pages/class-bulk-delete-pages.php:120
1391
  msgid "The selected pages are scheduled for deletion."
1392
  msgstr ""
1393
 
1394
+ #: dist/include/pages/class-bulk-delete-pages.php:124
1395
+ #: include/pages/class-bulk-delete-pages.php:124
1396
  msgid "Deleted %d page"
1397
  msgid_plural "Deleted %d pages"
1398
  msgstr[0] ""
1399
  msgstr[1] ""
1400
 
1401
+ #: dist/include/posts/class-bulk-delete-posts.php:26
1402
+ #: include/posts/class-bulk-delete-posts.php:26
1403
+ msgid "Select the post statuses from which you want to delete posts"
1404
+ msgstr ""
1405
+
1406
+ #: dist/include/posts/class-bulk-delete-posts.php:40
1407
+ #: dist/include/posts/class-bulk-delete-posts.php:54
1408
+ #: dist/include/posts/class-bulk-delete-posts.php:218
1409
+ #: dist/include/posts/class-bulk-delete-posts.php:350
1410
+ #: dist/include/posts/class-bulk-delete-posts.php:522
1411
+ #: dist/include/ui/form.php:237 include/posts/class-bulk-delete-posts.php:40
1412
+ #: include/posts/class-bulk-delete-posts.php:54
1413
+ #: include/posts/class-bulk-delete-posts.php:218
1414
+ #: include/posts/class-bulk-delete-posts.php:350
1415
+ #: include/posts/class-bulk-delete-posts.php:522 include/ui/form.php:238
 
 
 
 
 
 
 
 
 
 
 
1416
  msgid "Posts"
1417
  msgstr ""
1418
 
1419
+ #: dist/include/posts/class-bulk-delete-posts.php:53
1420
+ #: include/posts/class-bulk-delete-posts.php:53
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1421
  msgid "All Sticky Posts"
1422
  msgstr ""
1423
 
1424
+ #: dist/include/posts/class-bulk-delete-posts.php:55
1425
+ #: include/posts/class-bulk-delete-posts.php:55
1426
  msgid "Note"
1427
  msgstr ""
1428
 
1429
+ #: dist/include/posts/class-bulk-delete-posts.php:55
1430
+ #: include/posts/class-bulk-delete-posts.php:55
1431
  msgid "The date filter will not work for sticky posts"
1432
  msgstr ""
1433
 
1434
+ #: dist/include/posts/class-bulk-delete-posts.php:108
1435
+ #: include/posts/class-bulk-delete-posts.php:108
1436
  msgid "Posts with the selected status are scheduled for deletion."
1437
  msgstr ""
1438
 
1439
+ #. translators: 1 Number of posts deleted
1440
+ #: dist/include/posts/class-bulk-delete-posts.php:116
1441
+ #: include/posts/class-bulk-delete-posts.php:116
1442
  msgid "Deleted %d post with the selected post status"
1443
  msgid_plural "Deleted %d posts with the selected post status"
1444
  msgstr[0] ""
1445
  msgstr[1] ""
1446
 
1447
+ #: dist/include/posts/class-bulk-delete-posts.php:198
1448
+ #: include/posts/class-bulk-delete-posts.php:198
1449
  msgid "Select the post type from which you want to delete posts by category"
1450
  msgstr ""
1451
 
1452
+ #: dist/include/posts/class-bulk-delete-posts.php:204
1453
+ #: include/posts/class-bulk-delete-posts.php:204
1454
  msgid "Select the categories from which you wan to delete posts"
1455
  msgstr ""
1456
 
1457
+ #: dist/include/posts/class-bulk-delete-posts.php:205
1458
+ #: include/posts/class-bulk-delete-posts.php:205
1459
  msgid ""
1460
  "Note: The post count below for each category is the total number of posts in "
1461
  "that category, irrespective of post type"
1462
  msgstr ""
1463
 
1464
+ #: dist/include/posts/class-bulk-delete-posts.php:215
1465
+ #: include/posts/class-bulk-delete-posts.php:215
1466
  msgid "Select Categories"
1467
  msgstr ""
1468
 
1469
+ #: dist/include/posts/class-bulk-delete-posts.php:216
1470
+ #: include/posts/class-bulk-delete-posts.php:216
1471
  msgid "All Categories"
1472
  msgstr ""
1473
 
1474
+ #: dist/include/posts/class-bulk-delete-posts.php:268
1475
+ #: include/posts/class-bulk-delete-posts.php:268
1476
  msgid "Posts from the selected categories are scheduled for deletion."
1477
  msgstr ""
1478
 
1479
+ #: dist/include/posts/class-bulk-delete-posts.php:272
1480
+ #: include/posts/class-bulk-delete-posts.php:272
1481
  msgid "Deleted %d post from the selected categories"
1482
  msgid_plural "Deleted %d posts from the selected categories"
1483
  msgstr[0] ""
1484
  msgstr[1] ""
1485
 
1486
+ #: dist/include/posts/class-bulk-delete-posts.php:340
1487
+ #: include/posts/class-bulk-delete-posts.php:340
1488
  msgid "Select the tags from which you want to delete posts"
1489
  msgstr ""
1490
 
1491
+ #: dist/include/posts/class-bulk-delete-posts.php:347
1492
+ #: include/posts/class-bulk-delete-posts.php:347
1493
  msgid "Select Tags"
1494
  msgstr ""
1495
 
1496
+ #: dist/include/posts/class-bulk-delete-posts.php:348
1497
+ #: include/posts/class-bulk-delete-posts.php:348
1498
  msgid "All Tags"
1499
  msgstr ""
1500
 
1501
+ #: dist/include/posts/class-bulk-delete-posts.php:370
1502
+ #: include/posts/class-bulk-delete-posts.php:370
1503
  msgid "You don't have any posts assigned to tags in this blog."
1504
  msgstr ""
1505
 
1506
+ #: dist/include/posts/class-bulk-delete-posts.php:402
1507
+ #: include/posts/class-bulk-delete-posts.php:402
1508
  msgid "Posts from the selected tags are scheduled for deletion."
1509
  msgstr ""
1510
 
1511
+ #: dist/include/posts/class-bulk-delete-posts.php:406
1512
+ #: include/posts/class-bulk-delete-posts.php:406
1513
  msgid "Deleted %d post from the selected tags"
1514
  msgid_plural "Deleted %d posts from the selected tags"
1515
  msgstr[0] ""
1516
  msgstr[1] ""
1517
 
1518
+ #: dist/include/posts/class-bulk-delete-posts.php:482
1519
+ #: include/posts/class-bulk-delete-posts.php:482
1520
  msgid ""
1521
  "Select the post type from which you want to delete posts by custom taxonomy"
1522
  msgstr ""
1523
 
1524
+ #: dist/include/posts/class-bulk-delete-posts.php:489
1525
+ #: include/posts/class-bulk-delete-posts.php:489
1526
  msgid "Select the taxonomies from which you want to delete posts"
1527
  msgstr ""
1528
 
1529
+ #: dist/include/posts/class-bulk-delete-posts.php:508
1530
+ #: include/posts/class-bulk-delete-posts.php:508
1531
  msgid ""
1532
  "The selected taxonomy has the following terms. Select the terms from which "
1533
  "you want to delete posts"
1534
  msgstr ""
1535
 
1536
+ #: dist/include/posts/class-bulk-delete-posts.php:509
1537
+ #: include/posts/class-bulk-delete-posts.php:509
1538
  msgid ""
1539
  "Note: The post count below for each term is the total number of posts in "
1540
  "that term, irrespective of post type"
1541
  msgstr ""
1542
 
1543
+ #: dist/include/posts/class-bulk-delete-posts.php:546
1544
+ #: include/posts/class-bulk-delete-posts.php:546
1545
  msgid ""
1546
  "This WordPress installation doesn't have any non-empty custom taxonomies "
1547
  "defined"
1548
  msgstr ""
1549
 
1550
+ #: dist/include/posts/class-bulk-delete-posts.php:580
1551
+ #: include/posts/class-bulk-delete-posts.php:580
1552
  msgid "Posts from the selected custom taxonomies are scheduled for deletion."
1553
  msgstr ""
1554
 
1555
+ #: dist/include/posts/class-bulk-delete-posts.php:584
1556
+ #: include/posts/class-bulk-delete-posts.php:584
1557
  msgid "Deleted %d post from the selected custom taxonomies"
1558
  msgid_plural "Deleted %d posts from the selected custom taxonomies"
1559
  msgstr[0] ""
1560
  msgstr[1] ""
1561
 
1562
+ #: dist/include/posts/class-bulk-delete-posts.php:688
1563
+ #: include/posts/class-bulk-delete-posts.php:688
1564
  msgid "Select the custom post types from which you want to delete posts"
1565
  msgstr ""
1566
 
1567
+ #: dist/include/posts/class-bulk-delete-posts.php:717
1568
+ #: include/posts/class-bulk-delete-posts.php:717
1569
  msgid ""
1570
  "This WordPress installation doesn't have any non-empty custom post types"
1571
  msgstr ""
1572
 
1573
+ #: dist/include/posts/class-bulk-delete-posts.php:749
1574
+ #: include/posts/class-bulk-delete-posts.php:749
1575
  msgid "Posts from the selected custom post type are scheduled for deletion."
1576
  msgstr ""
1577
 
1578
+ #: dist/include/posts/class-bulk-delete-posts.php:753
1579
+ #: include/posts/class-bulk-delete-posts.php:753
1580
  msgid "Deleted %d post from the selected custom post type"
1581
  msgid_plural "Deleted %d posts from the selected custom post type"
1582
  msgstr[0] ""
1583
  msgstr[1] ""
1584
 
1585
+ #: dist/include/posts/class-bulk-delete-posts.php:828
1586
+ #: include/posts/class-bulk-delete-posts.php:828
1587
  msgid "Delete posts and pages that have the following Permalink"
1588
  msgstr ""
1589
 
1590
+ #: dist/include/posts/class-bulk-delete-posts.php:834
1591
+ #: include/posts/class-bulk-delete-posts.php:834
1592
  msgid "Enter one post url (not post ids) per line"
1593
  msgstr ""
1594
 
1595
+ #: dist/include/posts/class-bulk-delete-posts.php:870
1596
+ #: include/posts/class-bulk-delete-posts.php:870
1597
  msgid "Deleted %d post with the specified urls"
1598
  msgid_plural "Deleted %d posts with the specified urls"
1599
  msgstr[0] ""
1600
  msgstr[1] ""
1601
 
1602
+ #: dist/include/posts/class-bulk-delete-posts.php:897
1603
+ #: include/posts/class-bulk-delete-posts.php:897
1604
  msgid "Select the posts which you want to delete"
1605
  msgstr ""
1606
 
1607
+ #: dist/include/posts/class-bulk-delete-posts.php:904
1608
+ #: include/posts/class-bulk-delete-posts.php:904
1609
  msgid "All Revisions"
1610
  msgstr ""
1611
 
1612
+ #: dist/include/posts/class-bulk-delete-posts.php:904
1613
+ #: include/posts/class-bulk-delete-posts.php:904
1614
  msgid "Revisions"
1615
  msgstr ""
1616
 
1617
+ #: dist/include/posts/class-bulk-delete-posts.php:926
1618
+ #: include/posts/class-bulk-delete-posts.php:926
1619
  msgid "Deleted %d post revision"
1620
  msgid_plural "Deleted %d post revisions"
1621
  msgstr[0] ""
1622
  msgstr[1] ""
1623
 
1624
+ #: dist/include/posts/class-bulk-delete-posts.php:974
1625
+ #: include/posts/class-bulk-delete-posts.php:974
1626
  msgid ""
1627
  "Are you sure you want to delete all the posts based on the selected option?"
1628
  msgstr ""
1629
 
1630
+ #: dist/include/posts/class-bulk-delete-posts.php:975
1631
+ #: include/posts/class-bulk-delete-posts.php:975
1632
  msgid "Please select posts from at least one option"
1633
  msgstr ""
1634
 
1635
+ #: dist/include/posts/class-bulk-delete-posts.php:979
1636
+ #: include/posts/class-bulk-delete-posts.php:979
1637
  msgid "Please select at least one category"
1638
  msgstr ""
1639
 
1640
+ #: dist/include/posts/class-bulk-delete-posts.php:983
1641
+ #: include/posts/class-bulk-delete-posts.php:983
1642
  msgid "Please select at least one tag"
1643
  msgstr ""
1644
 
1645
+ #: dist/include/posts/class-bulk-delete-posts.php:987
1646
+ #: include/posts/class-bulk-delete-posts.php:987
1647
  msgid "Please enter at least one post url"
1648
  msgstr ""
1649
 
1650
+ #: dist/include/posts/class-bulk-delete-posts.php:1011
1651
+ #: include/posts/class-bulk-delete-posts.php:1011
1652
  msgid "The selected scheduled job was successfully deleted "
1653
  msgstr ""
1654
 
1655
+ #: dist/include/settings/class-bd-settings-page.php:47
1656
+ #: dist/include/settings/class-bd-settings-page.php:101
1657
+ #: include/settings/class-bd-settings-page.php:47
1658
+ #: include/settings/class-bd-settings-page.php:101
1659
  msgid "Bulk Delete Settings"
1660
  msgstr ""
1661
 
1662
+ #: dist/include/settings/class-bd-settings-page.php:48
1663
+ #: include/settings/class-bd-settings-page.php:48
1664
  msgid "Settings"
1665
  msgstr ""
1666
 
1669
  msgid "Add Addon License"
1670
  msgstr ""
1671
 
1672
+ #: dist/include/system-info/class-bd-system-info-page.php:50
1673
+ #: include/system-info/class-bd-system-info-page.php:50
1674
  msgid "Bulk Delete - System Info"
1675
  msgstr ""
1676
 
1677
+ #: dist/include/system-info/class-bd-system-info-page.php:51
1678
+ #: include/system-info/class-bd-system-info-page.php:51
1679
  msgid "System Info"
1680
  msgstr ""
1681
 
1682
+ #: dist/include/system-info/class-bd-system-info-page.php:55
1683
+ #: include/system-info/class-bd-system-info-page.php:55
1684
  msgid "Please include this information when posting support requests."
1685
  msgstr ""
1686
 
1687
+ #: dist/include/system-info/class-bd-system-info-page.php:75
1688
+ #: include/system-info/class-bd-system-info-page.php:75
1689
  msgid ""
1690
  "SAVEQUERIES is <a href=\"%s\" target=\"_blank\">enabled</a>. This puts "
1691
  "additional load on the memory and will restrict the number of items that can "
1692
  "be deleted."
1693
  msgstr ""
1694
 
1695
+ #: dist/include/system-info/class-bd-system-info-page.php:83
1696
+ #: include/system-info/class-bd-system-info-page.php:83
1697
  msgid ""
1698
  "DISABLE_WP_CRON is <a href=\"%s\" target=\"_blank\">enabled</a>. This "
1699
  "prevents scheduler from running."
1700
  msgstr ""
1701
 
1702
+ #: dist/include/system-info/class-bd-system-info-page.php:101
1703
+ #: include/system-info/class-bd-system-info-page.php:101
1704
  msgid ""
1705
  "To copy the system info, click below then press Ctrl + C (PC) or Cmd + C "
1706
  "(Mac)."
1707
  msgstr ""
1708
 
1709
+ #: dist/include/ui/admin-ui.php:23 include/ui/admin-ui.php:23
1710
  msgid ""
1711
  "Thank you for using <a href = \"%1$s\">Bulk Delete</a> plugin! Kindly <a "
1712
  "href = \"%2$s\">rate us</a> at <a href = \"%2$s\">WordPress.org</a>"
1713
  msgstr ""
1714
 
1715
+ #: dist/include/ui/admin-ui.php:76 include/ui/admin-ui.php:76
1716
  msgid "Buy Addons"
1717
  msgstr ""
1718
 
1741
  msgid "Other Plugin's by Author"
1742
  msgstr ""
1743
 
1744
+ #: dist/include/ui/class-bulk-delete-help-screen.php:59
1745
+ #: dist/include/ui/class-bulk-delete-help-screen.php:71
1746
+ #: dist/include/users/class-bd-users-page.php:88
1747
+ #: include/ui/class-bulk-delete-help-screen.php:59
1748
+ #: include/ui/class-bulk-delete-help-screen.php:71
1749
+ #: include/users/class-bd-users-page.php:88
1750
  #: tmp_addon/class-bd-attachment-page.php:62
1751
  msgid "Overview"
1752
  msgstr ""
1753
 
1754
+ #: dist/include/ui/class-bulk-delete-help-screen.php:61
1755
+ #: include/ui/class-bulk-delete-help-screen.php:61
1756
  msgid ""
1757
  "This screen contains different modules that allows you to delete posts or "
1758
  "schedule them for deletion."
1759
  msgstr ""
1760
 
1761
+ #: dist/include/ui/class-bulk-delete-help-screen.php:73
1762
+ #: include/ui/class-bulk-delete-help-screen.php:73
1763
  msgid ""
1764
  "This screen contains different modules that allows you to delete pages or "
1765
  "schedule them for deletion."
1766
  msgstr ""
1767
 
1768
+ #: dist/include/ui/class-bulk-delete-help-screen.php:83
1769
+ #: include/ui/class-bulk-delete-help-screen.php:83
1770
  msgid "About Plugin"
1771
  msgstr ""
1772
 
1773
+ #: dist/include/ui/class-bulk-delete-help-screen.php:106
1774
+ #: include/ui/class-bulk-delete-help-screen.php:106
1775
  msgid "This plugin allows you to perform bulk operations in WordPress easily."
1776
  msgstr ""
1777
 
1778
+ #: dist/include/ui/class-bulk-delete-help-screen.php:107
1779
+ #: include/ui/class-bulk-delete-help-screen.php:107
1780
  msgid ""
1781
  "This plugin can be used to delete the posts, pages or users using various "
1782
  "filters and conditions."
1783
  msgstr ""
1784
 
1785
+ #: dist/include/ui/form.php:43 include/ui/form.php:43
 
 
 
 
 
 
 
 
 
 
 
 
1786
  msgid "Only restrict to %s which are "
1787
  msgstr ""
1788
 
1789
+ #: dist/include/ui/form.php:83 include/ui/form.php:83
1790
  #: tmp_addon/bulk-delete-posts-by-attachment.php:190
1791
  #: tmp_addon/bulk-delete-posts-by-content.php:210
1792
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:235
1793
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:209
1794
  msgid "Public posts"
1795
  msgstr ""
1796
 
1797
+ #: dist/include/ui/form.php:84 include/ui/form.php:84
1798
  #: tmp_addon/bulk-delete-posts-by-attachment.php:191
1799
  #: tmp_addon/bulk-delete-posts-by-content.php:211
1800
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:236
1801
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:211
1802
  msgid "Private Posts"
1803
  msgstr ""
1804
 
1805
+ #: dist/include/ui/form.php:107 include/ui/form.php:107
1806
  msgid "Use this option if there are more than 1000 %s and the script timesout."
1807
  msgstr ""
1808
 
1809
+ #: dist/include/ui/form.php:144 include/ui/form.php:144
1810
  msgid ""
1811
  "Enter time in <strong>Y-m-d H:i:s</strong> format or enter <strong>now</"
1812
  "strong> to use current time"
1813
  msgstr ""
1814
 
1815
+ #: dist/include/ui/form.php:237 dist/include/util/class-bd-util.php:281
1816
+ #: include/ui/form.php:238 include/util/class-bd-util.php:281
1817
  msgid "All"
1818
  msgstr ""
1819
 
1820
+ #: dist/include/users/class-bd-users-page.php:48
1821
+ #: dist/include/users/class-bd-users-page.php:49
1822
+ #: dist/include/users/class-bd-users-page.php:72
1823
+ #: include/users/class-bd-users-page.php:48
1824
+ #: include/users/class-bd-users-page.php:49
1825
+ #: include/users/class-bd-users-page.php:72
1826
  msgid "Bulk Delete Users"
1827
  msgstr ""
1828
 
1829
+ #: dist/include/users/class-bd-users-page.php:53
1830
+ #: include/users/class-bd-users-page.php:53
1831
  msgid "WARNING: Users deleted once cannot be retrieved back. Use with caution."
1832
  msgstr ""
1833
 
1834
+ #: dist/include/users/class-bd-users-page.php:90
1835
+ #: include/users/class-bd-users-page.php:90
1836
  #: tmp_addon/class-bd-attachment-page.php:64
1837
  msgid ""
1838
  "This screen contains different modules that allows you to delete users or "
1839
  "schedule them for deletion."
1840
  msgstr ""
1841
 
1842
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:50
1843
+ #: include/users/modules/class-bulk-delete-users-by-user-meta.php:50
1844
  msgid "By User Meta"
1845
  msgstr ""
1846
 
1847
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:51
1848
+ #: include/users/modules/class-bulk-delete-users-by-user-meta.php:51
1849
  msgid "Users from with the selected user meta are scheduled for deletion."
1850
  msgstr ""
1851
 
1852
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:52
1853
+ #: include/users/modules/class-bulk-delete-users-by-user-meta.php:52
1854
  msgid "Deleted %d user with the selected user meta"
1855
  msgstr ""
1856
 
1857
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:53
1858
+ #: include/users/modules/class-bulk-delete-users-by-user-meta.php:53
1859
  msgid "Deleted %d users with the selected user meta"
1860
  msgstr ""
1861
 
1862
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:65
1863
+ #: include/users/modules/class-bulk-delete-users-by-user-meta.php:65
1864
  msgid "Select the user meta from which you want to delete users"
1865
  msgstr ""
1866
 
1867
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:85
1868
+ #: include/users/modules/class-bulk-delete-users-by-user-meta.php:85
1869
  #: tmp_addon/bulk-delete-comment-meta.php:145
1870
  #: tmp_addon/bulk-delete-post-meta.php:145
1871
  #: tmp_addon/bulk-delete-user-meta.php:145
1872
  msgid "Meta Value"
1873
  msgstr ""
1874
 
1875
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:90
1876
+ #: include/users/modules/class-bulk-delete-users-by-user-meta.php:90
 
1877
  msgid "If you want to check for null values, then leave the value column blank"
1878
  msgstr ""
1879
 
1880
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:167
1881
+ #: include/users/modules/class-bulk-delete-users-by-user-meta.php:167
1882
  msgid ""
1883
  "Are you sure you want to delete all the users from the selected user meta?"
1884
  msgstr ""
1885
 
1886
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-meta.php:170
1887
+ #: include/users/modules/class-bulk-delete-users-by-user-meta.php:170
1888
  msgid ""
1889
  "Please enter the value for the user meta field based on which you want to "
1890
  "delete users"
1891
  msgstr ""
1892
 
1893
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:51
1894
+ #: include/users/modules/class-bulk-delete-users-by-user-role.php:51
1895
  msgid "Users from the selected userrole are scheduled for deletion."
1896
  msgstr ""
1897
 
1898
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:52
1899
+ #: include/users/modules/class-bulk-delete-users-by-user-role.php:52
1900
  msgid "Deleted %d user from the selected roles"
1901
  msgstr ""
1902
 
1903
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:53
1904
+ #: include/users/modules/class-bulk-delete-users-by-user-role.php:53
1905
  msgid "Deleted %d users from the selected roles"
1906
  msgstr ""
1907
 
1908
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:65
1909
+ #: include/users/modules/class-bulk-delete-users-by-user-role.php:65
1910
  msgid "Select the user roles from which you want to delete users"
1911
  msgstr ""
1912
 
1913
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:154
1914
+ #: include/users/modules/class-bulk-delete-users-by-user-role.php:154
1915
  msgid ""
1916
  "Are you sure you want to delete all the users from the selected user role?"
1917
  msgstr ""
1918
 
1919
+ #: dist/include/users/modules/class-bulk-delete-users-by-user-role.php:157
1920
+ #: include/users/modules/class-bulk-delete-users-by-user-role.php:157
1921
  msgid "Select at least one user role from which users should be deleted"
1922
  msgstr ""
1923
 
1924
+ #: dist/include/util/class-bd-util.php:125 include/util/class-bd-util.php:125
1925
  msgctxt "Cron table date format"
1926
  msgid "M j, Y @ G:i"
1927
  msgstr ""
1928
 
1929
+ #: dist/include/util/class-bd-util.php:273 include/util/class-bd-util.php:273
1930
  msgid "All mime types"
1931
  msgstr ""
1932
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1933
  #: tmp_addon/bulk-delete-comment-meta.php:123
1934
  msgid "Comment Meta Value "
1935
  msgstr ""
1937
  #: tmp_addon/bulk-delete-comment-meta.php:125
1938
  #: tmp_addon/bulk-delete-post-meta.php:125
1939
  #: tmp_addon/bulk-delete-posts-by-content.php:165
1940
+ #: tmp_addon/bulk-delete-posts-by-title.php:132
1941
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:171
1942
  #: tmp_addon/bulk-delete-user-meta.php:125
1943
  msgid "equal to"
1944
  msgstr ""
1946
  #: tmp_addon/bulk-delete-comment-meta.php:126
1947
  #: tmp_addon/bulk-delete-post-meta.php:126
1948
  #: tmp_addon/bulk-delete-posts-by-content.php:166
1949
+ #: tmp_addon/bulk-delete-posts-by-title.php:133
1950
  #: tmp_addon/bulk-delete-user-meta.php:126
1951
  msgid "not equal to"
1952
  msgstr ""
1953
 
1954
  #: tmp_addon/bulk-delete-comment-meta.php:127
1955
  #: tmp_addon/bulk-delete-post-meta.php:127
1956
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:172
1957
  #: tmp_addon/bulk-delete-user-meta.php:127
1958
  msgid "less than"
1959
  msgstr ""
1966
 
1967
  #: tmp_addon/bulk-delete-comment-meta.php:129
1968
  #: tmp_addon/bulk-delete-post-meta.php:129
1969
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:173
1970
  #: tmp_addon/bulk-delete-user-meta.php:129
1971
  msgid "greater than"
1972
  msgstr ""
2049
  #: tmp_addon/bulk-delete-post-meta.php:213
2050
  #: tmp_addon/bulk-delete-posts-by-attachment.php:377
2051
  #: tmp_addon/bulk-delete-posts-by-content.php:388
2052
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:569
2053
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:367
2054
+ #: tmp_addon/bulk-delete-posts-by-title.php:428
2055
  #: tmp_addon/bulk-delete-posts-by-user-role.php:325
2056
  #: tmp_addon/bulk-delete-posts-by-user.php:335
2057
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:513
2058
  #: tmp_addon/bulk-delete-scheduler-email.php:335
2059
  #: tmp_addon/bulk-delete-scheduler-for-deleting-pages-by-status.php:108
2060
  #: tmp_addon/bulk-delete-scheduler-for-deleting-posts-by-attachment.php:114
2154
  msgid "in the last"
2155
  msgstr ""
2156
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2157
  #: tmp_addon/bulk-delete-post-meta.php:123
2158
  msgid "Post Meta Value "
2159
  msgstr ""
2163
  msgstr ""
2164
 
2165
  #: tmp_addon/bulk-delete-posts-by-attachment.php:129
2166
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:129
2167
  msgid "Select the post type whose posts you want to delete"
2168
  msgstr ""
2169
 
2196
  msgstr ""
2197
 
2198
  #: tmp_addon/bulk-delete-posts-by-content.php:135
2199
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:149
2200
  msgid "Select the fields to check for"
2201
  msgstr ""
2202
 
2203
  #: tmp_addon/bulk-delete-posts-by-content.php:140
2204
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:155
2205
  msgid "Check only Post Content"
2206
  msgstr ""
2207
 
2208
  #: tmp_addon/bulk-delete-posts-by-content.php:145
2209
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:161
2210
  msgid "Check only Post Title"
2211
  msgstr ""
2212
 
2223
  msgstr ""
2224
 
2225
  #: tmp_addon/bulk-delete-posts-by-content.php:167
2226
+ #: tmp_addon/bulk-delete-posts-by-title.php:134
2227
  msgid "contains"
2228
  msgstr ""
2229
 
2230
  #: tmp_addon/bulk-delete-posts-by-content.php:168
2231
+ #: tmp_addon/bulk-delete-posts-by-title.php:135
2232
  msgid "doesn't contains"
2233
  msgstr ""
2234
 
2235
  #: tmp_addon/bulk-delete-posts-by-content.php:169
2236
+ #: tmp_addon/bulk-delete-posts-by-title.php:136
2237
  msgid "starts with"
2238
  msgstr ""
2239
 
2240
  #: tmp_addon/bulk-delete-posts-by-content.php:170
2241
+ #: tmp_addon/bulk-delete-posts-by-title.php:137
2242
  msgid "ends with"
2243
  msgstr ""
2244
 
2259
  msgstr ""
2260
 
2261
  #: tmp_addon/bulk-delete-posts-by-content.php:291
2262
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:299
2263
  msgid "Posts matching the selected content setting are scheduled for deletion."
2264
  msgstr ""
2265
 
2266
  #: tmp_addon/bulk-delete-posts-by-content.php:295
2267
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:303
2268
  msgid "Deleted %d post using the selected content condition"
2269
  msgid_plural "Deleted %d posts using the selected content condition"
2270
  msgstr[0] ""
2271
  msgstr[1] ""
2272
 
2273
  #: tmp_addon/bulk-delete-posts-by-content.php:366
2274
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:489
2275
  msgid ""
2276
  "Are you sure you want to delete all the posts that match the selected "
2277
  "content criteria?"
2281
  msgid "Please enter the content based on which you want to delete posts"
2282
  msgstr ""
2283
 
2284
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:134
2285
  msgid "Choose your custom field settings"
2286
  msgstr ""
2287
 
2288
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:138
2289
  msgid "Key "
2290
  msgstr ""
2291
 
2292
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:143
2293
  msgid "equal to (string)"
2294
  msgstr ""
2295
 
2296
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:144
2297
  msgid "not equal to (string)"
2298
  msgstr ""
2299
 
2300
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:145
2301
  msgid "equal to (date)"
2302
  msgstr ""
2303
 
2304
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:146
2305
  msgid "not equal to (date)"
2306
  msgstr ""
2307
 
2308
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:147
2309
  msgid "less than (date)"
2310
  msgstr ""
2311
 
2312
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:148
2313
  msgid "greater than (date)"
2314
  msgstr ""
2315
 
2316
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:149
2317
  msgid "less than (number)"
2318
  msgstr ""
2319
 
2320
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:150
2321
  msgid "greater than (number)"
2322
  msgstr ""
2323
 
2324
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:154
2325
  msgid "Value "
2326
  msgstr ""
2327
 
2328
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:158
2329
+ msgid "If you want to check for null values, then leave the value field blank."
2330
+ msgstr ""
2331
+
2332
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:162
2333
+ msgid "Enter the date"
2334
+ msgstr ""
2335
+
2336
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:163
2337
+ msgid "Or"
2338
+ msgstr ""
2339
+
2340
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:165
2341
+ msgid "Select Relative date"
2342
+ msgstr ""
2343
+
2344
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:166
2345
+ msgid "Yesterday"
2346
+ msgstr ""
2347
+
2348
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:167
2349
+ msgid "Today"
2350
+ msgstr ""
2351
+
2352
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:168
2353
+ msgid "Tomorrow"
2354
+ msgstr ""
2355
+
2356
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:169
2357
+ msgid "Custom"
2358
+ msgstr ""
2359
+
2360
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:172
2361
+ msgid "You can select a date or enter a date which is relative to today."
2362
+ msgstr ""
2363
+
2364
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:177
2365
+ msgid "Day"
2366
+ msgstr ""
2367
+
2368
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:178
2369
+ msgid "Week"
2370
  msgstr ""
2371
 
2372
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:179
2373
+ msgid "Month"
2374
  msgstr ""
2375
 
2376
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:180
2377
+ msgid "Year"
2378
  msgstr ""
2379
 
2380
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:188
2381
+ msgid "Meta value date format"
2382
+ msgstr ""
2383
+
2384
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:191
2385
+ msgid "If you leave date format blank, then '%Y-%m-%d', will be assumed."
2386
+ msgstr ""
2387
+
2388
+ #. translators: 1 Mysql Format specifier url.
2389
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:197
2390
+ msgid ""
2391
+ "If you are storing the date in a format other than <em>YYYY-MM-DD</em> then "
2392
+ "enter the date format using <a href=\"%s\" target=\"_blank\" rel=\"noopener "
2393
+ "noreferrer\">Mysql format specifiers</a>."
2394
+ msgstr ""
2395
+
2396
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:338
2397
  msgid ""
2398
  "Posts matching the selected custom field setting are scheduled for deletion."
2399
  msgstr ""
2400
 
2401
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:343
2402
  msgid "Deleted %d post using the selected custom field condition"
2403
  msgid_plural "Deleted %d posts using the selected custom field condition"
2404
  msgstr[0] ""
2405
  msgstr[1] ""
2406
 
2407
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:476
2408
  msgid ""
2409
  "Are you sure you want to delete all the posts that match the entered custom "
2410
  "field condition?"
2411
  msgstr ""
2412
 
2413
+ #: tmp_addon/bulk-delete-posts-by-custom-field.php:479
2414
  msgid "Please enter the custom field based on which you want to delete posts"
2415
  msgstr ""
2416
 
2453
  msgstr ""
2454
 
2455
  #: tmp_addon/bulk-delete-posts-by-duplicate-title.php:261
2456
+ #: tmp_addon/bulk-delete-posts-by-title.php:277
2457
  msgid "Deleted %d post using the selected title condition"
2458
  msgid_plural "Deleted %d posts using the selected title condition"
2459
  msgstr[0] ""
2464
  "Are you sure you want to delete all the posts that have duplicate title?"
2465
  msgstr ""
2466
 
2467
+ #: tmp_addon/bulk-delete-posts-by-title.php:120
2468
+ msgid "Select the post type"
2469
+ msgstr ""
2470
+
2471
+ #: tmp_addon/bulk-delete-posts-by-title.php:128
2472
  msgid "Choose your title settings"
2473
  msgstr ""
2474
 
2475
+ #: tmp_addon/bulk-delete-posts-by-title.php:130
2476
  msgid "Title"
2477
  msgstr ""
2478
 
2479
  #: tmp_addon/bulk-delete-posts-by-title.php:150
 
 
 
 
2480
  msgid "Select the post status"
2481
  msgstr ""
2482
 
2483
+ #: tmp_addon/bulk-delete-posts-by-title.php:273
2484
  msgid "Posts matching the selected title setting are scheduled for deletion."
2485
  msgstr ""
2486
 
2487
+ #: tmp_addon/bulk-delete-posts-by-title.php:406
2488
  msgid ""
2489
  "Are you sure you want to delete all the posts that match the entered title?"
2490
  msgstr ""
2491
 
2492
+ #: tmp_addon/bulk-delete-posts-by-title.php:409
2493
  msgid "Please enter the title based on which you want to delete posts"
2494
  msgstr ""
2495
 
2551
  "Are you sure you want to delete all the posts belonging to the selected user?"
2552
  msgstr ""
2553
 
2554
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:117
2555
+ msgid "By Word Count"
2556
+ msgstr ""
2557
+
2558
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:134
2559
+ msgid "Select the post types from which you want to delete posts."
2560
+ msgstr ""
2561
+
2562
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:166
2563
+ msgid "Specify the word count"
2564
+ msgstr ""
2565
+
2566
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:175
2567
+ msgid "Word count"
2568
+ msgstr ""
2569
+
2570
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:176
2571
+ msgid "Word count must be a whole number."
2572
+ msgstr ""
2573
+
2574
+ #: tmp_addon/bulk-delete-posts-by-word-count.php:493
2575
+ msgid "Please specify the word count"
2576
+ msgstr ""
2577
+
2578
  #: tmp_addon/bulk-delete-scheduler-email.php:91
2579
  msgid "Scheduler Email Settings"
2580
  msgstr ""
readme.txt CHANGED
@@ -1,10 +1,10 @@
1
  === Bulk Delete ===
2
  Contributors: sudar
3
- Tags: mass, bulk, delete, post, comment, draft, revision, page, user, meta fields
4
- Requires at least: 3.9
5
  Tested up to: 4.9
6
  Donate Link: http://sudarmuthu.com/if-you-wanna-thank-me
7
- Stable tag: 5.5.7
8
 
9
  Bulk delete posts, pages, users, attachments and meta fields based on different conditions and filters.
10
 
@@ -95,7 +95,7 @@ Like posts, all the above options support the following filters as well
95
 
96
  - Delete Attachments (Available as a [Pro addon](http://bulkwp.com/addons/bulk-delete-attachments/?utm_source=wprepo&utm_campaign=BulkDelete&utm_medium=readme&utm_content=bd-at))
97
 
98
- #### Deleting other items
99
  - Delete Jetpack Contact Form Messages
100
 
101
  More options coming soon :)
@@ -275,6 +275,16 @@ You can contact us by posting about it in our [support forum](http://bulkwp.com/
275
  This Readme file was generated using <a href = 'http://sudarmuthu.com/wordpress/wp-readme'>wp-readme</a>, which generates readme files for WordPress Plugins.
276
  == Changelog ==
277
 
 
 
 
 
 
 
 
 
 
 
278
  = 2017-11-07 - v5.5.7 =
279
 
280
  - Enhancements
@@ -588,6 +598,9 @@ This Readme file was generated using <a href = 'http://sudarmuthu.com/wordpress/
588
 
589
  == Upgrade Notice ==
590
 
 
 
 
591
  = 5.5.7 =
592
  Improved the UI by removing all unnecessary sidebars.
593
 
1
  === Bulk Delete ===
2
  Contributors: sudar
3
+ Tags: mass, bulk, delete, post, draft, revision, page, user, meta fields
4
+ Requires at least: 4.0
5
  Tested up to: 4.9
6
  Donate Link: http://sudarmuthu.com/if-you-wanna-thank-me
7
+ Stable tag: 5.6.0
8
 
9
  Bulk delete posts, pages, users, attachments and meta fields based on different conditions and filters.
10
 
95
 
96
  - Delete Attachments (Available as a [Pro addon](http://bulkwp.com/addons/bulk-delete-attachments/?utm_source=wprepo&utm_campaign=BulkDelete&utm_medium=readme&utm_content=bd-at))
97
 
98
+ #### Deleting content from other plugins
99
  - Delete Jetpack Contact Form Messages
100
 
101
  More options coming soon :)
275
  This Readme file was generated using <a href = 'http://sudarmuthu.com/wordpress/wp-readme'>wp-readme</a>, which generates readme files for WordPress Plugins.
276
  == Changelog ==
277
 
278
+ = 2017-12-28 - v5.6.0 =
279
+
280
+ - New Features
281
+ - Added the ability to delete posts based on custom post status.
282
+ - Added the ability to filter delete users based on post count.
283
+ - Added the ability to filter the deletion of Jetpack contact messages using various filters.
284
+
285
+ - Enhancements
286
+ - Now works in PHP version from 5.2 to 7.2
287
+
288
  = 2017-11-07 - v5.5.7 =
289
 
290
  - Enhancements
598
 
599
  == Upgrade Notice ==
600
 
601
+ = 5.6.0 =
602
+ Added the ability to delete posts based on custom post status
603
+
604
  = 5.5.7 =
605
  Improved the UI by removing all unnecessary sidebars.
606