Archived topic
How to disbale breadcumb in specific page/post
3 replies · Started by Huy on May 6, 2018
Hi.
At the moment I am enabling breadcrumb in Post type only
But If I want to disable breadcrumb is a specific post without using CSS, actually I want it not to be rendered
What can I do
Also, my website is https://brobbq.com
Hi there,
Take a look at these two links:
https://docs.generatepress.com/article/using-hooks-conditional-tags/#static-pages
https://codex.wordpress.org/Conditional_Tags#A_PAGE_Page
Thank you, Leo
Can you check for me this code is right or not, please
<?php if ( is_single() && ! is_single(3479) ) : ?>
<div class="page-header grid-container grid-parent">
<?php if ( function_exists('yoast_breadcrumb') ) {
yoast_breadcrumb('<p id="breadcrumbs">','</p>');
} ?>
</div>
<?php endif; ?>
Try this:
<?php if ( function_exists('yoast_breadcrumb') && is_single() && ! is_single( '3479' ) ) : ?>
<?php yoast_breadcrumb( '<p id=”breadcrumbs”>','</p>' ); ?>
<?php endif; ?>
Any reason you need this part? <div class="page-header grid-container grid-parent">