Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery-1.8.2.min.js"></script>
<meta charset=utf-8 />
<title>JS Bin</title>
</head>
<body>
  <div id="bg">
  </div>
</body>
</html>
 
#bg {
  position: fixed;
  background-color: black;
  height: 100%;
  width: 100%;
  margin: 0;
  padding:0;
  opacity: 0;
}
body {
  background-color: white;
  height: 1000px;
}
 
$("#bg").hover(function() {
  $(this).stop().animate({ opacity: 1 }, 1000);
}, function( ) {
  $(this).stop().animate({ opacity: 0 }, 1000);
});
  
  
  
  
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
brunomartinspro
0viewers