模仿优酷社区返回顶部demo代码
发布时间:2015-10-15, 12:14:44 分类:HTML | 编辑 off 网址 | 辅助
正文 2047字数 77,889阅读
http://mytv.youku.com/
Run code
Cut to clipboard
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<!--<base href="http://lizhenqiu.com/">-->
<script src="jquery-1.8.3.min.js" type="text/javascript"></script>
Run code
Cut to clipboard
<style>
#scrolltop{z-index:10;position:fixed;display:block;margin:-30px 0 0 15px;width:40px;cursor:pointer;}.js_scrolltop{bottom:-100px;}#scrolltop:hover{text-decoration:none;}.ie6 #scrolltop{position:absolute;bottom:auto;}#scrolltop a{display:block;width:30px;height:80px;padding:0;line-height:12px;text-align:center;color:#787878;text-decoration:none;background:url(scrolltop_1.png) no-repeat 0 0;}a.scrolltopa .scrolltopb{position:absolute;width:16px;height:30px;top:37px;left:7px;}a.scrolltopa .scrolltopb img{width:16px;}a.scrolltopa:hover .scrolltopb{top:39px;}a.replyfast{background-position:0 -30px !important;}a.replyfast:hover{background-position:-40px -30px !important;}a.returnlist,a.returnboard{background-position:0 -60px !important;}a.returnlist:hover,a.returnboard:hover{background-position:-40px -60px !important;}#scrolltop a b{visibility:hidden;font-weight:normal;}
</style>
Run code
Cut to clipboard
lizhenqiu
Run code
Cut to clipboard
<script src="f.js" type="text/javascript"></script>
</head>
<body style="height:9999px;">
<div id="scrolltop" class="js_scrolltop" style="left: 1452px; opacity: 0; bottom: -100px;">
<a class="scrolltopa"><s class="scrolltopb"><img src="scrolltop_2.png" alt="" style="display: inline-block; overflow: hidden; height: 14px;"></s><b>返回顶部</b></a>
</div>
</body>
</html>
Run code
Cut to clipboard
/uploadfiles/d21299f1927c6d8cebbd87826e0f9d05_71652.rar
(支付宝)给作者钱财以资鼓励 (微信)→
暂无评论 »