Smush Image Compression and Optimization - Version 2.1.5

Version Description

  • Fixed: WP Media Folder Plugin compatibility
  • Fixed: Warning on Plugins Page
  • Updated: Settings Page styling
Download this release

Release Info

Developer UmeshSingla
Plugin Icon 128x128 Smush Image Compression and Optimization
Version 2.1.5
Comparing to
See all releases

Code changes from version 2.1.4 to 2.1.5

assets/css/images/ui-bg_glass_65_ffffff_1x400.png ADDED
Binary file
assets/css/wp-smushit-admin.css CHANGED
@@ -288,7 +288,7 @@ div#wp-smush-progress-status {
288
 
289
  #wp-smush-progress-status p {
290
  float: left;
291
- width: 50%;
292
  }
293
 
294
  div#wp-smush-progress-status p::before {
@@ -377,7 +377,41 @@ button .wp-smush-loader-wrap {
377
  padding: 5px 5px 5px 0;
378
  min-width: 323px;
379
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
380
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
381
  /*Pro rows*/
382
  #wp-smush-options-wrap .wp-smush-pro-features .wp-smush-setting-row {
383
  margin: 5px 20px 5px 25px;
288
 
289
  #wp-smush-progress-status p {
290
  float: left;
291
+ max-width: 100%;
292
  }
293
 
294
  div#wp-smush-progress-status p::before {
377
  padding: 5px 5px 5px 0;
378
  min-width: 323px;
379
  }
380
+ .wp-smushit-container-wrap {
381
+ display: inline-block;
382
+ max-width: 790px;
383
+ padding: 0 10px 0 0;
384
+ }
385
+ .wp-smushit-container-wrap.smush-full-width {
386
+ max-width: 100%;
387
+ }
388
+ .wp-smushit-features-wrap{
389
+ display: inline-block;
390
+ width: 270px;
391
+ vertical-align: top;
392
+ }
393
 
394
+ /** Media Query for screen size smaller than 1275px **/
395
+ @media screen and (max-width: 1275px) {
396
+ .wp-smushit-features-wrap {
397
+ display: block;
398
+ width: 100%;
399
+ }
400
+ }
401
+
402
+ .wp-smushit-features-inner{
403
+ border: 0;
404
+ padding: 1px 15px;
405
+ position: relative;
406
+ }
407
+ /** Pro Version **/
408
+ .wp-smush-pro-user.wp-smushit-features-inner {
409
+ padding: 1px 20px 1px 10px;
410
+ }
411
+ .wp-smushit-features-inner .notice-dismiss {
412
+ padding: 3px 1px 9px 9px;
413
+ text-decoration: none;
414
+ }
415
  /*Pro rows*/
416
  #wp-smush-options-wrap .wp-smush-pro-features .wp-smush-setting-row {
417
  margin: 5px 20px 5px 25px;
assets/js/wp-smushit-admin.js CHANGED
@@ -410,9 +410,29 @@ jQuery(function ($) {
410
  new WP_Smush.Smush($(this), true, 'nextgen');
411
  return;
412
  });
 
413
  /** Show help text on help image hover **/
414
  $( document ).tooltip();
415
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
416
  });
417
  (function ($) {
418
  var Smush = function (element, options) {
410
  new WP_Smush.Smush($(this), true, 'nextgen');
411
  return;
412
  });
413
+
414
  /** Show help text on help image hover **/
415
  $( document ).tooltip();
416
 
417
+ /** Dismiss the notice and store it in options table **/
418
+ $('.wp-smush-pro-feature-dismiss').on('click', function(e){
419
+ e.preventDefault();
420
+ var $el = $(this).parents().eq(1);
421
+
422
+ $el.fadeTo( 100, 0, function() {
423
+ $el.slideUp( 100, function() {
424
+ $el.remove();
425
+ });
426
+ });
427
+
428
+ //Send a ajax request to save the dismissed notice option
429
+ var param = {
430
+ action: 'dismiss_smush_notice'
431
+ };
432
+ $.post(ajaxurl, param );
433
+
434
+ });
435
+
436
  });
