Change form style after hovering over h1 with CSS only - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:Hover to change

Description

Change form style after hovering over h1 with CSS only

Demo Code

ResultView the demo in separate window

<html lang="en">
 <head> 
  <style>
#fast form {<!--from  www.jav a 2s  . c  o m-->
   color:Chartreuse;
}

#fast h1:hover~form {
   color:yellow;
}
</style> 
 </head> 
 <body translate="no"> 
  <div id="fast"> 
   <h1>Lorem ip</h1> 
   <br> 
   <form method="post"> 
    <input type="hidden" nam="fast_s" value="true"> 
    <div> 
     <h2>Lorem ipsum</h2> 
    </div> 
   </form> 
  </div>  
 </body>
</html>

Related Tutorials