reGenerate Thumbnails Advanced - Version 0.8.2.7

Version Description

  • Fixed a wp_debug notice bug
  • Fixed a js issue

=

Download this release

Release Info

Developer turcuciprian
Plugin Icon 128x128 reGenerate Thumbnails Advanced
Version 0.8.2.7
Comparing to
See all releases

Code changes from version 0.8.2.6 to 0.8.2.7

Files changed (4) hide show
  1. readme.txt +10 -1
  2. regenerate-thumbnails-advanced.php +13 -10
  3. screenshot-2.png +0 -0
  4. script.js +4 -0
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
4
  Tags: regenerate, thumbnails, advanced, easy, day, weeek, month
5
  Requires at least: 4.0
6
  Tested up to: 4.3.1
7
- Stable tag: 0.8.2.6
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -92,6 +92,11 @@ The script stops, it does not run in the background
92
  * Added new style
93
  * Added datepickers
94
 
 
 
 
 
 
95
  == Upgrade Notice ==
96
 
97
  = 0.7 =
@@ -123,3 +128,7 @@ No issuse with this version that require attention. Small update change. It's ba
123
 
124
  = 0.8.2.6 =
125
  This version changes the style and adds a bit of functionality to the general settings (a date start-end option to choose from)
 
 
 
 
4
  Tags: regenerate, thumbnails, advanced, easy, day, weeek, month
5
  Requires at least: 4.0
6
  Tested up to: 4.3.1
7
+ Stable tag: 0.8.2.7
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
92
  * Added new style
93
  * Added datepickers
94
 
95
+ = 0.8.2.7 =
96
+ * Fixed a wp_debug notice bug
97
+ * Fixed a js issue
98
+
99
+
100
  == Upgrade Notice ==
101
 
102
  = 0.7 =
128
 
129
  = 0.8.2.6 =
130
  This version changes the style and adds a bit of functionality to the general settings (a date start-end option to choose from)
131
+
132
+ = 0.8.2.7 =
133
+ No issuse with this version that require attention. Small update change. It's basically a feature, so unless you want it, the older version works great.
134
+ fixes some js issues and ajax issues. it's recommended to update
regenerate-thumbnails-advanced.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: reGenerate Thumbnails - advanced
4
  Plugin URI: http://turcuciprian.com
5
  Description: A plugin that makes regenerating thumbnails even easier than before and more flexible.
6
- Version: 0.8.2.6
7
  Author: turcuciprian
8
  Author URI: http://turcuciprian.com
9
  License: GPLv2 or later
