WP Notification Bars - Version 1.0.6

Version Description

  • Fixed security issues and hardened overall plugin security
  • Fixed plugin locale in gettext calls
Download this release

Release Info

Developer pbalazs
Plugin Icon 128x128 WP Notification Bars
Version 1.0.6
Comparing to
See all releases

Code changes from version 1.0.5 to 1.0.6

admin/class-wp-notification-bars-admin.php CHANGED
@@ -20,11 +20,12 @@
20
  * @subpackage MTSNBF/admin
21
  * @author MyThemeShop
22
  */
23
- // If this file is called directly, abort.
24
- if ( ! defined( 'WPINC' ) ) {
25
- die;
26
- }
27
- if( !class_exists( 'MTSNBF_Admin' ) ){
 
28
  class MTSNBF_Admin {
29
 
30
  /**
@@ -133,7 +134,7 @@
133
  $this->plugin_name,
134
  'mtsnb_locale',
135
  array(
136
- 'select_placeholder' => __( 'Enter Notification Bar Title', $this->plugin_name ),
137
  )
138
  );
139
  }
@@ -159,34 +160,34 @@
159
  */
160
  public function mts_notification_cpt() {
161
  $labels = array(
162
- 'name' => _x( 'Notification Bars', 'post type general name', $this->plugin_name ),
163
- 'singular_name' => _x( 'Notification Bar', 'post type singular name', $this->plugin_name ),
164
- 'menu_name' => _x( 'Notification Bars', 'admin menu', $this->plugin_name ),
165
- 'name_admin_bar' => _x( 'Notification Bar', 'add new on admin bar', $this->plugin_name ),
166
- 'add_new' => _x( 'Add New', 'notification bar', $this->plugin_name ),
167
- 'add_new_item' => __( 'Add New Notification Bar', $this->plugin_name ),
168
- 'new_item' => __( 'New Notification Bar', $this->plugin_name ),
169
- 'edit_item' => __( 'Edit Notification Bar', $this->plugin_name ),
170
- 'view_item' => __( 'View Notification Bar', $this->plugin_name ),
171
- 'all_items' => __( 'All Notification Bars', $this->plugin_name ),
172
- 'search_items' => __( 'Search Notification Bars', $this->plugin_name ),
173
- 'parent_item_colon' => __( 'Parent Notification Bars:', $this->plugin_name ),
174
- 'not_found' => __( 'No notification bars found.', $this->plugin_name ),
175
- 'not_found_in_trash' => __( 'No notification bars found in Trash.', $this->plugin_name )
176
  );
177
 
178
  $args = array(
179
- 'labels' => $labels,
180
- 'public' => false,
181
- 'show_ui' => true,
182
- 'capability_type' => 'post',
183
- 'hierarchical' => false,
184
- 'rewrite' => false,
185
  'publicly_queryable' => false,
186
- 'menu_position' => 100,
187
- 'menu_icon' => 'dashicons-info',
188
- 'has_archive' => false,
189
- 'supports' => array('title')
190
  );
191
 
192
  register_post_type( 'mts_notification_bar' , $args );
@@ -195,7 +196,6 @@
195
  $force_bar_supported_post_types = apply_filters( 'mtsnb_force_bar_post_types', array( 'post', 'page' ) );
196
 
197
  if ( ( $key = array_search( 'mts_notification_bar', $force_bar_supported_post_types ) ) !== false ) {
198
-
199
  unset( $force_bar_supported_post_types[ $key ] );
200
  }
201
 
@@ -211,30 +211,29 @@
211
  global $post;
212
  if ( 'mts_notification_bar' === $post->post_type ) {
213
  echo '<div class="misc-pub-section">';
214
- echo '<a href="#" class="button" id="preview-bar"><i class="dashicons dashicons-visibility"></i> '.__( 'Preview Bar', $this->plugin_name ).'</a>';
215
  echo '</div>';
216
  }
217
  }
218
 
219
  /**
220
- * Add the Meta Box
221
  *
222
  * @since 1.0
223
  */
224
  public function add_custom_meta_box() {
225
-
226
- add_meta_box(
227
- 'custom_meta_box',
228
- __( 'Settings', $this->plugin_name ),
229
- array( $this, 'show_custom_meta_box' ),
230
- 'mts_notification_bar',
231
- 'normal',
232
- 'high'
233
- );
234
  }
235
 
236
  /**
237
- * The Callback, Meta Box Content
238
  *
239
  * @since 1.0
240
  */
@@ -242,99 +241,99 @@
242
 
243
  $general_options = array(
244
  array(
245
- 'type' => 'select',
246
- 'name' => 'button',
247
- 'label' => __( 'Hide/Close Button', $this->plugin_name ),
248
- 'default'=> 'no_button',
249
  'options' => array(
250
- 'no_button' => __( 'No Button', $this->plugin_name ),
251
- 'toggle_button' => __( 'Toggle Button', $this->plugin_name ),
252
- 'close_button' => __( 'Close Button', $this->plugin_name ),
253
  ),
254
- 'class' => 'mtsnb-has-child-opt'
255
  ),
256
  array(
257
- 'type' => 'number',
258
- 'name' => 'content_width',
259
- 'label' => __( 'Content Width (px)', $this->plugin_name ),
260
- 'default'=> '960'
261
  ),
262
  array(
263
- 'type' => 'select',
264
- 'name' => 'css_position',
265
- 'label' => __( 'Notification bar CSS position', $this->plugin_name ),
266
- 'default'=> 'fixed',
267
  'options' => array(
268
- 'fixed' => __( 'Fixed', $this->plugin_name ),
269
- 'absolute' => __( 'Absolute', $this->plugin_name ),
270
- )
271
  ),
272
  );
273
 
274
  $style_options = array(
275
  array(
276
- 'type' => 'color',
277
- 'name' => 'bg_color',
278
- 'label' => __( 'Background Color', $this->plugin_name ),
279
- 'default'=> '#d35151'
280
  ),
281
  array(
282
- 'type' => 'color',
283
- 'name' => 'txt_color',
284
- 'label' => __( 'Text Color', $this->plugin_name ),
285
- 'default'=> '#ffffff'
286
  ),
287
  array(
288
- 'type' => 'color',
289
- 'name' => 'link_color',
290
- 'label' => __( 'Link Color/Button Color', $this->plugin_name ),
291
- 'default'=> '#f4a700'
292
  ),
293
  array(
294
- 'type' => 'number',
295
- 'name' => 'font_size',
296
- 'label' => __( 'Font size (px)', $this->plugin_name ),
297
- 'default'=> '15'
298
  ),
299
  );
300
 
301
  $button_content_type_options = array(
302
  array(
303
- 'type' => 'select',
304
- 'name' => 'basic_link_style',
305
- 'label' => __( 'Link Style', $this->plugin_name ),
306
- 'default'=> 'link',
307
  'options' => array(
308
- 'link' => __( 'Link', $this->plugin_name ),
309
- 'button' => __( 'Button', $this->plugin_name ),
310
- )
311
  ),
312
  array(
313
- 'type' => 'text',
314
- 'name' => 'basic_text',
315
- 'label' => __( 'Text', $this->plugin_name ),
316
- 'default'=> ''
317
  ),
318
  array(
319
- 'type' => 'text',
320
- 'name' => 'basic_link_text',
321
- 'label' => __( 'Link/Button Text', $this->plugin_name ),
322
- 'default'=> ''
323
  ),
324
  array(
325
- 'type' => 'text',
326
- 'name' => 'basic_link_url',
327
- 'label' => __( 'Link/Button Url', $this->plugin_name ),
328
- 'default'=> ''
329
  ),
330
  );
331
 
332
  $custom_content_type_options = array(
333
  array(
334
- 'type' => 'textarea',
335
- 'name' => 'custom_content',
336
- 'label' => __( 'Add custom content, shortcodes allowed', $this->plugin_name ),
337
- 'default'=> ''
338
  ),
339
  );
340
 
@@ -350,28 +349,28 @@
350
  <ul class="mtsnb-tabs-nav" id="main-tabs-nav">
351
  <li>
352
  <a href="#tab-general" <?php if ( $active_tab === 'general' ) echo 'class="active"'; ?>>
353
- <span class="mtsnb-tab-title"><i class="dashicons dashicons-admin-generic"></i><?php _e( 'General', $this->plugin_name ); ?></span>
354
  </a>
355
  </li>
356
  <li>
357
  <a href="#tab-type" <?php if ( $active_tab === 'type' ) echo 'class="active"'; ?>>
358
- <span class="mtsnb-tab-title"><i class="dashicons dashicons-edit"></i><?php _e( 'Content', $this->plugin_name ); ?></span>
359
  </a>
360
  </li>
361
  <li>
362
  <a href="#tab-style" <?php if ( $active_tab === 'style' ) echo 'class="active"'; ?>>
363
- <span class="mtsnb-tab-title"><i class="dashicons dashicons-admin-appearance"></i><?php _e( 'Style', $this->plugin_name ); ?></span>
364
  </a>
365
  </li>
366
  <li>
367
  <a href="#tab-conditions" <?php if ( $active_tab === 'conditions' ) echo 'class="active"'; ?>>
368
- <span class="mtsnb-tab-title"><i class="dashicons dashicons-admin-settings"></i><?php _e( 'Conditions', $this->plugin_name ); ?></span>
369
  </a>
370
  </li>
371
  </ul>
372
  <div class="mtsnb-tabs-wrap" id="main-tabs-wrap">
373
  <div id="tab-general" class="mtsnb-tabs-content <?php if ( $active_tab === 'general' ) echo 'active'; ?>">
374
- <div class="mtsnb-tab-desc"><?php _e( 'Select basic settings like close button type and CSS position of the bar.', $this->plugin_name ); ?></div>
375
  <div class="mtsnb-tab-options clearfix">
376
  <?php
377
  foreach ( $general_options as $option_args ) {
@@ -381,13 +380,13 @@
381
  </div>
382
  </div>
383
  <div id="tab-type" class="mtsnb-tabs-content <?php if ( $active_tab === 'type' ) echo 'active'; ?>">
384
- <div class="mtsnb-tab-desc"><?php _e( 'Set up notification bar content. Select content type and fill in the fields.', $this->plugin_name ); ?></div>
385
  <div class="mtsnb-tab-options clearfix">
386
  <?php $content_type = ( isset( $value['content_type'] ) && !empty( $value['content_type'] ) ) ? $value['content_type'] : 'button'; ?>
387
  <input type="hidden" class="mtsnb-tab-option" name="mtsnb_fields[content_type]" id="mtsnb_fields_content_type" value="<?php echo $content_type; ?>" />
388
  <ul class="mtsnb-tabs-nav" id="sub-tabs-nav">
389
- <li><a href="#tab-button" <?php if ( $content_type === 'button' ) echo 'class="active"'; ?>><?php _e( 'Text and Link/Button', $this->plugin_name ); ?></a></li>
390
- <li><a href="#tab-custom" <?php if ( $content_type === 'custom' ) echo 'class="active"'; ?>><?php _e( 'Custom', $this->plugin_name ); ?></a></li>
391
  </ul>
392
  <div class="meta-tabs-wrap" id="sub-tabs-wrap">
393
  <div id="tab-button" class="mtsnb-tabs-content <?php if ( $content_type === 'button' ) echo 'active'; ?>">
@@ -408,7 +407,7 @@
408
  </div>
409
  </div>
410
  <div id="tab-style" class="mtsnb-tabs-content <?php if ( $active_tab === 'style' ) echo 'active'; ?>">
411
- <div class="mtsnb-tab-desc"><?php _e( 'Change the appearance of the notification bar.', $this->plugin_name ); ?></div>
412
  <div class="mtsnb-tab-options clearfix">
413
  <?php
414
  foreach ( $style_options as $option_args ) {
@@ -418,7 +417,7 @@
418
  </div>
419
  </div>
420
  <div id="tab-conditions" class="mtsnb-tabs-content <?php if ( $active_tab === 'conditions' ) echo 'active'; ?>">
421
- <div class="mtsnb-tab-desc"><?php _e( 'Choose when and where to display the notification bar.', $this->plugin_name ); ?></div>
422
  <div id="conditions-selector-wrap" class="clearfix">
423
  <div id="conditions-selector">
424
  <ul>
@@ -427,12 +426,12 @@
427
  <?php $condition_location_disabled = empty( $condition_notlocation_state ) ? '' : ' disabled'; ?>
428
  <?php $condition_notlocation_disabled = empty( $condition_location_state ) ? '' : ' disabled'; ?>
429
  <li id="condition-location" data-disable="notlocation" class="condition-checkbox <?php echo $condition_location_state.$condition_location_disabled; ?>">
430
- <?php _e( 'On specific locations', $this->plugin_name ); ?>
431
  <div class="mtsnb-check"></div>
432
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_location_state" name="mtsnb_fields[conditions][location][state]" value="<?php echo $condition_location_state; ?>">
433
  </li>
434
  <li id="condition-notlocation" data-disable="location" class="condition-checkbox <?php echo $condition_notlocation_state.$condition_notlocation_disabled; ?>">
435
- <?php _e( 'Not on specific locations', $this->plugin_name ); ?>
436
  <div class="mtsnb-check"></div>
437
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_notlocation_state" name="mtsnb_fields[conditions][notlocation][state]" value="<?php echo $condition_notlocation_state; ?>">
438
  </li>
@@ -441,12 +440,12 @@
441
  <?php $condition_google_disabled = empty( $condition_notgoogle_state ) ? '' : ' disabled'; ?>
442
  <?php $condition_notgoogle_disabled = empty( $condition_google_state ) ? '' : ' disabled'; ?>
443
  <li id="condition-google" data-disable="notgoogle" class="condition-checkbox <?php echo $condition_google_state.$condition_google_disabled; ?>">
444
- <?php _e( 'From Google', $this->plugin_name ); ?>
445
  <div class="mtsnb-check"></div>
446
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_google_state" name="mtsnb_fields[conditions][google][state]" value="<?php echo $condition_google_state; ?>">
447
  </li>
448
  <li id="condition-notgoogle" data-disable="google" class="condition-checkbox <?php echo $condition_notgoogle_state.$condition_notgoogle_disabled; ?>">
449
- <?php _e( 'Not from Google', $this->plugin_name ); ?>
450
  <div class="mtsnb-check"></div>
451
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_notgoogle_state" name="mtsnb_fields[conditions][notgoogle][state]" value="<?php echo $condition_notgoogle_state; ?>">
452
  </li>
@@ -455,12 +454,12 @@
455
  <?php $condition_facebook_disabled = empty( $condition_notfacebook_state ) ? '' : ' disabled'; ?>
456
  <?php $condition_notfacebook_disabled = empty( $condition_facebook_state ) ? '' : ' disabled'; ?>
457
  <li id="condition-facebook" data-disable="notfacebook" class="condition-checkbox <?php echo $condition_facebook_state.$condition_facebook_disabled; ?>">
458
- <?php _e( 'From Facebook', $this->plugin_name ); ?>
459
  <div class="mtsnb-check"></div>
460
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_facebook_state" name="mtsnb_fields[conditions][facebook][state]" value="<?php echo $condition_facebook_state; ?>">
461
  </li>
462
  <li id="condition-notfacebook" data-disable="facebook" class="condition-checkbox <?php echo $condition_notfacebook_state.$condition_notfacebook_disabled; ?>">
463
- <?php _e( 'Not from Facebook', $this->plugin_name ); ?>
464
  <div class="mtsnb-check"></div>
465
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_notfacebook_state" name="mtsnb_fields[conditions][notfacebook][state]" value="<?php echo $condition_notfacebook_state; ?>">
466
  </li>
@@ -468,9 +467,9 @@
468
  </div>
469
  <div id="conditions-panels">
470
  <div id="condition-location-panel" class="mtsnb-conditions-panel <?php echo $condition_location_state; ?>">
471
- <div class="mtsnb-conditions-panel-title"><?php _e( 'On specific locations', $this->plugin_name ); ?></div>
472
  <div class="mtsnb-conditions-panel-content">
473
- <div class="mtsnb-conditions-panel-desc"><?php _e( 'Show Notification Bar on the following locations', $this->plugin_name ); ?></div>
474
  <div class="mtsnb-conditions-panel-opt">
475
  <?php $location_home = isset( $value['conditions'] ) && isset( $value['conditions']['location'] ) && ( isset( $value['conditions']['location']['home'] ) && !empty( $value['conditions']['location']['home'] ) ) ? $value['conditions']['location']['home'] : '0'; ?>
476
  <?php $location_blog_home = isset( $value['conditions'] ) && isset( $value['conditions']['location'] ) && ( isset( $value['conditions']['location']['blog_home'] ) && !empty( $value['conditions']['location']['blog_home'] ) ) ? $value['conditions']['location']['blog_home'] : '0'; ?>
@@ -479,36 +478,36 @@
479
  <p>
480
  <label>
481
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][location][home]" id="mtsnb_fields_conditions_location_home" value="1" <?php checked( $location_home, '1', true ); ?> />
482
- <?php _e( 'Homepage.', $this->plugin_name ); ?>
483
  </label>
484
  </p>
485
  <?php if ( 'page' === get_option('show_on_front') && '0' !== get_option('page_for_posts') && '0' !== get_option('page_on_front') ) { ?>
486
  <p>
487
  <label>
488
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][location][blog_home]" id="mtsnb_fields_conditions_location_blog_home" value="1" <?php checked( $location_blog_home, '1', true ); ?> />
489
- <?php _e( 'Blog Homepage.', $this->plugin_name ); ?>
490
  </label>
491
  </p>
492
  <?php } ?>
493
  <p>
494
  <label>
495
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][location][pages]" id="mtsnb_fields_conditions_location_pages" value="1" <?php checked( $location_pages, '1', true ); ?> />
496
- <?php _e( 'Pages.', $this->plugin_name ); ?>
497
  </label>
498
  </p>
499
  <p>
500
  <label>
501
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][location][posts]" id="mtsnb_fields_conditions_location_posts" value="1" <?php checked( $location_posts, '1', true ); ?> />
502
- <?php _e( 'Posts.', $this->plugin_name ); ?>
503
  </label>
504
  </p>
505
  </div>
506
  </div>
507
  </div>
508
  <div id="condition-notlocation-panel" class="mtsnb-conditions-panel <?php echo $condition_notlocation_state; ?>">
509
- <div class="mtsnb-conditions-panel-title"><?php _e( 'Not on specific locations', $this->plugin_name ); ?></div>
510
  <div class="mtsnb-conditions-panel-content">
511
- <div class="mtsnb-conditions-panel-desc"><?php _e( 'Hide Notification Bar on the following locations', $this->plugin_name ); ?></div>
512
  <div class="mtsnb-conditions-panel-opt">
513
  <?php $notlocation_home = isset( $value['conditions'] ) && isset( $value['conditions']['notlocation'] ) && ( isset( $value['conditions']['notlocation']['home'] ) && !empty( $value['conditions']['notlocation']['home'] ) ) ? $value['conditions']['notlocation']['home'] : '0'; ?>
514
  <?php $notlocation_blog_home = isset( $value['conditions'] ) && isset( $value['conditions']['notlocation'] ) && ( isset( $value['conditions']['notlocation']['blog_home'] ) && !empty( $value['conditions']['notlocation']['blog_home'] ) ) ? $value['conditions']['notlocation']['blog_home'] : '0'; ?>
@@ -517,75 +516,75 @@
517
  <p>
