Jump to content

Disable blog thumbnail link

Recommended Posts

Posted

Site URL: https://jeanne-m-juneau.squarespace.com/

Hi, I'd like to disable the blog thumbnail link. Is there any custom code for this? I'm using the Summary block Carousel to display some portfolio work using the forward and back arrow navigation to scroll between my portfolio pieces and don't want the image to be linked. I've tried this custom code, below, but it does not work. Does anyone have custom code to disable the blog thumbnail link in a summary section using the carousel?

https://jeanne-m-juneau.squarespace.com/web-design

pw is 123

/* disable blog thumbnail link */
section.blog-image-wrapper {
    pointer-events: none;
}

  • Replies 10
  • Views 876
  • Created
  • Last Reply
Posted

the pointer-events:none; bit is the right code to disable a link using just css, but you need to specify exactly which links you want to disable. the code you've supplied won't find the links you want. The answer will depend on how fine-grained you want the code to work. if you only wanted it to work on that one section, then you need to target the links using that particular section id. something like this:

div#yui_3_17_2_1_1627258107628_88 a {
	pointer-events:none;
}

the section id can be found using a squarespace block identifier extension on chrome, or looking in the source using chrome's developer settings.

the code you posted will only work for blog-image-wrapper instances, which dont' apply in a carousel setup (as far as I can tell looking at your site)

hope that helps

Dave Hart. Software/Technology Consultant living in London. buymeacoffee 

Posted
On 7/25/2021 at 5:22 PM, iamdavehart said:

the pointer-events:none; bit is the right code to disable a link using just css, but you need to specify exactly which links you want to disable. the code you've supplied won't find the links you want. The answer will depend on how fine-grained you want the code to work. if you only wanted it to work on that one section, then you need to target the links using that particular section id. something like this:

div#yui_3_17_2_1_1627258107628_88 a {
	pointer-events:none;
}

the section id can be found using a squarespace block identifier extension on chrome, or looking in the source using chrome's developer settings.

the code you posted will only work for blog-image-wrapper instances, which dont' apply in a carousel setup (as far as I can tell looking at your site)

hope that helps

Thank you! I found the section id, used this div#page-section-60fb7c850fd9d65c7436c370 a {
    pointer-events:none;} 
and it worked. No more linked blog thumbnails. Many thanks for your help.

Posted
46 minutes ago, islandgirl said:

Thank you! I found the section id, used this div#page-section-60fb7c850fd9d65c7436c370 a {
    pointer-events:none;} 
and it worked. No more linked blog thumbnails. Many thanks for your help.

Dang! Except that now the links in the text won't work. Maybe I should have asked this question: Is there a way to change the thumbnail link to a different link?

Posted

the section Id you've used is a very high up and contains basically most of your site. 

you need to use something a lot more specific.

try this one instead. this says find the section with id yui_3...._107 (which is your summary item wrapper, then find the summary-thumbnail-otuer-container within that (so it leaves the metadata captions beneath along) and then all the links (a) inside there.

#yui_3_17_2_1_1627420698207_107 .summary-thumbnail-outer-container a {
	pointer-events: none;
}

try that. see how you get on.

 

Dave Hart. Software/Technology Consultant living in London. buymeacoffee 

Posted
Just now, islandgirl said:

Dang! Except that now the links in the text won't work. Maybe I should have asked this question: Is there a way to change the thumbnail link to a different link?

To clarify: the excerpt links won't work now.

Posted

I eliminated it by changing the footer section height to "Small" instead of "custom 0". There's still too much of padding but maybe I have to live with it like that?

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.