Breadcrumb NavXT - Version 6.0.1

Version Description

Release date: December, 28th 2017

  • Behavior change: Removed unused Blog Template and Blog Template (Unlinked) from settings page.
  • Bug fix: Fixed issue where changes to the hierarchy type for any post type would not save.
  • Bug fix: Fixed issue where the blog display setting was ignored.
Download this release

Release Info

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

Code changes from version 6.0.0 to 6.0.1

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: 6.0.0
7
  Author: John Havlik
8
  Author URI: http://mtekk.us/
9
  License: GPL2
@@ -61,7 +61,7 @@ $breadcrumb_navxt = null;
61
  //TODO change to extends mtekk_plugKit
62
  class breadcrumb_navxt
63
  {
64
- const version = '6.0.0';
65
  protected $name = 'Breadcrumb NavXT';
66
  protected $identifier = 'breadcrumb-navxt';
67
  protected $unique_prefix = 'bcn';
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: 6.0.1
7
  Author: John Havlik
8
  Author URI: http://mtekk.us/
9
  License: GPL2
61
  //TODO change to extends mtekk_plugKit
62
  class breadcrumb_navxt
63
  {
64
+ const version = '6.0.1';
65
  protected $name = 'Breadcrumb NavXT';
66
  protected $identifier = 'breadcrumb-navxt';
67
  protected $unique_prefix = 'bcn';
class.bcn_admin.php CHANGED
@@ -43,7 +43,7 @@ if(!class_exists('mtekk_adminKit'))
43
  */
44
  class bcn_admin extends mtekk_adminKit
45
  {
46
- const version = '6.0.0';
47
  protected $full_name = 'Breadcrumb NavXT Settings';
48
  protected $short_name = 'Breadcrumb NavXT';
49
  protected $access_level = 'manage_options';
@@ -510,8 +510,6 @@ class bcn_admin extends mtekk_adminKit
510
  <table class="form-table adminkit-enset-top">
511
  <?php
512
  $this->input_check(__('Blog Breadcrumb', 'breadcrumb-navxt'), 'bblog_display', __('Place the blog breadcrumb in the trail.', 'breadcrumb-navxt'), $this->maybe_disable_blog_options(), '', 'adminkit-enset-ctrl adminkit-enset');
513
- $this->textbox(__('Blog Template', 'breadcrumb-navxt'), 'Hblog_template', '6', $this->maybe_disable_blog_options(), __('The template for the blog breadcrumb, used only in static front page environments.', 'breadcrumb-navxt'), 'adminkit-enset');
514
- $this->textbox(__('Blog Template (Unlinked)', 'breadcrumb-navxt'), 'Hblog_template_no_anchor', '4', $this->maybe_disable_blog_options(), __('The template for the blog breadcrumb, used only in static front page environments and when the breadcrumb is not linked.', 'breadcrumb-navxt'), 'adminkit-enset');
515
  do_action($this->unique_prefix . '_settings_blog', $this->opt);
516
  ?>
517
  </table>
43
  */
44
  class bcn_admin extends mtekk_adminKit
45
  {
46
+ const version = '6.0.1';
47
  protected $full_name = 'Breadcrumb NavXT Settings';
48
  protected $short_name = 'Breadcrumb NavXT';
49
  protected $access_level = 'manage_options';
510
  <table class="form-table adminkit-enset-top">
511
  <?php
512
  $this->input_check(__('Blog Breadcrumb', 'breadcrumb-navxt'), 'bblog_display', __('Place the blog breadcrumb in the trail.', 'breadcrumb-navxt'), $this->maybe_disable_blog_options(), '', 'adminkit-enset-ctrl adminkit-enset');
 
 
513
  do_action($this->unique_prefix . '_settings_blog', $this->opt);
514
  ?>
515
  </table>
class.bcn_breadcrumb.php CHANGED
@@ -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 = '6.0.0';
25
  //The main text that will be shown
26
  protected $title;
27
  //The breadcrumb's template, used durring assembly
@@ -118,9 +118,10 @@ class bcn_breadcrumb
118
  */
119
  public function set_url($url)
120
  {
 
121
  $this->url = apply_filters('bcn_breadcrumb_url', $url, $this->type, $this->id);
122
  //If the URL seemed nullish, we are not linked
123
- if($this->url == null)
124
  {
125
  $this->linked = false;
126
  }
21
  class bcn_breadcrumb
22
  {
23
  //Our member variables
24
+ const version = '6.0.1';
25
  //The main text that will be shown
26
  protected $title;
27
  //The breadcrumb's template, used durring assembly
118
  */
119
  public function set_url($url)
120
  {
121
+ $url = trim($url);
122
  $this->url = apply_filters('bcn_breadcrumb_url', $url, $this->type, $this->id);
123
  //If the URL seemed nullish, we are not linked
124
+ if($this->url === '')
125
  {
126
  $this->linked = false;
127
  }
class.bcn_breadcrumb_trail.php CHANGED
@@ -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 = '6.0.0';
25
  //An array of breadcrumbs
26
  public $breadcrumbs = array();
27
  public $trail = array();
@@ -52,10 +52,6 @@ class bcn_breadcrumb_trail
52
  'Hhome_template_no_anchor' => bcn_breadcrumb::default_template_no_anchor,
53
  //Should the blog page be shown globally
54
  'bblog_display' => true,
55
- //The breadcrumb template for the blog page only in static front page mode
56
- 'Hblog_template' => bcn_breadcrumb::get_default_template(),
57
- //The breadcrumb template for the blog page only in static front page mode, used when an anchor is not needed
58
- 'Hblog_template_no_anchor' => bcn_breadcrumb::default_template_no_anchor,
59
  //Separator that is placed between each item in the breadcrumb trial, but not placed before
60
  //the first and not after the last breadcrumb
61
  'hseparator' => ' &gt; ',
@@ -966,6 +962,14 @@ class bcn_breadcrumb_trail
966
  //Exit early since we have breadcrumbs in the trail
967
  return null;
968
  }
 
 
 
 
 
 
 
 
969
  //Do any actions if necessary, we past through the current object instance to keep life simple
970
  do_action('bcn_before_fill', $this);
971
  $type = $wp_query->get_queried_object();
@@ -1062,10 +1066,7 @@ class bcn_breadcrumb_trail
1062
  {
1063
  $this->type_archive($type);
1064
  }
1065
- if($type_str !== 'post')
1066
- {
1067
- $this->do_root($type_str, $this->opt['apost_' . $type_str . '_root'], is_paged(), $this->treat_as_root_page($type_str));
1068
- }
1069
  }
1070
  //For 404 pages
1071
  else if(is_404())
21
  class bcn_breadcrumb_trail
22
  {
23
  //Our member variables
24
+ const version = '6.0.1';
25
  //An array of breadcrumbs
26
  public $breadcrumbs = array();
27
  public $trail = array();
52
  'Hhome_template_no_anchor' => bcn_breadcrumb::default_template_no_anchor,
53
  //Should the blog page be shown globally
54
  'bblog_display' => true,
 
 
 
 
55
  //Separator that is placed between each item in the breadcrumb trial, but not placed before
56
  //the first and not after the last breadcrumb
57
  'hseparator' => ' &gt; ',
962
  //Exit early since we have breadcrumbs in the trail
963
  return null;
964
  }
965
+ if($this->opt['bblog_display'])
966
+ {
967
+ $this->opt['apost_post_root'] = get_option('page_for_posts');
968
+ }
969
+ else
970
+ {
971
+ $this->opt['apost_post_root'] = false;
972
+ }
973
  //Do any actions if necessary, we past through the current object instance to keep life simple
974
  do_action('bcn_before_fill', $this);
975
  $type = $wp_query->get_queried_object();
1066
  {
1067
  $this->type_archive($type);
1068
  }
1069
+ $this->do_root($type_str, $this->opt['apost_' . $type_str . '_root'], is_paged(), $this->treat_as_root_page($type_str));
 
 
 
1070
  }
1071
  //For 404 pages
1072
  else if(is_404())
class.bcn_network_admin.php CHANGED
@@ -28,7 +28,7 @@ if(!class_exists('bcn_admin'))
28
  */
29
  class bcn_network_admin extends bcn_admin
30
  {
31
- const version = '6.0.0';
32
  protected $full_name = 'Breadcrumb NavXT Network Settings';
33
  protected $access_level = 'manage_network_options';
34
  /**
28
  */
29
  class bcn_network_admin extends bcn_admin
30
  {
31
+ const version = '6.0.1';
32
  protected $full_name = 'Breadcrumb NavXT Network Settings';
33
  protected $access_level = 'manage_network_options';
34
  /**
class.bcn_widget.php CHANGED
@@ -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 = '6.0.0';
23
  protected $allowed_html = array();
24
  protected $defaults = array('title' => '', 'pretext' => '', 'type' => 'microdata', 'linked' => true, 'reverse' => false, 'front' => false, 'force' => false);
25
  //Default constructor
19
  require_once(dirname(__FILE__) . '/includes/block_direct_access.php');
20
  class bcn_widget extends WP_Widget
21
  {
22
+ const version = '6.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
includes/class.mtekk_adminkit.php CHANGED
@@ -24,7 +24,7 @@ if(!class_exists('mtekk_adminKit_message'))
24
  }
25
  abstract class mtekk_adminKit
26
  {
27
- const version = '2.0.0';
28
  protected $full_name;
29
  protected $short_name;
30
  protected $plugin_basename;
@@ -1086,7 +1086,7 @@ abstract class mtekk_adminKit
1086
  $class .= ' disabled';
1087
  }?>
1088
  <label>
1089
- <?php printf('<input type="radio" name="%1$s" id="%2$s" value="%3$s" class="%4$s" %5$s %6$s/>', esc_attr($opt_name), esc_attr($opt_id), esc_attr($this->opt[$option]), esc_attr($class), disabled($disable, true, false), checked($value, $this->opt[$option], false));?>
1090
  <?php echo $instruction; ?>
1091
  </label><br/>
1092
  <?php
24
  }
25
  abstract class mtekk_adminKit
26
  {
27
+ const version = '2.0.1';
28
  protected $full_name;
29
  protected $short_name;
30
  protected $plugin_basename;
1086
  $class .= ' disabled';
1087
  }?>
1088
  <label>
1089
+ <?php printf('<input type="radio" name="%1$s" id="%2$s" value="%3$s" class="%4$s" %5$s %6$s/>', esc_attr($opt_name), esc_attr($opt_id), esc_attr($value), esc_attr($class), disabled($disable, true, false), checked($value, $this->opt[$option], false));?>
1090
  <?php echo $instruction; ?>
1091
  </label><br/>
1092
  <?php
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=FD5XE
4
  Tags: breadcrumb, breadcrumbs, trail, navigation, menu, widget
5
  Requires at least: 4.7
6
  Tested up to: 4.9
7
- Stable tag: 6.0.0
8
  Requires PHP: 5.3
9
  License: GPLv2 or later
10
  Adds breadcrumb navigation showing the visitor's path to their current location.
@@ -52,6 +52,13 @@ Please visit [Breadcrumb NavXT's Documentation](http://mtekk.us/code/breadcrumb-
52
 
53
  == Changelog ==
54
 
 
 
 
 
 
 
 
55
  = 6.0.0 =
56
  Release date: December, 26th 2017
57
 
@@ -237,12 +244,8 @@ Release date: November 20th, 2013
237
  * Bug fix: The current_item breadcrumb for search results should result in a valid HTTPS link when appropriate.
238
 
239
  == Upgrade Notice ==
 
 
240
 
241
  = 5.6.0 =
242
- This version requires PHP5.3 or newer. This version introduces a new 4th optional parameter to `bcn_display()` and `bcn_display_list()` that bypasses the internal caching mechanism.
243
-
244
- = 5.5.0 =
245
- This version requires PHP5.3 or newer. This version introduces contextually aware taxonomy selection for post hierarchies.
246
-
247
- = 5.4.0 =
248
- This version requires PHP5.3 or newer. This version introduces three new filters: `bcn_post_terms`, `bcn_add_post_type_arg`, and `bcn_pick_post_term`.
4
  Tags: breadcrumb, breadcrumbs, trail, navigation, menu, widget
5
  Requires at least: 4.7
6
  Tested up to: 4.9
7
+ Stable tag: 6.0.1
8
  Requires PHP: 5.3
9
  License: GPLv2 or later
10
  Adds breadcrumb navigation showing the visitor's path to their current location.
52
 
53
  == Changelog ==
54
 
55
+ = 6.0.1 =
56
+ Release date: December, 28th 2017
57
+
58
+ * Behavior change: Removed unused Blog Template and Blog Template (Unlinked) from settings page.
59
+ * Bug fix: Fixed issue where changes to the hierarchy type for any post type would not save.
60
+ * Bug fix: Fixed issue where the blog display setting was ignored.
61
+
62
  = 6.0.0 =
63
  Release date: December, 26th 2017
64
 
244
  * Bug fix: The current_item breadcrumb for search results should result in a valid HTTPS link when appropriate.
245
 
246
  == Upgrade Notice ==
247
+ = 6.0.0 =
248
+ This version requires PHP5.3 or newer. This version introduces three new filters and deprecates a filter.
249
 
250
  = 5.6.0 =
251
+ This version requires PHP5.3 or newer. This version introduces a new 4th optional parameter to `bcn_display()` and `bcn_display_list()` that bypasses the internal caching mechanism.