Image and video hosting by TinyPic
Image and video hosting by TinyPic

Animasi warna dengan CSS3 dan PNG

Senin, 16 Juli 2012
Tidak usah basa-basi lagi,
Langasung aje yee :D



GAMBAR PNG (bolong tengah'e) SETELAH DI LEGALISIR,,,HA






#udud-dulu {
width:300px;
height:300px;
}
#udud-dulu img{
background: red;
-moz-animation: super-rainbow 5s infinite alternate linear;
-webkit-animation: super-rainbow 5s infinite alternate linear;
-o-animation: super-rainbow 5s infinite alternate linear;
}

@-moz-keyframes super-rainbow {
0% { background: red; }
20% { background: orange; }
40% { background: yellow; }
60% { background: green; }
80% { background: blue; }
100% { background: violet; }
}
@-webkit-keyframes super-rainbow {
0% { background: red; }
20% { background: orange; }
40% { background: yellow; }
60% { background: green; }
80% { background: blue; }
100% { background: violet; }
}
@-o-keyframes super-rainbow {
0% { background: red; }
20% { background: orange; }
40% { background: yellow; }
60% { background: green; }
80% { background: blue; }
100% { background: violet; }
}

#udud-dulu img:nth-of-type(2) { -moz-animation-delay: 1s; }
#udud-dulu img:nth-of-type(3) { -moz-animation-delay: 2s; }
#udud-dulu img:nth-of-type(4) { -moz-animation-delay: 3s; }

#udud-dulu img:nth-of-type(2) { -webkit-animation-delay: 1s; }
#udud-dulu img:nth-of-type(3) { -webkit-animation-delay: 2s; }
#udud-dulu img:nth-of-type(4) { -webkit-animation-delay: 3s; }

#udud-dulu img:nth-of-type(2) { -o-animation-delay: 1s; }
#udud-dulu img:nth-of-type(3) { -o-animation-delay: 2s; }
#udud-dulu img:nth-of-type(4) { -o-animation-delay: 3s; }

<div id="udud-dulu">
<img src="http://i48.tinypic.com/e13zww.png">
<img src="http://i48.tinypic.com/e13zww.png">
<img src="http://i48.tinypic.com/e13zww.png">
<img src="http://i48.tinypic.com/e13zww.png">
</div>

 
 Note:  (-moz-) for mozila
            (-webkit-) for gchrome & safari
            (-o-) for opera 

            (width & height) sesuaikan ukuran gambar

Posting Komentar

:)) ;)) ;;) :D ;) :p :(( :) :( :X =(( :-o :-/ :-* :| 8-} :)] ~x( :-t b-( :-L x( :-q =))