SCROLL TOP & SCROLL BOTTOM BUTTONS-1

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<style>
#toplink, #botlink {
          position: fixed;
          right: 1%;
          bottom: 50%;
          padding: 10px;
          margin: 0 -20px 0 0;
          color: #FFFFFF;
          font: 14px Arial;
          background: #105105;
          border: 1px solid #FBBB22;
          border-bottom: 1px solid #FBBB22;
          border-radius: 6px 3px 0 0;
          z-index: 99;}
#botlink {
          top: 50%;
          padding: 10px;
          background: #661111;
          bottom: auto;
          border: 1px solid #FBBB22;
          border-top: 1px solid #FBBB22;
          border-radius: 0 0 3px 6px;}
#toplink:hover {
          color: #FFFFFF;
          background: #207907;
          text-decoration: none;}
#botlink:hover {
          color: #FFFFFF;
          background: #FF1111;
          text-decoration: none;}
</style>
<script>
$.fn.ready(function() {
$("a[href=#top]").live("click", function(e) {
$("html,body").animate({scrollTop:0}, 1000);
e.preventDefault();});
$("a[href=#bot]").live("click", function(e) {
$("html,body").animate({scrollTop:$(document).height()}, 1000);
e.preventDefault();});});
</script>
<a href="#top" id="toplink" title="Go to top"></a>
<a href="#bot" id="botlink" title="Go to bottom"></a>';