CelsoDiniz Posted March 7, 2023 Share Posted March 7, 2023 Hi, On my page https://www.celsodinizphoto.com/ the very first object is a carousel gallery block, under the title of Favorites. Question: Is it possible to have that whole block to be clickable and associated with a link to https://www.celsodinizphoto.com/home ? I do not want to add that clickthrough link to every image in the gallery. I am looking for a CSS solution to have the whole carousel gallery block link to a particular page when the user clicks on it or any image of it. Thanks! Celso. Link to comment
Solution tuanphan Posted March 10, 2023 Solution Share Posted March 10, 2023 Add to Last Line in Code Injection > Footer <script> $(document).ready(function() { $("div#block-yui_3_17_2_1_1677849844342_21973").click(function() { var link = $(this).text(), href = "https://google.com"; window.location.href=href; }); }); </script> Replace google with new url CelsoDiniz 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
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment