Page 1 of 1
[CSS] How to create a non-scrolling column
Posted: Sat Jan 16, 2010 10:25 am
by techkid
Hello.
I want to know how to create a non-scrolling div column on top of the page. It should not scroll even the user scrolls the page.
Example: We have a toolbar in Facebook. Where chat and all are there.
Please help.
Thank you in advance.
Re: [CSS] How to create a non-scrolling column
Posted: Sat Jan 16, 2010 12:42 pm
by califdon
Re: [CSS] How to create a non-scrolling column
Posted: Sat Jan 16, 2010 11:27 pm
by techkid
is there any other way? without iframe?
Re: [CSS] How to create a non-scrolling column
Posted: Sun Jan 17, 2010 9:51 am
by califdon
techkid wrote:is there any other way? without iframe?
You could write a lot of Javascript code to capture whenever the user scrolls and then offset the relative position of the top div, but an iframe would be a lot easier. To see what would be involved, look at
http://codepunk.hardwar.org.uk/ajs02.htm.
Re: [CSS] How to create a non-scrolling column
Posted: Mon Jan 18, 2010 10:42 am
by pickle
position:fixed If you don't care about IE.
You could also maybe put your header in 1 div, and the rest of the content in the other. Set overflow in the page to hidden, and the overflow in the div to scroll.
Re: [CSS] How to create a non-scrolling column
Posted: Mon Jan 18, 2010 11:21 am
by kaszu
Re: [CSS] How to create a non-scrolling column
Posted: Wed Jan 20, 2010 12:43 pm
by daedalus__
IE7+ support fixed positioning.
i wonder how many people really still use IE6?
Re: [CSS] How to create a non-scrolling column
Posted: Wed Jan 20, 2010 12:53 pm
by stoshrocket
daedalus__ wrote:IE7+ support fixed positioning.
i wonder how many people really still use IE6?
20.99% still use IE6 as of December 2009, although with the recent security flaw people are being pushed (even by governments in the case of France and Australia) to upgrade from IE6.
Until this figure drops, I'd stick with iframes. Or just disable the element to IE6 users using an if statement in your CSS, displaying an "please upgrade" comment instead, but that's not very user friendly
EDIT: Changed user share from W3 statistics to Wikipedia average broswer share statictics (reference:
W3 statictics,
Multiple Sets of Data Collected on Wikipedia.)
Re: [CSS] How to create a non-scrolling column
Posted: Wed Jan 20, 2010 5:23 pm
by Eran
Re: [CSS] How to create a non-scrolling column
Posted: Wed Jan 20, 2010 11:07 pm
by daedalus__
well if microsoft can ignore what mozilla users say when they have 20% i can feel okay about ignoring the 20% that still use IE6. usually the way i handle it is by displaying very large red letters saying that they should stop using ie6 immediately
haha, really though. that figure should drop as more and more people adopt windows 7 this year. i hope...
EDIT:
http://en.wikipedia.org/wiki/Internet_E ... #Criticism
HAHA AWESOME
im putting
that on my website TODAY!