437
  (function ($) {
438
  var Smush = function (element, options) {
languages/wp-smushit.pot CHANGED
@@ -2,9 +2,9 @@
2
  # This file is distributed under the same license as the WP Smush package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: WP Smush 2.1.4\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/support/plugin/wp-smushit\n"
7
- "POT-Creation-Date: 2016-02-25 07:02:08+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
@@ -40,298 +40,298 @@ msgstr ""
40
  msgid "Rate %s"
41
  msgstr ""
42
 
43
- #: lib/class-wp-smush-admin.php:125 lib/class-wp-smush-admin.php:346
44
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:54
45
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:73
46
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:75
47
  msgid "WP Smush"
48
  msgstr ""
49
 
50
- #: lib/class-wp-smush-admin.php:256 lib/class-wp-smush-admin.php:1039
51
- #: lib/class-wp-smush-admin.php:1055
52
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:140
53
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:369
54
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:381
55
  msgid "Bulk Smush Now"
56
  msgstr ""
57
 
58
- #: lib/class-wp-smush-admin.php:258 lib/class-wp-smush-admin.php:1059
59
  msgid "Bulk Smush %d Attachments"
60
  msgstr ""
61
 
62
- #: lib/class-wp-smush-admin.php:262
63
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:143
64
  msgid "Smushing in Progress"
65
  msgstr ""
66
 
67
- #: lib/class-wp-smush-admin.php:263 lib/class-wp-smush-admin.php:1049
68
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:144
69
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:375
70
  msgid "All Done!"
71
  msgstr ""
72
 
73
- #: lib/class-wp-smush-admin.php:265
74
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:146
75
  msgid "Ops!... something went wrong"
76
  msgstr ""
77
 
78
- #: lib/class-wp-smush-admin.php:266 lib/class-wp-smush.php:808
79
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:147
80
  #: lib/nextgen-integration/class-wp-smush-nextgen-stats.php:230
81
  msgid "Super-Smush"
82
  msgstr ""
83
 
84
- #: lib/class-wp-smush-admin.php:267
85
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:148
86
  msgid "Smush it"
87
  msgstr ""
88
 
89
- #: lib/class-wp-smush-admin.php:268
90
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:149
91
  msgid "Smush Now"
92
  msgstr ""
93
 
94
- #: lib/class-wp-smush-admin.php:269
95
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:150
96
  msgid "Sending ..."
97
  msgstr ""
98
 
99
- #: lib/class-wp-smush-admin.php:270
100
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:151
101
  msgid "{{errors}} image(s) were skipped due to an error."
102
  msgstr ""
103
 
104
- #: lib/class-wp-smush-admin.php:271
105
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:152
106
  msgid "All images are Super-Smushed."
107
  msgstr ""
108
 
109
- #: lib/class-wp-smush-admin.php:310
110
  msgid "Smush all images, including originals."
111
  msgstr ""
112
 
113
- #: lib/class-wp-smush-admin.php:313 lib/class-wp-smush.php:1120
114
  msgid "When you upload an image to WordPress it automatically creates %s thumbnail sizes that are commonly used in your pages. WordPress also stores the original full-size image, but because these are not usually embedded on your site we don’t Smush them. Pro users can override this."
115
  msgstr ""
116
 
117
- #: lib/class-wp-smush-admin.php:316
118
  msgid "Smush images on upload"
119
  msgstr ""
120
 
121
- #: lib/class-wp-smush-admin.php:317
122
  msgid "Smush Original Image"
123
  msgstr ""
124
 
125
- #: lib/class-wp-smush-admin.php:318
126
  msgid "Super-Smush images"
127
  msgstr ""
128
 
129
- #: lib/class-wp-smush-admin.php:318
130
  msgid "Lossy Image Compression"
131
  msgstr ""
132
 
133
- #: lib/class-wp-smush-admin.php:319
134
  msgid "Backup Original Images"
135
  msgstr ""
136
 
137
- #: lib/class-wp-smush-admin.php:319
138
  msgid "Will nearly double the size of your Uploads Directory"
139
  msgstr ""
140
 
141
- #: lib/class-wp-smush-admin.php:320
142
  msgid "Enable NextGen Gallery integration"
143
  msgstr ""
144
 
145
- #: lib/class-wp-smush-admin.php:344
146
  msgid "WP Smush Pro"
147
  msgstr ""
148
 
149
- #: lib/class-wp-smush-admin.php:354 lib/class-wp-smush-admin.php:1114
150
  msgid "Settings"
151
  msgstr ""
152
 
153
- #: lib/class-wp-smush-admin.php:427
154
  msgid "PRO FEATURES"
155
  msgstr ""
156
 
157
- #: lib/class-wp-smush-admin.php:433
158
  msgid "These features are available in Pro Version of the plugin."
159
  msgstr ""
160
 
161
- #: lib/class-wp-smush-admin.php:460
162
  msgid "Save Changes"
163
  msgstr ""
164
 
165
- #: lib/class-wp-smush-admin.php:549
166
  msgid "%d image is over 1MB so will be skipped using the free version of the plugin."
167
  msgid_plural "%d images are over 1MB so will be skipped using the free version of the plugin."
168
  msgstr[0] ""
169
  msgstr[1] ""
170
 
171
- #: lib/class-wp-smush-admin.php:558
172
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:415
173
  msgid "Smush in Bulk"
174
  msgstr ""
175
 
176
- #: lib/class-wp-smush-admin.php:563
177
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:428
178
  msgid "Congratulations, all your images are currently Smushed!"
179
  msgstr ""
180
 
181
- #: lib/class-wp-smush-admin.php:572
182
  msgid "%d attachment in your media library has not been smushed."
183
  msgid_plural "%d image attachments in your media library have not been smushed yet."
184
  msgstr[0] ""
185
  msgstr[1] ""
186
 
187
- #: lib/class-wp-smush-admin.php:576
188
  msgid "Remove size limit »"
189
  msgstr ""
190
 
191
- #: lib/class-wp-smush-admin.php:581
192
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:434
193
  msgid ""
194
  "Please be aware, smushing a large number of images can take a while depending on your server and network speed.\n"
195
  "\t\t\t\t\t\t<strong>You must keep this page open while the bulk smush is processing</strong>, but you can leave at any time and come back to continue where it left off."
196
  msgstr ""
197
 
198
- #: lib/class-wp-smush-admin.php:586
199
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:439
200
  msgid "Free accounts are limited to bulk smushing %d attachments per request. You will need to click to start a new bulk job after each %d attachments."
201
  msgstr ""
202
 
203
- #: lib/class-wp-smush-admin.php:587
204
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:440
205
  msgid "Remove limits &raquo;"
206
  msgstr ""
207
 
208
- #: lib/class-wp-smush-admin.php:607
209
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:459
210
  msgid "When you <a href=\"%s\">upload some images</a> they will be available to smush here."
211
  msgstr ""
212
 
213
- #: lib/class-wp-smush-admin.php:613 lib/class-wp-smush-admin.php:853
214
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:465
215
  msgid "You can also smush images individually from your <a href=\"%s\">Media Library</a>."
216
  msgstr ""
217
 
218
- #: lib/class-wp-smush-admin.php:668
219
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:337
220
  msgid "Reduced by "
221
  msgstr ""
222
 
223
- #: lib/class-wp-smush-admin.php:678
224
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:347
225
  msgid "<span class=\"done-count\">%d</span> of <span class=\"total-count\">%d</span> total attachments have been smushed"
226
  msgstr ""
227
 
228
- #: lib/class-wp-smush-admin.php:734
229
  msgid "Smush request timed out, You can try setting a higher value for `WP_SMUSH_API_TIMEOUT`."
230
  msgstr ""
231
 
232
- #: lib/class-wp-smush-admin.php:749 lib/class-wp-smush-nextgen.php:321
233
  msgid "You don't have permission to work with uploaded files."
234
  msgstr ""
235
 
236
- #: lib/class-wp-smush-admin.php:753 lib/class-wp-smush-nextgen.php:325
237
  msgid "No attachment ID was provided."
238
  msgstr ""
239
 
240
- #: lib/class-wp-smush-admin.php:823
241
  msgid "<p>Please <a href=\"%s\">upload some images</a>.</p>"
242
  msgstr ""
243
 
244
- #: lib/class-wp-smush-admin.php:841
245
  msgid "All your images are already smushed!"
246
  msgstr ""
247
 
248
- #: lib/class-wp-smush-admin.php:943
249
  msgid "<strong>%d of %d images</strong> were sent for smushing:"
250
  msgstr ""
251
 
252
- #: lib/class-wp-smush-admin.php:1246
253
  msgid "Super-Smush Images"
254
  msgstr ""
255
 
256
- #: lib/class-wp-smush-admin.php:1247
257
  msgid "We found attachments that were previously smushed losslessly. If desired you can Super-Smush them now for more savings with almost no noticeable quality loss."
258
  msgstr ""
259
 
260
- #: lib/class-wp-smush-admin.php:1255
261
  msgid "<span class=\"remaining-count\">%d</span> attachment left to Super-Smush"
262
  msgid_plural "<span class=\"remaining-count\">%d</span> attachments left to Super-Smush"
263
  msgstr[0] ""
264
  msgstr[1] ""
265
 
266
- #: lib/class-wp-smush-admin.php:1280
267
  msgid "Thanks for using WP Smush Pro! You now can:"
268
  msgstr ""
269
 
270
- #: lib/class-wp-smush-admin.php:1282 lib/class-wp-smush-admin.php:1300
271
  msgid "Smush the original Full image sizes that are normally skipped by default."
272
  msgstr ""
273
 
274
- #: lib/class-wp-smush-admin.php:1283 lib/class-wp-smush-admin.php:1301
275
  msgid "NextGen Gallery integration"
276
  msgstr ""
277
 
278
- #: lib/class-wp-smush-admin.php:1284 lib/class-wp-smush-admin.php:1302
279
  msgid "\"Super-Smush\" your images with our intelligent multi-pass lossy compression. Get 2&times; more compression than lossless with almost no noticeable quality loss!"
280
  msgstr ""
281
 
282
- #: lib/class-wp-smush-admin.php:1285 lib/class-wp-smush-admin.php:1303
283
  msgid "Get the best lossless compression. We try multiple methods to squeeze every last byte out of your images."
284
  msgstr ""
285
 
286
- #: lib/class-wp-smush-admin.php:1286
287
  msgid "Smush images up to 32MB."
288
  msgstr ""
289
 
290
- #: lib/class-wp-smush-admin.php:1287
291
  msgid "Bulk smush ALL your images with one click!"
292
  msgstr ""
293
 
294
- #: lib/class-wp-smush-admin.php:1288 lib/class-wp-smush-admin.php:1306
295
  msgid "Keep a backup of your original un-smushed images in case you want to restore later."
296
  msgstr ""
297
 
298
- #: lib/class-wp-smush-admin.php:1298
299
  msgid "Upgrade to WP Smush Pro to:"
300
  msgstr ""
301
 
302
- #: lib/class-wp-smush-admin.php:1304
303
  msgid "Smush images greater than 1MB."
304
  msgstr ""
305
 
306
- #: lib/class-wp-smush-admin.php:1305
307
  msgid "Bulk smush ALL your images with one click! No more rate limiting."
308
  msgstr ""
309
 
310
- #: lib/class-wp-smush-admin.php:1307
311
  msgid "Access 24/7/365 support from <a href=\"https://premium.wpmudev.org/support/?utm_source=wordpress.org&utm_medium=plugin&utm_campaign=WP%20Smush%20Upgrade\">the best WordPress support team on the planet</a>."
312
  msgstr ""
313
 
314
- #: lib/class-wp-smush-admin.php:1308
315
- msgid "Download <a href=\"https://premium.wpmudev.org/?utm_source=wordpress.org&utm_medium=plugin&utm_campaign=WP%20Smush%20Upgrade\">350+ other premium plugins and themes</a> included in your membership."
316
  msgstr ""
317
 
318
- #: lib/class-wp-smush-admin.php:1311
319
  msgid "Upgrade Now &raquo;"
320
  msgstr ""
321
 
322
- #: lib/class-wp-smush-admin.php:1314
323
  msgid "Already upgraded to a WPMU DEV membership? Install and Login to our Dashboard plugin to enable Smush Pro features."
324
  msgstr ""
325
 
326
- #: lib/class-wp-smush-admin.php:1316
327
  msgid "Unable to access Pro Features? <a href=\"%s\">Refresh Status</a>"
328
  msgstr ""
329
 
330
- #: lib/class-wp-smush-admin.php:1326
331
  msgid "Activate WPMU DEV Dashboard"
332
  msgstr ""
333
 
334
- #: lib/class-wp-smush-admin.php:1329
335
  msgid "Install WPMU DEV Dashboard"
336
  msgstr ""
337
 
@@ -411,12 +411,12 @@ msgid "Smush stats"
411
  msgstr ""
412
 
413
  #: lib/class-wp-smush.php:814
414
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:246
415
  msgid "Not processed"
416
  msgstr ""
417
 
418
  #: lib/class-wp-smush.php:820
419
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:252
420
  msgid "Smush Now!"
421
  msgstr ""
422
 
@@ -442,11 +442,11 @@ msgstr ""
442
  msgid "WP Bulk Smush"
443
  msgstr ""
444
 
445
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:422
446
  msgid "We didn't find any images in NextGen gallery, please upload some images."
447
  msgstr ""
448
 
449
- #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:433
450
  msgid "%d attachment in NextGen Gallery has not been smushed yet."
451
  msgid_plural "%d image attachments in NextGen Gallery have not been smushed yet."
452
  msgstr[0] ""
2
  # This file is distributed under the same license as the WP Smush package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: WP Smush 2.1.5\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/support/plugin/wp-smushit\n"
7
+ "POT-Creation-Date: 2016-03-08 10:06:11+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
40
  msgid "Rate %s"
41
  msgstr ""
42
 
43
+ #: lib/class-wp-smush-admin.php:128 lib/class-wp-smush-admin.php:341
44
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:54
45
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:73
46
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:75
47
  msgid "WP Smush"
48
  msgstr ""
49
 
50
+ #: lib/class-wp-smush-admin.php:259 lib/class-wp-smush-admin.php:1036
51
+ #: lib/class-wp-smush-admin.php:1052
52
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:140
53
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:366
54
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:378
55
  msgid "Bulk Smush Now"
56
  msgstr ""
57
 
58
+ #: lib/class-wp-smush-admin.php:261 lib/class-wp-smush-admin.php:1056
59
  msgid "Bulk Smush %d Attachments"
60
  msgstr ""
61
 
62
+ #: lib/class-wp-smush-admin.php:265
63
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:143
64
  msgid "Smushing in Progress"
65
  msgstr ""
66
 
67
+ #: lib/class-wp-smush-admin.php:266 lib/class-wp-smush-admin.php:1046
68
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:144
69
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:372
70
  msgid "All Done!"
71
  msgstr ""
72
 
73
+ #: lib/class-wp-smush-admin.php:268
74
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:146
75
  msgid "Ops!... something went wrong"
76
  msgstr ""
77
 
78
+ #: lib/class-wp-smush-admin.php:269 lib/class-wp-smush.php:808
79
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:147
80
  #: lib/nextgen-integration/class-wp-smush-nextgen-stats.php:230
81
  msgid "Super-Smush"
82
  msgstr ""
83
 
84
+ #: lib/class-wp-smush-admin.php:270
85
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:148
86
  msgid "Smush it"
87
  msgstr ""
88
 
89
+ #: lib/class-wp-smush-admin.php:271
90
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:149
91
  msgid "Smush Now"
92
  msgstr ""
93
 
94
+ #: lib/class-wp-smush-admin.php:272
95
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:150
96
  msgid "Sending ..."
97
  msgstr ""
98
 
99
+ #: lib/class-wp-smush-admin.php:273
100
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:151
101
  msgid "{{errors}} image(s) were skipped due to an error."
102
  msgstr ""
103
 
104
+ #: lib/class-wp-smush-admin.php:274
105
  #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:152
106
  msgid "All images are Super-Smushed."
107
  msgstr ""
108
 
109
+ #: lib/class-wp-smush-admin.php:313
110
  msgid "Smush all images, including originals."
111
  msgstr ""
112
 
113
+ #: lib/class-wp-smush-admin.php:316 lib/class-wp-smush.php:1120
114
  msgid "When you upload an image to WordPress it automatically creates %s thumbnail sizes that are commonly used in your pages. WordPress also stores the original full-size image, but because these are not usually embedded on your site we don’t Smush them. Pro users can override this."
115
  msgstr ""
116
 
117
+ #: lib/class-wp-smush-admin.php:319
118
  msgid "Smush images on upload"
119
  msgstr ""
120
 
121
+ #: lib/class-wp-smush-admin.php:320
122
  msgid "Smush Original Image"
123
  msgstr ""
124
 
125
+ #: lib/class-wp-smush-admin.php:321
126
  msgid "Super-Smush images"
127
  msgstr ""
128
 
129
+ #: lib/class-wp-smush-admin.php:321
130
  msgid "Lossy Image Compression"
131
  msgstr ""
132
 
133
+ #: lib/class-wp-smush-admin.php:322
134
  msgid "Backup Original Images"
135
  msgstr ""
136
 
137
+ #: lib/class-wp-smush-admin.php:322
138
  msgid "Will nearly double the size of your Uploads Directory"
139
  msgstr ""
140
 
141
+ #: lib/class-wp-smush-admin.php:323
142
  msgid "Enable NextGen Gallery integration"
143
  msgstr ""
144
 
145
+ #: lib/class-wp-smush-admin.php:341
146
  msgid "WP Smush Pro"
147
  msgstr ""
148
 
149
+ #: lib/class-wp-smush-admin.php:348 lib/class-wp-smush-admin.php:1114
150
  msgid "Settings"
151
  msgstr ""
152
 
153
+ #: lib/class-wp-smush-admin.php:418
154
  msgid "PRO FEATURES"
155
  msgstr ""
156
 
157
+ #: lib/class-wp-smush-admin.php:424
158
  msgid "These features are available in Pro Version of the plugin."
159
  msgstr ""
160
 
161
+ #: lib/class-wp-smush-admin.php:451
162
  msgid "Save Changes"
163
  msgstr ""
164
 
165
+ #: lib/class-wp-smush-admin.php:540
166
  msgid "%d image is over 1MB so will be skipped using the free version of the plugin."
167
  msgid_plural "%d images are over 1MB so will be skipped using the free version of the plugin."
168
  msgstr[0] ""
169
  msgstr[1] ""
170
 
171
+ #: lib/class-wp-smush-admin.php:549
172
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:412
173
  msgid "Smush in Bulk"
174
  msgstr ""
175
 
176
+ #: lib/class-wp-smush-admin.php:554
177
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:425
178
  msgid "Congratulations, all your images are currently Smushed!"
179
  msgstr ""
180
 
181
+ #: lib/class-wp-smush-admin.php:563
182
  msgid "%d attachment in your media library has not been smushed."
183
  msgid_plural "%d image attachments in your media library have not been smushed yet."
184
  msgstr[0] ""
185
  msgstr[1] ""
186
 
187
+ #: lib/class-wp-smush-admin.php:567
188
  msgid "Remove size limit &raquo;"
189
  msgstr ""
190
 
191
+ #: lib/class-wp-smush-admin.php:572
192
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:431
193
  msgid ""
194
  "Please be aware, smushing a large number of images can take a while depending on your server and network speed.\n"
195
  "\t\t\t\t\t\t<strong>You must keep this page open while the bulk smush is processing</strong>, but you can leave at any time and come back to continue where it left off."
196
  msgstr ""
197
 
198
+ #: lib/class-wp-smush-admin.php:577
199
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:436
200
  msgid "Free accounts are limited to bulk smushing %d attachments per request. You will need to click to start a new bulk job after each %d attachments."
201
  msgstr ""
202
 
203
+ #: lib/class-wp-smush-admin.php:578
204
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:437
205
  msgid "Remove limits &raquo;"
206
  msgstr ""
207
 
208
+ #: lib/class-wp-smush-admin.php:598
209
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:456
210
  msgid "When you <a href=\"%s\">upload some images</a> they will be available to smush here."
211
  msgstr ""
212
 
213
+ #: lib/class-wp-smush-admin.php:604 lib/class-wp-smush-admin.php:844
214
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:462
215
  msgid "You can also smush images individually from your <a href=\"%s\">Media Library</a>."
216
  msgstr ""
217
 
218
+ #: lib/class-wp-smush-admin.php:659
219
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:334
220
  msgid "Reduced by "
221
  msgstr ""
222
 
223
+ #: lib/class-wp-smush-admin.php:669
224
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:344
225
  msgid "<span class=\"done-count\">%d</span> of <span class=\"total-count\">%d</span> total attachments have been smushed"
226
  msgstr ""
227
 
228
+ #: lib/class-wp-smush-admin.php:725
229
  msgid "Smush request timed out, You can try setting a higher value for `WP_SMUSH_API_TIMEOUT`."
230
  msgstr ""
231
 
232
+ #: lib/class-wp-smush-admin.php:740 lib/class-wp-smush-nextgen.php:321
233
  msgid "You don't have permission to work with uploaded files."
234
  msgstr ""
235
 
236
+ #: lib/class-wp-smush-admin.php:744 lib/class-wp-smush-nextgen.php:325
237
  msgid "No attachment ID was provided."
238
  msgstr ""
239
 
240
+ #: lib/class-wp-smush-admin.php:814
241
  msgid "<p>Please <a href=\"%s\">upload some images</a>.</p>"
242
  msgstr ""
243
 
244
+ #: lib/class-wp-smush-admin.php:832
245
  msgid "All your images are already smushed!"
246
  msgstr ""
247
 
248
+ #: lib/class-wp-smush-admin.php:940
249
  msgid "<strong>%d of %d images</strong> were sent for smushing:"
250
  msgstr ""
251
 
252
+ #: lib/class-wp-smush-admin.php:1250
253
  msgid "Super-Smush Images"
254
  msgstr ""
255
 
256
+ #: lib/class-wp-smush-admin.php:1251
257
  msgid "We found attachments that were previously smushed losslessly. If desired you can Super-Smush them now for more savings with almost no noticeable quality loss."
258
  msgstr ""
259
 
260
+ #: lib/class-wp-smush-admin.php:1259
261
  msgid "<span class=\"remaining-count\">%d</span> attachment left to Super-Smush"
262
  msgid_plural "<span class=\"remaining-count\">%d</span> attachments left to Super-Smush"
263
  msgstr[0] ""
264
  msgstr[1] ""
265
 
266
+ #: lib/class-wp-smush-admin.php:1290
267
  msgid "Thanks for using WP Smush Pro! You now can:"
268
  msgstr ""
269
 
270
+ #: lib/class-wp-smush-admin.php:1292 lib/class-wp-smush-admin.php:1312
271
  msgid "Smush the original Full image sizes that are normally skipped by default."
272
  msgstr ""
273
 
274
+ #: lib/class-wp-smush-admin.php:1293 lib/class-wp-smush-admin.php:1313
275
  msgid "NextGen Gallery integration"
276
  msgstr ""
277
 
278
+ #: lib/class-wp-smush-admin.php:1294 lib/class-wp-smush-admin.php:1314
279
  msgid "\"Super-Smush\" your images with our intelligent multi-pass lossy compression. Get 2&times; more compression than lossless with almost no noticeable quality loss!"
280
  msgstr ""
281
 
282
+ #: lib/class-wp-smush-admin.php:1295 lib/class-wp-smush-admin.php:1315
283
  msgid "Get the best lossless compression. We try multiple methods to squeeze every last byte out of your images."
284
  msgstr ""
285
 
286
+ #: lib/class-wp-smush-admin.php:1296
287
  msgid "Smush images up to 32MB."
288
  msgstr ""
289
 
290
+ #: lib/class-wp-smush-admin.php:1297
291
  msgid "Bulk smush ALL your images with one click!"
292
  msgstr ""
293
 
294
+ #: lib/class-wp-smush-admin.php:1298 lib/class-wp-smush-admin.php:1318
295
  msgid "Keep a backup of your original un-smushed images in case you want to restore later."
296
  msgstr ""
297
 
298
+ #: lib/class-wp-smush-admin.php:1310
299
  msgid "Upgrade to WP Smush Pro to:"
300
  msgstr ""
301
 
302
+ #: lib/class-wp-smush-admin.php:1316
303
  msgid "Smush images greater than 1MB."
304
  msgstr ""
305
 
306
+ #: lib/class-wp-smush-admin.php:1317
307
  msgid "Bulk smush ALL your images with one click! No more rate limiting."
308
  msgstr ""
309
 
310
+ #: lib/class-wp-smush-admin.php:1319
311
  msgid "Access 24/7/365 support from <a href=\"https://premium.wpmudev.org/support/?utm_source=wordpress.org&utm_medium=plugin&utm_campaign=WP%20Smush%20Upgrade\">the best WordPress support team on the planet</a>."
312
  msgstr ""
313
 
314
+ #: lib/class-wp-smush-admin.php:1320
315
+ msgid "Download <a href=\"https://premium.wpmudev.org/?utm_source=wordpress.org&utm_medium=plugin&utm_campaign=WP%20Smush%20Upgrade\">100+ other premium plugins and themes</a> included in your membership."
316
  msgstr ""
317
 
318
+ #: lib/class-wp-smush-admin.php:1324
319
  msgid "Upgrade Now &raquo;"
320
  msgstr ""
321
 
322
+ #: lib/class-wp-smush-admin.php:1327
323
  msgid "Already upgraded to a WPMU DEV membership? Install and Login to our Dashboard plugin to enable Smush Pro features."
324
  msgstr ""
325
 
326
+ #: lib/class-wp-smush-admin.php:1329
327
  msgid "Unable to access Pro Features? <a href=\"%s\">Refresh Status</a>"
328
  msgstr ""
329
 
330
+ #: lib/class-wp-smush-admin.php:1340
331
  msgid "Activate WPMU DEV Dashboard"
332
  msgstr ""
333
 
334
+ #: lib/class-wp-smush-admin.php:1344
335
  msgid "Install WPMU DEV Dashboard"
336
  msgstr ""
337
 
411
  msgstr ""
412
 
413
  #: lib/class-wp-smush.php:814
414
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:243
415
  msgid "Not processed"
416
  msgstr ""
417
 
418
  #: lib/class-wp-smush.php:820
419
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:249
420
  msgid "Smush Now!"
421
  msgstr ""
422
 
442
  msgid "WP Bulk Smush"
443
  msgstr ""
444
 
445
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:419
446
  msgid "We didn't find any images in NextGen gallery, please upload some images."
447
  msgstr ""
448
 
449
+ #: lib/nextgen-integration/class-wp-smush-nextgen-admin.php:430
450
  msgid "%d attachment in NextGen Gallery has not been smushed yet."
451
  msgid_plural "%d image attachments in NextGen Gallery have not been smushed yet."
452
  msgstr[0] ""
lib/class-wp-smush-admin.php CHANGED
@@ -106,6 +106,9 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
106
 
107
  /// Smush Upgrade
108
  add_action( 'admin_notices', array( $this, 'smush_upgrade' ) );
 
 
 
109
  }
110
 
111
  /**
@@ -335,32 +338,23 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
335
  */
336
  function ui() {
337
  $this->setup_global_stats();
 
 
338
  ?>
339
  <div class="wrap">
340
-
341
- <h2>
342
- <?php
343
- if ( $this->is_pro_user ) {
344
- _e( 'WP Smush Pro', 'wp-smushit' );
345
- } else {
346
- _e( 'WP Smush', 'wp-smushit' );
347
- } ?>
348
- </h2><?php
349
- $this->smush_pro_features();
350
- ?>
351
-
352
- <div class="wp-smpushit-container">
353
- <h3>
354
- <?php _e( 'Settings', 'wp-smushit' ) ?>
355
- </h3>
356
- <?php
357
- // display the options
358
- $this->options_ui();
359
-
360
- //Bulk Smushing
361
- $this->bulk_preview();
362
- ?>
363
  </div>
 
 
364
  </div>
365
  <?php
366
  $this->print_loader();
@@ -369,12 +363,9 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
369
  /**
370
  * Process and display the options form
371
  */
372
- function options_ui() {
373
- ?>
374
  <form action="" method="post">
375
-
376
- <div id="wp-smush-options-wrap">
377
- <?php
378
  //Smush auto key
379
  $opt_auto = WP_SMUSH_PREFIX . 'auto';
380
  //Auto value
@@ -881,6 +872,9 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
881
  'posts_per_page' => - 1,
882
  'no_found_rows' => true
883
  );
 
 
 
884
  $results = new WP_Query( $query );
885
  $count = ! empty( $results->post_count ) ? $results->post_count : 0;
886
 
@@ -907,6 +901,9 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
907
  'no_found_rows' => true
908
  );
909
 
 
 
 
910
  $results = new WP_Query( $query );
911
  if ( ! $return_ids ) {
912
  $count = ! empty( $results->post_count ) ? $results->post_count : 0;
@@ -1086,6 +1083,9 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
1086
  ),
1087
  'no_found_rows' => true
1088
  );
 
 
 
1089
  $query = new WP_Query( $args );
1090
 
1091
  return $query->posts;
@@ -1114,7 +1114,11 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
1114
  $settings = '<a href="' . $settings_page . '">' . __( 'Settings', 'wp-smushit' ) . '</a>';
1115
 
1116
  //Added a fix for weird warning in multisite, "array_unshift() expects parameter 1 to be array, null given"
1117
- + !empty( $links ) ? array_unshift( $links, $settings ) : array_push( $settings );
 
 
 
 
1118
 
1119
  return $links;
1120
  }
