KG1234 Posted July 4, 2020 Share Posted July 4, 2020 Hey everyone! On a site I am working on I am trying to layer two images of a neon sign (One with the sign off, and one with the sign on), so when the user hovers the mouse over the "turned off" image, the sign turns on. I found the code for how to do this online, and it works great on the backend, but when I got to publish for some reason the top image scales out and does not line up anymore. The two images are the exact same resolution and should lineup perfectly as they do when I'm editing. Any thoughts or ideas why this is happening? Code below, and screenshots are attached. https://www.thepridebeautylounge.com/ Password: TPBL Code: <div class="image-swap"> <img src="https://static1.squarespace.com/static/5ef632f039c60326990986d8/t/5eff89a5fcd86f0cfeb88abc/1593805226929/WEB_The+Pride+Beauty+Lounge+Logo+Rectangle+Grey.jpg"> <img src="https://static1.squarespace.com/static/5ef632f039c60326990986d8/t/5eff89b4e5e0f777e3f8f8f0/1593805244836/WEB_The+Pride+Beauty+Lounge+Logo+Rectangle+Pink.jpg"> </div> - - - - - - Custom CSS: .image-swap img:nth-child(1) { position: absolute; transition: 1s; } .image-swap img:nth-child(1):hover { opacity: 0; } Link to comment
rwp Posted July 4, 2020 Share Posted July 4, 2020 Add this in. .image-swap:last-child { position: absolute; } tuanphan 1 Link to comment
possejadon Posted November 4, 2020 Share Posted November 4, 2020 Did this work for you @KG1234 ? I'm experience the same issue and can't seem to fix it with the above code. Link to comment
tuanphan Posted November 6, 2020 Share Posted November 6, 2020 On 11/5/2020 at 6:10 AM, possejadon said: Did this work for you @KG1234 ? I'm experience the same issue and can't seem to fix it with the above code. If 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 How to: Setup Password & Share url - Insert Custom CSS - Page Header - Upload Custom Font - Upload File - Find Block ID - Contact Customer Care 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