Breadcrumb NavXT - Version 7.0.2

Version Description

Release date: January, 4th 2022

  • Behavior change: Allow value of Hhome_template, Hhome_template_unlinked, hseparator, and hseparator_higher_dim to be overridden via bcn_settings_init.
  • Bug fix: Fixed cause of Sorry, you are not allowed to access this page. message when attempting to visit the settings page.
Download this release

Release Info

Developer mtekk
Plugin Icon 128x128 Breadcrumb NavXT
Version 7.0.2
Comparing to
See all releases

Code changes from version 7.0.1 to 7.0.2

breadcrumb-navxt.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Breadcrumb NavXT
4
  Plugin URI: http://mtekk.us/code/breadcrumb-navxt/
5
  Description: Adds a breadcrumb navigation showing the visitor&#39;s path to their current location. For details on how to use this plugin visit <a href="http://mtekk.us/code/breadcrumb-navxt/">Breadcrumb NavXT</a>.
6
- Version: 7.0.1
7
  Author: John Havlik
8
  Author URI: http://mtekk.us/
9
  License: GPL2
@@ -11,7 +11,7 @@ Text Domain: breadcrumb-navxt
11
  Domain Path: /languages
12
  */
13
  /*
14
- Copyright 2007-2021 John Havlik (email : john.havlik@mtekk.us)
15
 
16
  This program is free software; you can redistribute it and/or modify
17
  it under the terms of the GNU General Public License as published by
@@ -63,7 +63,7 @@ $breadcrumb_navxt = null;
63
  //TODO change to extends \mtekk\plugKit
64
  class breadcrumb_navxt
65
  {
66
- const version = '7.0.1';
67
  protected $name = 'Breadcrumb NavXT';
68
  protected $identifier = 'breadcrumb-navxt';
69
  protected $unique_prefix = 'bcn';
@@ -333,7 +333,7 @@ class breadcrumb_navxt
333
  static function setup_setting_defaults(array &$settings)
334
  {
335
  //Hook for letting other plugins add in their default settings (has to go first to prevent other from overriding base settings)
336
- $settings= apply_filters('bcn_settings_init', $settings);
337
  //Now on to our settings
338
  $settings['bmainsite_display'] = new setting\setting_bool(
339
  'mainsite_display',
@@ -353,11 +353,11 @@ class breadcrumb_navxt
353
  __('Home Breadcrumb', 'breadcrumb-navxt'));
354
  $settings['Hhome_template'] = new setting\setting_html(
355
  'home_template',
356
- bcn_breadcrumb::get_default_template(),
357
  __('Home Template', 'breadcrumb-navxt'));
358
  $settings['Hhome_template_no_anchor'] = new setting\setting_html(
359
  'home_template_no_anchor',
360
- bcn_breadcrumb::default_template_no_anchor,
361
  __('Home Template (Unlinked)', 'breadcrumb-navxt'));
362
  $settings['bblog_display'] = new setting\setting_bool(
363
  'blog_display',
@@ -365,12 +365,12 @@ class breadcrumb_navxt
365
  __('Blog Breadcrumb', 'breadcrumb-navxt'));
366
  $settings['hseparator'] = new setting\setting_html(
367
  'separator',
368
- ' &gt; ',
369
  __('Breadcrumb Separator', 'breadcrumb-navxt'),
370
  true);
371
  $settings['hseparator_higher_dim'] = new setting\setting_html(
372
  'separator_higher_dim',
373
- ', ',
374
  __('Breadcrumb Separator (Higher Dimension)', 'breadcrumb-navxt'),
375
  true);
376
  $settings['bcurrent_item_linked'] = new setting\setting_bool(
3
  Plugin Name: Breadcrumb NavXT
4
  Plugin URI: http://mtekk.us/code/breadcrumb-navxt/
5
  Description: Adds a breadcrumb navigation showing the visitor&#39;s path to their current location. For details on how to use this plugin visit <a href="http://mtekk.us/code/breadcrumb-navxt/">Breadcrumb NavXT</a>.
6
+ Version: 7.0.2
7
  Author: John Havlik
8
  Author URI: http://mtekk.us/
9
  License: GPL2
11
  Domain Path: /languages
12
  */
