Countdown Timer – Widget Countdown - Version 2.1.7

Version Description

  • Changed the Countdown timer text color status.

=

Download this release

Release Info

Developer wpdevart
Plugin Icon 128x128 Countdown Timer – Widget Countdown
Version 2.1.7
Comparing to
See all releases

Code changes from version 2.1.6 to 2.1.7

includes/admin_menu.php CHANGED
@@ -62,6 +62,9 @@ class wpdevart_countdown_admin_menu{
62
  //wp_enqueue_script('jquery-ui-slider');
63
  ?>
64
  <style>
 
 
 
65
  #miain_wpdevart_countdown_window_manager > tbody > tr:nth-child(odd) {
66
  background-color: rgba(176, 176, 176, 0.07);
67
  }
@@ -254,14 +257,10 @@ class wpdevart_countdown_admin_menu{
254
 
255
  <tr class="tr_button tr_circle tr_vertical_slide">
256
  <td>
257
- Countdown timer text color <span class="pro_feature"> (pro)</span> <span title="Choose the Countdown text color." class="desription_class">?</span>
258
  </td>
259
  <td>
260
- <div onClick="alert(countdown_pro_text)">
261
- <div class="wp-picker-container disabled_picker">
262
- <button type="button" class="button wp-color-result" aria-expanded="false" style="background-color: rgb(0, 0, 0);"><span class="wp-color-result-text">Select Color</span></button>
263
- </div>
264
- </div>
265
  </td>
266
  </tr>
267
  <tr class="tr_button tr_circle tr_vertical_slide">
@@ -410,6 +409,9 @@ class wpdevart_countdown_admin_menu{
410
  if(jQuery('#countdown_experet_type').length)
411
  variables=variables+'countdown_end_type="'+jQuery('#countdown_experet_type').val()+'" ';
412
 
 
 
 
413
  if(jQuery('#countdown_hide_on_mobile').length)
414
  variables=variables+'hide_on_mobile="'+jQuery('#countdown_hide_on_mobile').val()+'" ';
415
 
62
  //wp_enqueue_script('jquery-ui-slider');
63
  ?>
64
  <style>
65
+ .wp-picker-container{
66
+ position:relative;
67
+ }
68
  #miain_wpdevart_countdown_window_manager > tbody > tr:nth-child(odd) {
69
  background-color: rgba(176, 176, 176, 0.07);
70
  }
257
 
258
  <tr class="tr_button tr_circle tr_vertical_slide">
259
  <td>
260
+ Countdown timer text color <span title="Choose the Countdown text color." class="desription_class">?</span>
261
  </td>
262
  <td>
263
+ <input type="text" class="color_option" id="countdown_font_color" name="countdown_font_color" value="#000000"/>
 
 
 
 
264
  </td>
265
  </tr>
266
  <tr class="tr_button tr_circle tr_vertical_slide">
409
  if(jQuery('#countdown_experet_type').length)
410
  variables=variables+'countdown_end_type="'+jQuery('#countdown_experet_type').val()+'" ';
411
 
412
+ if(jQuery('#countdown_font_color').length)
413
+ variables=variables+'font_color="'+jQuery('#countdown_font_color').val()+'" ';
414
+
415
  if(jQuery('#countdown_hide_on_mobile').length)
416
  variables=variables+'hide_on_mobile="'+jQuery('#countdown_hide_on_mobile').val()+'" ';
417
 
includes/front_end.php CHANGED
@@ -59,6 +59,7 @@ class wpdevart_countdown_front_end{
59
  "hide_on_mobile" => "show",
60
  "end_date" => date('d-m-Y 23:59'),
61
  "end_time" => "0,9,9",
 
62
  "action_end_time" => "hide",
63
  "content_position" => "center",
64
  "top_ditance" => "11",
@@ -172,12 +173,12 @@ class wpdevart_countdown_front_end{
172
  $output_css.= "background-color:#3DA8CC;\r\n";
173
  $output_css.= "font-size:23px;\r\n";
174
  $output_css.= "font-family:monospace;\r\n";
175
- $output_css.= "color:#000000;\r\n";
176
  $output_css.= "}\r\n";
177
  $output_css.= "#main_countedown_".self::$id_for_content." .time_description{\r\n";
178
  $output_css.= "font-size:23px;\r\n";
179
  $output_css.= "font-family:monospace;\r\n";
180
- $output_css.= "color:#000000;\r\n";
181
  $output_css.= "}\r\n";
182
  $output_css.= "#main_countedown_".self::$id_for_content." .element_conteiner{min-width:90px}";
183
 
59
  "hide_on_mobile" => "show",
60
  "end_date" => date('d-m-Y 23:59'),
61
  "end_time" => "0,9,9",
62
+ "font_color" => "#000000",
63
  "action_end_time" => "hide",
64
  "content_position" => "center",
65
  "top_ditance" => "11",
173
  $output_css.= "background-color:#3DA8CC;\r\n";
174
  $output_css.= "font-size:23px;\r\n";
175
  $output_css.= "font-family:monospace;\r\n";
176
+ $output_css.= "color:".$parametrs_for_countedown['font_color'].";\r\n";
177
  $output_css.= "}\r\n";
178
  $output_css.= "#main_countedown_".self::$id_for_content." .time_description{\r\n";
179
  $output_css.= "font-size:23px;\r\n";
180
  $output_css.= "font-family:monospace;\r\n";
181
+ $output_css.= "color:".$parametrs_for_countedown['font_color'].";\r\n";
182
  $output_css.= "}\r\n";
183
  $output_css.= "#main_countedown_".self::$id_for_content." .element_conteiner{min-width:90px}";
184
 
includes/gutenberg/block.js CHANGED
@@ -207,7 +207,8 @@
207
  wpda_countdown_fields.push(wpda_countdown_lb_simple_input_with_small("countdown_top_distance","Countdown distance from top","Type the Countdown distance from top(px).","(px)"));
208
  wpda_countdown_fields.push(wpda_countdown_lb_simple_input_with_small("countdown_bottom_distance","Countdown distance from bottom","Type the Countdown distance from bottom(px).","(px)"));
209
  wpda_countdown_fields.push(wpda_countdown_lb_simple_select("countdown_type",{"button":"Button","circle":"Circle","vertical_slide":"Vertical Slider"},"Countdown timer buttons type","Choose the Countdown buttons type.",true));
210
- wpda_countdown_fields.push(wpda_countdown_lb_color_input("timer_text_color","Countdown timer text color","Choose the Countdown text color.",true));
 
211
  wpda_countdown_fields.push(wpda_countdown_lb_color_input("timer_bg_color","Countdown timer background color","Select the Countdown background color.",true));
212
  wpda_countdown_fields.push(wpda_countdown_lb_simple_input_with_small("countdown_border_radius","Countdown timer border radius","Type the Countdown border radius(px).","(px)",true));
213
  wpda_countdown_fields.push(wpda_countdown_lb_simple_input_with_small("countdown_font_size","Countdown timer font size","Type the Countdown font-size(px).","(px)",true));
@@ -440,7 +441,7 @@
440
  if(props.attributes.redirect_url)
441
  shortcode_atributes = shortcode_atributes + ' redirect_url="' + props.attributes.redirect_url + '"';
442
  shortcode_atributes = shortcode_atributes + ' countdown_type="button"';
443
- shortcode_atributes = shortcode_atributes + ' font_color="#000000"';
444
  shortcode_atributes = shortcode_atributes + ' button_bg_color="#3DA8CC"';
445
  shortcode_atributes = shortcode_atributes + ' circle_size="130"';
446
  shortcode_atributes = shortcode_atributes + ' circle_border="5"';
207
  wpda_countdown_fields.push(wpda_countdown_lb_simple_input_with_small("countdown_top_distance","Countdown distance from top","Type the Countdown distance from top(px).","(px)"));
208
  wpda_countdown_fields.push(wpda_countdown_lb_simple_input_with_small("countdown_bottom_distance","Countdown distance from bottom","Type the Countdown distance from bottom(px).","(px)"));
209
  wpda_countdown_fields.push(wpda_countdown_lb_simple_select("countdown_type",{"button":"Button","circle":"Circle","vertical_slide":"Vertical Slider"},"Countdown timer buttons type","Choose the Countdown buttons type.",true));
210
+ /* wpda_countdown_fields.push(wpda_countdown_lb_color_input("timer_text_color","Countdown timer text color","Choose the Countdown text color.",true));*/
211
+ wpda_countdown_fields.push(wpda_countdown_lb_color_input("countdown_font_color","Countdown timer text color","Choose the Countdown text color.",false,{},"wpda_countdown_tr_button wpda_countdown_tr_circle wpda_countdown_tr_slider"));
212
  wpda_countdown_fields.push(wpda_countdown_lb_color_input("timer_bg_color","Countdown timer background color","Select the Countdown background color.",true));
213
  wpda_countdown_fields.push(wpda_countdown_lb_simple_input_with_small("countdown_border_radius","Countdown timer border radius","Type the Countdown border radius(px).","(px)",true));
214
  wpda_countdown_fields.push(wpda_countdown_lb_simple_input_with_small("countdown_font_size","Countdown timer font size","Type the Countdown font-size(px).","(px)",true));
441
  if(props.attributes.redirect_url)
442
  shortcode_atributes = shortcode_atributes + ' redirect_url="' + props.attributes.redirect_url + '"';
443
  shortcode_atributes = shortcode_atributes + ' countdown_type="button"';
444
+ shortcode_atributes = shortcode_atributes + ' font_color="' + props.attributes.countdown_font_color + '"';
445
  shortcode_atributes = shortcode_atributes + ' button_bg_color="#3DA8CC"';
446
  shortcode_atributes = shortcode_atributes + ' circle_size="130"';
447
  shortcode_atributes = shortcode_atributes + ' circle_border="5"';
includes/widget.php CHANGED
@@ -20,6 +20,9 @@ class wpdevart_countdown extends WP_Widget {
20
  $title = $instance['title'];
21
  // Before widget code //
22
  echo $before_widget;
 
 
 
23
 
24
  // Widget title//
25
  if ( $title ) { echo $before_title . $title . $after_title; }
@@ -43,6 +46,7 @@ class wpdevart_countdown extends WP_Widget {
43
  $instance['end_time_type'] = $new_instance['end_time_type'];
44
  $instance['end_time_date'] = $new_instance['end_time_date'];
45
  $instance['end_time'] = $new_instance['end_time'];
 
46
  $instance['start_time'] = $new_instance['start_time'];
47
  $instance['content'] = $new_instance['content'];
48
  $instance['action_end_time'] = $new_instance['action_end_time'];
@@ -68,6 +72,7 @@ class wpdevart_countdown extends WP_Widget {
68
  'end_time_type' => 'time',
69
  'end_time' => '0,9,9',
70
  'end_time_date' => date('d-m-Y 23:59'),
 
71
  'action_end_time' => 'hide',
72
  'redirect_url' => get_home_url(),
73
  'content' => '',
@@ -234,13 +239,9 @@ class wpdevart_countdown extends WP_Widget {
234
  </p>
235
 
236
  <p class="flb_field tr_button tr_circle tr_vertical_slide">
237
- <label>Countdown text color:<span class="pro_feature"> (pro)</span></label>
238
  <br>
239
- <div onClick="alert(countdown_pro_text)">
240
- <div class="wp-picker-container disabled_picker">
241
- <button type="button" class="button wp-color-result" aria-expanded="false" style="background-color: rgb(0, 0, 0);"><span class="wp-color-result-text">Select Color</span></button>
242
- </div>
243
- </div>
244
  </p>
245
 
246
  <p class="flb_field tr_button tr_circle tr_vertical_slide">
@@ -290,6 +291,12 @@ class wpdevart_countdown extends WP_Widget {
290
  <br>
291
  <input type="hidden" id="flb-submit" name="flb-submit" value="1">
292
  <script>
 
 
 
 
 
 
293
  jQuery('.wpdevart-date-time-picker').ready(function(){
294
  var nowTemp = new Date();
295
  var now = new Date(nowTemp.getFullYear(), nowTemp.getMonth(), nowTemp.getDate(), 0, 0, 0, 0);
@@ -402,12 +409,12 @@ class wpdevart_countdown extends WP_Widget {
402
  $output_css.= "background-color:#3DA8CC;\r\n";
403
  $output_css.= "font-size:20px;\r\n";
404
  $output_css.= "font-family:monospace;\r\n";
405
- $output_css.= "color:#000000;\r\n";
406
  $output_css.= "}\r\n";
407
  $output_css.= "#main_countedown_widget_".self::$id_for_content." .time_description{\r\n";
408
  $output_css.= "font-size:20px;\r\n";
409
  $output_css.= "font-family:monospace;\r\n";
410
- $output_css.= "color:#000000;\r\n";
411
  $output_css.= "}\r\n";
412
  $output_css.= "#main_countedown_widget_".self::$id_for_content." .element_conteiner{min-width:73px}";
413
  $output_html.='<script>'.$output_js.'</script><style>'.$output_css.'</style>';
20
  $title = $instance['title'];
21
  // Before widget code //
22
  echo $before_widget;
23
+ if(!isset($instance['font_color'])){
24
+ $instance['font_color']="#000000";
25
+ }
26
 
27
  // Widget title//
28
  if ( $title ) { echo $before_title . $title . $after_title; }
46
  $instance['end_time_type'] = $new_instance['end_time_type'];
47
  $instance['end_time_date'] = $new_instance['end_time_date'];
48
  $instance['end_time'] = $new_instance['end_time'];
49
+ $instance['font_color'] = $new_instance['font_color'];
50
  $instance['start_time'] = $new_instance['start_time'];
51
  $instance['content'] = $new_instance['content'];
52
  $instance['action_end_time'] = $new_instance['action_end_time'];
72
  'end_time_type' => 'time',
73
  'end_time' => '0,9,9',
74
  'end_time_date' => date('d-m-Y 23:59'),
75
+ 'font_color' => '#000000',
76
  'action_end_time' => 'hide',
77
  'redirect_url' => get_home_url(),
78
  'content' => '',
239
  </p>
240
 
241
  <p class="flb_field tr_button tr_circle tr_vertical_slide">
242
+ <label for="<?php echo $this->get_field_id('font_color'); ?>">Countdown timer text color:</label>
243
  <br>
244
+ <input class="color_option" id="<?php echo $this->get_field_id('font_color'); ?>" name="<?php echo $this->get_field_name('font_color'); ?>" type="text" value="<?php echo $instance['font_color']; ?>">
 
 
 
 
245
  </p>
246
 
247
  <p class="flb_field tr_button tr_circle tr_vertical_slide">
291
  <br>
292
  <input type="hidden" id="flb-submit" name="flb-submit" value="1">
293
  <script>
294
+ jQuery(".color_option").ready(function(e) {
295
+ jQuery(".color_option").each(function(index, element) {
296
+ if(!jQuery(this).hasClass('wp-color-picker') && jQuery(this).attr('name').indexOf('__i__')==-1){jQuery(this).wpColorPicker()};
297
+ });
298
+
299
+ });
300
  jQuery('.wpdevart-date-time-picker').ready(function(){
301
  var nowTemp = new Date();
302
  var now = new Date(nowTemp.getFullYear(), nowTemp.getMonth(), nowTemp.getDate(), 0, 0, 0, 0);
409
  $output_css.= "background-color:#3DA8CC;\r\n";
410
  $output_css.= "font-size:20px;\r\n";
411
  $output_css.= "font-family:monospace;\r\n";
412
+ $output_css.= "color:".$parametrs['font_color'].";\r\n";
413
  $output_css.= "}\r\n";
414
  $output_css.= "#main_countedown_widget_".self::$id_for_content." .time_description{\r\n";
415
  $output_css.= "font-size:20px;\r\n";
416
  $output_css.= "font-family:monospace;\r\n";
417
+ $output_css.= "color:".$parametrs['font_color'].";\r\n";
418
  $output_css.= "}\r\n";
419
  $output_css.= "#main_countedown_widget_".self::$id_for_content." .element_conteiner{min-width:73px}";
420
  $output_html.='<script>'.$output_js.'</script><style>'.$output_css.'</style>';
readme.txt CHANGED
@@ -3,8 +3,8 @@ Contributors: wpdevart
3
  Donate link: http://wpdevart.com/wordpress-countdown-plugin
4
  Tags: countdown, countdown widget, countdown timer, countdown system, countdown generator
5
  Requires at least: 3.3.0
6
- Tested up to: 5.4.2
7
- Stable tag: 2.1.6
8
  License: GPLv3
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
@@ -506,6 +506,10 @@ Yes dear users, you need to pay only one time for pro version, it's lifetime pla
506
 
507
  * Added new support URL.
508
 
 
 
 
 
509
  == Step by step guide ==
510
 
511
  ### Options
3
  Donate link: http://wpdevart.com/wordpress-countdown-plugin
4
  Tags: countdown, countdown widget, countdown timer, countdown system, countdown generator
5
  Requires at least: 3.3.0
6
+ Tested up to: 5.5
7
+ Stable tag: 2.1.7
8
  License: GPLv3
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
506
 
507
  * Added new support URL.
508
 
509
+ = 2.1.7 =
510
+
511
+ * Changed the Countdown timer text color status.
512
+
513
  == Step by step guide ==
514
 
515
  ### Options
wpdevart-countdown.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Countdown Wpdevart
4
  Plugin URI: http://wpdevart.com/wordpress-countdown-plugin/
5
  Description: Countdown plugin is an nice tool to create and insert countdown timers into your posts/pages and widgets .
6
- Version: 2.1.6
7
  Author: wpdevart
8
  Author URI: http://wpdevart.com
9
  License: GPL3 http://www.gnu.org/licenses/gpl-3.0.html
3
  Plugin Name: Countdown Wpdevart
4
  Plugin URI: http://wpdevart.com/wordpress-countdown-plugin/
5
  Description: Countdown plugin is an nice tool to create and insert countdown timers into your posts/pages and widgets .
6
+ Version: 2.1.7
7
  Author: wpdevart
8
  Author URI: http://wpdevart.com
9
  License: GPL3 http://www.gnu.org/licenses/gpl-3.0.html