I have a div that is 400px high and it has content that scrolls inside. I have another div with an image inside, this div sits at the bottom of this parent div using position:absolute; bottom:0; but when I scroll it moves up the parent div with the content.
I have used jQuery to change the position of the div to the bottom each time the user scrolls the parent div, this works but it jumps each time the div scrolls.
Is there a way to do this with a smooth scroll? I would like it to just sit at the bottom of the parent div and not move at all.
Thanks
You could put the div with content inside of another div and position the image relative to the parent. You would have to account for the height of the scrollbar if present, but other than that it should work. I’ll try to come up with a jsfiddle for you.
http://jsfiddle.net/AwH9S/
You might want to implement some javascript to determine the size of the scrollbar and whether or not it’s present.