Add Go to Top Button With Jquery for Blogger / Blogspot


Add Go to Top Button with Jquery for Blogger/Blogspot

Add “Go to Top Button” with Jquery. It is a Shortcut to come to top when you are at Bottom of Page...

















Add ‘Scroll to Top’ Button With Jquery:-




  1. Go To Blogger > Design > Edit HTML
  2. Back up your template
  3. Check the Expand Widget Templates box
  4. Then Use the Following code and Put it before </body> tag on your Template and Save...



<style type='text/css'>
#MFS-StoTop {-moz-border-radius: 5px;-webkit-border-radius: 5px;border-radius: 5px; width:100px;background-color:

#EEEEEE;background-color: rgba(238, 238, 238, 0.6);filter: progid:DXImageTransform.Microsoft.gradient

(startColorStr=&#39;#99EEEEEE&#39;,EndColorStr=&#39;#99EEEEEE&#39;);text-

align:center;padding:5px;position:fixed;bottom:10px;right:10px;cursor:pointer;color:#444;text-decoration:none;border:1px solid

#C9C9C9;}
</style>
<script type="text/javascript" src="http://yourjavascript.com/24490205115/Syed Bahadur Shah (MeGa FiLeS StOrE) Scroll To Top Jquery 1.5.1.js"></script>

<script type='text/javascript'>
$(function() {
    $.fn.scrollToTop = function() {
    $(this).hide().removeAttr(&quot;href&quot;);
    if ($(window).scrollTop() != &quot;0&quot;) {
        $(this).fadeIn(&quot;slow&quot;)
    }
    var scrollDiv = $(this);
    $(window).scroll(function() {
        if ($(window).scrollTop() == &quot;0&quot;) {
        $(scrollDiv).fadeOut(&quot;slow&quot;)
        } else {
        $(scrollDiv).fadeIn(&quot;slow&quot;)
        }
    });
    $(this).click(function() {
        $(&quot;html, body&quot;).animate({
        scrollTop: 0
        }, &quot;slow&quot;)
    })
    }
});
$(function() {
    $(&quot;#MFS-StoTop&quot;).scrollToTop();
});
</script>
<center>

<a href='#' id='MFS-StoTop' style='display:none;'>Scroll to Top </a>
</center>




You Are Done!

Thanks Take Care !!!





No comments:

Post a Comment

Previous Post Next Post Home