Banner width does not depend on browser size

I have the same problem as the Stackoverflow.com website. The problem is the width of the banner over the content or body of the website. I want to reduce the width of the browser page, but keep the banner size no matter what resolution works in the browser.

Example. If you reduce the width of this page, you will see a scroll bar appear so that you can move the page to the right and see the content is hidden. However, if you look at the banner, the banner will have a new width that would reduce the page.

Example of reducing browser width and banner is not displaying properly

+4
source share
1 answer

If I understand correctly, you can define min-width in the body. Write like this:

body{ min-width:975px; } 

This mainly happened when the element had auto width and its parent did not have a width definition.

+3
source

Source: https://habr.com/ru/post/1432185/


All Articles