@@ -1275,18 +1279,25 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
1275
  if ( ! is_super_admin() || ! $show_features ) {
1276
  return;
1277
  }
1278
- if ( $this->is_pro_user ) { ?>
1279
- <div class="wp-smpushit-features updated">
1280
- <h3><?php _e( 'Thanks for using WP Smush Pro! You now can:', 'wp-smushit' ) ?></h3>
1281
- <ol>
1282
- <li><?php _e( 'Smush the original Full image sizes that are normally skipped by default.', 'wp-smushit' ); ?></li>
1283
- <li><?php _e( 'NextGen Gallery integration', 'wp-smushit' ); ?></li>
1284
- <li><?php _e( '"Super-Smush" your images with our intelligent multi-pass lossy compression. Get 2&times; more compression than lossless with almost no noticeable quality loss!', 'wp-smushit' ); ?></li>
1285
- <li><?php _e( 'Get the best lossless compression. We try multiple methods to squeeze every last byte out of your images.', 'wp-smushit' ); ?></li>
1286
- <li><?php _e( 'Smush images up to 32MB.', 'wp-smushit' ); ?></li>
1287
- <li><?php _e( 'Bulk smush ALL your images with one click!', 'wp-smushit' ); ?></li>
1288
- <li><?php _e( 'Keep a backup of your original un-smushed images in case you want to restore later.', 'wp-smushit' ); ?></li>
1289
- </ol>
 
 
 
 
 
 
 
1290
  </div>
1291
  <?php } else {
1292
  if( $this->_get_api_key() ) {
@@ -1294,43 +1305,48 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
1294
  }else{
1295
  $refresh_url = '';
1296
  }?>
1297
- <div class="wp-smpushit-features error">
1298
- <h3><?php _e( 'Upgrade to WP Smush Pro to:', 'wp-smushit' ) ?></h3>
1299
- <ol>
1300
- <li><?php _e( 'Smush the original Full image sizes that are normally skipped by default.', 'wp-smushit' ); ?></li>
1301
- <li><?php _e( 'NextGen Gallery integration', 'wp-smushit' ); ?></li>
1302
- <li><?php _e( '"Super-Smush" your images with our intelligent multi-pass lossy compression. Get 2&times; more compression than lossless with almost no noticeable quality loss!', 'wp-smushit' ); ?></li>
1303
- <li><?php _e( 'Get the best lossless compression. We try multiple methods to squeeze every last byte out of your images.', 'wp-smushit' ); ?></li>
1304
- <li><?php _e( 'Smush images greater than 1MB.', 'wp-smushit' ); ?></li>
1305
- <li><?php _e( 'Bulk smush ALL your images with one click! No more rate limiting.', 'wp-smushit' ); ?></li>
1306
- <li><?php _e( 'Keep a backup of your original un-smushed images in case you want to restore later.', 'wp-smushit' ); ?></li>
1307
- <li><?php _e( 'Access 24/7/365 support from <a href="https://premium.wpmudev.org/support/?utm_source=wordpress.org&utm_medium=plugin&utm_campaign=WP%20Smush%20Upgrade">the best WordPress support team on the planet</a>.', 'wp-smushit' ); ?></li>
1308
- <li><?php _e( 'Download <a href="https://premium.wpmudev.org/?utm_source=wordpress.org&utm_medium=plugin&utm_campaign=WP%20Smush%20Upgrade">350+ other premium plugins and themes</a> included in your membership.', 'wp-smushit' ); ?></li>
1309
- </ol>
1310
- <p>
1311
- <a class="button-primary" href="<?php echo $this->upgrade_url; ?>"><?php _e( 'Upgrade Now &raquo;', 'wp-smushit' ); ?></a>
1312
- </p>
1313
-
1314
- <p><?php _e( 'Already upgraded to a WPMU DEV membership? Install and Login to our Dashboard plugin to enable Smush Pro features.', 'wp-smushit' ); ?></p><?php
1315
- if ( ! empty( $refresh_url ) ) {?>
1316
- <p><?php echo sprintf( __( 'Unable to access Pro Features? <a href="%s">Refresh Status</a>', 'wp-smushit' ), $refresh_url ); ?></p><?php }
1317
- ?>
 
 
1318
 
1319
- <p>
1320
- <?php
1321
- if ( ! class_exists( 'WPMUDEV_Dashboard' ) ) {
1322
- if ( file_exists( WP_PLUGIN_DIR . '/wpmudev-updates/update-notifications.php' ) ) {
1323
- $function = is_multisite() ? 'network_admin_url' : 'admin_url';
1324
- $url = wp_nonce_url( $function( 'plugins.php?action=activate&plugin=wpmudev-updates%2Fupdate-notifications.php' ), 'activate-plugin_wpmudev-updates/update-notifications.php' );
1325
- ?>
1326
- <a class="button-secondary" href="<?php echo $url; ?>"><?php _e( 'Activate WPMU DEV Dashboard', 'wp-smushit' ); ?></a><?php
1327
- } else { //dashboard not installed at all
1328
- ?>
1329
- <a class="button-secondary" target="_blank" href="https://premium.wpmudev.org/project/wpmu-dev-dashboard/"><?php _e( 'Install WPMU DEV Dashboard', 'wp-smushit' ); ?></a><?php
 
 
 
1330
  }
1331
- }
1332
- ?>
1333
- </p>
1334
  </div>
1335
  <?php }