518
  <label>
519
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][notlocation][home]" id="mtsnb_fields_conditions_notlocation_home" value="1" <?php checked( $notlocation_home, '1', true ); ?> />
520
- <?php _e( 'Homepage.', $this->plugin_name ); ?>
521
  </label>
522
  </p>
523
  <?php if ( 'page' === get_option('show_on_front') && '0' !== get_option('page_for_posts') && '0' !== get_option('page_on_front') ) { ?>
524
  <p>
525
  <label>
526
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][notlocation][blog_home]" id="mtsnb_fields_conditions_notlocation_blog_home" value="1" <?php checked( $notlocation_blog_home, '1', true ); ?> />
527
- <?php _e( 'Blog Homepage.', $this->plugin_name ); ?>
528
  </label>
529
  </p>
530
  <?php } ?>
531
  <p>
532
  <label>
533
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][notlocation][pages]" id="mtsnb_fields_conditions_notlocation_pages" value="1" <?php checked( $notlocation_pages, '1', true ); ?> />
534
- <?php _e( 'Pages.', $this->plugin_name ); ?>
535
  </label>
536
  </p>
537
  <p>
538
  <label>
539
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][notlocation][posts]" id="mtsnb_fields_conditions_notlocation_posts" value="1" <?php checked( $notlocation_posts, '1', true ); ?> />
540
- <?php _e( 'Posts.', $this->plugin_name ); ?>
541
  </label>
542
  </p>
543
  </div>
544
  </div>
545
  </div>
546
  <div id="condition-google-panel" class="mtsnb-conditions-panel <?php echo $condition_google_state; ?>">
547
- <div class="mtsnb-conditions-panel-title"><?php _e( 'From Google', $this->plugin_name ); ?></div>
548
  <div class="mtsnb-conditions-panel-content">
549
  <div class="mtsnb-conditions-panel-desc">
550
  <p>
551
  <label>
552
- <?php _e( 'Show Notification Bar if visitor arrived via Google search engine.', $this->plugin_name ); ?>
553
  </label>
554
  </p>
555
  </div>
556
  </div>
557
  </div>
558
  <div id="condition-notgoogle-panel" class="mtsnb-conditions-panel <?php echo $condition_notgoogle_state; ?>">
559
- <div class="mtsnb-conditions-panel-title"><?php _e( 'Not from Google', $this->plugin_name ); ?></div>
560
  <div class="mtsnb-conditions-panel-content">
561
  <div class="mtsnb-conditions-panel-desc">
562
  <p>
563
  <label>
564
- <?php _e( 'Hide Notification Bar if visitor arrived via Google search engine.', $this->plugin_name ); ?>
565
  </label>
566
  </p>
567
  </div>
568
  </div>
569
  </div>
570
  <div id="condition-facebook-panel" class="mtsnb-conditions-panel <?php echo $condition_facebook_state; ?>">
571
- <div class="mtsnb-conditions-panel-title"><?php _e( 'From Facebook', $this->plugin_name ); ?></div>
572
  <div class="mtsnb-conditions-panel-content">
573
  <div class="mtsnb-conditions-panel-desc">
574
  <p>
575
  <label>
576
- <?php _e( 'Show Notification Bar if visitor arrived from Facebook.', $this->plugin_name ); ?>
577
  </label>
578
  </p>
579
  </div>
580
  </div>
581
  </div>
582
  <div id="condition-notfacebook-panel" class="mtsnb-conditions-panel <?php echo $condition_notfacebook_state; ?>">
583
- <div class="mtsnb-conditions-panel-title"><?php _e( 'Not from Facebook', $this->plugin_name ); ?></div>
584
  <div class="mtsnb-conditions-panel-content">
585
  <div class="mtsnb-conditions-panel-desc">
586
  <p>
587
  <label>
588
- <?php _e( 'Hide Notification Bar if visitor arrived from Facebook.', $this->plugin_name ); ?>
589
  </label>
590
  </p>
591
  </div>
@@ -607,13 +606,13 @@
607
  */
