tomtho Posted March 20, 2022 Share Posted March 20, 2022 Site URL: https://www.qutefs.com.au/home-test Hi there, We are trying to launch a new page with our sponsors logos on it and I can't for the life of me work out how to get the banners to auto scroll. On our test home page I have tried to use code form this forum page but there's obviously no carousel available anymore. The only way to get it to auto play is using the simple slideshow format but that only shows one image at a time and is too tall for me to even consider it. We're trying to keep it pretty short so it doesn't take up the whole page. Any help or ideas for this would be much appreciated. Home Test Flight — QUTEFS - QUT Economics and Finance Society Link to comment
Solution Beyondspace Posted March 20, 2022 Solution Share Posted March 20, 2022 (edited) 5 hours ago, tomtho said: Site URL: https://www.qutefs.com.au/home-test Hi there, We are trying to launch a new page with our sponsors logos on it and I can't for the life of me work out how to get the banners to auto scroll. On our test home page I have tried to use code form this forum page but there's obviously no carousel available anymore. The only way to get it to auto play is using the simple slideshow format but that only shows one image at a time and is too tall for me to even consider it. We're trying to keep it pretty short so it doesn't take up the whole page. Any help or ideas for this would be much appreciated. Home Test Flight — QUTEFS - QUT Economics and Finance Society I gave the solution in the following post: For you case, we need change a little bit in selecting the next button (Currently your page has 2 next button, one in carousel, one in lightbox). Try adding to Home > Settings > Advanced > Code Injection, choose footer <script> (function docReady(fn) { // see if DOM is already available if (document.readyState === "complete" || document.readyState === "interactive") { // call on next available tick setTimeout(fn, 1); } else { document.addEventListener("DOMContentLoaded", fn); } })(() => { if (window.location == window.parent.location) { const reelControls = document.querySelectorAll('.gallery-reel-control-btn[aria-label*="Next"]'); reelControls.forEach(reelControl => { (function reelTimer() { setTimeout(() => { reelControl.click(); reelTimer(); }, 2000); // change this value to change the speed })(); }) } }); </script> Let me know how it works on your site Edited March 20, 2022 by bangank36 tuanphan and tomtho 1 1 BeyondSpace - Squarespace Website Developer 🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox - Lightbox captions only mode) 🗓️ Delivery Date Picker (Squarespace Date picker form field) 💫 Gallery block 7.1 workaround 🥳 No-code customisations for Squarespace 🚀 Learn how to rank new pages on Google in 48 hours! If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. Thank you! Link to comment
tomtho Posted March 20, 2022 Author Share Posted March 20, 2022 You're an absolute legend! Thanks so much it works perfectly. One follow up question. Since this is our test home page that we'll eventually swap with our current one, will I have to change anything if its slug is going from /home-test to /home? Link to comment
Beyondspace Posted March 20, 2022 Share Posted March 20, 2022 (edited) 12 minutes ago, tomtho said: You're an absolute legend! Thanks so much it works perfectly. One follow up question. Since this is our test home page that we'll eventually swap with our current one, will I have to change anything if its slug is going from /home-test to /home? No, my code apply for the general class, not target to a specific block, so you can check it in you go-live page Edited March 20, 2022 by bangank36 tomtho 1 BeyondSpace - Squarespace Website Developer 🖼️ Lightbox Studio (Enable Pinch/Zoom on lightbox - Lightbox captions only mode) 🗓️ Delivery Date Picker (Squarespace Date picker form field) 💫 Gallery block 7.1 workaround 🥳 No-code customisations for Squarespace 🚀 Learn how to rank new pages on Google in 48 hours! If you find my answer useful, let's leave a like or upvote so others with the same issue can find their solution. 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