1336
  }
@@ -1342,6 +1358,28 @@ if ( ! class_exists( 'WpSmushitAdmin' ) ) {
1342
 
1343
  delete_site_option('wp_smush_api_auth');
1344
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1345
  }
1346
 
1347
  global $wpsmushit_admin;
106
 
107
  /// Smush Upgrade
108
  add_action( 'admin_notices', array( $this, 'smush_upgrade' ) );
109
+
110
+ //Handle the smush pro dismiss features notice ajax
111
+ add_action( 'wp_ajax_dismiss_smush_notice', array( $this, 'dismiss_smush_notice' ) );
112
  }
113
 
114
  /**
338
  */
339
  function ui() {
340
  $this->setup_global_stats();
341
+ $page_heading = $this->is_pro_user ? esc_html__( 'WP Smush Pro', 'wp-smushit' ) : esc_html__( 'WP Smush', 'wp-smushit' );
342
+ $full_width = ( 1 == get_option( 'hide_smush_features' ) && $this->is_pro() ) ? ' smush-full-width' : '';
343
  ?>
344
  <div class="wrap">
345
+ <h1><?php echo $page_heading; ?></h1>
346
+ <div class="wp-smushit-container-wrap<?php echo $full_width; ?>">
347
+ <div class="wp-smushit-container">
348
+ <h3><?php _e( 'Settings', 'wp-smushit' ) ?></h3><?php
349
+ // display the options
350
+ $this->options_ui();
351
+ //Bulk Smushing
352
+ $this->bulk_preview();
353
+ ?>
354
+ </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
355
  </div>
356
+ <?php //Smush Pro Features
357
+ $this->smush_pro_features(); ?>
358
  </div>
359
  <?php
360
  $this->print_loader();
363
  /**
364
  * Process and display the options form
365
  */
366
+ function options_ui() { ?>
 
367
  <form action="" method="post">
368
+ <div id="wp-smush-options-wrap"><?php
 
 
369
  //Smush auto key
370
  $opt_auto = WP_SMUSH_PREFIX . 'auto';
371
  //Auto value
872
  'posts_per_page' => - 1,
873
  'no_found_rows' => true
874
  );
875
+ //Remove the Filters added by WP Media Folder
876
+ $this->remove_wmf_filters();
877
+
878
  $results = new WP_Query( $query );
879
  $count = ! empty( $results->post_count ) ? $results->post_count : 0;
880
 
901
  'no_found_rows' => true
902
  );