608
  public function custom_meta_field( $args, $value, $b = false ) {
609
 
610
- $type = isset( $args['type'] ) ? $args['type'] : '';
611
- $name = isset( $args['name'] ) ? $args['name'] : '';
612
- $name = $b ? 'b_'.$name : $name;
613
- $label = isset( $args['label'] ) ? $args['label'] : '';
614
  $options = isset( $args['options'] ) ? $args['options'] : array();
615
  $default = isset( $args['default'] ) ? $args['default'] : '';
616
- $min = isset( $args['min'] ) ? $args['min'] : '0';
617
 
618
  $class = isset( $args['class'] ) ? $args['class'] : '';
619
 
@@ -621,50 +620,50 @@
621
  $opt_val = isset( $value[ $name ] ) ? $value[ $name ] : $default;
622
 
623
  ?>
624
- <div id="mtsnb_fields_<?php echo $name;?>_row" class="form-row">
625
- <label class="form-label" for="mtsnb_fields_<?php echo $name;?>"><?php echo $label; ?></label>
626
- <div class="form-option <?php echo $class; ?>">
627
  <?php
628
  switch ( $type ) {
629
 
630
  case 'text':
631
  ?>
632
- <input type="text" name="mtsnb_fields[<?php echo $name;?>]" id="mtsnb_fields_<?php echo $name;?>" value="<?php echo esc_attr( $opt_val );?>" />
633
  <?php
634
  break;
635
  case 'select':
636
  ?>
637
- <select name="mtsnb_fields[<?php echo $name;?>]" id="mtsnb_fields_<?php echo $name;?>">
638
  <?php foreach ( $options as $val => $label ) { ?>
639
- <option value="<?php echo $val; ?>" <?php selected( $opt_val, $val, true); ?>><?php echo $label ?></option>
640
  <?php } ?>
641
  </select>
642
  <?php
643
  break;
644
  case 'number':
645
  ?>
646
- <input type="number" step="1" min="<?php echo $min;?>" name="mtsnb_fields[<?php echo $name;?>]" id="mtsnb_fields_<?php echo $name;?>" value="<?php echo $opt_val;?>" class="small-text"/>
647
  <?php
648
  break;
649
  case 'color':
650
  ?>
651
- <input type="text" name="mtsnb_fields[<?php echo $name;?>]" id="mtsnb_fields_<?php echo $name;?>" value="<?php echo $opt_val;?>" class="mtsnb-color-picker" />
652
  <?php
653
  break;
654
  case 'textarea':
655
  ?>
656
- <textarea name="mtsnb_fields[<?php echo $name;?>]" id="mtsnb_fields_<?php echo $name;?>" class="mtsnb-textarea"><?php echo esc_textarea( $opt_val );?></textarea>
657
  <?php
658
  break;
659
  case 'checkbox':
660
  ?>
661
- <input type="checkbox" name="mtsnb_fields[<?php echo $name;?>]" id="mtsnb_fields_<?php echo $name;?>" value="1" <?php checked( $opt_val, '1', true ); ?> />
662
  <?php
663
  break;
664
  case 'info':
665
  ?>
666
  <small class="mtsnb-option-info">
667
- <?php echo $default; ?>
668
  </small>
669
  <?php
670
  break;
@@ -745,7 +744,7 @@
745
  /* Only show the notice 2 days after plugin activation */
746
  if ( ! get_user_meta($user_id, 'wp_notification_bar_ignore_notice') && time() >= (get_option( 'wp_notification_bar_activated', 0 ) + (2 * 24 * 60 * 60)) ) {
747
  echo '<div class="updated notice-info wp-notification-bar-notice" id="wpnotificationbar-notice" style="position:relative;">';
748
- echo __('<p>Like WP Notification Bar plugin? You will LOVE <a target="_blank" href="https://mythemeshop.com/plugins/wp-notification-bar/?utm_source=WP+Notification+Bars&utm_medium=Notification+Link&utm_content=WP+Notification+Bar+Pro+LP&utm_campaign=WordPressOrg"><strong>WP Notification Bar Pro!</strong></a></p><a class="notice-dismiss mtsnb-notice-dismiss" data-ignore="0" href="#"></a>', $this->plugin_name);
749
  echo "</div>";
750
  }
751
  /* Other notice appears right after activating */
@@ -755,7 +754,7 @@
755
  update_option( 'wp_notification_bar_notice_views', ($views + 1) );
756
  echo '<div class="updated notice-info wp-notification-bar-notice" id="wpnotificationbar-notice2" style="position:relative;">';
757
  echo '<p>';
758
- _e('Thank you for trying WP Notification Bar. We hope you will like it.', $this->plugin_name);
759
  echo '</p>';
760
  echo '<a class="notice-dismiss mtsnb-notice-dismiss" data-ignore="1" href="#"></a>';
761
  echo "</div>";
@@ -783,7 +782,7 @@
783
  public function disabled_notice() {
784
  ?>
785
  <div class="updated">
786
- <p><?php _e( 'Free version of WP Notification Bars plugin disabled. Pro version is active!', $this->plugin_name ); ?></p>
787
  </div>
788
  <?php
789
  }
@@ -807,16 +806,16 @@
807
 
808
  $messages['mts_notification_bar'] = array(
809
  0 => '', // Unused. Messages start at index 1.
810
- 1 => __( 'Notification Bar updated.', $this->plugin_name ),
811
- 2 => __( 'Custom field updated.', $this->plugin_name ),
812
- 3 => __( 'Custom field deleted.', $this->plugin_name ),
813
- 4 => __( 'Notification Bar updated.', $this->plugin_name ),
814
  5 => isset($_GET['revision']) ? sprintf( __('Notification Bar restored to revision from %s'), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,
815
- 6 => __( 'Notification Bar published.', $this->plugin_name ),
816
- 7 => __( 'Notification Bar saved.', $this->plugin_name ),
817
- 8 => __( 'Notification Bar submitted.', $this->plugin_name),
818
- 9 => sprintf( __('Notification Bar scheduled for: <strong>%1$s</strong>.', $this->plugin_name ), date_i18n( __( 'M j, Y @ H:i' ), strtotime( $post->post_date ) ) ),
819
- 10 => __('Notification Bar draft updated.', $this->plugin_name ),
820
  );
821
  }
822
 
@@ -839,7 +838,7 @@
839
 
840
  add_meta_box(
841
  'mtsnb_single_bar_metabox',
842
- __( 'Notification Bar', $this->plugin_name ),
843
  array( $this, 'mtsnb_select_metabox_content' ),
844
  $screen,
845
  'side',
@@ -879,11 +878,11 @@
879
  }
880
  ?>
881
  <p>
882
- <label for="mtsnb_override_bar_field"><?php _e( 'Select Notification Bar (optional):', $this->plugin_name ); ?></label><br />
883
  <input style="width: 400px;" type="hidden" id="mtsnb_override_bar_field" name="mtsnb_override_bar_field" class="mtsnb-bar-select" value="<?php echo $processed_item_ids; ?>" />
884
  </p>
885
  <p>
886
- <i><?php _e( 'Selected notification bar will override any other bar.', $this->plugin_name ); ?></i>
887
  </p>
888
  <?php
889
  }
20
  * @subpackage MTSNBF/admin
21
  * @author MyThemeShop
22
  */
23
+ // If this file is called directly, abort.
24
+ if ( ! defined( 'WPINC' ) ) {
25
+ die;
26
+ }
27
+
28
+ if ( ! class_exists( 'MTSNBF_Admin' ) ) {
29
  class MTSNBF_Admin {
30
 
31
  /**
134
  $this->plugin_name,
135
  'mtsnb_locale',
136
  array(
137
+ 'select_placeholder' => __( 'Enter Notification Bar Title', 'wp-notification-bars' ),
138
  )
139
  );
140
  }
160
  */
161
  public function mts_notification_cpt() {
162
  $labels = array(
163
+ 'name' => _x( 'Notification Bars', 'post type general name', 'wp-notification-bars' ),
164
+ 'singular_name' => _x( 'Notification Bar', 'post type singular name', 'wp-notification-bars' ),
165
+ 'menu_name' => _x( 'Notification Bars', 'admin menu', 'wp-notification-bars' ),
166
+ 'name_admin_bar' => _x( 'Notification Bar', 'add new on admin bar', 'wp-notification-bars' ),
167
+ 'add_new' => _x( 'Add New', 'notification bar', 'wp-notification-bars' ),
168
+ 'add_new_item' => __( 'Add New Notification Bar', 'wp-notification-bars' ),
169
+ 'new_item' => __( 'New Notification Bar', 'wp-notification-bars' ),
170
+ 'edit_item' => __( 'Edit Notification Bar', 'wp-notification-bars' ),
171
+ 'view_item' => __( 'View Notification Bar', 'wp-notification-bars' ),
172
+ 'all_items' => __( 'All Notification Bars', 'wp-notification-bars' ),
173
+ 'search_items' => __( 'Search Notification Bars', 'wp-notification-bars' ),
174
+ 'parent_item_colon' => __( 'Parent Notification Bars:', 'wp-notification-bars' ),
175
+ 'not_found' => __( 'No notification bars found.', 'wp-notification-bars' ),
176
+ 'not_found_in_trash' => __( 'No notification bars found in Trash.', 'wp-notification-bars' )
177
  );
178
 
179
  $args = array(
180
+ 'labels' => $labels,
181
+ 'public' => false,
182
+ 'show_ui' => true,
183
+ 'capability_type' => 'post',
184
+ 'hierarchical' => false,
185
+ 'rewrite' => false,
186
  'publicly_queryable' => false,
187
+ 'menu_position' => 100,
188
+ 'menu_icon' => 'dashicons-info',
189
+ 'has_archive' => false,
190
+ 'supports' => array( 'title' ),
191
  );
192
 
193
  register_post_type( 'mts_notification_bar' , $args );
196
  $force_bar_supported_post_types = apply_filters( 'mtsnb_force_bar_post_types', array( 'post', 'page' ) );
197
 
198
  if ( ( $key = array_search( 'mts_notification_bar', $force_bar_supported_post_types ) ) !== false ) {
 
199
  unset( $force_bar_supported_post_types[ $key ] );
200
  }
201
 
211
  global $post;
212
  if ( 'mts_notification_bar' === $post->post_type ) {
213
  echo '<div class="misc-pub-section">';
214
+ echo '<a href="#" class="button" id="preview-bar"><i class="dashicons dashicons-visibility"></i> '.__( 'Preview Bar', 'wp-notification-bars' ).'</a>';
215
  echo '</div>';
216
  }
217
  }
218
 
219
  /**
220
+ * Add the Meta Box.
221
  *
222
  * @since 1.0
223
  */
224
  public function add_custom_meta_box() {
225
+ add_meta_box(
226
+ 'custom_meta_box',
227
+ __( 'Settings', 'wp-notification-bars' ),
228
+ array( $this, 'show_custom_meta_box' ),
229
+ 'mts_notification_bar',
230
+ 'normal',
231
+ 'high'
232
+ );
 
233
  }
234
 
235
  /**
236
+ * The Callback, Meta Box Content.
237
  *
238
  * @since 1.0
239
  */
241
 
242
  $general_options = array(
243
  array(
244
+ 'type' => 'select',
245
+ 'name' => 'button',
246
+ 'label' => __( 'Hide/Close Button', 'wp-notification-bars' ),
247
+ 'default' => 'no_button',
248
  'options' => array(
249
+ 'no_button' => __( 'No Button', 'wp-notification-bars' ),
250
+ 'toggle_button' => __( 'Toggle Button', 'wp-notification-bars' ),
251
+ 'close_button' => __( 'Close Button', 'wp-notification-bars' ),
252
  ),
253
+ 'class' => 'mtsnb-has-child-opt',
254
  ),
255
  array(
256
+ 'type' => 'number',
257
+ 'name' => 'content_width',
258
+ 'label' => __( 'Content Width (px)', 'wp-notification-bars' ),
259
+ 'default' => '960',
260
  ),
261
  array(
262
+ 'type' => 'select',
263
+ 'name' => 'css_position',
264
+ 'label' => __( 'Notification bar CSS position', 'wp-notification-bars' ),
265
+ 'default' => 'fixed',
266
  'options' => array(
267
+ 'fixed' => __( 'Fixed', 'wp-notification-bars' ),
268
+ 'absolute' => __( 'Absolute', 'wp-notification-bars' ),
269
+ ),
270
  ),
271
  );
272
 
273
  $style_options = array(
274
  array(
275
+ 'type' => 'color',
276
+ 'name' => 'bg_color',
277
+ 'label' => __( 'Background Color', 'wp-notification-bars' ),
278
+ 'default' => '#d35151',
279
  ),
280
  array(
281
+ 'type' => 'color',
282
+ 'name' => 'txt_color',
283
+ 'label' => __( 'Text Color', 'wp-notification-bars' ),
284
+ 'default' => '#ffffff',
285
  ),
286
  array(
287
+ 'type' => 'color',
288
+ 'name' => 'link_color',
289
+ 'label' => __( 'Link Color/Button Color', 'wp-notification-bars' ),
290
+ 'default' => '#f4a700',
291
  ),
292
  array(
293
+ 'type' => 'number',
294
+ 'name' => 'font_size',
295
+ 'label' => __( 'Font size (px)', 'wp-notification-bars' ),
296
+ 'default' => '15',
297
  ),
298
  );
299
 
300
  $button_content_type_options = array(
301
  array(
302
+ 'type' => 'select',
303
+ 'name' => 'basic_link_style',
304
+ 'label' => __( 'Link Style', 'wp-notification-bars' ),
305
+ 'default' => 'link',
306
  'options' => array(
307
+ 'link' => __( 'Link', 'wp-notification-bars' ),
308
+ 'button' => __( 'Button', 'wp-notification-bars' ),
309
+ ),
310
  ),
311
  array(
312
+ 'type' => 'text',
313
+ 'name' => 'basic_text',
314
+ 'label' => __( 'Text', 'wp-notification-bars' ),
315
+ 'default' => '',
316
  ),
317
  array(
318
+ 'type' => 'text',
319
+ 'name' => 'basic_link_text',
320
+ 'label' => __( 'Link/Button Text', 'wp-notification-bars' ),
321
+ 'default' => '',
322
  ),
323
  array(
324
+ 'type' => 'text',
325
+ 'name' => 'basic_link_url',
326
+ 'label' => __( 'Link/Button Url', 'wp-notification-bars' ),
327
+ 'default' => '',
328
  ),
329
  );
330
 
331
  $custom_content_type_options = array(
332
  array(
333
+ 'type' => 'textarea',
334
+ 'name' => 'custom_content',
335
+ 'label' => __( 'Add custom content, shortcodes allowed', 'wp-notification-bars' ),
336
+ 'default' => '',
337
  ),
338
  );
339
 
349
  <ul class="mtsnb-tabs-nav" id="main-tabs-nav">
350
  <li>
351
  <a href="#tab-general" <?php if ( $active_tab === 'general' ) echo 'class="active"'; ?>>
352
+ <span class="mtsnb-tab-title"><i class="dashicons dashicons-admin-generic"></i><?php _e( 'General', 'wp-notification-bars' ); ?></span>
353
  </a>
354
  </li>
355
  <li>
356
  <a href="#tab-type" <?php if ( $active_tab === 'type' ) echo 'class="active"'; ?>>
357
+ <span class="mtsnb-tab-title"><i class="dashicons dashicons-edit"></i><?php _e( 'Content', 'wp-notification-bars' ); ?></span>
358
  </a>
359
  </li>
360
  <li>
361
  <a href="#tab-style" <?php if ( $active_tab === 'style' ) echo 'class="active"'; ?>>
362
+ <span class="mtsnb-tab-title"><i class="dashicons dashicons-admin-appearance"></i><?php _e( 'Style', 'wp-notification-bars' ); ?></span>
363
  </a>
364
  </li>
365
  <li>
366
  <a href="#tab-conditions" <?php if ( $active_tab === 'conditions' ) echo 'class="active"'; ?>>
367
+ <span class="mtsnb-tab-title"><i class="dashicons dashicons-admin-settings"></i><?php _e( 'Conditions', 'wp-notification-bars' ); ?></span>
368
  </a>
369
  </li>
370
  </ul>
371
  <div class="mtsnb-tabs-wrap" id="main-tabs-wrap">
372
  <div id="tab-general" class="mtsnb-tabs-content <?php if ( $active_tab === 'general' ) echo 'active'; ?>">
373
+ <div class="mtsnb-tab-desc"><?php _e( 'Select basic settings like close button type and CSS position of the bar.', 'wp-notification-bars' ); ?></div>
374
  <div class="mtsnb-tab-options clearfix">
375
  <?php
376
  foreach ( $general_options as $option_args ) {
380
  </div>
381
  </div>
382
  <div id="tab-type" class="mtsnb-tabs-content <?php if ( $active_tab === 'type' ) echo 'active'; ?>">
383
+ <div class="mtsnb-tab-desc"><?php _e( 'Set up notification bar content. Select content type and fill in the fields.', 'wp-notification-bars' ); ?></div>
384
  <div class="mtsnb-tab-options clearfix">
385
  <?php $content_type = ( isset( $value['content_type'] ) && !empty( $value['content_type'] ) ) ? $value['content_type'] : 'button'; ?>
386
  <input type="hidden" class="mtsnb-tab-option" name="mtsnb_fields[content_type]" id="mtsnb_fields_content_type" value="<?php echo $content_type; ?>" />
387
  <ul class="mtsnb-tabs-nav" id="sub-tabs-nav">
388
+ <li><a href="#tab-button" <?php if ( $content_type === 'button' ) echo 'class="active"'; ?>><?php _e( 'Text and Link/Button', 'wp-notification-bars' ); ?></a></li>
389
+ <li><a href="#tab-custom" <?php if ( $content_type === 'custom' ) echo 'class="active"'; ?>><?php _e( 'Custom', 'wp-notification-bars' ); ?></a></li>
390
  </ul>
391
  <div class="meta-tabs-wrap" id="sub-tabs-wrap">
392
  <div id="tab-button" class="mtsnb-tabs-content <?php if ( $content_type === 'button' ) echo 'active'; ?>">
407
  </div>
408
  </div>
409
  <div id="tab-style" class="mtsnb-tabs-content <?php if ( $active_tab === 'style' ) echo 'active'; ?>">
410
+ <div class="mtsnb-tab-desc"><?php _e( 'Change the appearance of the notification bar.', 'wp-notification-bars' ); ?></div>
411
  <div class="mtsnb-tab-options clearfix">
412
  <?php
413
  foreach ( $style_options as $option_args ) {
417
  </div>
418
  </div>
419
  <div id="tab-conditions" class="mtsnb-tabs-content <?php if ( $active_tab === 'conditions' ) echo 'active'; ?>">
420
+ <div class="mtsnb-tab-desc"><?php _e( 'Choose when and where to display the notification bar.', 'wp-notification-bars' ); ?></div>
421
  <div id="conditions-selector-wrap" class="clearfix">
422
  <div id="conditions-selector">
423
  <ul>
426
  <?php $condition_location_disabled = empty( $condition_notlocation_state ) ? '' : ' disabled'; ?>
427
  <?php $condition_notlocation_disabled = empty( $condition_location_state ) ? '' : ' disabled'; ?>
428
  <li id="condition-location" data-disable="notlocation" class="condition-checkbox <?php echo $condition_location_state.$condition_location_disabled; ?>">
429
+ <?php _e( 'On specific locations', 'wp-notification-bars' ); ?>
430
  <div class="mtsnb-check"></div>
431
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_location_state" name="mtsnb_fields[conditions][location][state]" value="<?php echo $condition_location_state; ?>">
432
  </li>
433
  <li id="condition-notlocation" data-disable="location" class="condition-checkbox <?php echo $condition_notlocation_state.$condition_notlocation_disabled; ?>">
434
+ <?php _e( 'Not on specific locations', 'wp-notification-bars' ); ?>
435
  <div class="mtsnb-check"></div>
436
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_notlocation_state" name="mtsnb_fields[conditions][notlocation][state]" value="<?php echo $condition_notlocation_state; ?>">
437
  </li>
440
  <?php $condition_google_disabled = empty( $condition_notgoogle_state ) ? '' : ' disabled'; ?>
441
  <?php $condition_notgoogle_disabled = empty( $condition_google_state ) ? '' : ' disabled'; ?>
442
  <li id="condition-google" data-disable="notgoogle" class="condition-checkbox <?php echo $condition_google_state.$condition_google_disabled; ?>">
443
+ <?php _e( 'From Google', 'wp-notification-bars' ); ?>
444
  <div class="mtsnb-check"></div>
445
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_google_state" name="mtsnb_fields[conditions][google][state]" value="<?php echo $condition_google_state; ?>">
446
  </li>
447
  <li id="condition-notgoogle" data-disable="google" class="condition-checkbox <?php echo $condition_notgoogle_state.$condition_notgoogle_disabled; ?>">
448
+ <?php _e( 'Not from Google', 'wp-notification-bars' ); ?>
449
  <div class="mtsnb-check"></div>
450
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_notgoogle_state" name="mtsnb_fields[conditions][notgoogle][state]" value="<?php echo $condition_notgoogle_state; ?>">
451
  </li>
454
  <?php $condition_facebook_disabled = empty( $condition_notfacebook_state ) ? '' : ' disabled'; ?>
455
  <?php $condition_notfacebook_disabled = empty( $condition_facebook_state ) ? '' : ' disabled'; ?>
456
  <li id="condition-facebook" data-disable="notfacebook" class="condition-checkbox <?php echo $condition_facebook_state.$condition_facebook_disabled; ?>">
457
+ <?php _e( 'From Facebook', 'wp-notification-bars' ); ?>
458
  <div class="mtsnb-check"></div>
459
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_facebook_state" name="mtsnb_fields[conditions][facebook][state]" value="<?php echo $condition_facebook_state; ?>">
460
  </li>
461
  <li id="condition-notfacebook" data-disable="facebook" class="condition-checkbox <?php echo $condition_notfacebook_state.$condition_notfacebook_disabled; ?>">
462
+ <?php _e( 'Not from Facebook', 'wp-notification-bars' ); ?>
463
  <div class="mtsnb-check"></div>
464
  <input type="hidden" class="mtsnb-condition-checkbox-input" id="mtsnb_fields_conditions_notfacebook_state" name="mtsnb_fields[conditions][notfacebook][state]" value="<?php echo $condition_notfacebook_state; ?>">
465
  </li>
467
  </div>
468
  <div id="conditions-panels">
469
  <div id="condition-location-panel" class="mtsnb-conditions-panel <?php echo $condition_location_state; ?>">
470
+ <div class="mtsnb-conditions-panel-title"><?php _e( 'On specific locations', 'wp-notification-bars' ); ?></div>
471
  <div class="mtsnb-conditions-panel-content">
472
+ <div class="mtsnb-conditions-panel-desc"><?php _e( 'Show Notification Bar on the following locations', 'wp-notification-bars' ); ?></div>
473
  <div class="mtsnb-conditions-panel-opt">
474
  <?php $location_home = isset( $value['conditions'] ) && isset( $value['conditions']['location'] ) && ( isset( $value['conditions']['location']['home'] ) && !empty( $value['conditions']['location']['home'] ) ) ? $value['conditions']['location']['home'] : '0'; ?>
475
  <?php $location_blog_home = isset( $value['conditions'] ) && isset( $value['conditions']['location'] ) && ( isset( $value['conditions']['location']['blog_home'] ) && !empty( $value['conditions']['location']['blog_home'] ) ) ? $value['conditions']['location']['blog_home'] : '0'; ?>
478
  <p>
479
  <label>
480
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][location][home]" id="mtsnb_fields_conditions_location_home" value="1" <?php checked( $location_home, '1', true ); ?> />
481
+ <?php _e( 'Homepage.', 'wp-notification-bars' ); ?>
482
  </label>
483
  </p>
484
  <?php if ( 'page' === get_option('show_on_front') && '0' !== get_option('page_for_posts') && '0' !== get_option('page_on_front') ) { ?>
485
  <p>
486
  <label>
487
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][location][blog_home]" id="mtsnb_fields_conditions_location_blog_home" value="1" <?php checked( $location_blog_home, '1', true ); ?> />
488
+ <?php _e( 'Blog Homepage.', 'wp-notification-bars' ); ?>
489
  </label>
490
  </p>
491
  <?php } ?>
492
  <p>
493
  <label>
494
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][location][pages]" id="mtsnb_fields_conditions_location_pages" value="1" <?php checked( $location_pages, '1', true ); ?> />
495
+ <?php _e( 'Pages.', 'wp-notification-bars' ); ?>
496
  </label>
497
  </p>
498
  <p>
499
  <label>
500
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][location][posts]" id="mtsnb_fields_conditions_location_posts" value="1" <?php checked( $location_posts, '1', true ); ?> />
501
+ <?php _e( 'Posts.', 'wp-notification-bars' ); ?>
502
  </label>
503
  </p>
504
  </div>
505
  </div>
506
  </div>
507
  <div id="condition-notlocation-panel" class="mtsnb-conditions-panel <?php echo $condition_notlocation_state; ?>">
508
+ <div class="mtsnb-conditions-panel-title"><?php _e( 'Not on specific locations', 'wp-notification-bars' ); ?></div>
509
  <div class="mtsnb-conditions-panel-content">
510
+ <div class="mtsnb-conditions-panel-desc"><?php _e( 'Hide Notification Bar on the following locations', 'wp-notification-bars' ); ?></div>
511
  <div class="mtsnb-conditions-panel-opt">
512
  <?php $notlocation_home = isset( $value['conditions'] ) && isset( $value['conditions']['notlocation'] ) && ( isset( $value['conditions']['notlocation']['home'] ) && !empty( $value['conditions']['notlocation']['home'] ) ) ? $value['conditions']['notlocation']['home'] : '0'; ?>
513
  <?php $notlocation_blog_home = isset( $value['conditions'] ) && isset( $value['conditions']['notlocation'] ) && ( isset( $value['conditions']['notlocation']['blog_home'] ) && !empty( $value['conditions']['notlocation']['blog_home'] ) ) ? $value['conditions']['notlocation']['blog_home'] : '0'; ?>
516
  <p>
517
  <label>
518
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][notlocation][home]" id="mtsnb_fields_conditions_notlocation_home" value="1" <?php checked( $notlocation_home, '1', true ); ?> />
519
+ <?php _e( 'Homepage.', 'wp-notification-bars' ); ?>
520
  </label>
