HTML CSS examples for CSS Widget:Hover Image
Display text over image on hover
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> div.title { display:none; position:relative; text-align:center; top:-171px; } a.wrapper:hover + div { display:block; } </style> <!-- ww w .j a v a2 s. co m--> </head> <body> <a class="wrapper"> <img style="margin-top:50px;" src="https://www.java2s.com/style/demo/Google-Chrome.png" alt=""> </a> <div class="title"> <h1>Lorem ips</h1> </div> </body> </html>