I am using the Rank Math SEO plugin and I want to enable breadcrumbs. It says I need to insert the code below into my "theme template files" but I am not sure which file it should go in.
I tried adding it to page.php but the breadcrumbs showed up at the bottom of the page. Please advise.
<?php if (function_exists('rank_math_the_breadcrumbs')) rank_math_the_breadcrumbs(); ?>
Thanks for your reply. I placed the code in the header.php file, but unfortunately the breadcrumbs appeared above the header/nav bar instead of below the header image and before the body. See screenshot here. Any idea what went wrong?
I can't seem to locate the breadcrumbs on your site. Normally, the breadcrumbs added to our theme appear below the header and above the header image, since the image is loaded in the body.
You would have to add the breadcrumbs either below the header or above the body. Try enabling the breadcrumbs as shown in this guide, https://rankmath.com/kb/breadcrumbs/.
Try adding the code in the page.php and single.php files and see if this resolves your issue.
To assist you better, we'd love to have a closer look at your setup and to do this, we'll need admin login credentials
(dashboard URL, username, password) to your site. This will enable us to conduct a more in-depth investigation of the issue based on your specific configurations. Would you mind sharing this with us?
I am using the Rank Math SEO plugin and I want to enable breadcrumbs. It says I need to insert the code below into my "theme template files" but I am not sure which file it should go in.
I tried adding it to page.php but the breadcrumbs showed up at the bottom of the page. Please advise.
Hello Akraev,
Thanks for writing to us.
Youcan add the code in header.php.
I have recorded a screencast to show how you can locate the header.php and single.php files.
I hope you find this helpful.
Please feel free to write to us in case of any other queries.
Hello Judith,
Thanks for your reply. I placed the code in the header.php file, but unfortunately the breadcrumbs appeared above the header/nav bar instead of below the header image and before the body. See screenshot here. Any idea what went wrong?
Hi again,
Thank you for getting back to us.
Could you share your site URL so we can look into this for you?
We look forward to your reply.
Thanks,
Hi Andrew,
Yes the URL is: https://tdc-int.com/tdc-staging-/
Hi again,
Thank you for getting back to us.
I can't seem to locate the breadcrumbs on your site. Normally, the breadcrumbs added to our theme appear below the header and above the header image, since the image is loaded in the body.
You would have to add the breadcrumbs either below the header or above the body. Try enabling the breadcrumbs as shown in this guide, https://rankmath.com/kb/breadcrumbs/.
Try adding the code in the page.php and single.php files and see if this resolves your issue.
Try this and let us know how it goes.
Thanks,
Hi Andrew,
I had removed the code since the breadcrumbs were displaying in weird locations. I have now added it to page.php.
Please have a look and let me know if there is a solve.
Thank you
Hello Akraev,
Thanks for writing back.
To assist you better, we'd love to have a closer look at your setup and to do this, we'll need admin login credentials
(dashboard URL, username, password) to your site. This will enable us to conduct a more in-depth investigation of the issue based on your specific configurations. Would you mind sharing this with us?
If you prefer, you can safely share the access through a one-time secret note or using an access plugin such as Controlled Admin Access.
Before you provide this information, we strongly recommend taking a backup of your site.
If you have any concerns or questions about this process, please don't hesitate to let me know.
Best regards,
Hey Again,
Try using the Hooks available and add them to your desired location: https://themenectar.com/docs/salient/developer-docs/#hooks and https://tdc-int.com/tdc-staging-/wp-admin/admin.php?page=edit-snippet&id=6 .
Thanks
ThemeNectar Support Team
That didn't work either.
I solved it by using the shortcode and creating a global section. All working now.
Hello Akraev,
Thanks for writing back.
We're glad this now works for you.
Should you have any further questions or encounter any difficulties along the way, please don't hesitate to reach out.
Best regards,