521
  </p>
522
  <?php if ( 'page' === get_option('show_on_front') && '0' !== get_option('page_for_posts') && '0' !== get_option('page_on_front') ) { ?>
523
  <p>
524
  <label>
525
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][notlocation][blog_home]" id="mtsnb_fields_conditions_notlocation_blog_home" value="1" <?php checked( $notlocation_blog_home, '1', true ); ?> />
526
+ <?php _e( 'Blog Homepage.', 'wp-notification-bars' ); ?>
527
  </label>
528
  </p>
529
  <?php } ?>
530
  <p>
531
  <label>
532
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][notlocation][pages]" id="mtsnb_fields_conditions_notlocation_pages" value="1" <?php checked( $notlocation_pages, '1', true ); ?> />
533
+ <?php _e( 'Pages.', 'wp-notification-bars' ); ?>
534
  </label>
535
  </p>
536
  <p>
537
  <label>
538
  <input type="checkbox" class="mtsnb-checkbox" name="mtsnb_fields[conditions][notlocation][posts]" id="mtsnb_fields_conditions_notlocation_posts" value="1" <?php checked( $notlocation_posts, '1', true ); ?> />
539
+ <?php _e( 'Posts.', 'wp-notification-bars' ); ?>
540
  </label>
541
  </p>
