John Havlik
Forum Replies Created
-
Forum: Plugins
In reply to: [Breadcrumb NavXT] Disable on home page.You probably want to look at the last example in this article: https://mtekk.us/archives/guides/calling-the-breadcrumb-trail/ Just replace the checks for
!is_page()with a single!is_front_page().Forum: Plugins
In reply to: [Breadcrumb NavXT] Filter bcn_settings_init problemThe
bcn_settings_initfilter is intended for providing good/safe default values for settings in the plugin. This can be for existing settings, or for extension plugins to Breadcrumb NavXT that have options (the primary user of this filter). If you want to dynamically change a setting, you’re better off using thebcn_before_fillaction and modifying the specific option when appropriate (e.g. when on a page for that CPT).Forum: Plugins
In reply to: [Breadcrumb NavXT] breadcrumbs trail from page to category to postIt sounds like you want to use pages instead of the category/term archives that WordPress normally generates. The best way to do this is to map a page to your category (use a term meta field) and then replace the URL appropriately everywhere in your site using the appropriate filter (look for something in
get_term_link), or just target the URLs in the breadcrumb trail by using thebcn_breadcrumb_urlfilter (https://mtekk.us/archives/guides/link-to-a-page-rather-than-the-category-archive-in-a-breadcrumb/ is a quick primer on how to this filter).Forum: Plugins
In reply to: [Breadcrumb NavXT] Truncating the current “crumb”To truncate the length of the breadcrumbs, use CSS as discussed in this article: https://mtekk.us/archives/guides/trimming-breadcrumb-title-lengths-with-css/ You can modify that to only apply to the current item.
To remove the current item alltogether, you can use the following micro plugin: https://github.com/mtekk/Breadcrumb-NavXT-Extensions/blob/master/breadcrumb_navxt_remove_curitm.php
Forum: Plugins
In reply to: [Breadcrumb NavXT] Pluggin broken since 5.2@motionous Thanks for taking the time to report back your findings!
@willowleaf Thanks for reporting that the findings by @motionous applied to your situation as well.
Forum: Plugins
In reply to: [Breadcrumb NavXT] Pluggin broken since 5.2If there are details you can share in this thread, I’d prefer that. However, if there are details that can’t be shared in this thread, you can send me an email (via the email address in the plugin source code).
Forum: Plugins
In reply to: [Breadcrumb NavXT] Pluggin broken since 5.2@pqinstitute: Do you have more information regarding the page you visited that exhibited this issue? I’m not seeing this issue on my testbed and would like more information to hopefully reproduce it locally.
Forum: Plugins
In reply to: [Breadcrumb NavXT] Inserts phantom category with bad linkOne thing you can do is, in the Breadcrumb NavXT settings page, make sure that the checkbox next to “Place the blog breadcrumb in the trail.” is unchecked. If the option is disabled (can’t toggle the checkbox), then what is probably going on is you have a page set for the “front page” but do not have a “page for posts” set, which isn’t really a valid WordPress configuration (solution is to set a page for the “page for posts”, even if it is just a dummy that is hidden elsewhere, and then you can toggle the checkbox as you see fit).
Forum: Plugins
In reply to: [Breadcrumb NavXT] Root page for PostI forgot that you may need to set
$trail->opts['bblog_display'] = true;as well. This is probably best added to the example code I provided. There is an equivalent option in the settings page, but it may be disabled if a static frontpage and a page for posts are not set.Forum: Plugins
In reply to: [Breadcrumb NavXT] Root page for PostIf you must use a different page for the post root, you can do the following:
Write a hook into the
bcn_before_fillaction. In the passed in instance ofbcn_breadcrumb_trailsetopts['apost_post_root']to the ID of the page you want to use for the post root page. The following should get you started:add_action('bcn_before_fill', 'my_before_fill'); function my_before_fill($trail) { $trail->opts['apost_post_root'] = POST_ROOT_PAGE_ID; }Replace POST_ROOT_PAGE_ID with the ID of the page you want to use for your root page for posts.
Forum: Plugins
In reply to: [Breadcrumb NavXT] Pluggin broken since 5.2Just following up on this. After looking into this more, I am nearly certain it is not a Breadcrumb NavXT or WordPress 5.2 issue.
The first parameter for the
plugin_action_linksfilter has to be an array. If it is not, the plugins page is going to look goofy (the action links will be missing). You either have another plugin/other code that is behaving poorly, or a corrupt WordPress install. I strongly suggest disabling all plugins other than Breadcrumb NavXT to see if the problem persists (then re-enable the other plugins, one-by-one until the problem returns to identify the offending plugin).As an FYI, someone else reported this earlier in March (before WP 5.2 was released) see https://github.com/mtekk/Breadcrumb-NavXT/issues/218 Hence, I’m fairly confident this is not a WordPress 5.2 related issue.
Forum: Plugins
In reply to: [Breadcrumb NavXT] Remove the custom post type title on taxonomy detailpageCurrently, the way Breadcrumb NavXT is designed, it assumes that taxonomies are primarily associated with a single post type and will use that post type’s archive and root page (if enabled/set). There, unfortunately, is not an easy way to do this currently. For reference, I have opened up a GitHub issue to track this: https://github.com/mtekk/Breadcrumb-NavXT/issues/223
Forum: Plugins
In reply to: [Breadcrumb NavXT] Remove the custom post type title on taxonomy detailpageIn the Breadcrumb NavXT settings page, under the “Post Types” tab, look for the “Archive Display” setting for the post type in question. Make sure the checkbox for this setting is unchecked, then press the “Save Changes” button. This should prevent Breadcrumb NavXT from placing the CPT archive breadcrumb in the breadcrumb trail for that post type.
Forum: Plugins
In reply to: [Breadcrumb NavXT] Pluggin broken since 5.2You’re going to have to do a little debugging (e.g. try disabling all other plugins and then try re-activating Breadcrumb NavXT). This does not appear to be an issue with Breadcrumb NavXT itself but rather something other code is doing to it.
Forum: Plugins
In reply to: [Breadcrumb NavXT] Root page for PostThe root page for the WordPress post type “Post” is set in the WordPress settings. This is found under Settings > Reading, there is an option “Your homepage displays”, set that to “A static page (select below)” and select the desired “Posts page”. The root page concept for CPTs is simply an extension of this “Posts page” idea to custom post types.