Block size under background



  • .no-image {
        background: url('/assets/images/no-image.jpg') no-repeat center center #FFF;
        background-size: contain;
    }
    .categories {
        float: left;
        width: 23%;
    }
    <div class="categories no-image" style="
         background: url('http://pir.uborka25.ru/assets/img/sets/035nb-zhivi-yarko.jpg') no-repeat;
         background-size: contain;
         margin: 1%;
         ">
    <div class="categories-dark">
    <span class="hint">C кремом</span>
    <div class="link-category">
     <a href="kapkeyki  /s-kremom/" title="Классические капкейки с кремом">Выбрать </a>
    </div>
    </div>
    

    </div>

    We need the height of the block to hang on to the height of the picture at a given width. On a clean sss, js is already in place.



  • There's gonna be a real picture of it, sss.


Log in to reply
 


Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2