542
  </div>
543
  </div>
544
  </div>
545
  <div id="condition-google-panel" class="mtsnb-conditions-panel <?php echo $condition_google_state; ?>">
546
+ <div class="mtsnb-conditions-panel-title"><?php _e( 'From Google', 'wp-notification-bars' ); ?></div>
547
  <div class="mtsnb-conditions-panel-content">
548
  <div class="mtsnb-conditions-panel-desc">
549
  <p>
550
  <label>
551
+ <?php _e( 'Show Notification Bar if visitor arrived via Google search engine.', 'wp-notification-bars' ); ?>
552
  </label>
553
  </p>
554
  </div>
555
  </div>
556
  </div>
557
  <div id="condition-notgoogle-panel" class="mtsnb-conditions-panel <?php echo $condition_notgoogle_state; ?>">
558
+ <div class="mtsnb-conditions-panel-title"><?php _e( 'Not from Google', 'wp-notification-bars' ); ?></div>
559
  <div class="mtsnb-conditions-panel-content">
560
  <div class="mtsnb-conditions-panel-desc">
561
  <p>
562
  <label>
563
+ <?php _e( 'Hide Notification Bar if visitor arrived via Google search engine.', 'wp-notification-bars' ); ?>
564
  </label>
565
  </p>
566
  </div>
567
  </div>
568
  </div>
569
  <div id="condition-facebook-panel" class="mtsnb-conditions-panel <?php echo $condition_facebook_state; ?>">
570
+ <div class="mtsnb-conditions-panel-title"><?php _e( 'From Facebook', 'wp-notification-bars' ); ?></div>
571
  <div class="mtsnb-conditions-panel-content">
572
  <div class="mtsnb-conditions-panel-desc">
573
  <p>
574
  <label>
575
+ <?php _e( 'Show Notification Bar if visitor arrived from Facebook.', 'wp-notification-bars' ); ?>
576
  </label>
577
  </p>
578
  </div>
579
  </div>
580
  </div>
581
  <div id="condition-notfacebook-panel" class="mtsnb-conditions-panel <?php echo $condition_notfacebook_state; ?>">
582
+ <div class="mtsnb-conditions-panel-title"><?php _e( 'Not from Facebook', 'wp-notification-bars' ); ?></div>
583
  <div class="mtsnb-conditions-panel-content">
584
  <div class="mtsnb-conditions-panel-desc">
585
  <p>
586
  <label>
587
+ <?php _e( 'Hide Notification Bar if visitor arrived from Facebook.', 'wp-notification-bars' ); ?>
588
  </label>
589
  </p>
590
  </div>
606
  */
