Hello,
Thank you for contacting Rank Math support. I’m sorry to hear that you’re having trouble with adding breadcrumbs to your site.
To add breadcrumbs to your website, you need to enable the breadcrumbs function in Rank Math from Rank Math > General Settings > Breadcrumbs. Then, you need to add the following code snippet to your theme template files where you want to display the breadcrumb:
/**
* Use the following code in your theme template files to display breadcrumbs:
*/
<?php if (function_exists('rank_math_the_breadcrumbs')) rank_math_the_breadcrumbs(); ?>
The exact file where you add this code would depend on your theme, it is usually the single.php file or the header.php file, but it can vary from theme to theme. If you’re not sure where to add the Rank Math breadcrumb code, you can reach out to your theme developers for help.
You can also refer to this guide for more details: https://rankmath.com/kb/breadcrumbs/
I hope this helps you set up the breadcrumbs on your site. If you have any other questions or issues, please feel free to reply to this ticket and I’ll be happy to assist you further.
Thank you for choosing Rank Math as your SEO plugin. Have a great day!
I’ve tried this with the Divi theme but there has been no success.
That’s why I was reaching out for further help rather than a link to an article.
The following is in the single.php code of the theme settings.
<?php
*/
<?php if (function_exists(‘rank_math_the_breadcrumbs’)) rank_math_the_breadcrumbs(); ?>
get_footer();
Hi again,
From your code, it looks like you’re adding the code closer to the bottom of the page. Typically you want to add your breadcrumb somewhere at the top of your page, but as we mentioned before, your theme developers would be in the best position to advise on where to add this code. We’d advise you to reach out to them for help with this.
Cheers!
Hello,
Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.
If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.
Thank you.