返回顶部

主要代码
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<!-- css -->
<style type="text/css">
#totop {
position: fixed;
bottom: 3em;
right: 1em;
cursor: pointer;
}
</style>
<!-- include javascript -->
<script src="assets/js/jquery-1.11.2.min.js"></script>
<!-- html -->
<div id="totop" style="display: block; opacity: 1;">
<a title="返回顶部"><img src="assets/images/scrollup.png"></a>
</div>
<!-- include javascript -->
<script src="assets/js/totop.js"></script>