Css and jQuery: How do I trigger the repositioning of a CSS3-animated element back to where it was before the animation?
问题 http://jsfiddle.net/cD4Gr/4/ Le Code: $j(document).bind('click', function() { $j("#test").css({ bottom:0px }) }); Looking in the inspector, even when the element is at the top of the page, it still says it's bottom value is 0. Maybe I need to play the animation in reverse somehow? or play a different animation? (Using Bottom %, rather than top %) 回答1: As you were thinking you can make a second keyframe block to reset it back to the bottom: @-webkit-keyframes reset_to_bottom { 0%, 100% { top: