• jquery最简单的右侧返回顶部代码(滚动才出现)


    <div style="display:none;" id="gotopbtn" class="to_top"><a title="返回顶部" href="javascript:void(0);"></a></div>
    <script type="text/javascript">
    $(function(){
    
        $(window).scroll(function(){
            $(window).scrollTop()>200 ? $("#gotopbtn").css('display','').click(function(){
                $(window).scrollTop(0);
            }):$("#gotopbtn").css('display','none');    
        });
        
    });
    </script>

     CSS代码

    .to_top a,.to_top a:hover{ background:url(../images/gotop1_03.gif) no-repeat;}
    .to_top a{
        background-position:0 0;float:left;height:83px;overflow:hidden;width:25px;position:fixed;bottom:35px;cursor:pointer;right:20px;
        _position:absolute;
        _right:auto;
        _left:expression(eval(document.documentElement.scrollLeft+document.documentElement.clientWidth-this.offsetWidth)-(parseInt(this.currentStyle.marginLeft, 10)||0)-(parseInt(this.currentStyle.marginRight, 10)||20));
        _top:expression(eval(document.documentElement.scrollTop+document.documentElement.clientHeight-this.offsetHeight-(parseInt(this.currentStyle.marginTop, 10)||20)-(parseInt(this.currentStyle.marginBottom, 10)||20)));
    }
    .to_top span{ background:url(../images/gotop1_03.gif) no-repeat;}
    .to_top span{
        background-position:0 0;float:left;height:83px;overflow:hidden;width:25px;position:fixed;bottom:35px;cursor:pointer;right:20px;
        _position:absolute;
        _right:auto;
        _left:expression(eval(document.documentElement.scrollLeft+document.documentElement.clientWidth-this.offsetWidth)-(parseInt(this.currentStyle.marginLeft, 10)||0)-(parseInt(this.currentStyle.marginRight, 10)||20));
        _top:expression(eval(document.documentElement.scrollTop+document.documentElement.clientHeight-this.offsetHeight-(parseInt(this.currentStyle.marginTop, 10)||20)-(parseInt(this.currentStyle.marginBottom, 10)||20)));
    }
  • 相关阅读:
    Excel对象
    使用C#和Excel进行报表开发(6)
    使用C#和Excel进行报表开发(1)
    c# excel一个小例子
    HDU1226 BFS
    HDU2145 SPFA
    HDU1229
    HDU1535 spfa
    HDU1230
    HDU3986 SPFA
  • 原文地址:https://www.cnblogs.com/henshui/p/3300683.html
Copyright © 2020-2023  润新知