Jump to content

Breadcrumb at the start of every blog post.

Go to solution Solved by colin.irwin,

Recommended Posts

Posted
On 6/28/2024 at 3:43 AM, tuanphan said:

It looks fine to me. Can you take a screenshot of problem?

Its saying the title twice, "Smoke Detector & Fire Alarm Smoke Detector & Fire Alarm"

 

Screenshot 2024-07-02 153756.png

Posted
On 7/3/2024 at 5:38 AM, MegRae said:

Its saying the title twice, "Smoke Detector & Fire Alarm Smoke Detector & Fire Alarm"

 

Screenshot 2024-07-02 153756.png

You can remove this code, I will test it again

<script>$(document).ready(function(){  
  var thisPath = window.location.pathname;
  var thisPage;
  var breadcrumbLink;
    thisPage = $('.blog-item-title').text();
      $('.blog-item-top-wrapper').prepend('<div id="breadcrumbNewsArticle"><div><a href="/">Home</a> &#187; <a href="/services">All Services</a> &#187; <span class="truncate">'+thisPage+'</span></div></div>');
});
</script>

https://www.brutinel.com/services/smoke-detector-amp-fire-alarm

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

  • 1 month later...
Posted

Hey, I'm using 7.1 and added the code as discussed above. It works, but when using it inside of a lightbox, it's remembering the previous page. Here's my setup:

  1. I added breadcrumbs code to a blog (code works perfectly directly in blog)
  2. Added a summary block of the blog to a page
  3. I'm using lightbox anything to turn the summary block into lightbox (Lightbox Anything plugin) so a pop-up opens every time without loading the blog page. 
  4. When I close one blog lightbox, I can open another. This is where the issue happens.

When I close the lightbox and open up the next post, there isn't a reset and a breadcrumb from the first post is showing up in the second post. When I refresh the page, it resets and the breadcrumbs are working correctly again.

Here's a Loom showing what's happening.

This is the test page that I'm using: goodbrother.tv/test

 

goodbrother.tv

Posted
On 8/29/2024 at 8:29 PM, jaker said:

Hey, I'm using 7.1 and added the code as discussed above. It works, but when using it inside of a lightbox, it's remembering the previous page. Here's my setup:

  1. I added breadcrumbs code to a blog (code works perfectly directly in blog)
  2. Added a summary block of the blog to a page
  3. I'm using lightbox anything to turn the summary block into lightbox (Lightbox Anything plugin) so a pop-up opens every time without loading the blog page. 
  4. When I close one blog lightbox, I can open another. This is where the issue happens.

When I close the lightbox and open up the next post, there isn't a reset and a breadcrumb from the first post is showing up in the second post. When I refresh the page, it resets and the breadcrumbs are working correctly again.

Here's a Loom showing what's happening.

This is the test page that I'm using: goodbrother.tv/test

 

With Lightbox plugin, you will need to add breadcrumb code use Lightbox function

Which exact breadcrumb you used? I will test again

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.