13
  /*
14
+ Copyright 2007-2022 John Havlik (email : john.havlik@mtekk.us)
15
 
16
  This program is free software; you can redistribute it and/or modify
17
  it under the terms of the GNU General Public License as published by
63
  //TODO change to extends \mtekk\plugKit
64
  class breadcrumb_navxt
65
  {
66
+ const version = '7.0.2';
67
  protected $name = 'Breadcrumb NavXT';
68
  protected $identifier = 'breadcrumb-navxt';
69
  protected $unique_prefix = 'bcn';
333
  static function setup_setting_defaults(array &$settings)
334
  {
335
  //Hook for letting other plugins add in their default settings (has to go first to prevent other from overriding base settings)
336
+ $settings = apply_filters('bcn_settings_init', $settings);
337
  //Now on to our settings
338
  $settings['bmainsite_display'] = new setting\setting_bool(
339
  'mainsite_display',
353
  __('Home Breadcrumb', 'breadcrumb-navxt'));
354
  $settings['Hhome_template'] = new setting\setting_html(
355
  'home_template',
356
+ (isset($settings['Hhome_template']) && is_string($settings['Hhome_template'])) ? $settings['Hhome_template'] : bcn_breadcrumb::get_default_template(),
357
  __('Home Template', 'breadcrumb-navxt'));
358
  $settings['Hhome_template_no_anchor'] = new setting\setting_html(
359
  'home_template_no_anchor',
360
+ (isset($settings['Hhome_template_no_anchor']) && is_string($settings['Hhome_template_no_anchor'])) ? $settings['Hhome_template_no_anchor'] : bcn_breadcrumb::default_template_no_anchor,
361
  __('Home Template (Unlinked)', 'breadcrumb-navxt'));
362
  $settings['bblog_display'] = new setting\setting_bool(
363
  'blog_display',
365
  __('Blog Breadcrumb', 'breadcrumb-navxt'));
366
  $settings['hseparator'] = new setting\setting_html(
367
  'separator',
368
+ (isset($settings['hseparator']) && is_string($settings['hseparator'])) ? $settings['hseparator'] : ' &gt; ',
369
  __('Breadcrumb Separator', 'breadcrumb-navxt'),
370
  true);
371
  $settings['hseparator_higher_dim'] = new setting\setting_html(
372
  'separator_higher_dim',
373
+ (isset($settings['hseparator_higher_dim']) && is_string($settings['hseparator_higher_dim'])) ? $settings['hseparator_higher_dim'] : ', ',
374
  __('Breadcrumb Separator (Higher Dimension)', 'breadcrumb-navxt'),
375
  true);
376
  $settings['bcurrent_item_linked'] = new setting\setting_bool(
class.bcn_admin.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /*
3
- Copyright 2015-2021 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
@@ -44,7 +44,7 @@ use mtekk\adminKit\{adminKit, form, message, setting};
44
  */
45
  class bcn_admin extends adminKit