607
  public function custom_meta_field( $args, $value, $b = false ) {
608
 
609
+ $type = isset( $args['type'] ) ? $args['type'] : '';
610
+ $name = isset( $args['name'] ) ? $args['name'] : '';
611
+ $name = $b ? 'b_'.$name : $name;
612
+ $label = isset( $args['label'] ) ? $args['label'] : '';
613
  $options = isset( $args['options'] ) ? $args['options'] : array();
614
  $default = isset( $args['default'] ) ? $args['default'] : '';
615
+ $min = isset( $args['min'] ) ? $args['min'] : '0';
616
 
617
  $class = isset( $args['class'] ) ? $args['class'] : '';
618
 
620
  $opt_val = isset( $value[ $name ] ) ? $value[ $name ] : $default;
621
 
622
  ?>
623
+ <div id="mtsnb_fields_<?php echo sanitize_html_class( $name );?>_row" class="form-row">
624
+ <label class="form-label" for="mtsnb_fields_<?php echo sanitize_html_class( $name );?>"><?php echo esc_html( $label ); ?></label>
625
+ <div class="form-option <?php echo esc_attr( $class ); ?>">
626
  <?php
627
  switch ( $type ) {
628
 
629
  case 'text':
630
  ?>
631
+ <input type="text" name="mtsnb_fields[<?php echo sanitize_html_class( $name );?>]" id="mtsnb_fields_<?php echo sanitize_html_class( $name );?>" value="<?php echo esc_attr( $opt_val );?>" />
632
  <?php
633
  break;
634
  case 'select':
635
  ?>
636
+ <select name="mtsnb_fields[<?php echo sanitize_html_class( $name );?>]" id="mtsnb_fields_<?php echo sanitize_html_class( $name ); ?>">
637
  <?php foreach ( $options as $val => $label ) { ?>
638
+ <option value="<?php echo esc_attr( $val ); ?>" <?php selected( $opt_val, $val, true); ?>><?php echo esc_html( $label ); ?></option>
639
  <?php } ?>
640
  </select>
641
  <?php
642
  break;
643
  case 'number':
644
  ?>
645
+ <input type="number" step="1" min="<?php echo (int) $min; ?>" name="mtsnb_fields[<?php echo sanitize_html_class( $name ); ?>]" id="mtsnb_fields_<?php echo sanitize_html_class( $name ); ?>" value="<?php echo esc_attr( $opt_val ); ?>" class="small-text"/>
646
  <?php
647
  break;
648
  case 'color':
649
  ?>
650
+ <input type="text" name="mtsnb_fields[<?php echo sanitize_html_class( $name ); ?>]" id="mtsnb_fields_<?php echo sanitize_html_class( $name ); ?>" value="<?php echo esc_attr( $opt_val );?>" class="mtsnb-color-picker" />
651
  <?php
652
  break;
653
  case 'textarea':
654
  ?>
655
+ <textarea name="mtsnb_fields[<?php echo sanitize_html_class( $name ); ?>]" id="mtsnb_fields_<?php echo sanitize_html_class( $name ); ?>" class="mtsnb-textarea"><?php echo esc_textarea( $opt_val ); ?></textarea>
656
  <?php
657
  break;
658
  case 'checkbox':
659
  ?>
660
+ <input type="checkbox" name="mtsnb_fields[<?php echo sanitize_html_class( $name ); ?>]" id="mtsnb_fields_<?php echo sanitize_html_class( $name ); ?>" value="1" <?php checked( $opt_val, '1', true ); ?> />
661
  <?php
662
  break;
663
  case 'info':
664
  ?>
665
  <small class="mtsnb-option-info">
666
+ <?php echo wp_kses_post( $default ); ?>
667
  </small>
668
  <?php
669
  break;
744
  /* Only show the notice 2 days after plugin activation */
745
  if ( ! get_user_meta($user_id, 'wp_notification_bar_ignore_notice') && time() >= (get_option( 'wp_notification_bar_activated', 0 ) + (2 * 24 * 60 * 60)) ) {
746
  echo '<div class="updated notice-info wp-notification-bar-notice" id="wpnotificationbar-notice" style="position:relative;">';
747
+ echo __( '<p>Like WP Notification Bar plugin? You will LOVE <a target="_blank" href="https://mythemeshop.com/plugins/wp-notification-bar/?utm_source=WP+Notification+Bars&utm_medium=Notification+Link&utm_content=WP+Notification+Bar+Pro+LP&utm_campaign=WordPressOrg"><strong>WP Notification Bar Pro!</strong></a></p><a class="notice-dismiss mtsnb-notice-dismiss" data-ignore="0" href="#"></a>', 'wp-notification-bars');
748
  echo "</div>";
749
  }
750
  /* Other notice appears right after activating */
754
  update_option( 'wp_notification_bar_notice_views', ($views + 1) );
755
  echo '<div class="updated notice-info wp-notification-bar-notice" id="wpnotificationbar-notice2" style="position:relative;">';
756
  echo '<p>';
757
+ _e( 'Thank you for trying WP Notification Bar. We hope you will like it.', 'wp-notification-bars');
758
  echo '</p>';
759
  echo '<a class="notice-dismiss mtsnb-notice-dismiss" data-ignore="1" href="#"></a>';
760
  echo "</div>";
782
  public function disabled_notice() {
783
  ?>
784
  <div class="updated">
785
+ <p><?php _e( 'Free version of WP Notification Bars plugin disabled. Pro version is active!', 'wp-notification-bars' ); ?></p>
786
  </div>
787
  <?php
788
  }
806
 
807
  $messages['mts_notification_bar'] = array(
808
  0 => '', // Unused. Messages start at index 1.
809
+ 1 => __( 'Notification Bar updated.', 'wp-notification-bars' ),
810
+ 2 => __( 'Custom field updated.', 'wp-notification-bars' ),
811
+ 3 => __( 'Custom field deleted.', 'wp-notification-bars' ),
812
+ 4 => __( 'Notification Bar updated.', 'wp-notification-bars' ),
813
  5 => isset($_GET['revision']) ? sprintf( __('Notification Bar restored to revision from %s'), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,
814
+ 6 => __( 'Notification Bar published.', 'wp-notification-bars' ),
815
+ 7 => __( 'Notification Bar saved.', 'wp-notification-bars' ),
816
+ 8 => __( 'Notification Bar submitted.', 'wp-notification-bars'),
817
+ 9 => sprintf( __( 'Notification Bar scheduled for: <strong>%1$s</strong>.', 'wp-notification-bars' ), date_i18n( __( 'M j, Y @ H:i' ), strtotime( $post->post_date ) ) ),
818
+ 10 => __( 'Notification Bar draft updated.', 'wp-notification-bars' ),
819
  );
820
  }
821
 
838
 
839
  add_meta_box(
840
  'mtsnb_single_bar_metabox',
841
+ __( 'Notification Bar', 'wp-notification-bars' ),
842
  array( $this, 'mtsnb_select_metabox_content' ),
843
  $screen,
844
  'side',
878
  }
879
  ?>
880
  <p>
881
+ <label for="mtsnb_override_bar_field"><?php _e( 'Select Notification Bar (optional):', 'wp-notification-bars' ); ?></label><br />
882
  <input style="width: 400px;" type="hidden" id="mtsnb_override_bar_field" name="mtsnb_override_bar_field" class="mtsnb-bar-select" value="<?php echo $processed_item_ids; ?>" />
883
  </p>
884
  <p>
885
+ <i><?php _e( 'Selected notification bar will override any other bar.', 'wp-notification-bars' ); ?></i>
886
  </p>
887
  <?php
888
  }
admin/css/select2.min.css CHANGED
File without changes
admin/js/select2.full.min.js CHANGED
File without changes
admin/js/wp-nb-admin-notices.js CHANGED
File without changes
includes/class-wp-notification-bars-shared.php CHANGED
@@ -205,18 +205,18 @@
205
 
206
  $shadow = '-webkit-box-shadow: 0 3px 4px rgba(0, 0, 0, 0.05);box-shadow: 0 3px 4px rgba(0, 0, 0, 0.05);';
207
 
208
- $width = ( isset( $meta_values['content_width'] ) && !empty( $meta_values['content_width'] ) ) ? $meta_values['content_width'] : '960';
209
- $width = (int)$width+120;
210
 
211
  $screen_position_class = 'mtsnb-top';
212
- $css_position_class = isset( $meta_values['css_position'] ) ? ' mtsnb-'.$meta_values['css_position'] : ' mtsnb-fixed';
213
  ?>
214
- <div class="mtsnb mtsnb-shown <?php echo $screen_position_class.$css_position_class; ?>" id="mtsnb-<?php echo $bar_id; ?>" data-mtsnb-id="<?php echo $bar_id; ?>" style="<?php echo $style;?>">
215
  <style type="text/css">
216
- .mtsnb { position: <?php echo $meta_values['css_position'];?>; <?php echo $shadow;?>}
217
- .mtsnb .mtsnb-container { width: <?php echo $width;?>px; font-size: <?php echo $meta_values['font_size'];?>px;}
218
- .mtsnb a { color: <?php echo $meta_values['link_color'];?>;}
219
- .mtsnb .mtsnb-button { background-color: <?php echo $meta_values['link_color'];?>;}
220
  </style>
221
  <div class="mtsnb-container-outer">
222
  <div class="mtsnb-container mtsnb-clearfix">
@@ -226,7 +226,7 @@
226
  </div>
227
  <?php if ( 'no_button' !== $button_type ) { ?>
228
  <?php if ( 'toggle_button' === $button_type ) {?><a href="#" class="mtsnb-show" style="<?php echo $btn_style; ?>"><?php echo $button_open_icon; ?></a><?php } ?>
229
- <a href="#" class="mtsnb-hide" style="<?php echo $style; ?>"><?php echo $button_close_icon; ?></a>
230
  <?php } ?>
231
  </div>
232
  </div>
@@ -241,7 +241,7 @@
241
  public function bar_content( $options ) {
242
 
243
  // Output
244
- echo '<div class="mtsnb-'.$options['content_type'].'-type mtsnb-content">';
245
 
246
  switch ( $options['content_type'] ) {
247
 
@@ -250,7 +250,7 @@
250
  $text = wp_kses_post( $options['basic_text'] );
251
  $link_text = wp_kses_post( $options['basic_link_text'] );
252
  $link_url = esc_url( $options['basic_link_url'] );
253
- $link_style = $options['basic_link_style'];
254
 
255
  echo '<span class="mtsnb-text">'.$text.'</span><a href="'.$link_url.'" class="mtsnb-'.$link_style.'">'.$link_text.'</a>';
256
 
@@ -258,7 +258,11 @@
258
  case 'custom':
259
 
260
  echo '<div class="mtsnb-custom-content">';
 
261
  echo do_shortcode( html_entity_decode( $options['custom_content'] ) );
 
 
 
262
  echo '</div>';
263
 
264
  break;
@@ -312,7 +316,7 @@
312
  // Show for google
313
  if ( !empty( $meta_values['conditions']['google']['state'] ) ) {
314
 
315
- if ( !$referer || empty( $referer ) ) return false; // not set, don't display
316
  $is_search_engine = $this->test_searchengine( $referer );
317
 
318
  if ( $is_search_engine ) {
@@ -326,7 +330,7 @@
326
  // Don't show for google
327
  if ( !empty( $meta_values['conditions']['notgoogle']['state'] ) ) {
328
 
329
- if ( !$referer || empty( $referer ) ) return true; // not set, display
330
  $is_search_engine = $this->test_searchengine( $referer );
331
 
332
  if ( $is_search_engine ) {
@@ -340,7 +344,7 @@
340
  // Show for facebook
341
  if ( !empty( $meta_values['conditions']['facebook']['state'] ) ) {
342
 
343
- if ( !$referer || empty( $referer ) ) return false; // not set, don't display
344
 
345
  if ( false !== strpos( $referer, 'facebook.' ) ) {
346
 
@@ -353,7 +357,7 @@
353
  // Don't show for facebook
354
  if ( !empty( $meta_values['conditions']['notfacebook']['state'] ) ) {
355
 
356
- if ( !$referer || empty( $referer ) ) return true; // not set, display
357
 
358
  if ( false !== strpos( $referer, 'facebook.' ) ) {
359
 
205
 
206
  $shadow = '-webkit-box-shadow: 0 3px 4px rgba(0, 0, 0, 0.05);box-shadow: 0 3px 4px rgba(0, 0, 0, 0.05);';
207
 
208
+ $width = ( isset( $meta_values['content_width'] ) && ! empty( $meta_values['content_width'] ) ) ? $meta_values['content_width'] : '960';
209
+ $width = (int) $width + 120;
210
 
211
  $screen_position_class = 'mtsnb-top';
212
+ $css_position_class = isset( $meta_values['css_position'] ) ? 'mtsnb-' . sanitize_html_class( $meta_values['css_position'] ) : 'mtsnb-fixed';
213
  ?>
214
+ <div class="mtsnb mtsnb-shown <?php echo $screen_position_class . ' ' . $css_position_class; ?>" id="mtsnb-<?php echo absint( $bar_id ); ?>" data-mtsnb-id="<?php echo absint( $bar_id ); ?>" style="<?php echo esc_attr( $style );?>">
215
  <style type="text/css">
216
+ .mtsnb { position: <?php echo sanitize_html_class( $meta_values['css_position'] );?>; <?php echo $shadow; ?>}
217
+ .mtsnb .mtsnb-container { width: <?php echo $width; ?>px; font-size: <?php echo (int) $meta_values['font_size']; ?>px;}
218
+ .mtsnb a { color: <?php echo sanitize_hex_color( $meta_values['link_color'] ); ?>;}
219
+ .mtsnb .mtsnb-button { background-color: <?php echo sanitize_hex_color( $meta_values['link_color'] ); ?>;}
220
  </style>
221
  <div class="mtsnb-container-outer">
222
  <div class="mtsnb-container mtsnb-clearfix">
226
  </div>
227
  <?php if ( 'no_button' !== $button_type ) { ?>
228
  <?php if ( 'toggle_button' === $button_type ) {?><a href="#" class="mtsnb-show" style="<?php echo $btn_style; ?>"><?php echo $button_open_icon; ?></a><?php } ?>
229
+ <a href="#" class="mtsnb-hide" style="<?php echo esc_attr( $style ); ?>"><?php echo $button_close_icon; ?></a>
230
  <?php } ?>
231
  </div>
232
  </div>
241
  public function bar_content( $options ) {
242
 
243
  // Output
244
+ echo '<div class="mtsnb-' . sanitize_html_class( $options['content_type'] ) . '-type mtsnb-content">';
245
 
246
  switch ( $options['content_type'] ) {
247
 
250
  $text = wp_kses_post( $options['basic_text'] );
251
  $link_text = wp_kses_post( $options['basic_link_text'] );
252
  $link_url = esc_url( $options['basic_link_url'] );
253
+ $link_style = sanitize_html_class( $options['basic_link_style'] );
254
 
255
  echo '<span class="mtsnb-text">'.$text.'</span><a href="'.$link_url.'" class="mtsnb-'.$link_style.'">'.$link_text.'</a>';
256
 
258
  case 'custom':
259
 
260
  echo '<div class="mtsnb-custom-content">';
261
+ if ( defined( 'MTSNBF_UNFILTERED_HTML' ) && MTSNBF_UNFILTERED_HTML ) {
262
  echo do_shortcode( html_entity_decode( $options['custom_content'] ) );
263
+ } else {
264
+ echo do_shortcode( wp_kses_post( html_entity_decode( $options['custom_content'] ) ) );
265
+ }
266
  echo '</div>';
267
 
268
  break;
316
  // Show for google
317
  if ( !empty( $meta_values['conditions']['google']['state'] ) ) {
318
 
319
+ if ( empty( $referer ) ) return false; // not set, don't display
320
  $is_search_engine = $this->test_searchengine( $referer );
321
 
322
  if ( $is_search_engine ) {
330
  // Don't show for google
331
  if ( !empty( $meta_values['conditions']['notgoogle']['state'] ) ) {
332
 
333
+ if ( empty( $referer ) ) return true; // not set, display
334
  $is_search_engine = $this->test_searchengine( $referer );
335
 
336
  if ( $is_search_engine ) {
344
  // Show for facebook
345
  if ( !empty( $meta_values['conditions']['facebook']['state'] ) ) {
346
 
347
+ if ( empty( $referer ) ) return false; // not set, don't display
348
 
349
  if ( false !== strpos( $referer, 'facebook.' ) ) {
350
 
357
  // Don't show for facebook
358
  if ( !empty( $meta_values['conditions']['notfacebook']['state'] ) ) {
359
 
360
+ if ( empty( $referer ) ) return true; // not set, display
361
 
362
  if ( false !== strpos( $referer, 'facebook.' ) ) {
363
 
includes/class-wp-notification-bars.php CHANGED
@@ -69,7 +69,7 @@ class MTSNBF {
69
  public function __construct() {
70
 
71
  $this->plugin_name = 'wp-notification-bars';
72
- $this->version = '1.0.5';
73
 
74
  $this->load_dependencies();
75
  $this->set_locale();
69
  public function __construct() {
70
 
71
  $this->plugin_name = 'wp-notification-bars';
72
+ $this->version = '1.0.6';
73
 
74
  $this->load_dependencies();
75
  $this->set_locale();
languages/wp-notification-bars.mo CHANGED
File without changes
readme.txt CHANGED
@@ -4,7 +4,7 @@ Creator's website link: http://mythemeshop.com/plugins/wp-notification-bars/
4
  Tags: notification, alert, notification bar, welcome google visitor, welcome facebook visitor, attention bar, floating bar, message, notice, sticky header, offer bar, hello bar
5
  Requires at least: 3.0.1
6
  Tested up to: 4.9.8
7
- Stable tag: 1.0.5
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -74,6 +74,10 @@ Please disable all plugins and check if backup is working properly. Then you can
74
 
75
  == Changelog ==
76
 
 
 
 
 
77
  = 1.0.5 =
78
  * Fixed styling issue of number input field
79
 
4
  Tags: notification, alert, notification bar, welcome google visitor, welcome facebook visitor, attention bar, floating bar, message, notice, sticky header, offer bar, hello bar
5
  Requires at least: 3.0.1
6
  Tested up to: 4.9.8
7
+ Stable tag: 1.0.6
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
74
 
75
  == Changelog ==
76
 
77
+ = 1.0.6 =
78
+ * Fixed security issues and hardened overall plugin security
79
+ * Fixed plugin locale in gettext calls
80
+
81
  = 1.0.5 =
82
  * Fixed styling issue of number input field
83
 
wp-notification-bars.php CHANGED
@@ -4,7 +4,7 @@
4
  * Plugin Name: WP Notification Bars
5
  * Plugin URI: https://mythemeshop.com/plugins/wp-notification-bars/
6
  * Description: WP Notification Bars is a custom notification and alert bar plugin for WordPress which is perfect for marketing promotions, alerts, increasing click throughs to other pages and so much more.
7
- * Version: 1.0.5
8
  * Author: MyThemeShop
9
  * Author URI: https://mythemeshop.com/
10
  * Text Domain: wp-notification-bars
4
  * Plugin Name: WP Notification Bars
5
  * Plugin URI: https://mythemeshop.com/plugins/wp-notification-bars/
6
  * Description: WP Notification Bars is a custom notification and alert bar plugin for WordPress which is perfect for marketing promotions, alerts, increasing click throughs to other pages and so much more.
7
+ * Version: 1.0.6
8
  * Author: MyThemeShop
9
  * Author URI: https://mythemeshop.com/
10
  * Text Domain: wp-notification-bars