Jump to content

Hide Button and Divert Click to Google Calender Scheduler

Go to solution Solved by Lesum,

Recommended Posts

Hello,

I am attempting to hide and redirect a page button using custom code injection in the page 'advanced' tab. I successfully used with code on another page found here:

https://www.coorlasarch.com/

I cannot find the button block or collection ID to make this code function on this page:

https://www.coorlasarch.com/process

(PW: Process)

image.png.07c82a873e7d3785cc0db917fc386e0d.png

Here is the root code with (Enter Here) needing to be replaced to function properly:

<style>
div.code-block {
    visibility: hidden;
}
</style>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script>
<script>
$(document).on('click', '#collection-(Enter Here) .button-block a[href="#google-scheduler"]', function(event) {
    event.preventDefault();
    $('.code-block button').click();
});
</script>

 

Thank you in advance for your assistance!

Link to comment
  • Replies 3
  • Views 196
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Posted Images

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.