-
AuthorPosts
-
February 22, 2020 at 5:59 pm #1186986
Hello,
I would like to add a beadcrump on every pages/posts/category on my website just bellow the header.As classic implementation involves to insert it into a title_container which uses alternate content I have 2 issues:
> I don’t wan to diplay breadcrumbs on mobile. When I do so, an empty title_container is still displayed (see website link).
> I want to avoid to diplay it on an anternate content because I don’t want separator beetwin main content and alternate content. Il want it to look naturally on main content (see website link).
Actually I would like to display breadcrumbs directly at to of page (in main content) except on home page and mobile. And why not using shortcode.
Any help would be apreciated.
Regards.
February 24, 2020 at 4:45 pm #1187395Hey kumharas,
When you edit the pages, in the sidebar you have this option Title Bar Settings, you can set there if you want to hide or show the breadcrumbs.
You can just go to the homepage and remove it there while the global default option is set to show.
As for mobile devices, you can add this CSS code, in Quick CSS (located in Enfold > General Styling) to hide it:
Try adding this CSS code in Quick CSS, located in Enfold > General Styling:@media only screen and (max-width:767px) { #top .avia-breadcrumbs { display: none; } }
Best regards,
NikkoFebruary 25, 2020 at 1:09 pm #1187673Hi Nikko,
Thanks for your awnser, it works!
Now, how can I put breadcrumb in main content (body) for every page ?Regards.
February 25, 2020 at 2:35 pm #1187692Hi kumharas,
Inside the WordPress Dashboard, go to Enfold > Header > Header Title and Breadcrumbs set this to Display title and breadcrumbs. :)
Best regards,
NikkoFebruary 25, 2020 at 3:56 pm #1187739Yes I did it but the issue is that it displays breadcrumb in an alternate content and I want it to be displayed in a main content.
How can I do this ?
Thanks.
February 27, 2020 at 5:09 am #1188325Hi kumharas,
I see now what you meant by alternate and main content.
Please hide breadcrumbs in Enfold > Header > Header Title and Breadcrumbs.
Then in your child theme’s functions.php add this code at the bottom:add_shortcode('enfold_breadcrumbs', 'avia_breadcrumbs');
Then in your pages, add a Code Block then add this inside it:
[enfold_breadcrumbs]
Hope this helps :)
Best regards,
NikkoFebruary 27, 2020 at 10:20 am #1188358Hi Nikko,
That’s a good idea but as far as there about 500 posts, I cannot add shortcode for each one.
Is there a way to but add this shortcode for 500 posts at the same time?Thanks a lot for your help!
February 28, 2020 at 5:50 am #1188721Hi kumharas,
Yes, first you’ll need to use a child (skip this if you already have one): https://kriesi.at/documentation/enfold/child-theme/
Next copy single.php from enfold to your child theme.
Edit single.php (child theme) and on top of this code (line 40):get_template_part( 'includes/loop', 'index' );
add this:
echo do_shortcode(‘[enfold_breadcrumbs]’);
Hope this helps :)Best regards,
NikkoFebruary 29, 2020 at 11:51 am #1189005Hi Nikko,
That’s perfect! Many thanks.
Many thanks
March 1, 2020 at 8:05 am #1189171Hi,
Great, I’m glad that Nikko could help you out. Please let us know if you should need any further help on the topic or if we can close it.
Best regards,
RikardMarch 1, 2020 at 10:30 am #1189191It’s ok you can close it.
Regards
March 1, 2020 at 11:42 pm #1189279Hi,
Glad that Nikko could help you out, we will close this now. Thank you for using Enfold.For your information, you can take a look at Enfold documentation here
For any other questions or issues, feel free to start new threads in the Enfold forum and we will gladly try to help you :)Best regards,
Mike -
AuthorPosts
- The topic ‘Breadcrumb in page content’ is closed to new replies.