嗨我正在嘗試使用CSS在屏幕上移動圖像。目前,當我運行它時,只出現在頁面的頂部。這是我正在嘗試的代碼。我試圖在Chrome中運行這個。CSS動畫/使用@KEYFRAMES將圖像向上移動屏幕
<head>
<style>
#float{
width: 200px;
height: 500px;
position: relative;
animation: floatBubble 2s inifnate;
animation-directon: normal;
}
@keyframes floatBubble{
0% {
top:0;
-webkit-animation-timing-function: ease-in;
}
100% {
top: 500px;
animation-timing-function: ease-out;
}
}
</style>
</head>
<body style="background-color:#FF9900; color:#CC0033; text-align:center">
<div id="float">
<img src ="bub.png" height="100px" width="100px" alt="bubbles">
</div>
</body>
方式拼寫'infinite'夥伴。 :P也,你有0%的供應商前綴,而不是100%?而且即時通訊假設你說,由於缺少其他廠商前綴,60%的人不使用Chrome/Safari? – PlantTheIdea