Image Positioning

1

I'm having a problem positioning images in a website I'm developing. Some of them apparently are not fitting into a line, in this case, I placed 4 per line. I made a few attempts, created a div that accommodated the entire contents of the image, thus:

  <div class="posicao">
    <div class="produtos-wrapper">
      <div class="produtos-conteudo one-fourth"> 
          <a href="detalhes.php?produto=<?php echo $row_rsProdutos['id_produto']; ?>&dep=<?php echo $row_rsProdutos['id_departamento']; ?>&subdep=<?php echo $row_rsProdutos['id_subdepartamento']; ?>"><img class="photo" src="<?php echo $foto; ?>"  /></a>
            <div class="content">
              <h3 class="name"><?php echo $row_rsProdutos['descricao'];  ?> </h3>
              <span class="job-title"> <?php echo $row_rsProdutos['codigo_msb']; ?> </span> </div>
          </div>
      </div>
      <?php } while ($row_rsProdutos = mysql_fetch_assoc($rsProdutos)); ?>              
    </div>

And the css, like this:

.posicao {
float: right;
width:auto;     
}

But the images still have spaces. The site for verification is this Site to view

    
asked by anonymous 13.01.2015 / 17:33

1 answer

2

When you work with div, basically you have several support squares for inserting content, whether it is text or multimedia. In case, there is a lack of standardization of height and therefore the divs do not fit.

Add this to your CSS:

.produtos-conteudo{
height: 200px;
}
    
13.01.2015 / 17:38