Jump to content

Changing header logo URL on one page (mobile)

Go to solution Solved by tuanphan,

Recommended Posts

I have a secondary shop (separate from my main shop) in my site. When I am on the product details page on mobile, there is no way to get back to the secondary shop page.

Is there any way, with CSS, to do 1 of the following options (ideally both):

  1. To change the header logo URL on the second shop page to redirect to  shannoncamillearts.com/reelsisterspod, rather than my main site (shannoncamillearts.com) on web and mobile.
  2. Add breadcrumbs on the product details page on mobile (for some reason they are only appearing on the web version, not mobile)

Squarespace URL is: https://spinach-accordion-j2lf.squarespace.com/

Link to comment
  • Replies 12
  • Views 2.4k
  • Created
  • Last Reply

Top Posters In This Topic

#1. Add this code to Reelsisterpod Page Settings > Advanced > Header (DO NOT use Custom CSS box)

<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script>
<script>
$(document).ready(function() {
$('.header-title-logo a, .header-mobile-logo a').attr('href','/reelsisterspod');
});
</script>

#2. Show it under image or above image?

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!)

Link to comment
On 9/2/2023 at 4:05 PM, tuanphan said:

#1. Add this code to Reelsisterpod Page Settings > Advanced > Header (DO NOT use Custom CSS box)

<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script>
<script>
$(document).ready(function() {
$('.header-title-logo a, .header-mobile-logo a').attr('href','/reelsisterspod');
});
</script>

#2. Show it under image or above image?

That worked! 

and for #2, above image. 

Link to comment
  • Solution
On 9/7/2023 at 12:49 PM, smoman said:

That worked! 

and for #2, above image. 

#2. Add to Last Line in Code Injection > Footer > Then check again on real mobile

<script>
  $(document).ready(function(){
    if (jQuery(window).width() < 767) {
    $('nav.ProductItem-nav').insertBefore('article#pdp>section');
}
});
</script>
<style>
  @media screen and (max-width:767px) {
  nav.ProductItem-nav {
    padding: 10px !important;
}
  }
</style>

image.png.b1383b564ac2e63f9572457ddfde0a3a.png

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!)

Link to comment
On 9/11/2023 at 7:23 AM, smoman said:

@tuanphan That did it! But oddly now my shop items are pushed to the left (in both shops) and not centered as before. Any idea why that is?
Screenshot2023-09-10at5_22_28PM.thumb.png.1b07f979310f17a59831a87dba2ebdbb.pngScreenshot2023-09-10at5_22_13PM.thumb.png.719be3c28980e595074a0f583b4b09c9.png

In CSS box, find & edit this code

@media only screen and (max-width: 640px) {
    .products .list-grid {
        display:flex;
        flex-wrap: wrap;
        justify-content: space-between
    }

    .products .grid-item {
        width: 48%
    }
}

to this

@media only screen and (max-width: 640px) {
    .products .list-grid {
        display:grid !important;
        grid-template-columns: 1fr 1fr !important;
    }

    .products .grid-item {
        width: 100% !important;
    }
}

 

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!)

Link to comment
18 hours ago, tuanphan said:

In CSS box, find & edit this code

@media only screen and (max-width: 640px) {
    .products .list-grid {
        display:flex;
        flex-wrap: wrap;
        justify-content: space-between
    }

    .products .grid-item {
        width: 48%
    }
}

to this

@media only screen and (max-width: 640px) {
    .products .list-grid {
        display:grid !important;
        grid-template-columns: 1fr 1fr !important;
    }

    .products .grid-item {
        width: 100% !important;
    }
}

 

Perfection! Thanks so much!

Link to comment
  • 4 months later...

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.