Change img when hover - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Hover Image

Description

Change img when hover

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">
#first {<!--   ww  w.  ja  va  2  s .co m-->
   background:no-repeat url('https://www.java2s.com/style/demo/Google-Chrome.png');
   width:201px;
   height:201px;
}

#first:hover {
   background:no-repeat url('https://www.java2s.com/style/demo/Google-Chrome.png');
   width:201px;
   height:201px;
}
</style> 
 </head> 
 <body> 
  <div id="first">
    Lorem i 
  </div>  
 </body>
</html>

Related Tutorials