您的 宣传网址:
复制网址
手机查看
宣传有奖
首页
编程学习
源代码:
html编辑器
颜色值转换
点击运行
空若网<script src="https://cdn.staticfile.net/jquery/1.10.2/jquery.min.js"> </script> <script> $(document).ready(function(){ $("button").click(function(){ alert($("div").scrollTop()+" px"); }); }); </script> <div style="border:1px solid black;width:100px;height:150px;overflow:auto"> This is some text. This is some text. This is some text. This is some text. This is some text. This is some text. This is some text. This is some text. This is some text.</div><br> <button>返回垂直滚动条的位置</button> <p>向下移动滚动条,再次单击该按钮。</p>
运行结果:
×
空若网-温馨提示
您尚未登陆
请登陆后在来吧
立即登陆
注册账号
空若网