Breadcrumb Alignment for Collection and Product Pages

Solved

Breadcrumb Alignment for Collection and Product Pages

manbru
Pathfinder
112 0 31

Hey,

 

I have added code to align the breadcrumbs on the collection page with a 350px margin-left.

However, on the product page, I want the breadcrumbs to have a 70px margin-left but haven’t been able to achieve that.

 

This code is my current code and the one that I only want on the collection page:

 

<style>
@media (min-width: 769px) {
.breadcrumbs {
  margin-left: 350px;
}
}
</style>

 

But on the product page i want the breadcrumbs to have a 70px margin-left.

 

 

Here's the collection page: https://r1vex.myshopify.com/collections/all 

Here's the product page: https://r1vex.myshopify.com/products/akpase-rondane-frost-raven-black 

 

On collection page, good:

Skärmavbild 2024-09-27 kl. 16.41.59.png

 

On product page, not good:

Skärmavbild 2024-09-27 kl. 16.43.21.png

 

 

Thanks for helping!

Accepted Solution (1)

Made4uo-Ribe
Shopify Partner
8275 1985 2437

This is an accepted solution.

Hi @manbru 

Check this one. 

Paste it on the theme.liquid. 

 

{% if template.name == 'product' %}
<style>
  @media (min-width: 769px) {
    .breadcrumbs {
      margin-left: 70px;
    }
  }
</style>
{% endif %}

 

And save. 

 

 

Please don't forget to Like and Mark Solution to the post that helped you. Thanks!

If this fixed your issue Likes and Accept as Solution is highly appreciated. Coffee tips fuels my dedication.
Get EXPERIENCED Shopify developers at affordable rates—visit Made4Uo.com for quick quote!
Do not lost your Shopify store! Get FREE trial with ✔️ Rewind Backup: Automatic, reliable, stress-free.
Need THEME UPDATES but has custom codes? No worries, contact us for affordable price.

View solution in original post

Replies 2 (2)

Moeed
Shopify Partner
5456 1476 1763

Hey @manbru 

 

Replace your current code with this code

 

{% if template == 'collection' %}
<style>
@media (min-width: 769px) {
.breadcrumbs {
  margin-left: 350px;
}
}
</style>
{% endif %}
{% if template.name == 'product' %}
<style>
  @media (min-width: 769px) {
    .breadcrumbs {
      margin-left: 70px;
    }
  }
</style>
{% endif %}

 

 

If I managed to help you then, don't forget to Like it and Mark it as Solution!

 

Best Regards,
Moeed

- Need a Shopify Specialist? Chat on WhatsApp

- Custom Design | Advanced Coding | Store Modifications


Made4uo-Ribe
Shopify Partner
8275 1985 2437

This is an accepted solution.

Hi @manbru 

Check this one. 

Paste it on the theme.liquid. 

 

{% if template.name == 'product' %}
<style>
  @media (min-width: 769px) {
    .breadcrumbs {
      margin-left: 70px;
    }
  }
</style>
{% endif %}

 

And save. 

 

 

Please don't forget to Like and Mark Solution to the post that helped you. Thanks!

If this fixed your issue Likes and Accept as Solution is highly appreciated. Coffee tips fuels my dedication.
Get EXPERIENCED Shopify developers at affordable rates—visit Made4Uo.com for quick quote!
Do not lost your Shopify store! Get FREE trial with ✔️ Rewind Backup: Automatic, reliable, stress-free.
Need THEME UPDATES but has custom codes? No worries, contact us for affordable price.