Jump to content

wzrdofthestnk

Member
  • Posts

    21
  • Joined

  • Last visited

Everything posted by wzrdofthestnk

  1. Hi, I added these two custom css scripts to my website. One is for making the images in the carousel slider clickable. The other is for making all external links 'nofollow'. They both have target="_blank" and so the built in toggle switch in squarespace is not changing it. But I need to make some links open in a new tab and some (especially the internal ones) open in the same tab. Will appreciate your advice on this. website Password: 4204200 The first carousel section with several slides should open in new tab when the toggle switch "open in new tab" is disabled. The other external links set to "open in new tab" should continue doing this. <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script> <script> $( ( ) => { const selector = '.user-items-list-carousel__slides .list-item'; $( selector ).each ( function ( ) { const $this = $( this ); $( $this ).click ( function ( ) { const url = $( '.list-item-content__button', $this ) .attr ( 'href' ); $( `<a href="${ url }" target="_blank">` ) .get ( 0 ) .click ( ); } ); } ); } ); </script> <script> <script> (function () { window.addEventListener('load', function () { var fixAmazonLinks = function () { var amazonLinks = document.querySelectorAll( 'a[href*="https://"], a[href*="www."]' ); if (!amazonLinks instanceof NodeList) { return; } amazonLinks.forEach(link => { link.rel = 'nofollow'; link.target = '_blank'; }); }; fixAmazonLinks(); }); })(); </script>
  2. Thanks, I tried "blank" and "self" both not working for my needs. I need a solution to make the links that lead to my internal pages open in same tab and links that lead to external pages open in different tab Any ideas how I can manage this myself? Thanks Edit: If if disable the "open link in new tab" in the content section of my carousel slides it still opens my internal links in a new tab. Any way I can make this feature usable again? Might have to do with this code I added to Code Injection -> Footer, that made my images and cards clickable in the carousel sections. Would really appreciate the help ! <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script> <script> $( ( ) => { const selector = '.user-items-list-carousel__slides .list-item'; $( selector ).each ( function ( ) { const $this = $( this ); $( $this ).click ( function ( ) { const url = $( '.list-item-content__button', $this ) .attr ( 'href' ); $( `<a href="${ url }" target="_blank">` ) .get ( 0 ) .click ( ); } ); } ); } ); </script> <style> .user-items-list-item-container[data-section-id="6531f15eb6b9412a3a3bb456"] .user-items-list-carousel__slide { pointer-events: initial !important; user-select: unset !important; } .user-items-list-item-container[data-section-id="6531f15eb6b9412a3a3bb456"] .user-items-list-carousel__gutter { cursor: pointer; } </style>
  3. @Collaborada Any idea how to make the internal links to my pages NOT open up in a new tab. <script> (function () { window.addEventListener('load', function () { var fixAmazonLinks = function () { var amazonLinks = document.querySelectorAll( 'a[href*="https://"], a[href*="www."]' ); if (!amazonLinks instanceof NodeList) { return; } amazonLinks.forEach(link => { link.rel = 'nofollow'; link.target = '_blank'; }); }; fixAmazonLinks(); }); })(); </script>
  4. @tuanphan Can you add a website symbol please? NOTE: Fixed it with this line of code <i class="fa-solid fa-link"></i>
  5. This worked for me: .header-nav-wrapper a { background-image: none !important; }
  6. Hey. There is this line under my Nav-Bar (Burger Menu) and I can't get rid of it. Would really appreciate someone helping me fix this. Can't find any information on this topic, except for changing the browser (which didn't work). www.stunk.info pass: 4204200 Thanks!
  7. Thanks. This really worked for me by just replacing the "amazon.com" and "amzn.to" part with "https://" and "www." 👍🏼
  8. Hey! I want to disable the hover effect when hovering over a card button on my gallery sections. I already added custom css from @tuanphan to make the images and the whole card clickable. Now I need to remove the hover effect. If I change Card Button Background and Card Button Text it doesn't work the way I want to. This is my website: www.stunk.info Password: 4204200
  9. Made it work, so that it is on the right side again. By changing this } .header-nav { display: flex !important; width: 70% !important; flex: 1 1 70% !important; } .header-title { flex: 1 0 30% !important; } } to this } .header-title-nav-wrapper { flex: 1 0 100% !important; } .header-nav { display: flex !important; width: 70% !important; flex: 1 1 0% !important; } .header-title { flex: 1 0 90% !important; } }
  10. Does this work, even though I didn't use the amazon block but the gallery section instead. And the script is searching for any link that has "amazon" in it. Can I just leave it like that or should I change the parts up to something like "https://" What would be a smart way to do this?
  11. www.stunk.info password: 4204200 Hey everyone, I want the scrolling of my website to be smooth, going from one section to the next one (top to bottom) and giving the possibility to swipe up free. Would really appreciate someone helping me with this one. Thanks.
  12. @paul2009 So, I've created an cookie banner with Cookie Script and added it to my header in squarespace. Is this DSGVO ready now? www.stunk.info Password: 4204200
  13. Hey. I want to change the links on my website to non-follow. www.stunk.info Password: 4204200 Can someone help me?
  14. Can I just copy this code to make the images clickable in my carousels? I want to add more and more carousels over time. this is my password and website RgqWr99C238yjy3p#Bp9 https://gazelle-flounder-wfn2.squarespace.com/
  15. Ok. Maybe someone can come up with an alternative solution and I don't even have to use this carousel slider. I want to present brands in the carousel slider and want to make the images, titles and buttons clickable, so that the click leads to a custom "brand page". Is this not possible at all to do this in a carousel slider? (mabe a custom one works?)
  16. Unfortunately this is for the "Simple List" only. I've been using the "Carousel Slide" setting. "It is not possible to make the entire element clickable if you choose to use the Banner Slideshow or Carousel design options." 😢
  17. https://gazelle-flounder-wfn2.squarespace.com/home password: RgqWr99C238yjy3p#Bp9 This is the URL and the password.
  18. Hello. I want to make the images and the titles of my carousel content clickable and they should link to the same url as the green button does. Someone please tell me how to make this possible. I entered a site url which you probably can't access, because I'm still in demo mode, because I just registered. How can I share with you safely? Thank you all 🦦
×
×
  • 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.