Preview:
FIRST IN THE PRODUCT PAGE ADD THE NEW BUTTON 
 <!---- // -------- NEW FAREHARBOR BLUE BUTTON -------- // ---->
      <div class="fhButton" style="margin-top: 1.5em !important;">
        <a href="<?php echo $fareHarborLink; ?>" style="font-weight: bold !important; width: 100% !important; font-family:Lato, sans-serif !important; font-size: 1em !important; box-shadow:none !important; padding: .15em 2em !important; border-radius: 3px !important;" class="fh-shape--square fh-size--small  fh-button-true-flat-blue fh-color--white">Book now</a>
      </div>


THEN IN THE THEME LIQUID FILE ADD THE SCRIPT
<!-------- // -------- FAREHARBOR SCRIPT TO OVERRIDE PREVIOUS SOFTWARE BLUE BUTTON - CREATED A NEW BLUE BUTTON -------- // -------->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script>
    $(document).ready(function() {
        // Object to map page slugs to FareHarbor links
        var pageToLinkMapping = {
            "knife-skills-vegetable-yaki-soba-vegan-5": "https://fareharbor.com/embeds/book/leedscookeryschool/items/580473/?full-items=yes&flow=1265884",
            "friday-night-takeaway-thai": "https://fareharbor.com/embeds/book/leedscookeryschool/items/580660/?full-items=yes&flow=1265866",
            "a-taste-of-mexico-3": "https://fareharbor.com/embeds/book/leedscookeryschool/items/580459/?full-items=yes&flow=1265859",
            "parent-and-kids-chinese-takeaway": "https://fareharbor.com/embeds/book/leedscookeryschool/items/580676/?full-items=yes&flow=1265838"
        };

        // Get the current page URL
        var currentUrl = window.location.pathname;
        
        // Extract the page slug (part after the last slash)
        var pageSlug = currentUrl.substring(currentUrl.lastIndexOf('/') + 1);

        // Default FareHarbor link (in case no match is found)
        var fareHarborLink = "https://fareharbor.com/embeds/book/leedscookeryschool/?full-items=yes";

        // Check if the page slug exists in the mapping
        if (pageToLinkMapping.hasOwnProperty(pageSlug)) {
            fareHarborLink = pageToLinkMapping[pageSlug];
        }

        // Update the href attribute of the booking button
        $('.fhButton a').attr('href', fareHarborLink);
    });
</script>
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter