Keyword

Putting K2 Content Module in two columns: question

  • Robert Peterson
  • Robert Peterson's Avatar Topic Author
  • Offline
  • Junior Member
More
10 years 10 months ago #120679 by Robert Peterson
Hello!

I've split the K2 content module into two columns using the following CSS:
	

Attachment not found



Any idea how to fix this? Thanks!

Please Log in or Create an account to join the conversation.

More
10 years 10 months ago - 10 years 10 months ago #120680 by Vitaly
Logic is simple. That module only counts width of your columns that depends on amount of that columns. Nothing changes height, so it's based on your item's description and their amount. If you want to have few columns with similar height you need to declare height via css.

Your columns is
Log in  or Create an account to join the conversation.

  • Yiota
  • Yiota's Avatar
  • Visitor
10 years 10 months ago #120681 by Yiota
You can also try to add a clear container after each odd item in order for your items to begin from the same top position.
You need to create an override of the k2 content module, if not already, and make a check like
<?php if (count($items)%2==0) echo '<li class="clearList"></li>'; ?>

Put this clear list right before the <?php endforeach; ?> occurs.

PS. Read here on how overrides work
getk2.org/documentation/tutorials/174-templating-with-k2-and-the-concepts-of-sub-templates

Please Log in or Create an account to join the conversation.