@@ -28,6 +28,7 @@ class cc {
28
  if (isset($_POST['type'])) {
29
  $type = $_POST['type'];
30
  }
 
31
  $offset = 0;
32
  switch ($type) {
33
  case 'general':
@@ -59,7 +60,7 @@ class cc {
59
  break;
60
  }
61
  }
62
- if (!empty($date)) {
63
  $fromTo = explode('-', $date);
64
  $startDate = date("m/d/Y", strtotime($fromTo[0] . " -1 day"));
65
  $endDate = date("m/d/Y", strtotime($fromTo[1] . " +1 day"));
@@ -81,15 +82,21 @@ class cc {
81
  }
82
  wp_reset_query();
83
  wp_reset_postdata();
84
- // $logstatus .= "<pre>" . print_r($the_query, true) . "</pre>";
85
- $return_arr = array('pCount' => $post_count, 'fromTo' => $date, 'type' => $_POST['type'], 'period' => $period);
 
 
 
 
 
 
86
  // return the total number of results
87
 
88
 
89
  echo json_encode($return_arr);
90
  break;
91
  case 'submit':
92
- // $logstatus = '';
93
  $error = array();
94
  if (isset($_POST['offset'])) {
95
  $offset = $_POST['offset'];
@@ -196,16 +203,12 @@ class cc {
196
  }
197
  //increment offset
198
  $result = $offset + 1;
199
- // $logstatus .= "<br/>".$the_query->post->ID;
200
- // $logstatus .= "<br/><pre>" . print_r($args, true) . "</pre>";
201
  echo json_encode(array('offset' => ($offset + 1), 'error' => $error, 'logstatus' => $logstatus, 'startTime' => $_POST['startTime'], 'fromTo' => $_POST['fromTo'], 'type' => $_POST['type'], 'period' => $period));
202
  break;
203
  }
204
  /* Restore original Post Data */
205
  wp_reset_query();
206
  wp_reset_postdata();
207
-
208
-
209
  wp_die();
210
  }
211
 
@@ -219,7 +222,7 @@ class cc {
219
  }
220
 
221
  function enqueue_admin($hook) {
222
- if (!isset($_GET['page']) && isset($hook)) {
223
  if ($_GET['page'] !== 'regenerate_thumbnails_advanced' && $hook != 'options-general.php ') {
224
  return;
225
  }
3
  Plugin Name: reGenerate Thumbnails - advanced
4
  Plugin URI: http://turcuciprian.com
5
  Description: A plugin that makes regenerating thumbnails even easier than before and more flexible.
6
+ Version: 0.8.2.7
7
  Author: turcuciprian
8
  Author URI: http://turcuciprian.com
9
  License: GPLv2 or later
28
  if (isset($_POST['type'])) {
29
  $type = $_POST['type'];
30
  }
31
+ $logstatus ='';
32
  $offset = 0;
33
  switch ($type) {
34
  case 'general':
60
  break;
61
  }
62
  }
63
+ if (isset($date) && !empty($date)) {
64
  $fromTo = explode('-', $date);
65
  $startDate = date("m/d/Y", strtotime($fromTo[0] . " -1 day"));
66
  $endDate = date("m/d/Y", strtotime($fromTo[1] . " +1 day"));
82
  }
83
  wp_reset_query();
84
  wp_reset_postdata();
85
+ $logstatus .= "<pre>" . print_r($the_query, true) . "</pre>";
86
+ if(isset($_POST['type'])){
87
+ $typeV = $_POST['type'];
88
+ }
89
+ if(!isset($date) || empty($date)){
90
+ $date = '';
91
+ }
92
+ $return_arr = array('pCount' => $post_count, 'fromTo' => $date, 'type' => $typeV, 'period' => $period);
93
  // return the total number of results
94
 
95
 
96
  echo json_encode($return_arr);
97
  break;
98
  case 'submit':
99
+ $logstatus = '';
100
  $error = array();
101
  if (isset($_POST['offset'])) {
102
  $offset = $_POST['offset'];
203
  }
204
  //increment offset
205
  $result = $offset + 1;
 
 
206
  echo json_encode(array('offset' => ($offset + 1), 'error' => $error, 'logstatus' => $logstatus, 'startTime' => $_POST['startTime'], 'fromTo' => $_POST['fromTo'], 'type' => $_POST['type'], 'period' => $period));
207
  break;
208
  }
209
  /* Restore original Post Data */
210
  wp_reset_query();
211
  wp_reset_postdata();
 
 
212
  wp_die();
213
  }
214
 
222
  }
223
 
224
  function enqueue_admin($hook) {
225
+ if (isset($_GET['page']) && isset($hook)) {
226
  if ($_GET['page'] !== 'regenerate_thumbnails_advanced' && $hook != 'options-general.php ') {
227
  return;
228
  }
screenshot-2.png CHANGED
Binary file
script.js CHANGED
@@ -92,16 +92,20 @@ jQuery(document).ready(function ($) {
92
 
93
  //var err_arr = new Array();
94
  //json response
 
95
  var json = JSON.parse(response);
 
96
  // console.log(json);
97
  var startTime = json.startTime;
98
  var offset = 0;
99
  var tCount = 0;
 
100
  var rta_total = $('#rta .info .total');
101
  var type = json.type;
102
 
103
  switch (type) {
104
  case 'general':
 
105
  var period = $('#rta_period');
106
  var rta_total = $('#rta .info .total');
107
  var rta_processed = $('#rta .info .processed');
92
 
93
  //var err_arr = new Array();
94
  //json response
95
+ console.log(response);
96
  var json = JSON.parse(response);
97
+
98
  // console.log(json);
99
  var startTime = json.startTime;
100
  var offset = 0;
101
  var tCount = 0;
102
+
103
  var rta_total = $('#rta .info .total');
104
  var type = json.type;
105
 
106
  switch (type) {
107
  case 'general':
108
+
109
  var period = $('#rta_period');
110
  var rta_total = $('#rta .info .total');
111
  var rta_processed = $('#rta .info .processed');