Jump to content

100% height inside <li> element


sini-maaria

Recommended Posts

Hi, I've been struggling with this for a while now. http://www.creamedia.fi/horisontal_slider/ Is there any possibility to get scrollbars working inside the content areas? I don't want a scrollbar for the body.Overflow is set to auto and for all the parent elements height: 100%; min-height: 100%; (including html and body). I appreciate all the help, thanks.

Link to comment
Share on other sites

You will find that part of the problem stems from adding margin and padding to elements that already have 100% height. Padding and margins are added in addition to the element's height.Another thing you should change is the min-height declarations. There is no purpose in setting min-height when the height is already set. min-height and max-height are only good on elements that may vary in height. You should also remove any "width: 100%" declarations because elements naturally are 100% wide with the additional advantage that margin and padding are actually accounted for. Anyways, getting straight to the very root of the problem: You forgot a "height: 100%" property on the <ul> element.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...