Tumblr-like footer

When you have endless scrolling on Tumblr, when you mouse over the bottom of your panel, the footer fades out. How can I use this technique for my site?

+5
source share
1 answer

If you use jQuery library, it will be very simple.

Suppose you have the following footer with id = "footer" with a custom style

<div id="footer" style="position:fixed;bottom:0px;left:0px;margin:0px;width:100%;opacity:0.001">
    <center>StackOverflow | About US | Privacy | Blah Blah Blah | Something </center>
</div>

Then add the following java script

<script type="text/javascript">
   $(document).ready(function() { 
    $('#footer').hover(
        function(){
            $(this).stop().fadeTo('slow',1);
        },
        function(){
            $(this).stop().fadeTo('slow',0.001);
        });

    });
</script>

make sure you include the jQuery library, if not just adding the following line to the head section:

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script>
+3
source

All Articles