HTML CSS examples for CSS Widget:Hover
display a div while another div is hovered with position: fixed
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> #parent {<!--from w w w . j a v a2 s.c o m--> position:fixed; top:0px; text-align:right; height:33px; width:100%; } #msg { position:absolute; right:35px; display:none; } #img:hover + #msg { display:block; } </style> </head> <body> <div id="parent"> <div id="img"> <a href="some link here"> <img src="https://www.java2s.com/style/demo/InternetExplorer.png"> </a> </div> <div id="msg"> Lorem ipsum dolor sit amet, consectetur </div> </div> </body> </html>