Keyword

No columns in K2 content module

  • Jon Freeman
  • Jon Freeman's Avatar Topic Author
  • Offline
  • New Member
More
4 years 11 months ago #171879 by Jon Freeman
No columns in K2 content module was created by Jon Freeman
Sorry if this is a dim Newbie question.

I have been trying to put a K2 content module in the feature position of my template. It is intended to display 4 specific items from within a category that I am not using anywhere else.

The four items are displaying. But they are not appearing in the 4 columns that I have set up in the leading options in the edit category item. They are displaying as a list as per the attached screenshot.

I have looked everywhere I can think of for where the content module might be getting its definition overridden. What am I missing?

Thanks for your help,
Jon
Attachments:

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

More
4 years 11 months ago #171887 by JoomlaWorks
Replied by JoomlaWorks on topic No columns in K2 content module
The module has its own layout, different from category layouts. By default it presents the items in a list (vertical). The layout settings in the category only control how the items would show when viewing the K2 category alone.

You need to add some CSS code to "break" positioning into 4 columns. I could give you the CSS changes, but you need to have your site online to check it out.

Fotis / JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

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

  • Jon Freeman
  • Jon Freeman's Avatar Topic Author
  • Offline
  • New Member
More
4 years 11 months ago #171895 by Jon Freeman
Replied by Jon Freeman on topic No columns in K2 content module
Thanks, Fotis, that is really helpful. At least I can stop banging my head against a wall trying to do the impossible!

I am reluctant to go down a route of modifying code, though. Is there another way to achieve the result I am looking for within the structure of K2 and Joomla as supplied? Or do I need to revisit the design itself?

Regards,
Jon

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

More
4 years 11 months ago #171899 by JoomlaWorks
Replied by JoomlaWorks on topic No columns in K2 content module
You can create overrides for both the component views and the modules.

Compared to regular Joomla overrides, K2's are a bit supercharged: getk2.org/documentation/tutorials/174-templating-with-k2-and-the-concepts-of-sub-templates

For the K2 Content module, simply copy the "default" folder from /modules/mod_k2_content/tmpl/ into /templates/YOUR_JOOMLA_TEMPLATE/html/mod_k2_content/. The same applies for the other K2 modules as well. You can even create multiple sub-templates for K2 Content specifically.

Finally, if you copy /components/com_k2/css/k2.css into /templates/YOUR_JOOMLA_TEMPLATE/css/ you'll also be able to totally override the default K2 CSS. If you want to start fresh with your own CSS rules, you can disable loading k2.css in K2's component settings.

Overall, K2 is the most flexible component to override in the Joomla community (even compared to core Joomla components).

Fotis / JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

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


Powered by Kunena Forum