Jump to content

Recommended Posts

Доброе время суток, возникла проблема при натяжке своего шаблона на движок. Как вывести в 3 колонки блок товаром?

Сделал так но нечего не выходит:
<див class="kontent1">
[Описание раздела]
[Популярные товары]
{foreach name=products item=product from=$products}
<див class="lot">
[заголовок]
[картинка]
[описание]
[цена, корзина]
</див>
{if $smarty.foreach.products.iteration%3 == 0}
<див class="clear"><!-- /--></див>
{/if}
{/foreach}
[</див>]

Link to post
Share on other sites
  • 2 years later...

.lot{

    float: left;
    position: relative;
    width: 33%;

}

 

Можно добавить заданную высоту, чтоб товары выводились на одном уровне, например:

height: 180px;

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...