madebyapricot Posted May 23 Share Posted May 23 Looking to add the below Google calendar pop-up to the "Book A Free Call" button in our header and "Stop Noodlin'" section. It's currently a TypeForm pop-up, but looking to make the switch. Website -> https://www.madebyapricot.com/ Code: Google Calendar "Button With Pop Up" <!-- Google Calendar Appointment Scheduling begin --> <link href="https://calendar.google.com/calendar/scheduling-button-script.css" rel="stylesheet"> <script src="https://calendar.google.com/calendar/scheduling-button-script.js" async></script> <script> (function() { var target = document.currentScript; window.addEventListener('load', function() { calendar.schedulingButton.load({ url: 'https://calendar.google.com/calendar/appointments/schedules/AcZssZ0pwSCOMh-CIFof5UzIT1yklZ5xgUBnUuZegMvNeTHKQ4bK77LjPlL6MAGx1spP7iDdPZKmwAOV?gv=true', color: '#039BE5', label: 'Book an appointment', target, }); }); })(); </script> <!-- end Google Calendar Appointment Scheduling --> Beyondspace 1 Link to comment
tuanphan Posted May 24 Share Posted May 24 #0. Make sure header button, option "Open in New Tab" is disabled #1. First, add your Google Calendar to Website Tools > Code Injection > Footer #2. Use this code to Website Tools > Custom CSS button.qxCTlb { position: fixed; opacity: 0; transform: translateX(-1000px); } #3. Use this code under #1 code <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script> <script> $(document).on('click', 'header#header a.btn', function(event) { event.preventDefault(); $('button.qxCTlb').click(); }); </script> #4. Result Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
madebyapricot Posted May 24 Author Share Posted May 24 Perfect @tuanphan. How can I add the same thing to the button in the "Stop Noodlin', Start Doolin'" section at the bottom? Link to comment
Solution tuanphan Posted May 25 Solution Share Posted May 25 Change #3 code to this <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script> <script> $(document).on('click', 'header#header a.btn, div#block-yui_3_17_2_1_1708117493982_80427 a', function(event) { event.preventDefault(); $('button.qxCTlb').click(); }); </script> and make sure that button url "Open in New Tab" is disabled madebyapricot 1 Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Roman1222 Posted July 12 Share Posted July 12 I have followed your codes based on this chat above, but on the home page and the header throughout the website, the close button on the google calendar pop up won't work. It works on the pop ups when you scroll to a different button lower on the page (except the home page). This is the only piece I need to figure out to help make this happen for a website. Can you help me out @tuanphan? Link to comment
tuanphan Posted July 15 Share Posted July 15 On 7/12/2024 at 9:56 PM, Roman1222 said: I have followed your codes based on this chat above, but on the home page and the header throughout the website, the close button on the google calendar pop up won't work. It works on the pop ups when you scroll to a different button lower on the page (except the home page). This is the only piece I need to figure out to help make this happen for a website. Can you help me out @tuanphan? Can you share site url? We can check easier Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Roman1222 Posted July 15 Share Posted July 15 https://ladybug-elk-w8ck.squarespace.com/ Password: C0d3n0w Link to comment
tuanphan Posted July 19 Share Posted July 19 On 7/16/2024 at 1:45 AM, Roman1222 said: https://ladybug-elk-w8ck.squarespace.com/ Password: C0d3n0w You can remove this code, I will test code again easier. I check the forum every 2-3 days so answers may be a bit delayed. Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Roman1222 Posted July 19 Share Posted July 19 I deleted the code and I'm still having a problem with the close button not working on the home page. The header button goes to a black page with written code instead of showing the calendar. Let me know what you can do when you get the time. Thanks for the update on response time. I appreciate it. Link to comment
tuanphan Posted July 25 Share Posted July 25 On 7/19/2024 at 10:28 PM, Roman1222 said: I deleted the code and I'm still having a problem with the close button not working on the home page. The header button goes to a black page with written code instead of showing the calendar. Let me know what you can do when you get the time. Thanks for the update on response time. I appreciate it. Have you disabled option "Open in New Tab" yet? Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
tuanphan Posted August 1 Share Posted August 1 I see you added new code. If you have any other problems with old code, just comment below. Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) 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