操作成功!
$(function(){
$(window).scroll(function(){
var scrollTop=document.body.scrollTop||document.documentElement.scrollTop;
document.getElementById('backTop').style.top=scrollTop+250+"px";
if(scrollTop>100){document.getElementById('backTop').style.display="block";}
else{document.getElementById('backTop').style.display="none";}
});
document.getElementById('backTop').onclick=function(){
document.body.scrollTop=0;
document.documentElement.scrollTop=0;
document.getElementById('backTop').style.display="none";
}
});
-->