Viktor Viktor - 3 years ago 190
HTML Question

Background picture has margin top,left,right how to remove it

Background picture has margin top,left and right, trued to remove it with position absolute and relative, didn't worked what can true else to remove them.

HTML

<header class="banner"></header>


Css

banner {
background-image: url(../images/banner.jpg);
min-height: 750px;
background-size: cover;
background-position: center top; }


enter image description here

Answer Source

This seems to be initial margin of HTML page. Remove it through CSS:

body{margin:0}
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download