I've got position:fixed;
container and it is always fixed when I sroll page on PC (remains on the top left corner).
On iPhone it appears on the top left corner but it stays there forever as I scroll. Is there any solution to that?
I've got position:fixed;
container and it is always fixed when I sroll page on PC (remains on the top left corner).
On iPhone it appears on the top left corner but it stays there forever as I scroll. Is there any solution to that?
The best option here seems Media Queries, see: http://www.w3.org/TR/css3-mediaqueries/ and http://webdesignerwall.com/tutorials/css3-media-queries for examples.
edit: Miss read the question:
As Josh' link suggests you can achieve this by:
window.onscroll = function() {
document.getElementById('fixedDiv').style.top =
(window.pageYOffset + window.innerHeight - 25) + 'px';
};