I can not insert the logo on the cap

HTML

<div id="header"> <img src="img/header.jpg"> <img id="sm" src="img/sm.png"> <img id="cross" src="img/cross.png"> </div> 

CSS

 body{ margin:0; padding: 0; line-height: 1.6; font-size: 16px; } #header{ position: relative; } #sm{ float: left; position: absolute; margin-top: 16px; left: 176px; } #cross{ float: right; margin-top: 96px; right: -176px; } 

Result enter image description here

  • 2
    And where do you 1) is located, in your opinion, the cap and 2) which of the images is the logo? - nick_n_a
  • Maybe you mean the icon in the title on the left? - nick_n_a
  • They should be placed on the cap. Indents have already been made, you just need to put them on the picture - FLWRZ4U
  • Set style=position:absolute;left:0px;top;0px; in the logo picture and position the left top as you like - nick_n_a
  • Is it for the cap to set such values? - FLWRZ4U

3 answers 3

It seems to me that it will be easier:

 #header{ background: url(img/header.jpg) no-repeat; } 

    if quick then

     <div id="header"> <img style="position:absolute;left:0px;top;0px;" src="img/header.jpg"> <img id="sm" src="img/sm.png"> <img id="cross" src="img/cross.png"></div> 

    But this is a great evil. You can not do this;

    • 3
      so answer as it should, and do not show crutches! - MaximPro

    Need to change the order of the blocks

     <img id="sm" src="img/sm.png"> <img id="cross" src="img/cross.png"> <img src="img/header.jpg">