Forum Moderators: not2easy

Message Too Old, No Replies

Margin, padding and scrollbars.

         

ultradude25

2:21 pm on Mar 29, 2010 (gmt 0)

10+ Year Member



I have a rounded border around all the content in my site (Thanks to border-radius) and 50px of margin in the body so it's keeps off the edges of the browser window.

The problem is, the right of the margin doesn't apply when you have a page that's too wide, which makes a horizontal scrollbar.
<snip>

I've also tried padding instead of margin, and both but it acts exactly the same.


The problem seems to be that the scrollbar ignores the padding/margin.

[edited by: limbo at 7:36 am (utc) on Apr 1, 2010]
[edit reason] No URL's please, see TOS [webmasterworld.com] [/edit]

limbo

8:28 am on Apr 1, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Do you see this issue in all browsers? Judging by your question it sounds like the box model issue. IE6/7 render the box model differently to most other browsers. You may need to compensate for your padding, pad only the contents, or create a wrapper to rein in you content.