903
 
904
+ //Remove the Filters added by WP Media Folder
905
+ $this->remove_wmf_filters();
906
+
907
  $results = new WP_Query( $query );
908
  if ( ! $return_ids ) {
909
  $count = ! empty( $results->post_count ) ? $results->post_count : 0;
1083
  ),
1084
  'no_found_rows' => true
1085
  );
1086
+ //Remove the Filters added by WP Media Folder
1087
+ $this->remove_wmf_filters();
1088
+
1089
  $query = new WP_Query( $args );
1090
 
1091
  return $query->posts;
1114
  $settings = '<a href="' . $settings_page . '">' . __( 'Settings', 'wp-smushit' ) . '</a>';
1115
 
1116
  //Added a fix for weird warning in multisite, "array_unshift() expects parameter 1 to be array, null given"
1117
+ if( !empty( $links ) ) {
1118
+ array_unshift( $links, $settings );
1119
+ }else{
1120
+ $links = array( $settings );
1121
+ }
1122
 
1123
  return $links;
1124
  }
1279
  if ( ! is_super_admin() || ! $show_features ) {
1280
  return;
1281
  }
1282
+ if ( $this->is_pro_user ) {
1283
+ //If User choose to hide the notice
1284
+ if ( 1 == get_option( 'hide_smush_features' ) ) {
1285
+ return;
1286
+ } ?>
1287
+ <div class="wp-smushit-features-wrap">
1288
+ <div class="wp-smushit-features-inner notice inline wp-smush-pro-user">
1289
+ <a href="#" class="wp-smush-pro-feature-dismiss notice-dismiss"></a>
1290
+ <h3><?php _e( 'Thanks for using WP Smush Pro! You now can:', 'wp-smushit' ) ?></h3>
1291
+ <ol>
1292
+ <li><?php _e( 'Smush the original Full image sizes that are normally skipped by default.', 'wp-smushit' ); ?></li>
1293
+ <li><?php _e( 'NextGen Gallery integration', 'wp-smushit' ); ?></li>
1294
+ <li><?php _e( '"Super-Smush" your images with our intelligent multi-pass lossy compression. Get 2&times; more compression than lossless with almost no noticeable quality loss!', 'wp-smushit' ); ?></li>
1295
+ <li><?php _e( 'Get the best lossless compression. We try multiple methods to squeeze every last byte out of your images.', 'wp-smushit' ); ?></li>
1296
+ <li><?php _e( 'Smush images up to 32MB.', 'wp-smushit' ); ?></li>
1297
+ <li><?php _e( 'Bulk smush ALL your images with one click!', 'wp-smushit' ); ?></li>
1298
+ <li><?php _e( 'Keep a backup of your original un-smushed images in case you want to restore later.', 'wp-smushit' ); ?></li>
1299
+ </ol>
1300
+ </div>
1301
  </div>
1302
  <?php } else {
1303
  if( $this->_get_api_key() ) {
1305
  }else{
1306
  $refresh_url = '';
1307
  }?>
1308
+ <div class="wp-smushit-features-wrap">
1309
+ <div class="wp-smushit-features-inner notice inline">
1310
+ <h3><?php _e( 'Upgrade to WP Smush Pro to:', 'wp-smushit' ) ?></h3>
1311
+ <ol>
1312
+ <li><?php _e( 'Smush the original Full image sizes that are normally skipped by default.', 'wp-smushit' ); ?></li>
1313
+ <li><?php _e( 'NextGen Gallery integration', 'wp-smushit' ); ?></li>
1314
+ <li><?php _e( '"Super-Smush" your images with our intelligent multi-pass lossy compression. Get 2&times; more compression than lossless with almost no noticeable quality loss!', 'wp-smushit' ); ?></li>
1315
+ <li><?php _e( 'Get the best lossless compression. We try multiple methods to squeeze every last byte out of your images.', 'wp-smushit' ); ?></li>
1316
+ <li><?php _e( 'Smush images greater than 1MB.', 'wp-smushit' ); ?></li>
1317
+ <li><?php _e( 'Bulk smush ALL your images with one click! No more rate limiting.', 'wp-smushit' ); ?></li>
1318
+ <li><?php _e( 'Keep a backup of your original un-smushed images in case you want to restore later.', 'wp-smushit' ); ?></li>
1319
+ <li><?php _e( 'Access 24/7/365 support from <a href="https://premium.wpmudev.org/support/?utm_source=wordpress.org&utm_medium=plugin&utm_campaign=WP%20Smush%20Upgrade">the best WordPress support team on the planet</a>.', 'wp-smushit' ); ?></li>
1320
+ <li><?php _e( 'Download <a href="https://premium.wpmudev.org/?utm_source=wordpress.org&utm_medium=plugin&utm_campaign=WP%20Smush%20Upgrade">100+ other premium plugins and themes</a> included in your membership.', 'wp-smushit' ); ?></li>
1321
+ </ol>
1322
+ <p>
1323
+ <a class="button-primary"
1324
+ href="<?php echo $this->upgrade_url; ?>"><?php _e( 'Upgrade Now &raquo;', 'wp-smushit' ); ?></a>
1325
+ </p>
1326
+
1327
+ <p><?php _e( 'Already upgraded to a WPMU DEV membership? Install and Login to our Dashboard plugin to enable Smush Pro features.', 'wp-smushit' ); ?></p><?php
1328
+ if ( ! empty( $refresh_url ) ) { ?>
1329
+ <p><?php echo sprintf( __( 'Unable to access Pro Features? <a href="%s">Refresh Status</a>', 'wp-smushit' ), $refresh_url ); ?></p><?php }
1330
+ ?>
1331
 
1332
+ <p>
1333
+ <?php
1334
+ if ( ! class_exists( 'WPMUDEV_Dashboard' ) ) {
1335
+ if ( file_exists( WP_PLUGIN_DIR . '/wpmudev-updates/update-notifications.php' ) ) {
1336
+ $function = is_multisite() ? 'network_admin_url' : 'admin_url';
1337
+ $url = wp_nonce_url( $function( 'plugins.php?action=activate&plugin=wpmudev-updates%2Fupdate-notifications.php' ), 'activate-plugin_wpmudev-updates/update-notifications.php' );
1338
+ ?>
1339
+ <a class="button-secondary"
1340
+ href="<?php echo $url; ?>"><?php _e( 'Activate WPMU DEV Dashboard', 'wp-smushit' ); ?></a><?php
1341
+ } else { //dashboard not installed at all
1342
+ ?>
1343
+ <a class="button-secondary" target="_blank"
1344
+ href="https://premium.wpmudev.org/project/wpmu-dev-dashboard/"><?php _e( 'Install WPMU DEV Dashboard', 'wp-smushit' ); ?></a><?php
1345
+ }
1346
  }
1347
+ ?>
1348
+ </p>
1349
+ </div>
1350
  </div>
1351
  <?php }
