簡単なアニメーション
<!DOCTYPE html> <html> <head> <style> div#anime1{ width:100px; height:100px; background:red; animation:myfirst 5s; -webkit-animation:myfirst 5s; /* Safari and Chrome */ } @keyframes myfirst{ from {background:red;} to {background:yellow;} } @-webkit-keyframes myfirst{ /* Safari and Chrome */ from {background:red;} to {background:yellow;} } </style> </head> <body> <h3>簡単なアニメーション</h3> <div id="anime1"></div> </body> </html>