46
  {
47
- const version = '7.0.1';
48
  protected $full_name = 'Breadcrumb NavXT Settings';
49
  protected $short_name = 'Breadcrumb NavXT';
50
  protected $access_level = 'bcn_manage_options';
1
  <?php
2
  /*
3
+ Copyright 2015-2022 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
44
  */
45
  class bcn_admin extends adminKit
46
  {
47
+ const version = '7.0.2';
48
  protected $full_name = 'Breadcrumb NavXT Settings';
49
  protected $short_name = 'Breadcrumb NavXT';
50
  protected $access_level = 'bcn_manage_options';
class.bcn_breadcrumb.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /*
3
- Copyright 2007-2021 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
@@ -21,7 +21,7 @@ require_once(dirname(__FILE__) . '/includes/block_direct_access.php');
21
  class bcn_breadcrumb
22
  {
23
  //Our member variables
24
- const version = '7.0.1';
25
  //The main text that will be shown
26
  protected $title;
27
  //The breadcrumb's template, used durring assembly
1
  <?php
2
  /*
3
+ Copyright 2007-2022 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
21
  class bcn_breadcrumb
22
  {
23
  //Our member variables
24
+ const version = '7.0.2';
25
  //The main text that will be shown
26
  protected $title;
27
  //The breadcrumb's template, used durring assembly
class.bcn_breadcrumb_trail.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /*
3
- Copyright 2015-2021 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
@@ -21,7 +21,7 @@ require_once(dirname(__FILE__) . '/includes/block_direct_access.php');
21
  class bcn_breadcrumb_trail
22
  {
23
  //Our member variables
24
- const version = '7.0.1';
25
  //An array of breadcrumbs
26
  public $breadcrumbs = array();
27
  public $trail = array();
1
  <?php
2
  /*
3
+ Copyright 2015-2022 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
21
  class bcn_breadcrumb_trail
22
  {
23
  //Our member variables
24
+ const version = '7.0.2';
25
  //An array of breadcrumbs
26
  public $breadcrumbs = array();
27
  public $trail = array();
class.bcn_network_admin.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /*
3
- Copyright 2015-2021 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
@@ -29,7 +29,7 @@ use mtekk\adminKit\{adminKit, form, message, setting};
29
  */
30
  class bcn_network_admin extends bcn_admin
31
  {
32
- const version = '7.0.1';
33
  protected $full_name = 'Breadcrumb NavXT Network Settings';
34
  protected $access_level = 'manage_network_options';
35
  /**
1
  <?php
2
  /*
3
+ Copyright 2015-2022 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
29
  */
30
  class bcn_network_admin extends bcn_admin
31
  {
32
+ const version = '7.0.2';
33
  protected $full_name = 'Breadcrumb NavXT Network Settings';
34
  protected $access_level = 'manage_network_options';
35
  /**
class.bcn_rest_controller.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /*
3
- Copyright 2015-2021 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
1
  <?php
2
  /*
3
+ Copyright 2015-2022 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
class.bcn_widget.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /*
3
- Copyright 2015-2021 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
@@ -19,7 +19,7 @@
19
  require_once(dirname(__FILE__) . '/includes/block_direct_access.php');
20
  class bcn_widget extends WP_Widget
21
  {
22
- const version = '7.0.1';
23
  protected $allowed_html = array();
24
  protected $defaults = array('title' => '', 'pretext' => '', 'type' => 'microdata', 'linked' => true, 'reverse' => false, 'front' => false, 'force' => false);
25
  //Default constructor
1
  <?php
2
  /*
3
+ Copyright 2015-2022 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
19
  require_once(dirname(__FILE__) . '/includes/block_direct_access.php');
20
  class bcn_widget extends WP_Widget
21
  {
22
+ const version = '7.0.2';
23
  protected $allowed_html = array();
24
  protected $defaults = array('title' => '', 'pretext' => '', 'type' => 'microdata', 'linked' => true, 'reverse' => false, 'front' => false, 'force' => false);
25
  //Default constructor
includes/adminKit/class-mtekk_adminkit.php CHANGED
@@ -67,7 +67,7 @@ if(!class_exists('form'))
67
  }
68
  abstract class adminKit
69
  {
70
- const version = '2.9.50';
71
  protected $full_name;
72
  protected $short_name;
73
  protected $plugin_basename;
@@ -116,7 +116,7 @@ abstract class adminKit
116
  function add_cap()
117
  {
118
  $role = get_role('administrator');
119
- if($role instanceof WP_Role && !$role->has_cap($this->access_level))
120
  {
121
  $role->add_cap($this->access_level);
122
  }
67
  }
68
  abstract class adminKit
69
  {
70
+ const version = '3.0.2';
71
  protected $full_name;
72
  protected $short_name;
73
  protected $plugin_basename;
116
  function add_cap()
117
  {
118
  $role = get_role('administrator');
119
+ if($role instanceof \WP_Role && !$role->has_cap($this->access_level))
120
  {
121
  $role->add_cap($this->access_level);
122
  }
options_upgrade.php CHANGED
@@ -1,6 +1,6 @@
1
  <?php
2
  /*
3
- Copyright 2015-2021 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
1
  <?php
2
  /*
3
+ Copyright 2015-2022 John Havlik (email : john.havlik@mtekk.us)
4
 
5
  This program is free software; you can redistribute it and/or modify
6
  it under the terms of the GNU General Public License as published by
readme.txt CHANGED
@@ -3,8 +3,8 @@ Contributors: mtekk, hakre
3
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=FD5XEU783BR8U&lc=US&item_name=Breadcrumb%20NavXT%20Donation&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted
4
  Tags: breadcrumb, breadcrumbs, trail, navigation, menu, widget
5
  Requires at least: 4.9
6
- Tested up to: 5.8
7
- Stable tag: 7.0.1
8
  Requires PHP: 7.0
9
  License: GPLv2 or later
10
  Adds breadcrumb navigation showing the visitor's path to their current location.
@@ -50,6 +50,12 @@ Please visit [Breadcrumb NavXT's Documentation](http://mtekk.us/code/breadcrumb-
50
 
51
  == Changelog ==
52
 
 
 
 
 
 
 
53
  = 7.0.1 =
54
  Release date: December, 27th 2021
55
 
3
  Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=FD5XEU783BR8U&lc=US&item_name=Breadcrumb%20NavXT%20Donation&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted
4
  Tags: breadcrumb, breadcrumbs, trail, navigation, menu, widget
5
  Requires at least: 4.9
6
+ Tested up to: 6.0
7
+ Stable tag: 7.0.2
8
  Requires PHP: 7.0
9
  License: GPLv2 or later
10
  Adds breadcrumb navigation showing the visitor's path to their current location.
50
 
51
  == Changelog ==
52
 
53
+ = 7.0.2 =
54
+ Release date: January, 4th 2022
55
+
56
+ * Behavior change: Allow value of `Hhome_template`, `Hhome_template_unlinked`, `hseparator`, and `hseparator_higher_dim` to be overridden via `bcn_settings_init`.
57
+ * Bug fix: Fixed cause of “Sorry, you are not allowed to access this page.” message when attempting to visit the settings page.
58
+
59
  = 7.0.1 =
60
  Release date: December, 27th 2021
61
 
uninstall.php CHANGED
@@ -22,7 +22,7 @@
22
  * @author Tom Klingenberg
23
  */
24
  /*
25
- Copyright 2010-2021 John Havlik (email : john.havlik@mtekk.us)
26
 
27
  This program is free software; you can redistribute it and/or modify
28
  it under the terms of the GNU General Public License as published by
22
  * @author Tom Klingenberg
23
  */
24
  /*
25
+ Copyright 2010-2022 John Havlik (email : john.havlik@mtekk.us)
26
 
27
  This program is free software; you can redistribute it and/or modify
28
  it under the terms of the GNU General Public License as published by