1352
  }
1358
 
1359
  delete_site_option('wp_smush_api_auth');
1360
  }
1361
+
1362
+ /**
1363
+ * Remove any pre_get_posts_filters added by WP Media Folder plugin
1364
+ */
1365
+ function remove_wmf_filters() {
1366
+ //remove any filters added b WP media Folder plugin to get the all attachments
1367
+ if( class_exists('Wp_Media_Folder') ) {
1368
+ global $wp_media_folder;
1369
+ if( is_object( $wp_media_folder ) ) {
1370
+ remove_filter( 'pre_get_posts', array( $wp_media_folder, 'wpmf_pre_get_posts1' ) );
1371
+ remove_filter( 'pre_get_posts', array( $wp_media_folder, 'wpmf_pre_get_posts' ), 0, 1 );
1372
+ }
1373
+ }
1374
+ }
1375
+
1376
+ /**
1377
+ * Store a key/value to hide the smush features on bulk page
1378
+ */
1379
+ function dismiss_smush_notice() {
1380
+ update_option( 'hide_smush_features', 1 );
1381
+ wp_send_json_success();
1382
+ }
1383
  }
1384
 
1385
  global $wpsmushit_admin;
lib/class-wp-smush-bulk.php CHANGED
@@ -22,6 +22,7 @@ if ( ! class_exists( 'WpSmushitBulk' ) ) {
22
  * @return array $attachments
23
  */
24
  function get_attachments() {
 
25
  if ( ! isset( $_REQUEST['ids'] ) ) {
26
  $args = array(
27
  'fields' => 'ids',
@@ -40,6 +41,10 @@ if ( ! class_exists( 'WpSmushitBulk' ) ) {
40
  'update_post_term_cache' => false,
41
  'no_found_rows' => true
42
  );
 
 
 
 
43
  $query = new WP_Query( $args );
44
  $unsmushed_posts = $query->posts;
45
  } else {
@@ -54,6 +59,7 @@ if ( ! class_exists( 'WpSmushitBulk' ) ) {
54
  * @return array
55
  */
56
  function get_nextgen_attachments() {
 
57
  if ( ! isset( $_REQUEST['ids'] ) ) {
58
  $args = array(
59
  'fields' => 'ids',
@@ -71,6 +77,10 @@ if ( ! class_exists( 'WpSmushitBulk' ) ) {
71
  ),
72
  'no_found_rows' => true
73
  );
 
 
 
 
74
  $query = new WP_Query( $args );
75
  $unsmushed_posts = $query->posts;
76
  } else {
22
  * @return array $attachments
23
  */
24
  function get_attachments() {
25
+ global $wpsmushit_admin;
26
  if ( ! isset( $_REQUEST['ids'] ) ) {
27
  $args = array(
28
  'fields' => 'ids',
41
  'update_post_term_cache' => false,
42
  'no_found_rows' => true
43
  );
44
+
45
+ //Remove the Filters added by WP Media Folder
46
+ $wpsmushit_admin->remove_wmf_filters();
47
+
48
  $query = new WP_Query( $args );
49
  $unsmushed_posts = $query->posts;
50
  } else {
59
  * @return array
60
  */
61
  function get_nextgen_attachments() {
62
+ global $wpsmushit_admin;
63
  if ( ! isset( $_REQUEST['ids'] ) ) {
64
  $args = array(
65
  'fields' => 'ids',
77
  ),
78
  'no_found_rows' => true
79
  );
80
+
81
+ //Remove the Filters added by WP Media Folder
82
+ $wpsmushit_admin->remove_wmf_filters();
83
+
84
  $query = new WP_Query( $args );
85
  $unsmushed_posts = $query->posts;
86
  } else {
lib/nextgen-integration/class-wp-smush-nextgen-admin.php CHANGED
@@ -198,9 +198,6 @@ if ( ! class_exists( 'WpSmushNextGenAdmin' ) ) {
198
  global $wpsmushit_admin;
199
  ?>
200
  <div class="wrap"><?php
201
- //Promotional Text
202
- $wpsmushit_admin->smush_pro_features();
203
-
204
  //Bulk Smush UI, calls progress UI, Super Smush UI
205
  $this->bulk_smush_ui(); ?>
206
  </div><?php
198
  global $wpsmushit_admin;
199
  ?>
200
  <div class="wrap"><?php
 
 
 
201
  //Bulk Smush UI, calls progress UI, Super Smush UI
202
  $this->bulk_smush_ui(); ?>
203
  </div><?php
readme.txt CHANGED
@@ -1,13 +1,13 @@
1
  === WP Smush ===
2
  Plugin Name: WP Smush
3
- Version: 2.1.4
4
  Author: WPMU DEV
5
  Author URI: http://premium.wpmudev.org/
6
  Contributors: WPMUDEV, alexdunae
7
  Tags: Attachment,Attachments,Compress,Compress Image File,Compress Image Size,Compress JPG,Compressed JPG, Compression Image,Image,Images,JPG,Optimise,Optimize,Photo,Photos,Pictures,PNG,Reduce Image Size,Smush,Smush.it,Upload,WordPress Compression,WordPress Image Tool,Yahoo, Yahoo Smush.it
8
  Requires at least: 3.5
9
  Tested up to: 4.4.2
10
- Stable tag: 2.1.4
11
  License: GPL v2 - http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
12
 
13
  Reduce image file sizes, improve performance and boost your SEO using the free <a href="https://premium.wpmudev.org/">WPMU DEV</a> WordPress Smush API.
@@ -80,6 +80,12 @@ Yahoo's Smush.it API is gone forever. So WPMU DEV built our own free API that is
80
 
81
  == Changelog ==
82
 
 
 
 
 
 
 
83
  = 2.1.4 =
84
  * Fixed: Preserve file permission after smushing ( Fix for Images disappearing in Media library on some hosts )
85
  * Fixed: Styles plugin compatibility
1
  === WP Smush ===
2
  Plugin Name: WP Smush
3
+ Version: 2.1.5
4
  Author: WPMU DEV
5
  Author URI: http://premium.wpmudev.org/
6
  Contributors: WPMUDEV, alexdunae
7
  Tags: Attachment,Attachments,Compress,Compress Image File,Compress Image Size,Compress JPG,Compressed JPG, Compression Image,Image,Images,JPG,Optimise,Optimize,Photo,Photos,Pictures,PNG,Reduce Image Size,Smush,Smush.it,Upload,WordPress Compression,WordPress Image Tool,Yahoo, Yahoo Smush.it
8
  Requires at least: 3.5
9
  Tested up to: 4.4.2
10
+ Stable tag: 2.1.5
11
  License: GPL v2 - http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
12
 
13
  Reduce image file sizes, improve performance and boost your SEO using the free <a href="https://premium.wpmudev.org/">WPMU DEV</a> WordPress Smush API.
80
 
81
  == Changelog ==
82
 
83
+ = 2.1.5 =
84
+
85
+ * Fixed: WP Media Folder Plugin compatibility
86
+ * Fixed: Warning on Plugins Page
87
+ * Updated: Settings Page styling
88
+
89
  = 2.1.4 =
90
  * Fixed: Preserve file permission after smushing ( Fix for Images disappearing in Media library on some hosts )
91
  * Fixed: Styles plugin compatibility
wp-smush.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: WP Smush
4
  Plugin URI: http://wordpress.org/extend/plugins/wp-smushit/
5
  Description: Reduce image file sizes, improve performance and boost your SEO using the free <a href="https://premium.wpmudev.org/">WPMU DEV</a> WordPress Smush API.
6
  Author: WPMU DEV
7
- Version: 2.1.4
8
  Author URI: http://premium.wpmudev.org/
9
  Textdomain: wp-smushit
10
  */
@@ -35,7 +35,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
35
  * Constants
36
  */
37
  $prefix = 'WP_SMUSH_';
38
- $version = '2.1.4';
39
 
40
  /**
41
  * Set the default timeout for API request and AJAX timeout
4
  Plugin URI: http://wordpress.org/extend/plugins/wp-smushit/
5
  Description: Reduce image file sizes, improve performance and boost your SEO using the free <a href="https://premium.wpmudev.org/">WPMU DEV</a> WordPress Smush API.
6
  Author: WPMU DEV
7
+ Version: 2.1.5
8
  Author URI: http://premium.wpmudev.org/
9
  Textdomain: wp-smushit
10
  */
35
  * Constants
36
  */
37
  $prefix = 'WP_SMUSH_';
38
+ $version = '2.1.5';
39
 
40
  /**
41
  * Set the default timeout for API request and AJAX timeout