Jump to content

tuanphan

Circle Member
  • Posts

    65,221
  • Joined

  • Last visited

  • Days Won

    520

Posts posted by tuanphan

  1. On 4/15/2023 at 5:51 AM, sure11 said:

    Hi, would this code be correct to automatically correct certain affiliate links (with certain domain URL), and convert them all automatically to add the sponsored tag to each one?

        <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
        <script>
            $(document).ready(function() {
                  $('a[href*="https://www.affiliate.com"]').attr('rel', 'sponsored');
            });
        </script>

    I have a business plan. Would I inject this code into blog code injection header area? It will convert all links with a new attribute?

    This code will add rel="sponsored" attribute to https://www.affiliate.com link

    If you add to Blog Page Code Injection, it will affect blog page 

    If you add to Site wide Code Injection, it will affect all pages

  2. 4 hours ago, MichelleSandler said:

    Hi I also need help with how to do this same coding. 

     

    Add to Design > Custom CSS

    a.grid-item .grid-image-inner-wrapper {
        background-size: cover;
        background-repeat: no-repeat;
        background-position: center center;
        transition: all 0.3s ease;
    }
    a.grid-item:hover .grid-image-inner-wrapper img {
        opacity: 0;
        transition: all 0.3s ease;
    }
    a.grid-item .grid-image-inner-wrapper img {
        transition: all 0.3s ease;
    }
    a.grid-item:nth-child(1) .grid-image-inner-wrapper {
        background-image: url(https://images.squarespace-cdn.com/content/5ffc7fcb6bbc7c3452a02a51/40f786c3-b0b5-4f89-9cdc-67588a42be77/MWF2.gif);
    }
    a.grid-item:nth-child(2) .grid-image-inner-wrapper {
        background-image: url(https://images.squarespace-cdn.com/content/5ffc7fcb6bbc7c3452a02a51/1661782657732-F1MC8XFCK78K57X6J8JR/NISSAN+MAGNITE-high.gif);
    }
    a.grid-item:nth-child(3) .grid-image-inner-wrapper {
        background-image: url(https://images.squarespace-cdn.com/content/5ffc7fcb6bbc7c3452a02a51/8a9879b6-ad11-4c12-904a-fa046332cfcc/I+Shape+My+World+-+Zuleika+Patel.gif);
    }
    a.grid-item:nth-child(4) .grid-image-inner-wrapper {
        background-image: url(https://images.squarespace-cdn.com/content/5ffc7fcb6bbc7c3452a02a51/24194dd9-6fba-406a-a7c2-dff860426a85/120+Years+of+Quality+%26+Style.gif);
    }
    a.grid-item:nth-child(5) .grid-image-inner-wrapper {
        background-image: url(https://images.squarespace-cdn.com/content/5ffc7fcb6bbc7c3452a02a51/0d7ae118-ca52-497f-ac43-29d2a06219e0/adidas+Continental+80.gif);
    }

     

  3. On 4/11/2023 at 10:40 PM, RodyHuy said:

    Hello Tuanphan

    I made an error on the previous script you have sent me. The resizing works, only I have some grey margin on both sides. Do you have an idea to remove them? or may be to set the background to white?

    If you have a script to be able to put another video for the mobile version only, it would be great (mobile video is on vimeo (https://vimeo.com/815994215)

    Best regards

    Rodolphe

     

    IMG_7689.PNG

    If you can add 2 sections with desktop video - mobile video, I can give code to show 1 on desktop, show another on mobile

  4. On 4/12/2023 at 3:27 PM, aina said:

    Perfect! How should I do that? Thank you! 

     

    On 4/11/2023 at 3:52 PM, tuanphan said:

    I think we can add Slideshow, enable arrows, then we will use code to make arrows cover slideshow (and use code to hide arrows then)

    You ca add Slideshow, enable arrows then share link to page where you added, we will check

  5. On 4/15/2023 at 2:26 AM, jonuehring said:

    @tuanphan I have a pop-up with the image/text side-by-side layout: https://revivalskinartistry.com/

    Is there a way to use this code to show the image above the text on mobile? with that CSS it shows on mobile but only behind the text 

    Use this new code

    @media screen and (max-width:767px) {
    .sqs-popup-overlay-content .sqs-slide {
        position: fixed !important;
        bottom: 0 !important;
    }
    .sqs-slide-wrapper[data-slide-type="popup-overlay"] [data-slice-type="gallery"] .sqs-slice-gallery-item.loaded img {
        opacity: 1 !important;
    }
    .sqs-slide-wrapper[data-slide-type="popup-overlay"] .sqs-slide-container[data-slide-type="popup-overlay"] [data-slice-type="gallery"] {
        display: block !important;
    }
    .sqs-slide-wrapper[data-slide-type="popup-overlay"] [data-slice-type="gallery"] {
        z-index: 1000 !important;
    }
     .sqs-slice-group.group-copy.copy-layer-background {
        z-index: 99999999;
        background-color: transparent !important;
        top: 50%;
    }
    a.sqs-popup-overlay-close {
        z-index: 9999999 !important;
    }
        .sqs-slide-wrapper[data-slide-type="popup-overlay"] [data-slide-layout-id="overlay-center-card-02"] [data-slice-type="gallery"] {
            width: 100% !important;
            height: 50% !important;
        }
        .sqs-slide-wrapper[data-slide-type="popup-overlay"] .sqs-slide-container[data-slide-type="popup-overlay"] .layer-front, .sqs-slide-wrapper[data-slide-type="popup-overlay"] .sqs-slide-container[data-slide-type="popup-overlay"] .sqs-slide-layer-content {
            height: 500px !important;
        }}

     

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