zoukankan      html  css  js  c++  java
  • 返回头部的小火箭

    <!DOCTYPE html>
    <html>
    <head lang="en">
    <meta charset="UTF-8">
    <title></title>
    <style>
    body {
    2000px;
    }
    .top{
    position: fixed;
    right:50px;
    bottom:100px;
    display: none;
    }

    </style>
     
     
    </head>
    <body>
    <div id="gotop" class="top">
    <img src="images/Top.jpg" alt=""/>
    </div>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    <p>天王盖地虎,小鸡炖蘑菇</p>
    </body>
    </html>
    <script type="text/javascript">
    var oGotop = document.getElementById("gotop");
    window.onscroll = function(){
      var h = document.documentElement.scrollTop || document.body.scrollTop;
      var y = 100;
      if( h>y ){
         oGotop.style.display = "block";
         oGotop.onclick = function(){
             document.documentElement.scrollTop = 0; 
             oGotop.style.display = "none";  
         }
      }
    }
    </script>
  • 相关阅读:
    jmeterxpath的用法
    Jmeter中Websocket协议支持包的使用
    http 错误代码汇总
    Jmeter正则表达和xpath
    SSH Secure Shell Client安装和使用
    SecureCRT安装步骤
    DataRow转化成对象
    vb.net 与 c# 的switch ... case ...的一个重要区别
    DataRow 转换成Entity实例
    Sqlserver查找数据库中含有某字段的所有表
  • 原文地址:https://www.cnblogs.com/tis100204/p/10328774.html
Copyright © 2011-2022 走看看