CoorlasArchitecture Posted August 22 Share Posted August 22 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) 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
Solution Lesum Posted August 22 Solution Share Posted August 22 @CoorlasArchitecture Hi! The collection-ID for that page is #collection-66c55c4aec59166e57fc8aaf If my comments were useful, please like or mark my solution as answer so others can scroll to it quickly. Sam Web Developer & Digital Designer ☕ Did you find my contribution helpful? Buy me a coffee? Link to comment
CoorlasArchitecture Posted August 22 Author Share Posted August 22 Awesome, it worked! Thank you! How in the world do you find it? when I try inspecting the page I only find block or yui ID's Link to comment
Lesum Posted August 22 Share Posted August 22 @CoorlasArchitecture You might find this tool helpful for easily finding collection, section, and block IDs: Squarespace ID Finder If my comments were useful, please like or mark my solution as answer so others can scroll to it quickly. Sam Web Developer & Digital Designer ☕ Did you find my contribution helpful? Buy me a coffee? Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment