<html>
<head>
<style>
#myDIV {
width: 300px;
height: 200px;
background: red;
animation: mymove 5s infinite; /* Safari 4.0 - 8.0 */
animation: mymove 5s infinite;
}
/* Safari 4.0 - 8.0 */
@-webkit-keyframes mymove {
50% {background-color: blue;}
}
@keyframes mymove {
50% {background-color: blue;}
}
</style>
</head>
<body>
<h1>Animation of background-color</h1>
<p>Gradually change the background-color from red to blue, and back to red:<p>
<div id="myDIV"></div>
<p><b>Note:</b> CSS Animations do not work in Internet Explorer 9 and earlier versions.</p>
</body>
<!-- Mirrored from www.w3schools.com/cssref/tryit.asp?filename=trycss_anim_background-color by HTTrack Website Copier/3.x [XR&CO'2014], Wed, 05 Jun 2019 13:18:18 GMT -->
</html>