Reputation: 473
I'm making a landing and I've this set of rules applied for the body and html elements:
html {
margin: 0px;
height: 100%;
width: 100%;
}
body {
margin: 0px;
min-height: 100%;
width: 100%;
}
Also, everything is viewported:
<meta name="viewport" content="width=device-width, initial-scale=1">
And on the picture, below, you can see main blocks of the page, they all have width 100%
However, nothing of what I mentioned really helped and the blocks of the page despite they all have 100% width, have different size and, there's a horizontal scrollbar too.
What should I do to get rid of the scrollbar and to make all the blocks be the size of a current viewport?
Upvotes: 0
Views: 4133
Reputation: 360
you shouldn't have horizontal scrollbar. If you have horizontal scrollbar - one of the elements overflow the main page. Try to find which makes the problem. If you use overflow - you don't correct the problem, but cover it. It will blow when you scale the page - the content won't be center.
Upvotes: 3