nickjamespiper Posted September 1, 2020 Share Posted September 1, 2020 (edited) Site URL: http://nickpiper.tv I have three options for users to click in my navigation bar. FILMS ABOUT PEOPLE There is a secondary drop down menu under the PEOPLE link that reveals three options for users to click on: PEOPLE EFFECTS CARS When users click on these links is there a way to make the navigation bar update to show the title of the drop down menu page, so for example if a user selects EFFECTS, then the navigation bar updates to: FILMS ABOUT EFFECTS I understand this will require some unsupported code editing, but I'm hoping someone has a clever trick they can share. Thanks Edited September 1, 2020 by nickjamespiper Beyondspace 1 Link to comment
Beyondspace Posted September 1, 2020 Share Posted September 1, 2020 You can insert this snippet in the FOOTER Settings -> Advanced -> Code Injection <script> (function() { var matchedUrl = location.href.replace(location.origin, "") var linkItem = document.querySelector('.Header-nav-folder-item[href*="'+matchedUrl+'"]'); if (linkItem) { linkItem.parentNode.previousElementSibling.innerText = linkItem.innerText; } })(); </script> Greeting, it's BeyondSpace, I am Squarespace dev focus on provide solutions to enhance feature that squarespace.com can't provide.Feel free to check my current Squarespace Plugins Developement: Enable Pinch/Zoom on lightbox, Delivery Date Picker, Lightbox Studio pluginIf you find my answer fit your need, 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