我正在使用<marquee>
在jsp页面中滑动图像。但是,我找不到如何从jsp页面的右侧顶部到右侧底部滑动图像。有人可以帮我怎么做吗?
答案 0 :(得分:1)
您可以使用jQuery的native animate()函数:
HTML:
<img height="100" width="100" id="box" src="#" />
CSS:
#box{
position:absolute;
right:0px;
top:0px;
}
jQuery的:
$(function() {
$theBox = $("#box");
$theBox.animate({
top:$(window).height()-$theBox.height()
}, 1000);
});